You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gns3-server/gns3server/static/web-ui/main.e7b089d7c8fa292097fb.js

1 line
3.1 MiB

(window.webpackJsonp=window.webpackJsonp||[]).push([[1],{"+/L5":function(t,e,n){var i=n("t1UP").isCustomProperty,r=n("vd7W").TYPE,o=n("4njK").mode,a=r.Ident,s=r.Hash,c=r.Colon,l=r.Semicolon,u=r.Delim;function h(t){return this.Raw(t,o.exclamationMarkOrSemicolon,!0)}function d(t){return this.Raw(t,o.exclamationMarkOrSemicolon,!1)}function f(){var t=this.scanner.tokenIndex,e=this.Value();return"Raw"!==e.type&&!1===this.scanner.eof&&this.scanner.tokenType!==l&&!1===this.scanner.isDelim(33)&&!1===this.scanner.isBalanceEdge(t)&&this.error(),e}function p(){var t=this.scanner.tokenStart;if(this.scanner.tokenType===u)switch(this.scanner.source.charCodeAt(this.scanner.tokenStart)){case 42:case 36:case 43:case 35:case 38:this.scanner.next();break;case 47:this.scanner.next(),this.scanner.isDelim(47)&&this.scanner.next()}return this.eat(this.scanner.tokenType===s?s:a),this.scanner.substrToCursor(t)}function m(){this.eat(u),this.scanner.skipSC();var t=this.consume(a);return"important"===t||t}t.exports={name:"Declaration",structure:{important:[Boolean,String],property:String,value:["Value","Raw"]},parse:function(){var t,e=this.scanner.tokenStart,n=this.scanner.tokenIndex,r=p.call(this),o=i(r),a=o?this.parseCustomProperty:this.parseValue,s=o?d:h,u=!1;return this.scanner.skipSC(),this.eat(c),o||this.scanner.skipSC(),t=a?this.parseWithFallback(f,s):s.call(this,this.scanner.tokenIndex),this.scanner.isDelim(33)&&(u=m.call(this),this.scanner.skipSC()),!1===this.scanner.eof&&this.scanner.tokenType!==l&&!1===this.scanner.isBalanceEdge(n)&&this.error(),{type:"Declaration",loc:this.getLocation(e,this.scanner.tokenStart),important:u,property:r,value:t}},generate:function(t){this.chunk(t.property),this.chunk(":"),this.node(t.value),t.important&&this.chunk(!0===t.important?"!important":"!"+t.important)},walkContext:"declaration"}},"+4/i":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("odkN");i.Observable.prototype.let=r.letProto,i.Observable.prototype.letBind=r.letProto},"+Kd2":function(t,e,n){var i=n("vd7W").TYPE,r=n("4njK").mode,o=i.Comma;t.exports=function(){var t=this.createList();return this.scanner.skipSC(),t.push(this.Identifier()),this.scanner.skipSC(),this.scanner.tokenType===o&&(t.push(this.Operator()),t.push(this.parseCustomProperty?this.Value(null):this.Raw(this.scanner.tokenIndex,r.exclamationMarkOrSemicolon,!1))),t}},"+oeQ":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("H+DX");i.Observable.prototype.observeOn=r.observeOn},"+psR":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("16Oq");i.Observable.prototype.retry=r.retry},"+qxJ":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("GsYY");i.Observable.prototype.distinctUntilChanged=r.distinctUntilChanged},"+v8i":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.concat=i.concat},"/+5V":function(t,e){function n(t){function e(t){return null!==t&&("Type"===t.type||"Property"===t.type||"Keyword"===t.type)}var n=null;return null!==this.matched&&function i(r){if(Array.isArray(r.match)){for(var o=0;o<r.match.length;o++)if(i(r.match[o]))return e(r.syntax)&&n.unshift(r.syntax),!0}else if(r.node===t)return n=e(r.syntax)?[r.syntax]:[],!0;return!1}(this.matched),n}function i(t,e,i){var r=n.call(t,e);return null!==r&&r.some(i)}t.exports={getTrace:n,isType:function(t,e){return i(this,t,(function(t){return"Type"===t.type&&t.name===e}))},isProperty:function(t,e){return i(this,t,(function(t){return"Property"===t.type&&t.name===e}))},isKeyword:function(t){return i(this,t,(function(t){return"Keyword"===t.type}))}}},"/BcF":function(t,e){t.exports={name:"Selector",structure:{children:[["TypeSelector","IdSelector","ClassSelector","AttributeSelector","PseudoClassSelector","PseudoElementSelector","Combinator","WhiteSpace"]]},parse:function(){var t=this.readSequence(this.scope.Selector);return null===this.getFirstListNode(t)&&this.error("Selector is expected"),{type:"Selector",loc:this.getLocationFromList(t),children:t}},generate:function(t){this.children(t)}}},"/POA":function(t,e,n){window,t.exports=function(t){var e={};function n(i){if(e[i])return e[i].exports;var r=e[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=t,n.c=e,n.d=function(t,e,i){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(i,r,(function(e){return t[e]}).bind(null,r));return i},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=34)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.forwardEvent=e.EventEmitter=void 0;var i=function(){function t(){this._listeners=[],this._disposed=!1}return Object.defineProperty(t.prototype,"event",{get:function(){var t=this;return this._event||(this._event=function(e){return t._listeners.push(e),{dispose:function(){if(!t._disposed)for(var n=0;n<t._listeners.length;n++)if(t._listeners[n]===e)return void t._listeners.splice(n,1)}}}),this._event},enumerable:!1,configurable:!0}),t.prototype.fire=function(t,e){for(var n=[],i=0;i<this._listeners.length;i++)n.push(this._listeners[i]);for(i=0;i<n.length;i++)n[i].call(void 0,t,e)},t.prototype.dispose=function(){this._listeners&&(this._listeners.length=0),this._disposed=!0},t}();e.EventEmitter=i,e.forwardEvent=function(t,e){return t((function(t){return e.fire(t)}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IUnicodeService=e.IOptionsService=e.ILogService=e.IInstantiationService=e.IDirtyRowService=e.ICharsetService=e.ICoreService=e.ICoreMouseService=e.IBufferService=void 0;var i=n(14);e.IBufferService=i.createDecorator("BufferService"),e.ICoreMouseService=i.createDecorator("CoreMouseService"),e.ICoreService=i.createDecorator("CoreService"),e.ICharsetService=i.createDecorator("CharsetService"),e.IDirtyRowService=i.createDecorator("DirtyRowService"),e.IInstantiationService=i.createDecorator("InstantiationService"),e.ILogService=i.createDecorator("LogService"),e.IOptionsService=i.createDecorator("OptionsService"),e.IUnicodeService=i.createDecorator("UnicodeService")},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getDisposeArrayDisposable=e.disposeArray=e.Disposable=void 0;var i=function(){function t(){this._disposables=[],this._isDisposed=!1}return t.prototype.dispose=function(){this._isDisposed=!0;for(var t=0,e=this._disposables;t<e.length;t++)e[t].dispose();this._disposables.length=0},t.prototype.register=function(t){return this._disposables.push(t),t},t.prototype.unregister=function(t){var e=this._disposables.indexOf(t);-1!==e&&this._disposables.splice(e,1)},t}();function r(t){for(var e=0,n=t;e<n.length;e++)n[e].dispose();t.length=0}e.Disposable=i,e.disposeArray=r,e.getDisposeArrayDisposable=function(t){return{dispose:function(){return r(t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.WHITESPACE_CELL_CODE=e.WHITESPACE_CELL_WIDTH=e.WHITESPACE_CELL_CHAR=e.NULL_CELL_CODE=e.NULL_CELL_WIDTH=e.NULL_CELL_CHAR=e.CHAR_DATA_CODE_INDEX=e.CHAR_DATA_WIDTH_INDEX=e.CHAR_DATA_CHAR_INDEX=e.CHAR_DATA_ATTR_INDEX=e.DEFAULT_ATTR=e.DEFAULT_COLOR=void 0,e.DEFAULT_COLOR=256,e.DEFAULT_ATTR=256|e.DEFAULT_COLOR<<9,e.CHAR_DATA_ATTR_INDEX=0,e.CHAR_DATA_CHAR_INDEX=1,e.CHAR_DATA_WIDTH_INDEX=2,e.CHAR_DATA_CODE_INDEX=3,e.NULL_CELL_CHAR="",e.NULL_CELL_WIDTH=1,e.NULL_CELL_CODE=0,e.WHITESPACE_CELL_CHAR=" ",e.WHITESPACE_CELL_WIDTH=1,e.WHITESPACE_CELL_CODE=32},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.CellData=void 0;var o=n(8),a=n(3),s=n(6),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.content=0,e.fg=0,e.bg=0,e.extended=new s.ExtendedAttrs,e.combinedData="",e}return r(e,t),e.fromCharData=function(t){var n=new e;return n.setFromCharData(t),n},e.prototype.isCombined=function(){return 2097152&this.content},e.prototype.getWidth=function(){return this.content>>22},e.prototype.getChars=function(){return 2097152&this.content?this.combinedData:2097151&this.content?o.stringFromCodePoint(2097151&this.content):""},e.prototype.getCode=function(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content},e.prototype.setFromCharData=function(t){this.fg=t[a.CHAR_DATA_ATTR_INDEX],this.bg=0;var e=!1;if(t[a.CHAR_DATA_CHAR_INDEX].length>2)e=!0;else if(2===t[a.CHAR_DATA_CHAR_INDEX].length){var n=t[a.CHAR_DATA_CHAR_INDEX].charCodeAt(0);if(55296<=n&&n<=56319){var i=t[a.CHAR_DATA_CHAR_INDEX].charCodeAt(1);56320<=i&&i<=57343?this.content=1024*(n-55296)+i-56320+65536|t[a.CHAR_DATA_WIDTH_INDEX]<<22:e=!0}else e=!0}else this.content=t[a.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|t[a.CHAR_DATA_WIDTH_INDEX]<<22;e&&(this.combinedData=t[a.CHAR_DATA_CHAR_INDEX],this.content=2097152|t[a.CHAR_DATA_WIDTH_INDEX]<<22)},e.prototype.getAsCharData=function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]},e}(s.AttributeData);e.CellData=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ISoundService=e.ISelectionService=e.IRenderService=e.IMouseService=e.ICoreBrowserService=e.ICharSizeService=void 0;var i=n(14);e.ICharSizeService=i.createDecorator("CharSizeService"),e.ICoreBrowserService=i.createDecorator("CoreBrowserService"),e.IMouseService=i.createDecorator("MouseService"),e.IRenderService=i.createDecorator("RenderService"),e.ISelectionService=i.createDecorator("SelectionService"),e.ISoundService=i.createDecorator("SoundService")},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtendedAttrs=e.AttributeData=void 0;var i=function(){function t(){this.fg=0,this.bg=0,this.extended=new r}return t.toColorRGB=function(t){return[t>>>16&255,t>>>8&255,255&t]},t.fromColorRGB=function(t){return(255&t[0])<<16|(255&t[1])<<8|255&t[2]},t.prototype.clone=function(){var e=new t;return e.fg=this.fg,e.bg=this.bg,e.extended=this.extended.clone(),e},t.prototype.isInverse=function(){return 67108864&this.fg},t.prototype.isBold=function(){return 134217728&this.fg},t.prototype.isUnderline=function(){return 268435456&this.fg},t.prototype.isBlink=function(){return 536870912&this.fg},t.prototype.isInvisible=function(){return 1073741824&this.fg},t.prototype.isItalic=function(){return 67108864&this.bg},t.prototype.isDim=function(){return 134217728&this.bg},t.prototype.getFgColorMode=function(){return 50331648&this.fg},t.prototype.getBgColorMode=function(){return 50331648&this.bg},t.prototype.isFgRGB=function(){return 50331648==(50331648&this.fg)},t.prototype.isBgRGB=function(){return 50331648==(50331648&this.bg)},t.prototype.isFgPalette=function(){return 16777216==(50331648&this.fg)||33554432==(50331648&this.fg)},t.prototype.isBgPalette=function(){return 16777216==(50331648&this.bg)||33554432==(50331648&this.bg)},t.prototype.isFgDefault=function(){return 0==(50331648&this.fg)},t.prototype.isBgDefault=function(){return 0==(50331648&this.bg)},t.prototype.isAttributeDefault=function(){return 0===this.fg&&0===this.bg},t.prototype.getFgColor=function(){switch(50331648&this.fg){case 16777216:case 33554432:return 255&this.fg;case 50331648:return 16777215&this.fg;default:return-1}},t.prototype.getBgColor=function(){switch(50331648&this.bg){case 16777216:case 33554432:return 255&this.bg;case 50331648:return 16777215&this.bg;default:return-1}},t.prototype.hasExtendedAttrs=function(){return 268435456&this.bg},t.prototype.updateExtended=function(){this.extended.isEmpty()?this.bg&=-268435457:this.bg|=268435456},t.prototype.getUnderlineColor=function(){if(268435456&this.bg&&~this.extended.underlineColor)switch(50331648&this.extended.underlineColor){case 16777216:case 33554432:return 255&this.extended.underlineColor;case 50331648:return 16777215&this.extended.underlineColor;default:return this.getFgColor()}return this.getFgColor()},t.prototype.getUnderlineColorMode=function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648&this.extended.underlineColor:this.getFgColorMode()},t.prototype.isUnderlineColorRGB=function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648==(50331648&this.extended.underlineColor):this.isFgRGB()},t.prototype.isUnderlineColorPalette=function(){return 268435456&this.bg&&~this.extended.underlineColor?16777216==(50331648&this.extended.underlineColor)||33554432==(50331648&this.extended.underlineColor):this.isFgPalette()},t.prototype.isUnderlineColorDefault=function(){return 268435456&this.bg&&~this.extended.underlineColor?0==(50331648&this.extended.underlineColor):this.isFgDefault()},t.prototype.getUnderlineStyle=function(){return 268435456&this.fg?268435456&this.bg?this.extended.underlineStyle:1:0},t}();e.AttributeData=i;var r=function(){function t(t,e){void 0===t&&(t=0),void 0===e&&(e=-1),this.underlineStyle=t,this.underlineColor=e}return t.prototype.clone=function(){return new t(this.underlineStyle,this.underlineColor)},t.prototype.isEmpty=function(){return 0===this.underlineStyle},t}();e.ExtendedAttrs=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.addDisposableDomListener=void 0,e.addDisposableDomListener=function(t,e,n,i){t.addEventListener(e,n,i);var r=!1;return{dispose:function(){r||(r=!0,t.removeEventListener(e,n,i))}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Utf8ToUtf32=e.StringToUtf32=e.utf32ToString=e.stringFromCodePoint=void 0,e.stringFromCodePoint=function(t){return t>65535?(t-=65536,String.fromCharCode(55296+(t>>10))+String.fromCharCode(t%1024+56320)):String.fromCharCode(t)},e.utf32ToString=function(t,e,n){void 0===e&&(e=0),void 0===n&&(n=t.length);for(var i="",r=e;r<n;++r){var o=t[r];o>65535?(o-=65536,i+=String.fromCharCode(55296+(o>>10))+String.fromCharCode(o%1024+56320)):i+=String.fromCharCode(o)}return i};var i=function(){function t(){this._interim=0}return t.prototype.clear=function(){this._interim=0},t.prototype.decode=function(t,e){var n=t.length;if(!n)return 0;var i=0,r=0;this._interim&&(56320<=(s=t.charCodeAt(r++))&&s<=57343?e[i++]=1024*(this._interim-55296)+s-56320+65536:(e[i++]=this._interim,e[i++]=s),this._interim=0);for(var o=r;o<n;++o){var a=t.charCodeAt(o);if(55296<=a&&a<=56319){if(++o>=n)return this._interim=a,i;var s;56320<=(s=t.charCodeAt(o))&&s<=57343?e[i++]=1024*(a-55296)+s-56320+65536:(e[i++]=a,e[i++]=s)}else e[i++]=a}return i},t}();e.StringToUtf32=i;var r=function(){function t(){this.interim=new Uint8Array(3)}return t.prototype.clear=function(){this.interim.fill(0)},t.prototype.decode=function(t,e){var n=t.length;if(!n)return 0;var i,r,o,a,s=0,c=0,l=0;if(this.interim[0]){var u=!1,h=this.interim[0];h&=192==(224&h)?31:224==(240&h)?15:7;for(var d=0,f=void 0;(f=63&this.interim[++d])&&d<4;)h<<=6,h|=f;for(var p=192==(224&this.interim[0])?2:224==(240&this.interim[0])?3:4,m=p-d;l<m;){if(l>=n)return 0;if(128!=(192&(f=t[l++]))){l--,u=!0;break}this.interim[d++]=f,h<<=6,h|=63&f}u||(2===p?h<128?l--:e[s++]=h:3===p?h<2048||h>=55296&&h<=57343||(e[s++]=h):h<65536||h>1114111||(e[s++]=h)),this.interim.fill(0)}for(var g=n-4,v=l;v<n;){for(;!(!(v<g)||128&(i=t[v])||128&(r=t[v+1])||128&(o=t[v+2])||128&(a=t[v+3]));)e[s++]=i,e[s++]=r,e[s++]=o,e[s++]=a,v+=4;if((i=t[v++])<128)e[s++]=i;else if(192==(224&i)){if(v>=n)return this.interim[0]=i,s;if(128!=(192&(r=t[v++]))){v--;continue}if((c=(31&i)<<6|63&r)<128){v--;continue}e[s++]=c}else if(224==(240&i)){if(v>=n)return this.interim[0]=i,s;if(128!=(192&(r=t[v++]))){v--;continue}if(v>=n)return this.interim[0]=i,this.interim[1]=r,s;if(128!=(192&(o=t[v++]))){v--;continue}if((c=(15&i)<<12|(63&r)<<6|63&o)<2048||c>=55296&&c<=57343)continue;e[s++]=c}else if(240==(248&i)){if(v>=n)return this.interim[0]=i,s;if(128!=(192&(r=t[v++]))){v--;continue}if(v>=n)return this.interim[0]=i,this.interim[1]=r,s;if(128!=(192&(o=t[v++]))){v--;continue}if(v>=n)return this.interim[0]=i,this.interim[1]=r,this.interim[2]=o,s;if(128!=(192&(a=t[v++]))){v--;continue}if((c=(7&i)<<18|(63&r)<<12|(63&o)<<6|63&a)<65536||c>1114111)continue;e[s++]=c}}return s},t}();e.Utf8ToUtf32=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CHAR_ATLAS_CELL_SPACING=e.DIM_OPACITY=e.INVERTED_DEFAULT_COLOR=void 0,e.INVERTED_DEFAULT_COLOR=257,e.DIM_OPACITY=.5,e.CHAR_ATLAS_CELL_SPACING=1},function(t,e,n){"use strict";var i,r,o,a;function s(t){var e=t.toString(16);return e.length<2?"0"+e:e}function c(t,e){return t<e?(e+.05)/(t+.05):(t+.05)/(e+.05)}Object.defineProperty(e,"__esModule",{value:!0}),e.contrastRatio=e.toPaddedHex=e.rgba=e.rgb=e.css=e.color=e.channels=void 0,function(t){t.toCss=function(t,e,n,i){return void 0!==i?"#"+s(t)+s(e)+s(n)+s(i):"#"+s(t)+s(e)+s(n)},t.toRgba=function(t,e,n,i){return void 0===i&&(i=255),(t<<24|e<<16|n<<8|i)>>>0}}(i=e.channels||(e.channels={})),(r=e.color||(e.color={})).blend=function(t,e){var n=(255&e.rgba)/255;if(1===n)return{css:e.css,rgba:e.rgba};var r=e.rgba>>16&255,o=e.rgba>>8&255,a=t.rgba>>24&255,s=t.rgba>>16&255,c=t.rgba>>8&255,l=a+Math.round(((e.rgba>>24&255)-a)*n),u=s+Math.round((r-s)*n),h=c+Math.round((o-c)*n);return{css:i.toCss(l,u,h),rgba:i.toRgba(l,u,h)}},r.isOpaque=function(t){return 255==(255&t.rgba)},r.ensureContrastRatio=function(t,e,n){var i=a.ensureContrastRatio(t.rgba,e.rgba,n);if(i)return a.toColor(i>>24&255,i>>16&255,i>>8&255)},r.opaque=function(t){var e=(255|t.rgba)>>>0,n=a.toChannels(e);return{css:i.toCss(n[0],n[1],n[2]),rgba:e}},r.opacity=function(t,e){var n=Math.round(255*e),r=a.toChannels(t.rgba),o=r[0],s=r[1],c=r[2];return{css:i.toCss(o,s,c,n),rgba:i.toRgba(o,s,c,n)}},(e.css||(e.css={})).toColor=function(t){switch(t.length){case 7:return{css:t,rgba:(parseInt(t.slice(1),16)<<8|255)>>>0};case 9:return{css:t,rgba:parseInt(t.slice(1),16)>>>0}}throw new Error("css.toColor: Unsupported css format")},function(t){function e(t,e,n){var i=t/255,r=e/255,o=n/255;return.2126*(i<=.03928?i/12.92:Math.pow((i+.055)/1.055,2.4))+.7152*(r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4))+.0722*(o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4))}t.relativeLuminance=function(t){return e(t>>16&255,t>>8&255,255&t)},t.relativeLuminance2=e}(o=e.rgb||(e.rgb={})),function(t){function e(t,e,n){for(var i=t>>24&255,r=t>>16&255,a=t>>8&255,s=e>>24&255,l=e>>16&255,u=e>>8&255,h=c(o.relativeLuminance2(s,u,l),o.relativeLuminance2(i,r,a));h<n&&(s>0||l>0||u>0);)s-=Math.max(0,Math.ceil(.1*s)),l-=Math.max(0,Math.ceil(.1*l)),u-=Math.max(0,Math.ceil(.1*u)),h=c(o.relativeLuminance2(s,u,l),o.relativeLuminance2(i,r,a));return(s<<24|l<<16|u<<8|255)>>>0}function n(t,e,n){for(var i=t>>24&255,r=t>>16&255,a=t>>8&255,s=e>>24&255,l=e>>16&255,u=e>>8&255,h=c(o.relativeLuminance2(s,u,l),o.relativeLuminance2(i,r,a));h<n&&(s<255||l<255||u<255);)s=Math.min(255,s+Math.ceil(.1*(255-s))),l=Math.min(255,l+Math.ceil(.1*(255-l))),u=Math.min(255,u+Math.ceil(.1*(255-u))),h=c(o.relativeLuminance2(s,u,l),o.relativeLuminance2(i,r,a));return(s<<24|l<<16|u<<8|255)>>>0}t.ensureContrastRatio=function(t,i,r){var a=o.relativeLuminance(t>>8),s=o.relativeLuminance(i>>8);if(c(a,s)<r)return s<a?e(t,i,r):n(t,i,r)},t.reduceLuminance=e,t.increaseLuminance=n,t.toChannels=function(t){return[t>>24&255,t>>16&255,t>>8&255,255&t]},t.toColor=function(t,e,n){return{css:i.toCss(t,e,n),rgba:i.toRgba(t,e,n)}}}(a=e.rgba||(e.rgba={})),e.toPaddedHex=s,e.contrastRatio=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isLinux=e.isWindows=e.isIphone=e.isIpad=e.isMac=e.isSafari=e.isFirefox=void 0;var i="undefined"==typeof navigator,r=i?"node":navigator.userAgent,o=i?"node":navigator.platform;function a(t,e){return t.indexOf(e)>=0}e.isFirefox=!!~r.indexOf("Firefox"),e.isSafari=/^((?!chrome|android).)*safari/i.test(r),e.isMac=a(["Macintosh","MacIntel","MacPPC","Mac68K"],o),e.isIpad="iPad"===o,e.isIphone="iPhone"===o,e.isWindows=a(["Windows","Win16","Win32","WinCE"],o),e.isLinux=o.indexOf("Linux")>=0},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.C1=e.C0=void 0,function(t){t.NUL="\0",t.SOH="\x01",t.STX="\x02",t.ETX="\x03",t.EOT="\x04",t.ENQ="\x05",t.ACK="\x06",t.BEL="\x07",t.BS="\b",t.HT="\t",t.LF="\n",t.VT="\v",t.FF="\f",t.CR="\r",t.SO="\x0e",t.SI="\x0f",t.DLE="\x10",t.DC1="\x11",t.DC2="\x12",t.DC3="\x13",t.DC4="\x14",t.NAK="\x15",t.SYN="\x16",t.ETB="\x17",t.CAN="\x18",t.EM="\x19",t.SUB="\x1a",t.ESC="\x1b",t.FS="\x1c",t.GS="\x1d",t.RS="\x1e",t.US="\x1f",t.SP=" ",t.DEL="\x7f"}(e.C0||(e.C0={})),function(t){t.PAD="\x80",t.HOP="\x81",t.BPH="\x82",t.NBH="\x83",t.IND="\x84",t.NEL="\x85",t.SSA="\x86",t.ESA="\x87",t.HTS="\x88",t.HTJ="\x89",t.VTS="\x8a",t.PLD="\x8b",t.PLU="\x8c",t.RI="\x8d",t.SS2="\x8e",t.SS3="\x8f",t.DCS="\x90",t.PU1="\x91",t.PU2="\x92",t.STS="\x93",t.CCH="\x94",t.MW="\x95",t.SPA="\x96",t.EPA="\x97",t.SOS="\x98",t.SGCI="\x99",t.SCI="\x9a",t.CSI="\x9b",t.ST="\x9c",t.OSC="\x9d",t.PM="\x9e",t.APC="\x9f"}(e.C1||(e.C1={}))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BaseRenderLayer=void 0;var i=n(3),r=n(9),o=n(25),a=n(6),s=n(28),c=n(10),l=n(17),u=function(){function t(t,e,n,i,r,o,a,s){this._container=t,this._alpha=i,this._colors=r,this._rendererId=o,this._bufferService=a,this._optionsService=s,this._scaledCharWidth=0,this._scaledCharHeight=0,this._scaledCellWidth=0,this._scaledCellHeight=0,this._scaledCharLeft=0,this._scaledCharTop=0,this._currentGlyphIdentifier={chars:"",code:0,bg:0,fg:0,bold:!1,dim:!1,italic:!1},this._canvas=document.createElement("canvas"),this._canvas.classList.add("xterm-"+e+"-layer"),this._canvas.style.zIndex=n.toString(),this._initCanvas(),this._container.appendChild(this._canvas)}return t.prototype.dispose=function(){var t;l.removeElementFromParent(this._canvas),null===(t=this._charAtlas)||void 0===t||t.dispose()},t.prototype._initCanvas=function(){this._ctx=s.throwIfFalsy(this._canvas.getContext("2d",{alpha:this._alpha})),this._alpha||this._clearAll()},t.prototype.onOptionsChanged=function(){},t.prototype.onBlur=function(){},t.prototype.onFocus=function(){},t.prototype.onCursorMove=function(){},t.prototype.onGridChanged=function(t,e){},t.prototype.onSelectionChanged=function(t,e,n){void 0===n&&(n=!1)},t.prototype.setColors=function(t){this._refreshCharAtlas(t)},t.prototype._setTransparency=function(t){if(t!==this._alpha){var e=this._canvas;this._alpha=t,this._canvas=this._canvas.cloneNode(),this._initCanvas(),this._container.replaceChild(this._canvas,e),this._refreshCharAtlas(this._colors),this.onGridChanged(0,this._bufferService.rows-1)}},t.prototype._refreshCharAtlas=function(t){this._scaledCharWidth<=0&&this._scaledCharHeight<=0||(this._charAtlas=o.acquireCharAtlas(this._optionsService.options,this._rendererId,t,this._scaledCharWidth,this._scaledCharHeight),this._charAtlas.warmUp())},t.prototype.resize=function(t){this._scaledCellWidth=t.scaledCellWidth,this._scaledCellHeight=t.scaledCellHeight,this._scaledCharWidth=t.scaledCharWidth,this._scaledCharHeight=t.scaledCharHeight,this._scaledCharLeft=t.scaledCharLeft,this._scaledCharTop=t.scaledCharTop,this._canvas.width=t.scaledCanvasWidth,this._canvas.height=t.scaledCanvasHeight,this._canvas.style.width=t.canvasWidth+"px",this._canvas.style.height=t.canvasHeight+"px",this._alpha||this._clearAll(),this._refreshCharAtlas(this._colors)},t.prototype._fillCells=function(t,e,n,i){this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,i*this._scaledCellHeight)},t.prototype._fillBottomLineAtCells=function(t,e,n){void 0===n&&(n=1),this._ctx.fillRect(t*this._scaledCellWidth,(e+1)*this._scaledCellHeight-window.devicePixelRatio-1,n*this._scaledCellWidth,window.devicePixelRatio)},t.prototype._fillLeftLineAtCell=function(t,e,n){this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,window.devicePixelRatio*n,this._scaledCellHeight)},t.prototype._strokeRectAtCell=function(t,e,n,i){this._ctx.lineWidth=window.devicePixelRatio,this._ctx.strokeRect(t*this._scaledCellWidth+window.devicePixelRatio/2,e*this._scaledCellHeight+window.devicePixelRatio/2,n*this._scaledCellWidth-window.devicePixelRatio,i*this._scaledCellHeight-window.devicePixelRatio)},t.prototype._clearAll=function(){this._alpha?this._ctx.clearRect(0,0,this._canvas.width,this._canvas.height):(this._ctx.fillStyle=this._colors.background.css,this._ctx.fillRect(0,0,this._canvas.width,this._canvas.height))},t.prototype._clearCells=function(t,e,n,i){this._alpha?this._ctx.clearRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,i*this._scaledCellHeight):(this._ctx.fillStyle=this._colors.background.css,this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,i*this._scaledCellHeight))},t.prototype._fillCharTrueColor=function(t,e,n){this._ctx.font=this._getFont(!1,!1),this._ctx.textBaseline="middle",this._clipRow(n),this._ctx.fillText(t.getChars(),e*this._scaledCellWidth+this._scaledCharLeft,n*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2)},t.prototype._drawChars=function(t,e,n){var o,a,s=this._getContrastColor(t);s||t.isFgRGB()||t.isBgRGB()?this._drawUncachedChars(t,e,n,s):(t.isInverse()?(o=t.isBgDefault()?r.INVERTED_DEFAULT_COLOR:t.getBgColor(),a=t.isFgDefault()?r.INVERTED_DEFAULT_COLOR:t.getFgColor()):(a=t.isBgDefault()?i.DEFAULT_COLOR:t.getBgColor(),o=t.isFgDefault()?i.DEFAULT_COLOR:t.getFgColor()),o+=this._optionsService.options.drawBoldTextInBrightColors&&t.isBold()&&o<8?8:0,this._currentGlyphIdentifier.chars=t.getChars()||i.WHITESPACE_CELL_CHAR,this._currentGlyphIdentifier.code=t.getCode()||i.WHITESPACE_CELL_CODE,this._currentGlyphIdentifier.bg=a,this._currentGlyphIdentifier.fg=o,this._currentGlyphIdentifier.bold=!!t.isBold(),this._currentGlyphIdentifier.dim=!!t.isDim(),this._currentGlyphIdentifier.italic=!!t.isItalic(),this._charAtlas&&this._charAtlas.draw(this._ctx,this._currentGlyphIdentifier,e*this._scaledCellWidth+this._scaledCharLeft,n*this._scaledCellHeight+this._scaledCharTop)||this._drawUncachedChars(t,e,n))},t.prototype._drawUncachedChars=function(t,e,n,i){if(this._ctx.save(),this._ctx.font=this._getFont(!!t.isBold(),!!t.isItalic()),this._ctx.textBaseline="middle",t.isInverse())if(i)this._ctx.fillStyle=i.css;else if(t.isBgDefault())this._ctx.fillStyle=c.color.opaque(this._colors.background).css;else if(t.isBgRGB())this._ctx.fillStyle="rgb("+a.AttributeData.toColorRGB(t.getBgColor()).join(",")+")";else{var o=t.getBgColor();this._optionsService.options.drawBoldTextInBrightColors&&t.isBold()&&o<8&&(o+=8),this._ctx.fillStyle=this._colors.ansi[o].css}else if(i)this._ctx.fillStyle=i.css;else if(t.isFgDefault())this._ctx.fillStyle=this._colors.foreground.css;else if(t.isFgRGB())this._ctx.fillStyle="rgb("+a.AttributeData.toColorRGB(t.getFgColor()).join(",")+")";else{var s=t.getFgColor();this._optionsService.options.drawBoldTextInBrightColors&&t.isBold()&&s<8&&(s+=8),this._ctx.fillStyle=this._colors.ansi[s].css}this._clipRow(n),t.isDim()&&(this._ctx.globalAlpha=r.DIM_OPACITY),this._ctx.fillText(t.getChars(),e*this._scaledCellWidth+this._scaledCharLeft,n*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2),this._ctx.restore()},t.prototype._clipRow=function(t){this._ctx.beginPath(),this._ctx.rect(0,t*this._scaledCellHeight,this._bufferService.cols*this._scaledCellWidth,this._scaledCellHeight),this._ctx.clip()},t.prototype._getFont=function(t,e){return(e?"italic":"")+" "+(t?this._optionsService.options.fontWeightBold:this._optionsService.options.fontWeight)+" "+this._optionsService.options.fontSize*window.devicePixelRatio+"px "+this._optionsService.options.fontFamily},t.prototype._getContrastColor=function(t){if(1!==this._optionsService.options.minimumContrastRatio){var e=this._colors.contrastCache.getColor(t.bg,t.fg);if(void 0!==e)return e||void 0;var n=t.getFgColor(),i=t.getFgColorMode(),r=t.getBgColor(),o=t.getBgColorMode(),a=!!t.isInverse(),s=!!t.isInverse();if(a){var l=n;n=r,r=l;var u=i;i=o,o=u}var h=this._resolveBackgroundRgba(o,r,a),d=this._resolveForegroundRgba(i,n,a,s),f=c.rgba.ensureContrastRatio(h,d,this._optionsService.options.minimumContrastRatio);if(f){var p={css:c.channels.toCss(f>>24&255,f>>16&255,f>>8&255),rgba:f};return this._colors.contrastCache.setColor(t.bg,t.fg,p),p}this._colors.contrastCache.setColor(t.bg,t.fg,null)}},t.prototype._resolveBackgroundRgba=function(t,e,n){switch(t){case 16777216:case 33554432:return this._colors.ansi[e].rgba;case 50331648:return e<<8;case 0:default:return n?this._colors.foreground.rgba:this._colors.background.rgba}},t.prototype._resolveForegroundRgba=function(t,e,n,i){switch(t){case 16777216:case 33554432:return this._optionsService.options.drawBoldTextInBrightColors&&i&&e<8&&(e+=8),this._colors.ansi[e].rgba;case 50331648:return e<<8;case 0:default:return n?this._colors.background.rgba:this._colors.foreground.rgba}},t}();e.BaseRenderLayer=u},function(t,e,n){"use strict";function i(t,e,n){e.di$target===e?e.di$dependencies.push({id:t,index:n}):(e.di$dependencies=[{id:t,index:n}],e.di$target=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.createDecorator=e.getServiceDependencies=e.serviceRegistry=void 0,e.serviceRegistry=new Map,e.getServiceDependencies=function(t){return t.di$dependencies||[]},e.createDecorator=function(t){if(e.serviceRegistry.has(t))return e.serviceRegistry.get(t);var n=function t(e,n,r){if(3!==arguments.length)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");i(t,e,r)};return n.toString=function(){return t},e.serviceRegistry.set(t,n),n}},function(t,e,n){"use strict";function i(t,e,n,i){if(void 0===n&&(n=0),void 0===i&&(i=t.length),n>=t.length)return t;i=i>=t.length?t.length:(t.length+i)%t.length;for(var r=n=(t.length+n)%t.length;r<i;++r)t[r]=e;return t}Object.defineProperty(e,"__esModule",{value:!0}),e.concat=e.fillFallback=e.fill=void 0,e.fill=function(t,e,n,r){return t.fill?t.fill(e,n,r):i(t,e,n,r)},e.fillFallback=i,e.concat=function(t,e){var n=new t.constructor(t.length+e.length);return n.set(t),n.set(e,t.length),n}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BufferLine=e.DEFAULT_ATTR_DATA=void 0;var i=n(8),r=n(3),o=n(4),a=n(6);e.DEFAULT_ATTR_DATA=Object.freeze(new a.AttributeData);var s=function(){function t(t,e,n){void 0===n&&(n=!1),this.isWrapped=n,this._combined={},this._extendedAttrs={},this._data=new Uint32Array(3*t);for(var i=e||o.CellData.fromCharData([0,r.NULL_CELL_CHAR,r.NULL_CELL_WIDTH,r.NULL_CELL_CODE]),a=0;a<t;++a)this.setCell(a,i);this.length=t}return t.prototype.get=function(t){var e=this._data[3*t+0],n=2097151&e;return[this._data[3*t+1],2097152&e?this._combined[t]:n?i.stringFromCodePoint(n):"",e>>22,2097152&e?this._combined[t].charCodeAt(this._combined[t].length-1):n]},t.prototype.set=function(t,e){this._data[3*t+1]=e[r.CHAR_DATA_ATTR_INDEX],e[r.CHAR_DATA_CHAR_INDEX].length>1?(this._combined[t]=e[1],this._data[3*t+0]=2097152|t|e[r.CHAR_DATA_WIDTH_INDEX]<<22):this._data[3*t+0]=e[r.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|e[r.CHAR_DATA_WIDTH_INDEX]<<22},t.prototype.getWidth=function(t){return this._data[3*t+0]>>22},t.prototype.hasWidth=function(t){return 12582912&this._data[3*t+0]},t.prototype.getFg=function(t){return this._data[3*t+1]},t.prototype.getBg=function(t){return this._data[3*t+2]},t.prototype.hasContent=function(t){return 4194303&this._data[3*t+0]},t.prototype.getCodePoint=function(t){var e=this._data[3*t+0];return 2097152&e?this._combined[t].charCodeAt(this._combined[t].length-1):2097151&e},t.prototype.isCombined=function(t){return 2097152&this._data[3*t+0]},t.prototype.getString=function(t){var e=this._data[3*t+0];return 2097152&e?this._combined[t]:2097151&e?i.stringFromCodePoint(2097151&e):""},t.prototype.loadCell=function(t,e){var n=3*t;return e.content=this._data[n+0],e.fg=this._data[n+1],e.bg=this._data[n+2],2097152&e.content&&(e.combinedData=this._combined[t]),268435456&e.bg&&(e.extended=this._extendedAttrs[t]),e},t.prototype.setCell=function(t,e){2097152&e.content&&(this._combined[t]=e.combinedData),268435456&e.bg&&(this._extendedAttrs[t]=e.extended),this._data[3*t+0]=e.content,this._data[3*t+1]=e.fg,this._data[3*t+2]=e.bg},t.prototype.setCellFromCodePoint=function(t,e,n,i,r,o){268435456&r&&(this._extendedAttrs[t]=o),this._data[3*t+0]=e|n<<22,this._data[3*t+1]=i,this._data[3*t+2]=r},t.prototype.addCodepointToCell=function(t,e){var n=this._data[3*t+0];2097152&n?this._combined[t]+=i.stringFromCodePoint(e):(2097151&n?(this._combined[t]=i.stringFromCodePoint(2097151&n)+i.stringFromCodePoint(e),n&=-2097152,n|=2097152):n=e|1<<22,this._data[3*t+0]=n)},t.prototype.insertCells=function(t,e,n,i){if((t%=this.length)&&2===this.getWidth(t-1)&&this.setCellFromCodePoint(t-1,0,1,(null==i?void 0:i.fg)||0,(null==i?void 0:i.bg)||0,(null==i?void 0:i.extended)||new a.ExtendedAttrs),e<this.length-t){for(var r=new o.CellData,s=this.length-t-e-1;s>=0;--s)this.setCell(t+e+s,this.loadCell(t+s,r));for(s=0;s<e;++s)this.setCell(t+s,n)}else for(s=t;s<this.length;++s)this.setCell(s,n);2===this.getWidth(this.length-1)&&this.setCellFromCodePoint(this.length-1,0,1,(null==i?void 0:i.fg)||0,(null==i?void 0:i.bg)||0,(null==i?void 0:i.extended)||new a.ExtendedAttrs)},t.prototype.deleteCells=function(t,e,n,i){if(e<this.length-(t%=this.length)){for(var r=new o.CellData,s=0;s<this.length-t-e;++s)this.setCell(t+s,this.loadCell(t+e+s,r));for(s=this.length-e;s<this.length;++s)this.setCell(s,n)}else for(s=t;s<this.length;++s)this.setCell(s,n);t&&2===this.getWidth(t-1)&&this.setCellFromCodePoint(t-1,0,1,(null==i?void 0:i.fg)||0,(null==i?void 0:i.bg)||0,(null==i?void 0:i.extended)||new a.ExtendedAttrs),0!==this.getWidth(t)||this.hasContent(t)||this.setCellFromCodePoint(t,0,1,(null==i?void 0:i.fg)||0,(null==i?void 0:i.bg)||0,(null==i?void 0:i.extended)||new a.ExtendedAttrs)},t.prototype.replaceCells=function(t,e,n,i){for(t&&2===this.getWidth(t-1)&&this.setCellFromCodePoint(t-1,0,1,(null==i?void 0:i.fg)||0,(null==i?void 0:i.bg)||0,(null==i?void 0:i.extended)||new a.ExtendedAttrs),e<this.length&&2===this.getWidth(e-1)&&this.setCellFromCodePoint(e,0,1,(null==i?void 0:i.fg)||0,(null==i?void 0:i.bg)||0,(null==i?void 0:i.extended)||new a.ExtendedAttrs);t<e&&t<this.length;)this.setCell(t++,n)},t.prototype.resize=function(t,e){if(t!==this.length){if(t>this.length){var n=new Uint32Array(3*t);this.length&&n.set(3*t<this._data.length?this._data.subarray(0,3*t):this._data),this._data=n;for(var i=this.length;i<t;++i)this.setCell(i,e)}else if(t){(n=new Uint32Array(3*t)).set(this._data.subarray(0,3*t)),this._data=n;var r=Object.keys(this._combined);for(i=0;i<r.length;i++){var o=parseInt(r[i],10);o>=t&&delete this._combined[o]}}else this._data=new Uint32Array(0),this._combined={};this.length=t}},t.prototype.fill=function(t){this._combined={},this._extendedAttrs={};for(var e=0;e<this.length;++e)this.setCell(e,t)},t.prototype.copyFrom=function(t){for(var e in this.length!==t.length?this._data=new Uint32Array(t._data):this._data.set(t._data),this.length=t.length,this._combined={},t._combined)this._combined[e]=t._combined[e];for(var e in this._extendedAttrs={},t._extendedAttrs)this._extendedAttrs[e]=t._extendedAttrs[e];this.isWrapped=t.isWrapped},t.prototype.clone=function(){var e=new t(0);for(var n in e._data=new Uint32Array(this._data),e.length=this.length,this._combined)e._combined[n]=this._combined[n];for(var n in this._extendedAttrs)e._extendedAttrs[n]=this._extendedAttrs[n];return e.isWrapped=this.isWrapped,e},t.prototype.getTrimmedLength=function(){for(var t=this.length-1;t>=0;--t)if(4194303&this._data[3*t+0])return t+(this._data[3*t+0]>>22);return 0},t.prototype.copyCellsFrom=function(t,e,n,i,r){var o=t._data;if(r)for(var a=i-1;a>=0;a--)for(var s=0;s<3;s++)this._data[3*(n+a)+s]=o[3*(e+a)+s];else for(a=0;a<i;a++)for(s=0;s<3;s++)this._data[3*(n+a)+s]=o[3*(e+a)+s];var c=Object.keys(t._combined);for(s=0;s<c.length;s++){var l=parseInt(c[s],10);l>=e&&(this._combined[l-e+n]=t._combined[l])}},t.prototype.translateToString=function(t,e,n){void 0===t&&(t=!1),void 0===e&&(e=0),void 0===n&&(n=this.length),t&&(n=Math.min(n,this.getTrimmedLength()));for(var o="";e<n;){var a=this._data[3*e+0],s=2097151&a;o+=2097152&a?this._combined[e]:s?i.stringFromCodePoint(s):r.WHITESPACE_CELL_CHAR,e+=a>>22||1}return o},t}();e.BufferLine=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.removeElementFromParent=void 0,e.removeElementFromParent=function(){for(var t,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];for(var i=0,r=e;i<r.length;i++){var o=r[i];null===(t=null==o?void 0:o.parentElement)||void 0===t||t.removeChild(o)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.tooMuchOutput=e.promptLabel=void 0,e.promptLabel="Terminal input",e.tooMuchOutput="Too much output to announce, navigate to rows manually to read"},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.InputHandler=e.WindowsOptionsReportType=void 0;var o,a=n(12),s=n(20),c=n(39),l=n(2),u=n(15),h=n(8),d=n(16),f=n(0),p=n(3),m=n(4),g=n(6),v=n(22),b=n(24),y={"(":0,")":1,"*":2,"+":3,"-":1,".":2};function _(t,e){if(t>24)return e.setWinLines||!1;switch(t){case 1:return!!e.restoreWin;case 2:return!!e.minimizeWin;case 3:return!!e.setWinPosition;case 4:return!!e.setWinSizePixels;case 5:return!!e.raiseWin;case 6:return!!e.lowerWin;case 7:return!!e.refreshWin;case 8:return!!e.setWinSizeChars;case 9:return!!e.maximizeWin;case 10:return!!e.fullscreenWin;case 11:return!!e.getWinState;case 13:return!!e.getWinPosition;case 14:return!!e.getWinSizePixels;case 15:return!!e.getScreenSizePixels;case 16:return!!e.getCellSizePixels;case 18:return!!e.getWinSizeChars;case 19:return!!e.getScreenSizeChars;case 20:return!!e.getIconTitle;case 21:return!!e.getWinTitle;case 22:return!!e.pushTitle;case 23:return!!e.popTitle;case 24:return!!e.setWinLines}return!1}!function(t){t[t.GET_WIN_SIZE_PIXELS=0]="GET_WIN_SIZE_PIXELS",t[t.GET_CELL_SIZE_PIXELS=1]="GET_CELL_SIZE_PIXELS"}(o=e.WindowsOptionsReportType||(e.WindowsOptionsReportType={}));var w=function(){function t(t,e,n,i){this._bufferService=t,this._coreService=e,this._logService=n,this._optionsService=i,this._data=new Uint32Array(0)}return t.prototype.hook=function(t){this._data=new Uint32Array(0)},t.prototype.put=function(t,e,n){this._data=u.concat(this._data,t.subarray(e,n))},t.prototype.unhook=function(t){if(t){var e=h.utf32ToString(this._data);switch(this._data=new Uint32Array(0),e){case'"q':return this._coreService.triggerDataEvent(a.C0.ESC+'P1$r0"q'+a.C0.ESC+"\\");case'"p':return this._coreService.triggerDataEvent(a.C0.ESC+'P1$r61;1"p'+a.C0.ESC+"\\");case"r":return this._coreService.triggerDataEvent(a.C0.ESC+"P1$r"+(this._bufferService.buffer.scrollTop+1)+";"+(this._bufferService.buffer.scrollBottom+1)+"r"+a.C0.ESC+"\\");case"m":return this._coreService.triggerDataEvent(a.C0.ESC+"P1$r0m"+a.C0.ESC+"\\");case" q":var n={block:2,underline:4,bar:6}[this._optionsService.options.cursorStyle];return this._coreService.triggerDataEvent(a.C0.ESC+"P1$r"+(n-=this._optionsService.options.cursorBlink?1:0)+" q"+a.C0.ESC+"\\");default:this._logService.debug("Unknown DCS $q %s",e),this._coreService.triggerDataEvent(a.C0.ESC+"P0$r"+a.C0.ESC+"\\")}}else this._data=new Uint32Array(0)},t}(),k=function(t){function e(e,n,i,r,o,l,u,p,g){void 0===g&&(g=new c.EscapeSequenceParser);var b=t.call(this)||this;b._bufferService=e,b._charsetService=n,b._coreService=i,b._dirtyRowService=r,b._logService=o,b._optionsService=l,b._coreMouseService=u,b._unicodeService=p,b._parser=g,b._parseBuffer=new Uint32Array(4096),b._stringDecoder=new h.StringToUtf32,b._utf8Decoder=new h.Utf8ToUtf32,b._workCell=new m.CellData,b._windowTitle="",b._iconName="",b._windowTitleStack=[],b._iconNameStack=[],b._curAttrData=d.DEFAULT_ATTR_DATA.clone(),b._eraseAttrDataInternal=d.DEFAULT_ATTR_DATA.clone(),b._onRequestBell=new f.EventEmitter,b._onRequestRefreshRows=new f.EventEmitter,b._onRequestReset=new f.EventEmitter,b._onRequestScroll=new f.EventEmitter,b._onRequestSyncScrollBar=new f.EventEmitter,b._onRequestWindowsOptionsReport=new f.EventEmitter,b._onA11yChar=new f.EventEmitter,b._onA11yTab=new f.EventEmitter,b._onCursorMove=new f.EventEmitter,b._onLineFeed=new f.EventEmitter,b._onScroll=new f.EventEmitter,b._onTitleChange=new f.EventEmitter,b.register(b._parser),b._parser.setCsiHandlerFallback((function(t,e){b._logService.debug("Unknown CSI code: ",{identifier:b._parser.identToString(t),params:e.toArray()})})),b._parser.setEscHandlerFallback((function(t){b._logService.debug("Unknown ESC code: ",{identifier:b._parser.identToString(t)})})),b._parser.setExecuteHandlerFallback((function(t){b._logService.debug("Unknown EXECUTE code: ",{code:t})})),b._parser.setOscHandlerFallback((function(t,e,n){b._logService.debug("Unknown OSC code: ",{identifier:t,action:e,data:n})})),b._parser.setDcsHandlerFallback((function(t,e,n){"HOOK"===e&&(n=n.toArray()),b._logService.debug("Unknown DCS code: ",{identifier:b._parser.identToString(t),action:e,payload:n})})),b._parser.setPrintHandler((function(t,e,n){return b.print(t,e,n)})),b._parser.setCsiHandler({final:"@"},(function(t){return b.insertChars(t)})),b._parser.setCsiHandler({intermediates:" ",final:"@"},(function(t){return b.scrollLeft(t)})),b._parser.setCsiHandler({final:"A"},(function(t){return b.cursorUp(t)})),b._parser.setCsiHandler({intermediates:" ",final:"A"},(function(t){return b.scrollRight(t)})),b._parser.setCsiHandler({final:"B"},(function(t){return b.cursorDown(t)})),b._parser.setCsiHandler({final:"C"},(function(t){return b.cursorForward(t)})),b._parser.setCsiHandler({final:"D"},(function(t){return b.cursorBackward(t)})),b._parser.setCsiHandler({final:"E"},(function(t){return b.cursorNextLine(t)})),b._parser.setCsiHandler({final:"F"},(function(t){return b.cursorPrecedingLine(t)})),b._parser.setCsiHandler({final:"G"},(function(t){return b.cursorCharAbsolute(t)})),b._parser.setCsiHandler({final:"H"},(function(t){return b.cursorPosition(t)})),b._parser.setCsiHandler({final:"I"},(function(t){return b.cursorForwardTab(t)})),b._parser.setCsiHandler({final:"J"},(function(t){return b.eraseInDisplay(t)})),b._parser.setCsiHandler({prefix:"?",final:"J"},(function(t){return b.eraseInDisplay(t)})),b._parser.setCsiHandler({final:"K"},(function(t){return b.eraseInLine(t)})),b._parser.setCsiHandler({prefix:"?",final:"K"},(function(t){return b.eraseInLine(t)})),b._parser.setCsiHandler({final:"L"},(function(t){return b.insertLines(t)})),b._parser.setCsiHandler({final:"M"},(function(t){return b.deleteLines(t)})),b._parser.setCsiHandler({final:"P"},(function(t){return b.deleteChars(t)})),b._parser.setCsiHandler({final:"S"},(function(t){return b.scrollUp(t)})),b._parser.setCsiHandler({final:"T"},(function(t){return b.scrollDown(t)})),b._parser.setCsiHandler({final:"X"},(function(t){return b.eraseChars(t)})),b._parser.setCsiHandler({final:"Z"},(function(t){return b.cursorBackwardTab(t)})),b._parser.setCsiHandler({final:"`"},(function(t){return b.charPosAbsolute(t)})),b._parser.setCsiHandler({final:"a"},(function(t){return b.hPositionRelative(t)})),b._parser.setCsiHandler({final:"b"},(function(t){return b.repeatPrecedingCharacter(t)})),b._parser.setCsiHandler({final:"c"},(function(t){return b.sendDeviceAttributesPrimary(t)})),b._parser.setCsiHandler({prefix:">",final:"c"},(function(t){return b.sendDeviceAttributesSecondary(t)})),b._parser.setCsiHandler({final:"d"},(function(t){return b.linePosAbsolute(t)})),b._parser.setCsiHandler({final:"e"},(function(t){return b.vPositionRelative(t)})),b._parser.setCsiHandler({final:"f"},(function(t){return b.hVPosition(t)})),b._parser.setCsiHandler({final:"g"},(function(t){return b.tabClear(t)})),b._parser.setCsiHandler({final:"h"},(function(t){return b.setMode(t)})),b._parser.setCsiHandler({prefix:"?",final:"h"},(function(t){return b.setModePrivate(t)})),b._parser.setCsiHandler({final:"l"},(function(t){return b.resetMode(t)})),b._parser.setCsiHandler({prefix:"?",final:"l"},(function(t){return b.resetModePrivate(t)})),b._parser.setCsiHandler({final:"m"},(function(t){return b.charAttributes(t)})),b._parser.setCsiHandler({final:"n"},(function(t){return b.deviceStatus(t)})),b._parser.setCsiHandler({prefix:"?",final:"n"},(function(t){return b.deviceStatusPrivate(t)})),b._parser.setCsiHandler({intermediates:"!",final:"p"},(function(t){return b.softReset(t)})),b._parser.setCsiHandler({intermediates:" ",final:"q"},(function(t){return b.setCursorStyle(t)})),b._parser.setCsiHandler({final:"r"},(function(t){return b.setScrollRegion(t)})),b._parser.setCsiHandler({final:"s"},(function(t){return b.saveCursor(t)})),b._parser.setCsiHandler({final:"t"},(function(t){return b.windowOptions(t)})),b._parser.setCsiHandler({final:"u"},(function(t){return b.restoreCursor(t)})),b._parser.setCsiHandler({intermediates:"'",final:"}"},(function(t){return b.insertColumns(t)})),b._parser.setCsiHandler({intermediates:"'",final:"~"},(function(t){return b.deleteColumns(t)})),b._parser.setExecuteHandler(a.C0.BEL,(function(){return b.bell()})),b._parser.setExecuteHandler(a.C0.LF,(function(){return b.lineFeed()})),b._parser.setExecuteHandler(a.C0.VT,(function(){return b.lineFeed()})),b._parser.setExecuteHandler(a.C0.FF,(function(){return b.lineFeed()})),b._parser.setExecuteHandler(a.C0.CR,(function(){return b.carriageReturn()})),b._parser.setExecuteHandler(a.C0.BS,(function(){return b.backspace()})),b._parser.setExecuteHandler(a.C0.HT,(function(){return b.tab()})),b._parser.setExecuteHandler(a.C0.SO,(function(){return b.shiftOut()})),b._parser.setExecuteHandler(a.C0.SI,(function(){return b.shiftIn()})),b._parser.setExecuteHandler(a.C1.IND,(function(){return b.index()})),b._parser.setExecuteHandler(a.C1.NEL,(function(){return b.nextLine()})),b._parser.setExecuteHandler(a.C1.HTS,(function(){return b.tabSet()})),b._parser.setOscHandler(0,new v.OscHandler((function(t){b.setTitle(t),b.setIconName(t)}))),b._parser.setOscHandler(1,new v.OscHandler((function(t){return b.setIconName(t)}))),b._parser.setOscHandler(2,new v.OscHandler((function(t){return b.setTitle(t)}))),b._parser.setEscHandler({final:"7"},(function(){return b.saveCursor()})),b._parser.setEscHandler({final:"8"},(function(){return b.restoreCursor()})),b._parser.setEscHandler({final:"D"},(function(){return b.index()})),b._parser.setEscHandler({final:"E"},(function(){return b.nextLine()})),b._parser.setEscHandler({final:"H"},(function(){return b.tabSet()})),b._parser.setEscHandler({final:"M"},(function(){return b.reverseIndex()})),b._parser.setEscHandler({final:"="},(function(){return b.keypadApplicationMode()})),b._parser.setEscHandler({final:">"},(function(){return b.keypadNumericMode()})),b._parser.setEscHandler({final:"c"},(function(){return b.fullReset()})),b._parser.setEscHandler({final:"n"},(function(){return b.setgLevel(2)})),b._parser.setEscHandler({final:"o"},(function(){return b.setgLevel(3)})),b._parser.setEscHandler({final:"|"},(function(){return b.setgLevel(3)})),b._parser.setEscHandler({final:"}"},(function(){return b.setgLevel(2)})),b._parser.setEscHandler({final:"~"},(function(){return b.setgLevel(1)})),b._parser.setEscHandler({intermediates:"%",final:"@"},(function(){return b.selectDefaultCharset()})),b._parser.setEscHandler({intermediates:"%",final:"G"},(function(){return b.selectDefaultCharset()}));var y=function(t){_._parser.setEscHandler({intermediates:"(",final:t},(function(){return b.selectCharset("("+t)})),_._parser.setEscHandler({intermediates:")",final:t},(function(){return b.selectCharset(")"+t)})),_._parser.setEscHandler({intermediates:"*",final:t},(function(){return b.selectCharset("*"+t)})),_._parser.setEscHandler({intermediates:"+",final:t},(function(){return b.selectCharset("+"+t)})),_._parser.setEscHandler({intermediates:"-",final:t},(function(){return b.selectCharset("-"+t)})),_._parser.setEscHandler({intermediates:".",final:t},(function(){return b.selectCharset("."+t)})),_._parser.setEscHandler({intermediates:"/",final:t},(function(){return b.selectCharset("/"+t)}))},_=this;for(var k in s.CHARSETS)y(k);return b._parser.setEscHandler({intermediates:"#",final:"8"},(function(){return b.screenAlignmentPattern()})),b._parser.setErrorHandler((function(t){return b._logService.error("Parsing error: ",t),t})),b._parser.setDcsHandler({intermediates:"$",final:"q"},new w(b._bufferService,b._coreService,b._logService,b._optionsService)),b}return r(e,t),Object.defineProperty(e.prototype,"onRequestBell",{get:function(){return this._onRequestBell.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRequestRefreshRows",{get:function(){return this._onRequestRefreshRows.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRequestReset",{get:function(){return this._onRequestReset.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRequestScroll",{get:function(){return this._onRequestScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRequestSyncScrollBar",{get:function(){return this._onRequestSyncScrollBar.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRequestWindowsOptionsReport",{get:function(){return this._onRequestWindowsOptionsReport.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onA11yChar",{get:function(){return this._onA11yChar.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onA11yTab",{get:function(){return this._onA11yTab.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onCursorMove",{get:function(){return this._onCursorMove.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onLineFeed",{get:function(){return this._onLineFeed.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onScroll",{get:function(){return this._onScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onTitleChange",{get:function(){return this._onTitleChange.event},enumerable:!1,configurable:!0}),e.prototype.dispose=function(){t.prototype.dispose.call(this)},e.prototype.parse=function(t){var e=this._bufferService.buffer,n=e.x,i=e.y;if(this._logService.debug("parsing data",t),this._parseBuffer.length<t.length&&this._parseBuffer.length<131072&&(this._parseBuffer=new Uint32Array(Math.min(t.length,131072))),this._dirtyRowService.clearRange(),t.length>131072)for(var r=0;r<t.length;r+=131072){var o=r+131072<t.length?r+131072:t.length,a="string"==typeof t?this._stringDecoder.decode(t.substring(r,o),this._parseBuffer):this._utf8Decoder.decode(t.subarray(r,o),this._parseBuffer);this._parser.parse(this._parseBuffer,a)}else a="string"==typeof t?this._stringDecoder.decode(t,this._parseBuffer):this._utf8Decoder.decode(t,this._parseBuffer),this._parser.parse(this._parseBuffer,a);(e=this._bufferService.buffer).x===n&&e.y===i||this._onCursorMove.fire(),this._onRequestRefreshRows.fire(this._dirtyRowService.start,this._dirtyRowService.end)},e.prototype.print=function(t,e,n){var i,r,o=this._bufferService.buffer,a=this._charsetService.charset,s=this._optionsService.options.screenReaderMode,c=this._bufferService.cols,l=this._coreService.decPrivateModes.wraparound,u=this._coreService.modes.insertMode,d=this._curAttrData,f=o.lines.get(o.ybase+o.y);this._dirtyRowService.markDirty(o.y),o.x&&n-e>0&&2===f.getWidth(o.x-1)&&f.setCellFromCodePoint(o.x-1,0,1,d.fg,d.bg,d.extended);for(var m=e;m<n;++m){if(r=this._unicodeService.wcwidth(i=t[m]),i<127&&a){var g=a[String.fromCharCode(i)];g&&(i=g.charCodeAt(0))}if(s&&this._onA11yChar.fire(h.stringFromCodePoint(i)),r||!o.x){if(o.x+r-1>=c)if(l){for(;o.x<c;)f.setCellFromCodePoint(o.x++,0,1,d.fg,d.bg,d.extended);o.x=0,o.y++,o.y===o.scrollBottom+1?(o.y--,this._onRequestScroll.fire(this._eraseAttrData(),!0)):(o.y>=this._bufferService.rows&&(o.y=this._bufferService.rows-1),o.lines.get(o.ybase+o.y).isWrapped=!0),f=o.lines.get(o.ybase+o.y)}else if(o.x=c-1,2===r)continue;if(u&&(f.insertCells(o.x,r,o.getNullCell(d),d),2===f.getWidth(c-1)&&f.setCellFromCodePoint(c-1,p.NULL_CELL_CODE,p.NULL_CELL_WIDTH,d.fg,d.bg,d.extended)),f.setCellFromCodePoint(o.x++,i,r,d.fg,d.bg,d.extended),r>0)for(;--r;)f.setCellFromCodePoint(o.x++,0,0,d.fg,d.bg,d.extended)}else f.getWidth(o.x-1)?f.addCodepointToCell(o.x-1,i):f.addCodepointToCell(o.x-2,i)}n-e>0&&(f.loadCell(o.x-1,this._workCell),this._parser.precedingCodepoint=2===this._workCell.getWidth()||this._workCell.getCode()>65535?0:this._workCell.isCombined()?this._workCell.getChars().charCodeAt(0):this._workCell.content),o.x<c&&n-e>0&&0===f.getWidth(o.x)&&!f.hasContent(o.x)&&f.setCellFromCodePoint(o.x,0,1,d.fg,d.bg,d.extended),this._dirtyRowService.markDirty(o.y)},e.prototype.addCsiHandler=function(t,e){var n=this;return this._parser.addCsiHandler(t,"t"!==t.final||t.prefix||t.intermediates?e:function(t){return!_(t.params[0],n._optionsService.options.windowOptions)||e(t)})},e.prototype.addDcsHandler=function(t,e){return this._parser.addDcsHandler(t,new b.DcsHandler(e))},e.prototype.addEscHandler=function(t,e){return this._parser.addEscHandler(t,e)},e.prototype.addOscHandler=function(t,e){return this._parser.addOscHandler(t,new v.OscHandler(e))},e.prototype.bell=function(){this._onRequestBell.fire()},e.prototype.lineFeed=function(){var t=this._bufferService.buffer;this._dirtyRowService.markDirty(t.y),this._optionsService.options.convertEol&&(t.x=0),t.y++,t.y===t.scrollBottom+1?(t.y--,this._onRequestScroll.fire(this._eraseAttrData())):t.y>=this._bufferService.rows&&(t.y=this._bufferService.rows-1),t.x>=this._bufferService.cols&&t.x--,this._dirtyRowService.markDirty(t.y),this._onLineFeed.fire()},e.prototype.carriageReturn=function(){this._bufferService.buffer.x=0},e.prototype.backspace=function(){var t,e=this._bufferService.buffer;if(!this._coreService.decPrivateModes.reverseWraparound)return this._restrictCursor(),void(e.x>0&&e.x--);if(this._restrictCursor(this._bufferService.cols),e.x>0)e.x--;else if(0===e.x&&e.y>e.scrollTop&&e.y<=e.scrollBottom&&(null===(t=e.lines.get(e.ybase+e.y))||void 0===t?void 0:t.isWrapped)){e.lines.get(e.ybase+e.y).isWrapped=!1,e.y--,e.x=this._bufferService.cols-1;var n=e.lines.get(e.ybase+e.y);n.hasWidth(e.x)&&!n.hasContent(e.x)&&e.x--}this._restrictCursor()},e.prototype.tab=function(){if(!(this._bufferService.buffer.x>=this._bufferService.cols)){var t=this._bufferService.buffer.x;this._bufferService.buffer.x=this._bufferService.buffer.nextStop(),this._optionsService.options.screenReaderMode&&this._onA11yTab.fire(this._bufferService.buffer.x-t)}},e.prototype.shiftOut=function(){this._charsetService.setgLevel(1)},e.prototype.shiftIn=function(){this._charsetService.setgLevel(0)},e.prototype._restrictCursor=function(t){void 0===t&&(t=this._bufferService.cols-1),this._bufferService.buffer.x=Math.min(t,Math.max(0,this._bufferService.buffer.x)),this._bufferService.buffer.y=this._coreService.decPrivateModes.origin?Math.min(this._bufferService.buffer.scrollBottom,Math.max(this._bufferService.buffer.scrollTop,this._bufferService.buffer.y)):Math.min(this._bufferService.rows-1,Math.max(0,this._bufferService.buffer.y)),this._dirtyRowService.markDirty(this._bufferService.buffer.y)},e.prototype._setCursor=function(t,e){this._dirtyRowService.markDirty(this._bufferService.buffer.y),this._coreService.decPrivateModes.origin?(this._bufferService.buffer.x=t,this._bufferService.buffer.y=this._bufferService.buffer.scrollTop+e):(this._bufferService.buffer.x=t,this._bufferService.buffer.y=e),this._restrictCursor(),this._dirtyRowService.markDirty(this._bufferService.buffer.y)},e.prototype._moveCursor=function(t,e){this._restrictCursor(),this._setCursor(this._bufferService.buffer.x+t,this._bufferService.buffer.y+e)},e.prototype.cursorUp=function(t){var e=this._bufferService.buffer.y-this._bufferService.buffer.scrollTop;this._moveCursor(0,e>=0?-Math.min(e,t.params[0]||1):-(t.params[0]||1))},e.prototype.cursorDown=function(t){var e=this._bufferService.buffer.scrollBottom-this._bufferService.buffer.y;this._moveCursor(0,e>=0?Math.min(e,t.params[0]||1):t.params[0]||1)},e.prototype.cursorForward=function(t){this._moveCursor(t.params[0]||1,0)},e.prototype.cursorBackward=function(t){this._moveCursor(-(t.params[0]||1),0)},e.prototype.cursorNextLine=function(t){this.cursorDown(t),this._bufferService.buffer.x=0},e.prototype.cursorPrecedingLine=function(t){this.cursorUp(t),this._bufferService.buffer.x=0},e.prototype.cursorCharAbsolute=function(t){this._setCursor((t.params[0]||1)-1,this._bufferService.buffer.y)},e.prototype.cursorPosition=function(t){this._setCursor(t.length>=2?(t.params[1]||1)-1:0,(t.params[0]||1)-1)},e.prototype.charPosAbsolute=function(t){this._setCursor((t.params[0]||1)-1,this._bufferService.buffer.y)},e.prototype.hPositionRelative=function(t){this._moveCursor(t.params[0]||1,0)},e.prototype.linePosAbsolute=function(t){this._setCursor(this._bufferService.buffer.x,(t.params[0]||1)-1)},e.prototype.vPositionRelative=function(t){this._moveCursor(0,t.params[0]||1)},e.prototype.hVPosition=function(t){this.cursorPosition(t)},e.prototype.tabClear=function(t){var e=t.params[0];0===e?delete this._bufferService.buffer.tabs[this._bufferService.buffer.x]:3===e&&(this._bufferService.buffer.tabs={})},e.prototype.cursorForwardTab=function(t){if(!(this._bufferService.buffer.x>=this._bufferService.cols))for(var e=t.params[0]||1;e--;)this._bufferService.buffer.x=this._bufferService.buffer.nextStop()},e.prototype.cursorBackwardTab=function(t){if(!(this._bufferService.buffer.x>=this._bufferService.cols))for(var e=t.params[0]||1,n=this._bufferService.buffer;e--;)n.x=n.prevStop()},e.prototype._eraseInBufferLine=function(t,e,n,i){void 0===i&&(i=!1);var r=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+t);r.replaceCells(e,n,this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),i&&(r.isWrapped=!1)},e.prototype._resetBufferLine=function(t){var e=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+t);e.fill(this._bufferService.buffer.getNullCell(this._eraseAttrData())),e.isWrapped=!1},e.prototype.eraseInDisplay=function(t){var e;switch(this._restrictCursor(),t.params[0]){case 0:for(this._dirtyRowService.markDirty(e=this._bufferService.buffer.y),this._eraseInBufferLine(e++,this._bufferService.buffer.x,this._bufferService.cols,0===this._bufferService.buffer.x);e<this._bufferService.rows;e++)this._resetBufferLine(e);this._dirtyRowService.markDirty(e);break;case 1:for(this._dirtyRowService.markDirty(e=this._bufferService.buffer.y),this._eraseInBufferLine(e,0,this._bufferService.buffer.x+1,!0),this._bufferService.buffer.x+1>=this._bufferService.cols&&(this._bufferService.buffer.lines.get(e+1).isWrapped=!1);e--;)this._resetBufferLine(e);this._dirtyRowService.markDirty(0);break;case 2:for(this._dirtyRowService.markDirty((e=this._bufferService.rows)-1);e--;)this._resetBufferLine(e);this._dirtyRowService.markDirty(0);break;case 3:var n=this._bufferService.buffer.lines.length-this._bufferService.rows;n>0&&(this._bufferService.buffer.lines.trimStart(n),this._bufferService.buffer.ybase=Math.max(this._bufferService.buffer.ybase-n,0),this._bufferService.buffer.ydisp=Math.max(this._bufferService.buffer.ydisp-n,0),this._onScroll.fire(0))}},e.prototype.eraseInLine=function(t){switch(this._restrictCursor(),t.params[0]){case 0:this._eraseInBufferLine(this._bufferService.buffer.y,this._bufferService.buffer.x,this._bufferService.cols);break;case 1:this._eraseInBufferLine(this._bufferService.buffer.y,0,this._bufferService.buffer.x+1);break;case 2:this._eraseInBufferLine(this._bufferService.buffer.y,0,this._bufferService.cols)}this._dirtyRowService.markDirty(this._bufferService.buffer.y)},e.prototype.insertLines=function(t){this._restrictCursor();var e=t.params[0]||1,n=this._bufferService.buffer;if(!(n.y>n.scrollBottom||n.y<n.scrollTop)){for(var i=n.ybase+n.y,r=this._bufferService.rows-1+n.ybase-(this._bufferService.rows-1-n.scrollBottom)+1;e--;)n.lines.splice(r-1,1),n.lines.splice(i,0,n.getBlankLine(this._eraseAttrData()));this._dirtyRowService.markRangeDirty(n.y,n.scrollBottom),n.x=0}},e.prototype.deleteLines=function(t){this._restrictCursor();var e=t.params[0]||1,n=this._bufferService.buffer;if(!(n.y>n.scrollBottom||n.y<n.scrollTop)){var i,r=n.ybase+n.y;for(i=this._bufferService.rows-1+n.ybase-(i=this._bufferService.rows-1-n.scrollBottom);e--;)n.lines.splice(r,1),n.lines.splice(i,0,n.getBlankLine(this._eraseAttrData()));this._dirtyRowService.markRangeDirty(n.y,n.scrollBottom),n.x=0}},e.prototype.insertChars=function(t){this._restrictCursor();var e=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+this._bufferService.buffer.y);e&&(e.insertCells(this._bufferService.buffer.x,t.params[0]||1,this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowService.markDirty(this._bufferService.buffer.y))},e.prototype.deleteChars=function(t){this._restrictCursor();var e=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+this._bufferService.buffer.y);e&&(e.deleteCells(this._bufferService.buffer.x,t.params[0]||1,this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowService.markDirty(this._bufferService.buffer.y))},e.prototype.scrollUp=function(t){for(var e=t.params[0]||1,n=this._bufferService.buffer;e--;)n.lines.splice(n.ybase+n.scrollTop,1),n.lines.splice(n.ybase+n.scrollBottom,0,n.getBlankLine(this._eraseAttrData()));this._dirtyRowService.markRangeDirty(n.scrollTop,n.scrollBottom)},e.prototype.scrollDown=function(t){for(var e=t.params[0]||1,n=this._bufferService.buffer;e--;)n.lines.splice(n.ybase+n.scrollBottom,1),n.lines.splice(n.ybase+n.scrollTop,0,n.getBlankLine(d.DEFAULT_ATTR_DATA));this._dirtyRowService.markRangeDirty(n.scrollTop,n.scrollBottom)},e.prototype.scrollLeft=function(t){var e=this._bufferService.buffer;if(!(e.y>e.scrollBottom||e.y<e.scrollTop)){for(var n=t.params[0]||1,i=e.scrollTop;i<=e.scrollBottom;++i){var r=e.lines.get(e.ybase+i);r.deleteCells(0,n,e.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r.isWrapped=!1}this._dirtyRowService.markRangeDirty(e.scrollTop,e.scrollBottom)}},e.prototype.scrollRight=function(t){var e=this._bufferService.buffer;if(!(e.y>e.scrollBottom||e.y<e.scrollTop)){for(var n=t.params[0]||1,i=e.scrollTop;i<=e.scrollBottom;++i){var r=e.lines.get(e.ybase+i);r.insertCells(0,n,e.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r.isWrapped=!1}this._dirtyRowService.markRangeDirty(e.scrollTop,e.scrollBottom)}},e.prototype.insertColumns=function(t){var e=this._bufferService.buffer;if(!(e.y>e.scrollBottom||e.y<e.scrollTop)){for(var n=t.params[0]||1,i=e.scrollTop;i<=e.scrollBottom;++i){var r=this._bufferService.buffer.lines.get(e.ybase+i);r.insertCells(e.x,n,e.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r.isWrapped=!1}this._dirtyRowService.markRangeDirty(e.scrollTop,e.scrollBottom)}},e.prototype.deleteColumns=function(t){var e=this._bufferService.buffer;if(!(e.y>e.scrollBottom||e.y<e.scrollTop)){for(var n=t.params[0]||1,i=e.scrollTop;i<=e.scrollBottom;++i){var r=e.lines.get(e.ybase+i);r.deleteCells(e.x,n,e.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r.isWrapped=!1}this._dirtyRowService.markRangeDirty(e.scrollTop,e.scrollBottom)}},e.prototype.eraseChars=function(t){this._restrictCursor();var e=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+this._bufferService.buffer.y);e&&(e.replaceCells(this._bufferService.buffer.x,this._bufferService.buffer.x+(t.params[0]||1),this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowService.markDirty(this._bufferService.buffer.y))},e.prototype.repeatPrecedingCharacter=function(t){if(this._parser.precedingCodepoint){for(var e=t.params[0]||1,n=new Uint32Array(e),i=0;i<e;++i)n[i]=this._parser.precedingCodepoint;this.print(n,0,n.length)}},e.prototype.sendDeviceAttributesPrimary=function(t){t.params[0]>0||(this._is("xterm")||this._is("rxvt-unicode")||this._is("screen")?this._coreService.triggerDataEvent(a.C0.ESC+"[?1;2c"):this._is("linux")&&this._coreService.triggerDataEvent(a.C0.ESC+"[?6c"))},e.prototype.sendDeviceAttributesSecondary=function(t){t.params[0]>0||(this._is("xterm")?this._coreService.triggerDataEvent(a.C0.ESC+"[>0;276;0c"):this._is("rxvt-unicode")?this._coreService.triggerDataEvent(a.C0.ESC+"[>85;95;0c"):this._is("linux")?this._coreService.triggerDataEvent(t.params[0]+"c"):this._is("screen")&&this._coreService.triggerDataEvent(a.C0.ESC+"[>83;40003;0c"))},e.prototype._is=function(t){return 0===(this._optionsService.options.termName+"").indexOf(t)},e.prototype.setMode=function(t){for(var e=0;e<t.length;e++)switch(t.params[e]){case 4:this._coreService.modes.insertMode=!0}},e.prototype.setModePrivate=function(t){for(var e=0;e<t.length;e++)switch(t.params[e]){case 1:this._coreService.decPrivateModes.applicationCursorKeys=!0;break;case 2:this._charsetService.setgCharset(0,s.DEFAULT_CHARSET),this._charsetService.setgCharset(1,s.DEFAULT_CHARSET),this._charsetService.setgCharset(2,s.DEFAULT_CHARSET),this._charsetService.setgCharset(3,s.DEFAULT_CHARSET);break;case 3:this._optionsService.options.windowOptions.setWinLines&&(this._bufferService.resize(132,this._bufferService.rows),this._onRequestReset.fire());break;case 6:this._coreService.decPrivateModes.origin=!0,this._setCursor(0,0);break;case 7:this._coreService.decPrivateModes.wraparound=!0;break;case 12:break;case 45:this._coreService.decPrivateModes.reverseWraparound=!0;break;case 66:this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire();break;case 9:this._coreMouseService.activeProtocol="X10";break;case 1e3:this._coreMouseService.activeProtocol="VT200";break;case 1002:this._coreMouseService.activeProtocol="DRAG";break;case 1003:this._coreMouseService.activeProtocol="ANY";break;case 1004:this._coreService.decPrivateModes.sendFocus=!0;break;case 1005:this._logService.debug("DECSET 1005 not supported (see #2507)");break;case 1006:this._coreMouseService.activeEncoding="SGR";break;case 1015:this._logService.debug("DECSET 1015 not supported (see #2507)");break;case 25:this._coreService.isCursorHidden=!1;break;case 1048:this.saveCursor();break;case 1049:this.saveCursor();case 47:case 1047:this._bufferService.buffers.activateAltBuffer(this._eraseAttrData()),this._coreService.isCursorInitialized=!0,this._onRequestRefreshRows.fire(0,this._bufferService.rows-1),this._onRequestSyncScrollBar.fire();break;case 2004:this._coreService.decPrivateModes.bracketedPasteMode=!0}},e.prototype.resetMode=function(t){for(var e=0;e<t.length;e++)switch(t.params[e]){case 4:this._coreService.modes.insertMode=!1}},e.prototype.resetModePrivate=function(t){for(var e=0;e<t.length;e++)switch(t.params[e]){case 1:this._coreService.decPrivateModes.applicationCursorKeys=!1;break;case 3:this._optionsService.options.windowOptions.setWinLines&&(this._bufferService.resize(80,this._bufferService.rows),this._onRequestReset.fire());break;case 6:this._coreService.decPrivateModes.origin=!1,this._setCursor(0,0);break;case 7:this._coreService.decPrivateModes.wraparound=!1;break;case 12:break;case 45:this._coreService.decPrivateModes.reverseWraparound=!1;break;case 66:this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire();break;case 9:case 1e3:case 1002:case 1003:this._coreMouseService.activeProtocol="NONE";break;case 1004:this._coreService.decPrivateModes.sendFocus=!1;break;case 1005:this._logService.debug("DECRST 1005 not supported (see #2507)");break;case 1006:this._coreMouseService.activeEncoding="DEFAULT";break;case 1015:this._logService.debug("DECRST 1015 not supported (see #2507)");break;case 25:this._coreService.isCursorHidden=!0;break;case 1048:this.restoreCursor();break;case 1049:case 47:case 1047:this._bufferService.buffers.activateNormalBuffer(),1049===t.params[e]&&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}},e.prototype._updateAttrColor=function(t,e,n,i,r){return 2===e?(t|=50331648,t&=-16777216,t|=g.AttributeData.fromColorRGB([n,i,r])):5===e&&(t&=-50331904,t|=33554432|255&n),t},e.prototype._extractColor=function(t,e,n){var i=[0,0,-1,0,0,0],r=0,o=0;do{if(i[o+r]=t.params[e+o],t.hasSubParams(e+o)){var a=t.getSubParams(e+o),s=0;do{5===i[1]&&(r=1),i[o+s+1+r]=a[s]}while(++s<a.length&&s+o+1+r<i.length);break}if(5===i[1]&&o+r>=2||2===i[1]&&o+r>=5)break;i[1]&&(r=1)}while(++o+e<t.length&&o+r<i.length);for(s=2;s<i.length;++s)-1===i[s]&&(i[s]=0);switch(i[0]){case 38:n.fg=this._updateAttrColor(n.fg,i[1],i[3],i[4],i[5]);break;case 48:n.bg=this._updateAttrColor(n.bg,i[1],i[3],i[4],i[5]);break;case 58:n.extended=n.extended.clone(),n.extended.underlineColor=this._updateAttrColor(n.extended.underlineColor,i[1],i[3],i[4],i[5])}return o},e.prototype._processUnderline=function(t,e){e.extended=e.extended.clone(),(!~t||t>5)&&(t=1),e.extended.underlineStyle=t,e.fg|=268435456,0===t&&(e.fg&=-268435457),e.updateExtended()},e.prototype.charAttributes=function(t){if(1===t.length&&0===t.params[0])return this._curAttrData.fg=d.DEFAULT_ATTR_DATA.fg,void(this._curAttrData.bg=d.DEFAULT_ATTR_DATA.bg);for(var e,n=t.length,i=this._curAttrData,r=0;r<n;r++)(e=t.params[r])>=30&&e<=37?(i.fg&=-50331904,i.fg|=16777216|e-30):e>=40&&e<=47?(i.bg&=-50331904,i.bg|=16777216|e-40):e>=90&&e<=97?(i.fg&=-50331904,i.fg|=16777224|e-90):e>=100&&e<=107?(i.bg&=-50331904,i.bg|=16777224|e-100):0===e?(i.fg=d.DEFAULT_ATTR_DATA.fg,i.bg=d.DEFAULT_ATTR_DATA.bg):1===e?i.fg|=134217728:3===e?i.bg|=67108864:4===e?(i.fg|=268435456,this._processUnderline(t.hasSubParams(r)?t.getSubParams(r)[0]:1,i)):5===e?i.fg|=536870912:7===e?i.fg|=67108864:8===e?i.fg|=1073741824:2===e?i.bg|=134217728:21===e?this._processUnderline(2,i):22===e?(i.fg&=-134217729,i.bg&=-134217729):23===e?i.bg&=-67108865:24===e?i.fg&=-268435457:25===e?i.fg&=-536870913:27===e?i.fg&=-67108865:28===e?i.fg&=-1073741825:39===e?(i.fg&=-67108864,i.fg|=16777215&d.DEFAULT_ATTR_DATA.fg):49===e?(i.bg&=-67108864,i.bg|=16777215&d.DEFAULT_ATTR_DATA.bg):38===e||48===e||58===e?r+=this._extractColor(t,r,i):59===e?(i.extended=i.extended.clone(),i.extended.underlineColor=-1,i.updateExtended()):100===e?(i.fg&=-67108864,i.fg|=16777215&d.DEFAULT_ATTR_DATA.fg,i.bg&=-67108864,i.bg|=16777215&d.DEFAULT_ATTR_DATA.bg):this._logService.debug("Unknown SGR attribute: %d.",e)},e.prototype.deviceStatus=function(t){switch(t.params[0]){case 5:this._coreService.triggerDataEvent(a.C0.ESC+"[0n");break;case 6:this._coreService.triggerDataEvent(a.C0.ESC+"["+(this._bufferService.buffer.y+1)+";"+(this._bufferService.buffer.x+1)+"R")}},e.prototype.deviceStatusPrivate=function(t){switch(t.params[0]){case 6:this._coreService.triggerDataEvent(a.C0.ESC+"[?"+(this._bufferService.buffer.y+1)+";"+(this._bufferService.buffer.x+1)+"R")}},e.prototype.softReset=function(t){this._coreService.isCursorHidden=!1,this._onRequestSyncScrollBar.fire(),this._bufferService.buffer.scrollTop=0,this._bufferService.buffer.scrollBottom=this._bufferService.rows-1,this._curAttrData=d.DEFAULT_ATTR_DATA.clone(),this._coreService.reset(),this._charsetService.reset(),this._bufferService.buffer.savedX=0,this._bufferService.buffer.savedY=this._bufferService.buffer.ybase,this._bufferService.buffer.savedCurAttrData.fg=this._curAttrData.fg,this._bufferService.buffer.savedCurAttrData.bg=this._curAttrData.bg,this._bufferService.buffer.savedCharset=this._charsetService.charset,this._coreService.decPrivateModes.origin=!1},e.prototype.setCursorStyle=function(t){var e=t.params[0]||1;switch(e){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"}this._optionsService.options.cursorBlink=e%2==1},e.prototype.setScrollRegion=function(t){var e,n=t.params[0]||1;(t.length<2||(e=t.params[1])>this._bufferService.rows||0===e)&&(e=this._bufferService.rows),e>n&&(this._bufferService.buffer.scrollTop=n-1,this._bufferService.buffer.scrollBottom=e-1,this._setCursor(0,0))},e.prototype.windowOptions=function(t){if(_(t.params[0],this._optionsService.options.windowOptions)){var e=t.length>1?t.params[1]:0;switch(t.params[0]){case 14:2!==e&&this._onRequestWindowsOptionsReport.fire(o.GET_WIN_SIZE_PIXELS);break;case 16:this._onRequestWindowsOptionsReport.fire(o.GET_CELL_SIZE_PIXELS);break;case 18:this._bufferService&&this._coreService.triggerDataEvent(a.C0.ESC+"[8;"+this._bufferService.rows+";"+this._bufferService.cols+"t");break;case 22:0!==e&&2!==e||(this._windowTitleStack.push(this._windowTitle),this._windowTitleStack.length>10&&this._windowTitleStack.shift()),0!==e&&1!==e||(this._iconNameStack.push(this._iconName),this._iconNameStack.length>10&&this._iconNameStack.shift());break;case 23:0!==e&&2!==e||this._windowTitleStack.length&&this.setTitle(this._windowTitleStack.pop()),0!==e&&1!==e||this._iconNameStack.length&&this.setIconName(this._iconNameStack.pop())}}},e.prototype.saveCursor=function(t){this._bufferService.buffer.savedX=this._bufferService.buffer.x,this._bufferService.buffer.savedY=this._bufferService.buffer.ybase+this._bufferService.buffer.y,this._bufferService.buffer.savedCurAttrData.fg=this._curAttrData.fg,this._bufferService.buffer.savedCurAttrData.bg=this._curAttrData.bg,this._bufferService.buffer.savedCharset=this._charsetService.charset},e.prototype.restoreCursor=function(t){this._bufferService.buffer.x=this._bufferService.buffer.savedX||0,this._bufferService.buffer.y=Math.max(this._bufferService.buffer.savedY-this._bufferService.buffer.ybase,0),this._curAttrData.fg=this._bufferService.buffer.savedCurAttrData.fg,this._curAttrData.bg=this._bufferService.buffer.savedCurAttrData.bg,this._charsetService.charset=this._savedCharset,this._bufferService.buffer.savedCharset&&(this._charsetService.charset=this._bufferService.buffer.savedCharset),this._restrictCursor()},e.prototype.setTitle=function(t){this._windowTitle=t,this._onTitleChange.fire(t)},e.prototype.setIconName=function(t){this._iconName=t},e.prototype.nextLine=function(){this._bufferService.buffer.x=0,this.index()},e.prototype.keypadApplicationMode=function(){this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire()},e.prototype.keypadNumericMode=function(){this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire()},e.prototype.selectDefaultCharset=function(){this._charsetService.setgLevel(0),this._charsetService.setgCharset(0,s.DEFAULT_CHARSET)},e.prototype.selectCharset=function(t){2===t.length?"/"!==t[0]&&this._charsetService.setgCharset(y[t[0]],s.CHARSETS[t[1]]||s.DEFAULT_CHARSET):this.selectDefaultCharset()},e.prototype.index=function(){this._restrictCursor();var t=this._bufferService.buffer;this._bufferService.buffer.y++,t.y===t.scrollBottom+1?(t.y--,this._onRequestScroll.fire(this._eraseAttrData())):t.y>=this._bufferService.rows&&(t.y=this._bufferService.rows-1),this._restrictCursor()},e.prototype.tabSet=function(){this._bufferService.buffer.tabs[this._bufferService.buffer.x]=!0},e.prototype.reverseIndex=function(){this._restrictCursor();var t=this._bufferService.buffer;t.y===t.scrollTop?(t.lines.shiftElements(t.ybase+t.y,t.scrollBottom-t.scrollTop,1),t.lines.set(t.ybase+t.y,t.getBlankLine(this._eraseAttrData())),this._dirtyRowService.markRangeDirty(t.scrollTop,t.scrollBottom)):(t.y--,this._restrictCursor())},e.prototype.fullReset=function(){this._parser.reset(),this._onRequestReset.fire()},e.prototype.reset=function(){this._curAttrData=d.DEFAULT_ATTR_DATA.clone(),this._eraseAttrDataInternal=d.DEFAULT_ATTR_DATA.clone()},e.prototype._eraseAttrData=function(){return this._eraseAttrDataInternal.bg&=-67108864,this._eraseAttrDataInternal.bg|=67108863&this._curAttrData.bg,this._eraseAttrDataInternal},e.prototype.setgLevel=function(t){this._charsetService.setgLevel(t)},e.prototype.screenAlignmentPattern=function(){var t=new m.CellData;t.content=1<<22|"E".charCodeAt(0),t.fg=this._curAttrData.fg,t.bg=this._curAttrData.bg;var e=this._bufferService.buffer;this._setCursor(0,0);for(var n=0;n<this._bufferService.rows;++n){var i=e.lines.get(e.ybase+e.y+n);i&&(i.fill(t),i.isWrapped=!1)}this._dirtyRowService.markAllDirty(),this._setCursor(0,0)},e}(l.Disposable);e.InputHandler=k},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_CHARSET=e.CHARSETS=void 0,e.CHARSETS={},e.DEFAULT_CHARSET=e.CHARSETS.B,e.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"},e.CHARSETS.A={"#":"\xa3"},e.CHARSETS.B=void 0,e.CHARSETS[4]={"#":"\xa3","@":"\xbe","[":"ij","\\":"\xbd","]":"|","{":"\xa8","|":"f","}":"\xbc","~":"\xb4"},e.CHARSETS.C=e.CHARSETS[5]={"[":"\xc4","\\":"\xd6","]":"\xc5","^":"\xdc","`":"\xe9","{":"\xe4","|":"\xf6","}":"\xe5","~":"\xfc"},e.CHARSETS.R={"#":"\xa3","@":"\xe0","[":"\xb0","\\":"\xe7","]":"\xa7","{":"\xe9","|":"\xf9","}":"\xe8","~":"\xa8"},e.CHARSETS.Q={"@":"\xe0","[":"\xe2","\\":"\xe7","]":"\xea","^":"\xee","`":"\xf4","{":"\xe9","|":"\xf9","}":"\xe8","~":"\xfb"},e.CHARSETS.K={"@":"\xa7","[":"\xc4","\\":"\xd6","]":"\xdc","{":"\xe4","|":"\xf6","}":"\xfc","~":"\xdf"},e.CHARSETS.Y={"#":"\xa3","@":"\xa7","[":"\xb0","\\":"\xe7","]":"\xe9","`":"\xf9","{":"\xe0","|":"\xf2","}":"\xe8","~":"\xec"},e.CHARSETS.E=e.CHARSETS[6]={"@":"\xc4","[":"\xc6","\\":"\xd8","]":"\xc5","^":"\xdc","`":"\xe4","{":"\xe6","|":"\xf8","}":"\xe5","~":"\xfc"},e.CHARSETS.Z={"#":"\xa3","@":"\xa7","[":"\xa1","\\":"\xd1","]":"\xbf","{":"\xb0","|":"\xf1","}":"\xe7"},e.CHARSETS.H=e.CHARSETS[7]={"@":"\xc9","[":"\xc4","\\":"\xd6","]":"\xc5","^":"\xdc","`":"\xe9","{":"\xe4","|":"\xf6","}":"\xe5","~":"\xfc"},e.CHARSETS["="]={"#":"\xf9","@":"\xe0","[":"\xe9","\\":"\xe7","]":"\xea","^":"\xee",_:"\xe8","`":"\xf4","{":"\xe4","|":"\xf6","}":"\xfc","~":"\xfb"}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Params=void 0;var i=function(){function t(t,e){if(void 0===t&&(t=32),void 0===e&&(e=32),this.maxLength=t,this.maxSubParamsLength=e,e>256)throw new Error("maxSubParamsLength must not be greater than 256");this.params=new Int32Array(t),this.length=0,this._subParams=new Int32Array(e),this._subParamsLength=0,this._subParamsIdx=new Uint16Array(t),this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}return t.fromArray=function(e){var n=new t;if(!e.length)return n;for(var i=e[0]instanceof Array?1:0;i<e.length;++i){var r=e[i];if(r instanceof Array)for(var o=0;o<r.length;++o)n.addSubParam(r[o]);else n.addParam(r)}return n},t.prototype.clone=function(){var e=new t(this.maxLength,this.maxSubParamsLength);return e.params.set(this.params),e.length=this.length,e._subParams.set(this._subParams),e._subParamsLength=this._subParamsLength,e._subParamsIdx.set(this._subParamsIdx),e._rejectDigits=this._rejectDigits,e._rejectSubDigits=this._rejectSubDigits,e._digitIsSub=this._digitIsSub,e},t.prototype.toArray=function(){for(var t=[],e=0;e<this.length;++e){t.push(this.params[e]);var n=this._subParamsIdx[e]>>8,i=255&this._subParamsIdx[e];i-n>0&&t.push(Array.prototype.slice.call(this._subParams,n,i))}return t},t.prototype.reset=function(){this.length=0,this._subParamsLength=0,this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1},t.prototype.addParam=function(t){if(this._digitIsSub=!1,this.length>=this.maxLength)this._rejectDigits=!0;else{if(t<-1)throw new Error("values lesser than -1 are not allowed");this._subParamsIdx[this.length]=this._subParamsLength<<8|this._subParamsLength,this.params[this.length++]=t>2147483647?2147483647:t}},t.prototype.addSubParam=function(t){if(this._digitIsSub=!0,this.length)if(this._rejectDigits||this._subParamsLength>=this.maxSubParamsLength)this._rejectSubDigits=!0;else{if(t<-1)throw new Error("values lesser than -1 are not allowed");this._subParams[this._subParamsLength++]=t>2147483647?2147483647:t,this._subParamsIdx[this.length-1]++}},t.prototype.hasSubParams=function(t){return(255&this._subParamsIdx[t])-(this._subParamsIdx[t]>>8)>0},t.prototype.getSubParams=function(t){var e=this._subParamsIdx[t]>>8,n=255&this._subParamsIdx[t];return n-e>0?this._subParams.subarray(e,n):null},t.prototype.getSubParamsAll=function(){for(var t={},e=0;e<this.length;++e){var n=this._subParamsIdx[e]>>8,i=255&this._subParamsIdx[e];i-n>0&&(t[e]=this._subParams.slice(n,i))}return t},t.prototype.addDigit=function(t){var e;if(!(this._rejectDigits||!(e=this._digitIsSub?this._subParamsLength:this.length)||this._digitIsSub&&this._rejectSubDigits)){var n=this._digitIsSub?this._subParams:this.params,i=n[e-1];n[e-1]=~i?Math.min(10*i+t,2147483647):t}},t}();e.Params=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.OscHandler=e.OscParser=void 0;var i=n(23),r=n(8),o=function(){function t(){this._state=0,this._id=-1,this._handlers=Object.create(null),this._handlerFb=function(){}}return t.prototype.addHandler=function(t,e){void 0===this._handlers[t]&&(this._handlers[t]=[]);var n=this._handlers[t];return n.push(e),{dispose:function(){var t=n.indexOf(e);-1!==t&&n.splice(t,1)}}},t.prototype.setHandler=function(t,e){this._handlers[t]=[e]},t.prototype.clearHandler=function(t){this._handlers[t]&&delete this._handlers[t]},t.prototype.setHandlerFallback=function(t){this._handlerFb=t},t.prototype.dispose=function(){this._handlers=Object.create(null),this._handlerFb=function(){}},t.prototype.reset=function(){2===this._state&&this.end(!1),this._id=-1,this._state=0},t.prototype._start=function(){var t=this._handlers[this._id];if(t)for(var e=t.length-1;e>=0;e--)t[e].start();else this._handlerFb(this._id,"START")},t.prototype._put=function(t,e,n){var i=this._handlers[this._id];if(i)for(var o=i.length-1;o>=0;o--)i[o].put(t,e,n);else this._handlerFb(this._id,"PUT",r.utf32ToString(t,e,n))},t.prototype._end=function(t){var e=this._handlers[this._id];if(e){for(var n=e.length-1;n>=0&&!1===e[n].end(t);n--);for(n--;n>=0;n--)e[n].end(!1)}else this._handlerFb(this._id,"END",t)},t.prototype.start=function(){this.reset(),this._id=-1,this._state=1},t.prototype.put=function(t,e,n){if(3!==this._state){if(1===this._state)for(;e<n;){var i=t[e++];if(59===i){this._state=2,this._start();break}if(i<48||57<i)return void(this._state=3);-1===this._id&&(this._id=0),this._id=10*this._id+i-48}2===this._state&&n-e>0&&this._put(t,e,n)}},t.prototype.end=function(t){0!==this._state&&(3!==this._state&&(1===this._state&&this._start(),this._end(t)),this._id=-1,this._state=0)},t}();e.OscParser=o;var a=function(){function t(t){this._handler=t,this._data="",this._hitLimit=!1}return t.prototype.start=function(){this._data="",this._hitLimit=!1},t.prototype.put=function(t,e,n){this._hitLimit||(this._data+=r.utf32ToString(t,e,n),this._data.length>i.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))},t.prototype.end=function(t){var e;return this._hitLimit?e=!1:t&&(e=this._handler(this._data)),this._data="",this._hitLimit=!1,e},t}();e.OscHandler=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.PAYLOAD_LIMIT=void 0,e.PAYLOAD_LIMIT=1e7},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DcsHandler=e.DcsParser=void 0;var i=n(8),r=n(21),o=n(23),a=[],s=function(){function t(){this._handlers=Object.create(null),this._active=a,this._ident=0,this._handlerFb=function(){}}return t.prototype.dispose=function(){this._handlers=Object.create(null),this._handlerFb=function(){}},t.prototype.addHandler=function(t,e){void 0===this._handlers[t]&&(this._handlers[t]=[]);var n=this._handlers[t];return n.push(e),{dispose:function(){var t=n.indexOf(e);-1!==t&&n.splice(t,1)}}},t.prototype.setHandler=function(t,e){this._handlers[t]=[e]},t.prototype.clearHandler=function(t){this._handlers[t]&&delete this._handlers[t]},t.prototype.setHandlerFallback=function(t){this._handlerFb=t},t.prototype.reset=function(){this._active.length&&this.unhook(!1),this._active=a,this._ident=0},t.prototype.hook=function(t,e){if(this.reset(),this._ident=t,this._active=this._handlers[t]||a,this._active.length)for(var n=this._active.length-1;n>=0;n--)this._active[n].hook(e);else this._handlerFb(this._ident,"HOOK",e)},t.prototype.put=function(t,e,n){if(this._active.length)for(var r=this._active.length-1;r>=0;r--)this._active[r].put(t,e,n);else this._handlerFb(this._ident,"PUT",i.utf32ToString(t,e,n))},t.prototype.unhook=function(t){if(this._active.length){for(var e=this._active.length-1;e>=0&&!1===this._active[e].unhook(t);e--);for(e--;e>=0;e--)this._active[e].unhook(!1)}else this._handlerFb(this._ident,"UNHOOK",t);this._active=a,this._ident=0},t}();e.DcsParser=s;var c=function(){function t(t){this._handler=t,this._data="",this._hitLimit=!1}return t.prototype.hook=function(t){this._params=t.clone(),this._data="",this._hitLimit=!1},t.prototype.put=function(t,e,n){this._hitLimit||(this._data+=i.utf32ToString(t,e,n),this._data.length>o.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))},t.prototype.unhook=function(t){var e;return this._hitLimit?e=!1:t&&(e=this._handler(this._data,this._params||new r.Params)),this._params=void 0,this._data="",this._hitLimit=!1,e},t}();e.DcsHandler=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.removeTerminalFromCache=e.acquireCharAtlas=void 0;var i=n(26),r=n(43),o=[];e.acquireCharAtlas=function(t,e,n,a,s){for(var c=i.generateConfig(a,s,t,n),l=0;l<o.length;l++){var u=(h=o[l]).ownedBy.indexOf(e);if(u>=0){if(i.configEquals(h.config,c))return h.atlas;1===h.ownedBy.length?(h.atlas.dispose(),o.splice(l,1)):h.ownedBy.splice(u,1);break}}for(l=0;l<o.length;l++){var h=o[l];if(i.configEquals(h.config,c))return h.ownedBy.push(e),h.atlas}var d={atlas:new r.DynamicCharAtlas(document,c),config:c,ownedBy:[e]};return o.push(d),d.atlas},e.removeTerminalFromCache=function(t){for(var e=0;e<o.length;e++){var n=o[e].ownedBy.indexOf(t);if(-1!==n){1===o[e].ownedBy.length?(o[e].atlas.dispose(),o.splice(e,1)):o[e].ownedBy.splice(n,1);break}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.is256Color=e.configEquals=e.generateConfig=void 0;var i=n(3);e.generateConfig=function(t,e,n,i){var r={foreground:i.foreground,background:i.background,cursor:void 0,cursorAccent:void 0,selection:void 0,ansi:i.ansi.slice(0,16)};return{devicePixelRatio:window.devicePixelRatio,scaledCharWidth:t,scaledCharHeight:e,fontFamily:n.fontFamily,fontSize:n.fontSize,fontWeight:n.fontWeight,fontWeightBold:n.fontWeightBold,allowTransparency:n.allowTransparency,colors:r}},e.configEquals=function(t,e){for(var n=0;n<t.colors.ansi.length;n++)if(t.colors.ansi[n].rgba!==e.colors.ansi[n].rgba)return!1;return t.devicePixelRatio===e.devicePixelRatio&&t.fontFamily===e.fontFamily&&t.fontSize===e.fontSize&&t.fontWeight===e.fontWeight&&t.fontWeightBold===e.fontWeightBold&&t.allowTransparency===e.allowTransparency&&t.scaledCharWidth===e.scaledCharWidth&&t.scaledCharHeight===e.scaledCharHeight&&t.colors.foreground===e.colors.foreground&&t.colors.background===e.colors.background},e.is256Color=function(t){return t<i.DEFAULT_COLOR}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ColorManager=e.DEFAULT_ANSI_COLORS=void 0;var i=n(10),r=n(45),o=i.css.toColor("#ffffff"),a=i.css.toColor("#000000"),s=i.css.toColor("#ffffff"),c=i.css.toColor("#000000"),l={css:"rgba(255, 255, 255, 0.3)",rgba:4294967117};e.DEFAULT_ANSI_COLORS=function(){for(var t=[i.css.toColor("#2e3436"),i.css.toColor("#cc0000"),i.css.toColor("#4e9a06"),i.css.toColor("#c4a000"),i.css.toColor("#3465a4"),i.css.toColor("#75507b"),i.css.toColor("#06989a"),i.css.toColor("#d3d7cf"),i.css.toColor("#555753"),i.css.toColor("#ef2929"),i.css.toColor("#8ae234"),i.css.toColor("#fce94f"),i.css.toColor("#729fcf"),i.css.toColor("#ad7fa8"),i.css.toColor("#34e2e2"),i.css.toColor("#eeeeec")],e=[0,95,135,175,215,255],n=0;n<216;n++){var r=e[n/36%6|0],o=e[n/6%6|0],a=e[n%6];t.push({css:i.channels.toCss(r,o,a),rgba:i.channels.toRgba(r,o,a)})}for(n=0;n<24;n++){var s=8+10*n;t.push({css:i.channels.toCss(s,s,s),rgba:i.channels.toRgba(s,s,s)})}return t}();var u=function(){function t(t,n){this.allowTransparency=n;var u=t.createElement("canvas");u.width=1,u.height=1;var h=u.getContext("2d");if(!h)throw new Error("Could not get rendering context");this._ctx=h,this._ctx.globalCompositeOperation="copy",this._litmusColor=this._ctx.createLinearGradient(0,0,1,1),this._contrastCache=new r.ColorContrastCache,this.colors={foreground:o,background:a,cursor:s,cursorAccent:c,selectionTransparent:l,selectionOpaque:i.color.blend(a,l),ansi:e.DEFAULT_ANSI_COLORS.slice(),contrastCache:this._contrastCache}}return t.prototype.onOptionsChange=function(t){"minimumContrastRatio"===t&&this._contrastCache.clear()},t.prototype.setTheme=function(t){void 0===t&&(t={}),this.colors.foreground=this._parseColor(t.foreground,o),this.colors.background=this._parseColor(t.background,a),this.colors.cursor=this._parseColor(t.cursor,s,!0),this.colors.cursorAccent=this._parseColor(t.cursorAccent,c,!0),this.colors.selectionTransparent=this._parseColor(t.selection,l,!0),this.colors.selectionOpaque=i.color.blend(this.colors.background,this.colors.selectionTransparent),i.color.isOpaque(this.colors.selectionTransparent)&&(this.colors.selectionTransparent=i.color.opacity(this.colors.selectionTransparent,.3)),this.colors.ansi[0]=this._parseColor(t.black,e.DEFAULT_ANSI_COLORS[0]),this.colors.ansi[1]=this._parseColor(t.red,e.DEFAULT_ANSI_COLORS[1]),this.colors.ansi[2]=this._parseColor(t.green,e.DEFAULT_ANSI_COLORS[2]),this.colors.ansi[3]=this._parseColor(t.yellow,e.DEFAULT_ANSI_COLORS[3]),this.colors.ansi[4]=this._parseColor(t.blue,e.DEFAULT_ANSI_COLORS[4]),this.colors.ansi[5]=this._parseColor(t.magenta,e.DEFAULT_ANSI_COLORS[5]),this.colors.ansi[6]=this._parseColor(t.cyan,e.DEFAULT_ANSI_COLORS[6]),this.colors.ansi[7]=this._parseColor(t.white,e.DEFAULT_ANSI_COLORS[7]),this.colors.ansi[8]=this._parseColor(t.brightBlack,e.DEFAULT_ANSI_COLORS[8]),this.colors.ansi[9]=this._parseColor(t.brightRed,e.DEFAULT_ANSI_COLORS[9]),this.colors.ansi[10]=this._parseColor(t.brightGreen,e.DEFAULT_ANSI_COLORS[10]),this.colors.ansi[11]=this._parseColor(t.brightYellow,e.DEFAULT_ANSI_COLORS[11]),this.colors.ansi[12]=this._parseColor(t.brightBlue,e.DEFAULT_ANSI_COLORS[12]),this.colors.ansi[13]=this._parseColor(t.brightMagenta,e.DEFAULT_ANSI_COLORS[13]),this.colors.ansi[14]=this._parseColor(t.brightCyan,e.DEFAULT_ANSI_COLORS[14]),this.colors.ansi[15]=this._parseColor(t.brightWhite,e.DEFAULT_ANSI_COLORS[15]),this._contrastCache.clear()},t.prototype._parseColor=function(t,e,n){if(void 0===n&&(n=this.allowTransparency),void 0===t)return e;if(this._ctx.fillStyle=this._litmusColor,this._ctx.fillStyle=t,"string"!=typeof this._ctx.fillStyle)return console.warn("Color: "+t+" is invalid using fallback "+e.css),e;this._ctx.fillRect(0,0,1,1);var r=this._ctx.getImageData(0,0,1,1).data;if(255!==r[3]){if(!n)return console.warn("Color: "+t+" is using transparency, but allowTransparency is false. Using fallback "+e.css+"."),e;var o=this._ctx.fillStyle.substring(5,this._ctx.fillStyle.length-1).split(",").map((function(t){return Number(t)})),a=o[0],s=o[1],c=o[2],l=Math.round(255*o[3]);return{rgba:i.channels.toRgba(a,s,c,l),css:t}}return{css:this._ctx.fillStyle,rgba:i.channels.toRgba(r[0],r[1],r[2],r[3])}},t}();e.ColorManager=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.throwIfFalsy=void 0,e.throwIfFalsy=function(t){if(!t)throw new Error("value must not be falsy");return t}},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.CharacterJoinerRegistry=e.JoinedCellData=void 0;var o=n(6),a=n(3),s=n(4),c=function(t){function e(e,n,i){var r=t.call(this)||this;return r.content=0,r.combinedData="",r.fg=e.fg,r.bg=e.bg,r.combinedData=n,r._width=i,r}return r(e,t),e.prototype.isCombined=function(){return 2097152},e.prototype.getWidth=function(){return this._width},e.prototype.getChars=function(){return this.combinedData},e.prototype.getCode=function(){return 2097151},e.prototype.setFromCharData=function(t){throw new Error("not implemented")},e.prototype.getAsCharData=function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]},e}(o.AttributeData);e.JoinedCellData=c;var l=function(){function t(t){this._bufferService=t,this._characterJoiners=[],this._nextCharacterJoinerId=0,this._workCell=new s.CellData}return t.prototype.registerCharacterJoiner=function(t){var e={id:this._nextCharacterJoinerId++,handler:t};return this._characterJoiners.push(e),e.id},t.prototype.deregisterCharacterJoiner=function(t){for(var e=0;e<this._characterJoiners.length;e++)if(this._characterJoiners[e].id===t)return this._characterJoiners.splice(e,1),!0;return!1},t.prototype.getJoinedCharacters=function(t){if(0===this._characterJoiners.length)return[];var e=this._bufferService.buffer.lines.get(t);if(!e||0===e.length)return[];for(var n=[],i=e.translateToString(!0),r=0,o=0,s=0,c=e.getFg(0),l=e.getBg(0),u=0;u<e.getTrimmedLength();u++)if(e.loadCell(u,this._workCell),0!==this._workCell.getWidth()){if(this._workCell.fg!==c||this._workCell.bg!==l){if(u-r>1)for(var h=this._getJoinedRanges(i,s,o,e,r),d=0;d<h.length;d++)n.push(h[d]);r=u,s=o,c=this._workCell.fg,l=this._workCell.bg}o+=this._workCell.getChars().length||a.WHITESPACE_CELL_CHAR.length}if(this._bufferService.cols-r>1)for(h=this._getJoinedRanges(i,s,o,e,r),d=0;d<h.length;d++)n.push(h[d]);return n},t.prototype._getJoinedRanges=function(e,n,i,r,o){for(var a=e.substring(n,i),s=this._characterJoiners[0].handler(a),c=1;c<this._characterJoiners.length;c++)for(var l=this._characterJoiners[c].handler(a),u=0;u<l.length;u++)t._mergeRanges(s,l[u]);return this._stringRangesToCellRanges(s,r,o),s},t.prototype._stringRangesToCellRanges=function(t,e,n){var i=0,r=!1,o=0,s=t[i];if(s){for(var c=n;c<this._bufferService.cols;c++){var l=e.getWidth(c),u=e.getString(c).length||a.WHITESPACE_CELL_CHAR.length;if(0!==l){if(!r&&s[0]<=o&&(s[0]=c,r=!0),s[1]<=o){if(s[1]=c,!(s=t[++i]))break;s[0]<=o?(s[0]=c,r=!0):r=!1}o+=u}}s&&(s[1]=this._bufferService.cols)}},t._mergeRanges=function(t,e){for(var n=!1,i=0;i<t.length;i++){var r=t[i];if(n){if(e[1]<=r[0])return t[i-1][1]=e[1],t;if(e[1]<=r[1])return t[i-1][1]=Math.max(e[1],r[1]),t.splice(i,1),t;t.splice(i,1),i--}else{if(e[1]<=r[0])return t.splice(i,0,e),t;if(e[1]<=r[1])return r[0]=Math.min(e[0],r[0]),t;e[0]<r[1]&&(r[0]=Math.min(e[0],r[0]),n=!0)}}return n?t[t.length-1][1]=e[1]:t.push(e),t},t}();e.CharacterJoinerRegistry=l},function(t,e,n){"use strict";function i(t,e){var n=e.getBoundingClientRect();return[t.clientX-n.left,t.clientY-n.top]}Object.defineProperty(e,"__esModule",{value:!0}),e.getRawByteCoords=e.getCoords=e.getCoordsRelativeToElement=void 0,e.getCoordsRelativeToElement=i,e.getCoords=function(t,e,n,r,o,a,s,c){if(o){var l=i(t,e);if(l)return l[0]=Math.ceil((l[0]+(c?a/2:0))/a),l[1]=Math.ceil(l[1]/s),l[0]=Math.min(Math.max(l[0],1),n+(c?1:0)),l[1]=Math.min(Math.max(l[1],1),r),l}},e.getRawByteCoords=function(t){if(t)return{x:t[0]+32,y:t[1]+32}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.RenderDebouncer=void 0;var i=function(){function t(t){this._renderCallback=t}return t.prototype.dispose=function(){this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)},t.prototype.refresh=function(t,e,n){var i=this;this._rowCount=n,t=void 0!==t?t:0,e=void 0!==e?e:this._rowCount-1,this._rowStart=void 0!==this._rowStart?Math.min(this._rowStart,t):t,this._rowEnd=void 0!==this._rowEnd?Math.max(this._rowEnd,e):e,this._animationFrame||(this._animationFrame=window.requestAnimationFrame((function(){return i._innerRefresh()})))},t.prototype._innerRefresh=function(){if(void 0!==this._rowStart&&void 0!==this._rowEnd&&void 0!==this._rowCount){var t=Math.max(this._rowStart,0),e=Math.min(this._rowEnd,this._rowCount-1);this._rowStart=void 0,this._rowEnd=void 0,this._animationFrame=void 0,this._renderCallback(t,e)}},t}();e.RenderDebouncer=i},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.ScreenDprMonitor=void 0;var o=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._currentDevicePixelRatio=window.devicePixelRatio,e}return r(e,t),e.prototype.setListener=function(t){var e=this;this._listener&&this.clearListener(),this._listener=t,this._outerListener=function(){e._listener&&(e._listener(window.devicePixelRatio,e._currentDevicePixelRatio),e._updateDpr())},this._updateDpr()},e.prototype.dispose=function(){t.prototype.dispose.call(this),this.clearListener()},e.prototype._updateDpr=function(){var t;this._outerListener&&(null===(t=this._resolutionMediaMatchList)||void 0===t||t.removeListener(this._outerListener),this._currentDevicePixelRatio=window.devicePixelRatio,this._resolutionMediaMatchList=window.matchMedia("screen and (resolution: "+window.devicePixelRatio+"dppx)"),this._resolutionMediaMatchList.addListener(this._outerListener))},e.prototype.clearListener=function(){this._resolutionMediaMatchList&&this._listener&&this._outerListener&&(this._resolutionMediaMatchList.removeListener(this._outerListener),this._resolutionMediaMatchList=void 0,this._listener=void 0,this._outerListener=void 0)},e}(n(2).Disposable);e.ScreenDprMonitor=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.clone=void 0,e.clone=function t(e,n){if(void 0===n&&(n=5),"object"!=typeof e)return e;var i=Array.isArray(e)?[]:{};for(var r in e)i[r]=n<=1?e[r]:e[r]?t(e[r],n-1):e[r];return i}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Terminal=void 0;var i=n(4),r=n(35),o=n(18),a=n(0),s=n(83),c=function(){function t(t){this._core=new r.Terminal(t),this._addonManager=new s.AddonManager}return t.prototype._checkProposedApi=function(){if(!this._core.optionsService.options.allowProposedApi)throw new Error("You must set the allowProposedApi option to true to use proposed API")},Object.defineProperty(t.prototype,"onCursorMove",{get:function(){return this._core.onCursorMove},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onLineFeed",{get:function(){return this._core.onLineFeed},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onSelectionChange",{get:function(){return this._core.onSelectionChange},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onData",{get:function(){return this._core.onData},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onBinary",{get:function(){return this._core.onBinary},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onTitleChange",{get:function(){return this._core.onTitleChange},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onScroll",{get:function(){return this._core.onScroll},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onKey",{get:function(){return this._core.onKey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRender",{get:function(){return this._core.onRender},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onResize",{get:function(){return this._core.onResize},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"element",{get:function(){return this._core.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"parser",{get:function(){return this._checkProposedApi(),this._parser||(this._parser=new d(this._core)),this._parser},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"unicode",{get:function(){return this._checkProposedApi(),new f(this._core)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"textarea",{get:function(){return this._core.textarea},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rows",{get:function(){return this._core.rows},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cols",{get:function(){return this._core.cols},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"buffer",{get:function(){return this._checkProposedApi(),new u(this._core.buffers)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"markers",{get:function(){return this._checkProposedApi(),this._core.markers},enumerable:!1,configurable:!0}),t.prototype.blur=function(){this._core.blur()},t.prototype.focus=function(){this._core.focus()},t.prototype.resize=function(t,e){this._verifyIntegers(t,e),this._core.resize(t,e)},t.prototype.open=function(t){this._core.open(t)},t.prototype.attachCustomKeyEventHandler=function(t){this._core.attachCustomKeyEventHandler(t)},t.prototype.registerLinkMatcher=function(t,e,n){return this._checkProposedApi(),this._core.registerLinkMatcher(t,e,n)},t.prototype.deregisterLinkMatcher=function(t){this._checkProposedApi(),this._core.deregisterLinkMatcher(t)},t.prototype.registerLinkProvider=function(t){return this._checkProposedApi(),this._core.registerLinkProvider(t)},t.prototype.registerCharacterJoiner=function(t){return this._checkProposedApi(),this._core.registerCharacterJoiner(t)},t.prototype.deregisterCharacterJoiner=function(t){this._checkProposedApi(),this._core.deregisterCharacterJoiner(t)},t.prototype.registerMarker=function(t){return this._checkProposedApi(),this._verifyIntegers(t),this._core.addMarker(t)},t.prototype.addMarker=function(t){return this.registerMarker(t)},t.prototype.hasSelection=function(){return this._core.hasSelection()},t.prototype.select=function(t,e,n){this._verifyIntegers(t,e,n),this._core.select(t,e,n)},t.prototype.getSelection=function(){return this._core.getSelection()},t.prototype.getSelectionPosition=function(){return this._core.getSelectionPosition()},t.prototype.clearSelection=function(){this._core.clearSelection()},t.prototype.selectAll=function(){this._core.selectAll()},t.prototype.selectLines=function(t,e){this._verifyIntegers(t,e),this._core.selectLines(t,e)},t.prototype.dispose=function(){this._addonManager.dispose(),this._core.dispose()},t.prototype.scrollLines=function(t){this._verifyIntegers(t),this._core.scrollLines(t)},t.prototype.scrollPages=function(t){this._verifyIntegers(t),this._core.scrollPages(t)},t.prototype.scrollToTop=function(){this._core.scrollToTop()},t.prototype.scrollToBottom=function(){this._core.scrollToBottom()},t.prototype.scrollToLine=function(t){this._verifyIntegers(t),this._core.scrollToLine(t)},t.prototype.clear=function(){this._core.clear()},t.prototype.write=function(t,e){this._core.write(t,e)},t.prototype.writeUtf8=function(t,e){this._core.write(t,e)},t.prototype.writeln=function(t,e){this._core.write(t),this._core.write("\r\n",e)},t.prototype.paste=function(t){this._core.paste(t)},t.prototype.getOption=function(t){return this._core.optionsService.getOption(t)},t.prototype.setOption=function(t,e){this._core.optionsService.setOption(t,e)},t.prototype.refresh=function(t,e){this._verifyIntegers(t,e),this._core.refresh(t,e)},t.prototype.reset=function(){this._core.reset()},t.prototype.loadAddon=function(t){return this._addonManager.loadAddon(this,t)},Object.defineProperty(t,"strings",{get:function(){return o},enumerable:!1,configurable:!0}),t.prototype._verifyIntegers=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var n=0,i=t;n<i.length;n++){var r=i[n];if(r===1/0||isNaN(r)||r%1!=0)throw new Error("This API only accepts integers")}},t}();e.Terminal=c;var l=function(){function t(t,e){this._buffer=t,this.type=e}return t.prototype.init=function(t){return this._buffer=t,this},Object.defineProperty(t.prototype,"cursorY",{get:function(){return this._buffer.y},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cursorX",{get:function(){return this._buffer.x},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"viewportY",{get:function(){return this._buffer.ydisp},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"baseY",{get:function(){return this._buffer.ybase},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"length",{get:function(){return this._buffer.lines.length},enumerable:!1,configurable:!0}),t.prototype.getLine=function(t){var e=this._buffer.lines.get(t);if(e)return new h(e)},t.prototype.getNullCell=function(){return new i.CellData},t}(),u=function(){function t(t){var e=this;this._buffers=t,this._onBufferChange=new a.EventEmitter,this._normal=new l(this._buffers.normal,"normal"),this._alternate=new l(this._buffers.alt,"alternate"),this._buffers.onBufferActivate((function(){return e._onBufferChange.fire(e.active)}))}return Object.defineProperty(t.prototype,"onBufferChange",{get:function(){return this._onBufferChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"active",{get:function(){if(this._buffers.active===this._buffers.normal)return this.normal;if(this._buffers.active===this._buffers.alt)return this.alternate;throw new Error("Active buffer is neither normal nor alternate")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"normal",{get:function(){return this._normal.init(this._buffers.normal)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"alternate",{get:function(){return this._alternate.init(this._buffers.alt)},enumerable:!1,configurable:!0}),t}(),h=function(){function t(t){this._line=t}return Object.defineProperty(t.prototype,"isWrapped",{get:function(){return this._line.isWrapped},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"length",{get:function(){return this._line.length},enumerable:!1,configurable:!0}),t.prototype.getCell=function(t,e){if(!(t<0||t>=this._line.length))return e?(this._line.loadCell(t,e),e):this._line.loadCell(t,new i.CellData)},t.prototype.translateToString=function(t,e,n){return this._line.translateToString(t,e,n)},t}(),d=function(){function t(t){this._core=t}return t.prototype.registerCsiHandler=function(t,e){return this._core.addCsiHandler(t,(function(t){return e(t.toArray())}))},t.prototype.addCsiHandler=function(t,e){return this.registerCsiHandler(t,e)},t.prototype.registerDcsHandler=function(t,e){return this._core.addDcsHandler(t,(function(t,n){return e(t,n.toArray())}))},t.prototype.addDcsHandler=function(t,e){return this.registerDcsHandler(t,e)},t.prototype.registerEscHandler=function(t,e){return this._core.addEscHandler(t,e)},t.prototype.addEscHandler=function(t,e){return this.registerEscHandler(t,e)},t.prototype.registerOscHandler=function(t,e){return this._core.addOscHandler(t,e)},t.prototype.addOscHandler=function(t,e){return this.registerOscHandler(t,e)},t}(),f=function(){function t(t){this._core=t}return t.prototype.register=function(t){this._core.unicodeService.register(t)},Object.defineProperty(t.prototype,"versions",{get:function(){return this._core.unicodeService.versions},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"activeVersion",{get:function(){return this._core.unicodeService.activeVersion},set:function(t){this._core.unicodeService.activeVersion=t},enumerable:!1,configurable:!0}),t}()},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.Terminal=void 0;var o=n(36),a=n(37),s=n(38),c=n(12),l=n(19),u=n(40),h=n(50),d=n(51),f=n(11),p=n(7),m=n(18),g=n(54),v=n(55),b=n(56),y=n(57),_=n(59),w=n(0),k=n(16),C=n(27),S=n(60),x=n(5),O=n(61),M=n(62),T=n(63),E=n(64),P=n(65),A="undefined"!=typeof window?window.document:null,j=function(t){function e(e){void 0===e&&(e={});var n=t.call(this,e)||this;return n.browser=f,n._keyDownHandled=!1,n._onCursorMove=new w.EventEmitter,n._onKey=new w.EventEmitter,n._onRender=new w.EventEmitter,n._onSelectionChange=new w.EventEmitter,n._onTitleChange=new w.EventEmitter,n._onFocus=new w.EventEmitter,n._onBlur=new w.EventEmitter,n._onA11yCharEmitter=new w.EventEmitter,n._onA11yTabEmitter=new w.EventEmitter,n._setup(),n.linkifier=n._instantiationService.createInstance(h.Linkifier),n.linkifier2=n.register(n._instantiationService.createInstance(T.Linkifier2)),n.register(n._inputHandler.onRequestBell((function(){return n.bell()}))),n.register(n._inputHandler.onRequestRefreshRows((function(t,e){return n.refresh(t,e)}))),n.register(n._inputHandler.onRequestReset((function(){return n.reset()}))),n.register(n._inputHandler.onRequestScroll((function(t,e){return n.scroll(t,e||void 0)}))),n.register(n._inputHandler.onRequestWindowsOptionsReport((function(t){return n._reportWindowsOptions(t)}))),n.register(w.forwardEvent(n._inputHandler.onCursorMove,n._onCursorMove)),n.register(w.forwardEvent(n._inputHandler.onTitleChange,n._onTitleChange)),n.register(w.forwardEvent(n._inputHandler.onA11yChar,n._onA11yCharEmitter)),n.register(w.forwardEvent(n._inputHandler.onA11yTab,n._onA11yTabEmitter)),n.register(n._bufferService.onResize((function(t){return n._afterResize(t.cols,t.rows)}))),n}return r(e,t),Object.defineProperty(e.prototype,"options",{get:function(){return this.optionsService.options},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onCursorMove",{get:function(){return this._onCursorMove.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onKey",{get:function(){return this._onKey.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRender",{get:function(){return this._onRender.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onSelectionChange",{get:function(){return this._onSelectionChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onTitleChange",{get:function(){return this._onTitleChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onFocus",{get:function(){return this._onFocus.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onBlur",{get:function(){return this._onBlur.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onA11yChar",{get:function(){return this._onA11yCharEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onA11yTab",{get:function(){return this._onA11yTabEmitter.event},enumerable:!1,configurable:!0}),e.prototype.dispose=function(){var e,n,i;this._isDisposed||(t.prototype.dispose.call(this),null===(e=this._renderService)||void 0===e||e.dispose(),this._customKeyEventHandler=void 0,this.write=function(){},null===(i=null===(n=this.element)||void 0===n?void 0:n.parentNode)||void 0===i||i.removeChild(this.element))},e.prototype._setup=function(){t.prototype._setup.call(this),this._customKeyEventHandler=void 0},Object.defineProperty(e.prototype,"buffer",{get:function(){return this.buffers.active},enumerable:!1,configurable:!0}),e.prototype.focus=function(){this.textarea&&this.textarea.focus({preventScroll:!0})},e.prototype._updateOptions=function(e){var n,i,r,o;switch(t.prototype._updateOptions.call(this,e),e){case"fontFamily":case"fontSize":null===(n=this._renderService)||void 0===n||n.clear(),null===(i=this._charSizeService)||void 0===i||i.measure();break;case"cursorBlink":case"cursorStyle":this.refresh(this.buffer.y,this.buffer.y);break;case"drawBoldTextInBrightColors":case"letterSpacing":case"lineHeight":case"fontWeight":case"fontWeightBold":case"minimumContrastRatio":this._renderService&&(this._renderService.clear(),this._renderService.onResize(this.cols,this.rows),this.refresh(0,this.rows-1));break;case"rendererType":this._renderService&&(this._renderService.setRenderer(this._createRenderer()),this._renderService.onResize(this.cols,this.rows));break;case"scrollback":null===(r=this.viewport)||void 0===r||r.syncScrollArea();break;case"screenReaderMode":this.optionsService.options.screenReaderMode?!this._accessibilityManager&&this._renderService&&(this._accessibilityManager=new b.AccessibilityManager(this,this._renderService)):(null===(o=this._accessibilityManager)||void 0===o||o.dispose(),this._accessibilityManager=void 0);break;case"tabStopWidth":this.buffers.setupTabStops();break;case"theme":this._setTheme(this.optionsService.options.theme)}},e.prototype._onTextAreaFocus=function(t){this._coreService.decPrivateModes.sendFocus&&this._coreService.triggerDataEvent(c.C0.ESC+"[I"),this.updateCursorStyle(t),this.element.classList.add("focus"),this._showCursor(),this._onFocus.fire()},e.prototype.blur=function(){var t;return null===(t=this.textarea)||void 0===t?void 0:t.blur()},e.prototype._onTextAreaBlur=function(){this.textarea.value="",this.refresh(this.buffer.y,this.buffer.y),this._coreService.decPrivateModes.sendFocus&&this._coreService.triggerDataEvent(c.C0.ESC+"[O"),this.element.classList.remove("focus"),this._onBlur.fire()},e.prototype._syncTextArea=function(){if(this.textarea&&this.buffer.isCursorInViewport&&!this._compositionHelper.isComposing){var t=Math.ceil(this._charSizeService.height*this.optionsService.options.lineHeight),e=this._bufferService.buffer.y*t;this.textarea.style.left=this._bufferService.buffer.x*this._charSizeService.width+"px",this.textarea.style.top=e+"px",this.textarea.style.width=this._charSizeService.width+"px",this.textarea.style.height=t+"px",this.textarea.style.lineHeight=t+"px",this.textarea.style.zIndex="-5"}},e.prototype._initGlobal=function(){var t=this;this._bindKeys(),this.register(p.addDisposableDomListener(this.element,"copy",(function(e){t.hasSelection()&&s.copyHandler(e,t._selectionService)})));var e=function(e){return s.handlePasteEvent(e,t.textarea,t._coreService)};this.register(p.addDisposableDomListener(this.textarea,"paste",e)),this.register(p.addDisposableDomListener(this.element,"paste",e)),this.register(f.isFirefox?p.addDisposableDomListener(this.element,"mousedown",(function(e){2===e.button&&s.rightClickHandler(e,t.textarea,t.screenElement,t._selectionService,t.options.rightClickSelectsWord)})):p.addDisposableDomListener(this.element,"contextmenu",(function(e){s.rightClickHandler(e,t.textarea,t.screenElement,t._selectionService,t.options.rightClickSelectsWord)}))),f.isLinux&&this.register(p.addDisposableDomListener(this.element,"auxclick",(function(e){1===e.button&&s.moveTextAreaUnderMouseCursor(e,t.textarea,t.screenElement)})))},e.prototype._bindKeys=function(){var t=this;this.register(p.addDisposableDomListener(this.textarea,"keyup",(function(e){return t._keyUp(e)}),!0)),this.register(p.addDisposableDomListener(this.textarea,"keydown",(function(e){return t._keyDown(e)}),!0)),this.register(p.addDisposableDomListener(this.textarea,"keypress",(function(e){return t._keyPress(e)}),!0)),this.register(p.addDisposableDomListener(this.textarea,"compositionstart",(function(){return t._compositionHelper.compositionstart()}))),this.register(p.addDisposableDomListener(this.textarea,"compositionupdate",(function(e){return t._compositionHelper.compositionupdate(e)}))),this.register(p.addDisposableDomListener(this.textarea,"compositionend",(function(){return t._compositionHelper.compositionend()}))),this.register(this.onRender((function(){return t._compositionHelper.updateCompositionElements()}))),this.register(this.onRender((function(e){return t._queueLinkification(e.start,e.end)})))},e.prototype.open=function(t){var e=this;if(!t)throw new Error("Terminal requires a parent element.");A.body.contains(t)||this._logService.debug("Terminal.open was called on an element that was not attached to the DOM"),this._document=t.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"),t.appendChild(this.element);var n=A.createDocumentFragment();this._viewportElement=A.createElement("div"),this._viewportElement.classList.add("xterm-viewport"),n.appendChild(this._viewportElement),this._viewportScrollArea=A.createElement("div"),this._viewportScrollArea.classList.add("xterm-scroll-area"),this._viewportElement.appendChild(this._viewportScrollArea),this.screenElement=A.createElement("div"),this.screenElement.classList.add("xterm-screen"),this._helperContainer=A.createElement("div"),this._helperContainer.classList.add("xterm-helpers"),this.screenElement.appendChild(this._helperContainer),n.appendChild(this.screenElement),this.textarea=A.createElement("textarea"),this.textarea.classList.add("xterm-helper-textarea"),this.textarea.setAttribute("aria-label",m.promptLabel),this.textarea.setAttribute("aria-multiline","false"),this.textarea.setAttribute("autocorrect","off"),this.textarea.setAttribute("autocapitalize","off"),this.textarea.setAttribute("spellcheck","false"),this.textarea.tabIndex=0,this.register(p.addDisposableDomListener(this.textarea,"focus",(function(t){return e._onTextAreaFocus(t)}))),this.register(p.addDisposableDomListener(this.textarea,"blur",(function(){return e._onTextAreaBlur()}))),this._helperContainer.appendChild(this.textarea);var i=this._instantiationService.createInstance(E.CoreBrowserService,this.textarea);this._instantiationService.setService(x.ICoreBrowserService,i),this._charSizeService=this._instantiationService.createInstance(O.CharSizeService,this._document,this._helperContainer),this._instantiationService.setService(x.ICharSizeService,this._charSizeService),this._compositionView=A.createElement("div"),this._compositionView.classList.add("composition-view"),this._compositionHelper=this._instantiationService.createInstance(o.CompositionHelper,this.textarea,this._compositionView),this._helperContainer.appendChild(this._compositionView),this.element.appendChild(n),this._theme=this.options.theme||this._theme,this._colorManager=new C.ColorManager(A,this.options.allowTransparency),this.register(this.optionsService.onOptionChange((function(t){return e._colorManager.onOptionsChange(t)}))),this._colorManager.setTheme(this._theme);var r=this._createRenderer();this._renderService=this.register(this._instantiationService.createInstance(S.RenderService,r,this.rows,this.screenElement)),this._instantiationService.setService(x.IRenderService,this._renderService),this.register(this._renderService.onRenderedBufferChange((function(t){return e._onRender.fire(t)}))),this.onResize((function(t){return e._renderService.resize(t.cols,t.rows)})),this._soundService=this._instantiationService.createInstance(g.SoundService),this._instantiationService.setService(x.ISoundService,this._soundService),this._mouseService=this._instantiationService.createInstance(M.MouseService),this._instantiationService.setService(x.IMouseService,this._mouseService),this.viewport=this._instantiationService.createInstance(a.Viewport,(function(t,n){return e.scrollLines(t,n)}),this._viewportElement,this._viewportScrollArea),this.viewport.onThemeChange(this._colorManager.colors),this.register(this._inputHandler.onRequestSyncScrollBar((function(){return e.viewport.syncScrollArea()}))),this.register(this.viewport),this.register(this.onCursorMove((function(){e._renderService.onCursorMove(),e._syncTextArea()}))),this.register(this.onResize((function(){return e._renderService.onResize(e.cols,e.rows)}))),this.register(this.onBlur((function(){return e._renderService.onBlur()}))),this.register(this.onFocus((function(){return e._renderService.onFocus()}))),this.register(this._renderService.onDimensionsChange((function(){return e.viewport.syncScrollArea()}))),this._selectionService=this.register(this._instantiationService.createInstance(d.SelectionService,this.element,this.screenElement)),this._instantiationService.setService(x.ISelectionService,this._selectionService),this.register(this._selectionService.onRequestScrollLines((function(t){return e.scrollLines(t.amount,t.suppressScrollEvent)}))),this.register(this._selectionService.onSelectionChange((function(){return e._onSelectionChange.fire()}))),this.register(this._selectionService.onRequestRedraw((function(t){return e._renderService.onSelectionChanged(t.start,t.end,t.columnSelectMode)}))),this.register(this._selectionService.onLinuxMouseSelection((function(t){e.textarea.value=t,e.textarea.focus(),e.textarea.select()}))),this.register(this.onScroll((function(){e.viewport.syncScrollArea(),e._selectionService.refresh()}))),this.register(p.addDisposableDomListener(this._viewportElement,"scroll",(function(){return e._selectionService.refresh()}))),this._mouseZoneManager=this._instantiationService.createInstance(v.MouseZoneManager,this.element,this.screenElement),this.register(this._mouseZoneManager),this.register(this.onScroll((function(){return e._mouseZoneManager.clearAll()}))),this.linkifier.attachToDom(this.element,this._mouseZoneManager),this.linkifier2.attachToDom(this.element,this._mouseService,this._renderService),this.register(p.addDisposableDomListener(this.element,"mousedown",(function(t){return e._selectionService.onMouseDown(t)}))),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._charSizeService.measure(),this.refresh(0,this.rows-1),this._initGlobal(),this.bindMouse()},e.prototype._createRenderer=function(){switch(this.options.rendererType){case"canvas":return this._instantiationService.createInstance(u.Renderer,this._colorManager.colors,this.screenElement,this.linkifier,this.linkifier2);case"dom":return this._instantiationService.createInstance(y.DomRenderer,this._colorManager.colors,this.element,this.screenElement,this._viewportElement,this.linkifier,this.linkifier2);default:throw new Error('Unrecognized rendererType "'+this.options.rendererType+'"')}},e.prototype._setTheme=function(t){var e,n,i;this._theme=t,null===(e=this._colorManager)||void 0===e||e.setTheme(t),null===(n=this._renderService)||void 0===n||n.setColors(this._colorManager.colors),null===(i=this.viewport)||void 0===i||i.onThemeChange(this._colorManager.colors)},e.prototype.bindMouse=function(){var t=this,e=this,n=this.element;function i(t){var n,i,r=e._mouseService.getRawByteCoords(t,e.screenElement,e.cols,e.rows);if(!r)return!1;switch(t.overrideType||t.type){case"mousemove":i=32,void 0===t.buttons?(n=3,void 0!==t.button&&(n=t.button<3?t.button:3)):n=1&t.buttons?0:4&t.buttons?1:2&t.buttons?2:3;break;case"mouseup":i=0,n=t.button<3?t.button:3;break;case"mousedown":i=1,n=t.button<3?t.button:3;break;case"wheel":0!==t.deltaY&&(i=t.deltaY<0?0:1),n=4;break;default:return!1}return!(void 0===i||void 0===n||n>4)&&e._coreMouseService.triggerMouseEvent({col:r.x-33,row:r.y-33,button:n,action:i,ctrl:t.ctrlKey,alt:t.altKey,shift:t.shiftKey})}var r={mouseup:null,wheel:null,mousedrag:null,mousemove:null},o=function(e){return i(e),e.buttons||(t._document.removeEventListener("mouseup",r.mouseup),r.mousedrag&&t._document.removeEventListener("mousemove",r.mousedrag)),t.cancel(e)},a=function(e){return i(e),e.preventDefault(),t.cancel(e)},s=function(t){t.buttons&&i(t)},l=function(t){t.buttons||i(t)};this.register(this._coreMouseService.onProtocolChange((function(e){e?("debug"===t.optionsService.options.logLevel&&t._logService.debug("Binding to mouse events:",t._coreMouseService.explainEvents(e)),t.element.classList.add("enable-mouse-events"),t._selectionService.disable()):(t._logService.debug("Unbinding from mouse events."),t.element.classList.remove("enable-mouse-events"),t._selectionService.enable()),8&e?r.mousemove||(n.addEventListener("mousemove",l),r.mousemove=l):(n.removeEventListener("mousemove",r.mousemove),r.mousemove=null),16&e?r.wheel||(n.addEventListener("wheel",a,{passive:!1}),r.wheel=a):(n.removeEventListener("wheel",r.wheel),r.wheel=null),2&e?r.mouseup||(r.mouseup=o):(t._document.removeEventListener("mouseup",r.mouseup),r.mouseup=null),4&e?r.mousedrag||(r.mousedrag=s):(t._document.removeEventListener("mousemove",r.mousedrag),r.mousedrag=null)}))),this._coreMouseService.activeProtocol=this._coreMouseService.activeProtocol,this.register(p.addDisposableDomListener(n,"mousedown",(function(e){if(e.preventDefault(),t.focus(),t._coreMouseService.areMouseEventsActive&&!t._selectionService.shouldForceSelection(e))return i(e),r.mouseup&&t._document.addEventListener("mouseup",r.mouseup),r.mousedrag&&t._document.addEventListener("mousemove",r.mousedrag),t.cancel(e)}))),this.register(p.addDisposableDomListener(n,"wheel",(function(e){if(r.wheel);else if(!t.buffer.hasScrollback){var n=t.viewport.getLinesScrolled(e);if(0===n)return;for(var i=c.C0.ESC+(t._coreService.decPrivateModes.applicationCursorKeys?"O":"[")+(e.deltaY<0?"A":"B"),o="",a=0;a<Math.abs(n);a++)o+=i;t._coreService.triggerDataEvent(o,!0)}}),{passive:!0})),this.register(p.addDisposableDomListener(n,"wheel",(function(e){if(!r.wheel)return t.viewport.onWheel(e)?void 0:t.cancel(e)}),{passive:!1})),this.register(p.addDisposableDomListener(n,"touchstart",(function(e){if(!t._coreMouseService.areMouseEventsActive)return t.viewport.onTouchStart(e),t.cancel(e)}),{passive:!0})),this.register(p.addDisposableDomListener(n,"touchmove",(function(e){if(!t._coreMouseService.areMouseEventsActive)return t.viewport.onTouchMove(e)?void 0:t.cancel(e)}),{passive:!1}))},e.prototype.refresh=function(t,e){var n;null===(n=this._renderService)||void 0===n||n.refreshRows(t,e)},e.prototype._queueLinkification=function(t,e){var n;null===(n=this.linkifier)||void 0===n||n.linkifyRows(t,e)},e.prototype.updateCursorStyle=function(t){this._selectionService&&this._selectionService.shouldColumnSelect(t)?this.element.classList.add("column-select"):this.element.classList.remove("column-select")},e.prototype._showCursor=function(){this._coreService.isCursorInitialized||(this._coreService.isCursorInitialized=!0,this.refresh(this.buffer.y,this.buffer.y))},e.prototype.scrollLines=function(e,n){t.prototype.scrollLines.call(this,e,n),this.refresh(0,this.rows-1)},e.prototype.paste=function(t){s.paste(t,this.textarea,this._coreService)},e.prototype.attachCustomKeyEventHandler=function(t){this._customKeyEventHandler=t},e.prototype.registerLinkMatcher=function(t,e,n){var i=this.linkifier.registerLinkMatcher(t,e,n);return this.refresh(0,this.rows-1),i},e.prototype.deregisterLinkMatcher=function(t){this.linkifier.deregisterLinkMatcher(t)&&this.refresh(0,this.rows-1)},e.prototype.registerLinkProvider=function(t){return this.linkifier2.registerLinkProvider(t)},e.prototype.registerCharacterJoiner=function(t){var e=this._renderService.registerCharacterJoiner(t);return this.refresh(0,this.rows-1),e},e.prototype.deregisterCharacterJoiner=function(t){this._renderService.deregisterCharacterJoiner(t)&&this.refresh(0,this.rows-1)},Object.defineProperty(e.prototype,"markers",{get:function(){return this.buffer.markers},enumerable:!1,configurable:!0}),e.prototype.addMarker=function(t){if(this.buffer===this.buffers.normal)return this.buffer.addMarker(this.buffer.ybase+this.buffer.y+t)},e.prototype.hasSelection=function(){return!!this._selectionService&&this._selectionService.hasSelection},e.prototype.select=function(t,e,n){this._selectionService.setSelection(t,e,n)},e.prototype.getSelection=function(){return this._selectionService?this._selectionService.selectionText:""},e.prototype.getSelectionPosition=function(){if(this._selectionService&&this._selectionService.hasSelection)return{startColumn:this._selectionService.selectionStart[0],startRow:this._selectionService.selectionStart[1],endColumn:this._selectionService.selectionEnd[0],endRow:this._selectionService.selectionEnd[1]}},e.prototype.clearSelection=function(){var t;null===(t=this._selectionService)||void 0===t||t.clearSelection()},e.prototype.selectAll=function(){var t;null===(t=this._selectionService)||void 0===t||t.selectAll()},e.prototype.selectLines=function(t,e){var n;null===(n=this._selectionService)||void 0===n||n.selectLines(t,e)},e.prototype._keyDown=function(t){if(this._keyDownHandled=!1,this._customKeyEventHandler&&!1===this._customKeyEventHandler(t))return!1;if(!this._compositionHelper.keydown(t))return this.buffer.ybase!==this.buffer.ydisp&&this.scrollToBottom(),!1;var e=_.evaluateKeyboardEvent(t,this._coreService.decPrivateModes.applicationCursorKeys,this.browser.isMac,this.options.macOptionIsMeta);if(this.updateCursorStyle(t),3===e.type||2===e.type){var n=this.rows-1;return this.scrollLines(2===e.type?-n:n),this.cancel(t,!0)}return 1===e.type&&this.selectAll(),!!this._isThirdLevelShift(this.browser,t)||(e.cancel&&this.cancel(t,!0),!e.key||(e.key!==c.C0.ETX&&e.key!==c.C0.CR||(this.textarea.value=""),this._onKey.fire({key:e.key,domEvent:t}),this._showCursor(),this._coreService.triggerDataEvent(e.key,!0),this.optionsService.options.screenReaderMode?void(this._keyDownHandled=!0):this.cancel(t,!0)))},e.prototype._isThirdLevelShift=function(t,e){var n=t.isMac&&!this.options.macOptionIsMeta&&e.altKey&&!e.ctrlKey&&!e.metaKey||t.isWindows&&e.altKey&&e.ctrlKey&&!e.metaKey;return"keypress"===e.type?n:n&&(!e.keyCode||e.keyCode>47)},e.prototype._keyUp=function(t){this._customKeyEventHandler&&!1===this._customKeyEventHandler(t)||(function(t){return 16===t.keyCode||17===t.keyCode||18===t.keyCode}(t)||this.focus(),this.updateCursorStyle(t))},e.prototype._keyPress=function(t){var e;if(this._keyDownHandled)return!1;if(this._customKeyEventHandler&&!1===this._customKeyEventHandler(t))return!1;if(this.cancel(t),t.charCode)e=t.charCode;else if(null==t.which)e=t.keyCode;else{if(0===t.which||0===t.charCode)return!1;e=t.which}return!(!e||(t.altKey||t.ctrlKey||t.metaKey)&&!this._isThirdLevelShift(this.browser,t)||(e=String.fromCharCode(e),this._onKey.fire({key:e,domEvent:t}),this._showCursor(),this._coreService.triggerDataEvent(e,!0),0))},e.prototype.bell=function(){this._soundBell()&&this._soundService.playBellSound()},e.prototype.resize=function(e,n){e!==this.cols||n!==this.rows?t.prototype.resize.call(this,e,n):this._charSizeService&&!this._charSizeService.hasValidSize&&this._charSizeService.measure()},e.prototype._afterResize=function(t,e){var n,i;null===(n=this._charSizeService)||void 0===n||n.measure(),null===(i=this.viewport)||void 0===i||i.syncScrollArea(!0)},e.prototype.clear=function(){if(0!==this.buffer.ybase||0!==this.buffer.y){this.buffer.lines.set(0,this.buffer.lines.get(this.buffer.ybase+this.buffer.y)),this.buffer.lines.length=1,this.buffer.ydisp=0,this.buffer.ybase=0,this.buffer.y=0;for(var t=1;t<this.rows;t++)this.buffer.lines.push(this.buffer.getBlankLine(k.DEFAULT_ATTR_DATA));this.refresh(0,this.rows-1),this._onScroll.fire(this.buffer.ydisp)}},e.prototype.reset=function(){var e,n;this.options.rows=this.rows,this.options.cols=this.cols;var i=this._customKeyEventHandler;this._setup(),t.prototype.reset.call(this),null===(e=this._selectionService)||void 0===e||e.reset(),this._customKeyEventHandler=i,this.refresh(0,this.rows-1),null===(n=this.viewport)||void 0===n||n.syncScrollArea()},e.prototype._reportWindowsOptions=function(t){if(this._renderService)switch(t){case l.WindowsOptionsReportType.GET_WIN_SIZE_PIXELS:var e=this._renderService.dimensions.scaledCanvasWidth.toFixed(0),n=this._renderService.dimensions.scaledCanvasHeight.toFixed(0);this._coreService.triggerDataEvent(c.C0.ESC+"[4;"+n+";"+e+"t");break;case l.WindowsOptionsReportType.GET_CELL_SIZE_PIXELS:var i=this._renderService.dimensions.scaledCellWidth.toFixed(0),r=this._renderService.dimensions.scaledCellHeight.toFixed(0);this._coreService.triggerDataEvent(c.C0.ESC+"[6;"+r+";"+i+"t")}},e.prototype.cancel=function(t,e){if(this.options.cancelEvents||e)return t.preventDefault(),t.stopPropagation(),!1},e.prototype._visualBell=function(){return!1},e.prototype._soundBell=function(){return"sound"===this.options.bellStyle},e}(P.CoreTerminal);e.Terminal=j},function(t,e,n){"use strict";var i=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},r=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.CompositionHelper=void 0;var o=n(5),a=n(1),s=function(){function t(t,e,n,i,r,o){this._textarea=t,this._compositionView=e,this._bufferService=n,this._optionsService=i,this._charSizeService=r,this._coreService=o,this._isComposing=!1,this._isSendingComposition=!1,this._compositionPosition={start:0,end:0}}return Object.defineProperty(t.prototype,"isComposing",{get:function(){return this._isComposing},enumerable:!1,configurable:!0}),t.prototype.compositionstart=function(){this._isComposing=!0,this._compositionPosition.start=this._textarea.value.length,this._compositionView.textContent="",this._compositionView.classList.add("active")},t.prototype.compositionupdate=function(t){var e=this;this._compositionView.textContent=t.data,this.updateCompositionElements(),setTimeout((function(){e._compositionPosition.end=e._textarea.value.length}),0)},t.prototype.compositionend=function(){this._finalizeComposition(!0)},t.prototype.keydown=function(t){if(this._isComposing||this._isSendingComposition){if(229===t.keyCode)return!1;if(16===t.keyCode||17===t.keyCode||18===t.keyCode)return!1;this._finalizeComposition(!1)}return 229!==t.keyCode||(this._handleAnyTextareaChanges(),!1)},t.prototype._finalizeComposition=function(t){var e=this;if(this._compositionView.classList.remove("active"),this._isComposing=!1,t){var n={start:this._compositionPosition.start,end:this._compositionPosition.end};this._isSendingComposition=!0,setTimeout((function(){var t;e._isSendingComposition&&(e._isSendingComposition=!1,t=e._isComposing?e._textarea.value.substring(n.start,n.end):e._textarea.value.substring(n.start),e._coreService.triggerDataEvent(t,!0))}),0)}else{this._isSendingComposition=!1;var i=this._textarea.value.substring(this._compositionPosition.start,this._compositionPosition.end);this._coreService.triggerDataEvent(i,!0)}},t.prototype._handleAnyTextareaChanges=function(){var t=this,e=this._textarea.value;setTimeout((function(){if(!t._isComposing){var n=t._textarea.value.replace(e,"");n.length>0&&t._coreService.triggerDataEvent(n,!0)}}),0)},t.prototype.updateCompositionElements=function(t){var e=this;if(this._isComposing){if(this._bufferService.buffer.isCursorInViewport){var n=Math.ceil(this._charSizeService.height*this._optionsService.options.lineHeight),i=this._bufferService.buffer.y*n,r=this._bufferService.buffer.x*this._charSizeService.width;this._compositionView.style.left=r+"px",this._compositionView.style.top=i+"px",this._compositionView.style.height=n+"px",this._compositionView.style.lineHeight=n+"px",this._compositionView.style.fontFamily=this._optionsService.options.fontFamily,this._compositionView.style.fontSize=this._optionsService.options.fontSize+"px";var o=this._compositionView.getBoundingClientRect();this._textarea.style.left=r+"px",this._textarea.style.top=i+"px",this._textarea.style.width=o.width+"px",this._textarea.style.height=o.height+"px",this._textarea.style.lineHeight=o.height+"px"}t||setTimeout((function(){return e.updateCompositionElements(!0)}),0)}},i([r(2,a.IBufferService),r(3,a.IOptionsService),r(4,o.ICharSizeService),r(5,a.ICoreService)],t)}();e.CompositionHelper=s},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.Viewport=void 0;var s=n(2),c=n(7),l=n(5),u=n(1),h=function(t){function e(e,n,i,r,o,a,s){var l=t.call(this)||this;return l._scrollLines=e,l._viewportElement=n,l._scrollArea=i,l._bufferService=r,l._optionsService=o,l._charSizeService=a,l._renderService=s,l.scrollBarWidth=0,l._currentRowHeight=0,l._lastRecordedBufferLength=0,l._lastRecordedViewportHeight=0,l._lastRecordedBufferHeight=0,l._lastTouchY=0,l._lastScrollTop=0,l._wheelPartialScroll=0,l._refreshAnimationFrame=null,l._ignoreNextScrollEvent=!1,l.scrollBarWidth=l._viewportElement.offsetWidth-l._scrollArea.offsetWidth||15,l.register(c.addDisposableDomListener(l._viewportElement,"scroll",l._onScroll.bind(l))),setTimeout((function(){return l.syncScrollArea()}),0),l}return r(e,t),e.prototype.onThemeChange=function(t){this._viewportElement.style.backgroundColor=t.background.css},e.prototype._refresh=function(t){var e=this;if(t)return this._innerRefresh(),void(null!==this._refreshAnimationFrame&&cancelAnimationFrame(this._refreshAnimationFrame));null===this._refreshAnimationFrame&&(this._refreshAnimationFrame=requestAnimationFrame((function(){return e._innerRefresh()})))},e.prototype._innerRefresh=function(){if(this._charSizeService.height>0){this._currentRowHeight=this._renderService.dimensions.scaledCellHeight/window.devicePixelRatio,this._lastRecordedViewportHeight=this._viewportElement.offsetHeight;var t=Math.round(this._currentRowHeight*this._lastRecordedBufferLength)+(this._lastRecordedViewportHeight-this._renderService.dimensions.canvasHeight);this._lastRecordedBufferHeight!==t&&(this._lastRecordedBufferHeight=t,this._scrollArea.style.height=this._lastRecordedBufferHeight+"px")}var e=this._bufferService.buffer.ydisp*this._currentRowHeight;this._viewportElement.scrollTop!==e&&(this._ignoreNextScrollEvent=!0,this._viewportElement.scrollTop=e),this._refreshAnimationFrame=null},e.prototype.syncScrollArea=function(t){if(void 0===t&&(t=!1),this._lastRecordedBufferLength!==this._bufferService.buffer.lines.length)return this._lastRecordedBufferLength=this._bufferService.buffer.lines.length,void this._refresh(t);this._lastRecordedViewportHeight===this._renderService.dimensions.canvasHeight&&this._lastScrollTop===this._bufferService.buffer.ydisp*this._currentRowHeight&&this._lastScrollTop===this._viewportElement.scrollTop&&this._renderService.dimensions.scaledCellHeight/window.devicePixelRatio===this._currentRowHeight||this._refresh(t)},e.prototype._onScroll=function(t){if(this._lastScrollTop=this._viewportElement.scrollTop,this._viewportElement.offsetParent)if(this._ignoreNextScrollEvent)this._ignoreNextScrollEvent=!1;else{var e=Math.round(this._lastScrollTop/this._currentRowHeight)-this._bufferService.buffer.ydisp;this._scrollLines(e,!0)}},e.prototype._bubbleScroll=function(t,e){return!(e<0&&0!==this._viewportElement.scrollTop||e>0&&this._viewportElement.scrollTop+this._lastRecordedViewportHeight<this._lastRecordedBufferHeight)||(t.cancelable&&t.preventDefault(),!1)},e.prototype.onWheel=function(t){var e=this._getPixelsScrolled(t);return 0!==e&&(this._viewportElement.scrollTop+=e,this._bubbleScroll(t,e))},e.prototype._getPixelsScrolled=function(t){if(0===t.deltaY)return 0;var e=this._applyScrollModifier(t.deltaY,t);return t.deltaMode===WheelEvent.DOM_DELTA_LINE?e*=this._currentRowHeight:t.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(e*=this._currentRowHeight*this._bufferService.rows),e},e.prototype.getLinesScrolled=function(t){if(0===t.deltaY)return 0;var e=this._applyScrollModifier(t.deltaY,t);return t.deltaMode===WheelEvent.DOM_DELTA_PIXEL?(this._wheelPartialScroll+=e/=this._currentRowHeight+0,e=Math.floor(Math.abs(this._wheelPartialScroll))*(this._wheelPartialScroll>0?1:-1),this._wheelPartialScroll%=1):t.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(e*=this._bufferService.rows),e},e.prototype._applyScrollModifier=function(t,e){var n=this._optionsService.options.fastScrollModifier;return"alt"===n&&e.altKey||"ctrl"===n&&e.ctrlKey||"shift"===n&&e.shiftKey?t*this._optionsService.options.fastScrollSensitivity*this._optionsService.options.scrollSensitivity:t*this._optionsService.options.scrollSensitivity},e.prototype.onTouchStart=function(t){this._lastTouchY=t.touches[0].pageY},e.prototype.onTouchMove=function(t){var e=this._lastTouchY-t.touches[0].pageY;return this._lastTouchY=t.touches[0].pageY,0!==e&&(this._viewportElement.scrollTop+=e,this._bubbleScroll(t,e))},o([a(3,u.IBufferService),a(4,u.IOptionsService),a(5,l.ICharSizeService),a(6,l.IRenderService)],e)}(s.Disposable);e.Viewport=h},function(t,e,n){"use strict";function i(t){return t.replace(/\r?\n/g,"\r")}function r(t,e){return e?"\x1b[200~"+t+"\x1b[201~":t}function o(t,e,n){t=r(t=i(t),n.decPrivateModes.bracketedPasteMode),n.triggerDataEvent(t,!0),e.value=""}function a(t,e,n){var i=n.getBoundingClientRect(),r=t.clientX-i.left-10,o=t.clientY-i.top-10;e.style.width="20px",e.style.height="20px",e.style.left=r+"px",e.style.top=o+"px",e.style.zIndex="1000",e.focus()}Object.defineProperty(e,"__esModule",{value:!0}),e.rightClickHandler=e.moveTextAreaUnderMouseCursor=e.paste=e.handlePasteEvent=e.copyHandler=e.bracketTextForPaste=e.prepareTextForTerminal=void 0,e.prepareTextForTerminal=i,e.bracketTextForPaste=r,e.copyHandler=function(t,e){t.clipboardData&&t.clipboardData.setData("text/plain",e.selectionText),t.preventDefault()},e.handlePasteEvent=function(t,e,n){t.stopPropagation(),t.clipboardData&&o(t.clipboardData.getData("text/plain"),e,n)},e.paste=o,e.moveTextAreaUnderMouseCursor=a,e.rightClickHandler=function(t,e,n,i,r){a(t,e,n),r&&!i.isClickInSelection(t)&&i.selectWordAtCursor(t),e.value=i.selectionText,e.select()}},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.EscapeSequenceParser=e.VT500_TRANSITION_TABLE=e.TransitionTable=void 0;var o=n(2),a=n(15),s=n(21),c=n(22),l=n(24),u=function(){function t(t){this.table=new Uint8Array(t)}return t.prototype.setDefault=function(t,e){a.fill(this.table,t<<4|e)},t.prototype.add=function(t,e,n,i){this.table[e<<8|t]=n<<4|i},t.prototype.addMany=function(t,e,n,i){for(var r=0;r<t.length;r++)this.table[e<<8|t[r]]=n<<4|i},t}();e.TransitionTable=u,e.VT500_TRANSITION_TABLE=function(){var t=new u(4095),e=Array.apply(null,Array(256)).map((function(t,e){return e})),n=function(t,n){return e.slice(t,n)},i=n(32,127),r=n(0,24);r.push(25),r.push.apply(r,n(28,32));var o,a=n(0,14);for(o in t.setDefault(1,0),t.addMany(i,0,2,0),a)t.addMany([24,26,153,154],o,3,0),t.addMany(n(128,144),o,3,0),t.addMany(n(144,152),o,3,0),t.add(156,o,0,0),t.add(27,o,11,1),t.add(157,o,4,8),t.addMany([152,158,159],o,0,7),t.add(155,o,11,3),t.add(144,o,11,9);return t.addMany(r,0,3,0),t.addMany(r,1,3,1),t.add(127,1,0,1),t.addMany(r,8,0,8),t.addMany(r,3,3,3),t.add(127,3,0,3),t.addMany(r,4,3,4),t.add(127,4,0,4),t.addMany(r,6,3,6),t.addMany(r,5,3,5),t.add(127,5,0,5),t.addMany(r,2,3,2),t.add(127,2,0,2),t.add(93,1,4,8),t.addMany(i,8,5,8),t.add(127,8,5,8),t.addMany([156,27,24,26,7],8,6,0),t.addMany(n(28,32),8,0,8),t.addMany([88,94,95],1,0,7),t.addMany(i,7,0,7),t.addMany(r,7,0,7),t.add(156,7,0,0),t.add(127,7,0,7),t.add(91,1,11,3),t.addMany(n(64,127),3,7,0),t.addMany(n(48,60),3,8,4),t.addMany([60,61,62,63],3,9,4),t.addMany(n(48,60),4,8,4),t.addMany(n(64,127),4,7,0),t.addMany([60,61,62,63],4,0,6),t.addMany(n(32,64),6,0,6),t.add(127,6,0,6),t.addMany(n(64,127),6,0,0),t.addMany(n(32,48),3,9,5),t.addMany(n(32,48),5,9,5),t.addMany(n(48,64),5,0,6),t.addMany(n(64,127),5,7,0),t.addMany(n(32,48),4,9,5),t.addMany(n(32,48),1,9,2),t.addMany(n(32,48),2,9,2),t.addMany(n(48,127),2,10,0),t.addMany(n(48,80),1,10,0),t.addMany(n(81,88),1,10,0),t.addMany([89,90,92],1,10,0),t.addMany(n(96,127),1,10,0),t.add(80,1,11,9),t.addMany(r,9,0,9),t.add(127,9,0,9),t.addMany(n(28,32),9,0,9),t.addMany(n(32,48),9,9,12),t.addMany(n(48,60),9,8,10),t.addMany([60,61,62,63],9,9,10),t.addMany(r,11,0,11),t.addMany(n(32,128),11,0,11),t.addMany(n(28,32),11,0,11),t.addMany(r,10,0,10),t.add(127,10,0,10),t.addMany(n(28,32),10,0,10),t.addMany(n(48,60),10,8,10),t.addMany([60,61,62,63],10,0,11),t.addMany(n(32,48),10,9,12),t.addMany(r,12,0,12),t.add(127,12,0,12),t.addMany(n(28,32),12,0,12),t.addMany(n(32,48),12,9,12),t.addMany(n(48,64),12,0,11),t.addMany(n(64,127),12,12,13),t.addMany(n(64,127),10,12,13),t.addMany(n(64,127),9,12,13),t.addMany(r,13,13,13),t.addMany(i,13,13,13),t.add(127,13,0,13),t.addMany([27,156,24,26],13,14,0),t.add(160,0,2,0),t.add(160,8,5,8),t.add(160,6,0,6),t.add(160,11,0,11),t.add(160,13,13,13),t}();var h=function(t){function n(n){void 0===n&&(n=e.VT500_TRANSITION_TABLE);var i=t.call(this)||this;return i._transitions=n,i.initialState=0,i.currentState=i.initialState,i._params=new s.Params,i._params.addParam(0),i._collect=0,i.precedingCodepoint=0,i._printHandlerFb=function(t,e,n){},i._executeHandlerFb=function(t){},i._csiHandlerFb=function(t,e){},i._escHandlerFb=function(t){},i._errorHandlerFb=function(t){return t},i._printHandler=i._printHandlerFb,i._executeHandlers=Object.create(null),i._csiHandlers=Object.create(null),i._escHandlers=Object.create(null),i._oscParser=new c.OscParser,i._dcsParser=new l.DcsParser,i._errorHandler=i._errorHandlerFb,i.setEscHandler({final:"\\"},(function(){})),i}return r(n,t),n.prototype._identifier=function(t,e){void 0===e&&(e=[64,126]);var n=0;if(t.prefix){if(t.prefix.length>1)throw new Error("only one byte as prefix supported");if((n=t.prefix.charCodeAt(0))&&60>n||n>63)throw new Error("prefix must be in range 0x3c .. 0x3f")}if(t.intermediates){if(t.intermediates.length>2)throw new Error("only two bytes as intermediates are supported");for(var i=0;i<t.intermediates.length;++i){var r=t.intermediates.charCodeAt(i);if(32>r||r>47)throw new Error("intermediate must be in range 0x20 .. 0x2f");n<<=8,n|=r}}if(1!==t.final.length)throw new Error("final must be a single byte");var o=t.final.charCodeAt(0);if(e[0]>o||o>e[1])throw new Error("final must be in range "+e[0]+" .. "+e[1]);return(n<<=8)|o},n.prototype.identToString=function(t){for(var e=[];t;)e.push(String.fromCharCode(255&t)),t>>=8;return e.reverse().join("")},n.prototype.dispose=function(){this._csiHandlers=Object.create(null),this._executeHandlers=Object.create(null),this._escHandlers=Object.create(null),this._oscParser.dispose(),this._dcsParser.dispose()},n.prototype.setPrintHandler=function(t){this._printHandler=t},n.prototype.clearPrintHandler=function(){this._printHandler=this._printHandlerFb},n.prototype.addEscHandler=function(t,e){var n=this._identifier(t,[48,126]);void 0===this._escHandlers[n]&&(this._escHandlers[n]=[]);var i=this._escHandlers[n];return i.push(e),{dispose:function(){var t=i.indexOf(e);-1!==t&&i.splice(t,1)}}},n.prototype.setEscHandler=function(t,e){this._escHandlers[this._identifier(t,[48,126])]=[e]},n.prototype.clearEscHandler=function(t){this._escHandlers[this._identifier(t,[48,126])]&&delete this._escHandlers[this._identifier(t,[48,126])]},n.prototype.setEscHandlerFallback=function(t){this._escHandlerFb=t},n.prototype.setExecuteHandler=function(t,e){this._executeHandlers[t.charCodeAt(0)]=e},n.prototype.clearExecuteHandler=function(t){this._executeHandlers[t.charCodeAt(0)]&&delete this._executeHandlers[t.charCodeAt(0)]},n.prototype.setExecuteHandlerFallback=function(t){this._executeHandlerFb=t},n.prototype.addCsiHandler=function(t,e){var n=this._identifier(t);void 0===this._csiHandlers[n]&&(this._csiHandlers[n]=[]);var i=this._csiHandlers[n];return i.push(e),{dispose:function(){var t=i.indexOf(e);-1!==t&&i.splice(t,1)}}},n.prototype.setCsiHandler=function(t,e){this._csiHandlers[this._identifier(t)]=[e]},n.prototype.clearCsiHandler=function(t){this._csiHandlers[this._identifier(t)]&&delete this._csiHandlers[this._identifier(t)]},n.prototype.setCsiHandlerFallback=function(t){this._csiHandlerFb=t},n.prototype.addDcsHandler=function(t,e){return this._dcsParser.addHandler(this._identifier(t),e)},n.prototype.setDcsHandler=function(t,e){this._dcsParser.setHandler(this._identifier(t),e)},n.prototype.clearDcsHandler=function(t){this._dcsParser.clearHandler(this._identifier(t))},n.prototype.setDcsHandlerFallback=function(t){this._dcsParser.setHandlerFallback(t)},n.prototype.addOscHandler=function(t,e){return this._oscParser.addHandler(t,e)},n.prototype.setOscHandler=function(t,e){this._oscParser.setHandler(t,e)},n.prototype.clearOscHandler=function(t){this._oscParser.clearHandler(t)},n.prototype.setOscHandlerFallback=function(t){this._oscParser.setHandlerFallback(t)},n.prototype.setErrorHandler=function(t){this._errorHandler=t},n.prototype.clearErrorHandler=function(){this._errorHandler=this._errorHandlerFb},n.prototype.reset=function(){this.currentState=this.initialState,this._oscParser.reset(),this._dcsParser.reset(),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingCodepoint=0},n.prototype.parse=function(t,e){for(var n=0,i=0,r=this.currentState,o=this._oscParser,a=this._dcsParser,s=this._collect,c=this._params,l=this._transitions.table,u=0;u<e;++u){switch((i=l[r<<8|((n=t[u])<160?n:160)])>>4){case 2:for(var h=u+1;;++h){if(h>=e||(n=t[h])<32||n>126&&n<160){this._printHandler(t,u,h),u=h-1;break}if(++h>=e||(n=t[h])<32||n>126&&n<160){this._printHandler(t,u,h),u=h-1;break}if(++h>=e||(n=t[h])<32||n>126&&n<160){this._printHandler(t,u,h),u=h-1;break}if(++h>=e||(n=t[h])<32||n>126&&n<160){this._printHandler(t,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:r,collect:s,params:c,abort:!1}).abort)return;break;case 7:for(var d=this._csiHandlers[s<<8|n],f=d?d.length-1:-1;f>=0&&!1===d[f](c);f--);f<0&&this._csiHandlerFb(s<<8|n,c),this.precedingCodepoint=0;break;case 8:do{switch(n){case 59:c.addParam(0);break;case 58:c.addSubParam(-1);break;default:c.addDigit(n-48)}}while(++u<e&&(n=t[u])>47&&n<60);u--;break;case 9:s<<=8,s|=n;break;case 10:for(var p=this._escHandlers[s<<8|n],m=p?p.length-1:-1;m>=0&&!1===p[m]();m--);m<0&&this._escHandlerFb(s<<8|n),this.precedingCodepoint=0;break;case 11:c.reset(),c.addParam(0),s=0;break;case 12:a.hook(s<<8|n,c);break;case 13:for(var g=u+1;;++g)if(g>=e||24===(n=t[g])||26===n||27===n||n>127&&n<160){a.put(t,u,g),u=g-1;break}break;case 14:a.unhook(24!==n&&26!==n),27===n&&(i|=1),c.reset(),c.addParam(0),s=0,this.precedingCodepoint=0;break;case 4:o.start();break;case 5:for(var v=u+1;;v++)if(v>=e||(n=t[v])<32||n>127&&n<=159){o.put(t,u,v),u=v-1;break}break;case 6:o.end(24!==n&&26!==n),27===n&&(i|=1),c.reset(),c.addParam(0),s=0,this.precedingCodepoint=0}r=15&i}this._collect=s,this.currentState=r},n}(o.Disposable);e.EscapeSequenceParser=h},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.Renderer=void 0;var s=n(41),c=n(47),l=n(48),u=n(49),h=n(29),d=n(2),f=n(5),p=n(1),m=n(25),g=n(0),v=1,b=function(t){function e(e,n,i,r,o,a,d,f,p){var m=t.call(this)||this;m._colors=e,m._screenElement=n,m._bufferService=o,m._charSizeService=a,m._optionsService=d,m._id=v++,m._onRequestRedraw=new g.EventEmitter;var b=m._optionsService.options.allowTransparency;return m._characterJoinerRegistry=new h.CharacterJoinerRegistry(m._bufferService),m._renderLayers=[new s.TextRenderLayer(m._screenElement,0,m._colors,m._characterJoinerRegistry,b,m._id,m._bufferService,d),new c.SelectionRenderLayer(m._screenElement,1,m._colors,m._id,m._bufferService,d),new u.LinkRenderLayer(m._screenElement,2,m._colors,m._id,i,r,m._bufferService,d),new l.CursorRenderLayer(m._screenElement,3,m._colors,m._id,m._onRequestRedraw,m._bufferService,d,f,p)],m.dimensions={scaledCharWidth:0,scaledCharHeight:0,scaledCellWidth:0,scaledCellHeight:0,scaledCharLeft:0,scaledCharTop:0,scaledCanvasWidth:0,scaledCanvasHeight:0,canvasWidth:0,canvasHeight:0,actualCellWidth:0,actualCellHeight:0},m._devicePixelRatio=window.devicePixelRatio,m._updateDimensions(),m.onOptionsChanged(),m}return r(e,t),Object.defineProperty(e.prototype,"onRequestRedraw",{get:function(){return this._onRequestRedraw.event},enumerable:!1,configurable:!0}),e.prototype.dispose=function(){for(var e=0,n=this._renderLayers;e<n.length;e++)n[e].dispose();t.prototype.dispose.call(this),m.removeTerminalFromCache(this._id)},e.prototype.onDevicePixelRatioChange=function(){this._devicePixelRatio!==window.devicePixelRatio&&(this._devicePixelRatio=window.devicePixelRatio,this.onResize(this._bufferService.cols,this._bufferService.rows))},e.prototype.setColors=function(t){this._colors=t;for(var e=0,n=this._renderLayers;e<n.length;e++){var i=n[e];i.setColors(this._colors),i.reset()}},e.prototype.onResize=function(t,e){this._updateDimensions();for(var n=0,i=this._renderLayers;n<i.length;n++)i[n].resize(this.dimensions);this._screenElement.style.width=this.dimensions.canvasWidth+"px",this._screenElement.style.height=this.dimensions.canvasHeight+"px"},e.prototype.onCharSizeChanged=function(){this.onResize(this._bufferService.cols,this._bufferService.rows)},e.prototype.onBlur=function(){this._runOperation((function(t){return t.onBlur()}))},e.prototype.onFocus=function(){this._runOperation((function(t){return t.onFocus()}))},e.prototype.onSelectionChanged=function(t,e,n){void 0===n&&(n=!1),this._runOperation((function(i){return i.onSelectionChanged(t,e,n)}))},e.prototype.onCursorMove=function(){this._runOperation((function(t){return t.onCursorMove()}))},e.prototype.onOptionsChanged=function(){this._runOperation((function(t){return t.onOptionsChanged()}))},e.prototype.clear=function(){this._runOperation((function(t){return t.reset()}))},e.prototype._runOperation=function(t){for(var e=0,n=this._renderLayers;e<n.length;e++)t(n[e])},e.prototype.renderRows=function(t,e){for(var n=0,i=this._renderLayers;n<i.length;n++)i[n].onGridChanged(t,e)},e.prototype._updateDimensions=function(){this._charSizeService.hasValidSize&&(this.dimensions.scaledCharWidth=Math.floor(this._charSizeService.width*window.devicePixelRatio),this.dimensions.scaledCharHeight=Math.ceil(this._charSizeService.height*window.devicePixelRatio),this.dimensions.scaledCellHeight=Math.floor(this.dimensions.scaledCharHeight*this._optionsService.options.lineHeight),this.dimensions.scaledCharTop=1===this._optionsService.options.lineHeight?0:Math.round((this.dimensions.scaledCellHeight-this.dimensions.scaledCharHeight)/2),this.dimensions.scaledCellWidth=this.dimensions.scaledCharWidth+Math.round(this._optionsService.options.letterSpacing),this.dimensions.scaledCharLeft=Math.floor(this._optionsService.options.letterSpacing/2),this.dimensions.scaledCanvasHeight=this._bufferService.rows*this.dimensions.scaledCellHeight,this.dimensions.scaledCanvasWidth=this._bufferService.cols*this.dimensions.scaledCellWidth,this.dimensions.canvasHeight=Math.round(this.dimensions.scaledCanvasHeight/window.devicePixelRatio),this.dimensions.canvasWidth=Math.round(this.dimensions.scaledCanvasWidth/window.devicePixelRatio),this.dimensions.actualCellHeight=this.dimensions.canvasHeight/this._bufferService.rows,this.dimensions.actualCellWidth=this.dimensions.canvasWidth/this._bufferService.cols)},e.prototype.registerCharacterJoiner=function(t){return this._characterJoinerRegistry.registerCharacterJoiner(t)},e.prototype.deregisterCharacterJoiner=function(t){return this._characterJoinerRegistry.deregisterCharacterJoiner(t)},o([a(4,p.IBufferService),a(5,f.ICharSizeService),a(6,p.IOptionsService),a(7,p.ICoreService),a(8,f.ICoreBrowserService)],e)}(d.Disposable);e.Renderer=b},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.TextRenderLayer=void 0;var o=n(42),a=n(13),s=n(6),c=n(3),l=n(29),u=n(4),h=function(t){function e(e,n,i,r,a,s,c,l){var h=t.call(this,e,"text",n,a,i,s,c,l)||this;return h._characterWidth=0,h._characterFont="",h._characterOverlapCache={},h._workCell=new u.CellData,h._state=new o.GridCache,h._characterJoinerRegistry=r,h}return r(e,t),e.prototype.resize=function(e){t.prototype.resize.call(this,e);var n=this._getFont(!1,!1);this._characterWidth===e.scaledCharWidth&&this._characterFont===n||(this._characterWidth=e.scaledCharWidth,this._characterFont=n,this._characterOverlapCache={}),this._state.clear(),this._state.resize(this._bufferService.cols,this._bufferService.rows)},e.prototype.reset=function(){this._state.clear(),this._clearAll()},e.prototype._forEachCell=function(t,e,n,i){for(var r=t;r<=e;r++)for(var o=r+this._bufferService.buffer.ydisp,a=this._bufferService.buffer.lines.get(o),s=n?n.getJoinedCharacters(o):[],u=0;u<this._bufferService.cols;u++){a.loadCell(u,this._workCell);var h=this._workCell,d=!1,f=u;if(0!==h.getWidth()){if(s.length>0&&u===s[0][0]){d=!0;var p=s.shift();h=new l.JoinedCellData(this._workCell,a.translateToString(!0,p[0],p[1]),p[1]-p[0]),f=p[1]-1}!d&&this._isOverlapping(h)&&f<a.length-1&&a.getCodePoint(f+1)===c.NULL_CELL_CODE&&(h.content&=-12582913,h.content|=2<<22),i(h,u,r),u=f}}},e.prototype._drawBackground=function(t,e){var n=this,i=this._ctx,r=this._bufferService.cols,o=0,a=0,c=null;i.save(),this._forEachCell(t,e,null,(function(t,e,l){var u=null;t.isInverse()?u=t.isFgDefault()?n._colors.foreground.css:t.isFgRGB()?"rgb("+s.AttributeData.toColorRGB(t.getFgColor()).join(",")+")":n._colors.ansi[t.getFgColor()].css:t.isBgRGB()?u="rgb("+s.AttributeData.toColorRGB(t.getBgColor()).join(",")+")":t.isBgPalette()&&(u=n._colors.ansi[t.getBgColor()].css),null===c&&(o=e,a=l),l!==a?(i.fillStyle=c||"",n._fillCells(o,a,r-o,1),o=e,a=l):c!==u&&(i.fillStyle=c||"",n._fillCells(o,a,e-o,1),o=e,a=l),c=u})),null!==c&&(i.fillStyle=c,this._fillCells(o,a,r-o,1)),i.restore()},e.prototype._drawForeground=function(t,e){var n=this;this._forEachCell(t,e,this._characterJoinerRegistry,(function(t,e,i){if(!t.isInvisible()&&(n._drawChars(t,e,i),t.isUnderline())){if(n._ctx.save(),t.isInverse())if(t.isBgDefault())n._ctx.fillStyle=n._colors.background.css;else if(t.isBgRGB())n._ctx.fillStyle="rgb("+s.AttributeData.toColorRGB(t.getBgColor()).join(",")+")";else{var r=t.getBgColor();n._optionsService.options.drawBoldTextInBrightColors&&t.isBold()&&r<8&&(r+=8),n._ctx.fillStyle=n._colors.ansi[r].css}else if(t.isFgDefault())n._ctx.fillStyle=n._colors.foreground.css;else if(t.isFgRGB())n._ctx.fillStyle="rgb("+s.AttributeData.toColorRGB(t.getFgColor()).join(",")+")";else{var o=t.getFgColor();n._optionsService.options.drawBoldTextInBrightColors&&t.isBold()&&o<8&&(o+=8),n._ctx.fillStyle=n._colors.ansi[o].css}n._fillBottomLineAtCells(e,i,t.getWidth()),n._ctx.restore()}}))},e.prototype.onGridChanged=function(t,e){0!==this._state.cache.length&&(this._charAtlas&&this._charAtlas.beginFrame(),this._clearCells(0,t,this._bufferService.cols,e-t+1),this._drawBackground(t,e),this._drawForeground(t,e))},e.prototype.onOptionsChanged=function(){this._setTransparency(this._optionsService.options.allowTransparency)},e.prototype._isOverlapping=function(t){if(1!==t.getWidth())return!1;if(t.getCode()<256)return!1;var e=t.getChars();if(this._characterOverlapCache.hasOwnProperty(e))return this._characterOverlapCache[e];this._ctx.save(),this._ctx.font=this._characterFont;var n=Math.floor(this._ctx.measureText(e).width)>this._characterWidth;return this._ctx.restore(),this._characterOverlapCache[e]=n,n},e}(a.BaseRenderLayer);e.TextRenderLayer=h},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.GridCache=void 0;var i=function(){function t(){this.cache=[]}return t.prototype.resize=function(t,e){for(var n=0;n<t;n++){this.cache.length<=n&&this.cache.push([]);for(var i=this.cache[n].length;i<e;i++)this.cache[n].push(void 0);this.cache[n].length=e}this.cache.length=t},t.prototype.clear=function(){for(var t=0;t<this.cache.length;t++)for(var e=0;e<this.cache[t].length;e++)this.cache[t][e]=void 0},t}();e.GridCache=i},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.NoneCharAtlas=e.DynamicCharAtlas=e.getGlyphCacheKey=void 0;var o=n(9),a=n(44),s=n(27),c=n(46),l=n(11),u=n(28),h=n(10),d={css:"rgba(0, 0, 0, 0)",rgba:0};function f(t){return t.code<<21|t.bg<<12|t.fg<<3|(t.bold?0:4)+(t.dim?0:2)+(t.italic?0:1)}e.getGlyphCacheKey=f;var p=function(t){function e(e,n){var i=t.call(this)||this;i._config=n,i._drawToCacheCount=0,i._glyphsWaitingOnBitmap=[],i._bitmapCommitTimeout=null,i._bitmap=null,i._cacheCanvas=e.createElement("canvas"),i._cacheCanvas.width=1024,i._cacheCanvas.height=1024,i._cacheCtx=u.throwIfFalsy(i._cacheCanvas.getContext("2d",{alpha:!0}));var r=e.createElement("canvas");r.width=i._config.scaledCharWidth,r.height=i._config.scaledCharHeight,i._tmpCtx=u.throwIfFalsy(r.getContext("2d",{alpha:i._config.allowTransparency})),i._width=Math.floor(1024/i._config.scaledCharWidth),i._height=Math.floor(1024/i._config.scaledCharHeight);var o=i._width*i._height;return i._cacheMap=new c.LRUMap(o),i._cacheMap.prealloc(o),i}return r(e,t),e.prototype.dispose=function(){null!==this._bitmapCommitTimeout&&(window.clearTimeout(this._bitmapCommitTimeout),this._bitmapCommitTimeout=null)},e.prototype.beginFrame=function(){this._drawToCacheCount=0},e.prototype.draw=function(t,e,n,i){if(32===e.code)return!0;if(!this._canCache(e))return!1;var r=f(e),o=this._cacheMap.get(r);if(null!=o)return this._drawFromCache(t,o,n,i),!0;if(this._drawToCacheCount<100){var a;a=this._cacheMap.size<this._cacheMap.capacity?this._cacheMap.size:this._cacheMap.peek().index;var s=this._drawToCache(e,a);return this._cacheMap.set(r,s),this._drawFromCache(t,s,n,i),!0}return!1},e.prototype._canCache=function(t){return t.code<256},e.prototype._toCoordinateX=function(t){return t%this._width*this._config.scaledCharWidth},e.prototype._toCoordinateY=function(t){return Math.floor(t/this._width)*this._config.scaledCharHeight},e.prototype._drawFromCache=function(t,e,n,i){if(!e.isEmpty){var r=this._toCoordinateX(e.index),o=this._toCoordinateY(e.index);t.drawImage(e.inBitmap?this._bitmap:this._cacheCanvas,r,o,this._config.scaledCharWidth,this._config.scaledCharHeight,n,i,this._config.scaledCharWidth,this._config.scaledCharHeight)}},e.prototype._getColorFromAnsiIndex=function(t){return t<this._config.colors.ansi.length?this._config.colors.ansi[t]:s.DEFAULT_ANSI_COLORS[t]},e.prototype._getBackgroundColor=function(t){return this._config.allowTransparency?d:t.bg===o.INVERTED_DEFAULT_COLOR?this._config.colors.foreground:t.bg<256?this._getColorFromAnsiIndex(t.bg):this._config.colors.background},e.prototype._getForegroundColor=function(t){return t.fg===o.INVERTED_DEFAULT_COLOR?h.color.opaque(this._config.colors.background):t.fg<256?this._getColorFromAnsiIndex(t.fg):this._config.colors.foreground},e.prototype._drawToCache=function(t,e){this._drawToCacheCount++,this._tmpCtx.save();var n=this._getBackgroundColor(t);this._tmpCtx.globalCompositeOperation="copy",this._tmpCtx.fillStyle=n.css,this._tmpCtx.fillRect(0,0,this._config.scaledCharWidth,this._config.scaledCharHeight),this._tmpCtx.globalCompositeOperation="source-over",this._tmpCtx.font=(t.italic?"italic":"")+" "+(t.bold?this._config.fontWeightBold:this._config.fontWeight)+" "+this._config.fontSize*this._config.devicePixelRatio+"px "+this._config.fontFamily,this._tmpCtx.textBaseline="middle",this._tmpCtx.fillStyle=this._getForegroundColor(t).css,t.dim&&(this._tmpCtx.globalAlpha=o.DIM_OPACITY),this._tmpCtx.fillText(t.chars,0,this._config.scaledCharHeight/2),this._tmpCtx.restore();var i=this._tmpCtx.getImageData(0,0,this._config.scaledCharWidth,this._config.scaledCharHeight),r=!1;this._config.allowTransparency||(r=function(t,e){for(var n=!0,i=e.rgba>>>24,r=e.rgba>>>16&255,o=e.rgba>>>8&255,a=0;a<t.data.length;a+=4)t.data[a]===i&&t.data[a+1]===r&&t.data[a+2]===o?t.data[a+3]=0:n=!1;return n}(i,n));var a=this._toCoordinateX(e),s=this._toCoordinateY(e);this._cacheCtx.putImageData(i,a,s);var c={index:e,isEmpty:r,inBitmap:!1};return this._addGlyphToBitmap(c),c},e.prototype._addGlyphToBitmap=function(t){var e=this;!("createImageBitmap"in window)||l.isFirefox||l.isSafari||(this._glyphsWaitingOnBitmap.push(t),null===this._bitmapCommitTimeout&&(this._bitmapCommitTimeout=window.setTimeout((function(){return e._generateBitmap()}),100)))},e.prototype._generateBitmap=function(){var t=this,e=this._glyphsWaitingOnBitmap;this._glyphsWaitingOnBitmap=[],window.createImageBitmap(this._cacheCanvas).then((function(n){t._bitmap=n;for(var i=0;i<e.length;i++)e[i].inBitmap=!0})),this._bitmapCommitTimeout=null},e}(a.BaseCharAtlas);e.DynamicCharAtlas=p;var m=function(t){function e(e,n){return t.call(this)||this}return r(e,t),e.prototype.draw=function(t,e,n,i){return!1},e}(a.BaseCharAtlas);e.NoneCharAtlas=m},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BaseCharAtlas=void 0;var i=function(){function t(){this._didWarmUp=!1}return t.prototype.dispose=function(){},t.prototype.warmUp=function(){this._didWarmUp||(this._doWarmUp(),this._didWarmUp=!0)},t.prototype._doWarmUp=function(){},t.prototype.beginFrame=function(){},t}();e.BaseCharAtlas=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ColorContrastCache=void 0;var i=function(){function t(){this._color={},this._rgba={}}return t.prototype.clear=function(){this._color={},this._rgba={}},t.prototype.setCss=function(t,e,n){this._rgba[t]||(this._rgba[t]={}),this._rgba[t][e]=n},t.prototype.getCss=function(t,e){return this._rgba[t]?this._rgba[t][e]:void 0},t.prototype.setColor=function(t,e,n){this._color[t]||(this._color[t]={}),this._color[t][e]=n},t.prototype.getColor=function(t,e){return this._color[t]?this._color[t][e]:void 0},t}();e.ColorContrastCache=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.LRUMap=void 0;var i=function(){function t(t){this.capacity=t,this._map={},this._head=null,this._tail=null,this._nodePool=[],this.size=0}return t.prototype._unlinkNode=function(t){var e=t.prev,n=t.next;t===this._head&&(this._head=n),t===this._tail&&(this._tail=e),null!==e&&(e.next=n),null!==n&&(n.prev=e)},t.prototype._appendNode=function(t){var e=this._tail;null!==e&&(e.next=t),t.prev=e,t.next=null,this._tail=t,null===this._head&&(this._head=t)},t.prototype.prealloc=function(t){for(var e=this._nodePool,n=0;n<t;n++)e.push({prev:null,next:null,key:null,value:null})},t.prototype.get=function(t){var e=this._map[t];return void 0!==e?(this._unlinkNode(e),this._appendNode(e),e.value):null},t.prototype.peekValue=function(t){var e=this._map[t];return void 0!==e?e.value:null},t.prototype.peek=function(){var t=this._head;return null===t?null:t.value},t.prototype.set=function(t,e){var n=this._map[t];if(void 0!==n)this._unlinkNode(n=this._map[t]),n.value=e;else if(this.size>=this.capacity)this._unlinkNode(n=this._head),delete this._map[n.key],n.key=t,n.value=e,this._map[t]=n;else{var i=this._nodePool;i.length>0?((n=i.pop()).key=t,n.value=e):n={prev:null,next:null,key:t,value:e},this._map[t]=n,this.size++}this._appendNode(n)},t}();e.LRUMap=i},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.SelectionRenderLayer=void 0;var o=function(t){function e(e,n,i,r,o,a){var s=t.call(this,e,"selection",n,!0,i,r,o,a)||this;return s._clearState(),s}return r(e,t),e.prototype._clearState=function(){this._state={start:void 0,end:void 0,columnSelectMode:void 0,ydisp:void 0}},e.prototype.resize=function(e){t.prototype.resize.call(this,e),this._clearState()},e.prototype.reset=function(){this._state.start&&this._state.end&&(this._clearState(),this._clearAll())},e.prototype.onSelectionChanged=function(t,e,n){if(this._didStateChange(t,e,n,this._bufferService.buffer.ydisp))if(this._clearAll(),t&&e){var i=t[1]-this._bufferService.buffer.ydisp,r=e[1]-this._bufferService.buffer.ydisp,o=Math.max(i,0),a=Math.min(r,this._bufferService.rows-1);if(!(o>=this._bufferService.rows||a<0)){if(this._ctx.fillStyle=this._colors.selectionTransparent.css,n){var s=t[0];this._fillCells(s,o,e[0]-s,a-o+1)}else{this._fillCells(s=i===o?t[0]:0,o,(o===a?e[0]:this._bufferService.cols)-s,1);var c=Math.max(a-o-1,0);this._fillCells(0,o+1,this._bufferService.cols,c),o!==a&&this._fillCells(0,a,r===a?e[0]:this._bufferService.cols,1)}this._state.start=[t[0],t[1]],this._state.end=[e[0],e[1]],this._state.columnSelectMode=n,this._state.ydisp=this._bufferService.buffer.ydisp}}else this._clearState()},e.prototype._didStateChange=function(t,e,n,i){return!this._areCoordinatesEqual(t,this._state.start)||!this._areCoordinatesEqual(e,this._state.end)||n!==this._state.columnSelectMode||i!==this._state.ydisp},e.prototype._areCoordinatesEqual=function(t,e){return!(!t||!e)&&t[0]===e[0]&&t[1]===e[1]},e}(n(13).BaseRenderLayer);e.SelectionRenderLayer=o},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.CursorRenderLayer=void 0;var o=n(13),a=n(4),s=function(t){function e(e,n,i,r,o,s,c,l,u){var h=t.call(this,e,"cursor",n,!0,i,r,s,c)||this;return h._onRequestRedraw=o,h._coreService=l,h._coreBrowserService=u,h._cell=new a.CellData,h._state={x:0,y:0,isFocused:!1,style:"",width:0},h._cursorRenderers={bar:h._renderBarCursor.bind(h),block:h._renderBlockCursor.bind(h),underline:h._renderUnderlineCursor.bind(h)},h}return r(e,t),e.prototype.resize=function(e){t.prototype.resize.call(this,e),this._state={x:0,y:0,isFocused:!1,style:"",width:0}},e.prototype.reset=function(){this._clearCursor(),this._cursorBlinkStateManager&&(this._cursorBlinkStateManager.dispose(),this._cursorBlinkStateManager=void 0,this.onOptionsChanged())},e.prototype.onBlur=function(){this._cursorBlinkStateManager&&this._cursorBlinkStateManager.pause(),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},e.prototype.onFocus=function(){this._cursorBlinkStateManager?this._cursorBlinkStateManager.resume():this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},e.prototype.onOptionsChanged=function(){var t,e=this;this._optionsService.options.cursorBlink?this._cursorBlinkStateManager||(this._cursorBlinkStateManager=new c(this._coreBrowserService.isFocused,(function(){e._render(!0)}))):(null===(t=this._cursorBlinkStateManager)||void 0===t||t.dispose(),this._cursorBlinkStateManager=void 0),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},e.prototype.onCursorMove=function(){this._cursorBlinkStateManager&&this._cursorBlinkStateManager.restartBlinkAnimation()},e.prototype.onGridChanged=function(t,e){!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isPaused?this._render(!1):this._cursorBlinkStateManager.restartBlinkAnimation()},e.prototype._render=function(t){if(this._coreService.isCursorInitialized&&!this._coreService.isCursorHidden){var e=this._bufferService.buffer.ybase+this._bufferService.buffer.y,n=e-this._bufferService.buffer.ydisp;if(n<0||n>=this._bufferService.rows)this._clearCursor();else{var i=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1);if(this._bufferService.buffer.lines.get(e).loadCell(i,this._cell),void 0!==this._cell.content){if(!this._coreBrowserService.isFocused){this._clearCursor(),this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css;var r=this._optionsService.options.cursorStyle;return r&&"block"!==r?this._cursorRenderers[r](i,n,this._cell):this._renderBlurCursor(i,n,this._cell),this._ctx.restore(),this._state.x=i,this._state.y=n,this._state.isFocused=!1,this._state.style=r,void(this._state.width=this._cell.getWidth())}if(!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isCursorVisible){if(this._state){if(this._state.x===i&&this._state.y===n&&this._state.isFocused===this._coreBrowserService.isFocused&&this._state.style===this._optionsService.options.cursorStyle&&this._state.width===this._cell.getWidth())return;this._clearCursor()}this._ctx.save(),this._cursorRenderers[this._optionsService.options.cursorStyle||"block"](i,n,this._cell),this._ctx.restore(),this._state.x=i,this._state.y=n,this._state.isFocused=!1,this._state.style=this._optionsService.options.cursorStyle,this._state.width=this._cell.getWidth()}else this._clearCursor()}}}else this._clearCursor()},e.prototype._clearCursor=function(){this._state&&(this._clearCells(this._state.x,this._state.y,this._state.width,1),this._state={x:0,y:0,isFocused:!1,style:"",width:0})},e.prototype._renderBarCursor=function(t,e,n){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillLeftLineAtCell(t,e,this._optionsService.options.cursorWidth),this._ctx.restore()},e.prototype._renderBlockCursor=function(t,e,n){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillCells(t,e,n.getWidth(),1),this._ctx.fillStyle=this._colors.cursorAccent.css,this._fillCharTrueColor(n,t,e),this._ctx.restore()},e.prototype._renderUnderlineCursor=function(t,e,n){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillBottomLineAtCells(t,e),this._ctx.restore()},e.prototype._renderBlurCursor=function(t,e,n){this._ctx.save(),this._ctx.strokeStyle=this._colors.cursor.css,this._strokeRectAtCell(t,e,n.getWidth(),1),this._ctx.restore()},e}(o.BaseRenderLayer);e.CursorRenderLayer=s;var c=function(){function t(t,e){this._renderCallback=e,this.isCursorVisible=!0,t&&this._restartInterval()}return Object.defineProperty(t.prototype,"isPaused",{get:function(){return!(this._blinkStartTimeout||this._blinkInterval)},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){this._blinkInterval&&(window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout&&(window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=void 0),this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)},t.prototype.restartBlinkAnimation=function(){var t=this;this.isPaused||(this._animationTimeRestarted=Date.now(),this.isCursorVisible=!0,this._animationFrame||(this._animationFrame=window.requestAnimationFrame((function(){t._renderCallback(),t._animationFrame=void 0}))))},t.prototype._restartInterval=function(t){var e=this;void 0===t&&(t=600),this._blinkInterval&&window.clearInterval(this._blinkInterval),this._blinkStartTimeout=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=window.requestAnimationFrame((function(){e._renderCallback(),e._animationFrame=void 0})),e._blinkInterval=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=window.requestAnimationFrame((function(){e._renderCallback(),e._animationFrame=void 0}))}),600)}),t)},t.prototype.pause=function(){this.isCursorVisible=!0,this._blinkInterval&&(window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout&&(window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=void 0),this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)},t.prototype.resume=function(){this.pause(),this._animationTimeRestarted=void 0,this._restartInterval(),this.restartBlinkAnimation()},t}()},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.LinkRenderLayer=void 0;var o=n(13),a=n(9),s=n(26),c=function(t){function e(e,n,i,r,o,a,s,c){var l=t.call(this,e,"link",n,!0,i,r,s,c)||this;return o.onShowLinkUnderline((function(t){return l._onShowLinkUnderline(t)})),o.onHideLinkUnderline((function(t){return l._onHideLinkUnderline(t)})),a.onShowLinkUnderline((function(t){return l._onShowLinkUnderline(t)})),a.onHideLinkUnderline((function(t){return l._onHideLinkUnderline(t)})),l}return r(e,t),e.prototype.resize=function(e){t.prototype.resize.call(this,e),this._state=void 0},e.prototype.reset=function(){this._clearCurrentLink()},e.prototype._clearCurrentLink=function(){if(this._state){this._clearCells(this._state.x1,this._state.y1,this._state.cols-this._state.x1,1);var t=this._state.y2-this._state.y1-1;t>0&&this._clearCells(0,this._state.y1+1,this._state.cols,t),this._clearCells(0,this._state.y2,this._state.x2,1),this._state=void 0}},e.prototype._onShowLinkUnderline=function(t){if(this._ctx.fillStyle=t.fg===a.INVERTED_DEFAULT_COLOR?this._colors.background.css:t.fg&&s.is256Color(t.fg)?this._colors.ansi[t.fg].css:this._colors.foreground.css,t.y1===t.y2)this._fillBottomLineAtCells(t.x1,t.y1,t.x2-t.x1);else{this._fillBottomLineAtCells(t.x1,t.y1,t.cols-t.x1);for(var e=t.y1+1;e<t.y2;e++)this._fillBottomLineAtCells(0,e,t.cols);this._fillBottomLineAtCells(0,t.y2,t.x2)}this._state=t},e.prototype._onHideLinkUnderline=function(t){this._clearCurrentLink()},e}(o.BaseRenderLayer);e.LinkRenderLayer=c},function(t,e,n){"use strict";var i=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},r=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.MouseZone=e.Linkifier=void 0;var o=n(0),a=n(1),s=function(){function t(t,e,n){this._bufferService=t,this._logService=e,this._unicodeService=n,this._linkMatchers=[],this._nextLinkMatcherId=0,this._onShowLinkUnderline=new o.EventEmitter,this._onHideLinkUnderline=new o.EventEmitter,this._onLinkTooltip=new o.EventEmitter,this._rowsToLinkify={start:void 0,end:void 0}}return Object.defineProperty(t.prototype,"onShowLinkUnderline",{get:function(){return this._onShowLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onHideLinkUnderline",{get:function(){return this._onHideLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onLinkTooltip",{get:function(){return this._onLinkTooltip.event},enumerable:!1,configurable:!0}),t.prototype.attachToDom=function(t,e){this._element=t,this._mouseZoneManager=e},t.prototype.linkifyRows=function(e,n){var i=this;this._mouseZoneManager&&(void 0===this._rowsToLinkify.start||void 0===this._rowsToLinkify.end?(this._rowsToLinkify.start=e,this._rowsToLinkify.end=n):(this._rowsToLinkify.start=Math.min(this._rowsToLinkify.start,e),this._rowsToLinkify.end=Math.max(this._rowsToLinkify.end,n)),this._mouseZoneManager.clearAll(e,n),this._rowsTimeoutId&&clearTimeout(this._rowsTimeoutId),this._rowsTimeoutId=setTimeout((function(){return i._linkifyRows()}),t._timeBeforeLatency))},t.prototype._linkifyRows=function(){this._rowsTimeoutId=void 0;var t=this._bufferService.buffer;if(void 0!==this._rowsToLinkify.start&&void 0!==this._rowsToLinkify.end){var e=t.ydisp+this._rowsToLinkify.start;if(!(e>=t.lines.length)){for(var n=t.ydisp+Math.min(this._rowsToLinkify.end,this._bufferService.rows)+1,i=Math.ceil(2e3/this._bufferService.cols),r=this._bufferService.buffer.iterator(!1,e,n,i,i);r.hasNext();)for(var o=r.next(),a=0;a<this._linkMatchers.length;a++)this._doLinkifyRow(o.range.first,o.content,this._linkMatchers[a]);this._rowsToLinkify.start=void 0,this._rowsToLinkify.end=void 0}}else this._logService.debug("_rowToLinkify was unset before _linkifyRows was called")},t.prototype.registerLinkMatcher=function(t,e,n){if(void 0===n&&(n={}),!e)throw new Error("handler must be defined");var i={id:this._nextLinkMatcherId++,regex:t,handler:e,matchIndex:n.matchIndex,validationCallback:n.validationCallback,hoverTooltipCallback:n.tooltipCallback,hoverLeaveCallback:n.leaveCallback,willLinkActivate:n.willLinkActivate,priority:n.priority||0};return this._addLinkMatcherToList(i),i.id},t.prototype._addLinkMatcherToList=function(t){if(0!==this._linkMatchers.length){for(var e=this._linkMatchers.length-1;e>=0;e--)if(t.priority<=this._linkMatchers[e].priority)return void this._linkMatchers.splice(e+1,0,t);this._linkMatchers.splice(0,0,t)}else this._linkMatchers.push(t)},t.prototype.deregisterLinkMatcher=function(t){for(var e=0;e<this._linkMatchers.length;e++)if(this._linkMatchers[e].id===t)return this._linkMatchers.splice(e,1),!0;return!1},t.prototype._doLinkifyRow=function(t,e,n){for(var i,r=this,o=new RegExp(n.regex.source,(n.regex.flags||"")+"g"),a=-1,s=function(){var s=i["number"!=typeof n.matchIndex?0:n.matchIndex];if(!s)return c._logService.debug("match found without corresponding matchIndex",i,n),"break";if(a=e.indexOf(s,a+1),o.lastIndex=a+s.length,a<0)return"break";var l=c._bufferService.buffer.stringIndexToBufferIndex(t,a);if(l[0]<0)return"break";var u=c._bufferService.buffer.lines.get(l[0]);if(!u)return"break";var h=u.getFg(l[1]),d=h?h>>9&511:void 0;n.validationCallback?n.validationCallback(s,(function(t){r._rowsTimeoutId||t&&r._addLink(l[1],l[0]-r._bufferService.buffer.ydisp,s,n,d)})):c._addLink(l[1],l[0]-c._bufferService.buffer.ydisp,s,n,d)},c=this;null!==(i=o.exec(e))&&"break"!==s(););},t.prototype._addLink=function(t,e,n,i,r){var o=this;if(this._mouseZoneManager&&this._element){var a=this._unicodeService.getStringCellWidth(n),s=t%this._bufferService.cols,l=e+Math.floor(t/this._bufferService.cols),u=(s+a)%this._bufferService.cols,h=l+Math.floor((s+a)/this._bufferService.cols);0===u&&(u=this._bufferService.cols,h--),this._mouseZoneManager.add(new c(s+1,l+1,u+1,h+1,(function(t){if(i.handler)return i.handler(t,n);var e=window.open();e?(e.opener=null,e.location.href=n):console.warn("Opening link blocked as opener could not be cleared")}),(function(){o._onShowLinkUnderline.fire(o._createLinkHoverEvent(s,l,u,h,r)),o._element.classList.add("xterm-cursor-pointer")}),(function(t){o._onLinkTooltip.fire(o._createLinkHoverEvent(s,l,u,h,r)),i.hoverTooltipCallback&&i.hoverTooltipCallback(t,n,{start:{x:s,y:l},end:{x:u,y:h}})}),(function(){o._onHideLinkUnderline.fire(o._createLinkHoverEvent(s,l,u,h,r)),o._element.classList.remove("xterm-cursor-pointer"),i.hoverLeaveCallback&&i.hoverLeaveCallback()}),(function(t){return!i.willLinkActivate||i.willLinkActivate(t,n)})))}},t.prototype._createLinkHoverEvent=function(t,e,n,i,r){return{x1:t,y1:e,x2:n,y2:i,cols:this._bufferService.cols,fg:r}},t._timeBeforeLatency=200,t=i([r(0,a.IBufferService),r(1,a.ILogService),r(2,a.IUnicodeService)],t)}();e.Linkifier=s;var c=function(t,e,n,i,r,o,a,s,c){this.x1=t,this.y1=e,this.x2=n,this.y2=i,this.clickCallback=r,this.hoverCallback=o,this.tooltipCallback=a,this.leaveCallback=s,this.willLinkActivate=c};e.MouseZone=c},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.SelectionService=void 0;var s=n(11),c=n(52),l=n(4),u=n(0),h=n(5),d=n(1),f=n(30),p=n(53),m=n(2),g=String.fromCharCode(160),v=new RegExp(g,"g"),b=function(t){function e(e,n,i,r,o,a,s){var h=t.call(this)||this;return h._element=e,h._screenElement=n,h._bufferService=i,h._coreService=r,h._mouseService=o,h._optionsService=a,h._renderService=s,h._dragScrollAmount=0,h._enabled=!0,h._workCell=new l.CellData,h._mouseDownTimeStamp=0,h._onLinuxMouseSelection=h.register(new u.EventEmitter),h._onRedrawRequest=h.register(new u.EventEmitter),h._onSelectionChange=h.register(new u.EventEmitter),h._onRequestScrollLines=h.register(new u.EventEmitter),h._mouseMoveListener=function(t){return h._onMouseMove(t)},h._mouseUpListener=function(t){return h._onMouseUp(t)},h._coreService.onUserInput((function(){h.hasSelection&&h.clearSelection()})),h._trimListener=h._bufferService.buffer.lines.onTrim((function(t){return h._onTrim(t)})),h.register(h._bufferService.buffers.onBufferActivate((function(t){return h._onBufferActivate(t)}))),h.enable(),h._model=new c.SelectionModel(h._bufferService),h._activeSelectionMode=0,h}return r(e,t),Object.defineProperty(e.prototype,"onLinuxMouseSelection",{get:function(){return this._onLinuxMouseSelection.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRequestRedraw",{get:function(){return this._onRedrawRequest.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onSelectionChange",{get:function(){return this._onSelectionChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRequestScrollLines",{get:function(){return this._onRequestScrollLines.event},enumerable:!1,configurable:!0}),e.prototype.dispose=function(){this._removeMouseDownListeners()},e.prototype.reset=function(){this.clearSelection()},e.prototype.disable=function(){this.clearSelection(),this._enabled=!1},e.prototype.enable=function(){this._enabled=!0},Object.defineProperty(e.prototype,"selectionStart",{get:function(){return this._model.finalSelectionStart},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"selectionEnd",{get:function(){return this._model.finalSelectionEnd},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hasSelection",{get:function(){var t=this._model.finalSelectionStart,e=this._model.finalSelectionEnd;return!(!t||!e||t[0]===e[0]&&t[1]===e[1])},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"selectionText",{get:function(){var t=this._model.finalSelectionStart,e=this._model.finalSelectionEnd;if(!t||!e)return"";var n=this._bufferService.buffer,i=[];if(3===this._activeSelectionMode){if(t[0]===e[0])return"";for(var r=t[1];r<=e[1];r++){var o=n.translateBufferLineToString(r,!0,t[0],e[0]);i.push(o)}}else{for(i.push(n.translateBufferLineToString(t[1],!0,t[0],t[1]===e[1]?e[0]:void 0)),r=t[1]+1;r<=e[1]-1;r++){var a=n.lines.get(r);o=n.translateBufferLineToString(r,!0),a&&a.isWrapped?i[i.length-1]+=o:i.push(o)}t[1]!==e[1]&&(a=n.lines.get(e[1]),o=n.translateBufferLineToString(e[1],!0,0,e[0]),a&&a.isWrapped?i[i.length-1]+=o:i.push(o))}return i.map((function(t){return t.replace(v," ")})).join(s.isWindows?"\r\n":"\n")},enumerable:!1,configurable:!0}),e.prototype.clearSelection=function(){this._model.clearSelection(),this._removeMouseDownListeners(),this.refresh(),this._onSelectionChange.fire()},e.prototype.refresh=function(t){var e=this;this._refreshAnimationFrame||(this._refreshAnimationFrame=window.requestAnimationFrame((function(){return e._refresh()}))),s.isLinux&&t&&this.selectionText.length&&this._onLinuxMouseSelection.fire(this.selectionText)},e.prototype._refresh=function(){this._refreshAnimationFrame=void 0,this._onRedrawRequest.fire({start:this._model.finalSelectionStart,end:this._model.finalSelectionEnd,columnSelectMode:3===this._activeSelectionMode})},e.prototype.isClickInSelection=function(t){var e=this._getMouseBufferCoords(t),n=this._model.finalSelectionStart,i=this._model.finalSelectionEnd;return!!(n&&i&&e)&&this._areCoordsInSelection(e,n,i)},e.prototype._areCoordsInSelection=function(t,e,n){return t[1]>e[1]&&t[1]<n[1]||e[1]===n[1]&&t[1]===e[1]&&t[0]>=e[0]&&t[0]<n[0]||e[1]<n[1]&&t[1]===n[1]&&t[0]<n[0]||e[1]<n[1]&&t[1]===e[1]&&t[0]>=e[0]},e.prototype.selectWordAtCursor=function(t){var e=this._getMouseBufferCoords(t);e&&(this._selectWordAt(e,!1),this._model.selectionEnd=void 0,this.refresh(!0))},e.prototype.selectAll=function(){this._model.isSelectAllActive=!0,this.refresh(),this._onSelectionChange.fire()},e.prototype.selectLines=function(t,e){this._model.clearSelection(),t=Math.max(t,0),e=Math.min(e,this._bufferService.buffer.lines.length-1),this._model.selectionStart=[0,t],this._model.selectionEnd=[this._bufferService.cols,e],this.refresh(),this._onSelectionChange.fire()},e.prototype._onTrim=function(t){this._model.onTrim(t)&&this.refresh()},e.prototype._getMouseBufferCoords=function(t){var e=this._mouseService.getCoords(t,this._screenElement,this._bufferService.cols,this._bufferService.rows,!0);if(e)return e[0]--,e[1]--,e[1]+=this._bufferService.buffer.ydisp,e},e.prototype._getMouseEventScrollAmount=function(t){var e=f.getCoordsRelativeToElement(t,this._screenElement)[1],n=this._renderService.dimensions.canvasHeight;return e>=0&&e<=n?0:(e>n&&(e-=n),e=Math.min(Math.max(e,-50),50),(e/=50)/Math.abs(e)+Math.round(14*e))},e.prototype.shouldForceSelection=function(t){return s.isMac?t.altKey&&this._optionsService.options.macOptionClickForcesSelection:t.shiftKey},e.prototype.onMouseDown=function(t){if(this._mouseDownTimeStamp=t.timeStamp,(2!==t.button||!this.hasSelection)&&0===t.button){if(!this._enabled){if(!this.shouldForceSelection(t))return;t.stopPropagation()}t.preventDefault(),this._dragScrollAmount=0,this._enabled&&t.shiftKey?this._onIncrementalClick(t):1===t.detail?this._onSingleClick(t):2===t.detail?this._onDoubleClick(t):3===t.detail&&this._onTripleClick(t),this._addMouseDownListeners(),this.refresh(!0)}},e.prototype._addMouseDownListeners=function(){var t=this;this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.addEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.addEventListener("mouseup",this._mouseUpListener)),this._dragScrollIntervalTimer=window.setInterval((function(){return t._dragScroll()}),50)},e.prototype._removeMouseDownListeners=function(){this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.removeEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.removeEventListener("mouseup",this._mouseUpListener)),clearInterval(this._dragScrollIntervalTimer),this._dragScrollIntervalTimer=void 0},e.prototype._onIncrementalClick=function(t){this._model.selectionStart&&(this._model.selectionEnd=this._getMouseBufferCoords(t))},e.prototype._onSingleClick=function(t){if(this._model.selectionStartLength=0,this._model.isSelectAllActive=!1,this._activeSelectionMode=this.shouldColumnSelect(t)?3:0,this._model.selectionStart=this._getMouseBufferCoords(t),this._model.selectionStart){this._model.selectionEnd=void 0;var e=this._bufferService.buffer.lines.get(this._model.selectionStart[1]);e&&e.length!==this._model.selectionStart[0]&&0===e.hasWidth(this._model.selectionStart[0])&&this._model.selectionStart[0]++}},e.prototype._onDoubleClick=function(t){var e=this._getMouseBufferCoords(t);e&&(this._activeSelectionMode=1,this._selectWordAt(e,!0))},e.prototype._onTripleClick=function(t){var e=this._getMouseBufferCoords(t);e&&(this._activeSelectionMode=2,this._selectLineAt(e[1]))},e.prototype.shouldColumnSelect=function(t){return t.altKey&&!(s.isMac&&this._optionsService.options.macOptionClickForcesSelection)},e.prototype._onMouseMove=function(t){if(t.stopImmediatePropagation(),this._model.selectionStart){var e=this._model.selectionEnd?[this._model.selectionEnd[0],this._model.selectionEnd[1]]:null;if(this._model.selectionEnd=this._getMouseBufferCoords(t),this._model.selectionEnd){2===this._activeSelectionMode?this._model.selectionEnd[0]=this._model.selectionEnd[1]<this._model.selectionStart[1]?0:this._bufferService.cols:1===this._activeSelectionMode&&this._selectToWordAt(this._model.selectionEnd),this._dragScrollAmount=this._getMouseEventScrollAmount(t),3!==this._activeSelectionMode&&(this._dragScrollAmount>0?this._model.selectionEnd[0]=this._bufferService.cols:this._dragScrollAmount<0&&(this._model.selectionEnd[0]=0));var n=this._bufferService.buffer;if(this._model.selectionEnd[1]<n.lines.length){var i=n.lines.get(this._model.selectionEnd[1]);i&&0===i.hasWidth(this._model.selectionEnd[0])&&this._model.selectionEnd[0]++}e&&e[0]===this._model.selectionEnd[0]&&e[1]===this._model.selectionEnd[1]||this.refresh(!0)}else this.refresh(!0)}},e.prototype._dragScroll=function(){if(this._model.selectionEnd&&this._model.selectionStart&&this._dragScrollAmount){this._onRequestScrollLines.fire({amount:this._dragScrollAmount,suppressScrollEvent:!1});var t=this._bufferService.buffer;this._dragScrollAmount>0?(3!==this._activeSelectionMode&&(this._model.selectionEnd[0]=this._bufferService.cols),this._model.selectionEnd[1]=Math.min(t.ydisp+this._bufferService.rows,t.lines.length-1)):(3!==this._activeSelectionMode&&(this._model.selectionEnd[0]=0),this._model.selectionEnd[1]=t.ydisp),this.refresh()}},e.prototype._onMouseUp=function(t){var e=t.timeStamp-this._mouseDownTimeStamp;if(this._removeMouseDownListeners(),this.selectionText.length<=1&&e<500&&t.altKey){if(this._bufferService.buffer.ybase===this._bufferService.buffer.ydisp){var n=this._mouseService.getCoords(t,this._element,this._bufferService.cols,this._bufferService.rows,!1);if(n&&void 0!==n[0]&&void 0!==n[1]){var i=p.moveToCellSequence(n[0]-1,n[1]-1,this._bufferService,this._coreService.decPrivateModes.applicationCursorKeys);this._coreService.triggerDataEvent(i,!0)}}}else this.hasSelection&&this._onSelectionChange.fire()},e.prototype._onBufferActivate=function(t){var e=this;this.clearSelection(),this._trimListener.dispose(),this._trimListener=t.activeBuffer.lines.onTrim((function(t){return e._onTrim(t)}))},e.prototype._convertViewportColToCharacterIndex=function(t,e){for(var n=e[0],i=0;e[0]>=i;i++){var r=t.loadCell(i,this._workCell).getChars().length;0===this._workCell.getWidth()?n--:r>1&&e[0]!==i&&(n+=r-1)}return n},e.prototype.setSelection=function(t,e,n){this._model.clearSelection(),this._removeMouseDownListeners(),this._model.selectionStart=[t,e],this._model.selectionStartLength=n,this.refresh()},e.prototype._getWordAt=function(t,e,n,i){if(void 0===n&&(n=!0),void 0===i&&(i=!0),!(t[0]>=this._bufferService.cols)){var r=this._bufferService.buffer,o=r.lines.get(t[1]);if(o){var a=r.translateBufferLineToString(t[1],!1),s=this._convertViewportColToCharacterIndex(o,t),c=s,l=t[0]-s,u=0,h=0,d=0,f=0;if(" "===a.charAt(s)){for(;s>0&&" "===a.charAt(s-1);)s--;for(;c<a.length&&" "===a.charAt(c+1);)c++}else{var p=t[0],m=t[0];0===o.getWidth(p)&&(u++,p--),2===o.getWidth(m)&&(h++,m++);var g=o.getString(m).length;for(g>1&&(f+=g-1,c+=g-1);p>0&&s>0&&!this._isCharWordSeparator(o.loadCell(p-1,this._workCell));){o.loadCell(p-1,this._workCell);var v=this._workCell.getChars().length;0===this._workCell.getWidth()?(u++,p--):v>1&&(d+=v-1,s-=v-1),s--,p--}for(;m<o.length&&c+1<a.length&&!this._isCharWordSeparator(o.loadCell(m+1,this._workCell));){o.loadCell(m+1,this._workCell);var b=this._workCell.getChars().length;2===this._workCell.getWidth()?(h++,m++):b>1&&(f+=b-1,c+=b-1),c++,m++}}c++;var y=s+l-u+d,_=Math.min(this._bufferService.cols,c-s+u+h-d-f);if(e||""!==a.slice(s,c).trim()){if(n&&0===y&&32!==o.getCodePoint(0)){var w=r.lines.get(t[1]-1);if(w&&o.isWrapped&&32!==w.getCodePoint(this._bufferService.cols-1)){var k=this._getWordAt([this._bufferService.cols-1,t[1]-1],!1,!0,!1);if(k){var C=this._bufferService.cols-k.start;y-=C,_+=C}}}if(i&&y+_===this._bufferService.cols&&32!==o.getCodePoint(this._bufferService.cols-1)){var S=r.lines.get(t[1]+1);if(S&&S.isWrapped&&32!==S.getCodePoint(0)){var x=this._getWordAt([0,t[1]+1],!1,!1,!0);x&&(_+=x.length)}}return{start:y,length:_}}}}},e.prototype._selectWordAt=function(t,e){var n=this._getWordAt(t,e);if(n){for(;n.start<0;)n.start+=this._bufferService.cols,t[1]--;this._model.selectionStart=[n.start,t[1]],this._model.selectionStartLength=n.length}},e.prototype._selectToWordAt=function(t){var e=this._getWordAt(t,!0);if(e){for(var n=t[1];e.start<0;)e.start+=this._bufferService.cols,n--;if(!this._model.areSelectionValuesReversed())for(;e.start+e.length>this._bufferService.cols;)e.length-=this._bufferService.cols,n++;this._model.selectionEnd=[this._model.areSelectionValuesReversed()?e.start:e.start+e.length,n]}},e.prototype._isCharWordSeparator=function(t){return 0!==t.getWidth()&&this._optionsService.options.wordSeparator.indexOf(t.getChars())>=0},e.prototype._selectLineAt=function(t){var e=this._bufferService.buffer.getWrappedRangeForLine(t);this._model.selectionStart=[0,e.first],this._model.selectionEnd=[this._bufferService.cols,e.last],this._model.selectionStartLength=0},o([a(2,d.IBufferService),a(3,d.ICoreService),a(4,h.IMouseService),a(5,d.IOptionsService),a(6,h.IRenderService)],e)}(m.Disposable);e.SelectionService=b},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SelectionModel=void 0;var i=function(){function t(t){this._bufferService=t,this.isSelectAllActive=!1,this.selectionStartLength=0}return t.prototype.clearSelection=function(){this.selectionStart=void 0,this.selectionEnd=void 0,this.isSelectAllActive=!1,this.selectionStartLength=0},Object.defineProperty(t.prototype,"finalSelectionStart",{get:function(){return this.isSelectAllActive?[0,0]:this.selectionEnd&&this.selectionStart&&this.areSelectionValuesReversed()?this.selectionEnd:this.selectionStart},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"finalSelectionEnd",{get:function(){if(this.isSelectAllActive)return[this._bufferService.cols,this._bufferService.buffer.ybase+this._bufferService.rows-1];if(this.selectionStart){if(!this.selectionEnd||this.areSelectionValuesReversed()){var t=this.selectionStart[0]+this.selectionStartLength;return t>this._bufferService.cols?[t%this._bufferService.cols,this.selectionStart[1]+Math.floor(t/this._bufferService.cols)]:[t,this.selectionStart[1]]}return this.selectionStartLength&&this.selectionEnd[1]===this.selectionStart[1]?[Math.max(this.selectionStart[0]+this.selectionStartLength,this.selectionEnd[0]),this.selectionEnd[1]]:this.selectionEnd}},enumerable:!1,configurable:!0}),t.prototype.areSelectionValuesReversed=function(){var t=this.selectionStart,e=this.selectionEnd;return!(!t||!e)&&(t[1]>e[1]||t[1]===e[1]&&t[0]>e[0])},t.prototype.onTrim=function(t){return this.selectionStart&&(this.selectionStart[1]-=t),this.selectionEnd&&(this.selectionEnd[1]-=t),this.selectionEnd&&this.selectionEnd[1]<0?(this.clearSelection(),!0):(this.selectionStart&&this.selectionStart[1]<0&&(this.selectionStart[1]=0),!1)},t}();e.SelectionModel=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.moveToCellSequence=void 0;var i=n(12);function r(t,e,n,i){var r=t-o(n,t),s=e-o(n,e);return l(Math.abs(r-s)-function(t,e,n){for(var i=0,r=t-o(n,t),s=e-o(n,e),c=0;c<Math.abs(r-s);c++){var l="A"===a(t,e)?-1:1,u=n.buffer.lines.get(r+l*c);u&&u.isWrapped&&i++}return i}(t,e,n),c(a(t,e),i))}function o(t,e){for(var n=0,i=t.buffer.lines.get(e),r=i&&i.isWrapped;r&&e>=0&&e<t.rows;)n++,r=(i=t.buffer.lines.get(--e))&&i.isWrapped;return n}function a(t,e){return t>e?"A":"B"}function s(t,e,n,i,r,o){for(var a=t,s=e,c="";a!==n||s!==i;)a+=r?1:-1,r&&a>o.cols-1?(c+=o.buffer.translateBufferLineToString(s,!1,t,a),a=0,t=0,s++):!r&&a<0&&(c+=o.buffer.translateBufferLineToString(s,!1,0,t+1),t=a=o.cols-1,s--);return c+o.buffer.translateBufferLineToString(s,!1,t,a)}function c(t,e){return i.C0.ESC+(e?"O":"[")+t}function l(t,e){t=Math.floor(t);for(var n="",i=0;i<t;i++)n+=e;return n}e.moveToCellSequence=function(t,e,n,i){var a,u=n.buffer.x,h=n.buffer.y;if(!n.buffer.hasScrollback)return function(t,e,n,i,a,u){return 0===r(e,i,a,u).length?"":l(s(t,e,t,e-o(a,e),!1,a).length,c("D",u))}(u,h,0,e,n,i)+r(h,e,n,i)+function(t,e,n,i,a,u){var h;h=r(e,i,a,u).length>0?i-o(a,i):e;var d=i,f=function(t,e,n,i,a,s){var c;return c=r(n,i,a,s).length>0?i-o(a,i):e,t<n&&c<=i||t>=n&&c<i?"C":"D"}(t,e,n,i,a,u);return l(s(t,h,n,d,"C"===f,a).length,c(f,u))}(u,h,t,e,n,i);if(h===e)return a=u>t?"D":"C",l(Math.abs(u-t),c(a,i));a=h>e?"D":"C";var d=Math.abs(h-e);return l(function(t,e){return e.cols-t}(h>e?t:u,n)+(d-1)*n.cols+1+((h>e?u:t)-1),c(a,i))}},function(t,e,n){"use strict";var i=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},r=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.SoundService=void 0;var o=n(1),a=function(){function t(t){this._optionsService=t}return Object.defineProperty(t,"audioContext",{get:function(){if(!t._audioContext){var e=window.AudioContext||window.webkitAudioContext;if(!e)return console.warn("Web Audio API is not supported by this browser. Consider upgrading to the latest version"),null;t._audioContext=new e}return t._audioContext},enumerable:!1,configurable:!0}),t.prototype.playBellSound=function(){var e=t.audioContext;if(e){var n=e.createBufferSource();e.decodeAudioData(this._base64ToArrayBuffer(this._removeMimeType(this._optionsService.options.bellSound)),(function(t){n.buffer=t,n.connect(e.destination),n.start(0)}))}},t.prototype._base64ToArrayBuffer=function(t){for(var e=window.atob(t),n=e.length,i=new Uint8Array(n),r=0;r<n;r++)i[r]=e.charCodeAt(r);return i.buffer},t.prototype._removeMimeType=function(t){return t.split(",")[1]},t=i([r(0,o.IOptionsService)],t)}();e.SoundService=a},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.MouseZoneManager=void 0;var s=n(2),c=n(7),l=n(5),u=n(1),h=function(t){function e(e,n,i,r,o,a){var s=t.call(this)||this;return s._element=e,s._screenElement=n,s._bufferService=i,s._mouseService=r,s._selectionService=o,s._optionsService=a,s._zones=[],s._areZonesActive=!1,s._lastHoverCoords=[void 0,void 0],s._initialSelectionLength=0,s.register(c.addDisposableDomListener(s._element,"mousedown",(function(t){return s._onMouseDown(t)}))),s._mouseMoveListener=function(t){return s._onMouseMove(t)},s._mouseLeaveListener=function(t){return s._onMouseLeave(t)},s._clickListener=function(t){return s._onClick(t)},s}return r(e,t),e.prototype.dispose=function(){t.prototype.dispose.call(this),this._deactivate()},e.prototype.add=function(t){this._zones.push(t),1===this._zones.length&&this._activate()},e.prototype.clearAll=function(t,e){if(0!==this._zones.length){t&&e||(t=0,e=this._bufferService.rows-1);for(var n=0;n<this._zones.length;n++){var i=this._zones[n];(i.y1>t&&i.y1<=e+1||i.y2>t&&i.y2<=e+1||i.y1<t&&i.y2>e+1)&&(this._currentZone&&this._currentZone===i&&(this._currentZone.leaveCallback(),this._currentZone=void 0),this._zones.splice(n--,1))}0===this._zones.length&&this._deactivate()}},e.prototype._activate=function(){this._areZonesActive||(this._areZonesActive=!0,this._element.addEventListener("mousemove",this._mouseMoveListener),this._element.addEventListener("mouseleave",this._mouseLeaveListener),this._element.addEventListener("click",this._clickListener))},e.prototype._deactivate=function(){this._areZonesActive&&(this._areZonesActive=!1,this._element.removeEventListener("mousemove",this._mouseMoveListener),this._element.removeEventListener("mouseleave",this._mouseLeaveListener),this._element.removeEventListener("click",this._clickListener))},e.prototype._onMouseMove=function(t){this._lastHoverCoords[0]===t.pageX&&this._lastHoverCoords[1]===t.pageY||(this._onHover(t),this._lastHoverCoords=[t.pageX,t.pageY])},e.prototype._onHover=function(t){var e=this,n=this._findZoneEventAt(t);n!==this._currentZone&&(this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=void 0,this._tooltipTimeout&&clearTimeout(this._tooltipTimeout)),n&&(this._currentZone=n,n.hoverCallback&&n.hoverCallback(t),this._tooltipTimeout=window.setTimeout((function(){return e._onTooltip(t)}),this._optionsService.options.linkTooltipHoverDuration)))},e.prototype._onTooltip=function(t){this._tooltipTimeout=void 0;var e=this._findZoneEventAt(t);e&&e.tooltipCallback&&e.tooltipCallback(t)},e.prototype._onMouseDown=function(t){if(this._initialSelectionLength=this._getSelectionLength(),this._areZonesActive){var e=this._findZoneEventAt(t);(null==e?void 0:e.willLinkActivate(t))&&(t.preventDefault(),t.stopImmediatePropagation())}},e.prototype._onMouseLeave=function(t){this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=void 0,this._tooltipTimeout&&clearTimeout(this._tooltipTimeout))},e.prototype._onClick=function(t){var e=this._findZoneEventAt(t),n=this._getSelectionLength();e&&n===this._initialSelectionLength&&(e.clickCallback(t),t.preventDefault(),t.stopImmediatePropagation())},e.prototype._getSelectionLength=function(){var t=this._selectionService.selectionText;return t?t.length:0},e.prototype._findZoneEventAt=function(t){var e=this._mouseService.getCoords(t,this._screenElement,this._bufferService.cols,this._bufferService.rows);if(e)for(var n=e[0],i=e[1],r=0;r<this._zones.length;r++){var o=this._zones[r];if(o.y1===o.y2){if(i===o.y1&&n>=o.x1&&n<o.x2)return o}else if(i===o.y1&&n>=o.x1||i===o.y2&&n<o.x2||i>o.y1&&i<o.y2)return o}},o([a(2,u.IBufferService),a(3,l.IMouseService),a(4,l.ISelectionService),a(5,u.IOptionsService)],e)}(s.Disposable);e.MouseZoneManager=h},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.AccessibilityManager=void 0;var o=n(18),a=n(11),s=n(31),c=n(7),l=n(2),u=n(32),h=n(17),d=function(t){function e(e,n){var i=t.call(this)||this;i._terminal=e,i._renderService=n,i._liveRegionLineCount=0,i._charsToConsume=[],i._charsToAnnounce="",i._accessibilityTreeRoot=document.createElement("div"),i._accessibilityTreeRoot.classList.add("xterm-accessibility"),i._rowContainer=document.createElement("div"),i._rowContainer.classList.add("xterm-accessibility-tree"),i._rowContainer.setAttribute("role","list"),i._rowElements=[];for(var r=0;r<i._terminal.rows;r++)i._rowElements[r]=i._createAccessibilityTreeNode(),i._rowContainer.appendChild(i._rowElements[r]);if(i._topBoundaryFocusListener=function(t){return i._onBoundaryFocus(t,0)},i._bottomBoundaryFocusListener=function(t){return i._onBoundaryFocus(t,1)},i._rowElements[0].addEventListener("focus",i._topBoundaryFocusListener),i._rowElements[i._rowElements.length-1].addEventListener("focus",i._bottomBoundaryFocusListener),i._refreshRowsDimensions(),i._accessibilityTreeRoot.appendChild(i._rowContainer),i._renderRowsDebouncer=new s.RenderDebouncer(i._renderRows.bind(i)),i._refreshRows(),i._liveRegion=document.createElement("div"),i._liveRegion.classList.add("live-region"),i._liveRegion.setAttribute("aria-live","assertive"),i._accessibilityTreeRoot.appendChild(i._liveRegion),!i._terminal.element)throw new Error("Cannot enable accessibility before Terminal.open");return i._terminal.element.insertAdjacentElement("afterbegin",i._accessibilityTreeRoot),i.register(i._renderRowsDebouncer),i.register(i._terminal.onResize((function(t){return i._onResize(t.rows)}))),i.register(i._terminal.onRender((function(t){return i._refreshRows(t.start,t.end)}))),i.register(i._terminal.onScroll((function(){return i._refreshRows()}))),i.register(i._terminal.onA11yChar((function(t){return i._onChar(t)}))),i.register(i._terminal.onLineFeed((function(){return i._onChar("\n")}))),i.register(i._terminal.onA11yTab((function(t){return i._onTab(t)}))),i.register(i._terminal.onKey((function(t){return i._onKey(t.key)}))),i.register(i._terminal.onBlur((function(){return i._clearLiveRegion()}))),i.register(i._renderService.onDimensionsChange((function(){return i._refreshRowsDimensions()}))),i._screenDprMonitor=new u.ScreenDprMonitor,i.register(i._screenDprMonitor),i._screenDprMonitor.setListener((function(){return i._refreshRowsDimensions()})),i.register(c.addDisposableDomListener(window,"resize",(function(){return i._refreshRowsDimensions()}))),i}return r(e,t),e.prototype.dispose=function(){t.prototype.dispose.call(this),h.removeElementFromParent(this._accessibilityTreeRoot),this._rowElements.length=0},e.prototype._onBoundaryFocus=function(t,e){var n=t.target,i=this._rowElements[0===e?1:this._rowElements.length-2];if(n.getAttribute("aria-posinset")!==(0===e?"1":""+this._terminal.buffer.lines.length)&&t.relatedTarget===i){var r,o;if(0===e?(r=n,o=this._rowElements.pop(),this._rowContainer.removeChild(o)):(r=this._rowElements.shift(),o=n,this._rowContainer.removeChild(r)),r.removeEventListener("focus",this._topBoundaryFocusListener),o.removeEventListener("focus",this._bottomBoundaryFocusListener),0===e){var a=this._createAccessibilityTreeNode();this._rowElements.unshift(a),this._rowContainer.insertAdjacentElement("afterbegin",a)}else 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===e?-1:1),this._rowElements[0===e?1:this._rowElements.length-2].focus(),t.preventDefault(),t.stopImmediatePropagation()}},e.prototype._onResize=function(t){this._rowElements[this._rowElements.length-1].removeEventListener("focus",this._bottomBoundaryFocusListener);for(var e=this._rowContainer.children.length;e<this._terminal.rows;e++)this._rowElements[e]=this._createAccessibilityTreeNode(),this._rowContainer.appendChild(this._rowElements[e]);for(;this._rowElements.length>t;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()},e.prototype._createAccessibilityTreeNode=function(){var t=document.createElement("div");return t.setAttribute("role","listitem"),t.tabIndex=-1,this._refreshRowDimensions(t),t},e.prototype._onTab=function(t){for(var e=0;e<t;e++)this._onChar(" ")},e.prototype._onChar=function(t){var e=this;this._liveRegionLineCount<21&&(this._charsToConsume.length>0?this._charsToConsume.shift()!==t&&(this._charsToAnnounce+=t):this._charsToAnnounce+=t,"\n"===t&&(this._liveRegionLineCount++,21===this._liveRegionLineCount&&(this._liveRegion.textContent+=o.tooMuchOutput)),a.isMac&&this._liveRegion.textContent&&this._liveRegion.textContent.length>0&&!this._liveRegion.parentNode&&setTimeout((function(){e._accessibilityTreeRoot.appendChild(e._liveRegion)}),0))},e.prototype._clearLiveRegion=function(){this._liveRegion.textContent="",this._liveRegionLineCount=0,a.isMac&&h.removeElementFromParent(this._liveRegion)},e.prototype._onKey=function(t){this._clearLiveRegion(),this._charsToConsume.push(t)},e.prototype._refreshRows=function(t,e){this._renderRowsDebouncer.refresh(t,e,this._terminal.rows)},e.prototype._renderRows=function(t,e){for(var n=this._terminal.buffer,i=n.lines.length.toString(),r=t;r<=e;r++){var o=n.translateBufferLineToString(n.ydisp+r,!0),a=(n.ydisp+r+1).toString(),s=this._rowElements[r];s&&(0===o.length?s.innerHTML="&nbsp;":s.textContent=o,s.setAttribute("aria-posinset",a),s.setAttribute("aria-setsize",i))}this._announceCharacters()},e.prototype._refreshRowsDimensions=function(){if(this._renderService.dimensions.actualCellHeight){this._rowElements.length!==this._terminal.rows&&this._onResize(this._terminal.rows);for(var t=0;t<this._terminal.rows;t++)this._refreshRowDimensions(this._rowElements[t])}},e.prototype._refreshRowDimensions=function(t){t.style.height=this._renderService.dimensions.actualCellHeight+"px"},e.prototype._announceCharacters=function(){0!==this._charsToAnnounce.length&&(this._liveRegion.textContent+=this._charsToAnnounce,this._charsToAnnounce="")},e}(l.Disposable);e.AccessibilityManager=d},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.DomRenderer=void 0;var s=n(58),c=n(9),l=n(2),u=n(5),h=n(1),d=n(0),f=n(10),p=n(17),m=1,g=function(t){function e(e,n,i,r,o,a,c,l,u){var h=t.call(this)||this;return h._colors=e,h._element=n,h._screenElement=i,h._viewportElement=r,h._linkifier=o,h._linkifier2=a,h._charSizeService=c,h._optionsService=l,h._bufferService=u,h._terminalClass=m++,h._rowElements=[],h._rowContainer=document.createElement("div"),h._rowContainer.classList.add("xterm-rows"),h._rowContainer.style.lineHeight="normal",h._rowContainer.setAttribute("aria-hidden","true"),h._refreshRowElements(h._bufferService.cols,h._bufferService.rows),h._selectionContainer=document.createElement("div"),h._selectionContainer.classList.add("xterm-selection"),h._selectionContainer.setAttribute("aria-hidden","true"),h.dimensions={scaledCharWidth:0,scaledCharHeight:0,scaledCellWidth:0,scaledCellHeight:0,scaledCharLeft:0,scaledCharTop:0,scaledCanvasWidth:0,scaledCanvasHeight:0,canvasWidth:0,canvasHeight:0,actualCellWidth:0,actualCellHeight:0},h._updateDimensions(),h._injectCss(),h._rowFactory=new s.DomRendererRowFactory(document,h._optionsService,h._colors),h._element.classList.add("xterm-dom-renderer-owner-"+h._terminalClass),h._screenElement.appendChild(h._rowContainer),h._screenElement.appendChild(h._selectionContainer),h._linkifier.onShowLinkUnderline((function(t){return h._onLinkHover(t)})),h._linkifier.onHideLinkUnderline((function(t){return h._onLinkLeave(t)})),h._linkifier2.onShowLinkUnderline((function(t){return h._onLinkHover(t)})),h._linkifier2.onHideLinkUnderline((function(t){return h._onLinkLeave(t)})),h}return r(e,t),Object.defineProperty(e.prototype,"onRequestRedraw",{get:function(){return(new d.EventEmitter).event},enumerable:!1,configurable:!0}),e.prototype.dispose=function(){this._element.classList.remove("xterm-dom-renderer-owner-"+this._terminalClass),p.removeElementFromParent(this._rowContainer,this._selectionContainer,this._themeStyleElement,this._dimensionsStyleElement),t.prototype.dispose.call(this)},e.prototype._updateDimensions=function(){this.dimensions.scaledCharWidth=this._charSizeService.width*window.devicePixelRatio,this.dimensions.scaledCharHeight=Math.ceil(this._charSizeService.height*window.devicePixelRatio),this.dimensions.scaledCellWidth=this.dimensions.scaledCharWidth+Math.round(this._optionsService.options.letterSpacing),this.dimensions.scaledCellHeight=Math.floor(this.dimensions.scaledCharHeight*this._optionsService.options.lineHeight),this.dimensions.scaledCharLeft=0,this.dimensions.scaledCharTop=0,this.dimensions.scaledCanvasWidth=this.dimensions.scaledCellWidth*this._bufferService.cols,this.dimensions.scaledCanvasHeight=this.dimensions.scaledCellHeight*this._bufferService.rows,this.dimensions.canvasWidth=Math.round(this.dimensions.scaledCanvasWidth/window.devicePixelRatio),this.dimensions.canvasHeight=Math.round(this.dimensions.scaledCanvasHeight/window.devicePixelRatio),this.dimensions.actualCellWidth=this.dimensions.canvasWidth/this._bufferService.cols,this.dimensions.actualCellHeight=this.dimensions.canvasHeight/this._bufferService.rows;for(var t=0,e=this._rowElements;t<e.length;t++){var n=e[t];n.style.width=this.dimensions.canvasWidth+"px",n.style.height=this.dimensions.actualCellHeight+"px",n.style.lineHeight=this.dimensions.actualCellHeight+"px",n.style.overflow="hidden"}this._dimensionsStyleElement||(this._dimensionsStyleElement=document.createElement("style"),this._screenElement.appendChild(this._dimensionsStyleElement)),this._dimensionsStyleElement.innerHTML=this._terminalSelector+" .xterm-rows span { display: inline-block; height: 100%; vertical-align: top; width: "+this.dimensions.actualCellWidth+"px}",this._selectionContainer.style.height=this._viewportElement.style.height,this._screenElement.style.width=this.dimensions.canvasWidth+"px",this._screenElement.style.height=this.dimensions.canvasHeight+"px"},e.prototype.setColors=function(t){this._colors=t,this._injectCss()},e.prototype._injectCss=function(){var t=this;this._themeStyleElement||(this._themeStyleElement=document.createElement("style"),this._screenElement.appendChild(this._themeStyleElement));var e=this._terminalSelector+" .xterm-rows { color: "+this._colors.foreground.css+"; font-family: "+this._optionsService.options.fontFamily+"; font-size: "+this._optionsService.options.fontSize+"px;}";e+=this._terminalSelector+" span:not(."+s.BOLD_CLASS+") { font-weight: "+this._optionsService.options.fontWeight+";}"+this._terminalSelector+" span."+s.BOLD_CLASS+" { font-weight: "+this._optionsService.options.fontWeightBold+";}"+this._terminalSelector+" span."+s.ITALIC_CLASS+" { font-style: italic;}",e+="@keyframes blink_box_shadow_"+this._terminalClass+" { 50% { box-shadow: none; }}",e+="@keyframes blink_block_"+this._terminalClass+" { 0% { background-color: "+this._colors.cursor.css+"; color: "+this._colors.cursorAccent.css+"; } 50% { background-color: "+this._colors.cursorAccent.css+"; color: "+this._colors.cursor.css+"; }}",e+=this._terminalSelector+" .xterm-rows:not(.xterm-focus) ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_BLOCK_CLASS+" { outline: 1px solid "+this._colors.cursor.css+"; outline-offset: -1px;}"+this._terminalSelector+" .xterm-rows.xterm-focus ."+s.CURSOR_CLASS+"."+s.CURSOR_BLINK_CLASS+":not(."+s.CURSOR_STYLE_BLOCK_CLASS+") { animation: blink_box_shadow_"+this._terminalClass+" 1s step-end infinite;}"+this._terminalSelector+" .xterm-rows.xterm-focus ."+s.CURSOR_CLASS+"."+s.CURSOR_BLINK_CLASS+"."+s.CURSOR_STYLE_BLOCK_CLASS+" { animation: blink_block_"+this._terminalClass+" 1s step-end infinite;}"+this._terminalSelector+" .xterm-rows.xterm-focus ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_BLOCK_CLASS+" { background-color: "+this._colors.cursor.css+"; color: "+this._colors.cursorAccent.css+";}"+this._terminalSelector+" .xterm-rows ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_BAR_CLASS+" { box-shadow: "+this._optionsService.options.cursorWidth+"px 0 0 "+this._colors.cursor.css+" inset;}"+this._terminalSelector+" .xterm-rows ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_UNDERLINE_CLASS+" { box-shadow: 0 -1px 0 "+this._colors.cursor.css+" inset;}",e+=this._terminalSelector+" .xterm-selection { position: absolute; top: 0; left: 0; z-index: 1; pointer-events: none;}"+this._terminalSelector+" .xterm-selection div { position: absolute; background-color: "+this._colors.selectionTransparent.css+";}",this._colors.ansi.forEach((function(n,i){e+=t._terminalSelector+" .xterm-fg-"+i+" { color: "+n.css+"; }"+t._terminalSelector+" .xterm-bg-"+i+" { background-color: "+n.css+"; }"})),e+=this._terminalSelector+" .xterm-fg-"+c.INVERTED_DEFAULT_COLOR+" { color: "+f.color.opaque(this._colors.background).css+"; }"+this._terminalSelector+" .xterm-bg-"+c.INVERTED_DEFAULT_COLOR+" { background-color: "+this._colors.foreground.css+"; }",this._themeStyleElement.innerHTML=e},e.prototype.onDevicePixelRatioChange=function(){this._updateDimensions()},e.prototype._refreshRowElements=function(t,e){for(var n=this._rowElements.length;n<=e;n++){var i=document.createElement("div");this._rowContainer.appendChild(i),this._rowElements.push(i)}for(;this._rowElements.length>e;)this._rowContainer.removeChild(this._rowElements.pop())},e.prototype.onResize=function(t,e){this._refreshRowElements(t,e),this._updateDimensions()},e.prototype.onCharSizeChanged=function(){this._updateDimensions()},e.prototype.onBlur=function(){this._rowContainer.classList.remove("xterm-focus")},e.prototype.onFocus=function(){this._rowContainer.classList.add("xterm-focus")},e.prototype.onSelectionChanged=function(t,e,n){for(;this._selectionContainer.children.length;)this._selectionContainer.removeChild(this._selectionContainer.children[0]);if(t&&e){var i=t[1]-this._bufferService.buffer.ydisp,r=e[1]-this._bufferService.buffer.ydisp,o=Math.max(i,0),a=Math.min(r,this._bufferService.rows-1);if(!(o>=this._bufferService.rows||a<0)){var s=document.createDocumentFragment();n?s.appendChild(this._createSelectionElement(o,t[0],e[0],a-o+1)):(s.appendChild(this._createSelectionElement(o,i===o?t[0]:0,o===a?e[0]:this._bufferService.cols)),s.appendChild(this._createSelectionElement(o+1,0,this._bufferService.cols,a-o-1)),o!==a&&s.appendChild(this._createSelectionElement(a,0,r===a?e[0]:this._bufferService.cols))),this._selectionContainer.appendChild(s)}}},e.prototype._createSelectionElement=function(t,e,n,i){void 0===i&&(i=1);var r=document.createElement("div");return r.style.height=i*this.dimensions.actualCellHeight+"px",r.style.top=t*this.dimensions.actualCellHeight+"px",r.style.left=e*this.dimensions.actualCellWidth+"px",r.style.width=this.dimensions.actualCellWidth*(n-e)+"px",r},e.prototype.onCursorMove=function(){},e.prototype.onOptionsChanged=function(){this._updateDimensions(),this._injectCss()},e.prototype.clear=function(){for(var t=0,e=this._rowElements;t<e.length;t++)e[t].innerHTML=""},e.prototype.renderRows=function(t,e){for(var n=this._bufferService.buffer.ybase+this._bufferService.buffer.y,i=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1),r=this._optionsService.options.cursorBlink,o=t;o<=e;o++){var a=this._rowElements[o];a.innerHTML="";var s=o+this._bufferService.buffer.ydisp,c=this._bufferService.buffer.lines.get(s);a.appendChild(this._rowFactory.createRow(c,s===n,this._optionsService.options.cursorStyle,i,r,this.dimensions.actualCellWidth,this._bufferService.cols))}},Object.defineProperty(e.prototype,"_terminalSelector",{get:function(){return".xterm-dom-renderer-owner-"+this._terminalClass},enumerable:!1,configurable:!0}),e.prototype.registerCharacterJoiner=function(t){return-1},e.prototype.deregisterCharacterJoiner=function(t){return!1},e.prototype._onLinkHover=function(t){this._setCellUnderline(t.x1,t.x2,t.y1,t.y2,t.cols,!0)},e.prototype._onLinkLeave=function(t){this._setCellUnderline(t.x1,t.x2,t.y1,t.y2,t.cols,!1)},e.prototype._setCellUnderline=function(t,e,n,i,r,o){for(;t!==e||n!==i;){var a=this._rowElements[n];if(!a)return;var s=a.children[t];s&&(s.style.textDecoration=o?"underline":"none"),++t>=r&&(t=0,n++)}},o([a(6,u.ICharSizeService),a(7,h.IOptionsService),a(8,h.IBufferService)],e)}(l.Disposable);e.DomRenderer=g},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DomRendererRowFactory=e.CURSOR_STYLE_UNDERLINE_CLASS=e.CURSOR_STYLE_BAR_CLASS=e.CURSOR_STYLE_BLOCK_CLASS=e.CURSOR_BLINK_CLASS=e.CURSOR_CLASS=e.UNDERLINE_CLASS=e.ITALIC_CLASS=e.DIM_CLASS=e.BOLD_CLASS=void 0;var i=n(9),r=n(3),o=n(4),a=n(10);e.BOLD_CLASS="xterm-bold",e.DIM_CLASS="xterm-dim",e.ITALIC_CLASS="xterm-italic",e.UNDERLINE_CLASS="xterm-underline",e.CURSOR_CLASS="xterm-cursor",e.CURSOR_BLINK_CLASS="xterm-cursor-blink",e.CURSOR_STYLE_BLOCK_CLASS="xterm-cursor-block",e.CURSOR_STYLE_BAR_CLASS="xterm-cursor-bar",e.CURSOR_STYLE_UNDERLINE_CLASS="xterm-cursor-underline";var s=function(){function t(t,e,n){this._document=t,this._optionsService=e,this._colors=n,this._workCell=new o.CellData}return t.prototype.setColors=function(t){this._colors=t},t.prototype.createRow=function(t,n,o,s,l,u,h){for(var d=this._document.createDocumentFragment(),f=0,p=Math.min(t.length,h)-1;p>=0;p--)if(t.loadCell(p,this._workCell).getCode()!==r.NULL_CELL_CODE||n&&p===s){f=p+1;break}for(p=0;p<f;p++){t.loadCell(p,this._workCell);var m=this._workCell.getWidth();if(0!==m){var g=this._document.createElement("span");if(m>1&&(g.style.width=u*m+"px"),n&&p===s)switch(g.classList.add(e.CURSOR_CLASS),l&&g.classList.add(e.CURSOR_BLINK_CLASS),o){case"bar":g.classList.add(e.CURSOR_STYLE_BAR_CLASS);break;case"underline":g.classList.add(e.CURSOR_STYLE_UNDERLINE_CLASS);break;default:g.classList.add(e.CURSOR_STYLE_BLOCK_CLASS)}this._workCell.isBold()&&g.classList.add(e.BOLD_CLASS),this._workCell.isItalic()&&g.classList.add(e.ITALIC_CLASS),this._workCell.isDim()&&g.classList.add(e.DIM_CLASS),this._workCell.isUnderline()&&g.classList.add(e.UNDERLINE_CLASS),g.textContent=this._workCell.isInvisible()?r.WHITESPACE_CELL_CHAR:this._workCell.getChars()||r.WHITESPACE_CELL_CHAR;var v=this._workCell.getFgColor(),b=this._workCell.getFgColorMode(),y=this._workCell.getBgColor(),_=this._workCell.getBgColorMode(),w=!!this._workCell.isInverse();if(w){var k=v;v=y,y=k;var C=b;b=_,_=C}switch(b){case 16777216:case 33554432:this._workCell.isBold()&&v<8&&this._optionsService.options.drawBoldTextInBrightColors&&(v+=8),this._applyMinimumContrast(g,this._colors.background,this._colors.ansi[v])||g.classList.add("xterm-fg-"+v);break;case 50331648:var S=a.rgba.toColor(v>>16&255,v>>8&255,255&v);this._applyMinimumContrast(g,this._colors.background,S)||this._addStyle(g,"color:#"+c(v.toString(16),"0",6));break;case 0:default:this._applyMinimumContrast(g,this._colors.background,this._colors.foreground)||w&&g.classList.add("xterm-fg-"+i.INVERTED_DEFAULT_COLOR)}switch(_){case 16777216:case 33554432:g.classList.add("xterm-bg-"+y);break;case 50331648:this._addStyle(g,"background-color:#"+c(y.toString(16),"0",6));break;case 0:default:w&&g.classList.add("xterm-bg-"+i.INVERTED_DEFAULT_COLOR)}d.appendChild(g)}}return d},t.prototype._applyMinimumContrast=function(t,e,n){if(1===this._optionsService.options.minimumContrastRatio)return!1;var i=this._colors.contrastCache.getColor(this._workCell.bg,this._workCell.fg);return void 0===i&&(i=a.color.ensureContrastRatio(e,n,this._optionsService.options.minimumContrastRatio),this._colors.contrastCache.setColor(this._workCell.bg,this._workCell.fg,null!=i?i:null)),!!i&&(this._addStyle(t,"color:"+i.css),!0)},t.prototype._addStyle=function(t,e){t.setAttribute("style",""+(t.getAttribute("style")||"")+e+";")},t}();function c(t,e,n){for(;t.length<n;)t=e+t;return t}e.DomRendererRowFactory=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.evaluateKeyboardEvent=void 0;var i=n(12),r={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:["'",'"']};e.evaluateKeyboardEvent=function(t,e,n,o){var a={type:0,cancel:!1,key:void 0},s=(t.shiftKey?1:0)|(t.altKey?2:0)|(t.ctrlKey?4:0)|(t.metaKey?8:0);switch(t.keyCode){case 0:"UIKeyInputUpArrow"===t.key?a.key=e?i.C0.ESC+"OA":i.C0.ESC+"[A":"UIKeyInputLeftArrow"===t.key?a.key=e?i.C0.ESC+"OD":i.C0.ESC+"[D":"UIKeyInputRightArrow"===t.key?a.key=e?i.C0.ESC+"OC":i.C0.ESC+"[C":"UIKeyInputDownArrow"===t.key&&(a.key=e?i.C0.ESC+"OB":i.C0.ESC+"[B");break;case 8:if(t.shiftKey){a.key=i.C0.BS;break}if(t.altKey){a.key=i.C0.ESC+i.C0.DEL;break}a.key=i.C0.DEL;break;case 9:if(t.shiftKey){a.key=i.C0.ESC+"[Z";break}a.key=i.C0.HT,a.cancel=!0;break;case 13:a.key=t.altKey?i.C0.ESC+i.C0.CR:i.C0.CR,a.cancel=!0;break;case 27:a.key=i.C0.ESC,t.altKey&&(a.key=i.C0.ESC+i.C0.ESC),a.cancel=!0;break;case 37:if(t.metaKey)break;s?(a.key=i.C0.ESC+"[1;"+(s+1)+"D",a.key===i.C0.ESC+"[1;3D"&&(a.key=i.C0.ESC+(n?"b":"[1;5D"))):a.key=e?i.C0.ESC+"OD":i.C0.ESC+"[D";break;case 39:if(t.metaKey)break;s?(a.key=i.C0.ESC+"[1;"+(s+1)+"C",a.key===i.C0.ESC+"[1;3C"&&(a.key=i.C0.ESC+(n?"f":"[1;5C"))):a.key=e?i.C0.ESC+"OC":i.C0.ESC+"[C";break;case 38:if(t.metaKey)break;s?(a.key=i.C0.ESC+"[1;"+(s+1)+"A",n||a.key!==i.C0.ESC+"[1;3A"||(a.key=i.C0.ESC+"[1;5A")):a.key=e?i.C0.ESC+"OA":i.C0.ESC+"[A";break;case 40:if(t.metaKey)break;s?(a.key=i.C0.ESC+"[1;"+(s+1)+"B",n||a.key!==i.C0.ESC+"[1;3B"||(a.key=i.C0.ESC+"[1;5B")):a.key=e?i.C0.ESC+"OB":i.C0.ESC+"[B";break;case 45:t.shiftKey||t.ctrlKey||(a.key=i.C0.ESC+"[2~");break;case 46:a.key=s?i.C0.ESC+"[3;"+(s+1)+"~":i.C0.ESC+"[3~";break;case 36:a.key=s?i.C0.ESC+"[1;"+(s+1)+"H":e?i.C0.ESC+"OH":i.C0.ESC+"[H";break;case 35:a.key=s?i.C0.ESC+"[1;"+(s+1)+"F":e?i.C0.ESC+"OF":i.C0.ESC+"[F";break;case 33:t.shiftKey?a.type=2:a.key=i.C0.ESC+"[5~";break;case 34:t.shiftKey?a.type=3:a.key=i.C0.ESC+"[6~";break;case 112:a.key=s?i.C0.ESC+"[1;"+(s+1)+"P":i.C0.ESC+"OP";break;case 113:a.key=s?i.C0.ESC+"[1;"+(s+1)+"Q":i.C0.ESC+"OQ";break;case 114:a.key=s?i.C0.ESC+"[1;"+(s+1)+"R":i.C0.ESC+"OR";break;case 115:a.key=s?i.C0.ESC+"[1;"+(s+1)+"S":i.C0.ESC+"OS";break;case 116:a.key=s?i.C0.ESC+"[15;"+(s+1)+"~":i.C0.ESC+"[15~";break;case 117:a.key=s?i.C0.ESC+"[17;"+(s+1)+"~":i.C0.ESC+"[17~";break;case 118:a.key=s?i.C0.ESC+"[18;"+(s+1)+"~":i.C0.ESC+"[18~";break;case 119:a.key=s?i.C0.ESC+"[19;"+(s+1)+"~":i.C0.ESC+"[19~";break;case 120:a.key=s?i.C0.ESC+"[20;"+(s+1)+"~":i.C0.ESC+"[20~";break;case 121:a.key=s?i.C0.ESC+"[21;"+(s+1)+"~":i.C0.ESC+"[21~";break;case 122:a.key=s?i.C0.ESC+"[23;"+(s+1)+"~":i.C0.ESC+"[23~";break;case 123:a.key=s?i.C0.ESC+"[24;"+(s+1)+"~":i.C0.ESC+"[24~";break;default:if(!t.ctrlKey||t.shiftKey||t.altKey||t.metaKey)if(n&&!o||!t.altKey||t.metaKey)n&&!t.altKey&&!t.ctrlKey&&t.metaKey?65===t.keyCode&&(a.type=1):t.key&&!t.ctrlKey&&!t.altKey&&!t.metaKey&&t.keyCode>=48&&1===t.key.length?a.key=t.key:t.key&&t.ctrlKey&&"_"===t.key&&(a.key=i.C0.US);else{var c=r[t.keyCode],l=c&&c[t.shiftKey?1:0];l?a.key=i.C0.ESC+l:t.keyCode>=65&&t.keyCode<=90&&(a.key=i.C0.ESC+String.fromCharCode(t.ctrlKey?t.keyCode-64:t.keyCode+32))}else t.keyCode>=65&&t.keyCode<=90?a.key=String.fromCharCode(t.keyCode-64):32===t.keyCode?a.key=i.C0.NUL:t.keyCode>=51&&t.keyCode<=55?a.key=String.fromCharCode(t.keyCode-51+27):56===t.keyCode?a.key=i.C0.DEL:219===t.keyCode?a.key=i.C0.ESC:220===t.keyCode?a.key=i.C0.FS:221===t.keyCode&&(a.key=i.C0.GS)}return a}},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.RenderService=void 0;var s=n(31),c=n(0),l=n(2),u=n(32),h=n(7),d=n(1),f=n(5),p=function(t){function e(e,n,i,r,o,a){var l=t.call(this)||this;if(l._renderer=e,l._rowCount=n,l._isPaused=!1,l._needsFullRefresh=!1,l._isNextRenderRedrawOnly=!0,l._needsSelectionRefresh=!1,l._canvasWidth=0,l._canvasHeight=0,l._selectionState={start:void 0,end:void 0,columnSelectMode:!1},l._onDimensionsChange=new c.EventEmitter,l._onRender=new c.EventEmitter,l._onRefreshRequest=new c.EventEmitter,l.register({dispose:function(){return l._renderer.dispose()}}),l._renderDebouncer=new s.RenderDebouncer((function(t,e){return l._renderRows(t,e)})),l.register(l._renderDebouncer),l._screenDprMonitor=new u.ScreenDprMonitor,l._screenDprMonitor.setListener((function(){return l.onDevicePixelRatioChange()})),l.register(l._screenDprMonitor),l.register(a.onResize((function(t){return l._fullRefresh()}))),l.register(r.onOptionChange((function(){return l._renderer.onOptionsChanged()}))),l.register(o.onCharSizeChange((function(){return l.onCharSizeChanged()}))),l._renderer.onRequestRedraw((function(t){return l.refreshRows(t.start,t.end,!0)})),l.register(h.addDisposableDomListener(window,"resize",(function(){return l.onDevicePixelRatioChange()}))),"IntersectionObserver"in window){var d=new IntersectionObserver((function(t){return l._onIntersectionChange(t[t.length-1])}),{threshold:0});d.observe(i),l.register({dispose:function(){return d.disconnect()}})}return l}return r(e,t),Object.defineProperty(e.prototype,"onDimensionsChange",{get:function(){return this._onDimensionsChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRenderedBufferChange",{get:function(){return this._onRender.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onRefreshRequest",{get:function(){return this._onRefreshRequest.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dimensions",{get:function(){return this._renderer.dimensions},enumerable:!1,configurable:!0}),e.prototype._onIntersectionChange=function(t){this._isPaused=0===t.intersectionRatio,!this._isPaused&&this._needsFullRefresh&&(this.refreshRows(0,this._rowCount-1),this._needsFullRefresh=!1)},e.prototype.refreshRows=function(t,e,n){void 0===n&&(n=!1),this._isPaused?this._needsFullRefresh=!0:(n||(this._isNextRenderRedrawOnly=!1),this._renderDebouncer.refresh(t,e,this._rowCount))},e.prototype._renderRows=function(t,e){this._renderer.renderRows(t,e),this._needsSelectionRefresh&&(this._renderer.onSelectionChanged(this._selectionState.start,this._selectionState.end,this._selectionState.columnSelectMode),this._needsSelectionRefresh=!1),this._isNextRenderRedrawOnly||this._onRender.fire({start:t,end:e}),this._isNextRenderRedrawOnly=!0},e.prototype.resize=function(t,e){this._rowCount=e,this._fireOnCanvasResize()},e.prototype.changeOptions=function(){this._renderer.onOptionsChanged(),this.refreshRows(0,this._rowCount-1),this._fireOnCanvasResize()},e.prototype._fireOnCanvasResize=function(){this._renderer.dimensions.canvasWidth===this._canvasWidth&&this._renderer.dimensions.canvasHeight===this._canvasHeight||this._onDimensionsChange.fire(this._renderer.dimensions)},e.prototype.dispose=function(){t.prototype.dispose.call(this)},e.prototype.setRenderer=function(t){var e=this;this._renderer.dispose(),this._renderer=t,this._renderer.onRequestRedraw((function(t){return e.refreshRows(t.start,t.end,!0)})),this._needsSelectionRefresh=!0,this._fullRefresh()},e.prototype._fullRefresh=function(){this._isPaused?this._needsFullRefresh=!0:this.refreshRows(0,this._rowCount-1)},e.prototype.setColors=function(t){this._renderer.setColors(t),this._fullRefresh()},e.prototype.onDevicePixelRatioChange=function(){this._renderer.onDevicePixelRatioChange(),this.refreshRows(0,this._rowCount-1)},e.prototype.onResize=function(t,e){this._renderer.onResize(t,e),this._fullRefresh()},e.prototype.onCharSizeChanged=function(){this._renderer.onCharSizeChanged()},e.prototype.onBlur=function(){this._renderer.onBlur()},e.prototype.onFocus=function(){this._renderer.onFocus()},e.prototype.onSelectionChanged=function(t,e,n){this._selectionState.start=t,this._selectionState.end=e,this._selectionState.columnSelectMode=n,this._renderer.onSelectionChanged(t,e,n)},e.prototype.onCursorMove=function(){this._renderer.onCursorMove()},e.prototype.clear=function(){this._renderer.clear()},e.prototype.registerCharacterJoiner=function(t){return this._renderer.registerCharacterJoiner(t)},e.prototype.deregisterCharacterJoiner=function(t){return this._renderer.deregisterCharacterJoiner(t)},o([a(3,d.IOptionsService),a(4,f.ICharSizeService),a(5,d.IBufferService)],e)}(l.Disposable);e.RenderService=p},function(t,e,n){"use strict";var i=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},r=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.CharSizeService=void 0;var o=n(1),a=n(0),s=function(){function t(t,e,n){this._optionsService=n,this.width=0,this.height=0,this._onCharSizeChange=new a.EventEmitter,this._measureStrategy=new c(t,e,this._optionsService)}return Object.defineProperty(t.prototype,"hasValidSize",{get:function(){return this.width>0&&this.height>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onCharSizeChange",{get:function(){return this._onCharSizeChange.event},enumerable:!1,configurable:!0}),t.prototype.measure=function(){var t=this._measureStrategy.measure();t.width===this.width&&t.height===this.height||(this.width=t.width,this.height=t.height,this._onCharSizeChange.fire())},i([r(2,o.IOptionsService)],t)}();e.CharSizeService=s;var c=function(){function t(t,e,n){this._document=t,this._parentElement=e,this._optionsService=n,this._result={width:0,height:0},this._measureElement=this._document.createElement("span"),this._measureElement.classList.add("xterm-char-measure-element"),this._measureElement.textContent="W",this._measureElement.setAttribute("aria-hidden","true"),this._parentElement.appendChild(this._measureElement)}return t.prototype.measure=function(){this._measureElement.style.fontFamily=this._optionsService.options.fontFamily,this._measureElement.style.fontSize=this._optionsService.options.fontSize+"px";var t=this._measureElement.getBoundingClientRect();return 0!==t.width&&0!==t.height&&(this._result.width=t.width,this._result.height=Math.ceil(t.height)),this._result},t}()},function(t,e,n){"use strict";var i=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},r=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.MouseService=void 0;var o=n(5),a=n(30),s=function(){function t(t,e){this._renderService=t,this._charSizeService=e}return t.prototype.getCoords=function(t,e,n,i,r){return a.getCoords(t,e,n,i,this._charSizeService.hasValidSize,this._renderService.dimensions.actualCellWidth,this._renderService.dimensions.actualCellHeight,r)},t.prototype.getRawByteCoords=function(t,e,n,i){var r=this.getCoords(t,e,n,i);return a.getRawByteCoords(r)},i([r(0,o.IRenderService),r(1,o.ICharSizeService)],t)}();e.MouseService=s},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.Linkifier2=void 0;var s=n(1),c=n(0),l=n(2),u=n(7),h=function(t){function e(e){var n=t.call(this)||this;return n._bufferService=e,n._linkProviders=[],n._linkCacheDisposables=[],n._isMouseOut=!0,n._activeLine=-1,n._onShowLinkUnderline=n.register(new c.EventEmitter),n._onHideLinkUnderline=n.register(new c.EventEmitter),n.register(l.getDisposeArrayDisposable(n._linkCacheDisposables)),n}return r(e,t),Object.defineProperty(e.prototype,"onShowLinkUnderline",{get:function(){return this._onShowLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onHideLinkUnderline",{get:function(){return this._onHideLinkUnderline.event},enumerable:!1,configurable:!0}),e.prototype.registerLinkProvider=function(t){var e=this;return this._linkProviders.push(t),{dispose:function(){var n=e._linkProviders.indexOf(t);-1!==n&&e._linkProviders.splice(n,1)}}},e.prototype.attachToDom=function(t,e,n){var i=this;this._element=t,this._mouseService=e,this._renderService=n,this.register(u.addDisposableDomListener(this._element,"mouseleave",(function(){i._isMouseOut=!0,i._clearCurrentLink()}))),this.register(u.addDisposableDomListener(this._element,"mousemove",this._onMouseMove.bind(this))),this.register(u.addDisposableDomListener(this._element,"click",this._onClick.bind(this)))},e.prototype._onMouseMove=function(t){if(this._lastMouseEvent=t,this._element&&this._mouseService){var e=this._positionFromMouseEvent(t,this._element,this._mouseService);if(e){this._isMouseOut=!1;for(var n=t.composedPath(),i=0;i<n.length;i++){var r=n[i];if(r.classList.contains("xterm"))break;if(r.classList.contains("xterm-hover"))return}this._lastBufferCell&&e.x===this._lastBufferCell.x&&e.y===this._lastBufferCell.y||(this._onHover(e),this._lastBufferCell=e)}}},e.prototype._onHover=function(t){if(this._activeLine!==t.y)return this._clearCurrentLink(),void this._askForLink(t,!1);this._currentLink&&this._linkAtPosition(this._currentLink.link,t)||(this._clearCurrentLink(),this._askForLink(t,!0))},e.prototype._askForLink=function(t,e){var n=this;this._activeProviderReplies&&e||(this._activeProviderReplies=new Map,this._activeLine=t.y);var i=!1;this._linkProviders.forEach((function(r,o){var a;e?(null===(a=n._activeProviderReplies)||void 0===a?void 0:a.get(o))&&(i=n._checkLinkProviderResult(o,t,i)):r.provideLinks(t.y,(function(e){var r,a;if(!n._isMouseOut){var s=null==e?void 0:e.map((function(t){return{link:t}}));null===(r=n._activeProviderReplies)||void 0===r||r.set(o,s),i=n._checkLinkProviderResult(o,t,i),(null===(a=n._activeProviderReplies)||void 0===a?void 0:a.size)===n._linkProviders.length&&n._removeIntersectingLinks(t.y,n._activeProviderReplies)}}))}))},e.prototype._removeIntersectingLinks=function(t,e){for(var n=new Set,i=0;i<e.size;i++){var r=e.get(i);if(r)for(var o=0;o<r.length;o++)for(var a=r[o],s=a.link.range.end.y>t?this._bufferService.cols:a.link.range.end.x,c=a.link.range.start.y<t?0:a.link.range.start.x;c<=s;c++){if(n.has(c)){r.splice(o--,1);break}n.add(c)}}},e.prototype._checkLinkProviderResult=function(t,e,n){var i,r=this;if(!this._activeProviderReplies)return n;for(var o=this._activeProviderReplies.get(t),a=!1,s=0;s<t;s++)this._activeProviderReplies.has(s)&&!this._activeProviderReplies.get(s)||(a=!0);if(!a&&o){var c=o.find((function(t){return r._linkAtPosition(t.link,e)}));c&&(n=!0,this._handleNewLink(c))}if(this._activeProviderReplies.size===this._linkProviders.length&&!n)for(s=0;s<this._activeProviderReplies.size;s++){var l=null===(i=this._activeProviderReplies.get(s))||void 0===i?void 0:i.find((function(t){return r._linkAtPosition(t.link,e)}));if(l){n=!0,this._handleNewLink(l);break}}return n},e.prototype._onClick=function(t){if(this._element&&this._mouseService&&this._currentLink){var e=this._positionFromMouseEvent(t,this._element,this._mouseService);e&&this._linkAtPosition(this._currentLink.link,e)&&this._currentLink.link.activate(t,this._currentLink.link.text)}},e.prototype._clearCurrentLink=function(t,e){this._element&&this._currentLink&&this._lastMouseEvent&&(!t||!e||this._currentLink.link.range.start.y>=t&&this._currentLink.link.range.end.y<=e)&&(this._linkLeave(this._element,this._currentLink.link,this._lastMouseEvent),this._currentLink=void 0,l.disposeArray(this._linkCacheDisposables))},e.prototype._handleNewLink=function(t){var e=this;if(this._element&&this._lastMouseEvent&&this._mouseService){var n=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);n&&this._linkAtPosition(t.link,n)&&(this._currentLink=t,this._currentLink.state={decorations:{underline:void 0===t.link.decorations||t.link.decorations.underline,pointerCursor:void 0===t.link.decorations||t.link.decorations.pointerCursor},isHovered:!0},this._linkHover(this._element,t.link,this._lastMouseEvent),t.link.decorations={},Object.defineProperties(t.link.decorations,{pointerCursor:{get:function(){var t,n;return null===(n=null===(t=e._currentLink)||void 0===t?void 0:t.state)||void 0===n?void 0:n.decorations.pointerCursor},set:function(t){var n,i;(null===(n=e._currentLink)||void 0===n?void 0:n.state)&&e._currentLink.state.decorations.pointerCursor!==t&&(e._currentLink.state.decorations.pointerCursor=t,e._currentLink.state.isHovered&&(null===(i=e._element)||void 0===i||i.classList.toggle("xterm-cursor-pointer",t)))}},underline:{get:function(){var t,n;return null===(n=null===(t=e._currentLink)||void 0===t?void 0:t.state)||void 0===n?void 0:n.decorations.underline},set:function(n){var i,r,o;(null===(i=e._currentLink)||void 0===i?void 0:i.state)&&(null===(o=null===(r=e._currentLink)||void 0===r?void 0:r.state)||void 0===o?void 0:o.decorations.underline)!==n&&(e._currentLink.state.decorations.underline=n,e._currentLink.state.isHovered&&e._fireUnderlineEvent(t.link,n))}}}),this._renderService&&this._linkCacheDisposables.push(this._renderService.onRenderedBufferChange((function(t){e._clearCurrentLink(0===t.start?0:t.start+1+e._bufferService.buffer.ydisp,t.end+1+e._bufferService.buffer.ydisp)}))))}},e.prototype._linkHover=function(t,e,n){var i;(null===(i=this._currentLink)||void 0===i?void 0:i.state)&&(this._currentLink.state.isHovered=!0,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(e,!0),this._currentLink.state.decorations.pointerCursor&&t.classList.add("xterm-cursor-pointer")),e.hover&&e.hover(n,e.text)},e.prototype._fireUnderlineEvent=function(t,e){var n=t.range,i=this._bufferService.buffer.ydisp,r=this._createLinkUnderlineEvent(n.start.x-1,n.start.y-i-1,n.end.x,n.end.y-i-1,void 0);(e?this._onShowLinkUnderline:this._onHideLinkUnderline).fire(r)},e.prototype._linkLeave=function(t,e,n){var i;(null===(i=this._currentLink)||void 0===i?void 0:i.state)&&(this._currentLink.state.isHovered=!1,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(e,!1),this._currentLink.state.decorations.pointerCursor&&t.classList.remove("xterm-cursor-pointer")),e.leave&&e.leave(n,e.text)},e.prototype._linkAtPosition=function(t,e){var n=t.range.start.y<e.y,i=t.range.end.y>e.y;return(t.range.start.y===t.range.end.y&&t.range.start.x<=e.x&&t.range.end.x>=e.x||n&&t.range.end.x>=e.x||i&&t.range.start.x<=e.x||n&&i)&&t.range.start.y<=e.y&&t.range.end.y>=e.y},e.prototype._positionFromMouseEvent=function(t,e,n){var i=n.getCoords(t,e,this._bufferService.cols,this._bufferService.rows);if(i)return{x:i[0],y:i[1]+this._bufferService.buffer.ydisp}},e.prototype._createLinkUnderlineEvent=function(t,e,n,i,r){return{x1:t,y1:e,x2:n,y2:i,cols:this._bufferService.cols,fg:r}},o([a(0,s.IBufferService)],e)}(l.Disposable);e.Linkifier2=h},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CoreBrowserService=void 0;var i=function(){function t(t){this._textarea=t}return Object.defineProperty(t.prototype,"isFocused",{get:function(){return document.activeElement===this._textarea&&document.hasFocus()},enumerable:!1,configurable:!0}),t}();e.CoreBrowserService=i},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.CoreTerminal=void 0;var o=n(2),a=n(1),s=n(66),c=n(67),l=n(68),u=n(74),h=n(75),d=n(0),f=n(76),p=n(77),m=n(78),g=n(80),v=n(81),b=n(19),y=n(82),_=function(t){function e(e){var n=t.call(this)||this;return n._onBinary=new d.EventEmitter,n._onData=new d.EventEmitter,n._onLineFeed=new d.EventEmitter,n._onResize=new d.EventEmitter,n._onScroll=new d.EventEmitter,n._instantiationService=new s.InstantiationService,n.optionsService=new u.OptionsService(e),n._instantiationService.setService(a.IOptionsService,n.optionsService),n._bufferService=n.register(n._instantiationService.createInstance(l.BufferService)),n._instantiationService.setService(a.IBufferService,n._bufferService),n._logService=n._instantiationService.createInstance(c.LogService),n._instantiationService.setService(a.ILogService,n._logService),n._coreService=n.register(n._instantiationService.createInstance(h.CoreService,(function(){return n.scrollToBottom()}))),n._instantiationService.setService(a.ICoreService,n._coreService),n._coreMouseService=n._instantiationService.createInstance(f.CoreMouseService),n._instantiationService.setService(a.ICoreMouseService,n._coreMouseService),n._dirtyRowService=n._instantiationService.createInstance(p.DirtyRowService),n._instantiationService.setService(a.IDirtyRowService,n._dirtyRowService),n.unicodeService=n._instantiationService.createInstance(m.UnicodeService),n._instantiationService.setService(a.IUnicodeService,n.unicodeService),n._charsetService=n._instantiationService.createInstance(g.CharsetService),n._instantiationService.setService(a.ICharsetService,n._charsetService),n._inputHandler=new b.InputHandler(n._bufferService,n._charsetService,n._coreService,n._dirtyRowService,n._logService,n.optionsService,n._coreMouseService,n.unicodeService),n.register(d.forwardEvent(n._inputHandler.onLineFeed,n._onLineFeed)),n.register(n._inputHandler),n.register(d.forwardEvent(n._bufferService.onResize,n._onResize)),n.register(d.forwardEvent(n._coreService.onData,n._onData)),n.register(d.forwardEvent(n._coreService.onBinary,n._onBinary)),n.register(n.optionsService.onOptionChange((function(t){return n._updateOptions(t)}))),n._writeBuffer=new y.WriteBuffer((function(t){return n._inputHandler.parse(t)})),n}return r(e,t),Object.defineProperty(e.prototype,"onBinary",{get:function(){return this._onBinary.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onData",{get:function(){return this._onData.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onLineFeed",{get:function(){return this._onLineFeed.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onResize",{get:function(){return this._onResize.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onScroll",{get:function(){return this._onScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"cols",{get:function(){return this._bufferService.cols},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rows",{get:function(){return this._bufferService.rows},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"buffers",{get:function(){return this._bufferService.buffers},enumerable:!1,configurable:!0}),e.prototype.dispose=function(){var e;this._isDisposed||(t.prototype.dispose.call(this),null===(e=this._windowsMode)||void 0===e||e.dispose(),this._windowsMode=void 0)},e.prototype.write=function(t,e){this._writeBuffer.write(t,e)},e.prototype.writeSync=function(t){this._writeBuffer.writeSync(t)},e.prototype.resize=function(t,e){isNaN(t)||isNaN(e)||(t=Math.max(t,l.MINIMUM_COLS),e=Math.max(e,l.MINIMUM_ROWS),this._bufferService.resize(t,e))},e.prototype.scroll=function(t,e){void 0===e&&(e=!1);var n,i=this._bufferService.buffer;(n=this._cachedBlankLine)&&n.length===this.cols&&n.getFg(0)===t.fg&&n.getBg(0)===t.bg||(n=i.getBlankLine(t,e),this._cachedBlankLine=n),n.isWrapped=e;var r=i.ybase+i.scrollTop,o=i.ybase+i.scrollBottom;if(0===i.scrollTop){var a=i.lines.isFull;o===i.lines.length-1?a?i.lines.recycle().copyFrom(n):i.lines.push(n.clone()):i.lines.splice(o+1,0,n.clone()),a?this._bufferService.isUserScrolling&&(i.ydisp=Math.max(i.ydisp-1,0)):(i.ybase++,this._bufferService.isUserScrolling||i.ydisp++)}else i.lines.shiftElements(r+1,o-r+1-1,-1),i.lines.set(o,n.clone());this._bufferService.isUserScrolling||(i.ydisp=i.ybase),this._dirtyRowService.markRangeDirty(i.scrollTop,i.scrollBottom),this._onScroll.fire(i.ydisp)},e.prototype.scrollLines=function(t,e){var n=this._bufferService.buffer;if(t<0){if(0===n.ydisp)return;this._bufferService.isUserScrolling=!0}else t+n.ydisp>=n.ybase&&(this._bufferService.isUserScrolling=!1);var i=n.ydisp;n.ydisp=Math.max(Math.min(n.ydisp+t,n.ybase),0),i!==n.ydisp&&(e||this._onScroll.fire(n.ydisp))},e.prototype.scrollPages=function(t){this.scrollLines(t*(this.rows-1))},e.prototype.scrollToTop=function(){this.scrollLines(-this._bufferService.buffer.ydisp)},e.prototype.scrollToBottom=function(){this.scrollLines(this._bufferService.buffer.ybase-this._bufferService.buffer.ydisp)},e.prototype.scrollToLine=function(t){var e=t-this._bufferService.buffer.ydisp;0!==e&&this.scrollLines(e)},e.prototype.addEscHandler=function(t,e){return this._inputHandler.addEscHandler(t,e)},e.prototype.addDcsHandler=function(t,e){return this._inputHandler.addDcsHandler(t,e)},e.prototype.addCsiHandler=function(t,e){return this._inputHandler.addCsiHandler(t,e)},e.prototype.addOscHandler=function(t,e){return this._inputHandler.addOscHandler(t,e)},e.prototype._setup=function(){this.optionsService.options.windowsMode&&this._enableWindowsMode()},e.prototype.reset=function(){this._inputHandler.reset(),this._bufferService.reset(),this._charsetService.reset(),this._coreService.reset(),this._coreMouseService.reset()},e.prototype._updateOptions=function(t){var e;switch(t){case"scrollback":this.buffers.resize(this.cols,this.rows);break;case"windowsMode":this.optionsService.options.windowsMode?this._enableWindowsMode():(null===(e=this._windowsMode)||void 0===e||e.dispose(),this._windowsMode=void 0)}},e.prototype._enableWindowsMode=function(){var t=this;if(!this._windowsMode){var e=[];e.push(this.onLineFeed(v.updateWindowsModeWrappedState.bind(null,this._bufferService))),e.push(this.addCsiHandler({final:"H"},(function(){return v.updateWindowsModeWrappedState(t._bufferService),!1}))),this._windowsMode={dispose:function(){for(var t=0,n=e;t<n.length;t++)n[t].dispose()}}}},e}(o.Disposable);e.CoreTerminal=_},function(t,e,n){"use strict";var i=this&&this.__spreadArrays||function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,r++)i[r]=o[a];return i};Object.defineProperty(e,"__esModule",{value:!0}),e.InstantiationService=e.ServiceCollection=void 0;var r=n(1),o=n(14),a=function(){function t(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._entries=new Map;for(var n=0,i=t;n<i.length;n++){var r=i[n],o=r[0],a=r[1];this.set(o,a)}}return t.prototype.set=function(t,e){var n=this._entries.get(t);return this._entries.set(t,e),n},t.prototype.forEach=function(t){this._entries.forEach((function(e,n){return t(n,e)}))},t.prototype.has=function(t){return this._entries.has(t)},t.prototype.get=function(t){return this._entries.get(t)},t}();e.ServiceCollection=a;var s=function(){function t(){this._services=new a,this._services.set(r.IInstantiationService,this)}return t.prototype.setService=function(t,e){this._services.set(t,e)},t.prototype.getService=function(t){return this._services.get(t)},t.prototype.createInstance=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];for(var r=o.getServiceDependencies(t).sort((function(t,e){return t.index-e.index})),a=[],s=0,c=r;s<c.length;s++){var l=c[s],u=this._services.get(l.id);if(!u)throw new Error("[createInstance] "+t.name+" depends on UNKNOWN service "+l.id+".");a.push(u)}var h=r.length>0?r[0].index:e.length;if(e.length!==h)throw new Error("[createInstance] First service dependency of "+t.name+" at position "+(h+1)+" conflicts with "+e.length+" static arguments");return new(t.bind.apply(t,i([void 0],i(e,a))))},t}();e.InstantiationService=s},function(t,e,n){"use strict";var i=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},r=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}},o=this&&this.__spreadArrays||function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,r++)i[r]=o[a];return i};Object.defineProperty(e,"__esModule",{value:!0}),e.LogService=e.LogLevel=void 0;var a,s=n(1);!function(t){t[t.DEBUG=0]="DEBUG",t[t.INFO=1]="INFO",t[t.WARN=2]="WARN",t[t.ERROR=3]="ERROR",t[t.OFF=4]="OFF"}(a=e.LogLevel||(e.LogLevel={}));var c={debug:a.DEBUG,info:a.INFO,warn:a.WARN,error:a.ERROR,off:a.OFF},l=function(){function t(t){var e=this;this._optionsService=t,this._updateLogLevel(),this._optionsService.onOptionChange((function(t){"logLevel"===t&&e._updateLogLevel()}))}return t.prototype._updateLogLevel=function(){this._logLevel=c[this._optionsService.options.logLevel]},t.prototype._evalLazyOptionalParams=function(t){for(var e=0;e<t.length;e++)"function"==typeof t[e]&&(t[e]=t[e]())},t.prototype._log=function(t,e,n){this._evalLazyOptionalParams(n),t.call.apply(t,o([console,"xterm.js: "+e],n))},t.prototype.debug=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];this._logLevel<=a.DEBUG&&this._log(console.log,t,e)},t.prototype.info=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];this._logLevel<=a.INFO&&this._log(console.info,t,e)},t.prototype.warn=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];this._logLevel<=a.WARN&&this._log(console.warn,t,e)},t.prototype.error=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];this._logLevel<=a.ERROR&&this._log(console.error,t,e)},i([r(0,s.IOptionsService)],t)}();e.LogService=l},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.BufferService=e.MINIMUM_ROWS=e.MINIMUM_COLS=void 0;var s=n(1),c=n(69),l=n(0),u=n(2);e.MINIMUM_COLS=2,e.MINIMUM_ROWS=1;var h=function(t){function n(n){var i=t.call(this)||this;return i._optionsService=n,i.isUserScrolling=!1,i._onResize=new l.EventEmitter,i.cols=Math.max(n.options.cols,e.MINIMUM_COLS),i.rows=Math.max(n.options.rows,e.MINIMUM_ROWS),i.buffers=new c.BufferSet(n,i),i}return r(n,t),Object.defineProperty(n.prototype,"onResize",{get:function(){return this._onResize.event},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"buffer",{get:function(){return this.buffers.active},enumerable:!1,configurable:!0}),n.prototype.dispose=function(){t.prototype.dispose.call(this),this.buffers.dispose()},n.prototype.resize=function(t,e){this.cols=t,this.rows=e,this.buffers.resize(t,e),this.buffers.setupTabStops(this.cols),this._onResize.fire({cols:t,rows:e})},n.prototype.reset=function(){this.buffers.dispose(),this.buffers=new c.BufferSet(this._optionsService,this),this.isUserScrolling=!1},o([a(0,s.IOptionsService)],n)}(u.Disposable);e.BufferService=h},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.BufferSet=void 0;var o=n(70),a=n(0),s=function(t){function e(e,n){var i=t.call(this)||this;return i._onBufferActivate=i.register(new a.EventEmitter),i._normal=new o.Buffer(!0,e,n),i._normal.fillViewportRows(),i._alt=new o.Buffer(!1,e,n),i._activeBuffer=i._normal,i.setupTabStops(),i}return r(e,t),Object.defineProperty(e.prototype,"onBufferActivate",{get:function(){return this._onBufferActivate.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"alt",{get:function(){return this._alt},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"active",{get:function(){return this._activeBuffer},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"normal",{get:function(){return this._normal},enumerable:!1,configurable:!0}),e.prototype.activateNormalBuffer=function(){this._activeBuffer!==this._normal&&(this._normal.x=this._alt.x,this._normal.y=this._alt.y,this._alt.clear(),this._activeBuffer=this._normal,this._onBufferActivate.fire({activeBuffer:this._normal,inactiveBuffer:this._alt}))},e.prototype.activateAltBuffer=function(t){this._activeBuffer!==this._alt&&(this._alt.fillViewportRows(t),this._alt.x=this._normal.x,this._alt.y=this._normal.y,this._activeBuffer=this._alt,this._onBufferActivate.fire({activeBuffer:this._alt,inactiveBuffer:this._normal}))},e.prototype.resize=function(t,e){this._normal.resize(t,e),this._alt.resize(t,e)},e.prototype.setupTabStops=function(t){this._normal.setupTabStops(t),this._alt.setupTabStops(t)},e}(n(2).Disposable);e.BufferSet=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BufferStringIterator=e.Buffer=e.MAX_BUFFER_SIZE=void 0;var i=n(71),r=n(16),o=n(4),a=n(3),s=n(72),c=n(73),l=n(20),u=n(6);e.MAX_BUFFER_SIZE=4294967295;var h=function(){function t(t,e,n){this._hasScrollback=t,this._optionsService=e,this._bufferService=n,this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.savedY=0,this.savedX=0,this.savedCurAttrData=r.DEFAULT_ATTR_DATA.clone(),this.savedCharset=l.DEFAULT_CHARSET,this.markers=[],this._nullCell=o.CellData.fromCharData([0,a.NULL_CELL_CHAR,a.NULL_CELL_WIDTH,a.NULL_CELL_CODE]),this._whitespaceCell=o.CellData.fromCharData([0,a.WHITESPACE_CELL_CHAR,a.WHITESPACE_CELL_WIDTH,a.WHITESPACE_CELL_CODE]),this._cols=this._bufferService.cols,this._rows=this._bufferService.rows,this.lines=new i.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()}return t.prototype.getNullCell=function(t){return t?(this._nullCell.fg=t.fg,this._nullCell.bg=t.bg,this._nullCell.extended=t.extended):(this._nullCell.fg=0,this._nullCell.bg=0,this._nullCell.extended=new u.ExtendedAttrs),this._nullCell},t.prototype.getWhitespaceCell=function(t){return t?(this._whitespaceCell.fg=t.fg,this._whitespaceCell.bg=t.bg,this._whitespaceCell.extended=t.extended):(this._whitespaceCell.fg=0,this._whitespaceCell.bg=0,this._whitespaceCell.extended=new u.ExtendedAttrs),this._whitespaceCell},t.prototype.getBlankLine=function(t,e){return new r.BufferLine(this._bufferService.cols,this.getNullCell(t),e)},Object.defineProperty(t.prototype,"hasScrollback",{get:function(){return this._hasScrollback&&this.lines.maxLength>this._rows},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isCursorInViewport",{get:function(){var t=this.ybase+this.y-this.ydisp;return t>=0&&t<this._rows},enumerable:!1,configurable:!0}),t.prototype._getCorrectBufferLength=function(t){if(!this._hasScrollback)return t;var n=t+this._optionsService.options.scrollback;return n>e.MAX_BUFFER_SIZE?e.MAX_BUFFER_SIZE:n},t.prototype.fillViewportRows=function(t){if(0===this.lines.length){void 0===t&&(t=r.DEFAULT_ATTR_DATA);for(var e=this._rows;e--;)this.lines.push(this.getBlankLine(t))}},t.prototype.clear=function(){this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.lines=new i.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()},t.prototype.resize=function(t,e){var n=this.getNullCell(r.DEFAULT_ATTR_DATA),i=this._getCorrectBufferLength(e);if(i>this.lines.maxLength&&(this.lines.maxLength=i),this.lines.length>0){if(this._cols<t)for(var o=0;o<this.lines.length;o++)this.lines.get(o).resize(t,n);var a=0;if(this._rows<e)for(var s=this._rows;s<e;s++)this.lines.length<e+this.ybase&&(this._optionsService.options.windowsMode?this.lines.push(new r.BufferLine(t,n)):this.ybase>0&&this.lines.length<=this.ybase+this.y+a+1?(this.ybase--,a++,this.ydisp>0&&this.ydisp--):this.lines.push(new r.BufferLine(t,n)));else for(s=this._rows;s>e;s--)this.lines.length>e+this.ybase&&(this.lines.length>this.ybase+this.y+1?this.lines.pop():(this.ybase++,this.ydisp++));if(i<this.lines.maxLength){var c=this.lines.length-i;c>0&&(this.lines.trimStart(c),this.ybase=Math.max(this.ybase-c,0),this.ydisp=Math.max(this.ydisp-c,0),this.savedY=Math.max(this.savedY-c,0)),this.lines.maxLength=i}this.x=Math.min(this.x,t-1),this.y=Math.min(this.y,e-1),a&&(this.y+=a),this.savedX=Math.min(this.savedX,t-1),this.scrollTop=0}if(this.scrollBottom=e-1,this._isReflowEnabled&&(this._reflow(t,e),this._cols>t))for(o=0;o<this.lines.length;o++)this.lines.get(o).resize(t,n);this._cols=t,this._rows=e},Object.defineProperty(t.prototype,"_isReflowEnabled",{get:function(){return this._hasScrollback&&!this._optionsService.options.windowsMode},enumerable:!1,configurable:!0}),t.prototype._reflow=function(t,e){this._cols!==t&&(t>this._cols?this._reflowLarger(t,e):this._reflowSmaller(t,e))},t.prototype._reflowLarger=function(t,e){var n=s.reflowLargerGetLinesToRemove(this.lines,this._cols,t,this.ybase+this.y,this.getNullCell(r.DEFAULT_ATTR_DATA));if(n.length>0){var i=s.reflowLargerCreateNewLayout(this.lines,n);s.reflowLargerApplyNewLayout(this.lines,i.layout),this._reflowLargerAdjustViewport(t,e,i.countRemoved)}},t.prototype._reflowLargerAdjustViewport=function(t,e,n){for(var i=this.getNullCell(r.DEFAULT_ATTR_DATA),o=n;o-- >0;)0===this.ybase?(this.y>0&&this.y--,this.lines.length<e&&this.lines.push(new r.BufferLine(t,i))):(this.ydisp===this.ybase&&this.ydisp--,this.ybase--);this.savedY=Math.max(this.savedY-n,0)},t.prototype._reflowSmaller=function(t,e){for(var n=this.getNullCell(r.DEFAULT_ATTR_DATA),i=[],o=0,a=this.lines.length-1;a>=0;a--){var c=this.lines.get(a);if(!(!c||!c.isWrapped&&c.getTrimmedLength()<=t)){for(var l=[c];c.isWrapped&&a>0;)c=this.lines.get(--a),l.unshift(c);var u=this.ybase+this.y;if(!(u>=a&&u<a+l.length)){var h,d=l[l.length-1].getTrimmedLength(),f=s.reflowSmallerGetNewLineLengths(l,this._cols,t),p=f.length-l.length;h=0===this.ybase&&this.y!==this.lines.length-1?Math.max(0,this.y-this.lines.maxLength+p):Math.max(0,this.lines.length-this.lines.maxLength+p);for(var m=[],g=0;g<p;g++){var v=this.getBlankLine(r.DEFAULT_ATTR_DATA,!0);m.push(v)}m.length>0&&(i.push({start:a+l.length+o,newLines:m}),o+=m.length),l.push.apply(l,m);var b=f.length-1,y=f[b];0===y&&(y=f[--b]);for(var _=l.length-p-1,w=d;_>=0;){var k=Math.min(w,y);if(l[b].copyCellsFrom(l[_],w-k,y-k,k,!0),0==(y-=k)&&(y=f[--b]),0==(w-=k)){_--;var C=Math.max(_,0);w=s.getWrappedLineTrimmedLength(l,C,this._cols)}}for(g=0;g<l.length;g++)f[g]<t&&l[g].setCell(f[g],n);for(var S=p-h;S-- >0;)0===this.ybase?this.y<e-1?(this.y++,this.lines.pop()):(this.ybase++,this.ydisp++):this.ybase<Math.min(this.lines.maxLength,this.lines.length+o)-e&&(this.ybase===this.ydisp&&this.ydisp++,this.ybase++);this.savedY=Math.min(this.savedY+p,this.ybase+e-1)}}}if(i.length>0){var x=[],O=[];for(g=0;g<this.lines.length;g++)O.push(this.lines.get(g));var M=this.lines.length,T=M-1,E=0,P=i[E];this.lines.length=Math.min(this.lines.maxLength,this.lines.length+o);var A=0;for(g=Math.min(this.lines.maxLength-1,M+o-1);g>=0;g--)if(P&&P.start>T+A){for(var j=P.newLines.length-1;j>=0;j--)this.lines.set(g--,P.newLines[j]);g++,x.push({index:T+1,amount:P.newLines.length}),A+=P.newLines.length,P=i[++E]}else this.lines.set(g,O[T--]);var I=0;for(g=x.length-1;g>=0;g--)x[g].index+=I,this.lines.onInsertEmitter.fire(x[g]),I+=x[g].amount;var D=Math.max(0,M+o-this.lines.maxLength);D>0&&this.lines.onTrimEmitter.fire(D)}},t.prototype.stringIndexToBufferIndex=function(t,e,n){for(void 0===n&&(n=!1);e;){var i=this.lines.get(t);if(!i)return[-1,-1];for(var r=n?i.getTrimmedLength():i.length,o=0;o<r;++o)if(i.get(o)[a.CHAR_DATA_WIDTH_INDEX]&&(e-=i.get(o)[a.CHAR_DATA_CHAR_INDEX].length||1),e<0)return[t,o];t++}return[t,0]},t.prototype.translateBufferLineToString=function(t,e,n,i){void 0===n&&(n=0);var r=this.lines.get(t);return r?r.translateToString(e,n,i):""},t.prototype.getWrappedRangeForLine=function(t){for(var e=t,n=t;e>0&&this.lines.get(e).isWrapped;)e--;for(;n+1<this.lines.length&&this.lines.get(n+1).isWrapped;)n++;return{first:e,last:n}},t.prototype.setupTabStops=function(t){for(null!=t?this.tabs[t]||(t=this.prevStop(t)):(this.tabs={},t=0);t<this._cols;t+=this._optionsService.options.tabStopWidth)this.tabs[t]=!0},t.prototype.prevStop=function(t){for(null==t&&(t=this.x);!this.tabs[--t]&&t>0;);return t>=this._cols?this._cols-1:t<0?0:t},t.prototype.nextStop=function(t){for(null==t&&(t=this.x);!this.tabs[++t]&&t<this._cols;);return t>=this._cols?this._cols-1:t<0?0:t},t.prototype.addMarker=function(t){var e=this,n=new c.Marker(t);return this.markers.push(n),n.register(this.lines.onTrim((function(t){n.line-=t,n.line<0&&n.dispose()}))),n.register(this.lines.onInsert((function(t){n.line>=t.index&&(n.line+=t.amount)}))),n.register(this.lines.onDelete((function(t){n.line>=t.index&&n.line<t.index+t.amount&&n.dispose(),n.line>t.index&&(n.line-=t.amount)}))),n.register(n.onDispose((function(){return e._removeMarker(n)}))),n},t.prototype._removeMarker=function(t){this.markers.splice(this.markers.indexOf(t),1)},t.prototype.iterator=function(t,e,n,i,r){return new d(this,t,e,n,i,r)},t}();e.Buffer=h;var d=function(){function t(t,e,n,i,r,o){void 0===n&&(n=0),void 0===i&&(i=t.lines.length),void 0===r&&(r=0),void 0===o&&(o=0),this._buffer=t,this._trimRight=e,this._startIndex=n,this._endIndex=i,this._startOverscan=r,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 t.prototype.hasNext=function(){return this._current<this._endIndex},t.prototype.next=function(){var t=this._buffer.getWrappedRangeForLine(this._current);t.first<this._startIndex-this._startOverscan&&(t.first=this._startIndex-this._startOverscan),t.last>this._endIndex+this._endOverscan&&(t.last=this._endIndex+this._endOverscan),t.first=Math.max(t.first,0),t.last=Math.min(t.last,this._buffer.lines.length);for(var e="",n=t.first;n<=t.last;++n)e+=this._buffer.translateBufferLineToString(n,this._trimRight);return this._current=t.last+1,{range:t,content:e}},t}();e.BufferStringIterator=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CircularList=void 0;var i=n(0),r=function(){function t(t){this._maxLength=t,this.onDeleteEmitter=new i.EventEmitter,this.onInsertEmitter=new i.EventEmitter,this.onTrimEmitter=new i.EventEmitter,this._array=new Array(this._maxLength),this._startIndex=0,this._length=0}return Object.defineProperty(t.prototype,"onDelete",{get:function(){return this.onDeleteEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onInsert",{get:function(){return this.onInsertEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onTrim",{get:function(){return this.onTrimEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"maxLength",{get:function(){return this._maxLength},set:function(t){if(this._maxLength!==t){for(var e=new Array(t),n=0;n<Math.min(t,this.length);n++)e[n]=this._array[this._getCyclicIndex(n)];this._array=e,this._maxLength=t,this._startIndex=0}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"length",{get:function(){return this._length},set:function(t){if(t>this._length)for(var e=this._length;e<t;e++)this._array[e]=void 0;this._length=t},enumerable:!1,configurable:!0}),t.prototype.get=function(t){return this._array[this._getCyclicIndex(t)]},t.prototype.set=function(t,e){this._array[this._getCyclicIndex(t)]=e},t.prototype.push=function(t){this._array[this._getCyclicIndex(this._length)]=t,this._length===this._maxLength?(this._startIndex=++this._startIndex%this._maxLength,this.onTrimEmitter.fire(1)):this._length++},t.prototype.recycle=function(){if(this._length!==this._maxLength)throw new Error("Can only recycle when the buffer is full");return this._startIndex=++this._startIndex%this._maxLength,this.onTrimEmitter.fire(1),this._array[this._getCyclicIndex(this._length-1)]},Object.defineProperty(t.prototype,"isFull",{get:function(){return this._length===this._maxLength},enumerable:!1,configurable:!0}),t.prototype.pop=function(){return this._array[this._getCyclicIndex(this._length---1)]},t.prototype.splice=function(t,e){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];if(e){for(var r=t;r<this._length-e;r++)this._array[this._getCyclicIndex(r)]=this._array[this._getCyclicIndex(r+e)];this._length-=e}for(r=this._length-1;r>=t;r--)this._array[this._getCyclicIndex(r+n.length)]=this._array[this._getCyclicIndex(r)];for(r=0;r<n.length;r++)this._array[this._getCyclicIndex(t+r)]=n[r];if(this._length+n.length>this._maxLength){var o=this._length+n.length-this._maxLength;this._startIndex+=o,this._length=this._maxLength,this.onTrimEmitter.fire(o)}else this._length+=n.length},t.prototype.trimStart=function(t){t>this._length&&(t=this._length),this._startIndex+=t,this._length-=t,this.onTrimEmitter.fire(t)},t.prototype.shiftElements=function(t,e,n){if(!(e<=0)){if(t<0||t>=this._length)throw new Error("start argument out of range");if(t+n<0)throw new Error("Cannot shift elements in list beyond index 0");if(n>0){for(var i=e-1;i>=0;i--)this.set(t+i+n,this.get(t+i));var r=t+e+n-this._length;if(r>0)for(this._length+=r;this._length>this._maxLength;)this._length--,this._startIndex++,this.onTrimEmitter.fire(1)}else for(i=0;i<e;i++)this.set(t+i+n,this.get(t+i))}},t.prototype._getCyclicIndex=function(t){return(this._startIndex+t)%this._maxLength},t}();e.CircularList=r},function(t,e,n){"use strict";function i(t,e,n){if(e===t.length-1)return t[e].getTrimmedLength();var i=!t[e].hasContent(n-1)&&1===t[e].getWidth(n-1),r=2===t[e+1].getWidth(0);return i&&r?n-1:n}Object.defineProperty(e,"__esModule",{value:!0}),e.getWrappedLineTrimmedLength=e.reflowSmallerGetNewLineLengths=e.reflowLargerApplyNewLayout=e.reflowLargerCreateNewLayout=e.reflowLargerGetLinesToRemove=void 0,e.reflowLargerGetLinesToRemove=function(t,e,n,r,o){for(var a=[],s=0;s<t.length-1;s++){var c=s,l=t.get(++c);if(l.isWrapped){for(var u=[t.get(s)];c<t.length&&l.isWrapped;)u.push(l),l=t.get(++c);if(r>=s&&r<c)s+=u.length-1;else{for(var h=0,d=i(u,h,e),f=1,p=0;f<u.length;){var m=i(u,f,e),g=Math.min(m-p,n-d);u[h].copyCellsFrom(u[f],p,d,g,!1),(d+=g)===n&&(h++,d=0),(p+=g)===m&&(f++,p=0),0===d&&0!==h&&2===u[h-1].getWidth(n-1)&&(u[h].copyCellsFrom(u[h-1],n-1,d++,1,!1),u[h-1].setCell(n-1,o))}u[h].replaceCells(d,n,o);for(var v=0,b=u.length-1;b>0&&(b>h||0===u[b].getTrimmedLength());b--)v++;v>0&&(a.push(s+u.length-v),a.push(v)),s+=u.length-1}}}return a},e.reflowLargerCreateNewLayout=function(t,e){for(var n=[],i=0,r=e[i],o=0,a=0;a<t.length;a++)if(r===a){var s=e[++i];t.onDeleteEmitter.fire({index:a-o,amount:s}),a+=s-1,o+=s,r=e[++i]}else n.push(a);return{layout:n,countRemoved:o}},e.reflowLargerApplyNewLayout=function(t,e){for(var n=[],i=0;i<e.length;i++)n.push(t.get(e[i]));for(i=0;i<n.length;i++)t.set(i,n[i]);t.length=e.length},e.reflowSmallerGetNewLineLengths=function(t,e,n){for(var r=[],o=t.map((function(n,r){return i(t,r,e)})).reduce((function(t,e){return t+e})),a=0,s=0,c=0;c<o;){if(o-c<n){r.push(o-c);break}a+=n;var l=i(t,s,e);a>l&&(a-=l,s++);var u=2===t[s].getWidth(a-1);u&&a--;var h=u?n-1:n;r.push(h),c+=h}return r},e.getWrappedLineTrimmedLength=i},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.Marker=void 0;var o=n(0),a=function(t){function e(n){var i=t.call(this)||this;return i.line=n,i._id=e._nextId++,i.isDisposed=!1,i._onDispose=new o.EventEmitter,i}return r(e,t),Object.defineProperty(e.prototype,"id",{get:function(){return this._id},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onDispose",{get:function(){return this._onDispose.event},enumerable:!1,configurable:!0}),e.prototype.dispose=function(){this.isDisposed||(this.isDisposed=!0,this.line=-1,this._onDispose.fire())},e._nextId=1,e}(n(2).Disposable);e.Marker=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.OptionsService=e.DEFAULT_OPTIONS=e.DEFAULT_BELL_SOUND=void 0;var i=n(0),r=n(11),o=n(33);e.DEFAULT_BELL_SOUND="data:audio/mp3;base64,SUQzBAAAAAAAI1RTU0UAAAAPAAADTGF2ZjU4LjMyLjEwNAAAAAAAAAAAAAAA//tQxAADB8AhSmxhIIEVCSiJrDCQBTcu3UrAIwUdkRgQbFAZC1CQEwTJ9mjRvBA4UOLD8nKVOWfh+UlK3z/177OXrfOdKl7pyn3Xf//WreyTRUoAWgBgkOAGbZHBgG1OF6zM82DWbZaUmMBptgQhGjsyYqc9ae9XFz280948NMBWInljyzsNRFLPWdnZGWrddDsjK1unuSrVN9jJsK8KuQtQCtMBjCEtImISdNKJOopIpBFpNSMbIHCSRpRR5iakjTiyzLhchUUBwCgyKiweBv/7UsQbg8isVNoMPMjAAAA0gAAABEVFGmgqK////9bP/6XCykxBTUUzLjEwMKqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq",e.DEFAULT_OPTIONS=Object.freeze({cols:80,rows:24,cursorBlink:!1,cursorStyle:"block",cursorWidth:1,bellSound:e.DEFAULT_BELL_SOUND,bellStyle:"none",drawBoldTextInBrightColors:!0,fastScrollModifier:"alt",fastScrollSensitivity:5,fontFamily:"courier-new, courier, monospace",fontSize:15,fontWeight:"normal",fontWeightBold:"bold",lineHeight:1,linkTooltipHoverDuration:500,letterSpacing:0,logLevel:"info",scrollback:1e3,scrollSensitivity:1,screenReaderMode:!1,macOptionIsMeta:!1,macOptionClickForcesSelection:!1,minimumContrastRatio:1,disableStdin:!1,allowProposedApi:!0,allowTransparency:!1,tabStopWidth:8,theme:{},rightClickSelectsWord:r.isMac,rendererType:"canvas",windowOptions:{},windowsMode:!1,wordSeparator:" ()[]{}',\"`",convertEol:!1,termName:"xterm",cancelEvents:!1});var a=["cols","rows"],s=function(){function t(t){this._onOptionChange=new i.EventEmitter,this.options=o.clone(e.DEFAULT_OPTIONS);for(var n=0,r=Object.keys(t);n<r.length;n++){var a=r[n];a in this.options&&(this.options[a]=t[a])}}return Object.defineProperty(t.prototype,"onOptionChange",{get:function(){return this._onOptionChange.event},enumerable:!1,configurable:!0}),t.prototype.setOption=function(t,n){if(!(t in e.DEFAULT_OPTIONS))throw new Error('No option with key "'+t+'"');if(-1!==a.indexOf(t))throw new Error('Option "'+t+'" can only be set in the constructor');this.options[t]!==n&&(n=this._sanitizeAndValidateOption(t,n),this.options[t]!==n&&(this.options[t]=n,this._onOptionChange.fire(t)))},t.prototype._sanitizeAndValidateOption=function(t,n){switch(t){case"bellStyle":case"cursorStyle":case"fontWeight":case"fontWeightBold":case"rendererType":case"wordSeparator":n||(n=e.DEFAULT_OPTIONS[t]);break;case"cursorWidth":n=Math.floor(n);case"lineHeight":case"tabStopWidth":if(n<1)throw new Error(t+" cannot be less than 1, value: "+n);break;case"minimumContrastRatio":n=Math.max(1,Math.min(21,Math.round(10*n)/10));break;case"scrollback":if((n=Math.min(n,4294967295))<0)throw new Error(t+" cannot be less than 0, value: "+n);break;case"fastScrollSensitivity":case"scrollSensitivity":if(n<=0)throw new Error(t+" cannot be less than or equal to 0, value: "+n)}return n},t.prototype.getOption=function(t){if(!(t in e.DEFAULT_OPTIONS))throw new Error('No option with key "'+t+'"');return this.options[t]},t}();e.OptionsService=s},function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},a=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.CoreService=void 0;var s=n(1),c=n(0),l=n(33),u=n(2),h=Object.freeze({insertMode:!1}),d=Object.freeze({applicationCursorKeys:!1,applicationKeypad:!1,bracketedPasteMode:!1,origin:!1,reverseWraparound:!1,sendFocus:!1,wraparound:!0}),f=function(t){function e(e,n,i,r){var o=t.call(this)||this;return o._bufferService=n,o._logService=i,o._optionsService=r,o.isCursorInitialized=!1,o.isCursorHidden=!1,o._onData=o.register(new c.EventEmitter),o._onUserInput=o.register(new c.EventEmitter),o._onBinary=o.register(new c.EventEmitter),o._scrollToBottom=e,o.register({dispose:function(){return o._scrollToBottom=void 0}}),o.modes=l.clone(h),o.decPrivateModes=l.clone(d),o}return r(e,t),Object.defineProperty(e.prototype,"onData",{get:function(){return this._onData.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onUserInput",{get:function(){return this._onUserInput.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onBinary",{get:function(){return this._onBinary.event},enumerable:!1,configurable:!0}),e.prototype.reset=function(){this.modes=l.clone(h),this.decPrivateModes=l.clone(d)},e.prototype.triggerDataEvent=function(t,e){if(void 0===e&&(e=!1),!this._optionsService.options.disableStdin){var n=this._bufferService.buffer;n.ybase!==n.ydisp&&this._scrollToBottom(),e&&this._onUserInput.fire(),this._logService.debug('sending data "'+t+'"',(function(){return t.split("").map((function(t){return t.charCodeAt(0)}))})),this._onData.fire(t)}},e.prototype.triggerBinaryEvent=function(t){this._optionsService.options.disableStdin||(this._logService.debug('sending binary "'+t+'"',(function(){return t.split("").map((function(t){return t.charCodeAt(0)}))})),this._onBinary.fire(t))},o([a(1,s.IBufferService),a(2,s.ILogService),a(3,s.IOptionsService)],e)}(u.Disposable);e.CoreService=f},function(t,e,n){"use strict";var i=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},r=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.CoreMouseService=void 0;var o=n(1),a=n(0),s={NONE:{events:0,restrict:function(){return!1}},X10:{events:1,restrict:function(t){return 4!==t.button&&1===t.action&&(t.ctrl=!1,t.alt=!1,t.shift=!1,!0)}},VT200:{events:19,restrict:function(t){return 32!==t.action}},DRAG:{events:23,restrict:function(t){return 32!==t.action||3!==t.button}},ANY:{events:31,restrict:function(t){return!0}}};function c(t,e){var n=(t.ctrl?16:0)|(t.shift?4:0)|(t.alt?8:0);return 4===t.button?(n|=64,n|=t.action):(n|=3&t.button,4&t.button&&(n|=64),8&t.button&&(n|=128),32===t.action?n|=32:0!==t.action||e||(n|=3)),n}var l=String.fromCharCode,u={DEFAULT:function(t){var e=[c(t,!1)+32,t.col+32,t.row+32];return e[0]>255||e[1]>255||e[2]>255?"":"\x1b[M"+l(e[0])+l(e[1])+l(e[2])},SGR:function(t){var e=0===t.action&&4!==t.button?"m":"M";return"\x1b[<"+c(t,!0)+";"+t.col+";"+t.row+e}},h=function(){function t(t,e){this._bufferService=t,this._coreService=e,this._protocols={},this._encodings={},this._activeProtocol="",this._activeEncoding="",this._onProtocolChange=new a.EventEmitter,this._lastEvent=null;for(var n=0,i=Object.keys(s);n<i.length;n++){var r=i[n];this.addProtocol(r,s[r])}for(var o=0,c=Object.keys(u);o<c.length;o++){var l=c[o];this.addEncoding(l,u[l])}this.reset()}return t.prototype.addProtocol=function(t,e){this._protocols[t]=e},t.prototype.addEncoding=function(t,e){this._encodings[t]=e},Object.defineProperty(t.prototype,"activeProtocol",{get:function(){return this._activeProtocol},set:function(t){if(!this._protocols[t])throw new Error('unknown protocol "'+t+'"');this._activeProtocol=t,this._onProtocolChange.fire(this._protocols[t].events)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"areMouseEventsActive",{get:function(){return 0!==this._protocols[this._activeProtocol].events},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"activeEncoding",{get:function(){return this._activeEncoding},set:function(t){if(!this._encodings[t])throw new Error('unknown encoding "'+t+'"');this._activeEncoding=t},enumerable:!1,configurable:!0}),t.prototype.reset=function(){this.activeProtocol="NONE",this.activeEncoding="DEFAULT",this._lastEvent=null},Object.defineProperty(t.prototype,"onProtocolChange",{get:function(){return this._onProtocolChange.event},enumerable:!1,configurable:!0}),t.prototype.triggerMouseEvent=function(t){if(t.col<0||t.col>=this._bufferService.cols||t.row<0||t.row>=this._bufferService.rows)return!1;if(4===t.button&&32===t.action)return!1;if(3===t.button&&32!==t.action)return!1;if(4!==t.button&&(2===t.action||3===t.action))return!1;if(t.col++,t.row++,32===t.action&&this._lastEvent&&this._compareEvents(this._lastEvent,t))return!1;if(!this._protocols[this._activeProtocol].restrict(t))return!1;var e=this._encodings[this._activeEncoding](t);return e&&("DEFAULT"===this._activeEncoding?this._coreService.triggerBinaryEvent(e):this._coreService.triggerDataEvent(e,!0)),this._lastEvent=t,!0},t.prototype.explainEvents=function(t){return{down:!!(1&t),up:!!(2&t),drag:!!(4&t),move:!!(8&t),wheel:!!(16&t)}},t.prototype._compareEvents=function(t,e){return t.col===e.col&&t.row===e.row&&t.button===e.button&&t.action===e.action&&t.ctrl===e.ctrl&&t.alt===e.alt&&t.shift===e.shift},i([r(0,o.IBufferService),r(1,o.ICoreService)],t)}();e.CoreMouseService=h},function(t,e,n){"use strict";var i=this&&this.__decorate||function(t,e,n,i){var r,o=arguments.length,a=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,i);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(o<3?r(a):o>3?r(e,n,a):r(e,n))||a);return o>3&&a&&Object.defineProperty(e,n,a),a},r=this&&this.__param||function(t,e){return function(n,i){e(n,i,t)}};Object.defineProperty(e,"__esModule",{value:!0}),e.DirtyRowService=void 0;var o=n(1),a=function(){function t(t){this._bufferService=t,this.clearRange()}return Object.defineProperty(t.prototype,"start",{get:function(){return this._start},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"end",{get:function(){return this._end},enumerable:!1,configurable:!0}),t.prototype.clearRange=function(){this._start=this._bufferService.buffer.y,this._end=this._bufferService.buffer.y},t.prototype.markDirty=function(t){t<this._start?this._start=t:t>this._end&&(this._end=t)},t.prototype.markRangeDirty=function(t,e){if(t>e){var n=t;t=e,e=n}t<this._start&&(this._start=t),e>this._end&&(this._end=e)},t.prototype.markAllDirty=function(){this.markRangeDirty(0,this._bufferService.rows-1)},i([r(0,o.IBufferService)],t)}();e.DirtyRowService=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UnicodeService=void 0;var i=n(0),r=n(79),o=function(){function t(){this._providers=Object.create(null),this._active="",this._onChange=new i.EventEmitter;var t=new r.UnicodeV6;this.register(t),this._active=t.version,this._activeProvider=t}return Object.defineProperty(t.prototype,"onChange",{get:function(){return this._onChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"versions",{get:function(){return Object.keys(this._providers)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"activeVersion",{get:function(){return this._active},set:function(t){if(!this._providers[t])throw new Error('unknown Unicode version "'+t+'"');this._active=t,this._activeProvider=this._providers[t],this._onChange.fire(t)},enumerable:!1,configurable:!0}),t.prototype.register=function(t){this._providers[t.version]=t},t.prototype.wcwidth=function(t){return this._activeProvider.wcwidth(t)},t.prototype.getStringCellWidth=function(t){for(var e=0,n=t.length,i=0;i<n;++i){var r=t.charCodeAt(i);if(55296<=r&&r<=56319){if(++i>=n)return e+this.wcwidth(r);var o=t.charCodeAt(i);56320<=o&&o<=57343?r=1024*(r-55296)+o-56320+65536:e+=this.wcwidth(o)}e+=this.wcwidth(r)}return e},t}();e.UnicodeService=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UnicodeV6=void 0;var i,r=n(15),o=[[768,879],[1155,1158],[1160,1161],[1425,1469],[1471,1471],[1473,1474],[1476,1477],[1479,1479],[1536,1539],[1552,1557],[1611,1630],[1648,1648],[1750,1764],[1767,1768],[1770,1773],[1807,1807],[1809,1809],[1840,1866],[1958,1968],[2027,2035],[2305,2306],[2364,2364],[2369,2376],[2381,2381],[2385,2388],[2402,2403],[2433,2433],[2492,2492],[2497,2500],[2509,2509],[2530,2531],[2561,2562],[2620,2620],[2625,2626],[2631,2632],[2635,2637],[2672,2673],[2689,2690],[2748,2748],[2753,2757],[2759,2760],[2765,2765],[2786,2787],[2817,2817],[2876,2876],[2879,2879],[2881,2883],[2893,2893],[2902,2902],[2946,2946],[3008,3008],[3021,3021],[3134,3136],[3142,3144],[3146,3149],[3157,3158],[3260,3260],[3263,3263],[3270,3270],[3276,3277],[3298,3299],[3393,3395],[3405,3405],[3530,3530],[3538,3540],[3542,3542],[3633,3633],[3636,3642],[3655,3662],[3761,3761],[3764,3769],[3771,3772],[3784,3789],[3864,3865],[3893,3893],[3895,3895],[3897,3897],[3953,3966],[3968,3972],[3974,3975],[3984,3991],[3993,4028],[4038,4038],[4141,4144],[4146,4146],[4150,4151],[4153,4153],[4184,4185],[4448,4607],[4959,4959],[5906,5908],[5938,5940],[5970,5971],[6002,6003],[6068,6069],[6071,6077],[6086,6086],[6089,6099],[6109,6109],[6155,6157],[6313,6313],[6432,6434],[6439,6440],[6450,6450],[6457,6459],[6679,6680],[6912,6915],[6964,6964],[6966,6970],[6972,6972],[6978,6978],[7019,7027],[7616,7626],[7678,7679],[8203,8207],[8234,8238],[8288,8291],[8298,8303],[8400,8431],[12330,12335],[12441,12442],[43014,43014],[43019,43019],[43045,43046],[64286,64286],[65024,65039],[65056,65059],[65279,65279],[65529,65531]],a=[[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]],s=function(){function t(){if(this.version="6",!i){i=new Uint8Array(65536),r.fill(i,1),i[0]=0,r.fill(i,0,1,32),r.fill(i,0,127,160),r.fill(i,2,4352,4448),i[9001]=2,i[9002]=2,r.fill(i,2,11904,42192),i[12351]=1,r.fill(i,2,44032,55204),r.fill(i,2,63744,64256),r.fill(i,2,65040,65050),r.fill(i,2,65072,65136),r.fill(i,2,65280,65377),r.fill(i,2,65504,65511);for(var t=0;t<o.length;++t)r.fill(i,0,o[t][0],o[t][1]+1)}}return t.prototype.wcwidth=function(t){return t<32?0:t<127?1:t<65536?i[t]:function(t,e){var n,i=0,r=e.length-1;if(t<e[0][0]||t>e[r][1])return!1;for(;r>=i;)if(t>e[n=i+r>>1][1])i=n+1;else{if(!(t<e[n][0]))return!0;r=n-1}return!1}(t,a)?0:t>=131072&&t<=196605||t>=196608&&t<=262141?2:1},t}();e.UnicodeV6=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CharsetService=void 0;var i=function(){function t(){this.glevel=0,this._charsets=[]}return t.prototype.reset=function(){this.charset=void 0,this._charsets=[],this.glevel=0},t.prototype.setgLevel=function(t){this.glevel=t,this.charset=this._charsets[t]},t.prototype.setgCharset=function(t,e){this._charsets[t]=e,this.glevel===t&&(this.charset=e)},t}();e.CharsetService=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.updateWindowsModeWrappedState=void 0;var i=n(3);e.updateWindowsModeWrappedState=function(t){var e=t.buffer.lines.get(t.buffer.ybase+t.buffer.y-1),n=null==e?void 0:e.get(t.cols-1),r=t.buffer.lines.get(t.buffer.ybase+t.buffer.y);r&&n&&(r.isWrapped=n[i.CHAR_DATA_CODE_INDEX]!==i.NULL_CELL_CODE&&n[i.CHAR_DATA_CODE_INDEX]!==i.WHITESPACE_CELL_CODE)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.WriteBuffer=void 0;var i=function(){function t(t){this._action=t,this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=0}return t.prototype.writeSync=function(t){if(this._writeBuffer.length){for(var e=this._bufferOffset;e<this._writeBuffer.length;++e){var n=this._callbacks[e];this._action(this._writeBuffer[e]),n&&n()}this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=2147483647}this._action(t)},t.prototype.write=function(t,e){var n=this;if(this._pendingData>5e7)throw new Error("write data discarded, use flow control to avoid losing data");this._writeBuffer.length||(this._bufferOffset=0,setTimeout((function(){return n._innerWrite()}))),this._pendingData+=t.length,this._writeBuffer.push(t),this._callbacks.push(e)},t.prototype._innerWrite=function(){for(var t=this,e=Date.now();this._writeBuffer.length>this._bufferOffset;){var n=this._writeBuffer[this._bufferOffset],i=this._callbacks[this._bufferOffset];if(this._bufferOffset++,this._action(n),this._pendingData-=n.length,i&&i(),Date.now()-e>=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 t._innerWrite()}),0)):(this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=0)},t}();e.WriteBuffer=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AddonManager=void 0;var i=function(){function t(){this._addons=[]}return t.prototype.dispose=function(){for(var t=this._addons.length-1;t>=0;t--)this._addons[t].instance.dispose()},t.prototype.loadAddon=function(t,e){var n=this,i={instance:e,dispose:e.dispose,isDisposed:!1};this._addons.push(i),e.dispose=function(){return n._wrappedAddonDispose(i)},e.activate(t)},t.prototype._wrappedAddonDispose=function(t){if(!t.isDisposed){for(var e=-1,n=0;n<this._addons.length;n++)if(this._addons[n]===t){e=n;break}if(-1===e)throw new Error("Could not dispose an addon that has not been loaded");t.isDisposed=!0,t.dispose.apply(t.instance),this._addons.splice(e,1)}},t}();e.AddonManager=i}])},"/slF":function(t,e,n){var i=n("vd7W").isDigit,r=n("vd7W").cmpChar,o=n("vd7W").TYPE,a=o.Delim,s=o.WhiteSpace,c=o.Comment,l=o.Ident,u=o.Number,h=o.Dimension;function d(t,e){return null!==t&&t.type===a&&t.value.charCodeAt(0)===e}function f(t,e,n){for(;null!==t&&(t.type===s||t.type===c);)t=n(++e);return e}function p(t,e,n,r){if(!t)return 0;var o=t.value.charCodeAt(e);if(43===o||45===o){if(n)return 0;e++}for(;e<t.value.length;e++)if(!i(t.value.charCodeAt(e)))return 0;return r+1}function m(t,e,n){var i=!1,r=f(t,e,n);if(null===(t=n(r)))return e;if(t.type!==u){if(!d(t,43)&&!d(t,45))return e;if(i=!0,r=f(n(++r),r,n),null===(t=n(r))&&t.type!==u)return 0}if(!i){var o=t.value.charCodeAt(0);if(43!==o&&45!==o)return 0}return p(t,i?0:1,i,r)}t.exports=function(t,e){var n=0;if(!t)return 0;if(t.type===u)return p(t,0,!1,n);if(t.type===l&&45===t.value.charCodeAt(0)){if(!r(t.value,1,110))return 0;switch(t.value.length){case 2:return m(e(++n),n,e);case 3:return 45!==t.value.charCodeAt(2)?0:(n=f(e(++n),n,e),p(t=e(n),0,!0,n));default:return 45!==t.value.charCodeAt(2)?0:p(t,3,!0,n)}}else if(t.type===l||d(t,43)&&e(n+1).type===l){if(t.type!==l&&(t=e(++n)),null===t||!r(t.value,0,110))return 0;switch(t.value.length){case 1:return m(e(++n),n,e);case 2:return 45!==t.value.charCodeAt(1)?0:(n=f(e(++n),n,e),p(t=e(n),0,!0,n));default:return 45!==t.value.charCodeAt(1)?0:p(t,2,!0,n)}}else if(t.type===h){for(var o=t.value.charCodeAt(0),a=43===o||45===o?1:0,s=a;s<t.value.length&&i(t.value.charCodeAt(s));s++);return s===a?0:r(t.value,s,110)?s+1===t.value.length?m(e(++n),n,e):45!==t.value.charCodeAt(s+1)?0:s+2===t.value.length?(n=f(e(++n),n,e),p(t=e(n),0,!0,n)):p(t,s+2,!0,n):0}return 0}},"/uUt":function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q");function c(t,e){return function(n){return n.lift(new l(t,e))}}var l=function(){function t(e,n){Object(o.a)(this,t),this.compare=e,this.keySelector=n}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new u(t,this.compare,this.keySelector))}}]),t}(),u=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i,r){var a;return Object(o.a)(this,n),(a=e.call(this,t)).keySelector=r,a.hasKey=!1,"function"==typeof i&&(a.compare=i),a}return Object(a.a)(n,[{key:"compare",value:function(t,e){return t===e}},{key:"_next",value:function(t){var e;try{var n=this.keySelector;e=n?n(t):t}catch(r){return this.destination.error(r)}var i=!1;if(this.hasKey)try{i=(0,this.compare)(this.key,e)}catch(r){return this.destination.error(r)}else this.hasKey=!0;i||(this.key=e,this.destination.next(t))}}]),n}(s.a)},0:function(t,e,n){t.exports=n("zUnb")},"00Es":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("bb3/");i.Observable.prototype.timestamp=r.timestamp},"02G1":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");e.merge=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return this.lift.call(i.merge.apply(void 0,[this].concat(t)))}},"06ho":function(t,e){t.exports={name:"Value",structure:{children:[[]]},parse:function(){var t=this.scanner.tokenStart,e=this.readSequence(this.scope.Value);return{type:"Value",loc:this.getLocation(t,this.scanner.tokenStart),children:e}},generate:function(t){this.children(t)}}},"0EUg":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("bHdf");function r(){return Object(i.a)(1)}},"0ZAG":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("8mU2");i.Observable.prototype.takeLast=r.takeLast},"0c70":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.toArray=function(){return i.toArray()(this)}},"11EI":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.fromEventPattern=i.fromEventPattern},"16Oq":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.retry=function(t){return void 0===t&&(t=-1),i.retry(t)(this)}},"19/K":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("Sj+y"),r=function(){return i.b.create}()},"1G5W":function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("l7GE"),c=n("ZUHj");function l(t){return function(e){return e.lift(new u(t))}}var u=function(){function t(e){Object(o.a)(this,t),this.notifier=e}return Object(a.a)(t,[{key:"call",value:function(t,e){var n=new h(t),i=Object(c.a)(n,this.notifier);return i&&!n.seenValue?(n.add(i),e.subscribe(n)):n}}]),t}(),h=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t){var i;return Object(o.a)(this,n),(i=e.call(this,t)).seenValue=!1,i}return Object(a.a)(n,[{key:"notifyNext",value:function(t,e,n,i,r){this.seenValue=!0,this.complete()}},{key:"notifyComplete",value:function(){}}]),n}(s.a)},"1JPw":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.bindCallback=i.bindCallback},"1M8x":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("Xk39");i.Observable.prototype.catch=r._catch,i.Observable.prototype._catch=r._catch},"1OyB":function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}n.d(e,"a",(function(){return i}))},"1aLD":function(t,e,n){var i=n("XDwu");function r(t,e){function n(t,e){return i.slice(t,e).map((function(e,n){for(var i=String(t+n+1);i.length<c;)i=" "+i;return i+" |"+e})).join("\n")}var i=t.source.split(/\r\n?|\n|\f/),r=t.line,o=t.column,a=Math.max(1,r-e)-1,s=Math.min(r+e,i.length+1),c=Math.max(4,String(s).length)+1,l=0;(o+=(" ".length-1)*(i[r-1].substr(0,o-1).match(/\t/g)||[]).length)>100&&(l=o-60+3,o=58);for(var u=a;u<=s;u++)u>=0&&u<i.length&&(i[u]=i[u].replace(/\t/g," "),i[u]=(l>0&&i[u].length>l?"\u2026":"")+i[u].substr(l,98)+(i[u].length>l+100-1?"\u2026":""));return[n(a,r),new Array(o+c+2).join("-")+"^",n(r,s)].filter(Boolean).join("\n")}t.exports=function(t,e,n,o,a){var s=i("SyntaxError",t);return s.source=e,s.offset=n,s.line=o,s.column=a,s.sourceFragment=function(t){return r(s,isNaN(t)?0:t)},Object.defineProperty(s,"formattedMessage",{get:function(){return"Parse error: "+s.message+"\n"+r(s,2)}}),s.parseError={offset:n,line:o,column:a},s}},"1gRP":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.materialize=function(){return i.materialize()(this)}},"1uah":function(t,e,n){"use strict";n.d(e,"b",(function(){return f})),n.d(e,"a",(function(){return p}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("yCtX"),c=n("DH7j"),l=n("7o/Q"),u=n("l7GE"),h=n("ZUHj"),d=n("Lhse");function f(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var i=e[e.length-1];return"function"==typeof i&&e.pop(),Object(s.a)(e,void 0).lift(new p(i))}var p=function(){function t(e){Object(o.a)(this,t),this.resultSelector=e}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new m(t,this.resultSelector))}}]),t}(),m=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Object.create(null);return Object(o.a)(this,n),(r=e.call(this,t)).iterators=[],r.active=0,r.resultSelector="function"==typeof i?i:null,r.values=a,r}return Object(a.a)(n,[{key:"_next",value:function(t){var e=this.iterators;Object(c.a)(t)?e.push(new v(t)):e.push("function"==typeof t[d.a]?new g(t[d.a]()):new b(this.destination,this,t))}},{key:"_complete",value:function(){var t=this.iterators,e=t.length;if(this.unsubscribe(),0!==e){this.active=e;for(var n=0;n<e;n++){var i=t[n];i.stillUnsubscribed?this.destination.add(i.subscribe(i,n)):this.active--}}else this.destination.complete()}},{key:"notifyInactive",value:function(){this.active--,0===this.active&&this.destination.complete()}},{key:"checkIterators",value:function(){for(var t=this.iterators,e=t.length,n=this.destination,i=0;i<e;i++){var r=t[i];if("function"==typeof r.hasValue&&!r.hasValue())return}for(var o=!1,a=[],s=0;s<e;s++){var c=t[s],l=c.next();if(c.hasCompleted()&&(o=!0),l.done)return void n.complete();a.push(l.value)}this.resultSelector?this._tryresultSelector(a):n.next(a),o&&n.complete()}},{key:"_tryresultSelector",value:function(t){var e;try{e=this.resultSelector.apply(this,t)}catch(n){return void this.destination.error(n)}this.destination.next(e)}}]),n}(l.a),g=function(){function t(e){Object(o.a)(this,t),this.iterator=e,this.nextResult=e.next()}return Object(a.a)(t,[{key:"hasValue",value:function(){return!0}},{key:"next",value:function(){var t=this.nextResult;return this.nextResult=this.iterator.next(),t}},{key:"hasCompleted",value:function(){var t=this.nextResult;return t&&t.done}}]),t}(),v=function(){function t(e){Object(o.a)(this,t),this.array=e,this.index=0,this.length=0,this.length=e.length}return Object(a.a)(t,[{key:d.a,value:function(){return this}},{key:"next",value:function(t){var e=this.index++;return e<this.length?{value:this.array[e],done:!1}:{value:null,done:!0}}},{key:"hasValue",value:function(){return this.array.length>this.index}},{key:"hasCompleted",value:function(){return this.array.length===this.index}}]),t}(),b=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i,r){var a;return Object(o.a)(this,n),(a=e.call(this,t)).parent=i,a.observable=r,a.stillUnsubscribed=!0,a.buffer=[],a.isComplete=!1,a}return Object(a.a)(n,[{key:d.a,value:function(){return this}},{key:"next",value:function(){var t=this.buffer;return 0===t.length&&this.isComplete?{value:null,done:!0}:{value:t.shift(),done:!1}}},{key:"hasValue",value:function(){return this.buffer.length>0}},{key:"hasCompleted",value:function(){return 0===this.buffer.length&&this.isComplete}},{key:"notifyComplete",value:function(){this.buffer.length>0?(this.isComplete=!0,this.parent.notifyInactive()):this.destination.complete()}},{key:"notifyNext",value:function(t,e,n,i,r){this.buffer.push(e),this.parent.checkIterators()}},{key:"subscribe",value:function(t,e){return Object(h.a)(this,this.observable,this,e)}}]),n}(u.a)},"2+DN":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("uMcE");i.Observable.prototype.shareReplay=r.shareReplay},"25BE":function(t,e,n){"use strict";function i(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}n.d(e,"a",(function(){return i}))},"2Gxe":function(t,e,n){var i=n("vd7W").TYPE,r=i.Ident,o=i.String,a=i.Colon,s=i.LeftSquareBracket,c=i.RightSquareBracket;function l(){this.scanner.eof&&this.error("Unexpected end of input");var t=this.scanner.tokenStart,e=!1,n=!0;return this.scanner.isDelim(42)?(e=!0,n=!1,this.scanner.next()):this.scanner.isDelim(124)||this.eat(r),this.scanner.isDelim(124)?61!==this.scanner.source.charCodeAt(this.scanner.tokenStart+1)?(this.scanner.next(),this.eat(r)):e&&this.error("Identifier is expected",this.scanner.tokenEnd):e&&this.error("Vertical line is expected"),n&&this.scanner.tokenType===a&&(this.scanner.next(),this.eat(r)),{type:"Identifier",loc:this.getLocation(t,this.scanner.tokenStart),name:this.scanner.substrToCursor(t)}}function u(){var t=this.scanner.tokenStart,e=this.scanner.source.charCodeAt(t);return 61!==e&&126!==e&&94!==e&&36!==e&&42!==e&&124!==e&&this.error("Attribute selector (=, ~=, ^=, $=, *=, |=) is expected"),this.scanner.next(),61!==e&&(this.scanner.isDelim(61)||this.error("Equal sign is expected"),this.scanner.next()),this.scanner.substrToCursor(t)}t.exports={name:"AttributeSelector",structure:{name:"Identifier",matcher:[String,null],value:["String","Identifier",null],flags:[String,null]},parse:function(){var t,e=this.scanner.tokenStart,n=null,i=null,a=null;return this.eat(s),this.scanner.skipSC(),t=l.call(this),this.scanner.skipSC(),this.scanner.tokenType!==c&&(this.scanner.tokenType!==r&&(n=u.call(this),this.scanner.skipSC(),i=this.scanner.tokenType===o?this.String():this.Identifier(),this.scanner.skipSC()),this.scanner.tokenType===r&&(a=this.scanner.getTokenValue(),this.scanner.next(),this.scanner.skipSC())),this.eat(c),{type:"AttributeSelector",loc:this.getLocation(e,this.scanner.tokenStart),name:t,matcher:n,value:i,flags:a}},generate:function(t){var e=" ";this.chunk("["),this.node(t.name),null!==t.matcher&&(this.chunk(t.matcher),null!==t.value&&(this.node(t.value),"String"===t.value.type&&(e=""))),null!==t.flags&&(this.chunk(e),this.chunk(t.flags)),this.chunk("]")}}},"2IC2":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("j5kd");i.Observable.prototype.windowTime=r.windowTime},"2QA8":function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){return"function"==typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random()}()},"2TAq":function(t,e,n){var i=n("vd7W").isHexDigit,r=n("vd7W").cmpChar,o=n("vd7W").TYPE,a=o.Ident,s=o.Delim,c=o.Number,l=o.Dimension;function u(t,e){return null!==t&&t.type===s&&t.value.charCodeAt(0)===e}function h(t,e){return t.value.charCodeAt(0)===e}function d(t,e,n){for(var r=e,o=0;r<t.value.length;r++){var a=t.value.charCodeAt(r);if(45===a&&n&&0!==o)return d(t,e+o+1,!1)>0?6:0;if(!i(a))return 0;if(++o>6)return 0}return o}function f(t,e,n){if(!t)return 0;for(;u(n(e),63);){if(++t>6)return 0;e++}return e}t.exports=function(t,e){var n=0;if(null===t||t.type!==a||!r(t.value,0,117))return 0;if(null===(t=e(++n)))return 0;if(u(t,43))return null===(t=e(++n))?0:t.type===a?f(d(t,0,!0),++n,e):u(t,63)?f(1,++n,e):0;if(t.type===c){if(!h(t,43))return 0;var i=d(t,1,!0);return 0===i?0:null===(t=e(++n))?n:t.type===l||t.type===c?h(t,45)&&d(t,1,!1)?n+1:0:f(i,n,e)}return t.type===l&&h(t,43)?f(d(t,1,!0),++n,e):0}},"2Vo4":function(t,e,n){"use strict";n.d(e,"a",(function(){return h}));var i=n("1OyB"),r=n("vuIU"),o=n("ReuC"),a=n("foSv"),s=n("Ji7U"),c=n("LK+K"),l=n("XNiG"),u=n("9ppp"),h=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t){var r;return Object(i.a)(this,n),(r=e.call(this))._value=t,r}return Object(r.a)(n,[{key:"_subscribe",value:function(t){var e=Object(o.a)(Object(a.a)(n.prototype),"_subscribe",this).call(this,t);return e&&!e.closed&&t.next(this._value),e}},{key:"getValue",value:function(){if(this.hasError)throw this.thrownError;if(this.closed)throw new u.a;return this._value}},{key:"next",value:function(t){Object(o.a)(Object(a.a)(n.prototype),"next",this).call(this,this._value=t)}},{key:"value",get:function(){return this.getValue()}}]),n}(l.b)},"2WcH":function(t,e,n){"use strict";function i(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}n.d(e,"a",(function(){return i}))},"2fFW":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=!1,r={Promise:void 0,set useDeprecatedSynchronousErrorHandling(t){if(t){var e=new Error;console.warn("DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n"+e.stack)}else i&&console.log("RxJS: Back to a better error behavior. Thank you. <3");i=t},get useDeprecatedSynchronousErrorHandling(){return i}}},"2pxp":function(t,e){t.exports={parse:function(){return this.createSingleNodeList(this.SelectorList())}}},"338f":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.concatMap=function(t){return i.concatMap(t)(this)}},"33Dm":function(t,e,n){var i=n("vd7W").TYPE,r=i.WhiteSpace,o=i.Comment,a=i.Ident,s=i.LeftParenthesis;t.exports={name:"MediaQuery",structure:{children:[["Identifier","MediaFeature","WhiteSpace"]]},parse:function(){this.scanner.skipSC();var t=this.createList(),e=null,n=null;t:for(;!this.scanner.eof;){switch(this.scanner.tokenType){case o:this.scanner.next();continue;case r:n=this.WhiteSpace();continue;case a:e=this.Identifier();break;case s:e=this.MediaFeature();break;default:break t}null!==n&&(t.push(n),n=null),t.push(e)}return null===e&&this.error("Identifier or parenthesis is expected"),{type:"MediaQuery",loc:this.getLocationFromList(t),children:t}},generate:function(t){this.children(t)}}},"37L2":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("338f");i.Observable.prototype.concatMap=r.concatMap},"3E0/":function(t,e,n){"use strict";n.d(e,"a",(function(){return h}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("D0XW"),c=n("mlxB"),l=n("7o/Q"),u=n("WMd4");function h(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:s.a,n=Object(c.a)(t),i=n?+t-e.now():Math.abs(t);return function(t){return t.lift(new d(i,e))}}var d=function(){function t(e,n){Object(o.a)(this,t),this.delay=e,this.scheduler=n}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new f(t,this.delay,this.scheduler))}}]),t}(),f=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i,r){var a;return Object(o.a)(this,n),(a=e.call(this,t)).delay=i,a.scheduler=r,a.queue=[],a.active=!1,a.errored=!1,a}return Object(a.a)(n,[{key:"_schedule",value:function(t){this.active=!0,this.destination.add(t.schedule(n.dispatch,this.delay,{source:this,destination:this.destination,scheduler:t}))}},{key:"scheduleNotification",value:function(t){if(!0!==this.errored){var e=this.scheduler,n=new p(e.now()+this.delay,t);this.queue.push(n),!1===this.active&&this._schedule(e)}}},{key:"_next",value:function(t){this.scheduleNotification(u.a.createNext(t))}},{key:"_error",value:function(t){this.errored=!0,this.queue=[],this.destination.error(t),this.unsubscribe()}},{key:"_complete",value:function(){this.scheduleNotification(u.a.createComplete()),this.unsubscribe()}}],[{key:"dispatch",value:function(t){for(var e=t.source,n=e.queue,i=t.scheduler,r=t.destination;n.length>0&&n[0].time-i.now()<=0;)n.shift().notification.observe(r);if(n.length>0){var o=Math.max(0,n[0].time-i.now());this.schedule(t,o)}else this.unsubscribe(),e.active=!1}}]),n}(l.a),p=function t(e,n){Object(o.a)(this,t),this.time=e,this.notification=n}},"3EiV":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("dL1u");i.Observable.prototype.buffer=r.buffer},"3N8a":function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("1OyB"),r=n("vuIU"),o=n("Ji7U"),a=n("LK+K"),s=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,r){var o;return Object(i.a)(this,n),(o=e.call(this,t,r)).scheduler=t,o.work=r,o.pending=!1,o}return Object(r.a)(n,[{key:"schedule",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;if(this.closed)return this;this.state=t;var n=this.id,i=this.scheduler;return null!=n&&(this.id=this.recycleAsyncId(i,n,e)),this.pending=!0,this.delay=e,this.id=this.id||this.requestAsyncId(i,this.id,e),this}},{key:"requestAsyncId",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return setInterval(t.flush.bind(t,this),n)}},{key:"recycleAsyncId",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(null!==n&&this.delay===n&&!1===this.pending)return e;clearInterval(e)}},{key:"execute",value:function(t,e){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;var n=this._execute(t,e);if(n)return n;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}},{key:"_execute",value:function(t,e){var n=!1,i=void 0;try{this.work(t)}catch(r){n=!0,i=!!r&&r||new Error(r)}if(n)return this.unsubscribe(),i}},{key:"_unsubscribe",value:function(){var t=this.id,e=this.scheduler,n=e.actions,i=n.indexOf(this);this.work=null,this.state=null,this.pending=!1,this.scheduler=null,-1!==i&&n.splice(i,1),null!=t&&(this.id=this.recycleAsyncId(e,t,null)),this.delay=null}}]),n}(function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,r){return Object(i.a)(this,n),e.call(this)}return Object(r.a)(n,[{key:"schedule",value:function(t){return this}}]),n}(n("quSY").a))},"3Qpg":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.fromPromise=i.from},"3UD+":function(t,e){t.exports=function(t){if(!t.webpackPolyfill){var e=Object.create(t);e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),Object.defineProperty(e,"exports",{enumerable:!0}),e.webpackPolyfill=1}return e}},"3UWI":function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("D0XW"),r=n("tnsW"),o=n("PqYM");function a(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:i.a;return Object(r.a)((function(){return Object(o.a)(t,e)}))}},"3XNy":function(t,e){function n(t){return t>=48&&t<=57}function i(t){return t>=65&&t<=90}function r(t){return t>=97&&t<=122}function o(t){return i(t)||r(t)}function a(t){return t>=128}function s(t){return o(t)||a(t)||95===t}function c(t){return t>=0&&t<=8||11===t||t>=14&&t<=31||127===t}function l(t){return 10===t||13===t||12===t}function u(t){return l(t)||32===t||9===t}function h(t,e){return 92===t&&!l(e)&&0!==e}var d=new Array(128);p.Eof=128,p.WhiteSpace=130,p.Digit=131,p.NameStart=132,p.NonPrintable=133;for(var f=0;f<d.length;f++)switch(!0){case u(f):d[f]=p.WhiteSpace;break;case n(f):d[f]=p.Digit;break;case s(f):d[f]=p.NameStart;break;case c(f):d[f]=p.NonPrintable;break;default:d[f]=f||p.Eof}function p(t){return t<128?d[t]:p.NameStart}t.exports={isDigit:n,isHexDigit:function(t){return n(t)||t>=65&&t<=70||t>=97&&t<=102},isUppercaseLetter:i,isLowercaseLetter:r,isLetter:o,isNonAscii:a,isNameStart:s,isName:function(t){return s(t)||n(t)||45===t},isNonPrintable:c,isNewline:l,isWhiteSpace:u,isValidEscape:h,isIdentifierStart:function(t,e,n){return 45===t?s(e)||45===e||h(e,n):!!s(t)||92===t&&h(t,e)},isNumberStart:function(t,e,i){return 43===t||45===t?n(e)?2:46===e&&n(i)?3:0:46===t?n(e)?2:0:n(t)?1:0},isBOM:function(t){return 65279===t||65534===t?1:0},charCodeCategory:p}},"3uOa":function(t,e,n){"use strict";n.r(e);var i=n("lcII");n.d(e,"webSocket",(function(){return i.a}));var r=n("wxn8");n.d(e,"WebSocketSubject",(function(){return r.a}))},"4AtU":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.expand=function(t,e,n){return void 0===e&&(e=Number.POSITIVE_INFINITY),void 0===n&&(n=void 0),i.expand(t,e=(e||0)<1?Number.POSITIVE_INFINITY:e,n)(this)}},"4HHr":function(t,e){var n=Object.prototype.hasOwnProperty,i=function(){};function r(t){return"function"==typeof t?t:i}function o(t,e){return function(n,i,r){n.type===e&&t.call(this,n,i,r)}}function a(t,e){var i=e.structure,r=[];for(var o in i)if(!1!==n.call(i,o)){var a=i[o],s={name:o,type:!1,nullable:!1};Array.isArray(i[o])||(a=[i[o]]);for(var c=0;c<a.length;c++){var l=a[c];null===l?s.nullable=!0:"string"==typeof l?s.type="node":Array.isArray(l)&&(s.type="list")}s.type&&r.push(s)}return r.length?{context:e.walkContext,fields:r}:null}function s(t,e){var n=t.fields.slice(),i=t.context,r="string"==typeof i;return e&&n.reverse(),function(t,o,a){var s;r&&(s=o[i],o[i]=t);for(var c=0;c<n.length;c++){var l=n[c],u=t[l.name];l.nullable&&!u||("list"===l.type?e?u.forEachRight(a):u.forEach(a):a(u))}r&&(o[i]=s)}}function c(t){return{Atrule:{StyleSheet:t.StyleSheet,Atrule:t.Atrule,Rule:t.Rule,Block:t.Block},Rule:{StyleSheet:t.StyleSheet,Atrule:t.Atrule,Rule:t.Rule,Block:t.Block},Declaration:{StyleSheet:t.StyleSheet,Atrule:t.Atrule,Rule:t.Rule,Block:t.Block,DeclarationList:t.DeclarationList}}}t.exports=function(t){var e=function(t){var e={};for(var i in t.node)if(n.call(t.node,i)){var r=t.node[i];if(!r.structure)throw new Error("Missed `structure` field in `"+i+"` node type definition");e[i]=a(0,r)}return e}(t),l={},u={};for(var h in e)n.call(e,h)&&null!==e[h]&&(l[h]=s(e[h],!1),u[h]=s(e[h],!0));var d=c(l),f=c(u),p=function(t,n){var a=i,s=i,c=l,h={root:t,stylesheet:null,atrule:null,atrulePrelude:null,rule:null,selector:null,block:null,declaration:null,function:null};if("function"==typeof n)a=n;else if(n&&(a=r(n.enter),s=r(n.leave),n.reverse&&(c=u),n.visit)){if(d.hasOwnProperty(n.visit))c=n.reverse?f[n.visit]:d[n.visit];else if(!e.hasOwnProperty(n.visit))throw new Error("Bad value `"+n.visit+"` for `visit` option (should be: "+Object.keys(e).join(", ")+")");a=o(a,n.visit),s=o(s,n.visit)}if(a===i&&s===i)throw new Error("Neither `enter` nor `leave` walker handler is set or both aren't a function");if(n.reverse){var p=a;a=s,s=p}!function t(e,n,i){a.call(h,e,n,i),c.hasOwnProperty(e.type)&&c[e.type](e,h,t),s.call(h,e,n,i)}(t)};return p.find=function(t,e){var n=null;return p(t,(function(t,i,r){null===n&&e.call(this,t,i,r)&&(n=t)})),n},p.findLast=function(t,e){var n=null;return p(t,{reverse:!0,enter:function(t,i,r){null===n&&e.call(this,t,i,r)&&(n=t)}}),n},p.findAll=function(t,e){var n=[];return p(t,(function(t,i,r){e.call(this,t,i,r)&&n.push(t)})),n},p}},"4Hgy":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e._do=function(t,e,n){return i.tap(t,e,n)(this)}},"4I5i":function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){function t(){return Error.call(this),this.message="argument out of range",this.name="ArgumentOutOfRangeError",this}return t.prototype=Object.create(Error.prototype),t}()},"4Wg5":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("nZYK");i.Observable.prototype.switchMap=r.switchMap},"4fRq":function(t,e){var n="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(n){var i=new Uint8Array(16);t.exports=function(){return n(i),i}}else{var r=new Array(16);t.exports=function(){for(var t,e=0;e<16;e++)0==(3&e)&&(t=4294967296*Math.random()),r[e]=t>>>((3&e)<<3)&255;return r}}},"4hIw":function(t,e,n){"use strict";n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return l}));var i=n("1OyB"),r=n("D0XW"),o=n("Kqap"),a=n("NXyV"),s=n("lJxs");function c(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:r.a;return function(e){return Object(a.a)((function(){return e.pipe(Object(o.a)((function(e,n){var i=e.current;return{value:n,current:t.now(),last:i}}),{current:t.now(),value:void 0,last:void 0}),Object(s.a)((function(t){return new l(t.value,t.current-t.last)})))}))}}var l=function t(e,n){Object(i.a)(this,t),this.value=e,this.interval=n}},"4njK":function(t,e,n){var i=n("vd7W").TYPE,r=i.WhiteSpace,o=i.Semicolon,a=i.LeftCurlyBracket,s=i.Delim;function c(){return this.scanner.tokenIndex>0&&this.scanner.lookupType(-1)===r?this.scanner.tokenIndex>1?this.scanner.getTokenStart(this.scanner.tokenIndex-1):this.scanner.firstCharOffset:this.scanner.tokenStart}function l(){return 0}t.exports={name:"Raw",structure:{value:String},parse:function(t,e,n){var i,r=this.scanner.getTokenStart(t);return this.scanner.skip(this.scanner.getRawLength(t,e||l)),i=n&&this.scanner.tokenStart>r?c.call(this):this.scanner.tokenStart,{type:"Raw",loc:this.getLocation(r,i),value:this.scanner.source.substring(r,i)}},generate:function(t){this.chunk(t.value)},mode:{default:l,leftCurlyBracket:function(t){return t===a?1:0},leftCurlyBracketOrSemicolon:function(t){return t===a||t===o?1:0},exclamationMarkOrSemicolon:function(t,e,n){return t===s&&33===e.charCodeAt(n)||t===o?1:0},semicolonIncluded:function(t){return t===o?2:0}}}},"4vYp":function(t){t.exports=JSON.parse('{"generic":true,"types":{"absolute-size":"xx-small|x-small|small|medium|large|x-large|xx-large","alpha-value":"<number>|<percentage>","angle-percentage":"<angle>|<percentage>","angular-color-hint":"<angle-percentage>","angular-color-stop":"<color>&&<color-stop-angle>?","angular-color-stop-list":"[<angular-color-stop> [, <angular-color-hint>]?]# , <angular-color-stop>","animateable-feature":"scroll-position|contents|<custom-ident>","attachment":"scroll|fixed|local","attr()":"attr( <attr-name> <type-or-unit>? [, <attr-fallback>]? )","attr-matcher":"[\'~\'|\'|\'|\'^\'|\'$\'|\'*\']? \'=\'","attr-modifier":"i|s","attribute-selector":"\'[\' <wq-name> \']\'|\'[\' <wq-name> <attr-matcher> [<string-token>|<ident-token>] <attr-modifier>? \']\'","auto-repeat":"repeat( [auto-fill|auto-fit] , [<line-names>? <fixed-size>]+ <line-names>? )","auto-track-list":"[<line-names>? [<fixed-size>|<fixed-repeat>]]* <line-names>? <auto-repeat> [<line-names>? [<fixed-size>|<fixed-repeat>]]* <line-names>?","baseline-position":"[first|last]? baseline","basic-shape":"<inset()>|<circle()>|<ellipse()>|<polygon()>","bg-image":"none|<image>","bg-layer":"<bg-image>||<bg-position> [/ <bg-size>]?||<repeat-style>||<attachment>||<box>||<box>","bg-position":"[[left|center|right|top|bottom|<length-percentage>]|[left|center|right|<length-percentage>] [top|center|bottom|<length-percentage>]|[center|[left|right] <length-percentage>?]&&[center|[top|bottom] <length-percentage>?]]","bg-size":"[<length-percentage>|auto]{1,2}|cover|contain","blur()":"blur( <length> )","blend-mode":"normal|multiply|screen|overlay|darken|lighten|color-dodge|color-burn|hard-light|soft-light|difference|exclusion|hue|saturation|color|luminosity","box":"border-box|padding-box|content-box","brightness()":"brightness( <number-percentage> )","calc()":"calc( <calc-sum> )","calc-sum":"<calc-product> [[\'+\'|\'-\'] <calc-product>]*","calc-product":"<calc-value> [\'*\' <calc-value>|\'/\' <number>]*","calc-value":"<number>|<dimension>|<percentage>|( <calc-sum> )","cf-final-image":"<image>|<color>","cf-mixing-image":"<percentage>?&&<image>","circle()":"circle( [<shape-radius>]? [at <position>]? )","clamp()":"clamp( <calc-sum>#{3} )","class-selector":"\'.\' <ident-token>","clip-source":"<url>","color":"<rgb()>|<rgba()>|<hsl()>|<hsla()>|<hex-color>|<named-color>|currentcolor|<deprecated-system-color>","color-stop":"<color-stop-length>|<color-stop-angle>","color-stop-angle":"<angle-percentage>{1,2}","color-stop-length":"<length-percentage>{1,2}","color-stop-list":"[<linear-color-stop> [, <linear-color-hint>]?]# , <linear-color-stop>","combinator":"\'>\'|\'+\'|\'~\'|[\'||\']","common-lig-values":"[common-ligatures|no-common-ligatures]","compat":"searchfield|textarea|push-button|button-bevel|slider-horizontal|checkbox|radio|square-button|menulist|menulist-button|listbox|meter|progress-bar","composite-style":"clear|copy|source-over|source-in|source-out|source-atop|destination-over|destination-in|destination-out|destination-atop|xor","compositing-operator":"add|subtract|intersect|exclude","compound-selector":"[<type-selector>? <subclass-selector>* [<pseudo-element-selector> <pseudo-class-selector>*]*]!","compound-selector-list":"<compound-selector>#","complex-selector":"<compound-selector> [<combinator>? <compound-selector>]*","complex-selector-list":"<complex-selector>#","conic-gradient()":"conic-gradient( [from <angle>]? [at <position>]? , <angular-color-stop-list> )","contextual-alt-values":"[contextual|no-contextual]","content-distribution":"space-between|space-around|space-evenly|stretch","content-list":"[<string>|contents|<url>|<quote>|<attr()>|counter( <ident> , <\'list-style-type\'>? )]+","content-position":"center|start|end|flex-start|flex-end","content-replacement":"<image>","contrast()":"contrast( [<number-percentage>] )","counter()":"counter( <custom-ident> , [<counter-style>|none]? )","counter-style":"<counter-style-name>|symbols( )","counter-style-name":"<custom-ident>","counters()":"counters( <custom-ident> , <string> , [<counter-style>|none]? )","cross-fade()":"cross-fade( <cf-mixing-image> , <cf-final-image>? )","cubic-bezier-timing-function":"ease|ease-in|ease-out|ease-in-out|cubic-bezier( <number> , <number> , <number> , <number> )","deprecated-system-color":"ActiveBorder|ActiveCaption|AppWorkspace|Background|ButtonFace|ButtonHighlight|ButtonShadow|ButtonText|CaptionText|GrayText|Highlight|HighlightText|InactiveBorder|InactiveCaption|InactiveCaptionText|InfoBackground|InfoText|Menu|MenuText|Scrollbar|ThreeDDarkShadow|ThreeDFace|ThreeDHighlight|ThreeDLightShadow|ThreeDShadow|Window|WindowFrame|WindowText","discretionary-lig-values":"[discretionary-ligatures|no-discretionary-ligatures]","display-box":"contents|none","display-inside":"flow|flow-root|table|flex|grid|ruby","display-internal":"table-row-group|table-header-group|table-footer-group|table-row|table-cell|table-column-group|table-column|table-caption|ruby-base|ruby-text|ruby-base-container|ruby-text-container","display-legacy":"inline-block|inline-list-item|inline-table|inline-flex|inline-grid","display-listitem":"<display-outside>?&&[flow|flow-root]?&&list-item","display-outside":"block|inline|run-in","drop-shadow()":"drop-shadow( <length>{2,3} <color>? )","east-asian-variant-values":"[jis78|jis83|jis90|jis04|simplified|traditional]","east-asian-width-values":"[full-width|proportional-width]","element()":"element( <id-selector> )","ellipse()":"ellipse( [<shape-radius>{2}]? [at <position>]? )","ending-shape":"circle|ellipse","env()":"env( <custom-ident> , <declaration-value>? )","explicit-track-list":"[<line-names>? <track-size>]+ <line-names>?","family-name":"<string>|<custom-ident>+","feature-tag-value":"<string> [<integer>|on|off]?","feature-type":"@stylistic|@historical-forms|@styleset|@character-variant|@swash|@ornaments|@annotation","feature-value-block":"<feature-type> \'{\' <feature-value-declaration-list> \'}\'","feature-value-block-list":"<feature-value-block>+","feature-value-declaration":"<custom-ident> : <integer>+ ;","feature-value-declaration-list":"<feature-value-declaration>","feature-value-name":"<custom-ident>","fill-rule":"nonzero|evenodd","filter-function":"<blur()>|<brightness()>|<contrast()>|<drop-shadow()>|<grayscale()>|<hue-rotate()>|<invert()>|<opacity()>|<saturate()>|<sepia()>","filter-function-list":"[<filter-function>|<url>]+","final-bg-layer":"<\'background-color\'>||<bg-image>||<bg-position> [/ <bg-size>]?||<repeat-style>||<attachment>||<box>||<box>","fit-content()":"fit-content( [<length>|<percentage>] )","fixed-breadth":"<length-percentage>","fixed-repeat":"repeat( [<positive-integer>] , [<line-names>? <fixed-size>]+ <line-names>? )","fixed-size":"<fixed-breadth>|minmax( <fixed-breadth> , <track-breadth> )|minmax( <inflexible-breadth> , <fixed-breadth> )","font-stretch-absolute":"normal|ultra-condensed|extra-condensed|condensed|semi-condensed|semi-expanded|expanded|extra-expanded|ultra-expanded|<percentage>","font-variant-css21":"[normal|small-caps]","font-weight-absolute":"normal|bold|<number>","frequency-percentage":"<frequency>|<percentage>","general-enclosed":"[<function-token> <any-value> )]|( <ident> <any-value> )","generic-family":"serif|sans-serif|cursive|fantasy|monospace|-apple-system","generic-name":"serif|sans-serif|cursive|fantasy|monospace","geometry-box":"<shape-box>|fill-box|stroke-box|view-box","gradient":"<linear-gradient()>|<repeating-linear-gradient()>|<radial-gradient()>|<repeating-radial-gradient()>|<conic-gradient()>|<-legacy-gradient>","grayscale()":"grayscale( <number-percentage> )","grid-line":"auto|<custom-ident>|[<integer>&&<custom-ident>?]|[span&&[<integer>||<custom-ident>]]","historical-lig-values":"[historical-ligatures|no-historical-ligatures]","hsl()":"hsl( <hue> <percentage> <percentage> [/ <alpha-value>]? )|hsl( <hue> , <percentage> , <percentage> , <alpha-value>? )","hsla()":"hsla( <hue> <percentage> <percentage> [/ <alpha-value>]? )|hsla( <hue> , <percentage> , <percentage> , <alpha-value>? )","hue":"<number>|<angle>","hue-rotate()":"hue-rotate( <angle> )","image":"<url>|<image()>|<image-set()>|<element()>|<cross-fade()>|<gradient>","image()":"image( <image-tags>? [<image-src>? , <color>?]! )","image-set()":"image-set( <image-set-option># )","image-set-option":"[<image>|<string>] <resolution>","image-src":"<url>|<string>","image-tags":"ltr|rtl","inflexible-breadth":"<length>|<percentage>|min-content|max-content|auto","inset()":"inset( <length-percentage>{1,4} [round <\'border-radius\'>]? )","invert()":"invert( <number-percentage> )","keyframes-name":"<custom-ident>|<string>","keyframe-block":"<keyframe-selector># { <declaration-list> }","keyframe-block-list":"<keyframe-block>+","keyframe-selector":"from|to|<percentage>","leader()":"leader( <leader-type> )","leader-type":"dotted|solid|space|<string>","length-percentage":"<length>|<percentage>","line-names":"\'[\' <custom-ident>* \']\'","line-name-list":"[<line-names>|<name-repeat>]+","line-style":"none|hidden|dotted|dashed|solid|double|groove|ridge|inset|outset","line-width":"<length>|thin|medium|thick","linear-color-hint":"<length-percentage>","linear-color-stop":"<color> <color-stop-length>?","linear-gradient()":"linear-gradient( [<angle>|to <side-or-corner>]? , <color-stop-list> )","mask-layer":"<mask-reference>||<position> [/ <bg-size>]?||<repeat-style>||<geometry-box>||[<geometry-box>|no-clip]||<compositing-operator>||<masking-mode>","mask-position":"[<length-percentage>|left|center|right] [<length-percentage>|top|center|bottom]?","mask-reference":"none|<image>|<mask-source>","mask-source":"<url>","masking-mode":"alpha|luminance|match-source","matrix()":"matrix( <number>#{6} )","matrix3d()":"matrix3d( <number>#{16} )","max()":"max( <calc-sum># )","media-and":"<media-in-parens> [and <media-in-parens>]+","media-condition":"<media-not>|<media-and>|<media-or>|<media-in-parens>","media-condition-without-or":"<media-not>|<media-and>|<media-in-parens>","media-feature":"( [<mf-plain>|<mf-boolean>|<mf-range>] )","media-in-parens":"( <media-condition> )|<media-feature>|<general-enclosed>","media-not":"not <media-in-parens>","media-or":"<media-in-parens> [or <media-in-parens>]+","media-query":"<media-condition>|[not|only]? <media-type> [and <media-condition-without-or>]?","media-query-list":"<media-query>#","media-type":"<ident>","mf-boolean":"<mf-name>","mf-name":"<ident>","mf-plain":"<mf-name> : <mf-value>","mf-range":"<mf-name> [\'<\'|\'>\']? \'=\'? <mf-value>|<mf-value> [\'<\'|\'>\']? \'=\'? <mf-name>|<mf-value> \'<\' \'=\'? <mf-name> \'<\' \'=\'? <mf-value>|<mf-value> \'>\' \'=\'? <mf-name> \'>\' \'=\'? <mf-value>","mf-value":"<number>|<dimension>|<ident>|<ratio>","min()":"min( <calc-sum># )","minmax()":"minmax( [<length>|<percentage>|<flex>|min-content|max-content|auto] , [<length>|<percentage>|<flex>|min-content|max-content|auto] )","named-color":"transparent|aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen|<-non-standard-color>","namespace-prefix":"<ident>","ns-prefix":"[<ident-token>|\'*\']? \'|\'","number-percentage":"<number>|<percentage>","numeric-figure-values":"[lining-nums|oldstyle-nums]","numeric-fraction-values":"[diagonal-fractions|stacked-fractions]","numeric-spacing-values":"[proportional-nums|tabular-nums]","nth":"<an-plus-b>|even|odd","opacity()":"opacity( [<number-percentage>] )","overflow-position":"unsafe|safe","outline-radius":"<length>|<percentage>","page-body":"<declaration>? [; <page-body>]?|<page-margin-box> <page-body>","page-margin-box":"<page-margin-box-type> \'{\' <declaration-list> \'}\'","page-margin-box-type":"@top-left-corner|@top-left|@top-center|@top-right|@top-right-corner|@bottom-left-corner|@bottom-left|@bottom-center|@bottom-right|@bottom-right-corner|@left-top|@left-middle|@left-bottom|@right-top|@right-middle|@right-bottom","page-selector-list":"[<page-selector>#]?","page-selector":"<pseudo-page>+|<ident> <pseudo-page>*","perspective()":"perspective( <length> )","polygon()":"polygon( <fill-rule>? , [<length-percentage> <length-percentage>]# )","position":"[[left|center|right]||[top|center|bottom]|[left|center|right|<length-percentage>] [top|center|bottom|<length-percentage>]?|[[left|right] <length-percentage>]&&[[top|bottom] <length-percentage>]]","pseudo-class-selector":"\':\' <ident-token>|\':\' <function-token> <any-value> \')\'","pseudo-element-selector":"\':\' <pseudo-class-selector>","pseudo-page":": [left|right|first|blank]","quote":"open-quote|close-quote|no-open-quote|no-close-quote","radial-gradient()":"radial-gradient( [<ending-shape>||<size>]? [at <position>]? , <color-stop-list> )","relative-selector":"<combinator>? <complex-selector>","relative-selector-list":"<relative-selector>#","relative-size":"larger|smaller","repeat-style":"repeat-x|repeat-y|[repeat|space|round|no-repeat]{1,2}","repeating-linear-gradient()":"repeating-linear-gradient( [<angle>|to <side-or-corner>]? , <color-stop-list> )","repeating-radial-gradient()":"repeating-radial-gradient( [<ending-shape>||<size>]? [at <position>]? , <color-stop-list> )","rgb()":"rgb( <percentage>{3} [/ <alpha-value>]? )|rgb( <number>{3} [/ <alpha-value>]? )|rgb( <percentage>#{3} , <alpha-value>? )|rgb( <number>#{3} , <alpha-value>? )","rgba()":"rgba( <percentage>{3} [/ <alpha-value>]? )|rgba( <number>{3} [/ <alpha-value>]? )|rgba( <percentage>#{3} , <alpha-value>? )|rgba( <number>#{3} , <alpha-value>? )","rotate()":"rotate( [<angle>|<zero>] )","rotate3d()":"rotate3d( <number> , <number> , <number> , [<angle>|<zero>] )","rotateX()":"rotateX( [<angle>|<zero>] )","rotateY()":"rotateY( [<angle>|<zero>] )","rotateZ()":"rotateZ( [<angle>|<zero>] )","saturate()":"saturate( <number-percentage> )","scale()":"scale( <number> , <number>? )","scale3d()":"scale3d( <number> , <number> , <number> )","scaleX()":"scaleX( <number> )","scaleY()":"scaleY( <number> )","scaleZ()":"scaleZ( <number> )","self-position":"center|start|end|self-start|self-end|flex-start|flex-end","shape-radius":"<length-percentage>|closest-side|farthest-side","skew()":"skew( [<angle>|<zero>] , [<angle>|<zero>]? )","skewX()":"skewX( [<angle>|<zero>] )","skewY()":"skewY( [<angle>|<zero>] )","sepia()":"sepia( <number-percentage> )","shadow":"inset?&&<length>{2,4}&&<color>?","shadow-t":"[<length>{2,3}&&<color>?]","shape":"rect( <top> , <right> , <bottom> , <left> )|rect( <top> <right> <bottom> <left> )","shape-box":"<box>|margin-box","side-or-corner":"[left|right]||[top|bottom]","single-animation":"<time>||<timing-function>||<time>||<single-animation-iteration-count>||<single-animation-direction>||<single-animation-fill-mode>||<single-animation-play-state>||[none|<keyframes-name>]","single-animation-direction":"normal|reverse|alternate|alternate-reverse","single-animation-fill-mode":"none|forwards|backwards|both","single-animation-iteration-count":"infinite|<number>","single-animation-play-state":"running|paused","single-transition":"[none|<single-transition-property>]||<time>||<timing-function>||<time>","single-transition-property":"all|<custom-ident>","size":"closest-side|farthest-side|closest-corner|farthest-corner|<length>|<length-percentage>{2}","step-position":"jump-start|jump-end|jump-none|jump-both|start|end","step-timing-function":"step-start|step-end|steps( <integer> [, <step-position>]? )","subclass-selector":"<id-selector>|<class-selector>|<attribute-selector>|<pseudo-class-selector>","supports-condition":"not <supports-in-parens>|<supports-in-parens> [and <supports-in-parens>]*|<supports-in-parens> [or <supports-in-parens>]*","supports-in-parens":"( <supports-condition> )|<supports-feature>|<general-enclosed>","supports-feature":"<supports-decl>|<supports-selector-fn>","supports-decl":"( <declaration> )","supports-selector-fn":"selector( <complex-selector> )","symbol":"<string>|<image>|<custom-ident>","target":"<target-counter()>|<target-counters()>|<target-text()>","target-counter()":"target-counter( [<string>|<url>] , <custom-ident> , <counter-style>? )","target-counters()":"target-counters( [<string>|<url>] , <custom-ident> , <string> , <counter-style>? )","target-text()":"target-text( [<string>|<url>] , [content|before|after|first-letter]? )","time-percentage":"<time>|<percentage>","timing-function":"linear|<cubic-bezier-timing-function>|<step-timing-function>","track-breadth":"<length-percentage>|<flex>|min-content|max-content|auto","track-list":"[<line-names>? [<track-size>|<track-repeat>]]+ <line-names>?","track-repeat":"repeat( [<positive-integer>] , [<line-names>? <track-size>]+ <line-names>? )","track-size":"<track-breadth>|minmax( <inflexible-breadth> , <track-breadth> )|fit-content( [<length>|<percentage>] )","transform-function":"<matrix()>|<translate()>|<translateX()>|<translateY()>|<scale()>|<scaleX()>|<scaleY()>|<rotate()>|<skew()>|<skewX()>|<skewY()>|<matrix3d()>|<translate3d()>|<translateZ()>|<scale3d()>|<scaleZ()>|<rotate3d()>|<rotateX()>|<rotateY()>|<rotateZ()>|<perspective()>","transform-list":"<transform-function>+","translate()":"translate( <length-percentage> , <length-percentage>? )","translate3d()":"translate3d( <length-percentage> , <length-percentage> , <length> )","translateX()":"translateX( <length-percentage> )","translateY()":"translateY( <length-percentage> )","translateZ()":"translateZ( <length> )","type-or-unit":"string|color|url|integer|number|length|angle|time|frequency|cap|ch|em|ex|ic|lh|rlh|rem|vb|vi|vw|vh|vmin|vmax|mm|Q|cm|in|pt|pc|px|deg|grad|rad|turn|ms|s|Hz|kHz|%","type-selector":"<wq-name>|<ns-prefix>? \'*\'","var()":"var( <custom-property-name> , <declaration-value>? )","viewport-length":"auto|<length-percentage>","wq-name":"<ns-prefix>? <ident-token>","-legacy-gradient":"<-webkit-gradient()>|<-legacy-linear-gradient>|<-legacy-repeating-linear-gradient>|<-legacy-radial-gradient>|<-legacy-repeating-radial-gradient>","-legacy-linear-gradient":"-moz-linear-gradient( <-legacy-linear-gradient-arguments> )|-webkit-linear-gradient( <-legacy-linear-gradient-arguments> )|-o-linear-gradient( <-legacy-linear-gradient-arguments> )","-legacy-repeating-linear-gradient":"-moz-repeating-linear-gradient( <-legacy-linear-gradient-arguments> )|-webkit-repeating-linear-gradient( <-legacy-linear-gradient-arguments> )|-o-repeating-linear-gradient( <-legacy-linear-gradient-arguments> )","-legacy-linear-gradient-arguments":"[<angle>|<side-or-corner>]? , <color-stop-list>","-legacy-radial-gradient":"-moz-radial-gradient( <-legacy-radial-gradient-arguments> )|-webkit-radial-gradient( <-legacy-radial-gradient-arguments> )|-o-radial-gradient( <-legacy-radial-gradient-arguments> )","-legacy-repeating-radial-gradient":"-moz-repeating-radial-gradient( <-legacy-radial-gradient-arguments> )|-webkit-repeating-radial-gradient( <-legacy-radial-gradient-arguments> )|-o-repeating-radial-gradient( <-legacy-radial-gradient-arguments> )","-legacy-radial-gradient-arguments":"[<position> ,]? [[[<-legacy-radial-gradient-shape>||<-legacy-radial-gradient-size>]|[<length>|<percentage>]{2}] ,]? <color-stop-list>","-legacy-radial-gradient-size":"closest-side|closest-corner|farthest-side|farthest-corner|contain|cover","-legacy-radial-gradient-shape":"circle|ellipse","-non-standard-font":"-apple-system-body|-apple-system-headline|-apple-system-subheadline|-apple-system-caption1|-apple-system-caption2|-apple-system-footnote|-apple-system-short-body|-apple-system-short-headline|-apple-system-short-subheadline|-apple-system-short-caption1|-apple-system-short-footnote|-apple-system-tall-body","-non-standard-color":"-moz-ButtonDefault|-moz-ButtonHoverFace|-moz-ButtonHoverText|-moz-CellHighlight|-moz-CellHighlightText|-moz-Combobox|-moz-ComboboxText|-moz-Dialog|-moz-DialogText|-moz-dragtargetzone|-moz-EvenTreeRow|-moz-Field|-moz-FieldText|-moz-html-CellHighlight|-moz-html-CellHighlightText|-moz-mac-accentdarkestshadow|-moz-mac-accentdarkshadow|-moz-mac-accentface|-moz-mac-accentlightesthighlight|-moz-mac-accentlightshadow|-moz-mac-accentregularhighlight|-moz-mac-accentregularshadow|-moz-mac-chrome-active|-moz-mac-chrome-inactive|-moz-mac-focusring|-moz-mac-menuselect|-moz-mac-menushadow|-moz-mac-menutextselect|-moz-MenuHover|-moz-MenuHoverText|-moz-MenuBarText|-moz-MenuBarHoverText|-moz-nativehyperlinktext|-moz-OddTreeRow|-moz-win-communicationstext|-moz-win-mediatext|-moz-activehyperlinktext|-moz-default-background-color|-moz-default-color|-moz-hyperlinktext|-moz-visitedhyperlinktext|-webkit-activelink|-webkit-focus-ring-color|-webkit-link|-webkit-text","-non-standard-image-rendering":"optimize-contrast|-moz-crisp-edges|-o-crisp-edges|-webkit-optimize-contrast","-non-standard-overflow":"-moz-scrollbars-none|-moz-scrollbars-horizontal|-moz-scrollbars-vertical|-moz-hidden-unscrollable","-non-standard-width":"min-intrinsic|intrinsic|-moz-min-content|-moz-max-content|-webkit-min-content|-webkit-max-content","-webkit-gradient()":"-webkit-gradient( <-webkit-gradient-type> , <-webkit-gradient-point> [, <-webkit-gradient-point>|, <-webkit-gradient-radius> , <-webkit-gradient-point>] [, <-webkit-gradient-radius>]? [, <-webkit-gradient-color-stop>]* )","-webkit-gradient-color-stop":"from( <color> )|color-stop( [<number-zero-one>|<percentage>] , <color> )|to( <color> )","-webkit-gradient-point":"[left|center|right|<length-percentage>] [top|center|bottom|<length-percentage>]","-webkit-gradient-radius":"<length>|<percentage>","-webkit-gradient-type":"linear|radial","-webkit-mask-box-repeat":"repeat|stretch|round","-webkit-mask-clip-style":"border|border-box|padding|padding-box|content|content-box|text","-ms-filter-function-list":"<-ms-filter-function>+","-ms-filter-function":"<-ms-filter-function-progid>|<-ms-filter-function-legacy>","-ms-filter-function-progid":"\'progid:\' [<ident-token> \'.\']* [<ident-token>|<function-token> <any-value>? )]","-ms-filter-function-legacy":"<ident-token>|<function-token> <any-value>? )","-ms-filter":"<string>","age":"child|young|old","attr-name":"<wq-name>","attr-fallback":"<any-value>","border-radius":"<length-percentage>{1,2}","bottom":"<length>|auto","generic-voice":"[<age>? <gender> <integer>?]","gender":"male|female|neutral","left":"<length>|auto","mask-image":"<mask-reference>#","name-repeat":"repeat( [<positive-integer>|auto-fill] , <line-names>+ )","paint":"none|<color>|<url> [none|<color>]?|context-fill|context-stroke","path()":"path( <string> )","ratio":"<integer> / <integer>","right":"<length>|auto","svg-length":"<percentage>|<length>|<number>","svg-writing-mode":"lr-tb|rl-tb|tb-rl|lr|rl|tb","top":"<length>|auto","track-group":"\'(\' [<string>* <track-minmax> <string>*]+ \')\' [\'[\' <positive-integer> \']\']?|<track-minmax>","track-list-v0":"[<string>* <track-group> <string>*]+|none","track-minmax":"minmax( <track-breadth> , <track-breadth> )|auto|<track-breadth>|fit-content","x":"<number>","y":"<number>","declaration":"<ident-token> : <declaration-value>? [\'!\' important]?","declaration-list":"[<declaration>? \';\']* <declaration>?","url":"url( <string> <url-modifier>* )|<url-token>","url-modifier":"<ident>|<function-token> <any-value> )","number-zero-one":"<number [0,1]>","number-one-or-greater":"<number [1,\u221e]>","positive-integer":"<integer [0,\u221e]>"},"properties":{"--*":"<declaration-value>","-ms-accelerator":"false|true","-ms-block-progression":"tb|rl|bt|lr","-ms-content-zoom-chaining":"none|chained","-ms-content-zooming":"none|zoom","-ms-content-zoom-limit":"<\'-ms-content-zoom-limit-min\'> <\'-ms-content-zoom-limit-max\'>","-ms-content-zoom-limit-max":"<percentage>","-ms-content-zoom-limit-min":"<percentage>","-ms-content-zoom-snap":"<\'-ms-content-zoom-snap-type\'>||<\'-ms-content-zoom-snap-points\'>","-ms-content-zoom-snap-points":"snapInterval( <percentage> , <percentage> )|snapList( <percentage># )","-ms-content-zoom-snap-type":"none|proximity|mandatory","-ms-filter":"<string>","-ms-flow-from":"[none|<custom-ident>]#","-ms-flow-into":"[none|<custom-ident>]#","-ms-high-contrast-adjust":"auto|none","-ms-hyphenate-limit-chars":"auto|<integer>{1,3}","-ms-hyphenate-limit-lines":"no-limit|<integer>","-ms-hyphenate-limit-zone":"<percentage>|<length>","-ms-ime-align":"auto|after","-ms-overflow-style":"auto|none|scrollbar|-ms-autohiding-scrollbar","-ms-scrollbar-3dlight-color":"<color>","-ms-scrollbar-arrow-color":"<color>","-ms-scrollbar-base-color":"<color>","-ms-scrollbar-darkshadow-color":"<color>","-ms-scrollbar-face-color":"<color>","-ms-scrollbar-highlight-color":"<color>","-ms-scrollbar-shadow-color":"<color>","-ms-scrollbar-track-color":"<color>","-ms-scroll-chaining":"chained|none","-ms-scroll-limit":"<\'-ms-scroll-limit-x-min\'> <\'-ms-scroll-limit-y-min\'> <\'-ms-scroll-limit-x-max\'> <\'-ms-scroll-limit-y-max\'>","-ms-scroll-limit-x-max":"auto|<length>","-ms-scroll-limit-x-min":"<length>","-ms-scroll-limit-y-max":"auto|<length>","-ms-scroll-limit-y-min":"<length>","-ms-scroll-rails":"none|railed","-ms-scroll-snap-points-x":"snapInterval( <length-percentage> , <length-percentage> )|snapList( <length-percentage># )","-ms-scroll-snap-points-y":"snapInterval( <length-percentage> , <length-percentage> )|snapList( <length-percentage># )","-ms-scroll-snap-type":"none|proximity|mandatory","-ms-scroll-snap-x":"<\'-ms-scroll-snap-type\'> <\'-ms-scroll-snap-points-x\'>","-ms-scroll-snap-y":"<\'-ms-scroll-snap-type\'> <\'-ms-scroll-snap-points-y\'>","-ms-scroll-translation":"none|vertical-to-horizontal","-ms-text-autospace":"none|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space","-ms-touch-select":"grippers|none","-ms-user-select":"none|element|text","-ms-wrap-flow":"auto|both|start|end|maximum|clear","-ms-wrap-margin":"<length>","-ms-wrap-through":"wrap|none","-moz-appearance":"none|button|button-arrow-down|button-arrow-next|button-arrow-previous|button-arrow-up|button-bevel|button-focus|caret|checkbox|checkbox-container|checkbox-label|checkmenuitem|dualbutton|groupbox|listbox|listitem|menuarrow|menubar|menucheckbox|menuimage|menuitem|menuitemtext|menulist|menulist-button|menulist-text|menulist-textfield|menupopup|menuradio|menuseparator|meterbar|meterchunk|progressbar|progressbar-vertical|progresschunk|progresschunk-vertical|radio|radio-container|radio-label|radiomenuitem|range|range-thumb|resizer|resizerpanel|scale-horizontal|scalethumbend|scalethumb-horizontal|scalethumbstart|scalethumbtick|scalethumb-vertical|scale-vertical|scrollbarbutton-down|scrollbarbutton-left|scrollbarbutton-right|scrollbarbutton-up|scrollbarthumb-horizontal|scrollbarthumb-vertical|scrollbartrack-horizontal|scrollbartrack-vertical|searchfield|separator|sheet|spinner|spinner-downbutton|spinner-textfield|spinner-upbutton|splitter|statusbar|statusbarpanel|tab|tabpanel|tabpanels|tab-scroll-arrow-back|tab-scroll-arrow-forward|textfield|textfield-multiline|toolbar|toolbarbutton|toolbarbutton-dropdown|toolbargripper|toolbox|tooltip|treeheader|treeheadercell|treeheadersortarrow|treeitem|treeline|treetwisty|treetwistyopen|treeview|-moz-mac-unified-toolbar|-moz-win-borderless-glass|-moz-win-browsertabbar-toolbox|-moz-win-communicationstext|-moz-win-communications-toolbox|-moz-win-exclude-glass|-moz-win-glass|-moz-win-mediatext|-moz-win-media-toolbox|-moz-window-button-box|-moz-window-button-box-maximized|-moz-window-button-close|-moz-window-button-maximize|-moz-window-button-minimize|-moz-window-button-restore|-moz-window-frame-bottom|-moz-window-frame-left|-moz-window-frame-right|-moz-window-titlebar|-moz-window-titlebar-maximized","-moz-binding":"<url>|none","-moz-border-bottom-colors":"<color>+|none","-moz-border-left-colors":"<color>+|none","-moz-border-right-colors":"<color>+|none","-moz-border-top-colors":"<color>+|none","-moz-context-properties":"none|[fill|fill-opacity|stroke|stroke-opacity]#","-moz-float-edge":"border-box|content-box|margin-box|padding-box","-moz-force-broken-image-icon":"<integer>","-moz-image-region":"<shape>|auto","-moz-orient":"inline|block|horizontal|vertical","-moz-outline-radius":"<outline-radius>{1,4} [/ <outline-radius>{1,4}]?","-moz-outline-radius-bottomleft":"<outline-radius>","-moz-outline-radius-bottomright":"<outline-radius>","-moz-outline-radius-topleft":"<outline-radius>","-moz-outline-radius-topright":"<outline-radius>","-moz-stack-sizing":"ignore|stretch-to-fit","-moz-text-blink":"none|blink","-moz-user-focus":"ignore|normal|select-after|select-before|select-menu|select-same|select-all|none","-moz-user-input":"auto|none|enabled|disabled","-moz-user-modify":"read-only|read-write|write-only","-moz-window-dragging":"drag|no-drag","-moz-window-shadow":"default|menu|tooltip|sheet|none","-webkit-appearance":"none|button|button-bevel|caps-lock-indicator|caret|checkbox|default-button|listbox|listitem|media-fullscreen-button|media-mute-button|media-play-button|media-seek-back-button|media-seek-forward-button|media-slider|media-sliderthumb|menulist|menulist-button|menulist-text|menulist-textfield|push-button|radio|scrollbarbutton-down|scrollbarbutton-left|scrollbarbutton-right|scrollbarbutton-up|scrollbargripper-horizontal|scrollbargripper-vertical|scrollbarthumb-horizontal|scrollbarthumb-vertical|scrollbartrack-horizontal|scrollbartrack-vertical|searchfield|searchfield-cancel-button|searchfield-decoration|searchfield-results-button|searchfield-results-decoration|slider-horizontal|slider-vertical|sliderthumb-horizontal|sliderthumb-vertical|square-button|textarea|textfield","-webkit-border-before":"<\'border-width\'>||<\'border-style\'>||<\'color\'>","-webkit-border-before-color":"<\'color\'>","-webkit-border-before-style":"<\'border-style\'>","-webkit-border-before-width":"<\'border-width\'>","-webkit-box-reflect":"[above|below|right|left]? <length>? <image>?","-webkit-line-clamp":"none|<integer>","-webkit-mask":"[<mask-reference>||<position> [/ <bg-size>]?||<repeat-style>||[<box>|border|padding|content|text]||[<box>|border|padding|content]]#","-webkit-mask-attachment":"<attachment>#","-webkit-mask-clip":"[<box>|border|padding|content|text]#","-webkit-mask-composite":"<composite-style>#","-webkit-mask-image":"<mask-reference>#","-webkit-mask-origin":"[<box>|border|padding|content]#","-webkit-mask-position":"<position>#","-webkit-mask-position-x":"[<length-percentage>|left|center|right]#","-webkit-mask-position-y":"[<length-percentage>|top|center|bottom]#","-webkit-mask-repeat":"<repeat-style>#","-webkit-mask-repeat-x":"repeat|no-repeat|space|round","-webkit-mask-repeat-y":"repeat|no-repeat|space|round","-webkit-mask-size":"<bg-size>#","-webkit-overflow-scrolling":"auto|touch","-webkit-tap-highlight-color":"<color>","-webkit-text-fill-color":"<color>","-webkit-text-stroke":"<length>||<color>","-webkit-text-stroke-color":"<color>","-webkit-text-stroke-width":"<length>","-webkit-touch-callout":"default|none","-webkit-user-modify":"read-only|read-write|read-write-plaintext-only","align-content":"normal|<baseline-position>|<content-distribution>|<overflow-position>? <content-position>","align-items":"normal|stretch|<baseline-position>|[<overflow-position>? <self-position>]","align-self":"auto|normal|stretch|<baseline-position>|<overflow-position>? <self-position>","all":"initial|inherit|unset|revert","animation":"<single-animation>#","animation-delay":"<time>#","animation-direction":"<single-animation-direction>#","animation-duration":"<time>#","animation-fill-mode":"<single-animation-fill-mode>#","animation-iteration-count":"<single-animation-iteration-count>#","animation-name":"[none|<keyframes-name>]#","animation-play-state":"<single-animation-play-state>#","animation-timing-function":"<timing-function>#","appearance":"none|auto|button|textfield|<compat>","azimuth":"<angle>|[[left-side|far-left|left|center-left|center|center-right|right|far-right|right-side]||behind]|leftwards|rightwards","backdrop-filter":"none|<filter-function-list>","backface-visibility":"visible|hidden","background":"[<bg-layer> ,]* <final-bg-layer>","background-attachment":"<attachment>#","background-blend-mode":"<blend-mode>#","background-clip":"<box>#","background-color":"<color>","background-image":"<bg-image>#","background-origin":"<box>#","background-position":"<bg-position>#","background-position-x":"[center|[left|right|x-start|x-end]? <length-percentage>?]#","background-position-y":"[center|[top|bottom|y-start|y-end]? <length-percentage>?]#","background-repeat":"<repeat-style>#","background-size":"<bg-size>#","block-overflow":"clip|ellipsis|<string>","block-size":"<\'width\'>","border":"<line-width>||<line-style>||<color>","border-block":"<\'border-top-width\'>||<\'border-top-style\'>||<\'color\'>","border-block-color":"<\'border-top-color\'>{1,2}","border-block-style":"<\'border-top-style\'>","border-block-width":"<\'border-top-width\'>","border-block-end":"<\'border-top-width\'>||<\'border-top-style\'>||<\'color\'>","border-block-end-color":"<\'border-top-color\'>","border-block-end-style":"<\'border-top-style\'>","border-block-end-width":"<\'border-top-width\'>","border-block-start":"<\'border-top-width\'>||<\'border-top-style\'>||<\'color\'>","border-block-start-color":"<\'border-top-color\'>","border-block-start-style":"<\'border-top-style\'>","border-block-start-width":"<\'border-top-width\'>","border-bottom":"<line-width>||<line-style>||<color>","border-bottom-color":"<\'border-top-color\'>","border-bottom-left-radius":"<length-percentage>{1,2}","border-bottom-right-radius":"<length-percentage>{1,2}","border-bottom-style":"<line-style>","border-bottom-width":"<line-width>","border-collapse":"collapse|separate","border-color":"<color>{1,4}","border-end-end-radius":"<length-percentage>{1,2}","border-end-start-radius":"<length-percentage>{1,2}","border-image":"<\'border-image-source\'>||<\'border-image-slice\'> [/ <\'border-image-width\'>|/ <\'border-image-width\'>? / <\'border-image-outset\'>]?||<\'border-image-repeat\'>","border-image-outset":"[<length>|<number>]{1,4}","border-image-repeat":"[stretch|repeat|round|space]{1,2}","border-image-slice":"<number-percentage>{1,4}&&fill?","border-image-source":"none|<image>","border-image-width":"[<length-percentage>|<number>|auto]{1,4}","border-inline":"<\'border-top-width\'>||<\'border-top-style\'>||<\'color\'>","border-inline-end":"<\'border-top-width\'>||<\'border-top-style\'>||<\'color\'>","border-inline-color":"<\'border-top-color\'>{1,2}","border-inline-style":"<\'border-top-style\'>","border-inline-width":"<\'border-top-width\'>","border-inline-end-color":"<\'border-top-color\'>","border-inline-end-style":"<\'border-top-style\'>","border-inline-end-width":"<\'border-top-width\'>","border-inline-start":"<\'border-top-width\'>||<\'border-top-style\'>||<\'color\'>","border-inline-start-color":"<\'border-top-color\'>","border-inline-start-style":"<\'border-top-style\'>","border-inline-start-width":"<\'border-top-width\'>","border-left":"<line-width>||<line-style>||<color>","border-left-color":"<color>","border-left-style":"<line-style>","border-left-width":"<line-width>","border-radius":"<length-percentage>{1,4} [/ <length-percentage>{1,4}]?","border-right":"<line-width>||<line-style>||<color>","border-right-color":"<color>","border-right-style":"<line-style>","border-right-width":"<line-width>","border-spacing":"<length> <length>?","border-start-end-radius":"<length-percentage>{1,2}","border-start-start-radius":"<length-percentage>{1,2}","border-style":"<line-style>{1,4}","border-top":"<line-width>||<line-style>||<color>","border-top-color":"<color>","border-top-left-radius":"<length-percentage>{1,2}","border-top-right-radius":"<length-percentage>{1,2}","border-top-style":"<line-style>","border-top-width":"<line-width>","border-width":"<line-width>{1,4}","bottom":"<length>|<percentage>|auto","box-align":"start|center|end|baseline|stretch","box-decoration-break":"slice|clone","box-direction":"normal|reverse|inherit","box-flex":"<number>","box-flex-group":"<integer>","box-lines":"single|multiple","box-ordinal-group":"<integer>","box-orient":"horizontal|vertical|inline-axis|block-axis|inherit","box-pack":"start|center|end|justify","box-shadow":"none|<shadow>#","box-sizing":"content-box|border-box","break-after":"auto|avoid|always|all|avoid-page|page|left|right|recto|verso|avoid-column|column|avoid-region|region","break-before":"auto|avoid|always|all|avoid-page|page|left|right|recto|verso|avoid-column|column|avoid-region|region","break-inside":"auto|avoid|avoid-page|avoid-column|avoid-region","caption-side":"top|bottom|block-start|block-end|inline-start|inline-end","caret-color":"auto|<color>","clear":"none|left|right|both|inline-start|inline-end","clip":"<shape>|auto","clip-path":"<clip-source>|[<basic-shape>||<geometry-box>]|none","color":"<color>","color-adjust":"economy|exact","column-count":"<integer>|auto","column-fill":"auto|balance|balance-all","column-gap":"normal|<length-percentage>","column-rule":"<\'column-rule-width\'>||<\'column-rule-style\'>||<\'column-rule-color\'>","column-rule-color":"<color>","column-rule-style":"<\'border-style\'>","column-rule-width":"<\'border-width\'>","column-span":"none|all","column-width":"<length>|auto","columns":"<\'column-width\'>||<\'column-count\'>","contain":"none|strict|content|[size||layout||style||paint]","content":"normal|none|[<content-replacement>|<content-list>] [/ <string>]?","counter-increment":"[<custom-ident> <integer>?]+|none","counter-reset":"[<custom-ident> <integer>?]+|none","counter-set":"[<custom-ident> <integer>?]+|none","cursor":"[[<url> [<x> <y>]? ,]* [auto|default|none|context-menu|help|pointer|progress|wait|cell|crosshair|text|vertical-text|alias|copy|move|no-drop|not-allowed|e-resize|n-resize|ne-resize|nw-resize|s-resize|se-resize|sw-resize|w-resize|ew-resize|ns-resize|nesw-resize|nwse-resize|col-resize|row-resize|all-scroll|zoom-in|zoom-out|grab|grabbing|hand|-webkit-grab|-webkit-grabbing|-webkit-zoom-in|-webkit-zoom-out|-moz-grab|-moz-grabbing|-moz-zoom-in|-moz-zoom-out]]","direction":"ltr|rtl","display":"block|contents|flex|flow|flow-root|grid|inline|inline-block|inline-flex|inline-grid|inline-list-item|inline-table|list-item|none|ruby|ruby-base|ruby-base-container|ruby-text|ruby-text-container|run-in|table|table-caption|table-cell|table-column|table-column-group|table-footer-group|table-header-group|table-row|table-row-group|-ms-flexbox|-ms-inline-flexbox|-ms-grid|-ms-inline-grid|-webkit-flex|-webkit-inline-flex|-webkit-box|-webkit-inline-box|-moz-inline-stack|-moz-box|-moz-inline-box","empty-cells":"show|hide","filter":"none|<filter-function-list>|<-ms-filter-function-list>","flex":"none|[<\'flex-grow\'> <\'flex-shrink\'>?||<\'flex-basis\'>]","flex-basis":"content|<\'width\'>","flex-direction":"row|row-reverse|column|column-reverse","flex-flow":"<\'flex-direction\'>||<\'flex-wrap\'>","flex-grow":"<number>","flex-shrink":"<number>","flex-wrap":"nowrap|wrap|wrap-reverse","float":"left|right|none|inline-start|inline-end","font":"[[<\'font-style\'>||<font-variant-css21>||<\'font-weight\'>||<\'font-stretch\'>]? <\'font-size\'> [/ <\'line-height\'>]? <\'font-family\'>]|caption|icon|menu|message-box|small-caption|status-bar","font-family":"[<family-name>|<generic-family>]#","font-feature-settings":"normal|<feature-tag-value>#","font-kerning":"auto|normal|none","font-language-override":"normal|<string>","font-optical-sizing":"auto|none","font-variation-settings":"normal|[<string> <number>]#","font-size":"<absolute-size>|<relative-size>|<length-percentage>","font-size-adjust":"none|<number>","font-stretch":"<font-stretch-absolute>","font-style":"normal|italic|oblique <angle>?","font-synthesis":"none|[weight||style]","font-variant":"normal|none|[<common-lig-values>||<discretionary-lig-values>||<historical-lig-values>||<contextual-alt-values>||stylistic( <feature-value-name> )||historical-forms||styleset( <feature-value-name># )||character-variant( <feature-value-name># )||swash( <feature-value-name> )||ornaments( <feature-value-name> )||annotation( <feature-value-name> )||[small-caps|all-small-caps|petite-caps|all-petite-caps|unicase|titling-caps]||<numeric-figure-values>||<numeric-spacing-values>||<numeric-fraction-values>||ordinal||slashed-zero||<east-asian-variant-values>||<east-asian-width-values>||ruby]","font-variant-alternates":"normal|[stylistic( <feature-value-name> )||historical-forms||styleset( <feature-value-name># )||character-variant( <feature-value-name># )||swash( <feature-value-name> )||ornaments( <feature-value-name> )||annotation( <feature-value-name> )]","font-variant-caps":"normal|small-caps|all-small-caps|petite-caps|all-petite-caps|unicase|titling-caps","font-variant-east-asian":"normal|[<east-asian-variant-values>||<east-asian-width-values>||ruby]","font-variant-ligatures":"normal|none|[<common-lig-values>||<discretionary-lig-values>||<historical-lig-values>||<contextual-alt-values>]","font-variant-numeric":"normal|[<numeric-figure-values>||<numeric-spacing-values>||<numeric-fraction-values>||ordinal||slashed-zero]","font-variant-position":"normal|sub|super","font-weight":"<font-weight-absolute>|bolder|lighter","gap":"<\'row-gap\'> <\'column-gap\'>?","grid":"<\'grid-template\'>|<\'grid-template-rows\'> / [auto-flow&&dense?] <\'grid-auto-columns\'>?|[auto-flow&&dense?] <\'grid-auto-rows\'>? / <\'grid-template-columns\'>","grid-area":"<grid-line> [/ <grid-line>]{0,3}","grid-auto-columns":"<track-size>+","grid-auto-flow":"[row|column]||dense","grid-auto-rows":"<track-size>+","grid-column":"<grid-line> [/ <grid-line>]?","grid-column-end":"<grid-line>","grid-column-gap":"<length-percentage>","grid-column-start":"<grid-line>","grid-gap":"<\'grid-row-gap\'> <\'grid-column-gap\'>?","grid-row":"<grid-line> [/ <grid-line>]?","grid-row-end":"<grid-line>","grid-row-gap":"<length-percentage>","grid-row-start":"<grid-line>","grid-template":"none|[<\'grid-template-rows\'> / <\'grid-template-columns\'>]|[<line-names>? <string> <track-size>? <line-names>?]+ [/ <explicit-track-list>]?","grid-template-areas":"none|<string>+","grid-template-columns":"none|<track-list>|<auto-track-list>","grid-template-rows":"none|<track-list>|<auto-track-list>","hanging-punctuation":"none|[first||[force-end|allow-end]||last]","height":"[<length>|<percentage>]&&[border-box|content-box]?|available|min-content|max-content|fit-content|auto","hyphens":"none|manual|auto","image-orientation":"from-image|<angle>|[<angle>? flip]","image-rendering":"auto|crisp-edges|pixelated|optimizeSpeed|optimizeQuality|<-non-standard-image-rendering>","image-resolution":"[from-image||<resolution>]&&snap?","ime-mode":"auto|normal|active|inactive|disabled","initial-letter":"normal|[<number> <integer>?]","initial-letter-align":"[auto|alphabetic|hanging|ideographic]","inline-size":"<\'width\'>","inset":"<\'top\'>{1,4}","inset-block":"<\'top\'>{1,2}","inset-block-end":"<\'top\'>","inset-block-start":"<\'top\'>","inset-inline":"<\'top\'>{1,2}","inset-inline-end":"<\'top\'>","inset-inline-start":"<\'top\'>","isolation":"auto|isolate","justify-content":"normal|<content-distribution>|<overflow-position>? [<content-position>|left|right]","justify-items":"normal|stretch|<baseline-position>|<overflow-position>? [<self-position>|left|right]|legacy|legacy&&[left|right|center]","justify-self":"auto|normal|stretch|<baseline-position>|<overflow-position>? [<self-position>|left|right]","left":"<length>|<percentage>|auto","letter-spacing":"normal|<length-percentage>","line-break":"auto|loose|normal|strict","line-clamp":"none|<integer>","line-height":"normal|<number>|<length>|<percentage>","line-height-step":"<length>","list-style":"<\'list-style-type\'>||<\'list-style-position\'>||<\'list-style-image\'>","list-style-image":"<url>|none","list-style-position":"inside|outside","list-style-type":"<counter-style>|<string>|none","margin":"[<length>|<percentage>|auto]{1,4}","margin-block":"<\'margin-left\'>{1,2}","margin-block-end":"<\'margin-left\'>","margin-block-start":"<\'margin-left\'>","margin-bottom":"<length>|<percentage>|auto","margin-inline":"<\'margin-left\'>{1,2}","margin-inline-end":"<\'margin-left\'>","margin-inline-start":"<\'margin-left\'>","margin-left":"<length>|<percentage>|auto","margin-right":"<length>|<percentage>|auto","margin-top":"<length>|<percentage>|auto","mask":"<mask-layer>#","mask-border":"<\'mask-border-source\'>||<\'mask-border-slice\'> [/ <\'mask-border-width\'>? [/ <\'mask-border-outset\'>]?]?||<\'mask-border-repeat\'>||<\'mask-border-mode\'>","mask-border-mode":"luminance|alpha","mask-border-outset":"[<length>|<number>]{1,4}","mask-border-repeat":"[stretch|repeat|round|space]{1,2}","mask-border-slice":"<number-percentage>{1,4} fill?","mask-border-source":"none|<image>","mask-border-width":"[<length-percentage>|<number>|auto]{1,4}","mask-clip":"[<geometry-box>|no-clip]#","mask-composite":"<compositing-operator>#","mask-image":"<mask-reference>#","mask-mode":"<masking-mode>#","mask-origin":"<geometry-box>#","mask-position":"<position>#","mask-repeat":"<repeat-style>#","mask-size":"<bg-size>#","mask-type":"luminance|alpha","max-block-size":"<\'max-width\'>","max-height":"<length>|<percentage>|none|max-content|min-content|fit-content|fill-available","max-inline-size":"<\'max-width\'>","max-lines":"none|<integer>","max-width":"<length>|<percentage>|none|max-content|min-content|fit-content|fill-available|<-non-standard-width>","min-block-size":"<\'min-width\'>","min-height":"<length>|<percentage>|auto|max-content|min-content|fit-content|fill-available","min-inline-size":"<\'min-width\'>","min-width":"<length>|<percentage>|auto|max-content|min-content|fit-content|fill-available|<-non-standard-width>","mix-blend-mode":"<blend-mode>","object-fit":"fill|contain|cover|none|scale-down","object-position":"<position>","offset":"[<\'offset-position\'>? [<\'offset-path\'> [<\'offset-distance\'>||<\'offset-rotate\'>]?]?]! [/ <\'offset-anchor\'>]?","offset-anchor":"auto|<position>","offset-distance":"<length-percentage>","offset-path":"none|ray( [<angle>&&<size>?&&contain?] )|<path()>|<url>|[<basic-shape>||<geometry-box>]","offset-position":"auto|<position>","offset-rotate":"[auto|reverse]||<angle>","opacity":"<number-zero-one>","order":"<integer>","orphans":"<integer>","outline":"[<\'outline-color\'>||<\'outline-style\'>||<\'outline-width\'>]","outline-color":"<color>|invert","outline-offset":"<length>","outline-style":"auto|<\'border-style\'>","outline-width":"<line-width>","overflow":"[visible|hidden|clip|scroll|auto]{1,2}|<-non-standard-overflow>","overflow-anchor":"auto|none","overflow-block":"visible|hidden|clip|scroll|auto","overflow-clip-box":"padding-box|content-box","overflow-inline":"visible|hidden|clip|scroll|auto","overflow-wrap":"normal|break-word|anywhere","overflow-x":"visible|hidden|clip|scroll|auto","overflow-y":"visible|hidden|clip|scroll|auto","overscroll-behavior":"[contain|none|auto]{1,2}","overscroll-behavior-x":"contain|none|auto","overscroll-behavior-y":"contain|none|auto","padding":"[<length>|<percentage>]{1,4}","padding-block":"<\'padding-left\'>{1,2}","padding-block-end":"<\'padding-left\'>","padding-block-start":"<\'padding-left\'>","padding-bottom":"<length>|<percentage>","padding-inline":"<\'padding-left\'>{1,2}","padding-inline-end":"<\'padding-left\'>","padding-inline-start":"<\'padding-left\'>","padding-left":"<length>|<percentage>","padding-right":"<length>|<percentage>","padding-top":"<length>|<percentage>","page-break-after":"auto|always|avoid|left|right|recto|verso","page-break-before":"auto|always|avoid|left|right|recto|verso","page-break-inside":"auto|avoid","paint-order":"normal|[fill||stroke||markers]","perspective":"none|<length>","perspective-origin":"<position>","place-content":"<\'align-content\'> <\'justify-content\'>?","place-items":"<\'align-items\'> <\'justify-items\'>?","place-self":"<\'align-self\'> <\'justify-self\'>?","pointer-events":"auto|none|visiblePainted|visibleFill|visibleStroke|visible|painted|fill|stroke|all|inherit","position":"static|relative|absolute|sticky|fixed|-webkit-sticky","quotes":"none|[<string> <string>]+","resize":"none|both|horizontal|vertical|block|inline","right":"<length>|<percentage>|auto","rotate":"none|<angle>|[x|y|z|<number>{3}]&&<angle>","row-gap":"normal|<length-percentage>","ruby-align":"start|center|space-between|space-around","ruby-merge":"separate|collapse|auto","ruby-position":"over|under|inter-character","scale":"none|<number>{1,3}","scrollbar-color":"auto|dark|light|<color>{2}","scrollbar-width":"auto|thin|none","scroll-behavior":"auto|smooth","scroll-margin":"<length>{1,4}","scroll-margin-block":"<length>{1,2}","scroll-margin-block-start":"<length>","scroll-margin-block-end":"<length>","scroll-margin-bottom":"<length>","scroll-margin-inline":"<length>{1,2}","scroll-margin-inline-start":"<length>","scroll-margin-inline-end":"<length>","scroll-margin-left":"<length>","scroll-margin-right":"<length>","scroll-margin-top":"<length>","scroll-padding":"[auto|<length-percentage>]{1,4}","scroll-padding-block":"[auto|<length-percentage>]{1,2}","scroll-padding-block-start":"auto|<length-percentage>","scroll-padding-block-end":"auto|<length-percentage>","scroll-padding-bottom":"auto|<length-percentage>","scroll-padding-inline":"[auto|<length-percentage>]{1,2}","scroll-padding-inline-start":"auto|<length-percentage>","scroll-padding-inline-end":"auto|<length-percentage>","scroll-padding-left":"auto|<length-percentage>","scroll-padding-right":"auto|<length-percentage>","scroll-padding-top":"auto|<length-percentage>","scroll-snap-align":"[none|start|end|center]{1,2}","scroll-snap-coordinate":"none|<position>#","scroll-snap-destination":"<position>","scroll-snap-points-x":"none|repeat( <length-percentage> )","scroll-snap-points-y":"none|repeat( <length-percentage> )","scroll-snap-stop":"normal|always","scroll-snap-type":"none|[x|y|block|inline|both] [mandatory|proximity]?","scroll-snap-type-x":"none|mandatory|proximity","scroll-snap-type-y":"none|mandatory|proximity","shape-image-threshold":"<number>","shape-margin":"<length-percentage>","shape-outside":"none|<shape-box>||<basic-shape>|<image>","tab-size":"<integer>|<length>","table-layout":"auto|fixed","text-align":"start|end|left|right|center|justify|match-parent","text-align-last":"auto|start|end|left|right|center|justify","text-combine-upright":"none|all|[digits <integer>?]","text-decoration":"<\'text-decoration-line\'>||<\'text-decoration-style\'>||<\'text-decoration-color\'>","text-decoration-color":"<color>","text-decoration-line":"none|[underline||overline||line-through||blink]","text-decoration-skip":"none|[objects||[spaces|[leading-spaces||trailing-spaces]]||edges||box-decoration]","text-decoration-skip-ink":"auto|none","text-decoration-style":"solid|double|dotted|dashed|wavy","text-emphasis":"<\'text-emphasis-style\'>||<\'text-emphasis-color\'>","text-emphasis-color":"<color>","text-emphasis-position":"[over|under]&&[right|left]","text-emphasis-style":"none|[[filled|open]||[dot|circle|double-circle|triangle|sesame]]|<string>","text-indent":"<length-percentage>&&hanging?&&each-line?","text-justify":"auto|inter-character|inter-word|none","text-orientation":"mixed|upright|sideways","text-overflow":"[clip|ellipsis|<string>]{1,2}","text-rendering":"auto|optimizeSpeed|optimizeLegibility|geometricPrecision","text-shadow":"none|<shadow-t>#","text-size-adjust":"none|auto|<percentage>","text-transform":"none|capitalize|uppercase|lowercase|full-width|full-size-kana","text-underline-position":"auto|[under||[left|right]]","top":"<length>|<percentage>|auto","touch-action":"auto|none|[[pan-x|pan-left|pan-right]||[pan-y|pan-up|pan-down]||pinch-zoom]|manipulation","transform":"none|<transform-list>","transform-box":"border-box|fill-box|view-box","transform-origin":"[<length-percentage>|left|center|right|top|bottom]|[[<length-percentage>|left|center|right]&&[<length-percentage>|top|center|bottom]] <length>?","transform-style":"flat|preserve-3d","transition":"<single-transition>#","transition-delay":"<time>#","transition-duration":"<time>#","transition-property":"none|<single-transition-property>#","transition-timing-function":"<timing-function>#","translate":"none|<length-percentage> [<length-percentage> <length>?]?","unicode-bidi":"normal|embed|isolate|bidi-override|isolate-override|plaintext|-moz-isolate|-moz-isolate-override|-moz-plaintext|-webkit-isolate","user-select":"auto|text|none|contain|all","vertical-align":"baseline|sub|super|text-top|text-bottom|middle|top|bottom|<percentage>|<length>","visibility":"visible|hidden|collapse","white-space":"normal|pre|nowrap|pre-wrap|pre-line","widows":"<integer>","width":"[<length>|<percentage>]&&[border-box|content-box]?|available|min-content|max-content|fit-content|auto","will-change":"auto|<animateable-feature>#","word-break":"normal|break-all|keep-all|break-word","word-spacing":"normal|<length-percentage>","word-wrap":"normal|break-word","writing-mode":"horizontal-tb|vertical-rl|vertical-lr|sideways-rl|sideways-lr|<svg-writing-mode>","z-index":"auto|<integer>","zoom":"normal|reset|<number>|<percentage>","-moz-background-clip":"padding|border","-moz-border-radius-bottomleft":"<\'border-bottom-left-radius\'>","-moz-border-radius-bottomright":"<\'border-bottom-right-radius\'>","-moz-border-radius-topleft":"<\'border-top-left-radius\'>","-moz-border-radius-topright":"<\'border-bottom-right-radius\'>","-moz-control-character-visibility":"visible|hidden","-moz-osx-font-smoothing":"auto|grayscale","-moz-user-select":"none|text|all|-moz-none","-ms-flex-align":"start|end|center|baseline|stretch","-ms-flex-item-align":"auto|start|end|center|baseline|stretch","-ms-flex-line-pack":"start|end|center|justify|distribute|stretch","-ms-flex-negative":"<\'flex-shrink\'>","-ms-flex-pack":"start|end|center|justify|distribute","-ms-flex-order":"<integer>","-ms-flex-positive":"<\'flex-grow\'>","-ms-flex-preferred-size":"<\'flex-basis\'>","-ms-interpolation-mode":"nearest-neighbor|bicubic","-ms-grid-column-align":"start|end|center|stretch","-ms-grid-columns":"<track-list-v0>","-ms-grid-row-align":"start|end|center|stretch","-ms-grid-rows":"<track-list-v0>","-ms-hyphenate-limit-last":"none|always|column|page|spread","-webkit-background-clip":"[<box>|border|padding|content|text]#","-webkit-column-break-after":"always|auto|avoid","-webkit-column-break-before":"always|auto|avoid","-webkit-column-break-inside":"always|auto|avoid","-webkit-font-smoothing":"auto|none|antialiased|subpixel-antialiased","-webkit-mask-box-image":"[<url>|<gradient>|none] [<length-percentage>{4} <-webkit-mask-box-repeat>{2}]?","-webkit-print-color-adjust":"economy|exact","-webkit-text-security":"none|circle|disc|square","-webkit-user-drag":"none|element|auto","-webkit-user-select":"auto|none|text|all","alignment-baseline":"auto|baseline|before-edge|text-before-edge|middle|central|after-edge|text-after-edge|ideographic|alphabetic|hanging|mathematical","baseline-shift":"baseline|sub|super|<svg-length>","behavior":"<url>+","clip-rule":"nonzero|evenodd","cue":"<\'cue-before\'> <\'cue-after\'>?","cue-after":"<url> <decibel>?|none","cue-before":"<url> <decibel>?|none","dominant-baseline":"auto|use-script|no-change|reset-size|ideographic|alphabetic|hanging|mathematical|central|middle|text-after-edge|text-before-edge","fill":"<paint>","fill-opacity":"<number-zero-one>","fill-rule":"nonzero|evenodd","glyph-orientation-horizontal":"<angle>","glyph-orientation-vertical":"<angle>","kerning":"auto|<svg-length>","marker":"none|<url>","marker-end":"none|<url>","marker-mid":"none|<url>","marker-start":"none|<url>","pause":"<\'pause-before\'> <\'pause-after\'>?","pause-after":"<time>|none|x-weak|weak|medium|strong|x-strong","pause-before":"<time>|none|x-weak|weak|medium|strong|x-strong","rest":"<\'rest-before\'> <\'rest-after\'>?","rest-after":"<time>|none|x-weak|weak|medium|strong|x-strong","rest-before":"<time>|none|x-weak|weak|medium|strong|x-strong","shape-rendering":"auto|optimizeSpeed|crispEdges|geometricPrecision","src":"[<url> [format( <string># )]?|local( <family-name> )]#","speak":"auto|none|normal","speak-as":"normal|spell-out||digits||[literal-punctuation|no-punctuation]","stroke":"<paint>","stroke-dasharray":"none|[<svg-length>+]#","stroke-dashoffset":"<svg-length>","stroke-linecap":"butt|round|square","stroke-linejoin":"miter|round|bevel","stroke-miterlimit":"<number-one-or-greater>","stroke-opacity":"<number-zero-one>","stroke-width":"<svg-length>","text-anchor":"start|middle|end","unicode-range":"<urange>#","voice-balance":"<number>|left|center|right|leftwards|rightwards","voice-duration":"auto|<time>","voice-family":"[[<family-name>|<generic-voice>] ,]* [<family-name>|<generic-voice>]|preserve","voice-pitch":"<frequency>&&absolute|[[x-low|low|medium|high|x-high]||[<frequency>|<semitones>|<percentage>]]","voice-range":"<frequency>&&absolute|[[x-low|low|medium|high|x-high]||[<frequency>|<semitones>|<percentage>]]","voice-rate":"[normal|x-slow|slow|medium|fast|x-fast]||<percentage>","voice-stress":"normal|strong|moderate|none|reduced","voice-volume":"silent|[[x-soft|soft|medium|loud|x-loud]||<decibel>]"}}')},"4w9M":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.race=i.race},"4yVj":function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("HDdC"),r=n("quSY");function o(t,e){return new i.a((function(n){var i=new r.a;return i.add(e.schedule((function(){return t.then((function(t){i.add(e.schedule((function(){n.next(t),i.add(e.schedule((function(){return n.complete()})))})))}),(function(t){i.add(e.schedule((function(){return n.error(t)})))}))}))),i}))}},"5+tZ":function(t,e,n){"use strict";n.d(e,"a",(function(){return d}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("ZUHj"),c=n("l7GE"),l=n("51Dv"),u=n("lJxs"),h=n("Cfvw");function d(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Number.POSITIVE_INFINITY;return"function"==typeof e?function(i){return i.pipe(d((function(n,i){return Object(h.a)(t(n,i)).pipe(Object(u.a)((function(t,r){return e(n,t,i,r)})))}),n))}:("number"==typeof e&&(n=e),function(e){return e.lift(new f(t,n))})}var f=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.POSITIVE_INFINITY;Object(o.a)(this,t),this.project=e,this.concurrent=n}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new p(t,this.project,this.concurrent))}}]),t}(),p=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Number.POSITIVE_INFINITY;return Object(o.a)(this,n),(r=e.call(this,t)).project=i,r.concurrent=a,r.hasCompleted=!1,r.buffer=[],r.active=0,r.index=0,r}return Object(a.a)(n,[{key:"_next",value:function(t){this.active<this.concurrent?this._tryNext(t):this.buffer.push(t)}},{key:"_tryNext",value:function(t){var e,n=this.index++;try{e=this.project(t,n)}catch(i){return void this.destination.error(i)}this.active++,this._innerSub(e,t,n)}},{key:"_innerSub",value:function(t,e,n){var i=new l.a(this,e,n),r=this.destination;r.add(i);var o=Object(s.a)(this,t,void 0,void 0,i);o!==i&&r.add(o)}},{key:"_complete",value:function(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&this.destination.complete(),this.unsubscribe()}},{key:"notifyNext",value:function(t,e,n,i,r){this.destination.next(e)}},{key:"notifyComplete",value:function(t){var e=this.buffer;this.remove(t),this.active--,e.length>0?this._next(e.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}]),n}(c.a)},"51Dv":function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("1OyB"),r=n("vuIU"),o=n("Ji7U"),a=n("LK+K"),s=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,r,o){var a;return Object(i.a)(this,n),(a=e.call(this)).parent=t,a.outerValue=r,a.outerIndex=o,a.index=0,a}return Object(r.a)(n,[{key:"_next",value:function(t){this.parent.notifyNext(this.outerValue,t,this.outerIndex,this.index++,this)}},{key:"_error",value:function(t){this.parent.notifyError(t,this),this.unsubscribe()}},{key:"_complete",value:function(){this.parent.notifyComplete(this),this.unsubscribe()}}]),n}(n("7o/Q").a)},"585i":function(t,e,n){t.exports={AnPlusB:n("Iyun"),Atrule:n("G9/t"),AtrulePrelude:n("FEnK"),AttributeSelector:n("2Gxe"),Block:n("DJod"),Brackets:n("gCdt"),CDC:n("aUQo"),CDO:n("HOgr"),ClassSelector:n("gTGj"),Combinator:n("8mYp"),Comment:n("Y+H1"),Declaration:n("+/L5"),DeclarationList:n("e1rG"),Dimension:n("klIg"),Function:n("UwDK"),HexColor:n("9K4g"),Identifier:n("OyBZ"),IdSelector:n("dB5I"),MediaFeature:n("QBsF"),MediaQuery:n("33Dm"),MediaQueryList:n("Pd0I"),Nth:n("n6Bp"),Number:n("mb2m"),Operator:n("HHXC"),Parentheses:n("Vj1t"),Percentage:n("kPWa"),PseudoClassSelector:n("PzWj"),PseudoElementSelector:n("DDB3"),Ratio:n("F977"),Raw:n("4njK"),Rule:n("yTw5"),Selector:n("/BcF"),SelectorList:n("Lw+5"),String:n("r1XK"),StyleSheet:n("6RFS"),TypeSelector:n("STE7"),UnicodeRange:n("Tnl3"),Url:n("ZVk9"),Value:n("06ho"),WhiteSpace:n("Tpyv")}},"5LO2":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.exhaust=function(){return i.exhaust()(this)}},"5hZ8":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("b/PJ");i.Observable.prototype.skipUntil=r.skipUntil},"5i7x":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.mapTo=function(t){return i.mapTo(t)(this)}},"6IDA":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("YiA4");i.Observable.prototype.windowWhen=r.windowWhen},"6PMC":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.skipWhile=function(t){return i.skipWhile(t)(this)}},"6RFS":function(t,e,n){var i=n("vd7W").TYPE,r=i.WhiteSpace,o=i.Comment,a=i.AtKeyword,s=i.CDO,c=i.CDC;function l(t){return this.Raw(t,null,!1)}t.exports={name:"StyleSheet",structure:{children:[["Comment","CDO","CDC","Atrule","Rule","Raw"]]},parse:function(){for(var t,e=this.scanner.tokenStart,n=this.createList();!this.scanner.eof;){switch(this.scanner.tokenType){case r:this.scanner.next();continue;case o:if(33!==this.scanner.source.charCodeAt(this.scanner.tokenStart+2)){this.scanner.next();continue}t=this.Comment();break;case s:t=this.CDO();break;case c:t=this.CDC();break;case a:t=this.parseWithFallback(this.Atrule,l);break;default:t=this.parseWithFallback(this.Rule,l)}n.push(t)}return{type:"StyleSheet",loc:this.getLocation(e,this.scanner.tokenStart),children:n}},generate:function(t){this.children(t)},walkContext:"stylesheet"}},"6dTv":function(t,e,n){t.exports={"font-face":n("xODi"),import:n("bxbb"),media:n("eAxx"),page:n("dv2O"),supports:n("EaiB")}},"6mJ0":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.findIndex=function(t,e){return i.findIndex(t,e)(this)}},"6yRa":function(t,e,n){"use strict";var i=n("OJSY");t.exports=function(t,e){var n=i.boolean((e=e||{}).allowUpdate,!0);return function(e){if(e=e||window.event,t.target=e.target||e.srcElement||e.originalTarget,t.element=this,t.type=e.type,n(e)){if(e.targetTouches)t.x=e.targetTouches[0].clientX,t.y=e.targetTouches[0].clientY,t.pageX=e.targetTouches[0].pageX,t.pageY=e.targetTouches[0].pageY,t.screenX=e.targetTouches[0].screenX,t.screenY=e.targetTouches[0].screenY;else{if(null===e.pageX&&null!==e.clientX){var i=e.target&&e.target.ownerDocument||document,r=i.documentElement,o=i.body;t.pageX=e.clientX+(r&&r.scrollLeft||o&&o.scrollLeft||0)-(r&&r.clientLeft||o&&o.clientLeft||0),t.pageY=e.clientY+(r&&r.scrollTop||o&&o.scrollTop||0)-(r&&r.clientTop||o&&o.clientTop||0)}else t.pageX=e.pageX,t.pageY=e.pageY;t.x=e.clientX,t.y=e.clientY,t.screenX=e.screenX,t.screenY=e.screenY}t.clientX=t.x,t.clientY=t.y}}}},"7+OI":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("HDdC");function r(t){return!!t&&(t instanceof i.a||"function"==typeof t.lift&&"function"==typeof t.subscribe)}},"7+k4":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("qIMP");i.Observable.prototype.pairwise=r.pairwise},7065:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.max=function(t){return i.max(t)(this)}},"70oK":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("73rQ");i.Observable.prototype.exhaustMap=r.exhaustMap},"73rQ":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.exhaustMap=function(t){return i.exhaustMap(t)(this)}},"7GzS":function(t,e,n){var i=n("vd7W").cmpChar,r=n("vd7W").cmpStr,o=n("vd7W").TYPE,a=o.Ident,s=o.String,c=o.Number,l=o.Function,u=o.Url,h=o.Hash,d=o.Dimension,f=o.Percentage,p=o.LeftParenthesis,m=o.LeftSquareBracket,g=o.Comma,v=o.Delim;t.exports=function(t){switch(this.scanner.tokenType){case h:return this.HexColor();case g:return t.space=null,t.ignoreWSAfter=!0,this.Operator();case p:return this.Parentheses(this.readSequence,t.recognizer);case m:return this.Brackets(this.readSequence,t.recognizer);case s:return this.String();case d:return this.Dimension();case f:return this.Percentage();case c:return this.Number();case l:return r(this.scanner.source,this.scanner.tokenStart,this.scanner.tokenEnd,"url(")?this.Url():this.Function(this.readSequence,t.recognizer);case u:return this.Url();case a:return i(this.scanner.source,this.scanner.tokenStart,117)&&i(this.scanner.source,this.scanner.tokenStart+1,43)?this.UnicodeRange():this.Identifier();case v:var e=this.scanner.source.charCodeAt(this.scanner.tokenStart);if(47===e||42===e||43===e||45===e)return this.Operator();35===e&&this.error("Hex or identifier is expected",this.scanner.tokenStart+1)}}},"7HRe":function(t,e,n){"use strict";n.d(e,"a",(function(){return f}));var i=n("HDdC"),r=n("quSY"),o=n("kJWO"),a=n("4yVj"),s=n("jZKg"),c=n("MBAA"),l=n("QIAL"),u=n("c2HN"),h=n("I55L"),d=n("CMyj");function f(t,e){if(null!=t){if(Object(l.a)(t))return function(t,e){return new i.a((function(n){var i=new r.a;return i.add(e.schedule((function(){var r=t[o.a]();i.add(r.subscribe({next:function(t){i.add(e.schedule((function(){return n.next(t)})))},error:function(t){i.add(e.schedule((function(){return n.error(t)})))},complete:function(){i.add(e.schedule((function(){return n.complete()})))}}))}))),i}))}(t,e);if(Object(u.a)(t))return Object(a.a)(t,e);if(Object(h.a)(t))return Object(s.a)(t,e);if(Object(d.a)(t)||"string"==typeof t)return Object(c.a)(t,e)}throw new TypeError((null!==t&&typeof t||t)+" is not observable")}},"7Hc7":function(t,e,n){"use strict";n.d(e,"a",(function(){return h}));var i=n("1OyB"),r=n("vuIU"),o=n("ReuC"),a=n("foSv"),s=n("Ji7U"),c=n("LK+K"),l=n("c7jc"),u=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,r){var o;return Object(i.a)(this,n),(o=e.call(this,t,r)).scheduler=t,o.work=r,o}return Object(r.a)(n,[{key:"requestAsyncId",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return null!==i&&i>0?Object(o.a)(Object(a.a)(n.prototype),"requestAsyncId",this).call(this,t,e,i):(t.actions.push(this),t.scheduled||(t.scheduled=l.a.setImmediate(t.flush.bind(t,null))))}},{key:"recycleAsyncId",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(null!==i&&i>0||null===i&&this.delay>0)return Object(o.a)(Object(a.a)(n.prototype),"recycleAsyncId",this).call(this,t,e,i);0===t.actions.length&&(l.a.clearImmediate(e),t.scheduled=void 0)}}]),n}(n("3N8a").a),h=new(function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(){return Object(i.a)(this,n),e.apply(this,arguments)}return Object(r.a)(n,[{key:"flush",value:function(t){this.active=!0,this.scheduled=void 0;var e,n=this.actions,i=-1,r=n.length;t=t||n.shift();do{if(e=t.execute(t.state,t.delay))break}while(++i<r&&(t=n.shift()));if(this.active=!1,e){for(;++i<r&&(t=n.shift());)t.unsubscribe();throw e}}}]),n}(n("IjjT").a))(u)},"7Ki+":function(t,e,n){"use strict";n.d(e,"d",(function(){return r})),n.d(e,"c",(function(){return o})),n.d(e,"b",(function(){return a})),n.d(e,"a",(function(){return s}));var i=n("Gqt4");function r(t,e){return void 0===e&&(e=0),"string"!=typeof t||0===e||t.length<=e?t:t.substr(0,e)+"..."}function o(t,e){var n=t,i=n.length;if(i<=150)return n;e>i&&(e=i);var r=Math.max(e-60,0);r<5&&(r=0);var o=Math.min(r+140,i);return o>i-5&&(o=i),o===i&&(r=Math.max(o-140,0)),n=n.slice(r,o),r>0&&(n="'{snip} "+n),o<i&&(n+=" {snip}"),n}function a(t,e){if(!Array.isArray(t))return"";for(var n=[],i=0;i<t.length;i++){var r=t[i];try{n.push(String(r))}catch(o){n.push("[value cannot be serialized]")}}return n.join(e)}function s(t,e){return!!Object(i.k)(t)&&(Object(i.j)(e)?e.test(t):"string"==typeof e&&-1!==t.indexOf(e))}},"7MrP":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("TqLU");i.Observable.prototype.find=r.find},"7N5M":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("TpWx");i.Observable.prototype.windowCount=r.windowCount},"7RDD":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("ZHaO");i.Observable.prototype.multicast=r.multicast},"7o/Q":function(t,e,n){"use strict";n.d(e,"a",(function(){return g}));var i=n("1OyB"),r=n("vuIU"),o=n("JX7q"),a=n("ReuC"),s=n("foSv"),c=n("Ji7U"),l=n("LK+K"),u=n("n6bG"),h=n("gRHU"),d=n("quSY"),f=n("2QA8"),p=n("2fFW"),m=n("NJ4a"),g=function(t){Object(c.a)(n,t);var e=Object(l.a)(n);function n(t,r,a){var s;switch(Object(i.a)(this,n),(s=e.call(this)).syncErrorValue=null,s.syncErrorThrown=!1,s.syncErrorThrowable=!1,s.isStopped=!1,arguments.length){case 0:s.destination=h.a;break;case 1:if(!t){s.destination=h.a;break}if("object"==typeof t){t instanceof n?(s.syncErrorThrowable=t.syncErrorThrowable,s.destination=t,t.add(Object(o.a)(s))):(s.syncErrorThrowable=!0,s.destination=new v(Object(o.a)(s),t));break}default:s.syncErrorThrowable=!0,s.destination=new v(Object(o.a)(s),t,r,a)}return s}return Object(r.a)(n,[{key:f.a,value:function(){return this}},{key:"next",value:function(t){this.isStopped||this._next(t)}},{key:"error",value:function(t){this.isStopped||(this.isStopped=!0,this._error(t))}},{key:"complete",value:function(){this.isStopped||(this.isStopped=!0,this._complete())}},{key:"unsubscribe",value:function(){this.closed||(this.isStopped=!0,Object(a.a)(Object(s.a)(n.prototype),"unsubscribe",this).call(this))}},{key:"_next",value:function(t){this.destination.next(t)}},{key:"_error",value:function(t){this.destination.error(t),this.unsubscribe()}},{key:"_complete",value:function(){this.destination.complete(),this.unsubscribe()}},{key:"_unsubscribeAndRecycle",value:function(){var t=this._parentOrParents;return this._parentOrParents=null,this.unsubscribe(),this.closed=!1,this.isStopped=!1,this._parentOrParents=t,this}}],[{key:"create",value:function(t,e,i){var r=new n(t,e,i);return r.syncErrorThrowable=!1,r}}]),n}(d.a),v=function(t){Object(c.a)(n,t);var e=Object(l.a)(n);function n(t,r,a,s){var c,l;Object(i.a)(this,n),(c=e.call(this))._parentSubscriber=t;var d=Object(o.a)(c);return Object(u.a)(r)?l=r:r&&(l=r.next,a=r.error,s=r.complete,r!==h.a&&(d=Object.create(r),Object(u.a)(d.unsubscribe)&&c.add(d.unsubscribe.bind(d)),d.unsubscribe=c.unsubscribe.bind(Object(o.a)(c)))),c._context=d,c._next=l,c._error=a,c._complete=s,c}return Object(r.a)(n,[{key:"next",value:function(t){if(!this.isStopped&&this._next){var e=this._parentSubscriber;p.a.useDeprecatedSynchronousErrorHandling&&e.syncErrorThrowable?this.__tryOrSetError(e,this._next,t)&&this.unsubscribe():this.__tryOrUnsub(this._next,t)}}},{key:"error",value:function(t){if(!this.isStopped){var e=this._parentSubscriber,n=p.a.useDeprecatedSynchronousErrorHandling;if(this._error)n&&e.syncErrorThrowable?(this.__tryOrSetError(e,this._error,t),this.unsubscribe()):(this.__tryOrUnsub(this._error,t),this.unsubscribe());else if(e.syncErrorThrowable)n?(e.syncErrorValue=t,e.syncErrorThrown=!0):Object(m.a)(t),this.unsubscribe();else{if(this.unsubscribe(),n)throw t;Object(m.a)(t)}}}},{key:"complete",value:function(){var t=this;if(!this.isStopped){var e=this._parentSubscriber;if(this._complete){var n=function(){return t._complete.call(t._context)};p.a.useDeprecatedSynchronousErrorHandling&&e.syncErrorThrowable?(this.__tryOrSetError(e,n),this.unsubscribe()):(this.__tryOrUnsub(n),this.unsubscribe())}else this.unsubscribe()}}},{key:"__tryOrUnsub",value:function(t,e){try{t.call(this._context,e)}catch(n){if(this.unsubscribe(),p.a.useDeprecatedSynchronousErrorHandling)throw n;Object(m.a)(n)}}},{key:"__tryOrSetError",value:function(t,e,n){if(!p.a.useDeprecatedSynchronousErrorHandling)throw new Error("bad call");try{e.call(this._context,n)}catch(i){return p.a.useDeprecatedSynchronousErrorHandling?(t.syncErrorValue=i,t.syncErrorThrown=!0,!0):(Object(m.a)(i),!0)}return!1}},{key:"_unsubscribe",value:function(){var t=this._parentSubscriber;this._context=null,this._parentSubscriber=null,t.unsubscribe()}}]),n}(g)},"7y2s":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.distinctUntilKeyChanged=function(t,e){return i.distinctUntilKeyChanged(t,e)(this)}},"82qP":function(t,e,n){t.exports={AtrulePrelude:n("TefO"),Selector:n("HvLG"),Value:n("n/gj")}},"89kA":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("ZR4w");i.Observable.prototype.map=r.map},"8Ip+":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");function r(){return i.NEVER}e.staticNever=r,i.Observable.never=r},"8LQU":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.subscribeOn=function(t,e){return void 0===e&&(e=0),i.subscribeOn(t,e)(this)}},"8Qeq":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("7o/Q");function r(t){for(;t;){var e=t.destination;if(t.closed||t.isStopped)return!1;t=e&&e instanceof i.a?e:null}return!0}},"8XFM":function(t,e){var n=Object.prototype.hasOwnProperty,i={generic:!0,types:{},atrules:{},properties:{},parseContext:{},scope:{},atrule:["parse"],pseudo:["parse"],node:["name","structure","parse","generate","walkContext"]};function r(t){return t&&t.constructor===Object}function o(t){return r(t)?Object.assign({},t):t}function a(t,e){for(var i in e)n.call(e,i)&&(r(t[i])?a(t[i],o(e[i])):t[i]=o(e[i]))}t.exports=function(t,e){return function t(e,i,s){for(var c in s)if(!1!==n.call(s,c))if(!0===s[c])c in i&&n.call(i,c)&&(e[c]=o(i[c]));else if(s[c])if(r(s[c]))a(l={},e[c]),a(l,i[c]),e[c]=l;else if(Array.isArray(s[c])){var l={},u=s[c].reduce((function(t,e){return t[e]=!0,t}),{});for(var h in e[c])n.call(e[c],h)&&(l[h]={},e[c]&&e[c][h]&&t(l[h],e[c][h],u));for(var h in i[c])n.call(i[c],h)&&(l[h]||(l[h]={}),i[c]&&i[c][h]&&t(l[h],i[c][h],u));e[c]=l}return e}(t,e,i)}},"8YE1":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("5i7x");i.Observable.prototype.mapTo=r.mapTo},"8Yhr":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("Vzig");i.Observable.prototype.throttleTime=r.throttleTime},"8mU2":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.takeLast=function(t){return i.takeLast(t)(this)}},"8mYp":function(t,e,n){var i=n("vd7W").TYPE.Ident;t.exports={name:"Combinator",structure:{name:String},parse:function(){var t=this.scanner.tokenStart;switch(this.scanner.source.charCodeAt(this.scanner.tokenStart)){case 62:case 43:case 126:this.scanner.next();break;case 47:this.scanner.next(),this.scanner.tokenType===i&&!1!==this.scanner.lookupValue(0,"deep")||this.error("Identifier `deep` is expected"),this.scanner.next(),this.scanner.isDelim(47)||this.error("Solidus is expected"),this.scanner.next();break;default:this.error("Combinator is expected")}return{type:"Combinator",loc:this.getLocation(t,this.scanner.tokenStart),name:this.scanner.substrToCursor(t)}},generate:function(t){this.chunk(t.name)}}},"8wsT":function(t,e,n){var i=n("twQA"),r=i.TYPE,o=i.NAME,a=n("P3uw").cmpStr,s=r.EOF,c=r.WhiteSpace,l=r.Comment,u=function(){this.offsetAndType=null,this.balance=null,this.reset()};u.prototype={reset:function(){this.eof=!1,this.tokenIndex=-1,this.tokenType=0,this.tokenStart=this.firstCharOffset,this.tokenEnd=this.firstCharOffset},lookupType:function(t){return(t+=this.tokenIndex)<this.tokenCount?this.offsetAndType[t]>>24:s},lookupOffset:function(t){return(t+=this.tokenIndex)<this.tokenCount?16777215&this.offsetAndType[t-1]:this.source.length},lookupValue:function(t,e){return(t+=this.tokenIndex)<this.tokenCount&&a(this.source,16777215&this.offsetAndType[t-1],16777215&this.offsetAndType[t],e)},getTokenStart:function(t){return t===this.tokenIndex?this.tokenStart:t>0?t<this.tokenCount?16777215&this.offsetAndType[t-1]:16777215&this.offsetAndType[this.tokenCount]:this.firstCharOffset},getRawLength:function(t,e){var n,i=t,r=16777215&this.offsetAndType[Math.max(i-1,0)];t:for(;i<this.tokenCount&&!((n=this.balance[i])<t);i++)switch(e(this.offsetAndType[i]>>24,this.source,r)){case 1:break t;case 2:i++;break t;default:r=16777215&this.offsetAndType[i],this.balance[n]===i&&(i=n)}return i-this.tokenIndex},isBalanceEdge:function(t){return this.balance[this.tokenIndex]<t},isDelim:function(t,e){return e?this.lookupType(e)===r.Delim&&this.source.charCodeAt(this.lookupOffset(e))===t:this.tokenType===r.Delim&&this.source.charCodeAt(this.tokenStart)===t},getTokenValue:function(){return this.source.substring(this.tokenStart,this.tokenEnd)},getTokenLength:function(){return this.tokenEnd-this.tokenStart},substrToCursor:function(t){return this.source.substring(t,this.tokenStart)},skipWS:function(){for(var t=this.tokenIndex,e=0;t<this.tokenCount&&this.offsetAndType[t]>>24===c;t++,e++);e>0&&this.skip(e)},skipSC:function(){for(;this.tokenType===c||this.tokenType===l;)this.next()},skip:function(t){var e=this.tokenIndex+t;e<this.tokenCount?(this.tokenIndex=e,this.tokenStart=16777215&this.offsetAndType[e-1],this.tokenType=(e=this.offsetAndType[e])>>24,this.tokenEnd=16777215&e):(this.tokenIndex=this.tokenCount,this.next())},next:function(){var t=this.tokenIndex+1;t<this.tokenCount?(this.tokenIndex=t,this.tokenStart=this.tokenEnd,this.tokenType=(t=this.offsetAndType[t])>>24,this.tokenEnd=16777215&t):(this.tokenIndex=this.tokenCount,this.eof=!0,this.tokenType=s,this.tokenStart=this.tokenEnd=this.source.length)},dump:function(){var t=this.firstCharOffset;return Array.prototype.slice.call(this.offsetAndType,0,this.tokenCount).map((function(e,n){var i=t,r=16777215&e;return t=r,{idx:n,type:o[e>>24],chunk:this.source.substring(i,r),balance:this.balance[n]}}),this)}},t.exports=u},"9E4K":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("gzwt");i.Observable.prototype.count=r.count},"9HtI":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("atJV");i.Observable.prototype.last=r.last},"9K4g":function(t,e,n){var i=n("vd7W").TYPE.Hash;t.exports={name:"HexColor",structure:{value:String},parse:function(){var t=this.scanner.tokenStart;return this.eat(i),{type:"HexColor",loc:this.getLocation(t,this.scanner.tokenStart),value:this.scanner.substrToCursor(t+1)}},generate:function(t){this.chunk("#"),this.chunk(t.value)}}},"9Sef":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("fY5S");i.Observable.prototype.zip=r.zipProto},"9ppp":function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){function t(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}return t.prototype=Object.create(Error.prototype),t}()},"9qLK":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("6PMC");i.Observable.prototype.skipWhile=r.skipWhile},"9xAK":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("w0v+"),o=n("kU1M");e.bufferTime=function(t){var e=arguments.length,n=i.asyncScheduler;r.isScheduler(arguments[arguments.length-1])&&(n=arguments[arguments.length-1],e--);var a=null;e>=2&&(a=arguments[1]);var s=Number.POSITIVE_INFINITY;return e>=3&&(s=arguments[2]),o.bufferTime(t,a,s,n)(this)}},"A+qg":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("IMZ1");i.Observable.prototype.publishBehavior=r.publishBehavior},A5T5:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.repeatWhen=function(t){return i.repeatWhen(t)(this)}},ADT6:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.filter=function(t,e){return i.filter(t,e)(this)}},B3CK:function(t,e,n){t.exports=n("lXnc")},B9G6:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.groupBy=function(t,e,n,r){return i.groupBy(t,e,n,r)(this)}},BFxc:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q"),c=n("4I5i"),l=n("EY2u");function u(t){return function(e){return 0===t?Object(l.b)():e.lift(new h(t))}}var h=function(){function t(e){if(Object(o.a)(this,t),this.total=e,this.total<0)throw new c.a}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new d(t,this.total))}}]),t}(),d=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).total=i,r.ring=new Array,r.count=0,r}return Object(a.a)(n,[{key:"_next",value:function(t){var e=this.ring,n=this.total,i=this.count++;e.length<n?e.push(t):e[i%n]=t}},{key:"_complete",value:function(){var t=this.destination,e=this.count;if(e>0)for(var n=this.count>=this.total?this.total:this.count,i=this.ring,r=0;r<n;r++){var o=e++%n;t.next(i[o])}t.complete()}}]),n}(s.a)},BSEn:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.bufferToggle=function(t,e){return i.bufferToggle(t,e)(this)}},BdNY:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("4Hgy");i.Observable.prototype.do=r._do,i.Observable.prototype._do=r._do},BilO:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.of=i.of},BsWD:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("a3WO");function r(t,e){if(t){if("string"==typeof t)return Object(i.a)(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Object(i.a)(t,e):void 0}}},"C/AH":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("Elj+");i.Observable.prototype.repeat=r.repeat},C8tm:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("B9G6");i.Observable.prototype.groupBy=r.groupBy},CJ5M:function(t,e,n){var i=n("vd7W"),r=i.isIdentifierStart,o=i.isHexDigit,a=i.isDigit,s=i.cmpStr,c=i.consumeNumber,l=i.TYPE,u=n("/slF"),h=n("2TAq"),d=["unset","initial","inherit"],f=["calc(","-moz-calc(","-webkit-calc("];function p(t,e){return e<t.length?t.charCodeAt(e):0}function m(t,e){return s(t,0,t.length,e)}function g(t,e){for(var n=0;n<e.length;n++)if(m(t,e[n]))return!0;return!1}function v(t,e){return e===t.length-2&&92===t.charCodeAt(e)&&a(t.charCodeAt(e+1))}function b(t,e,n){if(t&&"Range"===t.type){var i=Number(void 0!==n&&n!==e.length?e.substr(0,n):e);if(isNaN(i))return!0;if(null!==t.min&&i<t.min)return!0;if(null!==t.max&&i>t.max)return!0}return!1}function y(t,e){var n=t.index,i=0;do{if(i++,t.balance<=n)break}while(t=e(i));return i}function _(t){return function(e,n,i){return null===e?0:e.type===l.Function&&g(e.value,f)?y(e,n):t(e,n,i)}}function w(t){return function(e){return null===e||e.type!==t?0:1}}function k(t){return function(e,n,i){if(null===e||e.type!==l.Dimension)return 0;var r=c(e.value,0);if(null!==t){var o=e.value.indexOf("\\",r),a=-1!==o&&v(e.value,o)?e.value.substring(r,o):e.value.substr(r);if(!1===t.hasOwnProperty(a.toLowerCase()))return 0}return b(i,e.value,r)?0:1}}function C(t){return"function"!=typeof t&&(t=function(){return 0}),function(e,n,i){return null!==e&&e.type===l.Number&&0===Number(e.value)?1:t(e,n,i)}}t.exports={"ident-token":w(l.Ident),"function-token":w(l.Function),"at-keyword-token":w(l.AtKeyword),"hash-token":w(l.Hash),"string-token":w(l.String),"bad-string-token":w(l.BadString),"url-token":w(l.Url),"bad-url-token":w(l.BadUrl),"delim-token":w(l.Delim),"number-token":w(l.Number),"percentage-token":w(l.Percentage),"dimension-token":w(l.Dimension),"whitespace-token":w(l.WhiteSpace),"CDO-token":w(l.CDO),"CDC-token":w(l.CDC),"colon-token":w(l.Colon),"semicolon-token":w(l.Semicolon),"comma-token":w(l.Comma),"[-token":w(l.LeftSquareBracket),"]-token":w(l.RightSquareBracket),"(-token":w(l.LeftParenthesis),")-token":w(l.RightParenthesis),"{-token":w(l.LeftCurlyBracket),"}-token":w(l.RightCurlyBracket),string:w(l.String),ident:w(l.Ident),"custom-ident":function(t){if(null===t||t.type!==l.Ident)return 0;var e=t.value.toLowerCase();return g(e,d)||m(e,"default")?0:1},"custom-property-name":function(t){return null===t||t.type!==l.Ident||45!==p(t.value,0)||45!==p(t.value,1)?0:1},"hex-color":function(t){if(null===t||t.type!==l.Hash)return 0;var e=t.value.length;if(4!==e&&5!==e&&7!==e&&9!==e)return 0;for(var n=1;n<e;n++)if(!o(t.value.charCodeAt(n)))return 0;return 1},"id-selector":function(t){return null===t||t.type!==l.Hash?0:r(p(t.value,1),p(t.value,2),p(t.value,3))?1:0},"an-plus-b":u,urange:h,"declaration-value":function(t,e){if(!t)return 0;var n=0,i=0,r=t.index;t:do{switch(t.type){case l.BadString:case l.BadUrl:break t;case l.RightCurlyBracket:case l.RightParenthesis:case l.RightSquareBracket:if(t.balance>t.index||t.balance<r)break t;i--;break;case l.Semicolon:if(0===i)break t;break;case l.Delim:if("!"===t.value&&0===i)break t;break;case l.Function:case l.LeftParenthesis:case l.LeftSquareBracket:case l.LeftCurlyBracket:i++}if(n++,t.balance<=r)break}while(t=e(n));return n},"any-value":function(t,e){if(!t)return 0;var n=t.index,i=0;t:do{switch(t.type){case l.BadString:case l.BadUrl:break t;case l.RightCurlyBracket:case l.RightParenthesis:case l.RightSquareBracket:if(t.balance>t.index||t.balance<n)break t}if(i++,t.balance<=n)break}while(t=e(i));return i},dimension:_(k(null)),angle:_(k({deg:!0,grad:!0,rad:!0,turn:!0})),decibel:_(k({db:!0})),frequency:_(k({hz:!0,khz:!0})),flex:_(k({fr:!0})),length:_(C(k({px:!0,mm:!0,cm:!0,in:!0,pt:!0,pc:!0,q:!0,em:!0,ex:!0,ch:!0,rem:!0,vh:!0,vw:!0,vmin:!0,vmax:!0,vm:!0}))),resolution:_(k({dpi:!0,dpcm:!0,dppx:!0,x:!0})),semitones:_(k({st:!0})),time:_(k({s:!0,ms:!0})),percentage:_((function(t,e,n){return null===t||t.type!==l.Percentage||b(n,t.value,t.value.length-1)?0:1})),zero:C(),number:_((function(t,e,n){if(null===t)return 0;var i=c(t.value,0);return i===t.value.length||v(t.value,i)?b(n,t.value,i)?0:1:0})),integer:_((function(t,e,n){if(null===t||t.type!==l.Number)return 0;for(var i=43===t.value.charCodeAt(0)||45===t.value.charCodeAt(0)?1:0;i<t.value.length;i++)if(!a(t.value.charCodeAt(i)))return 0;return b(n,t.value,i)?0:1})),"-ms-legacy-expression":function(t,e){return null!==t&&m(t.value,"expression(")?y(t,e):0}}},CMyj:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("Lhse");function r(t){return t&&"function"==typeof t[i.a]}},COpn:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.skipLast=function(t){return i.skipLast(t)(this)}},CRDf:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("kJWO"),r=function(t){return function(e){var n=t[i.a]();if("function"!=typeof n.subscribe)throw new TypeError("Provided object does not correctly implement Symbol.observable");return n.subscribe(e)}}},CVW7:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.sample=function(t){return i.sample(t)(this)}},Cbry:function(t,e){e.getArg=function(t,e,n){if(e in t)return t[e];if(3===arguments.length)return n;throw new Error('"'+e+'" is a required argument.')};var n=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,i=/^data:.+\,.+$/;function r(t){var e=t.match(n);return e?{scheme:e[1],auth:e[2],host:e[3],port:e[4],path:e[5]}:null}function o(t){var e="";return t.scheme&&(e+=t.scheme+":"),e+="//",t.auth&&(e+=t.auth+"@"),t.host&&(e+=t.host),t.port&&(e+=":"+t.port),t.path&&(e+=t.path),e}function a(t){var n=t,i=r(t);if(i){if(!i.path)return t;n=i.path}for(var a,s=e.isAbsolute(n),c=n.split(/\/+/),l=0,u=c.length-1;u>=0;u--)"."===(a=c[u])?c.splice(u,1):".."===a?l++:l>0&&(""===a?(c.splice(u+1,l),l=0):(c.splice(u,2),l--));return""===(n=c.join("/"))&&(n=s?"/":"."),i?(i.path=n,o(i)):n}function s(t,e){""===t&&(t="."),""===e&&(e=".");var n=r(e),s=r(t);if(s&&(t=s.path||"/"),n&&!n.scheme)return s&&(n.scheme=s.scheme),o(n);if(n||e.match(i))return e;if(s&&!s.host&&!s.path)return s.host=e,o(s);var c="/"===e.charAt(0)?e:a(t.replace(/\/+$/,"")+"/"+e);return s?(s.path=c,o(s)):c}e.urlParse=r,e.urlGenerate=o,e.normalize=a,e.join=s,e.isAbsolute=function(t){return"/"===t.charAt(0)||n.test(t)},e.relative=function(t,e){""===t&&(t="."),t=t.replace(/\/$/,"");for(var n=0;0!==e.indexOf(t+"/");){var i=t.lastIndexOf("/");if(i<0)return e;if((t=t.slice(0,i)).match(/^([^\/]+:\/)?\/*$/))return e;++n}return Array(n+1).join("../")+e.substr(t.length+1)};var c=!("__proto__"in Object.create(null));function l(t){return t}function u(t){if(!t)return!1;var e=t.length;if(e<9)return!1;if(95!==t.charCodeAt(e-1)||95!==t.charCodeAt(e-2)||111!==t.charCodeAt(e-3)||116!==t.charCodeAt(e-4)||111!==t.charCodeAt(e-5)||114!==t.charCodeAt(e-6)||112!==t.charCodeAt(e-7)||95!==t.charCodeAt(e-8)||95!==t.charCodeAt(e-9))return!1;for(var n=e-10;n>=0;n--)if(36!==t.charCodeAt(n))return!1;return!0}function h(t,e){return t===e?0:null===t?1:null===e?-1:t>e?1:-1}e.toSetString=c?l:function(t){return u(t)?"$"+t:t},e.fromSetString=c?l:function(t){return u(t)?t.slice(1):t},e.compareByOriginalPositions=function(t,e,n){var i=h(t.source,e.source);return 0!==i||0!=(i=t.originalLine-e.originalLine)||0!=(i=t.originalColumn-e.originalColumn)||n||0!=(i=t.generatedColumn-e.generatedColumn)||0!=(i=t.generatedLine-e.generatedLine)?i:h(t.name,e.name)},e.compareByGeneratedPositionsDeflated=function(t,e,n){var i=t.generatedLine-e.generatedLine;return 0!==i||0!=(i=t.generatedColumn-e.generatedColumn)||n||0!==(i=h(t.source,e.source))||0!=(i=t.originalLine-e.originalLine)||0!=(i=t.originalColumn-e.originalColumn)?i:h(t.name,e.name)},e.compareByGeneratedPositionsInflated=function(t,e){var n=t.generatedLine-e.generatedLine;return 0!==n||0!=(n=t.generatedColumn-e.generatedColumn)||0!==(n=h(t.source,e.source))||0!=(n=t.originalLine-e.originalLine)||0!=(n=t.originalColumn-e.originalColumn)?n:h(t.name,e.name)},e.parseSourceMapInput=function(t){return JSON.parse(t.replace(/^\)]}'[^\n]*\n/,""))},e.computeSourceURL=function(t,e,n){if(e=e||"",t&&("/"!==t[t.length-1]&&"/"!==e[0]&&(t+="/"),e=t+e),n){var i=r(n);if(!i)throw new Error("sourceMapURL could not be parsed");if(i.path){var c=i.path.lastIndexOf("/");c>=0&&(i.path=i.path.substring(0,c+1))}e=s(o(i),e)}return a(e)}},Cfvw:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("HDdC"),r=n("SeVD"),o=n("7HRe");function a(t,e){return e?Object(o.a)(t,e):t instanceof i.a?t:new i.a(Object(r.a)(t))}},CuWV:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.publishLast=function(){return i.publishLast()(this)}},CwTu:function(t,e,n){var i=n("XDwu"),r=n("vI5D");function o(t,e){var n=t&&t.loc&&t.loc[e];return n?{offset:n.offset,line:n.line,column:n.column}:null}t.exports={SyntaxReferenceError:function(t,e){var n=i("SyntaxReferenceError",t+(e?" `"+e+"`":""));return n.reference=e,n},MatchError:function(t,e,n,a){var s=i("SyntaxMatchError",t),c=function(t){for(var e=t.tokens,n=t.longestMatch,i=n<e.length?e[n].node:null,r=-1,o=0,a="",s=0;s<e.length;s++)s===n&&(r=a.length),null!==i&&e[s].node===i&&(s<=n?o++:o=0),a+=e[s].value;return{node:i,css:a,mismatchOffset:-1===r?a.length:r,last:null===i||o>1}}(a),l=c.mismatchOffset||0,u=c.node||n,h=o(u,"end"),d=c.last?h:o(u,"start"),f=c.css;return s.rawMessage=t,s.syntax=e?r(e):"<generic>",s.css=f,s.mismatchOffset=l,s.loc={source:u&&u.loc&&u.loc.source||"<unknown>",start:d,end:h},s.line=d?d.line:void 0,s.column=d?d.column:void 0,s.offset=d?d.offset:void 0,s.message=t+"\n syntax: "+s.syntax+"\n value: "+(s.css||"<empty string>")+"\n --------"+new Array(s.mismatchOffset+1).join("-")+"^",s}}},D0XW:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("3N8a"),r=new(n("IjjT").a)(i.a)},DDB3:function(t,e,n){var i=n("vd7W").TYPE,r=i.Ident,o=i.Function,a=i.Colon,s=i.RightParenthesis;t.exports={name:"PseudoElementSelector",structure:{name:String,children:[["Raw"],null]},parse:function(){var t,e,n=this.scanner.tokenStart,i=null;return this.eat(a),this.eat(a),this.scanner.tokenType===o?(e=(t=this.consumeFunctionName()).toLowerCase(),this.pseudo.hasOwnProperty(e)?(this.scanner.skipSC(),i=this.pseudo[e].call(this),this.scanner.skipSC()):(i=this.createList()).push(this.Raw(this.scanner.tokenIndex,null,!1)),this.eat(s)):t=this.consume(r),{type:"PseudoElementSelector",loc:this.getLocation(n,this.scanner.tokenStart),name:t,children:i}},generate:function(t){this.chunk("::"),this.chunk(t.name),null!==t.children&&(this.chunk("("),this.children(t),this.chunk(")"))},walkContext:"function"}},DH7j:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){return Array.isArray||function(t){return t&&"number"==typeof t.length}}()},DJod:function(t,e,n){var i=n("vd7W").TYPE,r=n("4njK").mode,o=i.WhiteSpace,a=i.Comment,s=i.Semicolon,c=i.AtKeyword,l=i.LeftCurlyBracket,u=i.RightCurlyBracket;function h(t){return this.Raw(t,null,!0)}function d(){return this.parseWithFallback(this.Rule,h)}function f(t){return this.Raw(t,r.semicolonIncluded,!0)}function p(){if(this.scanner.tokenType===s)return f.call(this,this.scanner.tokenIndex);var t=this.parseWithFallback(this.Declaration,f);return this.scanner.tokenType===s&&this.scanner.next(),t}t.exports={name:"Block",structure:{children:[["Atrule","Rule","Declaration"]]},parse:function(t){var e=t?p:d,n=this.scanner.tokenStart,i=this.createList();this.eat(l);t:for(;!this.scanner.eof;)switch(this.scanner.tokenType){case u:break t;case o:case a:this.scanner.next();break;case c:i.push(this.parseWithFallback(this.Atrule,h));break;default:i.push(e.call(this))}return this.scanner.eof||this.eat(u),{type:"Block",loc:this.getLocation(n,this.scanner.tokenStart),children:i}},generate:function(t){this.chunk("{"),this.children(t,(function(t){"Declaration"===t.type&&this.chunk(";")})),this.chunk("}")},walkContext:"block"}},DNeS:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("4AtU");i.Observable.prototype.expand=r.expand},DWF9:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("mfsk");i.Observable.prototype.defaultIfEmpty=r.defaultIfEmpty},DpPw:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("bcPL");i.Observable.prototype.onErrorResumeNext=r.onErrorResumeNext},Du80:function(t,e,n){var i=n("vd7W"),r=new(n("8wsT")),o={decorator:function(t){var e=null,n={len:0,node:null},i=[n],r="";return{children:t.children,node:function(n){var i=e;e=n,t.node.call(this,n),e=i},chunk:function(t){r+=t,n.node!==e?i.push({len:t.length,node:e}):n.len+=t.length},result:function(){return a(r,i)}}}};function a(t,e){var n=[],o=0,a=0,s=e?e[a].node:null;for(i(t,r);!r.eof;){if(e)for(;a<e.length&&o+e[a].len<=r.tokenStart;)o+=e[a++].len,s=e[a].node;n.push({type:r.tokenType,value:r.getTokenValue(),index:r.tokenIndex,balance:r.balance[r.tokenIndex],node:s}),r.next()}return n}t.exports=function(t,e){return"string"==typeof t?a(t,null):e.generate(t,o)}},E2OZ:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("VmLd");i.Observable.prototype.combineLatest=r.combineLatest},EQ5u:function(t,e,n){"use strict";n.d(e,"a",(function(){return f})),n.d(e,"b",(function(){return p}));var i=n("ReuC"),r=n("foSv"),o=n("1OyB"),a=n("vuIU"),s=n("Ji7U"),c=n("LK+K"),l=n("XNiG"),u=n("HDdC"),h=(n("7o/Q"),n("quSY")),d=n("x+ZX"),f=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this)).source=t,r.subjectFactory=i,r._refCount=0,r._isComplete=!1,r}return Object(a.a)(n,[{key:"_subscribe",value:function(t){return this.getSubject().subscribe(t)}},{key:"getSubject",value:function(){var t=this._subject;return t&&!t.isStopped||(this._subject=this.subjectFactory()),this._subject}},{key:"connect",value:function(){var t=this._connection;return t||(this._isComplete=!1,(t=this._connection=new h.a).add(this.source.subscribe(new m(this.getSubject(),this))),t.closed&&(this._connection=null,t=h.a.EMPTY)),t}},{key:"refCount",value:function(){return Object(d.a)()(this)}}]),n}(u.a),p=function(){var t=f.prototype;return{operator:{value:null},_refCount:{value:0,writable:!0},_subject:{value:null,writable:!0},_connection:{value:null,writable:!0},_subscribe:{value:t._subscribe},_isComplete:{value:t._isComplete,writable:!0},getSubject:{value:t.getSubject},connect:{value:t.connect},refCount:{value:t.refCount}}}(),m=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).connectable=i,r}return Object(a.a)(n,[{key:"_error",value:function(t){this._unsubscribe(),Object(i.a)(Object(r.a)(n.prototype),"_error",this).call(this,t)}},{key:"_complete",value:function(){this.connectable._isComplete=!0,this._unsubscribe(),Object(i.a)(Object(r.a)(n.prototype),"_complete",this).call(this)}},{key:"_unsubscribe",value:function(){var t=this.connectable;if(t){this.connectable=null;var e=t._connection;t._refCount=0,t._subject=null,t._connection=null,e&&e.unsubscribe()}}}]),n}(l.c)},EUoG:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("v87U");i.Observable.prototype.single=r.single},EY2u:function(t,e,n){"use strict";n.d(e,"a",(function(){return r})),n.d(e,"b",(function(){return o}));var i=n("HDdC"),r=new i.a((function(t){return t.complete()}));function o(t){return t?function(t){return new i.a((function(e){return t.schedule((function(){return e.complete()}))}))}(t):r}},EaiB:function(t,e,n){var i=n("vd7W").TYPE,r=i.WhiteSpace,o=i.Comment,a=i.Ident,s=i.Function,c=i.Colon,l=i.LeftParenthesis;function u(){return this.createSingleNodeList(this.Raw(this.scanner.tokenIndex,null,!1))}function h(){return this.scanner.skipSC(),this.scanner.tokenType===a&&this.lookupNonWSType(1)===c?this.createSingleNodeList(this.Declaration()):d.call(this)}function d(){var t,e=this.createList(),n=null;this.scanner.skipSC();t:for(;!this.scanner.eof;){switch(this.scanner.tokenType){case r:n=this.WhiteSpace();continue;case o:this.scanner.next();continue;case s:t=this.Function(u,this.scope.AtrulePrelude);break;case a:t=this.Identifier();break;case l:t=this.Parentheses(h,this.scope.AtrulePrelude);break;default:break t}null!==n&&(e.push(n),n=null),e.push(t)}return e}t.exports={parse:{prelude:function(){var t=d.call(this);return null===this.getFirstListNode(t)&&this.error("Condition is expected"),t},block:function(){return this.Block(!1)}}}},EcEN:function(t,e,n){var i=n("xDdU"),r=n("xk4V"),o=r;o.v1=i,o.v4=r,t.exports=o},EiPP:function(t,e,n){var i=n("O36p"),r=n("1aLD"),o=n("8wsT"),a=n("mK1g"),s=n("fmF7"),c=n("vd7W"),l=n("u5kB"),u=n("jpu9"),h=n("QtvL"),d=n("4HHr"),f=n("bgAe"),p=n("t1UP"),m=n("8XFM");e.create=function(t){return function t(e){var n=l(e),g=d(e),v=u(e),b=h(g),y={List:i,SyntaxError:r,TokenStream:o,Lexer:a,vendorPrefix:p.vendorPrefix,keyword:p.keyword,property:p.property,isCustomProperty:p.isCustomProperty,definitionSyntax:s,lexer:null,createLexer:function(t){return new a(t,y,y.lexer.structure)},tokenize:c,parse:n,walk:g,generate:v,find:g.find,findLast:g.findLast,findAll:g.findAll,clone:f,fromPlainObject:b.fromPlainObject,toPlainObject:b.toPlainObject,createSyntax:function(e){return t(m({},e))},fork:function(n){var i=m({},e);return t("function"==typeof n?n(i,Object.assign):m(i,n))}};return y.lexer=new a({generic:!0,types:e.types,atrules:e.atrules,properties:e.properties,node:e.node},y),y}(m({},t))}},"Elj+":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.repeat=function(t){return void 0===t&&(t=-1),i.repeat(t)(this)}},"F97/":function(t,e,n){"use strict";function i(t,e){function n(){return!n.pred.apply(n.thisArg,arguments)}return n.pred=t,n.thisArg=e,n}n.d(e,"a",(function(){return i}))},F977:function(t,e,n){var i=n("vd7W").isDigit,r=n("vd7W").TYPE,o=r.Number,a=r.Delim;function s(){this.scanner.skipWS();for(var t=this.consume(o),e=0;e<t.length;e++){var n=t.charCodeAt(e);i(n)||46===n||this.error("Unsigned number is expected",this.scanner.tokenStart-t.length+e)}return 0===Number(t)&&this.error("Zero number is not allowed",this.scanner.tokenStart-t.length),t}t.exports={name:"Ratio",structure:{left:String,right:String},parse:function(){var t,e=this.scanner.tokenStart,n=s.call(this);return this.scanner.skipWS(),this.scanner.isDelim(47)||this.error("Solidus is expected"),this.eat(a),t=s.call(this),{type:"Ratio",loc:this.getLocation(e,this.scanner.tokenStart),left:n,right:t}},generate:function(t){this.chunk(t.left),this.chunk("/"),this.chunk(t.right)}}},FDEy:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.dematerialize=function(){return i.dematerialize()(this)}},FEnK:function(t,e,n){var i=n("vd7W").TYPE,r=i.Semicolon,o=i.LeftCurlyBracket;t.exports={name:"AtrulePrelude",structure:{children:[[]]},parse:function(t){var e=null;return null!==t&&(t=t.toLowerCase()),this.scanner.skipSC(),e=this.atrule.hasOwnProperty(t)&&"function"==typeof this.atrule[t].prelude?this.atrule[t].prelude.call(this):this.readSequence(this.scope.AtrulePrelude),this.scanner.skipSC(),!0!==this.scanner.eof&&this.scanner.tokenType!==o&&this.scanner.tokenType!==r&&this.error("Semicolon or block is expected"),null===e&&(e=this.createList()),{type:"AtrulePrelude",loc:this.getLocationFromList(e),children:e}},generate:function(t){this.children(t)},walkContext:"atrulePrelude"}},FU7m:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");e.Observable=i.Observable,e.Subject=i.Subject;var r=n("w0v+");e.AnonymousSubject=r.AnonymousSubject;var o=n("w0v+");e.config=o.config,n("1JPw"),n("PpQq"),n("sNY3"),n("+v8i"),n("lK5c"),n("XPuz"),n("O5hQ"),n("fnh7"),n("Xj2z"),n("11EI"),n("3Qpg"),n("G4Hi"),n("uGYe"),n("RhlD"),n("mx47"),n("4w9M"),n("8Ip+"),n("BilO"),n("t0XI"),n("HAEL"),n("ojb+"),n("czqU"),n("QXri"),n("cD4w"),n("m1gp"),n("bi34"),n("uO2z"),n("3EiV"),n("vQc4"),n("hf5g"),n("Zw/6"),n("YA+d"),n("1M8x"),n("LxJG"),n("E2OZ"),n("KC9P"),n("Qw2J"),n("37L2"),n("RT2N"),n("9E4K"),n("KGUQ"),n("LOqM"),n("QtPd"),n("DWF9"),n("n2g9"),n("wfyD"),n("FZ9u"),n("+qxJ"),n("TwXD"),n("BdNY"),n("jIeU"),n("70oK"),n("DNeS"),n("q8yx"),n("hswa"),n("Xs6s"),n("7MrP"),n("sjkp"),n("YwoP"),n("C8tm"),n("wWu8"),n("RFdt"),n("dlYL"),n("ksOG"),n("9HtI"),n("+4/i"),n("Kvnp"),n("89kA"),n("8YE1"),n("Qbza"),n("KVj6"),n("cPnI"),n("P+DX"),n("wGW3"),n("sRqT"),n("eyjB"),n("g0lY"),n("7RDD"),n("+oeQ"),n("DpPw"),n("7+k4"),n("Nh3w"),n("jdlx"),n("aMoL"),n("A+qg"),n("PZgn"),n("l3KV"),n("bUWp"),n("ob0Y"),n("C/AH"),n("W/jz"),n("+psR"),n("eYtX"),n("LUEE"),n("G12B"),n("QJJP"),n("G21R"),n("VSOP"),n("2+DN"),n("EUoG"),n("pe+M"),n("LSkT"),n("5hZ8"),n("9qLK"),n("gSmF"),n("rSqW"),n("okVX"),n("4Wg5"),n("W5YF"),n("oKp4"),n("0ZAG"),n("omlZ"),n("I6kD"),n("JpQp"),n("8Yhr"),n("VlMj"),n("fElF"),n("rqY6"),n("00Es"),n("TMm9"),n("XC4j"),n("ND/j"),n("7N5M"),n("2IC2"),n("bHhB"),n("6IDA"),n("cf52"),n("9Sef"),n("ofYe");var a=n("qCKp");e.Subscription=a.Subscription,e.ReplaySubject=a.ReplaySubject,e.BehaviorSubject=a.BehaviorSubject,e.Notification=a.Notification,e.EmptyError=a.EmptyError,e.ArgumentOutOfRangeError=a.ArgumentOutOfRangeError,e.ObjectUnsubscribedError=a.ObjectUnsubscribedError,e.UnsubscriptionError=a.UnsubscriptionError,e.pipe=a.pipe;var s=n("lYZj");e.TestScheduler=s.TestScheduler;var c=n("qCKp");e.Subscriber=c.Subscriber,e.AsyncSubject=c.AsyncSubject,e.ConnectableObservable=c.ConnectableObservable,e.TimeoutError=c.TimeoutError,e.VirtualTimeScheduler=c.VirtualTimeScheduler;var l=n("laIk");e.AjaxResponse=l.AjaxResponse,e.AjaxError=l.AjaxError,e.AjaxTimeoutError=l.AjaxTimeoutError;var u=n("qCKp"),h=n("w0v+"),d=n("w0v+");e.TimeInterval=d.TimeInterval,e.Timestamp=d.Timestamp;var f=n("kU1M");e.operators=f,e.Scheduler={asap:u.asapScheduler,queue:u.queueScheduler,animationFrame:u.animationFrameScheduler,async:u.asyncScheduler},e.Symbol={rxSubscriber:h.rxSubscriber,observable:h.observable,iterator:h.iterator}},FZ9u:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("vTln");i.Observable.prototype.distinct=r.distinct},Fm6d:function(t,e){var n=function(){};function i(t){return"function"==typeof t?t:n}t.exports=function(t,e,r){var o=n,a=n;if("function"==typeof e?o=e:e&&(o=i(e.enter),a=i(e.leave)),o===n&&a===n)throw new Error("Neither `enter` nor `leave` walker handler is set or both aren't a function");!function t(e){switch(o.call(r,e),e.type){case"Group":e.terms.forEach(t);break;case"Multiplier":t(e.term);break;case"Type":case"Property":case"Keyword":case"AtKeyword":case"Function":case"String":case"Token":case"Comma":break;default:throw new Error("Unknown type: "+e.type)}a.call(r,e)}(t)}},Fzww:function(t,e,n){window,t.exports=function(t){var e={};function n(i){if(e[i])return e[i].exports;var r=e[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=t,n.c=e,n.d=function(t,e,i){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(i,r,(function(e){return t[e]}).bind(null,r));return i},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=0)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AttachAddon=void 0;var i=function(){function t(t,e){this._disposables=[],this._socket=t,this._socket.binaryType="arraybuffer",this._bidirectional=!e||!1!==e.bidirectional}return t.prototype.activate=function(t){var e=this;this._disposables.push(r(this._socket,"message",(function(e){var n=e.data;t.write("string"==typeof n?n:new Uint8Array(n))}))),this._bidirectional&&(this._disposables.push(t.onData((function(t){return e._sendData(t)}))),this._disposables.push(t.onBinary((function(t){return e._sendBinary(t)})))),this._disposables.push(r(this._socket,"close",(function(){return e.dispose()}))),this._disposables.push(r(this._socket,"error",(function(){return e.dispose()})))},t.prototype.dispose=function(){this._disposables.forEach((function(t){return t.dispose()}))},t.prototype._sendData=function(t){1===this._socket.readyState&&this._socket.send(t)},t.prototype._sendBinary=function(t){if(1===this._socket.readyState){for(var e=new Uint8Array(t.length),n=0;n<t.length;++n)e[n]=255&t.charCodeAt(n);this._socket.send(e)}},t}();function r(t,e,n){return t.addEventListener(e,n),{dispose:function(){n&&t.removeEventListener(e,n)}}}e.AttachAddon=i}])},G12B:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("P71F");i.Observable.prototype.sampleTime=r.sampleTime},G21R:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("UE8N");i.Observable.prototype.sequenceEqual=r.sequenceEqual},G4Hi:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.generate=i.generate},"G9/t":function(t,e,n){var i=n("vd7W").TYPE,r=n("4njK").mode,o=i.AtKeyword,a=i.Semicolon,s=i.LeftCurlyBracket,c=i.RightCurlyBracket;function l(t){return this.Raw(t,r.leftCurlyBracketOrSemicolon,!0)}function u(){for(var t,e=1;t=this.scanner.lookupType(e);e++){if(t===c)return!0;if(t===s||t===o)return!1}return!1}t.exports={name:"Atrule",structure:{name:String,prelude:["AtrulePrelude","Raw",null],block:["Block",null]},parse:function(){var t,e,n=this.scanner.tokenStart,i=null,r=null;switch(this.eat(o),e=(t=this.scanner.substrToCursor(n+1)).toLowerCase(),this.scanner.skipSC(),!1===this.scanner.eof&&this.scanner.tokenType!==s&&this.scanner.tokenType!==a&&(this.parseAtrulePrelude?"AtrulePrelude"===(i=this.parseWithFallback(this.AtrulePrelude.bind(this,t),l)).type&&null===i.children.head&&(i=null):i=l.call(this,this.scanner.tokenIndex),this.scanner.skipSC()),this.scanner.tokenType){case a:this.scanner.next();break;case s:r=this.atrule.hasOwnProperty(e)&&"function"==typeof this.atrule[e].block?this.atrule[e].block.call(this):this.Block(u.call(this))}return{type:"Atrule",loc:this.getLocation(n,this.scanner.tokenStart),name:t,prelude:i,block:r}},generate:function(t){this.chunk("@"),this.chunk(t.name),null!==t.prelude&&(this.chunk(" "),this.node(t.prelude)),t.block?this.node(t.block):this.chunk(";")},walkContext:"atrule"}},Gi4w:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("JX7q"),r=n("Ji7U"),o=n("LK+K"),a=n("1OyB"),s=n("vuIU"),c=n("7o/Q");function l(t,e){return function(n){return n.lift(new u(t,e,n))}}var u=function(){function t(e,n,i){Object(a.a)(this,t),this.predicate=e,this.thisArg=n,this.source=i}return Object(s.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new h(t,this.predicate,this.thisArg,this.source))}}]),t}(),h=function(t){Object(r.a)(n,t);var e=Object(o.a)(n);function n(t,r,o,s){var c;return Object(a.a)(this,n),(c=e.call(this,t)).predicate=r,c.thisArg=o,c.source=s,c.index=0,c.thisArg=o||Object(i.a)(c),c}return Object(s.a)(n,[{key:"notifyComplete",value:function(t){this.destination.next(t),this.destination.complete()}},{key:"_next",value:function(t){var e=!1;try{e=this.predicate.call(this.thisArg,t,this.index++,this.source)}catch(n){return void this.destination.error(n)}e||this.notifyComplete(!1)}},{key:"_complete",value:function(){this.notifyComplete(!0)}}]),n}(c.a)},Gqt4:function(t,e,n){"use strict";function i(t){switch(Object.prototype.toString.call(t)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return m(t,Error)}}function r(t){return"[object ErrorEvent]"===Object.prototype.toString.call(t)}function o(t){return"[object DOMError]"===Object.prototype.toString.call(t)}function a(t){return"[object DOMException]"===Object.prototype.toString.call(t)}function s(t){return"[object String]"===Object.prototype.toString.call(t)}function c(t){return null===t||"object"!=typeof t&&"function"!=typeof t}function l(t){return"[object Object]"===Object.prototype.toString.call(t)}function u(t){return"undefined"!=typeof Event&&m(t,Event)}function h(t){return"undefined"!=typeof Element&&m(t,Element)}function d(t){return"[object RegExp]"===Object.prototype.toString.call(t)}function f(t){return Boolean(t&&t.then&&"function"==typeof t.then)}function p(t){return l(t)&&"nativeEvent"in t&&"preventDefault"in t&&"stopPropagation"in t}function m(t,e){try{return t instanceof e}catch(n){return!1}}n.d(e,"d",(function(){return i})),n.d(e,"e",(function(){return r})),n.d(e,"a",(function(){return o})),n.d(e,"b",(function(){return a})),n.d(e,"k",(function(){return s})),n.d(e,"i",(function(){return c})),n.d(e,"h",(function(){return l})),n.d(e,"f",(function(){return u})),n.d(e,"c",(function(){return h})),n.d(e,"j",(function(){return d})),n.d(e,"m",(function(){return f})),n.d(e,"l",(function(){return p})),n.d(e,"g",(function(){return m}))},GsYY:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.distinctUntilChanged=function(t,e){return i.distinctUntilChanged(t,e)(this)}},GyhO:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("LRne"),r=n("0EUg");function o(){return Object(r.a)()(i.a.apply(void 0,arguments))}},"H+DX":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.observeOn=function(t,e){return void 0===e&&(e=0),i.observeOn(t,e)(this)}},HAEL:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.pairs=i.pairs},HDdC:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i=n("1OyB"),r=n("vuIU"),o=n("8Qeq"),a=n("WyKG"),s=n("kJWO"),c=n("mCNh"),l=n("2fFW"),u=function(){var t=function(){function t(e){Object(i.a)(this,t),this._isScalar=!1,e&&(this._subscribe=e)}return Object(r.a)(t,[{key:"lift",value:function(e){var n=new t;return n.source=this,n.operator=e,n}},{key:"subscribe",value:function(t,e,n){var i=this.operator,r=Object(a.a)(t,e,n);if(r.add(i?i.call(r,this.source):this.source||l.a.useDeprecatedSynchronousErrorHandling&&!r.syncErrorThrowable?this._subscribe(r):this._trySubscribe(r)),l.a.useDeprecatedSynchronousErrorHandling&&r.syncErrorThrowable&&(r.syncErrorThrowable=!1,r.syncErrorThrown))throw r.syncErrorValue;return r}},{key:"_trySubscribe",value:function(t){try{return this._subscribe(t)}catch(e){l.a.useDeprecatedSynchronousErrorHandling&&(t.syncErrorThrown=!0,t.syncErrorValue=e),Object(o.a)(t)?t.error(e):console.warn(e)}}},{key:"forEach",value:function(t,e){var n=this;return new(e=h(e))((function(e,i){var r;r=n.subscribe((function(e){try{t(e)}catch(n){i(n),r&&r.unsubscribe()}}),i,e)}))}},{key:"_subscribe",value:function(t){var e=this.source;return e&&e.subscribe(t)}},{key:s.a,value:function(){return this}},{key:"pipe",value:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return 0===e.length?this:Object(c.b)(e)(this)}},{key:"toPromise",value:function(t){var e=this;return new(t=h(t))((function(t,n){var i;e.subscribe((function(t){return i=t}),(function(t){return n(t)}),(function(){return t(i)}))}))}}]),t}();return t.create=function(e){return new t(e)},t}();function h(t){if(t||(t=l.a.Promise||Promise),!t)throw new Error("no Promise impl found");return t}},HHXC:function(t,e){t.exports={name:"Operator",structure:{value:String},parse:function(){var t=this.scanner.tokenStart;return this.scanner.next(),{type:"Operator",loc:this.getLocation(t,this.scanner.tokenStart),value:this.scanner.substrToCursor(t)}},generate:function(t){this.chunk(t.value)}}},HOgr:function(t,e,n){var i=n("vd7W").TYPE.CDO;t.exports={name:"CDO",structure:[],parse:function(){var t=this.scanner.tokenStart;return this.eat(i),{type:"CDO",loc:this.getLocation(t,this.scanner.tokenStart)}},generate:function(){this.chunk("\x3c!--")}}},HjQM:function(t,e,n){"use strict";var i,r=n("OJSY"),o=n("VJNc"),a=n("PTRy"),s=(i=n("uzHG"))&&"object"==typeof i&&"default"in i?i.default:i,c=["webkit","moz","ms","o"],l=function(){if("undefined"==typeof window)return function(){};for(var t=0,e=c.length;t<e&&!window.requestAnimationFrame;++t)window.requestAnimationFrame=window[c[t]+"RequestAnimationFrame"];if(!window.requestAnimationFrame){var n=0;window.requestAnimationFrame=function(t){var e=(new Date).getTime(),i=Math.max(0,16-e-n),r=window.setTimeout((function(){return t(e+i)}),i);return n=e+i,r}}return window.requestAnimationFrame.bind(window)}(),u=function(){if("undefined"==typeof window)return function(){};for(var t=0,e=c.length;t<e&&!window.cancelAnimationFrame;++t)window.cancelAnimationFrame=window[c[t]+"CancelAnimationFrame"]||window[c[t]+"CancelRequestAnimationFrame"];return window.cancelAnimationFrame||(window.cancelAnimationFrame=function(t){window.clearTimeout(t)}),window.cancelAnimationFrame.bind(window)}();function h(t,e){void 0===e&&(e={});var n=this,i=4,c=!1;if("object"!=typeof e.margin){var h=e.margin||-1;this.margin={left:h,right:h,top:h,bottom:h}}else this.margin=e.margin;this.scrollWhenOutside=e.scrollWhenOutside||!1;var f={},p=a.createPointCB(f),m=s(),g=!1;window.addEventListener("mousemove",p,!1),window.addEventListener("touchmove",p,!1),isNaN(e.maxSpeed)||(i=e.maxSpeed),"object"!=typeof i&&(i={left:i,right:i,top:i,bottom:i}),this.autoScroll=r.boolean(e.autoScroll),this.syncMove=r.boolean(e.syncMove,!1),this.destroy=function(e){window.removeEventListener("mousemove",p,!1),window.removeEventListener("touchmove",p,!1),window.removeEventListener("mousedown",C,!1),window.removeEventListener("touchstart",C,!1),window.removeEventListener("mouseup",S,!1),window.removeEventListener("touchend",S,!1),window.removeEventListener("pointerup",S,!1),window.removeEventListener("mouseleave",O,!1),window.removeEventListener("mousemove",T,!1),window.removeEventListener("touchmove",T,!1),window.removeEventListener("scroll",k,!0),t=[],e&&x()},this.add=function(){for(var e=[],n=arguments.length;n--;)e[n]=arguments[n];return o.addElements.apply(void 0,[t].concat(e)),this},this.remove=function(){for(var e=[],n=arguments.length;n--;)e[n]=arguments[n];return o.removeElements.apply(void 0,[t].concat(e))};var v,b,y=null;"[object Array]"!==Object.prototype.toString.call(t)&&(t=[t]),b=t,t=[],b.forEach((function(t){t===window?y=window:n.add(t)})),Object.defineProperties(this,{down:{get:function(){return g}},maxSpeed:{get:function(){return i}},point:{get:function(){return f}},scrolling:{get:function(){return c}}});var _,w=null;function k(e){for(var n=0;n<t.length;n++)if(t[n]===e.target){c=!0;break}c&&l((function(){return c=!1}))}function C(){g=!0}function S(){g=!1,x()}function x(){u(_),u(v)}function O(){g=!1}function M(){for(var e=null,n=0;n<t.length;n++)d(f,t[n])&&(e=t[n]);return e}function T(e){if(n.autoScroll()&&!e.dispatched){var i=e.target,r=document.body;w&&!d(f,w)&&(n.scrollWhenOutside||(w=null)),i&&i.parentNode===r?i=M():(i=function(e){if(!e)return null;if(w===e)return e;if(o.hasElement(t,e))return e;for(;e=e.parentNode;)if(o.hasElement(t,e))return e;return null}(i))||(i=M()),i&&i!==w&&(w=i),y&&(u(v),v=l(E)),w&&(u(_),_=l(P))}}function E(){A(y),u(v),v=l(E)}function P(){w&&(A(w),u(_),_=l(P))}function A(t){var e,i,r=a.getClientRect(t);e=f.x<r.left+n.margin.left?Math.floor(Math.max(-1,(f.x-r.left)/n.margin.left-1)*n.maxSpeed.left):f.x>r.right-n.margin.right?Math.ceil(Math.min(1,(f.x-r.right)/n.margin.right+1)*n.maxSpeed.right):0,i=f.y<r.top+n.margin.top?Math.floor(Math.max(-1,(f.y-r.top)/n.margin.top-1)*n.maxSpeed.top):f.y>r.bottom-n.margin.bottom?Math.ceil(Math.min(1,(f.y-r.bottom)/n.margin.bottom+1)*n.maxSpeed.bottom):0,n.syncMove()&&m.dispatch(t,{pageX:f.pageX+e,pageY:f.pageY+i,clientX:f.x+e,clientY:f.y+i}),setTimeout((function(){i&&function(t,e){t===window?window.scrollTo(t.pageXOffset,t.pageYOffset+e):t.scrollTop+=e}(t,i),e&&function(t,e){t===window?window.scrollTo(t.pageXOffset+e,t.pageYOffset):t.scrollLeft+=e}(t,e)}))}window.addEventListener("mousedown",C,!1),window.addEventListener("touchstart",C,!1),window.addEventListener("mouseup",S,!1),window.addEventListener("touchend",S,!1),window.addEventListener("pointerup",S,!1),window.addEventListener("mousemove",T,!1),window.addEventListener("touchmove",T,!1),window.addEventListener("mouseleave",O,!1),window.addEventListener("scroll",k,!0)}function d(t,e,n){return n?t.y>n.top&&t.y<n.bottom&&t.x>n.left&&t.x<n.right:a.pointInside(t,e)}t.exports=function(t,e){return new h(t,e)}},HrJb:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q");function c(t){return function(e){return e.lift(new l(t,e))}}var l=function(){function t(e,n){Object(o.a)(this,t),this.predicate=e,this.source=n}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new u(t,this.predicate,this.source))}}]),t}(),u=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i,r){var a;return Object(o.a)(this,n),(a=e.call(this,t)).predicate=i,a.source=r,a.count=0,a.index=0,a}return Object(a.a)(n,[{key:"_next",value:function(t){this.predicate?this._tryPredicate(t):this.count++}},{key:"_tryPredicate",value:function(t){var e;try{e=this.predicate(t,this.index++,this.source)}catch(n){return void this.destination.error(n)}e&&this.count++}},{key:"_complete",value:function(){this.destination.next(this.count),this.destination.complete()}}]),n}(s.a)},HvLG:function(t,e,n){var i=n("vd7W").TYPE,r=i.Delim,o=i.Ident,a=i.Dimension,s=i.Percentage,c=i.Number,l=i.Hash,u=i.Colon,h=i.LeftSquareBracket;t.exports={getNode:function(t){switch(this.scanner.tokenType){case h:return this.AttributeSelector();case l:return this.IdSelector();case u:return this.scanner.lookupType(1)===u?this.PseudoElementSelector():this.PseudoClassSelector();case o:return this.TypeSelector();case c:case s:return this.Percentage();case a:46===this.scanner.source.charCodeAt(this.scanner.tokenStart)&&this.error("Identifier is expected",this.scanner.tokenStart+1);break;case r:switch(this.scanner.source.charCodeAt(this.scanner.tokenStart)){case 43:case 62:case 126:return t.space=null,t.ignoreWSAfter=!0,this.Combinator();case 47:return this.Combinator();case 46:return this.ClassSelector();case 42:case 124:return this.TypeSelector();case 35:return this.IdSelector()}}}}},I2ZF:function(t,e){for(var n=[],i=0;i<256;++i)n[i]=(i+256).toString(16).substr(1);t.exports=function(t,e){var i=e||0;return[n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]]].join("")}},I55L:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(t){return t&&"number"==typeof t.length&&"function"!=typeof t}},I6kD:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("QTCG");i.Observable.prototype.takeWhile=r.takeWhile},IMZ1:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.publishBehavior=function(t){return i.publishBehavior(t)(this)}},IUuq:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.combineAll=function(t){return i.combineAll(t)(this)}},IjjT:function(t,e,n){"use strict";n.d(e,"a",(function(){return h}));var i=n("1OyB"),r=n("vuIU"),o=n("JX7q"),a=n("ReuC"),s=n("foSv"),c=n("Ji7U"),l=n("LK+K"),u=n("Y/cZ"),h=function(t){Object(c.a)(n,t);var e=Object(l.a)(n);function n(t){var r,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:u.a.now;return Object(i.a)(this,n),(r=e.call(this,t,(function(){return n.delegate&&n.delegate!==Object(o.a)(r)?n.delegate.now():a()}))).actions=[],r.active=!1,r.scheduled=void 0,r}return Object(r.a)(n,[{key:"schedule",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2?arguments[2]:void 0;return n.delegate&&n.delegate!==this?n.delegate.schedule(t,e,i):Object(a.a)(Object(s.a)(n.prototype),"schedule",this).call(this,t,e,i)}},{key:"flush",value:function(t){var e=this.actions;if(this.active)e.push(t);else{var n;this.active=!0;do{if(n=t.execute(t.state,t.delay))break}while(t=e.shift());if(this.active=!1,n){for(;t=e.shift();)t.unsubscribe();throw n}}}}]),n}(u.a)},Iyun:function(t,e,n){var i=n("vd7W").cmpChar,r=n("vd7W").isDigit,o=n("vd7W").TYPE,a=o.WhiteSpace,s=o.Comment,c=o.Ident,l=o.Number,u=o.Dimension,h=110;function d(t,e){var n=this.scanner.tokenStart+t,i=this.scanner.source.charCodeAt(n);for(43!==i&&45!==i||(e&&this.error("Number sign is not allowed"),n++);n<this.scanner.tokenEnd;n++)r(this.scanner.source.charCodeAt(n))||this.error("Integer is expected",n)}function f(t){return d.call(this,0,t)}function p(t,e){if(!i(this.scanner.source,this.scanner.tokenStart+t,e)){var n="";switch(e){case h:n="N is expected";break;case 45:n="HyphenMinus is expected"}this.error(n,this.scanner.tokenStart+t)}}function m(){for(var t=0,e=0,n=this.scanner.tokenType;n===a||n===s;)n=this.scanner.lookupType(++t);if(n!==l){if(!this.scanner.isDelim(43,t)&&!this.scanner.isDelim(45,t))return null;e=this.scanner.isDelim(43,t)?43:45;do{n=this.scanner.lookupType(++t)}while(n===a||n===s);n!==l&&(this.scanner.skip(t),f.call(this,!0))}return t>0&&this.scanner.skip(t),0===e&&43!==(n=this.scanner.source.charCodeAt(this.scanner.tokenStart))&&45!==n&&this.error("Number sign is expected"),f.call(this,0!==e),45===e?"-"+this.consume(l):this.consume(l)}t.exports={name:"AnPlusB",structure:{a:[String,null],b:[String,null]},parse:function(){var t=this.scanner.tokenStart,e=null,n=null;if(this.scanner.tokenType===l)f.call(this,!1),n=this.consume(l);else if(this.scanner.tokenType===c&&i(this.scanner.source,this.scanner.tokenStart,45))switch(e="-1",p.call(this,1,h),this.scanner.getTokenLength()){case 2:this.scanner.next(),n=m.call(this);break;case 3:p.call(this,2,45),this.scanner.next(),this.scanner.skipSC(),f.call(this,!0),n="-"+this.consume(l);break;default:p.call(this,2,45),d.call(this,3,!0),this.scanner.next(),n=this.scanner.substrToCursor(t+2)}else if(this.scanner.tokenType===c||this.scanner.isDelim(43)&&this.scanner.lookupType(1)===c){var o=0;switch(e="1",this.scanner.isDelim(43)&&(o=1,this.scanner.next()),p.call(this,0,h),this.scanner.getTokenLength()){case 1:this.scanner.next(),n=m.call(this);break;case 2:p.call(this,1,45),this.scanner.next(),this.scanner.skipSC(),f.call(this,!0),n="-"+this.consume(l);break;default:p.call(this,1,45),d.call(this,2,!0),this.scanner.next(),n=this.scanner.substrToCursor(t+o+1)}}else if(this.scanner.tokenType===u){for(var a=this.scanner.source.charCodeAt(this.scanner.tokenStart),s=this.scanner.tokenStart+(o=43===a||45===a);s<this.scanner.tokenEnd&&r(this.scanner.source.charCodeAt(s));s++);s===this.scanner.tokenStart+o&&this.error("Integer is expected",this.scanner.tokenStart+o),p.call(this,s-this.scanner.tokenStart,h),e=this.scanner.source.substring(t,s),s+1===this.scanner.tokenEnd?(this.scanner.next(),n=m.call(this)):(p.call(this,s-this.scanner.tokenStart+1,45),s+2===this.scanner.tokenEnd?(this.scanner.next(),this.scanner.skipSC(),f.call(this,!0),n="-"+this.consume(l)):(d.call(this,s-this.scanner.tokenStart+2,!0),this.scanner.next(),n=this.scanner.substrToCursor(s+1)))}else this.error();return null!==e&&43===e.charCodeAt(0)&&(e=e.substr(1)),null!==n&&43===n.charCodeAt(0)&&(n=n.substr(1)),{type:"AnPlusB",loc:this.getLocation(t,this.scanner.tokenStart),a:e,b:n}},generate:function(t){var e=null!=t.b;null!=t.a?(this.chunk("+1"===t.a?"+n":"1"===t.a?"n":"-1"===t.a?"-n":t.a+"n"),e&&("-"===(e=String(t.b)).charAt(0)||"+"===e.charAt(0)?(this.chunk(e.charAt(0)),this.chunk(e.substr(1))):(this.chunk("+"),this.chunk(e)))):this.chunk(String(t.b))}}},IzEk:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q"),c=n("4I5i"),l=n("EY2u");function u(t){return function(e){return 0===t?Object(l.b)():e.lift(new h(t))}}var h=function(){function t(e){if(Object(o.a)(this,t),this.total=e,this.total<0)throw new c.a}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new d(t,this.total))}}]),t}(),d=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).total=i,r.count=0,r}return Object(a.a)(n,[{key:"_next",value:function(t){var e=this.total,n=++this.count;n<=e&&(this.destination.next(t),n===e&&(this.destination.complete(),this.unsubscribe()))}}]),n}(s.a)},JIr8:function(t,e,n){"use strict";n.d(e,"a",(function(){return d}));var i=n("ReuC"),r=n("foSv"),o=n("Ji7U"),a=n("LK+K"),s=n("1OyB"),c=n("vuIU"),l=n("l7GE"),u=n("51Dv"),h=n("ZUHj");function d(t){return function(e){var n=new f(t),i=e.lift(n);return n.caught=i}}var f=function(){function t(e){Object(s.a)(this,t),this.selector=e}return Object(c.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new p(t,this.selector,this.caught))}}]),t}(),p=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,i,r){var o;return Object(s.a)(this,n),(o=e.call(this,t)).selector=i,o.caught=r,o}return Object(c.a)(n,[{key:"error",value:function(t){if(!this.isStopped){var e;try{e=this.selector(t,this.caught)}catch(s){return void Object(i.a)(Object(r.a)(n.prototype),"error",this).call(this,s)}this._unsubscribeAndRecycle();var o=new u.a(this,void 0,void 0);this.add(o);var a=Object(h.a)(this,e,void 0,void 0,o);a!==o&&this.add(a)}}}]),n}(l.a)},JM0U:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("kU1M");e.auditTime=function(t,e){return void 0===e&&(e=i.asyncScheduler),r.auditTime(t,e)(this)}},JX7q:function(t,e,n){"use strict";function i(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}n.d(e,"a",(function(){return i}))},JX91:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("GyhO"),r=n("z+Ro");function o(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var o=e[e.length-1];return Object(r.a)(o)?(e.pop(),function(t){return Object(i.a)(e,t,o)}):function(t){return Object(i.a)(e,t)}}},Jcck:function(t,e){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");e.encode=function(t){if(0<=t&&t<n.length)return n[t];throw new TypeError("Must be between 0 and 63: "+t)},e.decode=function(t){return 65<=t&&t<=90?t-65:97<=t&&t<=122?t-97+26:48<=t&&t<=57?t-48+52:43==t?62:47==t?63:-1}},Ji7U:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("s4An");function r(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Object(i.a)(t,e)}},JpQp:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("LSSe");i.Observable.prototype.throttle=r.throttle},KC9P:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("ovWV");i.Observable.prototype.concat=r.concat},KGUQ:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("FDEy");i.Observable.prototype.dematerialize=r.dematerialize},KQm4:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("a3WO"),r=n("25BE"),o=n("BsWD");function a(t){return function(t){if(Array.isArray(t))return Object(i.a)(t)}(t)||Object(r.a)(t)||Object(o.a)(t)||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.")}()}},KVj6:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("7065");i.Observable.prototype.max=r.max},KW4y:function(t,e,n){var i=n("4vYp");t.exports={generic:!0,types:i.types,atrules:i.atrules,properties:i.properties,node:n("585i")}},KavO:function(t,e,n){var i=n("Cbry"),r=Object.prototype.hasOwnProperty,o="undefined"!=typeof Map;function a(){this._array=[],this._set=o?new Map:Object.create(null)}a.fromArray=function(t,e){for(var n=new a,i=0,r=t.length;i<r;i++)n.add(t[i],e);return n},a.prototype.size=function(){return o?this._set.size:Object.getOwnPropertyNames(this._set).length},a.prototype.add=function(t,e){var n=o?t:i.toSetString(t),a=o?this.has(t):r.call(this._set,n),s=this._array.length;a&&!e||this._array.push(t),a||(o?this._set.set(t,s):this._set[n]=s)},a.prototype.has=function(t){if(o)return this._set.has(t);var e=i.toSetString(t);return r.call(this._set,e)},a.prototype.indexOf=function(t){if(o){var e=this._set.get(t);if(e>=0)return e}else{var n=i.toSetString(t);if(r.call(this._set,n))return this._set[n]}throw new Error('"'+t+'" is not in the set.')},a.prototype.at=function(t){if(t>=0&&t<this._array.length)return this._array[t];throw new Error("No element indexed by "+t)},a.prototype.toArray=function(){return this._array.slice()},e.ArraySet=a},KcB0:function(t,e,n){var i=n("tZmI"),r={type:"Match"},o={type:"Mismatch"},a={type:"DisallowEmpty"};function s(t,e,n){return e===r&&n===o||t===r&&e===r&&n===r?t:("If"===t.type&&t.else===o&&e===r&&(e=t.then,t=t.match),{type:"If",match:t,then:e,else:n})}function c(t){return t.length>2&&40===t.charCodeAt(t.length-2)&&41===t.charCodeAt(t.length-1)}function l(t){return"Keyword"===t.type||"AtKeyword"===t.type||"Function"===t.type||"Type"===t.type&&c(t.name)}function u(t){if("function"==typeof t)return{type:"Generic",fn:t};switch(t.type){case"Group":var e=function t(e,n,i){switch(e){case" ":for(var a=r,u=n.length-1;u>=0;u--)a=s(f=n[u],a,o);return a;case"|":a=o;var h=null;for(u=n.length-1;u>=0;u--){if(l(f=n[u])&&(null===h&&u>0&&l(n[u-1])&&(a=s({type:"Enum",map:h=Object.create(null)},r,a)),null!==h)){var d=(c(f.name)?f.name.slice(0,-1):f.name).toLowerCase();if(d in h==0){h[d]=f;continue}}h=null,a=s(f,r,a)}return a;case"&&":if(n.length>5)return{type:"MatchOnce",terms:n,all:!0};for(a=o,u=n.length-1;u>=0;u--){var f=n[u];p=n.length>1?t(e,n.filter((function(t){return t!==f})),!1):r,a=s(f,p,a)}return a;case"||":if(n.length>5)return{type:"MatchOnce",terms:n,all:!1};for(a=i?r:o,u=n.length-1;u>=0;u--){var p;f=n[u],p=n.length>1?t(e,n.filter((function(t){return t!==f})),!0):r,a=s(f,p,a)}return a}}(t.combinator,t.terms.map(u),!1);return t.disallowEmpty&&(e=s(e,a,o)),e;case"Multiplier":return function(t){var e=r,n=u(t.term);if(0===t.max)n=s(n,a,o),(e=s(n,null,o)).then=s(r,r,e),t.comma&&(e.then.else=s({type:"Comma",syntax:t},e,o));else for(var i=t.min||1;i<=t.max;i++)t.comma&&e!==r&&(e=s({type:"Comma",syntax:t},e,o)),e=s(n,s(r,r,e),o);if(0===t.min)e=s(r,r,e);else for(i=0;i<t.min-1;i++)t.comma&&e!==r&&(e=s({type:"Comma",syntax:t},e,o)),e=s(n,e,o);return e}(t);case"Type":case"Property":return{type:t.type,name:t.name,syntax:t};case"Keyword":return{type:t.type,name:t.name.toLowerCase(),syntax:t};case"AtKeyword":return{type:t.type,name:"@"+t.name.toLowerCase(),syntax:t};case"Function":return{type:t.type,name:t.name.toLowerCase()+"(",syntax:t};case"String":return 3===t.value.length?{type:"Token",value:t.value.charAt(1),syntax:t}:{type:t.type,value:t.value.substr(1,t.value.length-2).replace(/\\'/g,"'"),syntax:t};case"Token":return{type:t.type,value:t.value,syntax:t};case"Comma":return{type:t.type,syntax:t};default:throw new Error("Unknown node type:",t.type)}}t.exports={MATCH:r,MISMATCH:o,DISALLOW_EMPTY:a,buildMatchGraph:function(t,e){return"string"==typeof t&&(t=i(t)),{type:"MatchGraph",match:u(t),syntax:e||null,source:t}}}},Kj3r:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q"),c=n("D0XW");function l(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:c.a;return function(n){return n.lift(new u(t,e))}}var u=function(){function t(e,n){Object(o.a)(this,t),this.dueTime=e,this.scheduler=n}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new h(t,this.dueTime,this.scheduler))}}]),t}(),h=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i,r){var a;return Object(o.a)(this,n),(a=e.call(this,t)).dueTime=i,a.scheduler=r,a.debouncedSubscription=null,a.lastValue=null,a.hasValue=!1,a}return Object(a.a)(n,[{key:"_next",value:function(t){this.clearDebounce(),this.lastValue=t,this.hasValue=!0,this.add(this.debouncedSubscription=this.scheduler.schedule(d,this.dueTime,this))}},{key:"_complete",value:function(){this.debouncedNext(),this.destination.complete()}},{key:"debouncedNext",value:function(){if(this.clearDebounce(),this.hasValue){var t=this.lastValue;this.lastValue=null,this.hasValue=!1,this.destination.next(t)}}},{key:"clearDebounce",value:function(){var t=this.debouncedSubscription;null!==t&&(this.remove(t),t.unsubscribe(),this.debouncedSubscription=null)}}]),n}(s.a);function d(t){t.debouncedNext()}},KjDf:function(t,e,n){var i=n("Sean"),r=n("vd7W").isBOM,o=function(){this.lines=null,this.columns=null,this.linesAndColumnsComputed=!1};o.prototype={setSource:function(t,e,n,i){this.source=t,this.startOffset=void 0===e?0:e,this.startLine=void 0===n?1:n,this.startColumn=void 0===i?1:i,this.linesAndColumnsComputed=!1},ensureLinesAndColumnsComputed:function(){this.linesAndColumnsComputed||(function(t,e){for(var n=e.length,o=i(t.lines,n),a=t.startLine,s=i(t.columns,n),c=t.startColumn,l=e.length>0?r(e.charCodeAt(0)):0;l<n;l++){var u=e.charCodeAt(l);o[l]=a,s[l]=c++,10!==u&&13!==u&&12!==u||(13===u&&l+1<n&&10===e.charCodeAt(l+1)&&(o[++l]=a,s[l]=c),a++,c=1)}o[l]=a,s[l]=c,t.lines=o,t.columns=s}(this,this.source),this.linesAndColumnsComputed=!0)},getLocation:function(t,e){return this.ensureLinesAndColumnsComputed(),{source:e,offset:this.startOffset+t,line:this.lines[t],column:this.columns[t]}},getLocationRange:function(t,e,n){return this.ensureLinesAndColumnsComputed(),{source:n,start:{offset:this.startOffset+t,line:this.lines[t],column:this.columns[t]},end:{offset:this.startOffset+e,line:this.lines[e],column:this.columns[e]}}}},t.exports=o},Kqap:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q");function c(t,e){var n=!1;return arguments.length>=2&&(n=!0),function(i){return i.lift(new l(t,e,n))}}var l=function(){function t(e,n){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];Object(o.a)(this,t),this.accumulator=e,this.seed=n,this.hasSeed=i}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new u(t,this.accumulator,this.seed,this.hasSeed))}}]),t}(),u=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i,r,a){var s;return Object(o.a)(this,n),(s=e.call(this,t)).accumulator=i,s._seed=r,s.hasSeed=a,s.index=0,s}return Object(a.a)(n,[{key:"_next",value:function(t){if(this.hasSeed)return this._tryNext(t);this.seed=t,this.destination.next(t)}},{key:"_tryNext",value:function(t){var e,n=this.index++;try{e=this.accumulator(this.seed,t,n)}catch(i){this.destination.error(i)}this.seed=e,this.destination.next(e)}},{key:"seed",get:function(){return this._seed},set:function(t){this.hasSeed=!0,this._seed=t}}]),n}(s.a)},KqfI:function(t,e,n){"use strict";function i(){}n.d(e,"a",(function(){return i}))},Kvnp:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("cLIC");i.Observable.prototype.every=r.every},KxFi:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.mergeAll=function(t){return void 0===t&&(t=Number.POSITIVE_INFINITY),i.mergeAll(t)(this)}},"LK+K":function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("foSv"),r=n("2WcH"),o=n("md7G");function a(t){var e=Object(r.a)();return function(){var n,r=Object(i.a)(t);if(e){var a=Object(i.a)(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return Object(o.a)(this,n)}}},LM6Q:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.startWith=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i.startWith.apply(void 0,t)(this)}},LOqM:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("uARb");i.Observable.prototype.debounce=r.debounce},"LOr+":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("kU1M");e.debounceTime=function(t,e){return void 0===e&&(e=i.asyncScheduler),r.debounceTime(t,e)(this)}},LRne:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("z+Ro"),r=n("yCtX"),o=n("jZKg");function a(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var a=e[e.length-1];return Object(i.a)(a)?(e.pop(),Object(o.a)(e,a)):Object(r.a)(e)}},LSSe:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M"),r=n("w0v+");e.throttle=function(t,e){return void 0===e&&(e=r.defaultThrottleConfig),i.throttle(t,e)(this)}},LSkT:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("COpn");i.Observable.prototype.skipLast=r.skipLast},LUEE:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("CVW7");i.Observable.prototype.sample=r.sample},LfHy:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.publishReplay=function(t,e,n,r){return i.publishReplay(t,e,n,r)(this)}},Lhse:function(t,e,n){"use strict";function i(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}n.d(e,"a",(function(){return r}));var r=i()},Lsvf:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.ignoreElements=function(){return i.ignoreElements()(this)}},"Lw+5":function(t,e,n){var i=n("vd7W").TYPE.Comma;t.exports={name:"SelectorList",structure:{children:[["Selector","Raw"]]},parse:function(){for(var t=this.createList();!this.scanner.eof&&(t.push(this.Selector()),this.scanner.tokenType===i);)this.scanner.next();return{type:"SelectorList",loc:this.getLocationFromList(t),children:t}},generate:function(t){this.children(t,(function(){this.chunk(",")}))},walkContext:"selector"}},LxJG:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("IUuq");i.Observable.prototype.combineAll=r.combineAll},M6P7:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e._finally=function(t){return i.finalize(t)(this)}},M6kn:function(t,e,n){},MBAA:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("HDdC"),r=n("quSY"),o=n("Lhse");function a(t,e){if(!t)throw new Error("Iterable cannot be null");return new i.a((function(n){var i,a=new r.a;return a.add((function(){i&&"function"==typeof i.return&&i.return()})),a.add(e.schedule((function(){i=t[o.a](),a.add(e.schedule((function(){if(!n.closed){var t,e;try{var r=i.next();t=r.value,e=r.done}catch(o){return void n.error(o)}e?n.complete():(n.next(t),this.schedule())}})))}))),a}))}},Mw3v:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.pluck=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i.pluck.apply(void 0,t)(this)}},Myac:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.race=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i.race.apply(void 0,t)(this)}},"ND/j":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("Xh4i");i.Observable.prototype.window=r.window},NEMR:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.retryWhen=function(t){return i.retryWhen(t)(this)}},"NHP+":function(t,e,n){"use strict";n.d(e,"a",(function(){return h}));var i=n("1OyB"),r=n("vuIU"),o=n("ReuC"),a=n("foSv"),s=n("Ji7U"),c=n("LK+K"),l=n("XNiG"),u=n("quSY"),h=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(){var t;return Object(i.a)(this,n),(t=e.apply(this,arguments)).value=null,t.hasNext=!1,t.hasCompleted=!1,t}return Object(r.a)(n,[{key:"_subscribe",value:function(t){return this.hasError?(t.error(this.thrownError),u.a.EMPTY):this.hasCompleted&&this.hasNext?(t.next(this.value),t.complete(),u.a.EMPTY):Object(o.a)(Object(a.a)(n.prototype),"_subscribe",this).call(this,t)}},{key:"next",value:function(t){this.hasCompleted||(this.value=t,this.hasNext=!0)}},{key:"error",value:function(t){this.hasCompleted||Object(o.a)(Object(a.a)(n.prototype),"error",this).call(this,t)}},{key:"complete",value:function(){this.hasCompleted=!0,this.hasNext&&Object(o.a)(Object(a.a)(n.prototype),"next",this).call(this,this.value),Object(o.a)(Object(a.a)(n.prototype),"complete",this).call(this)}}]),n}(l.b)},NJ4a:function(t,e,n){"use strict";function i(t){setTimeout((function(){throw t}),0)}n.d(e,"a",(function(){return i}))},NJ9Y:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("sVev"),r=n("pLZG"),o=n("BFxc"),a=n("XDbj"),s=n("xbPD"),c=n("SpAZ");function l(t,e){var n=arguments.length>=2;return function(l){return l.pipe(t?Object(r.a)((function(e,n){return t(e,n,l)})):c.a,Object(o.a)(1),n?Object(s.a)(e):Object(a.a)((function(){return new i.a})))}}},NNCq:function(t,e,n){"use strict";n.d(e,"b",(function(){return r})),n.d(e,"a",(function(){return o}));var i=n("HDdC");function r(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0;return new i.a((function(i){void 0===e&&(e=t,t=0);var r=0,a=t;if(n)return n.schedule(o,0,{index:r,count:e,start:t,subscriber:i});for(;;){if(r++>=e){i.complete();break}if(i.next(a++),i.closed)break}}))}function o(t){var e=t.start,n=t.index,i=t.subscriber;n>=t.count?i.complete():(i.next(e),i.closed||(t.index=n+1,t.start=e+1,this.schedule(t)))}},NXyV:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("HDdC"),r=n("Cfvw"),o=n("EY2u");function a(t){return new i.a((function(e){var n;try{n=t()}catch(i){return void e.error(i)}return(n?Object(r.a)(n):Object(o.b)()).subscribe(e)}))}},Nh3w:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("Y7AG");i.Observable.prototype.partition=r.partition},Nv8m:function(t,e,n){"use strict";n.d(e,"a",(function(){return h}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("DH7j"),c=n("yCtX"),l=n("l7GE"),u=n("ZUHj");function h(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if(1===e.length){if(!Object(s.a)(e[0]))return e[0];e=e[0]}return Object(c.a)(e,void 0).lift(new d)}var d=function(){function t(){Object(o.a)(this,t)}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new f(t))}}]),t}(),f=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t){var i;return Object(o.a)(this,n),(i=e.call(this,t)).hasFirst=!1,i.observables=[],i.subscriptions=[],i}return Object(a.a)(n,[{key:"_next",value:function(t){this.observables.push(t)}},{key:"_complete",value:function(){var t=this.observables,e=t.length;if(0===e)this.destination.complete();else{for(var n=0;n<e&&!this.hasFirst;n++){var i=t[n],r=Object(u.a)(this,i,i,n);this.subscriptions&&this.subscriptions.push(r),this.add(r)}this.observables=null}}},{key:"notifyNext",value:function(t,e,n,i,r){if(!this.hasFirst){this.hasFirst=!0;for(var o=0;o<this.subscriptions.length;o++)if(o!==n){var a=this.subscriptions[o];a.unsubscribe(),this.remove(a)}this.subscriptions=null}this.destination.next(e)}}]),n}(l.a)},O36p:function(t,e){function n(t){return{prev:null,next:null,data:t}}function i(t,e,n){var i;return null!==o?(i=o,o=o.cursor,i.prev=e,i.next=n,i.cursor=t.cursor):i={prev:e,next:n,cursor:t.cursor},t.cursor=i,i}function r(t){var e=t.cursor;t.cursor=e.cursor,e.prev=null,e.next=null,e.cursor=o,o=e}var o=null,a=function(){this.cursor=null,this.head=null,this.tail=null};a.createItem=n,a.prototype.createItem=n,a.prototype.updateCursors=function(t,e,n,i){for(var r=this.cursor;null!==r;)r.prev===t&&(r.prev=e),r.next===n&&(r.next=i),r=r.cursor},a.prototype.getSize=function(){for(var t=0,e=this.head;e;)t++,e=e.next;return t},a.prototype.fromArray=function(t){var e=null;this.head=null;for(var i=0;i<t.length;i++){var r=n(t[i]);null!==e?e.next=r:this.head=r,r.prev=e,e=r}return this.tail=e,this},a.prototype.toJSON=a.prototype.toArray=function(){for(var t=this.head,e=[];t;)e.push(t.data),t=t.next;return e},a.prototype.isEmpty=function(){return null===this.head},a.prototype.first=function(){return this.head&&this.head.data},a.prototype.last=function(){return this.tail&&this.tail.data},a.prototype.forEach=a.prototype.each=function(t,e){var n;void 0===e&&(e=this);for(var o=i(this,null,this.head);null!==o.next;)o.next=(n=o.next).next,t.call(e,n.data,n,this);r(this)},a.prototype.forEachRight=a.prototype.eachRight=function(t,e){var n;void 0===e&&(e=this);for(var o=i(this,this.tail,null);null!==o.prev;)o.prev=(n=o.prev).prev,t.call(e,n.data,n,this);r(this)},a.prototype.nextUntil=function(t,e,n){if(null!==t){var o;void 0===n&&(n=this);for(var a=i(this,null,t);null!==a.next&&(a.next=(o=a.next).next,!e.call(n,o.data,o,this)););r(this)}},a.prototype.prevUntil=function(t,e,n){if(null!==t){var o;void 0===n&&(n=this);for(var a=i(this,t,null);null!==a.prev&&(a.prev=(o=a.prev).prev,!e.call(n,o.data,o,this)););r(this)}},a.prototype.some=function(t,e){var n=this.head;for(void 0===e&&(e=this);null!==n;){if(t.call(e,n.data,n,this))return!0;n=n.next}return!1},a.prototype.map=function(t,e){var n=new a,i=this.head;for(void 0===e&&(e=this);null!==i;)n.appendData(t.call(e,i.data,i,this)),i=i.next;return n},a.prototype.filter=function(t,e){var n=new a,i=this.head;for(void 0===e&&(e=this);null!==i;)t.call(e,i.data,i,this)&&n.appendData(i.data),i=i.next;return n},a.prototype.clear=function(){this.head=null,this.tail=null},a.prototype.copy=function(){for(var t=new a,e=this.head;null!==e;)t.insert(n(e.data)),e=e.next;return t},a.prototype.prepend=function(t){return this.updateCursors(null,t,this.head,t),null!==this.head?(this.head.prev=t,t.next=this.head):this.tail=t,this.head=t,this},a.prototype.prependData=function(t){return this.prepend(n(t))},a.prototype.append=function(t){return this.insert(t)},a.prototype.appendData=function(t){return this.insert(n(t))},a.prototype.insert=function(t,e){if(null!=e)if(this.updateCursors(e.prev,t,e,t),null===e.prev){if(this.head!==e)throw new Error("before doesn't belong to list");this.head=t,e.prev=t,t.next=e,this.updateCursors(null,t)}else e.prev.next=t,t.prev=e.prev,e.prev=t,t.next=e;else this.updateCursors(this.tail,t,null,t),null!==this.tail?(this.tail.next=t,t.prev=this.tail):this.head=t,this.tail=t;return this},a.prototype.insertData=function(t,e){return this.insert(n(t),e)},a.prototype.remove=function(t){if(this.updateCursors(t,t.prev,t,t.next),null!==t.prev)t.prev.next=t.next;else{if(this.head!==t)throw new Error("item doesn't belong to list");this.head=t.next}if(null!==t.next)t.next.prev=t.prev;else{if(this.tail!==t)throw new Error("item doesn't belong to list");this.tail=t.prev}return t.prev=null,t.next=null,t},a.prototype.push=function(t){this.insert(n(t))},a.prototype.pop=function(){if(null!==this.tail)return this.remove(this.tail)},a.prototype.unshift=function(t){this.prepend(n(t))},a.prototype.shift=function(){if(null!==this.head)return this.remove(this.head)},a.prototype.prependList=function(t){return this.insertList(t,this.head)},a.prototype.appendList=function(t){return this.insertList(t)},a.prototype.insertList=function(t,e){return null===t.head||(null!=e?(this.updateCursors(e.prev,t.tail,e,t.head),null!==e.prev?(e.prev.next=t.head,t.head.prev=e.prev):this.head=t.head,e.prev=t.tail,t.tail.next=e):(this.updateCursors(this.tail,t.tail,null,t.head),null!==this.tail?(this.tail.next=t.head,t.head.prev=this.tail):this.head=t.head,this.tail=t.tail),t.head=null,t.tail=null),this},a.prototype.replace=function(t,e){"head"in e?this.insertList(e,t):this.insert(e,t),this.remove(t)},t.exports=a},O4y0:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i=n("1OyB"),r=n("vuIU"),o=n("Ji7U"),a=n("LK+K"),s=n("HDdC"),c=n("7Hc7"),l=n("Y7HM"),u=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t){var r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:c.a;return Object(i.a)(this,n),(r=e.call(this)).source=t,r.delayTime=o,r.scheduler=a,(!Object(l.a)(o)||o<0)&&(r.delayTime=0),a&&"function"==typeof a.schedule||(r.scheduler=c.a),r}return Object(r.a)(n,[{key:"_subscribe",value:function(t){return this.scheduler.schedule(n.dispatch,this.delayTime,{source:this.source,subscriber:t})}}],[{key:"create",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:c.a;return new n(t,e,i)}},{key:"dispatch",value:function(t){return this.add(t.source.subscribe(t.subscriber))}}]),n}(s.a)},O5hQ:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.forkJoin=i.forkJoin},OJSY:function(t,e,n){"use strict";function i(t,e){return void 0===t?void 0===e?t:e:t}Object.defineProperty(e,"__esModule",{value:!0}),e.boolean=function(t,e){return"function"==typeof(t=i(t,e))?function(){for(var e=arguments.length,n=Array(e),i=0;i<e;i++)n[i]=arguments[i];return!!t.apply(this,n)}:t?function(){return!0}:function(){return!1}},e.integer=function(t,e){return"function"==typeof(t=i(t,e))?function(){for(var e=arguments.length,n=Array(e),i=0;i<e;i++)n[i]=arguments[i];var r=parseInt(t.apply(this,n),10);return r!=r?0:r}:(t=parseInt(t,10))!=t?function(){return 0}:function(){return t}},e.string=function(t,e){return"function"==typeof(t=i(t,e))?function(){for(var e=arguments.length,n=Array(e),i=0;i<e;i++)n[i]=arguments[i];return""+t.apply(this,n)}:(t=""+t,function(){return t})}},OQgR:function(t,e,n){"use strict";n.d(e,"b",(function(){return f})),n.d(e,"a",(function(){return v}));var i=n("ReuC"),r=n("foSv"),o=n("Ji7U"),a=n("LK+K"),s=n("1OyB"),c=n("vuIU"),l=n("7o/Q"),u=n("quSY"),h=n("HDdC"),d=n("XNiG");function f(t,e,n,i){return function(r){return r.lift(new p(t,e,n,i))}}var p=function(){function t(e,n,i,r){Object(s.a)(this,t),this.keySelector=e,this.elementSelector=n,this.durationSelector=i,this.subjectSelector=r}return Object(c.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new m(t,this.keySelector,this.elementSelector,this.durationSelector,this.subjectSelector))}}]),t}(),m=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,i,r,o,a){var c;return Object(s.a)(this,n),(c=e.call(this,t)).keySelector=i,c.elementSelector=r,c.durationSelector=o,c.subjectSelector=a,c.groups=null,c.attemptedToUnsubscribe=!1,c.count=0,c}return Object(c.a)(n,[{key:"_next",value:function(t){var e;try{e=this.keySelector(t)}catch(n){return void this.error(n)}this._group(t,e)}},{key:"_group",value:function(t,e){var n=this.groups;n||(n=this.groups=new Map);var i,r=n.get(e);if(this.elementSelector)try{i=this.elementSelector(t)}catch(s){this.error(s)}else i=t;if(!r){r=this.subjectSelector?this.subjectSelector():new d.b,n.set(e,r);var o=new v(e,r,this);if(this.destination.next(o),this.durationSelector){var a;try{a=this.durationSelector(new v(e,r))}catch(s){return void this.error(s)}this.add(a.subscribe(new g(e,r,this)))}}r.closed||r.next(i)}},{key:"_error",value:function(t){var e=this.groups;e&&(e.forEach((function(e,n){e.error(t)})),e.clear()),this.destination.error(t)}},{key:"_complete",value:function(){var t=this.groups;t&&(t.forEach((function(t,e){t.complete()})),t.clear()),this.destination.complete()}},{key:"removeGroup",value:function(t){this.groups.delete(t)}},{key:"unsubscribe",value:function(){this.closed||(this.attemptedToUnsubscribe=!0,0===this.count&&Object(i.a)(Object(r.a)(n.prototype),"unsubscribe",this).call(this))}}]),n}(l.a),g=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,i,r){var o;return Object(s.a)(this,n),(o=e.call(this,i)).key=t,o.group=i,o.parent=r,o}return Object(c.a)(n,[{key:"_next",value:function(t){this.complete()}},{key:"_unsubscribe",value:function(){var t=this.parent,e=this.key;this.key=this.parent=null,t&&t.removeGroup(e)}}]),n}(l.a),v=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,i,r){var o;return Object(s.a)(this,n),(o=e.call(this)).key=t,o.groupSubject=i,o.refCountSubscription=r,o}return Object(c.a)(n,[{key:"_subscribe",value:function(t){var e=new u.a,n=this.refCountSubscription,i=this.groupSubject;return n&&!n.closed&&e.add(new b(n)),e.add(i.subscribe(t)),e}}]),n}(h.a),b=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t){var i;return Object(s.a)(this,n),(i=e.call(this)).parent=t,t.count++,i}return Object(c.a)(n,[{key:"unsubscribe",value:function(){var t=this.parent;t.closed||this.closed||(Object(i.a)(Object(r.a)(n.prototype),"unsubscribe",this).call(this),t.count-=1,0===t.count&&t.attemptedToUnsubscribe&&t.unsubscribe())}}]),n}(u.a)},Of7M:function(t,e,n){"use strict";function i(t,e){for(var n=0,i=e.length;n<i;n++)for(var r=e[n],o=Object.getOwnPropertyNames(r.prototype),a=0,s=o.length;a<s;a++){var c=o[a];t.prototype[c]=r.prototype[c]}}n.d(e,"a",(function(){return i}))},OohF:function(t,e,n){var i=n("vd7W").TYPE,r=i.WhiteSpace,o=i.Comment;t.exports=function(t){var e=this.createList(),n=null,i={recognizer:t,space:null,ignoreWS:!1,ignoreWSAfter:!1};for(this.scanner.skipSC();!this.scanner.eof;){switch(this.scanner.tokenType){case o:this.scanner.next();continue;case r:i.ignoreWS?this.scanner.next():i.space=this.WhiteSpace();continue}if(void 0===(n=t.getNode.call(this,i)))break;null!==i.space&&(e.push(i.space),i.space=null),e.push(n),i.ignoreWSAfter?(i.ignoreWSAfter=!1,i.ignoreWS=!0):i.ignoreWS=!1}return e}},OyBZ:function(t,e,n){var i=n("vd7W").TYPE.Ident;t.exports={name:"Identifier",structure:{name:String},parse:function(){return{type:"Identifier",loc:this.getLocation(this.scanner.tokenStart,this.scanner.tokenEnd),name:this.consume(i)}},generate:function(t){this.chunk(t.name)}}},"P+DX":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("KxFi");i.Observable.prototype.mergeAll=r.mergeAll},P2RB:function(t,e){t.exports=function(){this.scanner.skipSC();var t=this.createSingleNodeList(this.IdSelector());return this.scanner.skipSC(),t}},P3uw:function(t,e,n){var i=n("3XNy"),r=i.isDigit,o=i.isHexDigit,a=i.isUppercaseLetter,s=i.isName,c=i.isWhiteSpace,l=i.isValidEscape;function u(t,e){return e<t.length?t.charCodeAt(e):0}function h(t,e,n){return 13===n&&10===u(t,e+1)?2:1}function d(t,e,n){var i=t.charCodeAt(e);return a(i)&&(i|=32),i===n}function f(t,e){for(;e<t.length&&r(t.charCodeAt(e));e++);return e}function p(t,e){if(o(u(t,(e+=2)-1))){for(var n=Math.min(t.length,e+5);e<n&&o(u(t,e));e++);var i=u(t,e);c(i)&&(e+=h(t,e,i))}return e}t.exports={consumeEscaped:p,consumeName:function(t,e){for(;e<t.length;e++){var n=t.charCodeAt(e);if(!s(n)){if(!l(n,u(t,e+1)))break;e=p(t,e)-1}}return e},consumeNumber:function(t,e){var n=t.charCodeAt(e);if(43!==n&&45!==n||(n=t.charCodeAt(e+=1)),r(n)&&(e=f(t,e+1),n=t.charCodeAt(e)),46===n&&r(t.charCodeAt(e+1))&&(n=t.charCodeAt(e+=2),e=f(t,e)),d(t,e,101)){var i=0;45!==(n=t.charCodeAt(e+1))&&43!==n||(i=1,n=t.charCodeAt(e+2)),r(n)&&(e=f(t,e+1+i+1))}return e},consumeBadUrlRemnants:function(t,e){for(;e<t.length;e++){var n=t.charCodeAt(e);if(41===n){e++;break}l(n,u(t,e+1))&&(e=p(t,e))}return e},cmpChar:d,cmpStr:function(t,e,n,i){if(n-e!==i.length)return!1;if(e<0||n>t.length)return!1;for(var r=e;r<n;r++){var o=t.charCodeAt(r),s=i.charCodeAt(r-e);if(a(o)&&(o|=32),o!==s)return!1}return!0},getNewlineLength:h,findWhiteSpaceStart:function(t,e){for(;e>=0&&c(t.charCodeAt(e));e--);return e+1},findWhiteSpaceEnd:function(t,e){for(;e<t.length&&c(t.charCodeAt(e));e++);return e}}},P71F:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("kU1M");e.sampleTime=function(t,e){return void 0===e&&(e=i.asyncScheduler),r.sampleTime(t,e)(this)}},PTRy:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i,r=(i=n("6yRa"))&&"object"==typeof i&&"default"in i?i.default:i;function o(t){if(t===window)return function(){var t={top:{value:0,enumerable:!0},left:{value:0,enumerable:!0},right:{value:window.innerWidth,enumerable:!0},bottom:{value:window.innerHeight,enumerable:!0},width:{value:window.innerWidth,enumerable:!0},height:{value:window.innerHeight,enumerable:!0},x:{value:0,enumerable:!0},y:{value:0,enumerable:!0}};if(Object.create)return Object.create({},t);var e={};return Object.defineProperties(e,t),e}();try{var e=t.getBoundingClientRect();return void 0===e.x&&(e.x=e.left,e.y=e.top),e}catch(n){throw new TypeError("Can't call getBoundingClientRect on "+t)}}e.createPointCB=r,e.getClientRect=o,e.pointInside=function(t,e){var n=o(e);return t.y>n.top&&t.y<n.bottom&&t.x>n.left&&t.x<n.right}},PZgn:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("LfHy");i.Observable.prototype.publishReplay=r.publishReplay},Pd0I:function(t,e,n){var i=n("vd7W").TYPE.Comma;t.exports={name:"MediaQueryList",structure:{children:[["MediaQuery"]]},parse:function(t){var e=this.createList();for(this.scanner.skipSC();!this.scanner.eof&&(e.push(this.MediaQuery(t)),this.scanner.tokenType===i);)this.scanner.next();return{type:"MediaQueryList",loc:this.getLocationFromList(e),children:e}},generate:function(t){this.children(t,(function(){this.chunk(",")}))}}},PpQq:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.bindNodeCallback=i.bindNodeCallback},PqYM:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("HDdC"),r=n("D0XW"),o=n("Y7HM"),a=n("z+Ro");function s(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,s=-1;return Object(o.a)(e)?s=Number(e)<1?1:Number(e):Object(a.a)(e)&&(n=e),Object(a.a)(n)||(n=r.a),new i.a((function(e){var i=Object(o.a)(t)?t:+t-n.now();return n.schedule(c,i,{index:0,period:s,subscriber:e})}))}function c(t){var e=t.index,n=t.period,i=t.subscriber;if(i.next(e),!i.closed){if(-1===n)return i.complete();t.index=e+1,this.schedule(t,n)}}},PzWj:function(t,e,n){var i=n("vd7W").TYPE,r=i.Ident,o=i.Function,a=i.Colon,s=i.RightParenthesis;t.exports={name:"PseudoClassSelector",structure:{name:String,children:[["Raw"],null]},parse:function(){var t,e,n=this.scanner.tokenStart,i=null;return this.eat(a),this.scanner.tokenType===o?(e=(t=this.consumeFunctionName()).toLowerCase(),this.pseudo.hasOwnProperty(e)?(this.scanner.skipSC(),i=this.pseudo[e].call(this),this.scanner.skipSC()):(i=this.createList()).push(this.Raw(this.scanner.tokenIndex,null,!1)),this.eat(s)):t=this.consume(r),{type:"PseudoClassSelector",loc:this.getLocation(n,this.scanner.tokenStart),name:t,children:i}},generate:function(t){this.chunk(":"),this.chunk(t.name),null!==t.children&&(this.chunk("("),this.children(t),this.chunk(")"))},walkContext:"function"}},QBsF:function(t,e,n){var i=n("vd7W").TYPE,r=i.Ident,o=i.Number,a=i.Dimension,s=i.LeftParenthesis,c=i.RightParenthesis,l=i.Colon,u=i.Delim;t.exports={name:"MediaFeature",structure:{name:String,value:["Identifier","Number","Dimension","Ratio",null]},parse:function(){var t,e=this.scanner.tokenStart,n=null;if(this.eat(s),this.scanner.skipSC(),t=this.consume(r),this.scanner.skipSC(),this.scanner.tokenType!==c){switch(this.eat(l),this.scanner.skipSC(),this.scanner.tokenType){case o:n=this.lookupNonWSType(1)===u?this.Ratio():this.Number();break;case a:n=this.Dimension();break;case r:n=this.Identifier();break;default:this.error("Number, dimension, ratio or identifier is expected")}this.scanner.skipSC()}return this.eat(c),{type:"MediaFeature",loc:this.getLocation(e,this.scanner.tokenStart),name:t,value:n}},generate:function(t){this.chunk("("),this.chunk(t.name),null!==t.value&&(this.chunk(":"),this.node(t.value)),this.chunk(")")}}},QIAL:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("kJWO");function r(t){return t&&"function"==typeof t[i.a]}},QJJP:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("elu/");i.Observable.prototype.scan=r.scan},QKsE:function(t,e,n){var i=Object.prototype.hasOwnProperty,r=n("KcB0"),o=r.MATCH,a=r.MISMATCH,s=r.DISALLOW_EMPTY,c=n("twQA").TYPE,l=0;function u(t){for(var e=null,n=null,i=t;null!==i;)n=i.prev,i.prev=e,e=i,i=n;return e}function h(t,e){if(t.length!==e.length)return!1;for(var n=0;n<t.length;n++){var i=t.charCodeAt(n);if(i>=65&&i<=90&&(i|=32),i!==e.charCodeAt(n))return!1}return!0}function d(t){return null===t||t.type===c.Comma||t.type===c.Function||t.type===c.LeftParenthesis||t.type===c.LeftSquareBracket||t.type===c.LeftCurlyBracket||t.type===c.Delim}function f(t){return null===t||t.type===c.RightParenthesis||t.type===c.RightSquareBracket||t.type===c.RightCurlyBracket||t.type===c.Delim}function p(t,e,n){function r(){do{O++,x=O<t.length?t[O]:null}while(null!==x&&(x.type===c.WhiteSpace||x.type===c.Comment))}function u(e){var n=O+e;return n<t.length?t[n]:null}function p(t,e){return{nextState:t,matchStack:T,syntaxStack:y,thenStack:_,tokenIndex:O,prev:e}}function m(t){_={nextState:t,matchStack:T,syntaxStack:y,prev:_}}function g(t){w=p(t,w)}function v(){T={type:1,syntax:e.syntax,token:x,prev:T},r(),k=null,O>M&&(M=O)}function b(){T=2===T.type?T.prev:{type:3,syntax:y.syntax,token:T.token,prev:T},y=y.prev}var y=null,_=null,w=null,k=null,C=0,S=null,x=null,O=-1,M=0,T={type:0,syntax:null,token:null,prev:null};for(r();null===S&&++C<15e3;)switch(e.type){case"Match":if(null===_){if(null!==x&&(O!==t.length-1||"\\0"!==x.value&&"\\9"!==x.value)){e=a;break}S="Match";break}if((e=_.nextState)===s){if(_.matchStack===T){e=a;break}e=o}for(;_.syntaxStack!==y;)b();_=_.prev;break;case"Mismatch":if(null!==k&&!1!==k)(null===w||O>w.tokenIndex)&&(w=k,k=!1);else if(null===w){S="Mismatch";break}e=w.nextState,_=w.thenStack,y=w.syntaxStack,T=w.matchStack,x=(O=w.tokenIndex)<t.length?t[O]:null,w=w.prev;break;case"MatchGraph":e=e.match;break;case"If":e.else!==a&&g(e.else),e.then!==o&&m(e.then),e=e.match;break;case"MatchOnce":e={type:"MatchOnceBuffer",syntax:e,index:0,mask:0};break;case"MatchOnceBuffer":var E=e.syntax.terms;if(e.index===E.length){if(0===e.mask||e.syntax.all){e=a;break}e=o;break}if(e.mask===(1<<E.length)-1){e=o;break}for(;e.index<E.length;e.index++){var P=1<<e.index;if(0==(e.mask&P)){g(e),m({type:"AddMatchOnce",syntax:e.syntax,mask:e.mask|P}),e=E[e.index++];break}}break;case"AddMatchOnce":e={type:"MatchOnceBuffer",syntax:e.syntax,index:0,mask:e.mask};break;case"Enum":if(null!==x&&(-1!==(D=x.value.toLowerCase()).indexOf("\\")&&(D=D.replace(/\\[09].*$/,"")),i.call(e.map,D))){e=e.map[D];break}e=a;break;case"Generic":var A=O+Math.floor(e.fn(x,u,null!==y?y.opts:null));if(!isNaN(A)&&A>O){for(;O<A;)v();e=o}else e=a;break;case"Type":case"Property":var j="Type"===e.type?"types":"properties",I=i.call(n,j)?n[j][e.name]:null;if(!I||!I.match)throw new Error("Bad syntax reference: "+("Type"===e.type?"<"+e.name+">":"<'"+e.name+"'>"));if(!1!==k&&null!==x&&"Type"===e.type&&("custom-ident"===e.name&&x.type===c.Ident||"length"===e.name&&"0"===x.value)){null===k&&(k=p(e,w)),e=a;break}y={syntax:e.syntax,opts:e.syntax.opts||null!==y&&y.opts||null,prev:y},T={type:2,syntax:e.syntax,token:T.token,prev:T},e=I.match;break;case"Keyword":var D=e.name;if(null!==x){var R=x.value;if(-1!==R.indexOf("\\")&&(R=R.replace(/\\[09].*$/,"")),h(R,D)){v(),e=o;break}}e=a;break;case"AtKeyword":case"Function":if(null!==x&&h(x.value,e.name)){v(),e=o;break}e=a;break;case"Token":if(null!==x&&x.value===e.value){v(),e=o;break}e=a;break;case"Comma":null!==x&&x.type===c.Comma?d(T.token)?e=a:(v(),e=f(x)?a:o):e=d(T.token)||f(x)?o:a;break;case"String":var L="";for(A=O;A<t.length&&L.length<e.value.length;A++)L+=t[A].value;if(h(L,e.value)){for(;O<A;)v();e=o}else e=a;break;default:throw new Error("Unknown node type: "+e.type)}switch(l+=C,S){case null:console.warn("[csstree-match] BREAK after 15000 iterations"),S="Maximum iteration number exceeded (please fill an issue on https://github.com/csstree/csstree/issues)",T=null;break;case"Match":for(;null!==y;)b();break;default:T=null}return{tokens:t,reason:S,iterations:C,match:T,longestMatch:M}}t.exports={matchAsList:function(t,e,n){var i=p(t,e,n||{});if(null!==i.match){var r=u(i.match).prev;for(i.match=[];null!==r;){switch(r.type){case 0:break;case 2:case 3:i.match.push({type:r.type,syntax:r.syntax});break;default:i.match.push({token:r.token.value,node:r.token.node})}r=r.prev}}return i},matchAsTree:function(t,e,n){var i=p(t,e,n||{});if(null===i.match)return i;var r=i.match,o=i.match={syntax:e.syntax||null,match:[]},a=[o];for(r=u(r).prev;null!==r;){switch(r.type){case 2:o.match.push(o={syntax:r.syntax,match:[]}),a.push(o);break;case 3:a.pop(),o=a[a.length-1];break;default:o.match.push({syntax:r.syntax||null,token:r.token.value,node:r.token.node})}r=r.prev}return i},getTotalIterationCount:function(){return l}}},"QPu+":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.reduce=function(t,e){return arguments.length>=2?i.reduce(t,e)(this):i.reduce(t)(this)}},QTCG:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.takeWhile=function(t){return i.takeWhile(t)(this)}},QXri:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.throw=i.throwError,i.Observable.throwError=i.throwError},Qbza:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("1gRP");i.Observable.prototype.materialize=r.materialize},QsQ4:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.withLatestFrom=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i.withLatestFrom.apply(void 0,t)(this)}},QtPd:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("LOr+");i.Observable.prototype.debounceTime=r.debounceTime},QtvL:function(t,e,n){var i=n("O36p");t.exports=function(t){return{fromPlainObject:function(e){return t(e,{enter:function(t){t.children&&t.children instanceof i==0&&(t.children=(new i).fromArray(t.children))}}),e},toPlainObject:function(e){return t(e,{leave:function(t){t.children&&t.children instanceof i&&(t.children=t.children.toArray())}}),e}}}},Qw2J:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("caIW");i.Observable.prototype.concatAll=r.concatAll},R9As:function(t,e,n){window,t.exports=function(t){var e={};function n(i){if(e[i])return e[i].exports;var r=e[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=t,n.c=e,n.d=function(t,e,i){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(i,r,(function(e){return t[e]}).bind(null,r));return i},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=0)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.FitAddon=void 0;var i=function(){function t(){}return t.prototype.activate=function(t){this._terminal=t},t.prototype.dispose=function(){},t.prototype.fit=function(){var t=this.proposeDimensions();t&&this._terminal&&(this._terminal.rows===t.rows&&this._terminal.cols===t.cols||(this._terminal._core._renderService.clear(),this._terminal.resize(t.cols,t.rows)))},t.prototype.proposeDimensions=function(){if(this._terminal&&this._terminal.element&&this._terminal.element.parentElement){var t=this._terminal._core,e=window.getComputedStyle(this._terminal.element.parentElement),n=parseInt(e.getPropertyValue("height")),i=Math.max(0,parseInt(e.getPropertyValue("width"))),r=window.getComputedStyle(this._terminal.element),o=n-(parseInt(r.getPropertyValue("padding-top"))+parseInt(r.getPropertyValue("padding-bottom"))),a=i-(parseInt(r.getPropertyValue("padding-right"))+parseInt(r.getPropertyValue("padding-left")))-t.viewport.scrollBarWidth;return{cols:Math.max(2,Math.floor(a/t._renderService.dimensions.actualCellWidth)),rows:Math.max(1,Math.floor(o/t._renderService.dimensions.actualCellHeight))}}},t}();e.FitAddon=i}])},RApX:function(t,e){t.exports={parse:function(){return this.createSingleNodeList(this.Identifier())}}},RFdt:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("nueD");i.Observable.prototype.isEmpty=r.isEmpty},RFoL:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.first=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i.first.apply(void 0,t)(this)}},RT2N:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("eUyF");i.Observable.prototype.concatMapTo=r.concatMapTo},RX3l:function(t,e){var n=Object.prototype.toString;t.exports=Array.isArray||function(t){return!!t&&"[object Array]"==n.call(t)}},ReuC:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("foSv");function r(t,e,n){return(r="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=Object(i.a)(t)););return t}(t,e);if(r){var o=Object.getOwnPropertyDescriptor(r,e);return o.get?o.get.call(n):o.value}})(t,e,n||t)}},RhlD:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.interval=i.interval},STE7:function(t,e,n){var i=n("vd7W").TYPE.Ident;function r(){this.scanner.tokenType!==i&&!1===this.scanner.isDelim(42)&&this.error("Identifier or asterisk is expected"),this.scanner.next()}t.exports={name:"TypeSelector",structure:{name:String},parse:function(){var t=this.scanner.tokenStart;return this.scanner.isDelim(124)?(this.scanner.next(),r.call(this)):(r.call(this),this.scanner.isDelim(124)&&(this.scanner.next(),r.call(this))),{type:"TypeSelector",loc:this.getLocation(t,this.scanner.tokenStart),name:this.scanner.substrToCursor(t)}},generate:function(t){this.chunk(t.name)}}},SeVD:function(t,e,n){"use strict";n.d(e,"a",(function(){return d}));var i=n("ngJS"),r=n("a7t3"),o=n("pLzU"),a=n("CRDf"),s=n("I55L"),c=n("c2HN"),l=n("XoHu"),u=n("Lhse"),h=n("kJWO"),d=function(t){if(t&&"function"==typeof t[h.a])return Object(a.a)(t);if(Object(s.a)(t))return Object(i.a)(t);if(Object(c.a)(t))return Object(r.a)(t);if(t&&"function"==typeof t[u.a])return Object(o.a)(t);var e=Object(l.a)(t)?"an invalid object":"'".concat(t,"'"),n="You provided ".concat(e," where a stream was expected.")+" You can provide an Observable, Promise, Array, or Iterable.";throw new TypeError(n)}},Sean:function(t,e){var n="undefined"!=typeof Uint32Array?Uint32Array:Array;t.exports=function(t,e){return null===t||t.length<e?new n(Math.max(e+1024,16384)):t}},"Sj+y":function(t,e,n){"use strict";n.d(e,"g",(function(){return f})),n.d(e,"j",(function(){return p})),n.d(e,"f",(function(){return m})),n.d(e,"k",(function(){return g})),n.d(e,"i",(function(){return v})),n.d(e,"h",(function(){return y})),n.d(e,"b",(function(){return _})),n.d(e,"d",(function(){return w})),n.d(e,"c",(function(){return k})),n.d(e,"a",(function(){return C})),n.d(e,"e",(function(){return x}));var i=n("ReuC"),r=n("foSv"),o=n("1OyB"),a=n("vuIU"),s=n("Ji7U"),c=n("LK+K"),l=n("xJj7"),u=n("HDdC"),h=n("7o/Q"),d=n("lJxs");function f(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return new _({method:"GET",url:t,headers:e})}function p(t,e,n){return new _({method:"POST",url:t,body:e,headers:n})}function m(t,e){return new _({method:"DELETE",url:t,headers:e})}function g(t,e,n){return new _({method:"PUT",url:t,body:e,headers:n})}function v(t,e,n){return new _({method:"PATCH",url:t,body:e,headers:n})}var b=Object(d.a)((function(t,e){return t.response}));function y(t,e){return b(new _({method:"GET",url:t,responseType:"json",headers:e}))}var _=function(){var t=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t){var i;Object(o.a)(this,n),i=e.call(this);var r={async:!0,createXHR:function(){return this.crossDomain?function(){if(l.a.XMLHttpRequest)return new l.a.XMLHttpRequest;if(l.a.XDomainRequest)return new l.a.XDomainRequest;throw new Error("CORS is not supported by your browser")}():function(){if(l.a.XMLHttpRequest)return new l.a.XMLHttpRequest;var t;try{for(var e=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"],n=0;n<3;n++)try{if(new l.a.ActiveXObject(t=e[n]))break}catch(i){}return new l.a.ActiveXObject(t)}catch(i){throw new Error("XMLHttpRequest is not supported by your browser")}}()},crossDomain:!0,withCredentials:!1,headers:{},method:"GET",responseType:"json",timeout:0};if("string"==typeof t)r.url=t;else for(var a in t)t.hasOwnProperty(a)&&(r[a]=t[a]);return i.request=r,i}return Object(a.a)(n,[{key:"_subscribe",value:function(t){return new w(t,this.request)}}]),n}(u.a);return t.create=function(){var e=function(e){return new t(e)};return e.get=f,e.post=p,e.delete=m,e.put=g,e.patch=v,e.getJSON=y,e}(),t}(),w=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,i){var r;Object(o.a)(this,n),(r=e.call(this,t)).request=i,r.done=!1;var a=i.headers=i.headers||{};return i.crossDomain||r.getHeader(a,"X-Requested-With")||(a["X-Requested-With"]="XMLHttpRequest"),r.getHeader(a,"Content-Type")||l.a.FormData&&i.body instanceof l.a.FormData||void 0===i.body||(a["Content-Type"]="application/x-www-form-urlencoded; charset=UTF-8"),i.body=r.serializeBody(i.body,r.getHeader(i.headers,"Content-Type")),r.send(),r}return Object(a.a)(n,[{key:"next",value:function(t){this.done=!0;var e,n=this.xhr,i=this.request,r=this.destination;try{e=new k(t,n,i)}catch(o){return r.error(o)}r.next(e)}},{key:"send",value:function(){var t=this.request,e=this.request,n=e.user,i=e.method,r=e.url,o=e.async,a=e.password,s=e.headers,c=e.body;try{var l=this.xhr=t.createXHR();this.setupEvents(l,t),n?l.open(i,r,o,n,a):l.open(i,r,o),o&&(l.timeout=t.timeout,l.responseType=t.responseType),"withCredentials"in l&&(l.withCredentials=!!t.withCredentials),this.setHeaders(l,s),c?l.send(c):l.send()}catch(u){this.error(u)}}},{key:"serializeBody",value:function(t,e){if(!t||"string"==typeof t)return t;if(l.a.FormData&&t instanceof l.a.FormData)return t;if(e){var n=e.indexOf(";");-1!==n&&(e=e.substring(0,n))}switch(e){case"application/x-www-form-urlencoded":return Object.keys(t).map((function(e){return"".concat(encodeURIComponent(e),"=").concat(encodeURIComponent(t[e]))})).join("&");case"application/json":return JSON.stringify(t);default:return t}}},{key:"setHeaders",value:function(t,e){for(var n in e)e.hasOwnProperty(n)&&t.setRequestHeader(n,e[n])}},{key:"getHeader",value:function(t,e){for(var n in t)if(n.toLowerCase()===e.toLowerCase())return t[n]}},{key:"setupEvents",value:function(t,e){var n,i,r=e.progressSubscriber;function o(t){var e,n=o.subscriber,i=o.progressSubscriber,r=o.request;i&&i.error(t);try{e=new x(this,r)}catch(a){e=a}n.error(e)}function a(t){}function s(t){var e=s.subscriber,n=s.progressSubscriber,i=s.request;if(4===this.readyState){var r=1223===this.status?204:this.status;if(0===r&&(r=("text"===this.responseType?this.response||this.responseText:this.response)?200:0),r<400)n&&n.complete(),e.next(t),e.complete();else{var o;n&&n.error(t);try{o=new C("ajax error "+r,this,i)}catch(a){o=a}e.error(o)}}}t.ontimeout=o,o.request=e,o.subscriber=this,o.progressSubscriber=r,t.upload&&"withCredentials"in t&&(r&&(n=function(t){n.progressSubscriber.next(t)},l.a.XDomainRequest?t.onprogress=n:t.upload.onprogress=n,n.progressSubscriber=r),t.onerror=i=function(t){var e,n=i.progressSubscriber,r=i.subscriber,o=i.request;n&&n.error(t);try{e=new C("ajax error",this,o)}catch(a){e=a}r.error(e)},i.request=e,i.subscriber=this,i.progressSubscriber=r),t.onreadystatechange=a,a.subscriber=this,a.progressSubscriber=r,a.request=e,t.onload=s,s.subscriber=this,s.progressSubscriber=r,s.request=e}},{key:"unsubscribe",value:function(){var t=this.xhr;!this.done&&t&&4!==t.readyState&&"function"==typeof t.abort&&t.abort(),Object(i.a)(Object(r.a)(n.prototype),"unsubscribe",this).call(this)}}]),n}(h.a),k=function t(e,n,i){Object(o.a)(this,t),this.originalEvent=e,this.xhr=n,this.request=i,this.status=n.status,this.responseType=n.responseType||i.responseType,this.response=S(this.responseType,n)},C=function(){function t(t,e,n){return Error.call(this),this.message=t,this.name="AjaxError",this.xhr=e,this.request=n,this.status=e.status,this.responseType=e.responseType||n.responseType,this.response=S(this.responseType,e),this}return t.prototype=Object.create(Error.prototype),t}();function S(t,e){switch(t){case"json":return function(t){return"response"in t?t.responseType?t.response:JSON.parse(t.response||t.responseText||"null"):JSON.parse(t.responseText||"null")}(e);case"xml":return e.responseXML;case"text":default:return"response"in e?e.response:e.responseText}}var x=function(t,e){return C.call(this,"ajax timeout",t,e),this.name="AjaxTimeoutError",this}},SjmF:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.min=function(t){return i.min(t)(this)}},SpAZ:function(t,e,n){"use strict";function i(t){return t}n.d(e,"a",(function(){return i}))},SxV6:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("sVev"),r=n("pLZG"),o=n("IzEk"),a=n("xbPD"),s=n("XDbj"),c=n("SpAZ");function l(t,e){var n=arguments.length>=2;return function(l){return l.pipe(t?Object(r.a)((function(e,n){return t(e,n,l)})):c.a,Object(o.a)(1),n?Object(a.a)(e):Object(s.a)((function(){return new i.a})))}}},T8ZO:function(t,e,n){t.exports=n("EiPP").create(function(){for(var t={},e=0;e<arguments.length;e++){var n=arguments[e];for(var i in n)t[i]=n[i]}return t}(n("KW4y"),n("oYUb"),n("acmg")))},TMm9:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("0c70");i.Observable.prototype.toArray=r.toArray},TefO:function(t,e,n){t.exports={getNode:n("7GzS")}},Tnl3:function(t,e,n){var i=n("vd7W").isHexDigit,r=n("vd7W").cmpChar,o=n("vd7W").TYPE,a=n("vd7W").NAME,s=o.Ident,c=o.Number,l=o.Dimension;function u(t,e){for(var n=this.scanner.tokenStart+t,r=0;n<this.scanner.tokenEnd;n++){var o=this.scanner.source.charCodeAt(n);if(45===o&&e&&0!==r)return 0===u.call(this,t+r+1,!1)&&this.error(),-1;i(o)||this.error(e&&0!==r?"HyphenMinus"+(r<6?" or hex digit":"")+" is expected":r<6?"Hex digit is expected":"Unexpected input",n),++r>6&&this.error("Too many hex digits",n)}return this.scanner.next(),r}function h(t){for(var e=0;this.scanner.isDelim(63);)++e>t&&this.error("Too many question marks"),this.scanner.next()}function d(t){this.scanner.source.charCodeAt(this.scanner.tokenStart)!==t&&this.error(a[t]+" is expected")}function f(){var t=0;return this.scanner.isDelim(43)?(this.scanner.next(),this.scanner.tokenType===s?void((t=u.call(this,0,!0))>0&&h.call(this,6-t)):this.scanner.isDelim(63)?(this.scanner.next(),void h.call(this,5)):void this.error("Hex digit or question mark is expected")):this.scanner.tokenType===c?(d.call(this,43),t=u.call(this,1,!0),this.scanner.isDelim(63)?void h.call(this,6-t):this.scanner.tokenType===l||this.scanner.tokenType===c?(d.call(this,45),void u.call(this,1,!1)):void 0):this.scanner.tokenType===l?(d.call(this,43),void((t=u.call(this,1,!0))>0&&h.call(this,6-t))):void this.error()}t.exports={name:"UnicodeRange",structure:{value:String},parse:function(){var t=this.scanner.tokenStart;return r(this.scanner.source,t,117)||this.error("U is expected"),r(this.scanner.source,t+1,43)||this.error("Plus sign is expected"),this.scanner.next(),f.call(this),{type:"UnicodeRange",loc:this.getLocation(t,this.scanner.tokenStart),value:this.scanner.substrToCursor(t)}},generate:function(t){this.chunk(t.value)}}},TpWx:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.windowCount=function(t,e){return void 0===e&&(e=0),i.windowCount(t,e)(this)}},Tpyv:function(t,e,n){var i=n("vd7W").TYPE.WhiteSpace,r=Object.freeze({type:"WhiteSpace",loc:null,value:" "});t.exports={name:"WhiteSpace",structure:{value:String},parse:function(){return this.eat(i),r},generate:function(t){this.chunk(t.value)}}},TqLU:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.find=function(t,e){return i.find(t,e)(this)}},TwXD:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("7y2s");i.Observable.prototype.distinctUntilKeyChanged=r.distinctUntilKeyChanged},UCR5:function(t,e,n){var i=n("Vywy"),r=n("Cbry"),o=n("KavO").ArraySet,a=n("sQiz").MappingList;function s(t){t||(t={}),this._file=r.getArg(t,"file",null),this._sourceRoot=r.getArg(t,"sourceRoot",null),this._skipValidation=r.getArg(t,"skipValidation",!1),this._sources=new o,this._names=new o,this._mappings=new a,this._sourcesContents=null}s.prototype._version=3,s.fromSourceMap=function(t){var e=t.sourceRoot,n=new s({file:t.file,sourceRoot:e});return t.eachMapping((function(t){var i={generated:{line:t.generatedLine,column:t.generatedColumn}};null!=t.source&&(i.source=t.source,null!=e&&(i.source=r.relative(e,i.source)),i.original={line:t.originalLine,column:t.originalColumn},null!=t.name&&(i.name=t.name)),n.addMapping(i)})),t.sources.forEach((function(i){var o=i;null!==e&&(o=r.relative(e,i)),n._sources.has(o)||n._sources.add(o);var a=t.sourceContentFor(i);null!=a&&n.setSourceContent(i,a)})),n},s.prototype.addMapping=function(t){var e=r.getArg(t,"generated"),n=r.getArg(t,"original",null),i=r.getArg(t,"source",null),o=r.getArg(t,"name",null);this._skipValidation||this._validateMapping(e,n,i,o),null!=i&&(i=String(i),this._sources.has(i)||this._sources.add(i)),null!=o&&(o=String(o),this._names.has(o)||this._names.add(o)),this._mappings.add({generatedLine:e.line,generatedColumn:e.column,originalLine:null!=n&&n.line,originalColumn:null!=n&&n.column,source:i,name:o})},s.prototype.setSourceContent=function(t,e){var n=t;null!=this._sourceRoot&&(n=r.relative(this._sourceRoot,n)),null!=e?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[r.toSetString(n)]=e):this._sourcesContents&&(delete this._sourcesContents[r.toSetString(n)],0===Object.keys(this._sourcesContents).length&&(this._sourcesContents=null))},s.prototype.applySourceMap=function(t,e,n){var i=e;if(null==e){if(null==t.file)throw new Error('SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map\'s "file" property. Both were omitted.');i=t.file}var a=this._sourceRoot;null!=a&&(i=r.relative(a,i));var s=new o,c=new o;this._mappings.unsortedForEach((function(e){if(e.source===i&&null!=e.originalLine){var o=t.originalPositionFor({line:e.originalLine,column:e.originalColumn});null!=o.source&&(e.source=o.source,null!=n&&(e.source=r.join(n,e.source)),null!=a&&(e.source=r.relative(a,e.source)),e.originalLine=o.line,e.originalColumn=o.column,null!=o.name&&(e.name=o.name))}var l=e.source;null==l||s.has(l)||s.add(l);var u=e.name;null==u||c.has(u)||c.add(u)}),this),this._sources=s,this._names=c,t.sources.forEach((function(e){var i=t.sourceContentFor(e);null!=i&&(null!=n&&(e=r.join(n,e)),null!=a&&(e=r.relative(a,e)),this.setSourceContent(e,i))}),this)},s.prototype._validateMapping=function(t,e,n,i){if(e&&"number"!=typeof e.line&&"number"!=typeof e.column)throw new Error("original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.");if((!(t&&"line"in t&&"column"in t&&t.line>0&&t.column>=0)||e||n||i)&&!(t&&"line"in t&&"column"in t&&e&&"line"in e&&"column"in e&&t.line>0&&t.column>=0&&e.line>0&&e.column>=0&&n))throw new Error("Invalid mapping: "+JSON.stringify({generated:t,source:n,original:e,name:i}))},s.prototype._serializeMappings=function(){for(var t,e,n,o,a=0,s=1,c=0,l=0,u=0,h=0,d="",f=this._mappings.toArray(),p=0,m=f.length;p<m;p++){if(t="",(e=f[p]).generatedLine!==s)for(a=0;e.generatedLine!==s;)t+=";",s++;else if(p>0){if(!r.compareByGeneratedPositionsInflated(e,f[p-1]))continue;t+=","}t+=i.encode(e.generatedColumn-a),a=e.generatedColumn,null!=e.source&&(o=this._sources.indexOf(e.source),t+=i.encode(o-h),h=o,t+=i.encode(e.originalLine-1-l),l=e.originalLine-1,t+=i.encode(e.originalColumn-c),c=e.originalColumn,null!=e.name&&(n=this._names.indexOf(e.name),t+=i.encode(n-u),u=n)),d+=t}return d},s.prototype._generateSourcesContent=function(t,e){return t.map((function(t){if(!this._sourcesContents)return null;null!=e&&(t=r.relative(e,t));var n=r.toSetString(t);return Object.prototype.hasOwnProperty.call(this._sourcesContents,n)?this._sourcesContents[n]:null}),this)},s.prototype.toJSON=function(){var t={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return null!=this._file&&(t.file=this._file),null!=this._sourceRoot&&(t.sourceRoot=this._sourceRoot),this._sourcesContents&&(t.sourcesContent=this._generateSourcesContent(t.sources,t.sourceRoot)),t},s.prototype.toString=function(){return JSON.stringify(this.toJSON())},e.SourceMapGenerator=s},UE8N:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.sequenceEqual=function(t,e){return i.sequenceEqual(t,e)(this)}},UGdY:function(t,e,n){var i=n("UCR5").SourceMapGenerator,r={Atrule:!0,Selector:!0,Declaration:!0};t.exports=function(t){var e=new i,n=1,o=0,a={line:1,column:0},s={line:0,column:0},c=!1,l={line:1,column:0},u={generated:l},h=t.node;t.node=function(t){if(t.loc&&t.loc.start&&r.hasOwnProperty(t.type)){var i=t.loc.start.line,d=t.loc.start.column-1;s.line===i&&s.column===d||(s.line=i,s.column=d,a.line=n,a.column=o,c&&(c=!1,a.line===l.line&&a.column===l.column||e.addMapping(u)),c=!0,e.addMapping({source:t.loc.source,original:s,generated:a}))}h.call(this,t),c&&r.hasOwnProperty(t.type)&&(l.line=n,l.column=o)};var d=t.chunk;t.chunk=function(t){for(var e=0;e<t.length;e++)10===t.charCodeAt(e)?(n++,o=0):o++;d(t)};var f=t.result;return t.result=function(){return c&&e.addMapping(u),{css:f(),map:e}},t}},UXun:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("jtHE");function r(t,e,n){var r;return r=t&&"object"==typeof t?t:{bufferSize:t,windowTime:e,refCount:!1,scheduler:n},function(t){return t.lift(function(t){var e,n,r=t.bufferSize,o=void 0===r?Number.POSITIVE_INFINITY:r,a=t.windowTime,s=void 0===a?Number.POSITIVE_INFINITY:a,c=t.refCount,l=t.scheduler,u=0,h=!1,d=!1;return function(t){u++,e&&!h||(h=!1,e=new i.a(o,s,l),n=t.subscribe({next:function(t){e.next(t)},error:function(t){h=!0,e.error(t)},complete:function(){d=!0,n=void 0,e.complete()}}));var r=e.subscribe(this);this.add((function(){u--,r.unsubscribe(),n&&!d&&c&&0===u&&(n.unsubscribe(),n=void 0,e=void 0)}))}}(r))}}},UwDK:function(t,e,n){var i=n("vd7W").TYPE.RightParenthesis;t.exports={name:"Function",structure:{name:String,children:[[]]},parse:function(t,e){var n,r=this.scanner.tokenStart,o=this.consumeFunctionName(),a=o.toLowerCase();return n=e.hasOwnProperty(a)?e[a].call(this,e):t.call(this,e),this.scanner.eof||this.eat(i),{type:"Function",loc:this.getLocation(r,this.scanner.tokenStart),name:o,children:n}},generate:function(t){this.chunk(t.name),this.chunk("("),this.children(t),this.chunk(")")},walkContext:"function"}},VJNc:function(t,e,n){"use strict";function i(t){return t&&"object"==typeof t&&"default"in t?t.default:t}Object.defineProperty(e,"__esModule",{value:!0});var r=i(n("uMIJ")),o=i(n("RX3l")),a=i(n("xijO")),s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol?"symbol":typeof t},c=function(t){return null!=t&&"object"===(void 0===t?"undefined":s(t))&&1===t.nodeType&&"object"===s(t.style)&&"object"===s(t.ownerDocument)};function l(t){if("string"==typeof t)try{return document.querySelector(t)}catch(e){throw e}else if(a(t))return t}function u(t,e){if(e=p(e,!0),!c(e))return-1;for(var n=0;n<t.length;n++)if(t[n]===e)return n;return-1}function h(t,e){return-1!==u(t,e)}function d(t){if(!t)return[];try{return"string"==typeof t?r(document.querySelectorAll(t)):o(t)?t.map(p):void 0===t.length?[p(t)]:r(t,p)}catch(e){throw new Error(e)}}function f(t,e){for(var n=0;n<e.length;n++)h(t,e[n])||t.push(e[n]);return e}function p(t,e){if("string"==typeof t)try{return document.querySelector(t)}catch(n){throw n}if(!c(t)&&!e)throw new TypeError(t+" is not a DOM element.");return t}e.indexOfElement=u,e.hasElement=h,e.domListOf=d,e.concatElementLists=function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];return t.reduce((function(t,e){return e.length?t:t.concat(d(e))}),[])},e.addElements=function(t){for(var e=[],n=arguments.length-1;n-- >0;)e[n]=arguments[n+1];return f(t,e=e.map(p))},e.removeElements=function(t){for(var e=[],n=arguments.length-1;n-- >0;)e[n]=arguments[n+1];return e.map(p).reduce((function(e,n){var i=u(t,n);return-1!==i?e.concat(t.splice(i,1)):e}),[])},e.resolveElement=p,e.select=l,e.selectAll=function(t){return"string"==typeof t?Array.prototype.slice.apply(document.querySelectorAll(t)):o(t)?t.map(l):"length"in t?r(t).map(l):void 0}},VRG1:function(t,e,n){t.exports=n("2pxp")},VRyK:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("HDdC"),r=n("z+Ro"),o=n("bHdf"),a=n("yCtX");function s(){for(var t=Number.POSITIVE_INFINITY,e=null,n=arguments.length,s=new Array(n),c=0;c<n;c++)s[c]=arguments[c];var l=s[s.length-1];return Object(r.a)(l)?(e=s.pop(),s.length>1&&"number"==typeof s[s.length-1]&&(t=s.pop())):"number"==typeof l&&(t=s.pop()),null===e&&1===s.length&&s[0]instanceof i.a?s[0]:Object(o.a)(t)(Object(a.a)(s,e))}},VSOP:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("l4jP");i.Observable.prototype.share=r.share},Vj1t:function(t,e,n){var i=n("vd7W").TYPE,r=i.LeftParenthesis,o=i.RightParenthesis;t.exports={name:"Parentheses",structure:{children:[[]]},parse:function(t,e){var n,i=this.scanner.tokenStart;return this.eat(r),n=t.call(this,e),this.scanner.eof||this.eat(o),{type:"Parentheses",loc:this.getLocation(i,this.scanner.tokenStart),children:n}},generate:function(t){this.chunk("("),this.children(t),this.chunk(")")}}},VlMj:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("bKLx");i.Observable.prototype.timeInterval=r.timeInterval},VmLd:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("w0v+");e.combineLatest=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var n=null;return"function"==typeof t[t.length-1]&&(n=t.pop()),1===t.length&&r.isArray(t[0])&&(t=t[0].slice()),this.lift.call(i.of.apply(void 0,[this].concat(t)),new r.CombineLatestOperator(n))}},Vywy:function(t,e,n){var i=n("Jcck");e.encode=function(t){var e,n="",r=function(t){return t<0?1+(-t<<1):0+(t<<1)}(t);do{e=31&r,(r>>>=5)>0&&(e|=32),n+=i.encode(e)}while(r>0);return n},e.decode=function(t,e,n){var r,o,a,s,c=t.length,l=0,u=0;do{if(e>=c)throw new Error("Expected more digits in base 64 VLQ value.");if(-1===(o=i.decode(t.charCodeAt(e++))))throw new Error("Invalid base64 digit: "+t.charAt(e-1));r=!!(32&o),l+=(o&=31)<<u,u+=5}while(r);n.value=(s=(a=l)>>1,1==(1&a)?-s:s),n.rest=e}},Vzig:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("w0v+"),o=n("kU1M");e.throttleTime=function(t,e,n){return void 0===e&&(e=i.asyncScheduler),void 0===n&&(n=r.defaultThrottleConfig),o.throttleTime(t,e,n)(this)}},"W/jz":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("A5T5");i.Observable.prototype.repeatWhen=r.repeatWhen},W5YF:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("oXC5");i.Observable.prototype.switchMapTo=r.switchMapTo},WMd4:function(t,e,n){"use strict";n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return l}));var i=n("1OyB"),r=n("vuIU"),o=n("EY2u"),a=n("LRne"),s=n("z6cu"),c=function(t){return t.NEXT="N",t.ERROR="E",t.COMPLETE="C",t}({}),l=function(){var t=function(){function t(e,n,r){Object(i.a)(this,t),this.kind=e,this.value=n,this.error=r,this.hasValue="N"===e}return Object(r.a)(t,[{key:"observe",value:function(t){switch(this.kind){case"N":return t.next&&t.next(this.value);case"E":return t.error&&t.error(this.error);case"C":return t.complete&&t.complete()}}},{key:"do",value:function(t,e,n){switch(this.kind){case"N":return t&&t(this.value);case"E":return e&&e(this.error);case"C":return n&&n()}}},{key:"accept",value:function(t,e,n){return t&&"function"==typeof t.next?this.observe(t):this.do(t,e,n)}},{key:"toObservable",value:function(){switch(this.kind){case"N":return Object(a.a)(this.value);case"E":return Object(s.a)(this.error);case"C":return Object(o.b)()}throw new Error("unexpected notification kind value")}}],[{key:"createNext",value:function(e){return void 0!==e?new t("N",e):t.undefinedValueNotification}},{key:"createError",value:function(e){return new t("E",void 0,e)}},{key:"createComplete",value:function(){return t.completeNotification}}]),t}();return t.completeNotification=new t("C"),t.undefinedValueNotification=new t("N",void 0),t}()},WyKG:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("7o/Q"),r=n("2QA8"),o=n("gRHU");function a(t,e,n){if(t){if(t instanceof i.a)return t;if(t[r.a])return t[r.a]()}return t||e||n?new i.a(t,e,n):new i.a(o.a)}},XC4j:function(t,e){},XDL1:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.elementAt=function(t,e){return i.elementAt.apply(void 0,arguments)(this)}},XDbj:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("sVev"),c=n("7o/Q");function l(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d;return function(e){return e.lift(new u(t))}}var u=function(){function t(e){Object(o.a)(this,t),this.errorFactory=e}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new h(t,this.errorFactory))}}]),t}(),h=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).errorFactory=i,r.hasValue=!1,r}return Object(a.a)(n,[{key:"_next",value:function(t){this.hasValue=!0,this.destination.next(t)}},{key:"_complete",value:function(){if(this.hasValue)return this.destination.complete();var t;try{t=this.errorFactory()}catch(e){t=e}this.destination.error(t)}}]),n}(c.a);function d(){return new s.a}},XDwu:function(t,e){t.exports=function(t,e){var n=Object.create(SyntaxError.prototype),i=new Error;return n.name=t,n.message=e,Object.defineProperty(n,"stack",{get:function(){return(i.stack||"").replace(/^(.+\n){1,3}/,t+": "+e+"\n")}}),n}},XNiG:function(t,e,n){"use strict";n.d(e,"c",(function(){return m})),n.d(e,"b",(function(){return g})),n.d(e,"a",(function(){return v}));var i=n("vuIU"),r=n("ReuC"),o=n("foSv"),a=n("1OyB"),s=n("Ji7U"),c=n("LK+K"),l=n("HDdC"),u=n("7o/Q"),h=n("quSY"),d=n("9ppp"),f=n("Ylt2"),p=n("2QA8"),m=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t){var i;return Object(a.a)(this,n),(i=e.call(this,t)).destination=t,i}return n}(u.a),g=function(){var t=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(){var t;return Object(a.a)(this,n),(t=e.call(this)).observers=[],t.closed=!1,t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return Object(i.a)(n,[{key:p.a,value:function(){return new m(this)}},{key:"lift",value:function(t){var e=new v(this,this);return e.operator=t,e}},{key:"next",value:function(t){if(this.closed)throw new d.a;if(!this.isStopped)for(var e=this.observers,n=e.length,i=e.slice(),r=0;r<n;r++)i[r].next(t)}},{key:"error",value:function(t){if(this.closed)throw new d.a;this.hasError=!0,this.thrownError=t,this.isStopped=!0;for(var e=this.observers,n=e.length,i=e.slice(),r=0;r<n;r++)i[r].error(t);this.observers.length=0}},{key:"complete",value:function(){if(this.closed)throw new d.a;this.isStopped=!0;for(var t=this.observers,e=t.length,n=t.slice(),i=0;i<e;i++)n[i].complete();this.observers.length=0}},{key:"unsubscribe",value:function(){this.isStopped=!0,this.closed=!0,this.observers=null}},{key:"_trySubscribe",value:function(t){if(this.closed)throw new d.a;return Object(r.a)(Object(o.a)(n.prototype),"_trySubscribe",this).call(this,t)}},{key:"_subscribe",value:function(t){if(this.closed)throw new d.a;return this.hasError?(t.error(this.thrownError),h.a.EMPTY):this.isStopped?(t.complete(),h.a.EMPTY):(this.observers.push(t),new f.a(this,t))}},{key:"asObservable",value:function(){var t=new l.a;return t.source=this,t}}]),n}(l.a);return t.create=function(t,e){return new v(t,e)},t}(),v=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,i){var r;return Object(a.a)(this,n),(r=e.call(this)).destination=t,r.source=i,r}return Object(i.a)(n,[{key:"next",value:function(t){var e=this.destination;e&&e.next&&e.next(t)}},{key:"error",value:function(t){var e=this.destination;e&&e.error&&this.destination.error(t)}},{key:"complete",value:function(){var t=this.destination;t&&t.complete&&this.destination.complete()}},{key:"_subscribe",value:function(t){return this.source?this.source.subscribe(t):h.a.EMPTY}}]),n}(g)},XPuz:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.empty=i.empty},Xh4i:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.window=function(t){return i.window(t)(this)}},Xj2z:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.fromEvent=i.fromEvent},Xk39:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e._catch=function(t){return i.catchError(t)(this)}},XoHu:function(t,e,n){"use strict";function i(t){return null!==t&&"object"==typeof t}n.d(e,"a",(function(){return i}))},Xs6s:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("M6P7");i.Observable.prototype.finally=r._finally,i.Observable.prototype._finally=r._finally},"Y+H1":function(t,e,n){var i=n("vd7W").TYPE.Comment;t.exports={name:"Comment",structure:{value:String},parse:function(){var t=this.scanner.tokenStart,e=this.scanner.tokenEnd;return this.eat(i),e-t+2>=2&&42===this.scanner.source.charCodeAt(e-2)&&47===this.scanner.source.charCodeAt(e-1)&&(e-=2),{type:"Comment",loc:this.getLocation(t,this.scanner.tokenStart),value:this.scanner.source.substring(t+2,e)}},generate:function(t){this.chunk("/*"),this.chunk(t.value),this.chunk("*/")}}},"Y/cZ":function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("1OyB"),r=n("vuIU"),o=function(){var t=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.now;Object(i.a)(this,t),this.SchedulerAction=e,this.now=n}return Object(r.a)(t,[{key:"schedule",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2?arguments[2]:void 0;return new this.SchedulerAction(this,t).schedule(n,e)}}]),t}();return t.now=function(){return Date.now()},t}()},Y0sX:function(t,e,n){var i=n("O36p"),r=Object.prototype.hasOwnProperty;function o(t){return"number"==typeof t&&isFinite(t)&&Math.floor(t)===t&&t>=0}function a(t){return Boolean(t)&&o(t.offset)&&o(t.line)&&o(t.column)}function s(t,e){return function(n,o){if(!n||n.constructor!==Object)return o(n,"Type of node should be an Object");for(var s in n){var c=!0;if(!1!==r.call(n,s)){if("type"===s)n.type!==t&&o(n,"Wrong node type `"+n.type+"`, expected `"+t+"`");else if("loc"===s){if(null===n.loc)continue;if(n.loc&&n.loc.constructor===Object)if("string"!=typeof n.loc.source)s+=".source";else if(a(n.loc.start)){if(a(n.loc.end))continue;s+=".end"}else s+=".start";c=!1}else if(e.hasOwnProperty(s)){var l=0;for(c=!1;!c&&l<e[s].length;l++){var u=e[s][l];switch(u){case String:c="string"==typeof n[s];break;case Boolean:c="boolean"==typeof n[s];break;case null:c=null===n[s];break;default:"string"==typeof u?c=n[s]&&n[s].type===u:Array.isArray(u)&&(c=n[s]instanceof i)}}}else o(n,"Unknown field `"+s+"` for "+t+" node type");c||o(n,"Bad value for `"+t+"."+s+"`")}}for(var s in e)r.call(e,s)&&!1===r.call(n,s)&&o(n,"Field `"+t+"."+s+"` is missed")}}function c(t,e){var n=e.structure,i={type:String,loc:!0},o={type:'"'+t+'"'};for(var a in n)if(!1!==r.call(n,a)){for(var c=[],l=i[a]=Array.isArray(n[a])?n[a].slice():[n[a]],u=0;u<l.length;u++){var h=l[u];if(h===String||h===Boolean)c.push(h.name);else if(null===h)c.push("null");else if("string"==typeof h)c.push("<"+h+">");else{if(!Array.isArray(h))throw new Error("Wrong value `"+h+"` in `"+t+"."+a+"` structure definition");c.push("List")}}o[a]=c.join(" | ")}return{docs:o,check:s(t,i)}}t.exports={getStructureFromConfig:function(t){var e={};if(t.node)for(var n in t.node)if(r.call(t.node,n)){var i=t.node[n];if(!i.structure)throw new Error("Missed `structure` field in `"+n+"` node type definition");e[n]=c(n,i)}return e}}},Y6u4:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){function t(){return Error.call(this),this.message="Timeout has occurred",this.name="TimeoutError",this}return t.prototype=Object.create(Error.prototype),t}()},Y7AG:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.partition=function(t,e){return i.partition(t,e)(this)}},Y7HM:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("DH7j");function r(t){return!Object(i.a)(t)&&t-parseFloat(t)+1>=0}},"YA+d":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("cYpg");i.Observable.prototype.bufferWhen=r.bufferWhen},YiA4:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.windowWhen=function(t){return i.windowWhen(t)(this)}},Ylt2:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("1OyB"),r=n("vuIU"),o=n("Ji7U"),a=n("LK+K"),s=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,r){var o;return Object(i.a)(this,n),(o=e.call(this)).subject=t,o.subscriber=r,o.closed=!1,o}return Object(r.a)(n,[{key:"unsubscribe",value:function(){if(!this.closed){this.closed=!0;var t=this.subject,e=t.observers;if(this.subject=null,e&&0!==e.length&&!t.isStopped&&!t.closed){var n=e.indexOf(this.subscriber);-1!==n&&e.splice(n,1)}}}}]),n}(n("quSY").a)},YwoP:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("RFoL");i.Observable.prototype.first=r.first},ZHaO:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.multicast=function(t,e){return i.multicast(t,e)(this)}},ZHpM:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.take=function(t){return i.take(t)(this)}},ZR4w:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.map=function(t,e){return i.map(t,e)(this)}},ZUHj:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("51Dv"),r=n("SeVD"),o=n("HDdC");function a(t,e,n,a){var s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:new i.a(t,n,a);if(!s.closed)return e instanceof o.a?e.subscribe(s):Object(r.a)(e)(s)}},ZVk9:function(t,e,n){var i=n("vd7W").isWhiteSpace,r=n("vd7W").cmpStr,o=n("vd7W").TYPE,a=o.Function,s=o.Url,c=o.RightParenthesis;t.exports={name:"Url",structure:{value:["String","Raw"]},parse:function(){var t,e=this.scanner.tokenStart;switch(this.scanner.tokenType){case s:for(var n=e+4,o=this.scanner.tokenEnd-1;n<o&&i(this.scanner.source.charCodeAt(n));)n++;for(;n<o&&i(this.scanner.source.charCodeAt(o-1));)o--;t={type:"Raw",loc:this.getLocation(n,o),value:this.scanner.source.substring(n,o)},this.eat(s);break;case a:r(this.scanner.source,this.scanner.tokenStart,this.scanner.tokenEnd,"url(")||this.error("Function name must be `url`"),this.eat(a),this.scanner.skipSC(),t=this.String(),this.scanner.skipSC(),this.eat(c);break;default:this.error("Url or Function is expected")}return{type:"Url",loc:this.getLocation(e,this.scanner.tokenStart),value:t}},generate:function(t){this.chunk("url"),this.chunk("("),this.node(t.value),this.chunk(")")}}},"Zw/6":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("BSEn");i.Observable.prototype.bufferToggle=r.bufferToggle},Zy1z:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q");function c(){return function(t){return t.lift(new l)}}var l=function(){function t(){Object(o.a)(this,t)}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new u(t))}}]),t}(),u=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t){var i;return Object(o.a)(this,n),(i=e.call(this,t)).hasPrev=!1,i}return Object(a.a)(n,[{key:"_next",value:function(t){var e;this.hasPrev?e=[this.prev,t]:this.hasPrev=!0,this.prev=t,e&&this.destination.next(e)}}]),n}(s.a)},a3WO:function(t,e,n){"use strict";function i(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,i=new Array(e);n<e;n++)i[n]=t[n];return i}n.d(e,"a",(function(){return i}))},a3y9:function(t,e){t.exports=function(){return this.createSingleNodeList(this.Raw(this.scanner.tokenIndex,null,!1))}},a7t3:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("NJ4a"),r=function(t){return function(e){return t.then((function(t){e.closed||(e.next(t),e.complete())}),(function(t){return e.error(t)})).then(null,i.a),e}}},aMoL:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("jtHT");i.Observable.prototype.publish=r.publish},aP66:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("kU1M");e.timeout=function(t,e){return void 0===e&&(e=i.asyncScheduler),r.timeout(t,e)(this)}},aUQo:function(t,e,n){var i=n("vd7W").TYPE.CDC;t.exports={name:"CDC",structure:[],parse:function(){var t=this.scanner.tokenStart;return this.eat(i),{type:"CDC",loc:this.getLocation(t,this.scanner.tokenStart)}},generate:function(){this.chunk("--\x3e")}}},acmg:function(t,e,n){t.exports={node:n("585i")}},atJV:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.last=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i.last.apply(void 0,t)(this)}},avj0:function(t,e,n){t.exports={dir:n("RApX"),has:n("te+T"),lang:n("zuyY"),matches:n("VRG1"),not:n("wDXs"),"nth-child":n("twrC"),"nth-last-child":n("yJif"),"nth-last-of-type":n("dsX3"),"nth-of-type":n("B3CK"),slotted:n("d/Fg")}},"b/PJ":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.skipUntil=function(t){return i.skipUntil(t)(this)}},bHdf:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("5+tZ"),r=n("SpAZ");function o(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Number.POSITIVE_INFINITY;return Object(i.a)(r.a,t)}},bHhB:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("n6Nf");i.Observable.prototype.windowToggle=r.windowToggle},bKLx:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("kU1M");e.timeInterval=function(t){return void 0===t&&(t=i.asyncScheduler),r.timeInterval(t)(this)}},bOdf:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("5+tZ");function r(t,e){return Object(i.a)(t,e,1)}},bUWp:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("Myac");i.Observable.prototype.race=r.race},"bb3/":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("kU1M");e.timestamp=function(t){return void 0===t&&(t=i.asyncScheduler),r.timestamp(t)(this)}},bcPL:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.onErrorResumeNext=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i.onErrorResumeNext.apply(void 0,t)(this)}},bd5T:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("kU1M");e.delay=function(t,e){return void 0===e&&(e=i.asyncScheduler),r.delay(t,e)(this)}},bgAe:function(t,e,n){var i=n("O36p");t.exports=function t(e){var n={};for(var r in e){var o=e[r];o&&(Array.isArray(o)||o instanceof i?o=o.map(t):o.constructor===Object&&(o=t(o))),n[r]=o}return n}},bi34:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("laIk");i.Observable.ajax=r.ajax},bxbb:function(t,e,n){var i=n("vd7W").TYPE,r=i.String,o=i.Ident,a=i.Url,s=i.Function,c=i.LeftParenthesis;t.exports={parse:{prelude:function(){var t=this.createList();switch(this.scanner.skipSC(),this.scanner.tokenType){case r:t.push(this.String());break;case a:case s:t.push(this.Url());break;default:this.error("String or url() is expected")}return this.lookupNonWSType(0)!==o&&this.lookupNonWSType(0)!==c||(t.push(this.WhiteSpace()),t.push(this.MediaQueryList())),t},block:null}}},c2HN:function(t,e,n){"use strict";function i(t){return!!t&&"function"!=typeof t.subscribe&&"function"==typeof t.then}n.d(e,"a",(function(){return i}))},c7jc:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=1,r=function(){return Promise.resolve()}(),o={};function a(t){return t in o&&(delete o[t],!0)}var s={setImmediate:function(t){var e=i++;return o[e]=!0,r.then((function(){return a(e)&&t()})),e},clearImmediate:function(t){a(t)}}},cD4w:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.timer=i.timer},cLIC:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.every=function(t,e){return i.every(t,e)(this)}},cPnI:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("02G1");i.Observable.prototype.merge=r.merge},cYpg:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.bufferWhen=function(t){return i.bufferWhen(t)(this)}},caIW:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.concatAll=function(){return i.concatAll()(this)}},cf52:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("QsQ4");i.Observable.prototype.withLatestFrom=r.withLatestFrom},ciat:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.audit=function(t){return i.audit(t)(this)}},cp0P:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("KQm4"),r=n("HDdC"),o=n("DH7j"),a=n("lJxs"),s=n("XoHu"),c=n("Cfvw");function l(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if(1===e.length){var r=e[0];if(Object(o.a)(r))return u(r,null);if(Object(s.a)(r)&&Object.getPrototypeOf(r)===Object.prototype){var c=Object.keys(r);return u(c.map((function(t){return r[t]})),c)}}if("function"==typeof e[e.length-1]){var l=e.pop();return u(e=1===e.length&&Object(o.a)(e[0])?e[0]:e,null).pipe(Object(a.a)((function(t){return l.apply(void 0,Object(i.a)(t))})))}return u(e,null)}function u(t,e){return new r.a((function(n){var i=t.length;if(0!==i)for(var r=new Array(i),o=0,a=0,s=function(s){var l=Object(c.a)(t[s]),u=!1;n.add(l.subscribe({next:function(t){u||(u=!0,a++),r[s]=t},error:function(t){return n.error(t)},complete:function(){++o!==i&&u||(a===i&&n.next(e?e.reduce((function(t,e,n){return t[e]=r[n],t}),{}):r),n.complete())}}))},l=0;l<i;l++)s(l);else n.complete()}))}},crnd:function(t,e){function n(t){return Promise.resolve().then((function(){var e=new Error("Cannot find module '"+t+"'");throw e.code="MODULE_NOT_FOUND",e}))}n.keys=function(){return[]},n.resolve=n,t.exports=n,n.id="crnd"},czqU:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.using=i.using},"d/Fg":function(t,e){t.exports={parse:function(){return this.createSingleNodeList(this.Selector())}}},dB5I:function(t,e,n){var i=n("vd7W").TYPE.Hash;t.exports={name:"IdSelector",structure:{name:String},parse:function(){var t=this.scanner.tokenStart;return this.eat(i),{type:"IdSelector",loc:this.getLocation(t,this.scanner.tokenStart),name:this.scanner.substrToCursor(t+1)}},generate:function(t){this.chunk("#"),this.chunk(t.name)}}},dL1u:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.buffer=function(t){return i.buffer(t)(this)}},dlYL:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("ciat");i.Observable.prototype.audit=r.audit},dsX3:function(t,e,n){t.exports=n("lXnc")},dv2O:function(t,e){t.exports={parse:{prelude:function(){return this.createSingleNodeList(this.SelectorList())},block:function(){return this.Block(!0)}}}},e1rG:function(t,e,n){var i=n("vd7W").TYPE,r=n("4njK").mode,o=i.WhiteSpace,a=i.Comment,s=i.Semicolon;function c(t){return this.Raw(t,r.semicolonIncluded,!0)}t.exports={name:"DeclarationList",structure:{children:[["Declaration"]]},parse:function(){for(var t=this.createList();!this.scanner.eof;)switch(this.scanner.tokenType){case o:case a:case s:this.scanner.next();break;default:t.push(this.parseWithFallback(this.Declaration,c))}return{type:"DeclarationList",loc:this.getLocationFromList(t),children:t}},generate:function(t){this.children(t,(function(t){"Declaration"===t.type&&this.chunk(";")}))}}},eAxx:function(t,e){t.exports={parse:{prelude:function(){return this.createSingleNodeList(this.MediaQueryList())},block:function(){return this.Block(!1)}}}},eIep:function(t,e,n){"use strict";n.d(e,"a",(function(){return p}));var i=n("ReuC"),r=n("foSv"),o=n("Ji7U"),a=n("LK+K"),s=n("1OyB"),c=n("vuIU"),l=n("l7GE"),u=n("51Dv"),h=n("ZUHj"),d=n("lJxs"),f=n("Cfvw");function p(t,e){return"function"==typeof e?function(n){return n.pipe(p((function(n,i){return Object(f.a)(t(n,i)).pipe(Object(d.a)((function(t,r){return e(n,t,i,r)})))})))}:function(e){return e.lift(new m(t))}}var m=function(){function t(e){Object(s.a)(this,t),this.project=e}return Object(c.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new g(t,this.project))}}]),t}(),g=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(t,i){var r;return Object(s.a)(this,n),(r=e.call(this,t)).project=i,r.index=0,r}return Object(c.a)(n,[{key:"_next",value:function(t){var e,n=this.index++;try{e=this.project(t,n)}catch(i){return void this.destination.error(i)}this._innerSub(e,t,n)}},{key:"_innerSub",value:function(t,e,n){var i=this.innerSubscription;i&&i.unsubscribe();var r=new u.a(this,e,n),o=this.destination;o.add(r),this.innerSubscription=Object(h.a)(this,t,void 0,void 0,r),this.innerSubscription!==r&&o.add(this.innerSubscription)}},{key:"_complete",value:function(){var t=this.innerSubscription;t&&!t.closed||Object(i.a)(Object(r.a)(n.prototype),"_complete",this).call(this),this.unsubscribe()}},{key:"_unsubscribe",value:function(){this.innerSubscription=null}},{key:"notifyComplete",value:function(t){this.destination.remove(t),this.innerSubscription=null,this.isStopped&&Object(i.a)(Object(r.a)(n.prototype),"_complete",this).call(this)}},{key:"notifyNext",value:function(t,e,n,i,r){this.destination.next(e)}}]),n}(l.a)},eNwd:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i=n("1OyB"),r=n("vuIU"),o=n("ReuC"),a=n("foSv"),s=n("Ji7U"),c=n("LK+K"),l=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,r){var o;return Object(i.a)(this,n),(o=e.call(this,t,r)).scheduler=t,o.work=r,o}return Object(r.a)(n,[{key:"requestAsyncId",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return null!==i&&i>0?Object(o.a)(Object(a.a)(n.prototype),"requestAsyncId",this).call(this,t,e,i):(t.actions.push(this),t.scheduled||(t.scheduled=requestAnimationFrame((function(){return t.flush(null)}))))}},{key:"recycleAsyncId",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(null!==i&&i>0||null===i&&this.delay>0)return Object(o.a)(Object(a.a)(n.prototype),"recycleAsyncId",this).call(this,t,e,i);0===t.actions.length&&(cancelAnimationFrame(e),t.scheduled=void 0)}}]),n}(n("3N8a").a),u=new(function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(){return Object(i.a)(this,n),e.apply(this,arguments)}return Object(r.a)(n,[{key:"flush",value:function(t){this.active=!0,this.scheduled=void 0;var e,n=this.actions,i=-1,r=n.length;t=t||n.shift();do{if(e=t.execute(t.state,t.delay))break}while(++i<r&&(t=n.shift()));if(this.active=!1,e){for(;++i<r&&(t=n.shift());)t.unsubscribe();throw e}}}]),n}(n("IjjT").a))(l)},eUyF:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.concatMapTo=function(t){return i.concatMapTo(t)(this)}},eWth:function(t,e,n){var i=n("q8iP"),r=function(t){this.str=t,this.pos=0};r.prototype={charCodeAt:function(t){return t<this.str.length?this.str.charCodeAt(t):0},charCode:function(){return this.charCodeAt(this.pos)},nextCharCode:function(){return this.charCodeAt(this.pos+1)},nextNonWsCode:function(t){return this.charCodeAt(this.findWsEnd(t))},findWsEnd:function(t){for(;t<this.str.length;t++){var e=this.str.charCodeAt(t);if(13!==e&&10!==e&&12!==e&&32!==e&&9!==e)break}return t},substringToPos:function(t){return this.str.substring(this.pos,this.pos=t)},eat:function(t){this.charCode()!==t&&this.error("Expect `"+String.fromCharCode(t)+"`"),this.pos++},peek:function(){return this.pos<this.str.length?this.str.charAt(this.pos++):""},error:function(t){throw new i(t,this.str,this.pos)}},t.exports=r},eYtX:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("NEMR");i.Observable.prototype.retryWhen=r.retryWhen},"elu/":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.scan=function(t,e){return arguments.length>=2?i.scan(t,e)(this):i.scan(t)(this)}},errG:function(t,e){t.exports={parse:function(){return this.createSingleNodeList(this.Nth(!0))}}},eyjB:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("mQn8");i.Observable.prototype.mergeScan=r.mergeScan},fElF:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("aP66");i.Observable.prototype.timeout=r.timeout},fUwU:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.skip=function(t){return i.skip(t)(this)}},fY5S:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");e.zipProto=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return this.lift.call(i.zip.apply(void 0,[this].concat(t)))}},fmF7:function(t,e,n){t.exports={SyntaxError:n("q8iP"),parse:n("tZmI"),generate:n("vI5D"),walk:n("Fm6d")}},fnh7:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.from=i.from},foSv:function(t,e,n){"use strict";function i(t){return(i=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}n.d(e,"a",(function(){return i}))},g0lY:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("SjmF");i.Observable.prototype.min=r.min},gCdt:function(t,e,n){var i=n("vd7W").TYPE,r=i.LeftSquareBracket,o=i.RightSquareBracket;t.exports={name:"Brackets",structure:{children:[[]]},parse:function(t,e){var n,i=this.scanner.tokenStart;return this.eat(r),n=t.call(this,e),this.scanner.eof||this.eat(o),{type:"Brackets",loc:this.getLocation(i,this.scanner.tokenStart),children:n}},generate:function(t){this.chunk("["),this.children(t),this.chunk("]")}}},gRHU:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("2fFW"),r=n("NJ4a"),o={closed:!0,next:function(t){},error:function(t){if(i.a.useDeprecatedSynchronousErrorHandling)throw t;Object(r.a)(t)},complete:function(){}}},gSmF:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("LM6Q");i.Observable.prototype.startWith=r.startWith},gTGj:function(t,e,n){var i=n("vd7W").TYPE.Ident;t.exports={name:"ClassSelector",structure:{name:String},parse:function(){return this.scanner.isDelim(46)||this.error("Full stop is expected"),this.scanner.next(),{type:"ClassSelector",loc:this.getLocation(this.scanner.tokenStart-1,this.scanner.tokenEnd),name:this.consume(i)}},generate:function(t){this.chunk("."),this.chunk(t.name)}}},gzwt:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.count=function(t){return i.count(t)(this)}},hf5g:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("9xAK");i.Observable.prototype.bufferTime=r.bufferTime},hswa:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("ADT6");i.Observable.prototype.filter=r.filter},iD44:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.mergeMap=function(t,e){return void 0===e&&(e=Number.POSITIVE_INFINITY),i.mergeMap(t,e)(this)}},iKkX:function(t,e,n){"use strict";n.d(e,"b",(function(){return h})),n.d(e,"a",(function(){return d}));var i=n("ReuC"),r=n("foSv"),o=n("1OyB"),a=n("vuIU"),s=n("Ji7U"),c=n("LK+K"),l=n("3N8a"),u=n("IjjT"),h=function(){var t=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.POSITIVE_INFINITY;return Object(o.a)(this,n),(t=e.call(this,i,(function(){return t.frame}))).maxFrames=r,t.frame=0,t.index=-1,t}return Object(a.a)(n,[{key:"flush",value:function(){for(var t,e,n=this.actions,i=this.maxFrames;(e=n[0])&&e.delay<=i&&(n.shift(),this.frame=e.delay,!(t=e.execute(e.state,e.delay))););if(t){for(;e=n.shift();)e.unsubscribe();throw t}}}]),n}(u.a);return t.frameTimeFactor=10,t}(),d=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,i){var r,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.index+=1;return Object(o.a)(this,n),(r=e.call(this,t,i)).scheduler=t,r.work=i,r.index=a,r.active=!0,r.index=t.index=a,r}return Object(a.a)(n,[{key:"schedule",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;if(!this.id)return Object(i.a)(Object(r.a)(n.prototype),"schedule",this).call(this,t,e);this.active=!1;var o=new n(this.scheduler,this.work);return this.add(o),o.schedule(t,e)}},{key:"requestAsyncId",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;this.delay=t.frame+i;var r=t.actions;return r.push(this),r.sort(n.sortActions),!0}},{key:"recycleAsyncId",value:function(t,e){}},{key:"_execute",value:function(t,e){if(!0===this.active)return Object(i.a)(Object(r.a)(n.prototype),"_execute",this).call(this,t,e)}}],[{key:"sortActions",value:function(t,e){return t.delay===e.delay?t.index===e.index?0:t.index>e.index?1:-1:t.delay>e.delay?1:-1}}]),n}(l.a)},imBb:function(t,e,n){var i;!function(r,o,a){if(r){for(var s,c={8:"backspace",9:"tab",13:"enter",16:"shift",17:"ctrl",18:"alt",20:"capslock",27:"esc",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down",45:"ins",46:"del",91:"meta",93:"meta",224:"meta"},l={106:"*",107:"+",109:"-",110:".",111:"/",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},u={"~":"`","!":"1","@":"2","#":"3",$:"4","%":"5","^":"6","&":"7","*":"8","(":"9",")":"0",_:"-","+":"=",":":";",'"':"'","<":",",">":".","?":"/","|":"\\"},h={option:"alt",command:"meta",return:"enter",escape:"esc",plus:"+",mod:/Mac|iPod|iPhone|iPad/.test(navigator.platform)?"meta":"ctrl"},d=1;d<20;++d)c[111+d]="f"+d;for(d=0;d<=9;++d)c[d+96]=d.toString();b.prototype.bind=function(t,e,n){return this._bindMultiple.call(this,t=t instanceof Array?t:[t],e,n),this},b.prototype.unbind=function(t,e){return this.bind.call(this,t,(function(){}),e)},b.prototype.trigger=function(t,e){return this._directMap[t+":"+e]&&this._directMap[t+":"+e]({},t),this},b.prototype.reset=function(){return this._callbacks={},this._directMap={},this},b.prototype.stopCallback=function(t,e){if((" "+e.className+" ").indexOf(" mousetrap ")>-1)return!1;if(function t(e,n){return null!==e&&e!==o&&(e===n||t(e.parentNode,n))}(e,this.target))return!1;if("composedPath"in t&&"function"==typeof t.composedPath){var n=t.composedPath()[0];n!==t.target&&(e=n)}return"INPUT"==e.tagName||"SELECT"==e.tagName||"TEXTAREA"==e.tagName||e.isContentEditable},b.prototype.handleKey=function(){var t=this;return t._handleKey.apply(t,arguments)},b.addKeycodes=function(t){for(var e in t)t.hasOwnProperty(e)&&(c[e]=t[e]);s=null},b.init=function(){var t=b(o);for(var e in t)"_"!==e.charAt(0)&&(b[e]=function(e){return function(){return t[e].apply(t,arguments)}}(e))},b.init(),r.Mousetrap=b,t.exports&&(t.exports=b),void 0===(i=(function(){return b}).call(e,n,e,t))||(t.exports=i)}function f(t,e,n){t.addEventListener?t.addEventListener(e,n,!1):t.attachEvent("on"+e,n)}function p(t){if("keypress"==t.type){var e=String.fromCharCode(t.which);return t.shiftKey||(e=e.toLowerCase()),e}return c[t.which]?c[t.which]:l[t.which]?l[t.which]:String.fromCharCode(t.which).toLowerCase()}function m(t){return"shift"==t||"ctrl"==t||"alt"==t||"meta"==t}function g(t,e,n){return n||(n=function(){if(!s)for(var t in s={},c)t>95&&t<112||c.hasOwnProperty(t)&&(s[c[t]]=t);return s}()[t]?"keydown":"keypress"),"keypress"==n&&e.length&&(n="keydown"),n}function v(t,e){var n,i,r,o=[];for(n=function(t){return"+"===t?["+"]:(t=t.replace(/\+{2}/g,"+plus")).split("+")}(t),r=0;r<n.length;++r)h[i=n[r]]&&(i=h[i]),e&&"keypress"!=e&&u[i]&&(i=u[i],o.push("shift")),m(i)&&o.push(i);return{key:i,modifiers:o,action:e=g(i,o,e)}}function b(t){var e=this;if(t=t||o,!(e instanceof b))return new b(t);e.target=t,e._callbacks={},e._directMap={};var n,i={},r=!1,a=!1,s=!1;function c(t){t=t||{};var e,n=!1;for(e in i)t[e]?n=!0:i[e]=0;n||(s=!1)}function l(t,n,r,o,a,s){var c,l,u,h=[],d=r.type;if(!e._callbacks[t])return[];for("keyup"==d&&m(t)&&(n=[t]),c=0;c<e._callbacks[t].length;++c)l=e._callbacks[t][c],(o||!l.seq||i[l.seq]==l.level)&&d==l.action&&(("keypress"!=d||r.metaKey||r.ctrlKey)&&(u=l.modifiers,n.sort().join(",")!==u.sort().join(","))||((!o&&l.combo==a||o&&l.seq==o&&l.level==s)&&e._callbacks[t].splice(c,1),h.push(l)));return h}function u(t,n,i,r){e.stopCallback(n,n.target||n.srcElement,i,r)||!1===t(n,i)&&(function(t){t.preventDefault?t.preventDefault():t.returnValue=!1}(n),function(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0}(n))}function h(t){"number"!=typeof t.which&&(t.which=t.keyCode);var n=p(t);n&&("keyup"!=t.type||r!==n?e.handleKey(n,function(t){var e=[];return t.shiftKey&&e.push("shift"),t.altKey&&e.push("alt"),t.ctrlKey&&e.push("ctrl"),t.metaKey&&e.push("meta"),e}(t),t):r=!1)}function d(t,o,a,h,f){e._directMap[t+":"+a]=o;var m,g=(t=t.replace(/\s+/g," ")).split(" ");g.length>1?function(t,e,o,a){function l(e){return function(){s=e,++i[t],clearTimeout(n),n=setTimeout(c,1e3)}}function h(e){u(o,e,t),"keyup"!==a&&(r=p(e)),setTimeout(c,10)}i[t]=0;for(var f=0;f<e.length;++f){var m=f+1===e.length?h:l(a||v(e[f+1]).action);d(e[f],m,a,t,f)}}(t,g,o,a):(m=v(t,a),e._callbacks[m.key]=e._callbacks[m.key]||[],l(m.key,m.modifiers,{type:m.action},h,t,f),e._callbacks[m.key][h?"unshift":"push"]({callback:o,modifiers:m.modifiers,action:m.action,seq:h,level:f,combo:t}))}e._handleKey=function(t,e,n){var i,r=l(t,e,n),o={},h=0,d=!1;for(i=0;i<r.length;++i)r[i].seq&&(h=Math.max(h,r[i].level));for(i=0;i<r.length;++i)if(r[i].seq){if(r[i].level!=h)continue;d=!0,o[r[i].seq]=1,u(r[i].callback,n,r[i].combo,r[i].seq)}else d||u(r[i].callback,n,r[i].combo);var f="keypress"==n.type&&a;n.type!=s||m(t)||f||c(o),a=d&&"keydown"==n.type},e._bindMultiple=function(t,e,n){for(var i=0;i<t.length;++i)d(t[i],e,n)},f(t,"keypress",h),f(t,"keydown",h),f(t,"keyup",h)}}("undefined"!=typeof window?window:null,"undefined"!=typeof window?document:null)},"itJ+":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.bufferCount=function(t,e){return void 0===e&&(e=null),i.bufferCount(t,e)(this)}},itXk:function(t,e,n){"use strict";n.d(e,"b",(function(){return f})),n.d(e,"a",(function(){return p}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("z+Ro"),c=n("DH7j"),l=n("l7GE"),u=n("ZUHj"),h=n("yCtX"),d={};function f(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var i=null,r=null;return Object(s.a)(e[e.length-1])&&(r=e.pop()),"function"==typeof e[e.length-1]&&(i=e.pop()),1===e.length&&Object(c.a)(e[0])&&(e=e[0]),Object(h.a)(e,r).lift(new p(i))}var p=function(){function t(e){Object(o.a)(this,t),this.resultSelector=e}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new m(t,this.resultSelector))}}]),t}(),m=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).resultSelector=i,r.active=0,r.values=[],r.observables=[],r}return Object(a.a)(n,[{key:"_next",value:function(t){this.values.push(d),this.observables.push(t)}},{key:"_complete",value:function(){var t=this.observables,e=t.length;if(0===e)this.destination.complete();else{this.active=e,this.toRespond=e;for(var n=0;n<e;n++){var i=t[n];this.add(Object(u.a)(this,i,i,n))}}}},{key:"notifyComplete",value:function(t){0==(this.active-=1)&&this.destination.complete()}},{key:"notifyNext",value:function(t,e,n,i,r){var o=this.values,a=this.toRespond?o[n]===d?--this.toRespond:this.toRespond:0;o[n]=e,0===a&&(this.resultSelector?this._tryResultSelector(o):this.destination.next(o.slice()))}},{key:"_tryResultSelector",value:function(t){var e;try{e=this.resultSelector.apply(this,t)}catch(n){return void this.destination.error(n)}this.destination.next(e)}}]),n}(l.a)},j5kd:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("w0v+"),o=n("kU1M");e.windowTime=function(t){var e=i.asyncScheduler,n=null,a=Number.POSITIVE_INFINITY;return r.isScheduler(arguments[3])&&(e=arguments[3]),r.isScheduler(arguments[2])?e=arguments[2]:r.isNumeric(arguments[2])&&(a=arguments[2]),r.isScheduler(arguments[1])?e=arguments[1]:r.isNumeric(arguments[1])&&(n=arguments[1]),o.windowTime(t,n,a,e)(this)}},jIeU:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("5LO2");i.Observable.prototype.exhaust=r.exhaust},jZKg:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("HDdC"),r=n("quSY");function o(t,e){return new i.a((function(n){var i=new r.a,o=0;return i.add(e.schedule((function(){o!==t.length?(n.next(t[o++]),n.closed||i.add(this.schedule())):n.complete()}))),i}))}},jdlx:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("Mw3v");i.Observable.prototype.pluck=r.pluck},jpu9:function(t,e,n){var i=n("UGdY"),r=Object.prototype.hasOwnProperty;function o(t,e){var n=null;t.children.forEach("function"!=typeof e?this.node:function(t){null!==n&&e.call(this,n),this.node(t),n=t},this)}t.exports=function(t){function e(t){if(!r.call(n,t.type))throw new Error("Unknown node type: "+t.type);n[t.type].call(this,t)}var n={};if(t.node)for(var a in t.node)n[a]=t.node[a].generate;return function(t,n){var r="",a={children:o,node:e,chunk:function(t){r+=t},result:function(){return r}};return n&&("function"==typeof n.decorator&&(a=n.decorator(a)),n.sourceMap&&(a=i(a))),a.node(t),a.result()}}},jtHE:function(t,e,n){"use strict";n.d(e,"a",(function(){return m}));var i=n("1OyB"),r=n("vuIU"),o=n("ReuC"),a=n("foSv"),s=n("Ji7U"),c=n("LK+K"),l=n("XNiG"),u=n("qgXg"),h=n("quSY"),d=n("pxpQ"),f=n("9ppp"),p=n("Ylt2"),m=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(){var t,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Number.POSITIVE_INFINITY,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.POSITIVE_INFINITY,a=arguments.length>2?arguments[2]:void 0;return Object(i.a)(this,n),(t=e.call(this)).scheduler=a,t._events=[],t._infiniteTimeWindow=!1,t._bufferSize=r<1?1:r,t._windowTime=o<1?1:o,o===Number.POSITIVE_INFINITY?(t._infiniteTimeWindow=!0,t.next=t.nextInfiniteTimeWindow):t.next=t.nextTimeWindow,t}return Object(r.a)(n,[{key:"nextInfiniteTimeWindow",value:function(t){var e=this._events;e.push(t),e.length>this._bufferSize&&e.shift(),Object(o.a)(Object(a.a)(n.prototype),"next",this).call(this,t)}},{key:"nextTimeWindow",value:function(t){this._events.push(new g(this._getNow(),t)),this._trimBufferThenGetEvents(),Object(o.a)(Object(a.a)(n.prototype),"next",this).call(this,t)}},{key:"_subscribe",value:function(t){var e,n=this._infiniteTimeWindow,i=n?this._events:this._trimBufferThenGetEvents(),r=this.scheduler,o=i.length;if(this.closed)throw new f.a;if(this.isStopped||this.hasError?e=h.a.EMPTY:(this.observers.push(t),e=new p.a(this,t)),r&&t.add(t=new d.a(t,r)),n)for(var a=0;a<o&&!t.closed;a++)t.next(i[a]);else for(var s=0;s<o&&!t.closed;s++)t.next(i[s].value);return this.hasError?t.error(this.thrownError):this.isStopped&&t.complete(),e}},{key:"_getNow",value:function(){return(this.scheduler||u.a).now()}},{key:"_trimBufferThenGetEvents",value:function(){for(var t=this._getNow(),e=this._bufferSize,n=this._windowTime,i=this._events,r=i.length,o=0;o<r&&!(t-i[o].time<n);)o++;return r>e&&(o=Math.max(o,r-e)),o>0&&i.splice(0,o),i}}]),n}(l.b),g=function t(e,n){Object(i.a)(this,t),this.time=e,this.value=n}},jtHT:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.publish=function(t){return i.publish(t)(this)}},kJWO:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){return"function"==typeof Symbol&&Symbol.observable||"@@observable"}()},kPWa:function(t,e,n){var i=n("P3uw").consumeNumber,r=n("vd7W").TYPE.Percentage;t.exports={name:"Percentage",structure:{value:String},parse:function(){var t=this.scanner.tokenStart,e=i(this.scanner.source,t);return this.eat(r),{type:"Percentage",loc:this.getLocation(t,this.scanner.tokenStart),value:this.scanner.source.substring(t,e)}},generate:function(t){this.chunk(t.value),this.chunk("%")}}},kU1M:function(t,e,n){"use strict";n.r(e),n.d(e,"audit",(function(){return i.a})),n.d(e,"auditTime",(function(){return r.a})),n.d(e,"buffer",(function(){return d})),n.d(e,"bufferCount",(function(){return b})),n.d(e,"bufferTime",(function(){return S})),n.d(e,"bufferToggle",(function(){return j})),n.d(e,"bufferWhen",(function(){return R})),n.d(e,"catchError",(function(){return N.a})),n.d(e,"combineAll",(function(){return H})),n.d(e,"combineLatest",(function(){return q})),n.d(e,"concat",(function(){return W})),n.d(e,"concatAll",(function(){return K.a})),n.d(e,"concatMap",(function(){return X.a})),n.d(e,"concatMapTo",(function(){return Y})),n.d(e,"count",(function(){return Z.a})),n.d(e,"debounce",(function(){return Q})),n.d(e,"debounceTime",(function(){return tt.a})),n.d(e,"defaultIfEmpty",(function(){return et.a})),n.d(e,"delay",(function(){return nt.a})),n.d(e,"delayWhen",(function(){return rt})),n.d(e,"dematerialize",(function(){return lt})),n.d(e,"distinct",(function(){return dt})),n.d(e,"distinctUntilChanged",(function(){return mt.a})),n.d(e,"distinctUntilKeyChanged",(function(){return gt})),n.d(e,"elementAt",(function(){return wt})),n.d(e,"endWith",(function(){return Ct})),n.d(e,"every",(function(){return St.a})),n.d(e,"exhaust",(function(){return xt})),n.d(e,"exhaustMap",(function(){return Pt})),n.d(e,"expand",(function(){return It})),n.d(e,"filter",(function(){return bt.a})),n.d(e,"finalize",(function(){return Lt.a})),n.d(e,"find",(function(){return Ft})),n.d(e,"findIndex",(function(){return Ht})),n.d(e,"first",(function(){return zt.a})),n.d(e,"groupBy",(function(){return Vt.b})),n.d(e,"ignoreElements",(function(){return Ut})),n.d(e,"isEmpty",(function(){return Wt})),n.d(e,"last",(function(){return Yt.a})),n.d(e,"map",(function(){return Et.a})),n.d(e,"mapTo",(function(){return Zt})),n.d(e,"materialize",(function(){return te})),n.d(e,"max",(function(){return se})),n.d(e,"merge",(function(){return le})),n.d(e,"mergeAll",(function(){return ue.a})),n.d(e,"mergeMap",(function(){return he.a})),n.d(e,"flatMap",(function(){return he.a})),n.d(e,"mergeMapTo",(function(){return de})),n.d(e,"mergeScan",(function(){return fe})),n.d(e,"min",(function(){return ge})),n.d(e,"multicast",(function(){return ve.a})),n.d(e,"observeOn",(function(){return be.b})),n.d(e,"onErrorResumeNext",(function(){return ye})),n.d(e,"pairwise",(function(){return ke.a})),n.d(e,"partition",(function(){return Se})),n.d(e,"pluck",(function(){return xe})),n.d(e,"publish",(function(){return Te})),n.d(e,"publishBehavior",(function(){return Pe})),n.d(e,"publishLast",(function(){return je})),n.d(e,"publishReplay",(function(){return De})),n.d(e,"race",(function(){return Le})),n.d(e,"reduce",(function(){return ae})),n.d(e,"repeat",(function(){return Ne})),n.d(e,"repeatWhen",(function(){return ze})),n.d(e,"retry",(function(){return qe})),n.d(e,"retryWhen",(function(){return Ke})),n.d(e,"refCount",(function(){return Ze.a})),n.d(e,"sample",(function(){return Qe})),n.d(e,"sampleTime",(function(){return tn})),n.d(e,"scan",(function(){return ie.a})),n.d(e,"sequenceEqual",(function(){return on})),n.d(e,"share",(function(){return ln.a})),n.d(e,"shareReplay",(function(){return un.a})),n.d(e,"single",(function(){return dn})),n.d(e,"skip",(function(){return mn.a})),n.d(e,"skipLast",(function(){return gn})),n.d(e,"skipUntil",(function(){return yn})),n.d(e,"skipWhile",(function(){return kn})),n.d(e,"startWith",(function(){return xn.a})),n.d(e,"subscribeOn",(function(){return Mn})),n.d(e,"switchAll",(function(){return An})),n.d(e,"switchMap",(function(){return En.a})),n.d(e,"switchMapTo",(function(){return jn})),n.d(e,"take",(function(){return _t.a})),n.d(e,"takeLast",(function(){return re.a})),n.d(e,"takeUntil",(function(){return In.a})),n.d(e,"takeWhile",(function(){return Dn})),n.d(e,"tap",(function(){return Fn.a})),n.d(e,"throttle",(function(){return Nn.b})),n.d(e,"throttleTime",(function(){return Bn})),n.d(e,"throwIfEmpty",(function(){return yt.a})),n.d(e,"timeInterval",(function(){return Un.b})),n.d(e,"timeout",(function(){return Zn})),n.d(e,"timeoutWith",(function(){return Wn})),n.d(e,"timestamp",(function(){return Qn.b})),n.d(e,"toArray",(function(){return Jn})),n.d(e,"window",(function(){return ti})),n.d(e,"windowCount",(function(){return ii})),n.d(e,"windowTime",(function(){return si})),n.d(e,"windowToggle",(function(){return pi})),n.d(e,"windowWhen",(function(){return vi})),n.d(e,"withLatestFrom",(function(){return _i})),n.d(e,"zip",(function(){return Si})),n.d(e,"zipAll",(function(){return xi}));var i=n("tnsW"),r=n("3UWI"),o=n("JX7q"),a=n("Ji7U"),s=n("LK+K"),c=n("1OyB"),l=n("vuIU"),u=n("l7GE"),h=n("ZUHj");function d(t){return function(e){return e.lift(new f(t))}}var f=function(){function t(e){Object(c.a)(this,t),this.closingNotifier=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new p(t,this.closingNotifier))}}]),t}(),p=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).buffer=[],r.add(Object(h.a)(Object(o.a)(r),i)),r}return Object(l.a)(n,[{key:"_next",value:function(t){this.buffer.push(t)}},{key:"notifyNext",value:function(t,e,n,i,r){var o=this.buffer;this.buffer=[],this.destination.next(o)}}]),n}(u.a),m=n("ReuC"),g=n("foSv"),v=n("7o/Q");function b(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return function(n){return n.lift(new y(t,e))}}var y=function(){function t(e,n){Object(c.a)(this,t),this.bufferSize=e,this.startBufferEvery=n,this.subscriberClass=n&&e!==n?w:_}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new this.subscriberClass(t,this.bufferSize,this.startBufferEvery))}}]),t}(),_=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).bufferSize=i,r.buffer=[],r}return Object(l.a)(n,[{key:"_next",value:function(t){var e=this.buffer;e.push(t),e.length==this.bufferSize&&(this.destination.next(e),this.buffer=[])}},{key:"_complete",value:function(){var t=this.buffer;t.length>0&&this.destination.next(t),Object(m.a)(Object(g.a)(n.prototype),"_complete",this).call(this)}}]),n}(v.a),w=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var o;return Object(c.a)(this,n),(o=e.call(this,t)).bufferSize=i,o.startBufferEvery=r,o.buffers=[],o.count=0,o}return Object(l.a)(n,[{key:"_next",value:function(t){var e=this.bufferSize,n=this.startBufferEvery,i=this.buffers,r=this.count;this.count++,r%n==0&&i.push([]);for(var o=i.length;o--;){var a=i[o];a.push(t),a.length===e&&(i.splice(o,1),this.destination.next(a))}}},{key:"_complete",value:function(){for(var t=this.buffers,e=this.destination;t.length>0;){var i=t.shift();i.length>0&&e.next(i)}Object(m.a)(Object(g.a)(n.prototype),"_complete",this).call(this)}}]),n}(v.a),k=n("D0XW"),C=n("z+Ro");function S(t){var e=arguments.length,n=k.a;Object(C.a)(arguments[arguments.length-1])&&(n=arguments[arguments.length-1],e--);var i=null;e>=2&&(i=arguments[1]);var r=Number.POSITIVE_INFINITY;return e>=3&&(r=arguments[2]),function(e){return e.lift(new x(t,i,r,n))}}var x=function(){function t(e,n,i,r){Object(c.a)(this,t),this.bufferTimeSpan=e,this.bufferCreationInterval=n,this.maxBufferSize=i,this.scheduler=r}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new M(t,this.bufferTimeSpan,this.bufferCreationInterval,this.maxBufferSize,this.scheduler))}}]),t}(),O=function t(){Object(c.a)(this,t),this.buffer=[]},M=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r,a,s){var l;Object(c.a)(this,n),(l=e.call(this,t)).bufferTimeSpan=i,l.bufferCreationInterval=r,l.maxBufferSize=a,l.scheduler=s,l.contexts=[];var u=l.openContext();if(l.timespanOnly=null==r||r<0,l.timespanOnly){var h={subscriber:Object(o.a)(l),context:u,bufferTimeSpan:i};l.add(u.closeAction=s.schedule(T,i,h))}else{var d={subscriber:Object(o.a)(l),context:u},f={bufferTimeSpan:i,bufferCreationInterval:r,subscriber:Object(o.a)(l),scheduler:s};l.add(u.closeAction=s.schedule(P,i,d)),l.add(s.schedule(E,r,f))}return l}return Object(l.a)(n,[{key:"_next",value:function(t){for(var e,n=this.contexts,i=n.length,r=0;r<i;r++){var o=n[r],a=o.buffer;a.push(t),a.length==this.maxBufferSize&&(e=o)}e&&this.onBufferFull(e)}},{key:"_error",value:function(t){this.contexts.length=0,Object(m.a)(Object(g.a)(n.prototype),"_error",this).call(this,t)}},{key:"_complete",value:function(){for(var t=this.contexts,e=this.destination;t.length>0;){var i=t.shift();e.next(i.buffer)}Object(m.a)(Object(g.a)(n.prototype),"_complete",this).call(this)}},{key:"_unsubscribe",value:function(){this.contexts=null}},{key:"onBufferFull",value:function(t){this.closeContext(t);var e=t.closeAction;if(e.unsubscribe(),this.remove(e),!this.closed&&this.timespanOnly){t=this.openContext();var n=this.bufferTimeSpan;this.add(t.closeAction=this.scheduler.schedule(T,n,{subscriber:this,context:t,bufferTimeSpan:n}))}}},{key:"openContext",value:function(){var t=new O;return this.contexts.push(t),t}},{key:"closeContext",value:function(t){this.destination.next(t.buffer);var e=this.contexts;(e?e.indexOf(t):-1)>=0&&e.splice(e.indexOf(t),1)}}]),n}(v.a);function T(t){var e=t.subscriber,n=t.context;n&&e.closeContext(n),e.closed||(t.context=e.openContext(),t.context.closeAction=this.schedule(t,t.bufferTimeSpan))}function E(t){var e=t.bufferCreationInterval,n=t.bufferTimeSpan,i=t.subscriber,r=t.scheduler,o=i.openContext();i.closed||(i.add(o.closeAction=r.schedule(P,n,{subscriber:i,context:o})),this.schedule(t,e))}function P(t){t.subscriber.closeContext(t.context)}var A=n("quSY");function j(t,e){return function(n){return n.lift(new I(t,e))}}var I=function(){function t(e,n){Object(c.a)(this,t),this.openings=e,this.closingSelector=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new D(t,this.openings,this.closingSelector))}}]),t}(),D=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var a;return Object(c.a)(this,n),(a=e.call(this,t)).openings=i,a.closingSelector=r,a.contexts=[],a.add(Object(h.a)(Object(o.a)(a),i)),a}return Object(l.a)(n,[{key:"_next",value:function(t){for(var e=this.contexts,n=e.length,i=0;i<n;i++)e[i].buffer.push(t)}},{key:"_error",value:function(t){for(var e=this.contexts;e.length>0;){var i=e.shift();i.subscription.unsubscribe(),i.buffer=null,i.subscription=null}this.contexts=null,Object(m.a)(Object(g.a)(n.prototype),"_error",this).call(this,t)}},{key:"_complete",value:function(){for(var t=this.contexts;t.length>0;){var e=t.shift();this.destination.next(e.buffer),e.subscription.unsubscribe(),e.buffer=null,e.subscription=null}this.contexts=null,Object(m.a)(Object(g.a)(n.prototype),"_complete",this).call(this)}},{key:"notifyNext",value:function(t,e,n,i,r){t?this.closeBuffer(t):this.openBuffer(e)}},{key:"notifyComplete",value:function(t){this.closeBuffer(t.context)}},{key:"openBuffer",value:function(t){try{var e=this.closingSelector.call(this,t);e&&this.trySubscribe(e)}catch(n){this._error(n)}}},{key:"closeBuffer",value:function(t){var e=this.contexts;if(e&&t){var n=t.subscription;this.destination.next(t.buffer),e.splice(e.indexOf(t),1),this.remove(n),n.unsubscribe()}}},{key:"trySubscribe",value:function(t){var e=this.contexts,n=new A.a,i={buffer:[],subscription:n};e.push(i);var r=Object(h.a)(this,t,i);!r||r.closed?this.closeBuffer(i):(r.context=i,this.add(r),n.add(r))}}]),n}(u.a);function R(t){return function(e){return e.lift(new L(t))}}var L=function(){function t(e){Object(c.a)(this,t),this.closingSelector=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new F(t,this.closingSelector))}}]),t}(),F=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).closingSelector=i,r.subscribing=!1,r.openBuffer(),r}return Object(l.a)(n,[{key:"_next",value:function(t){this.buffer.push(t)}},{key:"_complete",value:function(){var t=this.buffer;t&&this.destination.next(t),Object(m.a)(Object(g.a)(n.prototype),"_complete",this).call(this)}},{key:"_unsubscribe",value:function(){this.buffer=null,this.subscribing=!1}},{key:"notifyNext",value:function(t,e,n,i,r){this.openBuffer()}},{key:"notifyComplete",value:function(){this.subscribing?this.complete():this.openBuffer()}},{key:"openBuffer",value:function(){var t,e=this.closingSubscription;e&&(this.remove(e),e.unsubscribe()),this.buffer&&this.destination.next(this.buffer),this.buffer=[];try{t=(0,this.closingSelector)()}catch(n){return this.error(n)}e=new A.a,this.closingSubscription=e,this.add(e),this.subscribing=!0,e.add(Object(h.a)(this,t)),this.subscribing=!1}}]),n}(u.a),N=n("JIr8"),B=n("itXk");function H(t){return function(e){return e.lift(new B.a(t))}}var z=n("KQm4"),V=n("DH7j"),U=n("Cfvw");function q(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var i=null;return"function"==typeof e[e.length-1]&&(i=e.pop()),1===e.length&&Object(V.a)(e[0])&&(e=e[0].slice()),function(t){return t.lift.call(Object(U.a)([t].concat(Object(z.a)(e))),new B.a(i))}}var G=n("GyhO");function W(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(t){return t.lift.call(G.a.apply(void 0,[t].concat(e)))}}var K=n("0EUg"),X=n("bOdf");function Y(t,e){return Object(X.a)((function(){return t}),e)}var Z=n("HrJb");function Q(t){return function(e){return e.lift(new $(t))}}var $=function(){function t(e){Object(c.a)(this,t),this.durationSelector=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new J(t,this.durationSelector))}}]),t}(),J=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).durationSelector=i,r.hasValue=!1,r.durationSubscription=null,r}return Object(l.a)(n,[{key:"_next",value:function(t){try{var e=this.durationSelector.call(this,t);e&&this._tryNext(t,e)}catch(n){this.destination.error(n)}}},{key:"_complete",value:function(){this.emitValue(),this.destination.complete()}},{key:"_tryNext",value:function(t,e){var n=this.durationSubscription;this.value=t,this.hasValue=!0,n&&(n.unsubscribe(),this.remove(n)),(n=Object(h.a)(this,e))&&!n.closed&&this.add(this.durationSubscription=n)}},{key:"notifyNext",value:function(t,e,n,i,r){this.emitValue()}},{key:"notifyComplete",value:function(){this.emitValue()}},{key:"emitValue",value:function(){if(this.hasValue){var t=this.value,e=this.durationSubscription;e&&(this.durationSubscription=null,e.unsubscribe(),this.remove(e)),this.value=null,this.hasValue=!1,Object(m.a)(Object(g.a)(n.prototype),"_next",this).call(this,t)}}}]),n}(u.a),tt=n("Kj3r"),et=n("xbPD"),nt=n("3E0/"),it=n("HDdC");function rt(t,e){return e?function(n){return new st(n,e).lift(new ot(t))}:function(e){return e.lift(new ot(t))}}var ot=function(){function t(e){Object(c.a)(this,t),this.delayDurationSelector=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new at(t,this.delayDurationSelector))}}]),t}(),at=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).delayDurationSelector=i,r.completed=!1,r.delayNotifierSubscriptions=[],r.index=0,r}return Object(l.a)(n,[{key:"notifyNext",value:function(t,e,n,i,r){this.destination.next(t),this.removeSubscription(r),this.tryComplete()}},{key:"notifyError",value:function(t,e){this._error(t)}},{key:"notifyComplete",value:function(t){var e=this.removeSubscription(t);e&&this.destination.next(e),this.tryComplete()}},{key:"_next",value:function(t){var e=this.index++;try{var n=this.delayDurationSelector(t,e);n&&this.tryDelay(n,t)}catch(i){this.destination.error(i)}}},{key:"_complete",value:function(){this.completed=!0,this.tryComplete(),this.unsubscribe()}},{key:"removeSubscription",value:function(t){t.unsubscribe();var e=this.delayNotifierSubscriptions.indexOf(t);return-1!==e&&this.delayNotifierSubscriptions.splice(e,1),t.outerValue}},{key:"tryDelay",value:function(t,e){var n=Object(h.a)(this,t,e);n&&!n.closed&&(this.destination.add(n),this.delayNotifierSubscriptions.push(n))}},{key:"tryComplete",value:function(){this.completed&&0===this.delayNotifierSubscriptions.length&&this.destination.complete()}}]),n}(u.a),st=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this)).source=t,r.subscriptionDelay=i,r}return Object(l.a)(n,[{key:"_subscribe",value:function(t){this.subscriptionDelay.subscribe(new ct(t,this.source))}}]),n}(it.a),ct=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this)).parent=t,r.source=i,r.sourceSubscribed=!1,r}return Object(l.a)(n,[{key:"_next",value:function(t){this.subscribeToSource()}},{key:"_error",value:function(t){this.unsubscribe(),this.parent.error(t)}},{key:"_complete",value:function(){this.unsubscribe(),this.subscribeToSource()}},{key:"subscribeToSource",value:function(){this.sourceSubscribed||(this.sourceSubscribed=!0,this.unsubscribe(),this.source.subscribe(this.parent))}}]),n}(v.a);function lt(){return function(t){return t.lift(new ut)}}var ut=function(){function t(){Object(c.a)(this,t)}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new ht(t))}}]),t}(),ht=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t){return Object(c.a)(this,n),e.call(this,t)}return Object(l.a)(n,[{key:"_next",value:function(t){t.observe(this.destination)}}]),n}(v.a);function dt(t,e){return function(n){return n.lift(new ft(t,e))}}var ft=function(){function t(e,n){Object(c.a)(this,t),this.keySelector=e,this.flushes=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new pt(t,this.keySelector,this.flushes))}}]),t}(),pt=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var a;return Object(c.a)(this,n),(a=e.call(this,t)).keySelector=i,a.values=new Set,r&&a.add(Object(h.a)(Object(o.a)(a),r)),a}return Object(l.a)(n,[{key:"notifyNext",value:function(t,e,n,i,r){this.values.clear()}},{key:"notifyError",value:function(t,e){this._error(t)}},{key:"_next",value:function(t){this.keySelector?this._useKeySelector(t):this._finalizeNext(t,t)}},{key:"_useKeySelector",value:function(t){var e,n=this.destination;try{e=this.keySelector(t)}catch(i){return void n.error(i)}this._finalizeNext(e,t)}},{key:"_finalizeNext",value:function(t,e){var n=this.values;n.has(t)||(n.add(t),this.destination.next(e))}}]),n}(u.a),mt=n("/uUt");function gt(t,e){return Object(mt.a)((function(n,i){return e?e(n[t],i[t]):n[t]===i[t]}))}var vt=n("4I5i"),bt=n("pLZG"),yt=n("XDbj"),_t=n("IzEk");function wt(t,e){if(t<0)throw new vt.a;var n=arguments.length>=2;return function(i){return i.pipe(Object(bt.a)((function(e,n){return n===t})),Object(_t.a)(1),n?Object(et.a)(e):Object(yt.a)((function(){return new vt.a})))}}var kt=n("LRne");function Ct(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(t){return Object(G.a)(t,kt.a.apply(void 0,e))}}var St=n("Gi4w");function xt(){return function(t){return t.lift(new Ot)}}var Ot=function(){function t(){Object(c.a)(this,t)}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Mt(t))}}]),t}(),Mt=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t){var i;return Object(c.a)(this,n),(i=e.call(this,t)).hasCompleted=!1,i.hasSubscription=!1,i}return Object(l.a)(n,[{key:"_next",value:function(t){this.hasSubscription||(this.hasSubscription=!0,this.add(Object(h.a)(this,t)))}},{key:"_complete",value:function(){this.hasCompleted=!0,this.hasSubscription||this.destination.complete()}},{key:"notifyComplete",value:function(t){this.remove(t),this.hasSubscription=!1,this.hasCompleted&&this.destination.complete()}}]),n}(u.a),Tt=n("51Dv"),Et=n("lJxs");function Pt(t,e){return e?function(n){return n.pipe(Pt((function(n,i){return Object(U.a)(t(n,i)).pipe(Object(Et.a)((function(t,r){return e(n,t,i,r)})))})))}:function(e){return e.lift(new At(t))}}var At=function(){function t(e){Object(c.a)(this,t),this.project=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new jt(t,this.project))}}]),t}(),jt=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).project=i,r.hasSubscription=!1,r.hasCompleted=!1,r.index=0,r}return Object(l.a)(n,[{key:"_next",value:function(t){this.hasSubscription||this.tryNext(t)}},{key:"tryNext",value:function(t){var e,n=this.index++;try{e=this.project(t,n)}catch(i){return void this.destination.error(i)}this.hasSubscription=!0,this._innerSub(e,t,n)}},{key:"_innerSub",value:function(t,e,n){var i=new Tt.a(this,e,n),r=this.destination;r.add(i);var o=Object(h.a)(this,t,void 0,void 0,i);o!==i&&r.add(o)}},{key:"_complete",value:function(){this.hasCompleted=!0,this.hasSubscription||this.destination.complete(),this.unsubscribe()}},{key:"notifyNext",value:function(t,e,n,i,r){this.destination.next(e)}},{key:"notifyError",value:function(t){this.destination.error(t)}},{key:"notifyComplete",value:function(t){this.destination.remove(t),this.hasSubscription=!1,this.hasCompleted&&this.destination.complete()}}]),n}(u.a);function It(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.POSITIVE_INFINITY,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;return e=(e||0)<1?Number.POSITIVE_INFINITY:e,function(i){return i.lift(new Dt(t,e,n))}}var Dt=function(){function t(e,n,i){Object(c.a)(this,t),this.project=e,this.concurrent=n,this.scheduler=i}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Rt(t,this.project,this.concurrent,this.scheduler))}}]),t}(),Rt=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r,o){var a;return Object(c.a)(this,n),(a=e.call(this,t)).project=i,a.concurrent=r,a.scheduler=o,a.index=0,a.active=0,a.hasCompleted=!1,r<Number.POSITIVE_INFINITY&&(a.buffer=[]),a}return Object(l.a)(n,[{key:"_next",value:function(t){var e=this.destination;if(e.closed)this._complete();else{var i=this.index++;if(this.active<this.concurrent){e.next(t);try{var r=(0,this.project)(t,i);this.scheduler?this.destination.add(this.scheduler.schedule(n.dispatch,0,{subscriber:this,result:r,value:t,index:i})):this.subscribeToProjection(r,t,i)}catch(o){e.error(o)}}else this.buffer.push(t)}}},{key:"subscribeToProjection",value:function(t,e,n){this.active++,this.destination.add(Object(h.a)(this,t,e,n))}},{key:"_complete",value:function(){this.hasCompleted=!0,this.hasCompleted&&0===this.active&&this.destination.complete(),this.unsubscribe()}},{key:"notifyNext",value:function(t,e,n,i,r){this._next(e)}},{key:"notifyComplete",value:function(t){var e=this.buffer;this.destination.remove(t),this.active--,e&&e.length>0&&this._next(e.shift()),this.hasCompleted&&0===this.active&&this.destination.complete()}}],[{key:"dispatch",value:function(t){t.subscriber.subscribeToProjection(t.result,t.value,t.index)}}]),n}(u.a),Lt=n("nYR2");function Ft(t,e){if("function"!=typeof t)throw new TypeError("predicate is not a function");return function(n){return n.lift(new Nt(t,n,!1,e))}}var Nt=function(){function t(e,n,i,r){Object(c.a)(this,t),this.predicate=e,this.source=n,this.yieldIndex=i,this.thisArg=r}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Bt(t,this.predicate,this.source,this.yieldIndex,this.thisArg))}}]),t}(),Bt=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r,o,a){var s;return Object(c.a)(this,n),(s=e.call(this,t)).predicate=i,s.source=r,s.yieldIndex=o,s.thisArg=a,s.index=0,s}return Object(l.a)(n,[{key:"notifyComplete",value:function(t){var e=this.destination;e.next(t),e.complete(),this.unsubscribe()}},{key:"_next",value:function(t){var e=this.predicate,n=this.thisArg,i=this.index++;try{e.call(n||this,t,i,this.source)&&this.notifyComplete(this.yieldIndex?i:t)}catch(r){this.destination.error(r)}}},{key:"_complete",value:function(){this.notifyComplete(this.yieldIndex?-1:void 0)}}]),n}(v.a);function Ht(t,e){return function(n){return n.lift(new Nt(t,n,!0,e))}}var zt=n("SxV6"),Vt=n("OQgR");function Ut(){return function(t){return t.lift(new qt)}}var qt=function(){function t(){Object(c.a)(this,t)}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Gt(t))}}]),t}(),Gt=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(){return Object(c.a)(this,n),e.apply(this,arguments)}return Object(l.a)(n,[{key:"_next",value:function(t){}}]),n}(v.a);function Wt(){return function(t){return t.lift(new Kt)}}var Kt=function(){function t(){Object(c.a)(this,t)}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Xt(t))}}]),t}(),Xt=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t){return Object(c.a)(this,n),e.call(this,t)}return Object(l.a)(n,[{key:"notifyComplete",value:function(t){var e=this.destination;e.next(t),e.complete()}},{key:"_next",value:function(t){this.notifyComplete(!1)}},{key:"_complete",value:function(){this.notifyComplete(!0)}}]),n}(v.a),Yt=n("NJ9Y");function Zt(t){return function(e){return e.lift(new Qt(t))}}var Qt=function(){function t(e){Object(c.a)(this,t),this.value=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new $t(t,this.value))}}]),t}(),$t=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).value=i,r}return Object(l.a)(n,[{key:"_next",value:function(t){this.destination.next(this.value)}}]),n}(v.a),Jt=n("WMd4");function te(){return function(t){return t.lift(new ee)}}var ee=function(){function t(){Object(c.a)(this,t)}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new ne(t))}}]),t}(),ne=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t){return Object(c.a)(this,n),e.call(this,t)}return Object(l.a)(n,[{key:"_next",value:function(t){this.destination.next(Jt.a.createNext(t))}},{key:"_error",value:function(t){var e=this.destination;e.next(Jt.a.createError(t)),e.complete()}},{key:"_complete",value:function(){var t=this.destination;t.next(Jt.a.createComplete()),t.complete()}}]),n}(v.a),ie=n("Kqap"),re=n("BFxc"),oe=n("mCNh");function ae(t,e){return arguments.length>=2?function(n){return Object(oe.a)(Object(ie.a)(t,e),Object(re.a)(1),Object(et.a)(e))(n)}:function(e){return Object(oe.a)(Object(ie.a)((function(e,n,i){return t(e,n,i+1)})),Object(re.a)(1))(e)}}function se(t){return ae("function"==typeof t?function(e,n){return t(e,n)>0?e:n}:function(t,e){return t>e?t:e})}var ce=n("VRyK");function le(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(t){return t.lift.call(ce.a.apply(void 0,[t].concat(e)))}}var ue=n("bHdf"),he=n("5+tZ");function de(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Number.POSITIVE_INFINITY;return"function"==typeof e?Object(he.a)((function(){return t}),e,n):("number"==typeof e&&(n=e),Object(he.a)((function(){return t}),n))}function fe(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Number.POSITIVE_INFINITY;return function(i){return i.lift(new pe(t,e,n))}}var pe=function(){function t(e,n,i){Object(c.a)(this,t),this.accumulator=e,this.seed=n,this.concurrent=i}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new me(t,this.accumulator,this.seed,this.concurrent))}}]),t}(),me=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r,o){var a;return Object(c.a)(this,n),(a=e.call(this,t)).accumulator=i,a.acc=r,a.concurrent=o,a.hasValue=!1,a.hasCompleted=!1,a.buffer=[],a.active=0,a.index=0,a}return Object(l.a)(n,[{key:"_next",value:function(t){if(this.active<this.concurrent){var e,n=this.index++,i=this.destination;try{e=(0,this.accumulator)(this.acc,t,n)}catch(r){return i.error(r)}this.active++,this._innerSub(e,t,n)}else this.buffer.push(t)}},{key:"_innerSub",value:function(t,e,n){var i=new Tt.a(this,e,n),r=this.destination;r.add(i);var o=Object(h.a)(this,t,void 0,void 0,i);o!==i&&r.add(o)}},{key:"_complete",value:function(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&(!1===this.hasValue&&this.destination.next(this.acc),this.destination.complete()),this.unsubscribe()}},{key:"notifyNext",value:function(t,e,n,i,r){var o=this.destination;this.acc=e,this.hasValue=!0,o.next(e)}},{key:"notifyComplete",value:function(t){var e=this.buffer;this.destination.remove(t),this.active--,e.length>0?this._next(e.shift()):0===this.active&&this.hasCompleted&&(!1===this.hasValue&&this.destination.next(this.acc),this.destination.complete())}}]),n}(u.a);function ge(t){return ae("function"==typeof t?function(e,n){return t(e,n)<0?e:n}:function(t,e){return t<e?t:e})}var ve=n("oB13"),be=n("pxpQ");function ye(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return 1===e.length&&Object(V.a)(e[0])&&(e=e[0]),function(t){return t.lift(new _e(e))}}var _e=function(){function t(e){Object(c.a)(this,t),this.nextSources=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new we(t,this.nextSources))}}]),t}(),we=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).destination=t,r.nextSources=i,r}return Object(l.a)(n,[{key:"notifyError",value:function(t,e){this.subscribeToNextSource()}},{key:"notifyComplete",value:function(t){this.subscribeToNextSource()}},{key:"_error",value:function(t){this.subscribeToNextSource(),this.unsubscribe()}},{key:"_complete",value:function(){this.subscribeToNextSource(),this.unsubscribe()}},{key:"subscribeToNextSource",value:function(){var t=this.nextSources.shift();if(t){var e=new Tt.a(this,void 0,void 0),n=this.destination;n.add(e);var i=Object(h.a)(this,t,void 0,void 0,e);i!==e&&n.add(i)}else this.destination.complete()}}]),n}(u.a),ke=n("Zy1z"),Ce=n("F97/");function Se(t,e){return function(n){return[Object(bt.a)(t,e)(n),Object(bt.a)(Object(Ce.a)(t,e))(n)]}}function xe(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var i=e.length;if(0===i)throw new Error("list of properties cannot be empty.");return function(t){return Object(Et.a)(Oe(e,i))(t)}}function Oe(t,e){return function(n){for(var i=n,r=0;r<e;r++){var o=i[t[r]];if(void 0===o)return;i=o}return i}}var Me=n("XNiG");function Te(t){return t?Object(ve.a)((function(){return new Me.b}),t):Object(ve.a)(new Me.b)}var Ee=n("2Vo4");function Pe(t){return function(e){return Object(ve.a)(new Ee.a(t))(e)}}var Ae=n("NHP+");function je(){return function(t){return Object(ve.a)(new Ae.a)(t)}}var Ie=n("jtHE");function De(t,e,n,i){n&&"function"!=typeof n&&(i=n);var r="function"==typeof n?n:void 0,o=new Ie.a(t,e,i);return function(t){return Object(ve.a)((function(){return o}),r)(t)}}var Re=n("Nv8m");function Le(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(t){return 1===e.length&&Object(V.a)(e[0])&&(e=e[0]),t.lift.call(Re.a.apply(void 0,[t].concat(Object(z.a)(e))))}}var Fe=n("EY2u");function Ne(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-1;return function(e){return 0===t?Object(Fe.b)():e.lift(new Be(t<0?-1:t-1,e))}}var Be=function(){function t(e,n){Object(c.a)(this,t),this.count=e,this.source=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new He(t,this.count,this.source))}}]),t}(),He=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var o;return Object(c.a)(this,n),(o=e.call(this,t)).count=i,o.source=r,o}return Object(l.a)(n,[{key:"complete",value:function(){if(!this.isStopped){var t=this.source,e=this.count;if(0===e)return Object(m.a)(Object(g.a)(n.prototype),"complete",this).call(this);e>-1&&(this.count=e-1),t.subscribe(this._unsubscribeAndRecycle())}}}]),n}(v.a);function ze(t){return function(e){return e.lift(new Ve(t))}}var Ve=function(){function t(e){Object(c.a)(this,t),this.notifier=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Ue(t,this.notifier,e))}}]),t}(),Ue=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var o;return Object(c.a)(this,n),(o=e.call(this,t)).notifier=i,o.source=r,o.sourceIsBeingSubscribedTo=!0,o}return Object(l.a)(n,[{key:"notifyNext",value:function(t,e,n,i,r){this.sourceIsBeingSubscribedTo=!0,this.source.subscribe(this)}},{key:"notifyComplete",value:function(t){if(!1===this.sourceIsBeingSubscribedTo)return Object(m.a)(Object(g.a)(n.prototype),"complete",this).call(this)}},{key:"complete",value:function(){if(this.sourceIsBeingSubscribedTo=!1,!this.isStopped){if(this.retries||this.subscribeToRetries(),!this.retriesSubscription||this.retriesSubscription.closed)return Object(m.a)(Object(g.a)(n.prototype),"complete",this).call(this);this._unsubscribeAndRecycle(),this.notifications.next()}}},{key:"_unsubscribe",value:function(){var t=this.notifications,e=this.retriesSubscription;t&&(t.unsubscribe(),this.notifications=null),e&&(e.unsubscribe(),this.retriesSubscription=null),this.retries=null}},{key:"_unsubscribeAndRecycle",value:function(){var t=this._unsubscribe;return this._unsubscribe=null,Object(m.a)(Object(g.a)(n.prototype),"_unsubscribeAndRecycle",this).call(this),this._unsubscribe=t,this}},{key:"subscribeToRetries",value:function(){var t;this.notifications=new Me.b;try{t=(0,this.notifier)(this.notifications)}catch(e){return Object(m.a)(Object(g.a)(n.prototype),"complete",this).call(this)}this.retries=t,this.retriesSubscription=Object(h.a)(this,t)}}]),n}(u.a);function qe(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-1;return function(e){return e.lift(new Ge(t,e))}}var Ge=function(){function t(e,n){Object(c.a)(this,t),this.count=e,this.source=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new We(t,this.count,this.source))}}]),t}(),We=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var o;return Object(c.a)(this,n),(o=e.call(this,t)).count=i,o.source=r,o}return Object(l.a)(n,[{key:"error",value:function(t){if(!this.isStopped){var e=this.source,i=this.count;if(0===i)return Object(m.a)(Object(g.a)(n.prototype),"error",this).call(this,t);i>-1&&(this.count=i-1),e.subscribe(this._unsubscribeAndRecycle())}}}]),n}(v.a);function Ke(t){return function(e){return e.lift(new Xe(t,e))}}var Xe=function(){function t(e,n){Object(c.a)(this,t),this.notifier=e,this.source=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Ye(t,this.notifier,this.source))}}]),t}(),Ye=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var o;return Object(c.a)(this,n),(o=e.call(this,t)).notifier=i,o.source=r,o}return Object(l.a)(n,[{key:"error",value:function(t){if(!this.isStopped){var e=this.errors,i=this.retries,r=this.retriesSubscription;if(i)this.errors=null,this.retriesSubscription=null;else{e=new Me.b;try{i=(0,this.notifier)(e)}catch(o){return Object(m.a)(Object(g.a)(n.prototype),"error",this).call(this,o)}r=Object(h.a)(this,i)}this._unsubscribeAndRecycle(),this.errors=e,this.retries=i,this.retriesSubscription=r,e.next(t)}}},{key:"_unsubscribe",value:function(){var t=this.errors,e=this.retriesSubscription;t&&(t.unsubscribe(),this.errors=null),e&&(e.unsubscribe(),this.retriesSubscription=null),this.retries=null}},{key:"notifyNext",value:function(t,e,n,i,r){var o=this._unsubscribe;this._unsubscribe=null,this._unsubscribeAndRecycle(),this._unsubscribe=o,this.source.subscribe(this)}}]),n}(u.a),Ze=n("x+ZX");function Qe(t){return function(e){return e.lift(new $e(t))}}var $e=function(){function t(e){Object(c.a)(this,t),this.notifier=e}return Object(l.a)(t,[{key:"call",value:function(t,e){var n=new Je(t),i=e.subscribe(n);return i.add(Object(h.a)(n,this.notifier)),i}}]),t}(),Je=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(){var t;return Object(c.a)(this,n),(t=e.apply(this,arguments)).hasValue=!1,t}return Object(l.a)(n,[{key:"_next",value:function(t){this.value=t,this.hasValue=!0}},{key:"notifyNext",value:function(t,e,n,i,r){this.emitValue()}},{key:"notifyComplete",value:function(){this.emitValue()}},{key:"emitValue",value:function(){this.hasValue&&(this.hasValue=!1,this.destination.next(this.value))}}]),n}(u.a);function tn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:k.a;return function(n){return n.lift(new en(t,e))}}var en=function(){function t(e,n){Object(c.a)(this,t),this.period=e,this.scheduler=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new nn(t,this.period,this.scheduler))}}]),t}(),nn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var a;return Object(c.a)(this,n),(a=e.call(this,t)).period=i,a.scheduler=r,a.hasValue=!1,a.add(r.schedule(rn,i,{subscriber:Object(o.a)(a),period:i})),a}return Object(l.a)(n,[{key:"_next",value:function(t){this.lastValue=t,this.hasValue=!0}},{key:"notifyNext",value:function(){this.hasValue&&(this.hasValue=!1,this.destination.next(this.lastValue))}}]),n}(v.a);function rn(t){var e=t.period;t.subscriber.notifyNext(),this.schedule(t,e)}function on(t,e){return function(n){return n.lift(new an(t,e))}}var an=function(){function t(e,n){Object(c.a)(this,t),this.compareTo=e,this.comparator=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new sn(t,this.compareTo,this.comparator))}}]),t}(),sn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var a;return Object(c.a)(this,n),(a=e.call(this,t)).compareTo=i,a.comparator=r,a._a=[],a._b=[],a._oneComplete=!1,a.destination.add(i.subscribe(new cn(t,Object(o.a)(a)))),a}return Object(l.a)(n,[{key:"_next",value:function(t){this._oneComplete&&0===this._b.length?this.emit(!1):(this._a.push(t),this.checkValues())}},{key:"_complete",value:function(){this._oneComplete?this.emit(0===this._a.length&&0===this._b.length):this._oneComplete=!0,this.unsubscribe()}},{key:"checkValues",value:function(){for(var t=this._a,e=this._b,n=this.comparator;t.length>0&&e.length>0;){var i=t.shift(),r=e.shift(),o=!1;try{o=n?n(i,r):i===r}catch(a){this.destination.error(a)}o||this.emit(!1)}}},{key:"emit",value:function(t){var e=this.destination;e.next(t),e.complete()}},{key:"nextB",value:function(t){this._oneComplete&&0===this._a.length?this.emit(!1):(this._b.push(t),this.checkValues())}},{key:"completeB",value:function(){this._oneComplete?this.emit(0===this._a.length&&0===this._b.length):this._oneComplete=!0}}]),n}(v.a),cn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).parent=i,r}return Object(l.a)(n,[{key:"_next",value:function(t){this.parent.nextB(t)}},{key:"_error",value:function(t){this.parent.error(t),this.unsubscribe()}},{key:"_complete",value:function(){this.parent.completeB(),this.unsubscribe()}}]),n}(v.a),ln=n("w1tV"),un=n("UXun"),hn=n("sVev");function dn(t){return function(e){return e.lift(new fn(t,e))}}var fn=function(){function t(e,n){Object(c.a)(this,t),this.predicate=e,this.source=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new pn(t,this.predicate,this.source))}}]),t}(),pn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var o;return Object(c.a)(this,n),(o=e.call(this,t)).predicate=i,o.source=r,o.seenValue=!1,o.index=0,o}return Object(l.a)(n,[{key:"applySingleValue",value:function(t){this.seenValue?this.destination.error("Sequence contains more than one element"):(this.seenValue=!0,this.singleValue=t)}},{key:"_next",value:function(t){var e=this.index++;this.predicate?this.tryNext(t,e):this.applySingleValue(t)}},{key:"tryNext",value:function(t,e){try{this.predicate(t,e,this.source)&&this.applySingleValue(t)}catch(n){this.destination.error(n)}}},{key:"_complete",value:function(){var t=this.destination;this.index>0?(t.next(this.seenValue?this.singleValue:void 0),t.complete()):t.error(new hn.a)}}]),n}(v.a),mn=n("zP0r");function gn(t){return function(e){return e.lift(new vn(t))}}var vn=function(){function t(e){if(Object(c.a)(this,t),this._skipCount=e,this._skipCount<0)throw new vt.a}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(0===this._skipCount?new v.a(t):new bn(t,this._skipCount))}}]),t}(),bn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t))._skipCount=i,r._count=0,r._ring=new Array(i),r}return Object(l.a)(n,[{key:"_next",value:function(t){var e=this._skipCount,n=this._count++;if(n<e)this._ring[n]=t;else{var i=n%e,r=this._ring,o=r[i];r[i]=t,this.destination.next(o)}}}]),n}(v.a);function yn(t){return function(e){return e.lift(new _n(t))}}var _n=function(){function t(e){Object(c.a)(this,t),this.notifier=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new wn(t,this.notifier))}}]),t}(),wn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;Object(c.a)(this,n),(r=e.call(this,t)).hasValue=!1;var a=new Tt.a(Object(o.a)(r),void 0,void 0);r.add(a),r.innerSubscription=a;var s=Object(h.a)(Object(o.a)(r),i,void 0,void 0,a);return s!==a&&(r.add(s),r.innerSubscription=s),r}return Object(l.a)(n,[{key:"_next",value:function(t){this.hasValue&&Object(m.a)(Object(g.a)(n.prototype),"_next",this).call(this,t)}},{key:"notifyNext",value:function(t,e,n,i,r){this.hasValue=!0,this.innerSubscription&&this.innerSubscription.unsubscribe()}},{key:"notifyComplete",value:function(){}}]),n}(u.a);function kn(t){return function(e){return e.lift(new Cn(t))}}var Cn=function(){function t(e){Object(c.a)(this,t),this.predicate=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Sn(t,this.predicate))}}]),t}(),Sn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).predicate=i,r.skipping=!0,r.index=0,r}return Object(l.a)(n,[{key:"_next",value:function(t){var e=this.destination;this.skipping&&this.tryCallPredicate(t),this.skipping||e.next(t)}},{key:"tryCallPredicate",value:function(t){try{var e=this.predicate(t,this.index++);this.skipping=Boolean(e)}catch(n){this.destination.error(n)}}}]),n}(v.a),xn=n("JX91"),On=n("O4y0");function Mn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return function(n){return n.lift(new Tn(t,e))}}var Tn=function(){function t(e,n){Object(c.a)(this,t),this.scheduler=e,this.delay=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return new On.a(e,this.delay,this.scheduler).subscribe(t)}}]),t}(),En=n("eIep"),Pn=n("SpAZ");function An(){return Object(En.a)(Pn.a)}function jn(t,e){return e?Object(En.a)((function(){return t}),e):Object(En.a)((function(){return t}))}var In=n("1G5W");function Dn(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return function(n){return n.lift(new Rn(t,e))}}var Rn=function(){function t(e,n){Object(c.a)(this,t),this.predicate=e,this.inclusive=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Ln(t,this.predicate,this.inclusive))}}]),t}(),Ln=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var o;return Object(c.a)(this,n),(o=e.call(this,t)).predicate=i,o.inclusive=r,o.index=0,o}return Object(l.a)(n,[{key:"_next",value:function(t){var e,n=this.destination;try{e=this.predicate(t,this.index++)}catch(i){return void n.error(i)}this.nextOrComplete(t,e)}},{key:"nextOrComplete",value:function(t,e){var n=this.destination;Boolean(e)?n.next(t):(this.inclusive&&n.next(t),n.complete())}}]),n}(v.a),Fn=n("vkgz"),Nn=n("yuhW");function Bn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:k.a,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Nn.a;return function(i){return i.lift(new Hn(t,e,n.leading,n.trailing))}}var Hn=function(){function t(e,n,i,r){Object(c.a)(this,t),this.duration=e,this.scheduler=n,this.leading=i,this.trailing=r}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new zn(t,this.duration,this.scheduler,this.leading,this.trailing))}}]),t}(),zn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r,o,a){var s;return Object(c.a)(this,n),(s=e.call(this,t)).duration=i,s.scheduler=r,s.leading=o,s.trailing=a,s._hasTrailingValue=!1,s._trailingValue=null,s}return Object(l.a)(n,[{key:"_next",value:function(t){this.throttled?this.trailing&&(this._trailingValue=t,this._hasTrailingValue=!0):(this.add(this.throttled=this.scheduler.schedule(Vn,this.duration,{subscriber:this})),this.leading?this.destination.next(t):this.trailing&&(this._trailingValue=t,this._hasTrailingValue=!0))}},{key:"_complete",value:function(){this._hasTrailingValue?(this.destination.next(this._trailingValue),this.destination.complete()):this.destination.complete()}},{key:"clearThrottle",value:function(){var t=this.throttled;t&&(this.trailing&&this._hasTrailingValue&&(this.destination.next(this._trailingValue),this._trailingValue=null,this._hasTrailingValue=!1),t.unsubscribe(),this.remove(t),this.throttled=null)}}]),n}(v.a);function Vn(t){t.subscriber.clearThrottle()}var Un=n("4hIw"),qn=n("Y6u4"),Gn=n("mlxB");function Wn(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:k.a;return function(i){var r=Object(Gn.a)(t),o=r?+t-n.now():Math.abs(t);return i.lift(new Kn(o,r,e,n))}}var Kn=function(){function t(e,n,i,r){Object(c.a)(this,t),this.waitFor=e,this.absoluteTimeout=n,this.withObservable=i,this.scheduler=r}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new Xn(t,this.absoluteTimeout,this.waitFor,this.withObservable,this.scheduler))}}]),t}(),Xn=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r,o,a){var s;return Object(c.a)(this,n),(s=e.call(this,t)).absoluteTimeout=i,s.waitFor=r,s.withObservable=o,s.scheduler=a,s.action=null,s.scheduleTimeout(),s}return Object(l.a)(n,[{key:"scheduleTimeout",value:function(){var t=this.action;t?this.action=t.schedule(this,this.waitFor):this.add(this.action=this.scheduler.schedule(n.dispatchTimeout,this.waitFor,this))}},{key:"_next",value:function(t){this.absoluteTimeout||this.scheduleTimeout(),Object(m.a)(Object(g.a)(n.prototype),"_next",this).call(this,t)}},{key:"_unsubscribe",value:function(){this.action=null,this.scheduler=null,this.withObservable=null}}],[{key:"dispatchTimeout",value:function(t){var e=t.withObservable;t._unsubscribeAndRecycle(),t.add(Object(h.a)(t,e))}}]),n}(u.a),Yn=n("z6cu");function Zn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:k.a;return Wn(t,Object(Yn.a)(new qn.a),e)}var Qn=n("r0WS");function $n(t,e,n){return 0===n?[e]:(t.push(e),t)}function Jn(){return ae($n,[])}function ti(t){return function(e){return e.lift(new ei(t))}}var ei=function(){function t(e){Object(c.a)(this,t),this.windowBoundaries=e}return Object(l.a)(t,[{key:"call",value:function(t,e){var n=new ni(t),i=e.subscribe(n);return i.closed||n.add(Object(h.a)(n,this.windowBoundaries)),i}}]),t}(),ni=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t){var i;return Object(c.a)(this,n),(i=e.call(this,t)).window=new Me.b,t.next(i.window),i}return Object(l.a)(n,[{key:"notifyNext",value:function(t,e,n,i,r){this.openWindow()}},{key:"notifyError",value:function(t,e){this._error(t)}},{key:"notifyComplete",value:function(t){this._complete()}},{key:"_next",value:function(t){this.window.next(t)}},{key:"_error",value:function(t){this.window.error(t),this.destination.error(t)}},{key:"_complete",value:function(){this.window.complete(),this.destination.complete()}},{key:"_unsubscribe",value:function(){this.window=null}},{key:"openWindow",value:function(){var t=this.window;t&&t.complete();var e=this.destination,n=this.window=new Me.b;e.next(n)}}]),n}(u.a);function ii(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return function(n){return n.lift(new ri(t,e))}}var ri=function(){function t(e,n){Object(c.a)(this,t),this.windowSize=e,this.startWindowEvery=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new oi(t,this.windowSize,this.startWindowEvery))}}]),t}(),oi=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var o;return Object(c.a)(this,n),(o=e.call(this,t)).destination=t,o.windowSize=i,o.startWindowEvery=r,o.windows=[new Me.b],o.count=0,t.next(o.windows[0]),o}return Object(l.a)(n,[{key:"_next",value:function(t){for(var e=this.startWindowEvery>0?this.startWindowEvery:this.windowSize,n=this.destination,i=this.windowSize,r=this.windows,o=r.length,a=0;a<o&&!this.closed;a++)r[a].next(t);var s=this.count-i+1;if(s>=0&&s%e==0&&!this.closed&&r.shift().complete(),++this.count%e==0&&!this.closed){var c=new Me.b;r.push(c),n.next(c)}}},{key:"_error",value:function(t){var e=this.windows;if(e)for(;e.length>0&&!this.closed;)e.shift().error(t);this.destination.error(t)}},{key:"_complete",value:function(){var t=this.windows;if(t)for(;t.length>0&&!this.closed;)t.shift().complete();this.destination.complete()}},{key:"_unsubscribe",value:function(){this.count=0,this.windows=null}}]),n}(v.a),ai=n("Y7HM");function si(t){var e=k.a,n=null,i=Number.POSITIVE_INFINITY;return Object(C.a)(arguments[3])&&(e=arguments[3]),Object(C.a)(arguments[2])?e=arguments[2]:Object(ai.a)(arguments[2])&&(i=arguments[2]),Object(C.a)(arguments[1])?e=arguments[1]:Object(ai.a)(arguments[1])&&(n=arguments[1]),function(r){return r.lift(new ci(t,n,i,e))}}var ci=function(){function t(e,n,i,r){Object(c.a)(this,t),this.windowTimeSpan=e,this.windowCreationInterval=n,this.maxWindowSize=i,this.scheduler=r}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new ui(t,this.windowTimeSpan,this.windowCreationInterval,this.maxWindowSize,this.scheduler))}}]),t}(),li=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(){var t;return Object(c.a)(this,n),(t=e.apply(this,arguments))._numberOfNextedValues=0,t}return Object(l.a)(n,[{key:"next",value:function(t){this._numberOfNextedValues++,Object(m.a)(Object(g.a)(n.prototype),"next",this).call(this,t)}},{key:"numberOfNextedValues",get:function(){return this._numberOfNextedValues}}]),n}(Me.b),ui=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r,a,s){var l;Object(c.a)(this,n),(l=e.call(this,t)).destination=t,l.windowTimeSpan=i,l.windowCreationInterval=r,l.maxWindowSize=a,l.scheduler=s,l.windows=[];var u=l.openWindow();if(null!==r&&r>=0){var h={subscriber:Object(o.a)(l),window:u,context:null},d={windowTimeSpan:i,windowCreationInterval:r,subscriber:Object(o.a)(l),scheduler:s};l.add(s.schedule(fi,i,h)),l.add(s.schedule(di,r,d))}else{var f={subscriber:Object(o.a)(l),window:u,windowTimeSpan:i};l.add(s.schedule(hi,i,f))}return l}return Object(l.a)(n,[{key:"_next",value:function(t){for(var e=this.windows,n=e.length,i=0;i<n;i++){var r=e[i];r.closed||(r.next(t),r.numberOfNextedValues>=this.maxWindowSize&&this.closeWindow(r))}}},{key:"_error",value:function(t){for(var e=this.windows;e.length>0;)e.shift().error(t);this.destination.error(t)}},{key:"_complete",value:function(){for(var t=this.windows;t.length>0;){var e=t.shift();e.closed||e.complete()}this.destination.complete()}},{key:"openWindow",value:function(){var t=new li;return this.windows.push(t),this.destination.next(t),t}},{key:"closeWindow",value:function(t){t.complete();var e=this.windows;e.splice(e.indexOf(t),1)}}]),n}(v.a);function hi(t){var e=t.subscriber,n=t.windowTimeSpan,i=t.window;i&&e.closeWindow(i),t.window=e.openWindow(),this.schedule(t,n)}function di(t){var e=t.windowTimeSpan,n=t.subscriber,i=t.scheduler,r=t.windowCreationInterval,o=n.openWindow(),a={action:this,subscription:null};a.subscription=i.schedule(fi,e,{subscriber:n,window:o,context:a}),this.add(a.subscription),this.schedule(t,r)}function fi(t){var e=t.subscriber,n=t.window,i=t.context;i&&i.action&&i.subscription&&i.action.remove(i.subscription),e.closeWindow(n)}function pi(t,e){return function(n){return n.lift(new mi(t,e))}}var mi=function(){function t(e,n){Object(c.a)(this,t),this.openings=e,this.closingSelector=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new gi(t,this.openings,this.closingSelector))}}]),t}(),gi=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var a;return Object(c.a)(this,n),(a=e.call(this,t)).openings=i,a.closingSelector=r,a.contexts=[],a.add(a.openSubscription=Object(h.a)(Object(o.a)(a),i,i)),a}return Object(l.a)(n,[{key:"_next",value:function(t){var e=this.contexts;if(e)for(var n=e.length,i=0;i<n;i++)e[i].window.next(t)}},{key:"_error",value:function(t){var e=this.contexts;if(this.contexts=null,e)for(var i=e.length,r=-1;++r<i;){var o=e[r];o.window.error(t),o.subscription.unsubscribe()}Object(m.a)(Object(g.a)(n.prototype),"_error",this).call(this,t)}},{key:"_complete",value:function(){var t=this.contexts;if(this.contexts=null,t)for(var e=t.length,i=-1;++i<e;){var r=t[i];r.window.complete(),r.subscription.unsubscribe()}Object(m.a)(Object(g.a)(n.prototype),"_complete",this).call(this)}},{key:"_unsubscribe",value:function(){var t=this.contexts;if(this.contexts=null,t)for(var e=t.length,n=-1;++n<e;){var i=t[n];i.window.unsubscribe(),i.subscription.unsubscribe()}}},{key:"notifyNext",value:function(t,e,n,i,r){if(t===this.openings){var o;try{o=(0,this.closingSelector)(e)}catch(u){return this.error(u)}var a=new Me.b,s=new A.a,c={window:a,subscription:s};this.contexts.push(c);var l=Object(h.a)(this,o,c);l.closed?this.closeWindow(this.contexts.length-1):(l.context=c,s.add(l)),this.destination.next(a)}else this.closeWindow(this.contexts.indexOf(t))}},{key:"notifyError",value:function(t){this.error(t)}},{key:"notifyComplete",value:function(t){t!==this.openSubscription&&this.closeWindow(this.contexts.indexOf(t.context))}},{key:"closeWindow",value:function(t){if(-1!==t){var e=this.contexts,n=e[t],i=n.window,r=n.subscription;e.splice(t,1),i.complete(),r.unsubscribe()}}}]),n}(u.a);function vi(t){return function(e){return e.lift(new bi(t))}}var bi=function(){function t(e){Object(c.a)(this,t),this.closingSelector=e}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new yi(t,this.closingSelector))}}]),t}(),yi=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i){var r;return Object(c.a)(this,n),(r=e.call(this,t)).destination=t,r.closingSelector=i,r.openWindow(),r}return Object(l.a)(n,[{key:"notifyNext",value:function(t,e,n,i,r){this.openWindow(r)}},{key:"notifyError",value:function(t,e){this._error(t)}},{key:"notifyComplete",value:function(t){this.openWindow(t)}},{key:"_next",value:function(t){this.window.next(t)}},{key:"_error",value:function(t){this.window.error(t),this.destination.error(t),this.unsubscribeClosingNotification()}},{key:"_complete",value:function(){this.window.complete(),this.destination.complete(),this.unsubscribeClosingNotification()}},{key:"unsubscribeClosingNotification",value:function(){this.closingNotification&&this.closingNotification.unsubscribe()}},{key:"openWindow",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;t&&(this.remove(t),t.unsubscribe());var e=this.window;e&&e.complete();var n,i=this.window=new Me.b;this.destination.next(i);try{var r=this.closingSelector;n=r()}catch(o){return this.destination.error(o),void this.window.error(o)}this.add(this.closingNotification=Object(h.a)(this,n))}}]),n}(u.a);function _i(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(t){var n;return"function"==typeof e[e.length-1]&&(n=e.pop()),t.lift(new wi(e,n))}}var wi=function(){function t(e,n){Object(c.a)(this,t),this.observables=e,this.project=n}return Object(l.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new ki(t,this.observables,this.project))}}]),t}(),ki=function(t){Object(a.a)(n,t);var e=Object(s.a)(n);function n(t,i,r){var a;Object(c.a)(this,n),(a=e.call(this,t)).observables=i,a.project=r,a.toRespond=[];var s=i.length;a.values=new Array(s);for(var l=0;l<s;l++)a.toRespond.push(l);for(var u=0;u<s;u++){var d=i[u];a.add(Object(h.a)(Object(o.a)(a),d,d,u))}return a}return Object(l.a)(n,[{key:"notifyNext",value:function(t,e,n,i,r){this.values[n]=e;var o=this.toRespond;if(o.length>0){var a=o.indexOf(n);-1!==a&&o.splice(a,1)}}},{key:"notifyComplete",value:function(){}},{key:"_next",value:function(t){if(0===this.toRespond.length){var e=[t].concat(Object(z.a)(this.values));this.project?this._tryProject(e):this.destination.next(e)}}},{key:"_tryProject",value:function(t){var e;try{e=this.project.apply(this,t)}catch(n){return void this.destination.error(n)}this.destination.next(e)}}]),n}(u.a),Ci=n("1uah");function Si(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(t){return t.lift.call(Ci.b.apply(void 0,[t].concat(e)))}}function xi(t){return function(e){return e.lift(new Ci.a(t))}}},kiQV:function(t){t.exports=JSON.parse('{"name":"gns3-web-ui","version":"2020.3.0-beta.4","author":{"name":"GNS3 Technology Inc.","email":"developers@gns3.com"},"description":"Graphical Network Simulator-3 is a network software emulator.","license":"GPLv3","main":"main.js","repository":{"type":"git","url":"https://github.com/GNS3/gns3-web-ui.git"},"scripts":{"ng":"ng","start":"ng serve","startforelectron":"ng serve --configuration=electronDev","build":"ng build","buildforelectron":"ng build --configuration=electronProd","buildforgithub":"ng build --configuration=githubProd","test":"ng test","lint":"ng lint","e2e":"ng e2e","electron":"electron .","electrondev":"concurrently -k \\"yarn startforelectron\\" \\"electron . -e dev\\"","distlinux":"yarn buildforelectron && electron-builder --linux --x64","distwin":"yarn buildforelectron && electron-builder --win --x64","distmac":"yarn buildforelectron && electron-builder --mac --x64","release":"build","coverage":"ng test --watch=false --code-coverage","prettier:base":"prettier","prettier:check":"yarn prettier:base -- --list-different \\"src/**/*.{ts,js,html,scss}\\"","prettier:write":"yarn prettier:base -- --write \\"src/**/*.{ts,js,html,scss}\\"","generate-licenses-file":"yarn license-checker --production --csv --out licenses.csv","prebuildforelectron":"node set-variables-in-env.js --set src/environments/environment.electron.prod.ts","postbuildforelectron":"node set-variables-in-env.js --unset src/environments/environment.electron.prod.ts","snyk-protect":"snyk protect","prepare":"yarn run snyk-protect"},"private":true,"dependencies":{"@angular/animations":"^10.0.2","@angular/cdk":"^10.0.1","@angular/common":"^10.0.2","@angular/compiler":"^10.0.2","@angular/core":"^10.0.2","@angular/forms":"^10.0.2","@angular/http":"^7.2.16","@angular/material":"^10.0.1","@angular/platform-browser":"^10.0.2","@angular/platform-browser-dynamic":"^10.0.2","@angular/router":"^10.0.2","@sentry/browser":"^5.18.0","@types/jest":"^26.0.3","@types/mocha":"^7.0.2","angular-draggable-droppable":"^4.5.1","angular-persistence":"^1.0.1","angular-resizable-element":"^3.3.2","angular2-draggable":"^2.3.2","angular2-hotkeys":"^2.2.0","angular2-indexeddb":"^1.2.3","bootstrap":"4.5.0","command-exists":"^1.2.9","core-js":"^3.6.5","css-tree":"^1.0.0-alpha.36","d3-ng2-service":"^2.1.0","file-saver":"^2.0.2","ini":"^1.3.5","material-design-icons":"^3.0.1","ng-circle-progress":"^1.5.1","ng2-file-upload":"^1.3.0","ngx-childprocess":"^0.0.6","ngx-device-detector":"^1.4.5","ngx-electron":"^2.1.1","node-fetch":"^2.6.1","notosans-fontface":"1.1.0","rxjs":"^6.5.5","rxjs-compat":"^6.5.5","save-html-as-image":"^1.3.3","save-svg-as-png":"^1.4.14","snyk":"^1.361.3","svg-crowbar":"^0.6.0","tree-kill":"^1.2.1","tslib":"^2.0.0","typeface-roboto":"^0.0.75","xterm":"^4.1.0","xterm-addon-attach":"^0.6.0","xterm-addon-fit":"^0.4.0","yargs":"^15.3.1","zone.js":"~0.10.3"},"devDependencies":{"@angular-devkit/build-angular":"~0.1000.0","@angular/cli":"^10.0.0","@angular/compiler-cli":"^10.0.2","@angular/language-service":"^10.0.2","@sentry/cli":"^1.53.0","@sentry/electron":"^1.3.0","@types/jasmine":"^3.5.11","@types/jasminewd2":"^2.0.8","@types/node":"12.12.6","codelyzer":"^5.2.2","electron":"^9.0.5","electron-builder":"22.7.0","file-loader":"^6.0.0","jasmine-core":"^3.5.0","jasmine-spec-reporter":"^5.0.2","jquery":"^3.5.1","karma":"^5.1.0","karma-chrome-launcher":"^3.1.0","karma-cli":"^2.0.0","karma-coverage-istanbul-reporter":"~3.0.2","karma-jasmine":"^3.3.1","karma-jasmine-html-reporter":"^1.5.4","license-checker":"^25.0.1","node-sass":"^4.14.1","popper.js":"^1.16.1","prettier":"^2.0.5","protractor":"^7.0.0","replace":"^1.2.0","rxjs-tslint":"^0.1.8","ts-mockito":"^2.6.1","ts-node":"~8.10.2","tslint":"^6.1.2","tslint-config-prettier":"^1.18.0","typescript":"^3.9.5","webpack":"^4.43.0"},"greenkeeper":{"ignore":["typescript"]},"snyk":true}')},klIg:function(t,e,n){var i=n("P3uw").consumeNumber,r=n("vd7W").TYPE.Dimension;t.exports={name:"Dimension",structure:{value:String,unit:String},parse:function(){var t=this.scanner.tokenStart,e=i(this.scanner.source,t);return this.eat(r),{type:"Dimension",loc:this.getLocation(t,this.scanner.tokenStart),value:this.scanner.source.substring(t,e),unit:this.scanner.source.substring(e,this.scanner.tokenStart)}},generate:function(t){this.chunk(t.value),this.chunk(t.unit)}}},ksOG:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("JM0U");i.Observable.prototype.auditTime=r.auditTime},l3KV:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("CuWV");i.Observable.prototype.publishLast=r.publishLast},l4jP:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.share=function(){return i.share()(this)}},l53z:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.zipAll=function(t){return i.zipAll(t)(this)}},l5mm:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("HDdC"),r=n("D0XW"),o=n("Y7HM");function a(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:r.a;return(!Object(o.a)(t)||t<0)&&(t=0),e&&"function"==typeof e.schedule||(e=r.a),new i.a((function(n){return n.add(e.schedule(s,t,{subscriber:n,counter:0,period:t})),n}))}function s(t){var e=t.subscriber,n=t.counter,i=t.period;e.next(n),this.schedule({subscriber:e,counter:n+1,period:i},i)}},l7GE:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("1OyB"),r=n("vuIU"),o=n("Ji7U"),a=n("LK+K"),s=function(t){Object(o.a)(n,t);var e=Object(a.a)(n);function n(){return Object(i.a)(this,n),e.apply(this,arguments)}return Object(r.a)(n,[{key:"notifyNext",value:function(t,e,n,i,r){this.destination.next(e)}},{key:"notifyError",value:function(t,e){this.destination.error(t)}},{key:"notifyComplete",value:function(t){this.destination.complete()}}]),n}(n("7o/Q").a)},lJxs:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("JX7q"),r=n("Ji7U"),o=n("LK+K"),a=n("1OyB"),s=n("vuIU"),c=n("7o/Q");function l(t,e){return function(n){if("function"!=typeof t)throw new TypeError("argument is not a function. Are you looking for `mapTo()`?");return n.lift(new u(t,e))}}var u=function(){function t(e,n){Object(a.a)(this,t),this.project=e,this.thisArg=n}return Object(s.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new h(t,this.project,this.thisArg))}}]),t}(),h=function(t){Object(r.a)(n,t);var e=Object(o.a)(n);function n(t,r,o){var s;return Object(a.a)(this,n),(s=e.call(this,t)).project=r,s.count=0,s.thisArg=o||Object(i.a)(s),s}return Object(s.a)(n,[{key:"_next",value:function(t){var e;try{e=this.project.call(this.thisArg,t,this.count++)}catch(n){return void this.destination.error(n)}this.destination.next(e)}}]),n}(c.a)},lK5c:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.defer=i.defer},lXds:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.delayWhen=function(t,e){return i.delayWhen(t,e)(this)}},lXnc:function(t,e){t.exports={parse:function(){return this.createSingleNodeList(this.Nth(!1))}}},lYZj:function(t,e,n){"use strict";n.r(e),n.d(e,"TestScheduler",(function(){return v}));var i=n("1OyB"),r=n("vuIU"),o=n("ReuC"),a=n("foSv"),s=n("Ji7U"),c=n("LK+K"),l=n("HDdC"),u=n("WMd4"),h=n("quSY"),d=function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.POSITIVE_INFINITY;Object(i.a)(this,t),this.subscribedFrame=e,this.unsubscribedFrame=n},f=(n("Of7M"),function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,r){var o;return Object(i.a)(this,n),(o=e.call(this,(function(t){var e=this,n=e.logSubscribedFrame(),i=new h.a;return i.add(new h.a((function(){e.logUnsubscribedFrame(n)}))),e.scheduleMessages(t),i}))).messages=t,o.subscriptions=[],o.scheduler=r,o}return Object(r.a)(n,[{key:"scheduleMessages",value:function(t){for(var e=this.messages.length,n=0;n<e;n++){var i=this.messages[n];t.add(this.scheduler.schedule((function(t){t.message.notification.observe(t.subscriber)}),i.frame,{message:i,subscriber:t}))}}}]),n}(l.a)),p=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,r){var o;return Object(i.a)(this,n),(o=e.call(this)).messages=t,o.subscriptions=[],o.scheduler=r,o}return Object(r.a)(n,[{key:"_subscribe",value:function(t){var e=this,i=e.logSubscribedFrame(),r=new h.a;return r.add(new h.a((function(){e.logUnsubscribedFrame(i)}))),r.add(Object(o.a)(Object(a.a)(n.prototype),"_subscribe",this).call(this,t)),r}},{key:"setup",value:function(){for(var t=this,e=t.messages.length,n=0;n<e;n++)!function(){var e=t.messages[n];t.scheduler.schedule((function(){e.notification.observe(t)}),e.frame)}()}}]),n}(n("XNiG").b),m=n("iKkX"),g=n("IjjT"),v=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t){var r;return Object(i.a)(this,n),(r=e.call(this,m.a,750)).assertDeepEqual=t,r.hotObservables=[],r.coldObservables=[],r.flushTests=[],r.runMode=!1,r}return Object(r.a)(n,[{key:"createTime",value:function(t){var e=t.indexOf("|");if(-1===e)throw new Error('marble diagram for time should have a completion marker "|"');return e*n.frameTimeFactor}},{key:"createColdObservable",value:function(t,e,i){if(-1!==t.indexOf("^"))throw new Error('cold observable cannot have subscription offset "^"');if(-1!==t.indexOf("!"))throw new Error('cold observable cannot have unsubscription marker "!"');var r=n.parseMarbles(t,e,i,void 0,this.runMode),o=new f(r,this);return this.coldObservables.push(o),o}},{key:"createHotObservable",value:function(t,e,i){if(-1!==t.indexOf("!"))throw new Error('hot observable cannot have unsubscription marker "!"');var r=n.parseMarbles(t,e,i,void 0,this.runMode),o=new p(r,this);return this.hotObservables.push(o),o}},{key:"materializeInnerObservable",value:function(t,e){var n=this,i=[];return t.subscribe((function(t){i.push({frame:n.frame-e,notification:u.a.createNext(t)})}),(function(t){i.push({frame:n.frame-e,notification:u.a.createError(t)})}),(function(){i.push({frame:n.frame-e,notification:u.a.createComplete()})})),i}},{key:"expectObservable",value:function(t){var e,i=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=[],a={actual:o,ready:!1},s=n.parseMarblesAsSubscriptions(r,this.runMode),c=s.subscribedFrame===Number.POSITIVE_INFINITY?0:s.subscribedFrame,h=s.unsubscribedFrame;this.schedule((function(){e=t.subscribe((function(t){var e=t;t instanceof l.a&&(e=i.materializeInnerObservable(e,i.frame)),o.push({frame:i.frame,notification:u.a.createNext(e)})}),(function(t){o.push({frame:i.frame,notification:u.a.createError(t)})}),(function(){o.push({frame:i.frame,notification:u.a.createComplete()})}))}),c),h!==Number.POSITIVE_INFINITY&&this.schedule((function(){return e.unsubscribe()}),h),this.flushTests.push(a);var d=this.runMode;return{toBe:function(t,e,i){a.ready=!0,a.expected=n.parseMarbles(t,e,i,!0,d)}}}},{key:"expectSubscriptions",value:function(t){var e={actual:t,ready:!1};this.flushTests.push(e);var i=this.runMode;return{toBe:function(t){var r="string"==typeof t?[t]:t;e.ready=!0,e.expected=r.map((function(t){return n.parseMarblesAsSubscriptions(t,i)}))}}}},{key:"flush",value:function(){for(var t=this,e=this.hotObservables;e.length>0;)e.shift().setup();Object(o.a)(Object(a.a)(n.prototype),"flush",this).call(this),this.flushTests=this.flushTests.filter((function(e){return!e.ready||(t.assertDeepEqual(e.actual,e.expected),!1)}))}},{key:"run",value:function(t){var e=n.frameTimeFactor,i=this.maxFrames;n.frameTimeFactor=1,this.maxFrames=Number.POSITIVE_INFINITY,this.runMode=!0,g.a.delegate=this;var r={cold:this.createColdObservable.bind(this),hot:this.createHotObservable.bind(this),flush:this.flush.bind(this),expectObservable:this.expectObservable.bind(this),expectSubscriptions:this.expectSubscriptions.bind(this)};try{var o=t(r);return this.flush(),o}finally{n.frameTimeFactor=e,this.maxFrames=i,this.runMode=!1,g.a.delegate=void 0}}}],[{key:"parseMarblesAsSubscriptions",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if("string"!=typeof t)return new d(Number.POSITIVE_INFINITY);for(var i=t.length,r=-1,o=Number.POSITIVE_INFINITY,a=Number.POSITIVE_INFINITY,s=0,c=0;c<i;c++){var l=s,u=function(t){l+=t*e.frameTimeFactor},h=t[c];switch(h){case" ":n||u(1);break;case"-":u(1);break;case"(":r=s,u(1);break;case")":r=-1,u(1);break;case"^":if(o!==Number.POSITIVE_INFINITY)throw new Error("found a second subscription point '^' in a subscription marble diagram. There can only be one.");o=r>-1?r:s,u(1);break;case"!":if(a!==Number.POSITIVE_INFINITY)throw new Error("found a second subscription point '^' in a subscription marble diagram. There can only be one.");a=r>-1?r:s;break;default:if(n&&h.match(/^[0-9]$/)&&(0===c||" "===t[c-1])){var f=t.slice(c),p=f.match(/^([0-9]+(?:\.[0-9]+)?)(ms|s|m) /);if(p){c+=p[0].length-1;var m=parseFloat(p[1]),g=p[2],v=void 0;switch(g){case"ms":v=m;break;case"s":v=1e3*m;break;case"m":v=1e3*m*60}u(v/this.frameTimeFactor);break}}throw new Error("there can only be '^' and '!' markers in a subscription marble diagram. Found instead '"+h+"'.")}s=l}return a<0?new d(o):new d(o,a)}},{key:"parseMarbles",value:function(t,e,n){var i=this,r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(-1!==t.indexOf("!"))throw new Error('conventional marble diagrams cannot have the unsubscription marker "!"');for(var a=t.length,s=[],c=o?t.replace(/^[ ]+/,"").indexOf("^"):t.indexOf("^"),l=-1===c?0:c*-this.frameTimeFactor,h="object"!=typeof e?function(t){return t}:function(t){return r&&e[t]instanceof f?e[t].messages:e[t]},d=-1,p=0;p<a;p++){var m=l,g=function(t){m+=t*i.frameTimeFactor},v=void 0,b=t[p];switch(b){case" ":o||g(1);break;case"-":g(1);break;case"(":d=l,g(1);break;case")":d=-1,g(1);break;case"|":v=u.a.createComplete(),g(1);break;case"^":g(1);break;case"#":v=u.a.createError(n||"error"),g(1);break;default:if(o&&b.match(/^[0-9]$/)&&(0===p||" "===t[p-1])){var y=t.slice(p),_=y.match(/^([0-9]+(?:\.[0-9]+)?)(ms|s|m) /);if(_){p+=_[0].length-1;var w=parseFloat(_[1]),k=_[2],C=void 0;switch(k){case"ms":C=w;break;case"s":C=1e3*w;break;case"m":C=1e3*w*60}g(C/this.frameTimeFactor);break}}v=u.a.createNext(h(b)),g(1)}v&&s.push({frame:d>-1?d:l,notification:v}),l=m}return s}}]),n}(m.b)},laIk:function(t,e,n){"use strict";n.r(e);var i=n("19/K");n.d(e,"ajax",(function(){return i.a}));var r=n("Sj+y");n.d(e,"AjaxResponse",(function(){return r.c})),n.d(e,"AjaxError",(function(){return r.a})),n.d(e,"AjaxTimeoutError",(function(){return r.e}))},lcII:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("wxn8");function r(t){return new i.a(t)}},lipz:function(t,e){var n,i,r,o,a,s;t.exports=(n=function(t){return"function"==typeof t},i=Math.pow(2,53)-1,r=function(t){var e=function(t){var e=Number(t);return isNaN(e)?0:0!==e&&isFinite(e)?(e>0?1:-1)*Math.floor(Math.abs(e)):e}(t);return Math.min(Math.max(e,0),i)},o=function(t){if(null!=t){if(["string","number","boolean","symbol"].indexOf(typeof t)>-1)return Symbol.iterator;if("undefined"!=typeof Symbol&&"iterator"in Symbol&&Symbol.iterator in t)return Symbol.iterator;if("@@iterator"in t)return"@@iterator"}},a=function(t,e){if(null!=t&&null!=e){var i=t[e];if(null==i)return;if(!n(i))throw new TypeError(i+" is not a function");return i}},s=function(t){var e=t.next();return!Boolean(e.done)&&e},function(t){"use strict";var e,i,c,l=this,u=arguments.length>1?arguments[1]:void 0;if(void 0!==u){if(!n(u))throw new TypeError("Array.from: when provided, the second argument must be a function");arguments.length>2&&(e=arguments[2])}var h=a(t,o(t));if(void 0!==h){i=n(l)?Object(new l):[];var d,f,p=h.call(t);if(null==p)throw new TypeError("Array.from requires an array-like or iterable object");for(c=0;;){if(!(d=s(p)))return i.length=c,i;f=d.value,i[c]=u?u.call(e,f,c):f,c++}}else{var m=Object(t);if(null==t)throw new TypeError("Array.from requires an array-like object - not null or undefined");var g,v=r(m.length);for(i=n(l)?Object(new l(v)):new Array(v),c=0;c<v;)g=m[c],i[c]=u?u.call(e,g,c):g,c++;i.length=v}return i})},m1gp:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.zip=i.zip},mCNh:function(t,e,n){"use strict";n.d(e,"a",(function(){return r})),n.d(e,"b",(function(){return o}));var i=n("SpAZ");function r(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return o(e)}function o(t){return 0===t.length?i.a:1===t.length?t[0]:function(e){return t.reduce((function(t,e){return e(t)}),e)}}},mK1g:function(t,e,n){var i=n("CwTu").SyntaxReferenceError,r=n("CwTu").MatchError,o=n("t1UP"),a=n("CJ5M"),s=n("tZmI"),c=n("vI5D"),l=n("Fm6d"),u=n("Du80"),h=n("KcB0").buildMatchGraph,d=n("QKsE").matchAsTree,f=n("/+5V"),p=n("ofj6"),m=n("Y0sX").getStructureFromConfig,g=h("inherit | initial | unset"),v=h("inherit | initial | unset | <-ms-legacy-expression>");function b(t,e,n){var i={};for(var r in t)t[r].syntax&&(i[r]=n?t[r].syntax:c(t[r].syntax,{compact:e}));return i}function y(t,e,n){return{matched:t,iterations:n,error:e,getTrace:f.getTrace,isType:f.isType,isProperty:f.isProperty,isKeyword:f.isKeyword}}function _(t,e,n,i){var o,a=u(n,t.syntax);return function(t){for(var e=0;e<t.length;e++)if("var("===t[e].value.toLowerCase())return!0;return!1}(a)?y(null,new Error("Matching for a tree with var() is not supported")):(i&&(o=d(a,t.valueCommonSyntax,t)),i&&o.match||(o=d(a,e.match,t)).match?y(o.match,null,o.iterations):y(null,new r(o.reason,e.syntax,n,o),o.iterations))}var w=function(t,e,n){if(this.valueCommonSyntax=g,this.syntax=e,this.generic=!1,this.atrules={},this.properties={},this.types={},this.structure=n||m(t),t){if(t.types)for(var i in t.types)this.addType_(i,t.types[i]);if(t.generic)for(var i in this.generic=!0,a)this.addType_(i,a[i]);if(t.atrules)for(var i in t.atrules)this.addAtrule_(i,t.atrules[i]);if(t.properties)for(var i in t.properties)this.addProperty_(i,t.properties[i])}};w.prototype={structure:{},checkStructure:function(t){function e(t,e){i.push({node:t,message:e})}var n=this.structure,i=[];return this.syntax.walk(t,(function(t){n.hasOwnProperty(t.type)?n[t.type].check(t,e):e(t,"Unknown node type `"+t.type+"`")})),!!i.length&&i},createDescriptor:function(t,e,n){var i={type:e,name:n},r={type:e,name:n,syntax:null,match:null};return"function"==typeof t?r.match=h(t,i):("string"==typeof t?Object.defineProperty(r,"syntax",{get:function(){return Object.defineProperty(r,"syntax",{value:s(t)}),r.syntax}}):r.syntax=t,Object.defineProperty(r,"match",{get:function(){return Object.defineProperty(r,"match",{value:h(r.syntax,i)}),r.match}})),r},addAtrule_:function(t,e){var n=this;this.atrules[t]={prelude:e.prelude?this.createDescriptor(e.prelude,"AtrulePrelude",t):null,descriptors:e.descriptors?Object.keys(e.descriptors).reduce((function(t,i){return t[i]=n.createDescriptor(e.descriptors[i],"AtruleDescriptor",i),t}),{}):null}},addProperty_:function(t,e){this.properties[t]=this.createDescriptor(e,"Property",t)},addType_:function(t,e){this.types[t]=this.createDescriptor(e,"Type",t),e===a["-ms-legacy-expression"]&&(this.valueCommonSyntax=v)},matchAtrulePrelude:function(t,e){var n=o.keyword(t),r=n.vendor?this.getAtrulePrelude(n.name)||this.getAtrulePrelude(n.basename):this.getAtrulePrelude(n.name);return r?_(this,r,e,!0):y(null,n.basename in this.atrules?new Error("At-rule `"+t+"` should not contain a prelude"):new i("Unknown at-rule",t))},matchAtruleDescriptor:function(t,e,n){var r=o.keyword(t),a=o.keyword(e),s=r.vendor?this.atrules[r.name]||this.atrules[r.basename]:this.atrules[r.name];if(!s)return y(null,new i("Unknown at-rule",t));if(!s.descriptors)return y(null,new Error("At-rule `"+t+"` has no known descriptors"));var c=a.vendor?s.descriptors[a.name]||s.descriptors[a.basename]:s.descriptors[a.name];return c?_(this,c,n,!0):y(null,new i("Unknown at-rule descriptor",e))},matchDeclaration:function(t){return"Declaration"!==t.type?y(null,new Error("Not a Declaration node")):this.matchProperty(t.property,t.value)},matchProperty:function(t,e){var n=o.property(t);if(n.custom)return y(null,new Error("Lexer matching doesn't applicable for custom properties"));var r=n.vendor?this.getProperty(n.name)||this.getProperty(n.basename):this.getProperty(n.name);return r?_(this,r,e,!0):y(null,new i("Unknown property",t))},matchType:function(t,e){var n=this.getType(t);return n?_(this,n,e,!1):y(null,new i("Unknown type",t))},match:function(t,e){return"string"==typeof t||t&&t.type?("string"!=typeof t&&t.match||(t=this.createDescriptor(t,"Type","anonymous")),_(this,t,e,!1)):y(null,new i("Bad syntax"))},findValueFragments:function(t,e,n,i){return p.matchFragments(this,e,this.matchProperty(t,e),n,i)},findDeclarationValueFragments:function(t,e,n){return p.matchFragments(this,t.value,this.matchDeclaration(t),e,n)},findAllFragments:function(t,e,n){var i=[];return this.syntax.walk(t,{visit:"Declaration",enter:(function(t){i.push.apply(i,this.findDeclarationValueFragments(t,e,n))}).bind(this)}),i},getAtrulePrelude:function(t){return this.atrules.hasOwnProperty(t)?this.atrules[t].prelude:null},getAtruleDescriptor:function(t,e){return this.atrules.hasOwnProperty(t)&&this.atrules.declarators&&this.atrules[t].declarators[e]||null},getProperty:function(t){return this.properties.hasOwnProperty(t)?this.properties[t]:null},getType:function(t){return this.types.hasOwnProperty(t)?this.types[t]:null},validate:function(){function t(i,r,o,a){if(o.hasOwnProperty(r))return o[r];o[r]=!1,null!==a.syntax&&l(a.syntax,(function(a){if("Type"===a.type||"Property"===a.type){var s="Type"===a.type?i.types:i.properties,c="Type"===a.type?e:n;s.hasOwnProperty(a.name)&&!t(i,a.name,c,s[a.name])||(o[r]=!0)}}),this)}var e={},n={};for(var i in this.types)t(this,i,e,this.types[i]);for(var i in this.properties)t(this,i,n,this.properties[i]);return e=Object.keys(e).filter((function(t){return e[t]})),n=Object.keys(n).filter((function(t){return n[t]})),e.length||n.length?{types:e,properties:n}:null},dump:function(t,e){return{generic:this.generic,types:b(this.types,!e,t),properties:b(this.properties,!e,t)}},toString:function(){return JSON.stringify(this.dump())}},t.exports=w},mQn8:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.mergeScan=function(t,e,n){return void 0===n&&(n=Number.POSITIVE_INFINITY),i.mergeScan(t,e,n)(this)}},mb2m:function(t,e,n){var i=n("vd7W").TYPE.Number;t.exports={name:"Number",structure:{value:String},parse:function(){return{type:"Number",loc:this.getLocation(this.scanner.tokenStart,this.scanner.tokenEnd),value:this.consume(i)}},generate:function(t){this.chunk(t.value)}}},md7G:function(t,e,n){"use strict";function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}n.d(e,"a",(function(){return o}));var r=n("JX7q");function o(t,e){return!e||"object"!==i(e)&&"function"!=typeof e?Object(r.a)(t):e}},mfsk:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.defaultIfEmpty=function(t){return void 0===t&&(t=null),i.defaultIfEmpty(t)(this)}},mlxB:function(t,e,n){"use strict";function i(t){return t instanceof Date&&!isNaN(+t)}n.d(e,"a",(function(){return i}))},mx47:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.merge=i.merge},"n/gj":function(t,e,n){t.exports={getNode:n("7GzS"),"-moz-element":n("P2RB"),element:n("P2RB"),expression:n("a3y9"),var:n("+Kd2")}},n2g9:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("bd5T");i.Observable.prototype.delay=r.delay},n6Bp:function(t,e){t.exports={name:"Nth",structure:{nth:["AnPlusB","Identifier"],selector:["SelectorList",null]},parse:function(t){this.scanner.skipSC();var e,n=this.scanner.tokenStart,i=n,r=null;return e=this.scanner.lookupValue(0,"odd")||this.scanner.lookupValue(0,"even")?this.Identifier():this.AnPlusB(),this.scanner.skipSC(),t&&this.scanner.lookupValue(0,"of")?(this.scanner.next(),r=this.SelectorList(),this.needPositions&&(i=this.getLastListNode(r.children).loc.end.offset)):this.needPositions&&(i=e.loc.end.offset),{type:"Nth",loc:this.getLocation(n,i),nth:e,selector:r}},generate:function(t){this.node(t.nth),null!==t.selector&&(this.chunk(" of "),this.node(t.selector))}}},n6Nf:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.windowToggle=function(t,e){return i.windowToggle(t,e)(this)}},n6bG:function(t,e,n){"use strict";function i(t){return"function"==typeof t}n.d(e,"a",(function(){return i}))},nYR2:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q"),c=n("quSY");function l(t){return function(e){return e.lift(new u(t))}}var u=function(){function t(e){Object(o.a)(this,t),this.callback=e}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new h(t,this.callback))}}]),t}(),h=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).add(new c.a(i)),r}return n}(s.a)},nZYK:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.switchMap=function(t){return i.switchMap(t)(this)}},ngJS:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(t){return function(e){for(var n=0,i=t.length;n<i&&!e.closed;n++)e.next(t[n]);e.complete()}}},nueD:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.isEmpty=function(){return i.isEmpty()(this)}},oB13:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("1OyB"),r=n("vuIU"),o=n("EQ5u");function a(t,e){return function(n){var i;if(i="function"==typeof t?t:function(){return t},"function"==typeof e)return n.lift(new s(i,e));var r=Object.create(n,o.b);return r.source=n,r.subjectFactory=i,r}}var s=function(){function t(e,n){Object(i.a)(this,t),this.subjectFactory=e,this.selector=n}return Object(r.a)(t,[{key:"call",value:function(t,e){var n=this.selector,i=this.subjectFactory(),r=n(i).subscribe(t);return r.add(e.subscribe(i)),r}}]),t}()},oKp4:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("ZHpM");i.Observable.prototype.take=r.take},oXC5:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.switchMapTo=function(t){return i.switchMapTo(t)(this)}},oYUb:function(t,e,n){t.exports={parseContext:{default:"StyleSheet",stylesheet:"StyleSheet",atrule:"Atrule",atrulePrelude:function(t){return this.AtrulePrelude(t.atrule?String(t.atrule):null)},mediaQueryList:"MediaQueryList",mediaQuery:"MediaQuery",rule:"Rule",selectorList:"SelectorList",selector:"Selector",block:function(){return this.Block(!0)},declarationList:"DeclarationList",declaration:"Declaration",value:"Value"},scope:n("82qP"),atrule:n("6dTv"),pseudo:n("avj0"),node:n("585i")}},ob0Y:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("QPu+");i.Observable.prototype.reduce=r.reduce},odkN:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.letProto=function(t){return t(this)}},ofYe:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("l53z");i.Observable.prototype.zipAll=r.zipAll},ofj6:function(t,e,n){var i=n("O36p");t.exports={matchFragments:function(t,e,n,r,o){var a=[];return null!==n.matched&&function n(s){if(null!==s.syntax&&s.syntax.type===r&&s.syntax.name===o){var c=function t(e){return"node"in e?e.node:t(e.match[0])}(s),l=function t(e){return"node"in e?e.node:t(e.match[e.match.length-1])}(s);t.syntax.walk(e,(function(t,e,n){if(t===c){var r=new i;do{if(r.appendData(e.data),e.data===l)break;e=e.next}while(null!==e);a.push({parent:n,nodes:r})}}))}Array.isArray(s.match)&&s.match.forEach(n)}(n.matched),a}}},"ojb+":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.range=i.range},okVX:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("pv6b");i.Observable.prototype.switch=r._switch,i.Observable.prototype._switch=r._switch},omlZ:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("r+37");i.Observable.prototype.takeUntil=r.takeUntil},ovWV:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");e.concat=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return this.lift.call(i.concat.apply(void 0,[this].concat(t)))}},pLZG:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q");function c(t,e){return function(n){return n.lift(new l(t,e))}}var l=function(){function t(e,n){Object(o.a)(this,t),this.predicate=e,this.thisArg=n}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new u(t,this.predicate,this.thisArg))}}]),t}(),u=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i,r){var a;return Object(o.a)(this,n),(a=e.call(this,t)).predicate=i,a.thisArg=r,a.count=0,a}return Object(a.a)(n,[{key:"_next",value:function(t){var e;try{e=this.predicate.call(this.thisArg,t,this.count++)}catch(n){return void this.destination.error(n)}e&&this.destination.next(t)}}]),n}(s.a)},pLzU:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("Lhse"),r=function(t){return function(e){for(var n=t[i.a]();;){var r=n.next();if(r.done){e.complete();break}if(e.next(r.value),e.closed)break}return"function"==typeof n.return&&e.add((function(){n.return&&n.return()})),e}}},"pe+M":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("fUwU");i.Observable.prototype.skip=r.skip},pjAE:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){function t(t){return Error.call(this),this.message=t?"".concat(t.length," errors occurred during unsubscription:\n").concat(t.map((function(t,e){return"".concat(e+1,") ").concat(t.toString())})).join("\n ")):"",this.name="UnsubscriptionError",this.errors=t,this}return t.prototype=Object.create(Error.prototype),t}()},pv6b:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e._switch=function(){return i.switchAll()(this)}},pxpQ:function(t,e,n){"use strict";n.d(e,"b",(function(){return l})),n.d(e,"a",(function(){return h}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q"),c=n("WMd4");function l(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return function(n){return n.lift(new u(t,e))}}var u=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;Object(o.a)(this,t),this.scheduler=e,this.delay=n}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new h(t,this.scheduler,this.delay))}}]),t}(),h=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return Object(o.a)(this,n),(r=e.call(this,t)).scheduler=i,r.delay=a,r}return Object(a.a)(n,[{key:"scheduleMessage",value:function(t){this.destination.add(this.scheduler.schedule(n.dispatch,this.delay,new d(t,this.destination)))}},{key:"_next",value:function(t){this.scheduleMessage(c.a.createNext(t))}},{key:"_error",value:function(t){this.scheduleMessage(c.a.createError(t)),this.unsubscribe()}},{key:"_complete",value:function(){this.scheduleMessage(c.a.createComplete()),this.unsubscribe()}}],[{key:"dispatch",value:function(t){t.notification.observe(t.destination),this.unsubscribe()}}]),n}(s.a),d=function t(e,n){Object(o.a)(this,t),this.notification=e,this.destination=n}},q8iP:function(t,e,n){var i=n("XDwu");t.exports=function(t,e,n){var r=i("SyntaxError",t);return r.input=e,r.offset=n,r.rawMessage=t,r.message=r.rawMessage+"\n "+r.input+"\n--"+new Array((r.offset||r.input.length)+1).join("-")+"^",r}},q8yx:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("XDL1");i.Observable.prototype.elementAt=r.elementAt},qCKp:function(t,e,n){"use strict";n.r(e),n.d(e,"Observable",(function(){return i.a})),n.d(e,"ConnectableObservable",(function(){return r.a})),n.d(e,"GroupedObservable",(function(){return o.a})),n.d(e,"observable",(function(){return a.a})),n.d(e,"Subject",(function(){return s.b})),n.d(e,"BehaviorSubject",(function(){return c.a})),n.d(e,"ReplaySubject",(function(){return l.a})),n.d(e,"AsyncSubject",(function(){return u.a})),n.d(e,"asapScheduler",(function(){return h.a})),n.d(e,"asyncScheduler",(function(){return d.a})),n.d(e,"queueScheduler",(function(){return f.a})),n.d(e,"animationFrameScheduler",(function(){return p.a})),n.d(e,"VirtualTimeScheduler",(function(){return m.b})),n.d(e,"VirtualAction",(function(){return m.a})),n.d(e,"Scheduler",(function(){return g.a})),n.d(e,"Subscription",(function(){return v.a})),n.d(e,"Subscriber",(function(){return b.a})),n.d(e,"Notification",(function(){return y.a})),n.d(e,"NotificationKind",(function(){return y.b})),n.d(e,"pipe",(function(){return _.a})),n.d(e,"noop",(function(){return w.a})),n.d(e,"identity",(function(){return k.a})),n.d(e,"isObservable",(function(){return C.a})),n.d(e,"ArgumentOutOfRangeError",(function(){return S.a})),n.d(e,"EmptyError",(function(){return x.a})),n.d(e,"ObjectUnsubscribedError",(function(){return O.a})),n.d(e,"UnsubscriptionError",(function(){return M.a})),n.d(e,"TimeoutError",(function(){return T.a})),n.d(e,"bindCallback",(function(){return D})),n.d(e,"bindNodeCallback",(function(){return F})),n.d(e,"combineLatest",(function(){return z.b})),n.d(e,"concat",(function(){return V.a})),n.d(e,"defer",(function(){return U.a})),n.d(e,"empty",(function(){return q.b})),n.d(e,"forkJoin",(function(){return G.a})),n.d(e,"from",(function(){return W.a})),n.d(e,"fromEvent",(function(){return K.a})),n.d(e,"fromEventPattern",(function(){return Y})),n.d(e,"generate",(function(){return Z})),n.d(e,"iif",(function(){return $})),n.d(e,"interval",(function(){return J.a})),n.d(e,"merge",(function(){return tt.a})),n.d(e,"never",(function(){return nt})),n.d(e,"of",(function(){return it.a})),n.d(e,"onErrorResumeNext",(function(){return rt})),n.d(e,"pairs",(function(){return ot})),n.d(e,"partition",(function(){return ut})),n.d(e,"race",(function(){return ht.a})),n.d(e,"range",(function(){return dt.b})),n.d(e,"throwError",(function(){return ft.a})),n.d(e,"timer",(function(){return pt.a})),n.d(e,"using",(function(){return mt})),n.d(e,"zip",(function(){return gt.b})),n.d(e,"scheduled",(function(){return vt.a})),n.d(e,"EMPTY",(function(){return q.a})),n.d(e,"NEVER",(function(){return et})),n.d(e,"config",(function(){return bt.a}));var i=n("HDdC"),r=n("EQ5u"),o=n("OQgR"),a=n("kJWO"),s=n("XNiG"),c=n("2Vo4"),l=n("jtHE"),u=n("NHP+"),h=n("7Hc7"),d=n("D0XW"),f=n("qgXg"),p=n("eNwd"),m=n("iKkX"),g=n("Y/cZ"),v=n("quSY"),b=n("7o/Q"),y=n("WMd4"),_=n("mCNh"),w=n("KqfI"),k=n("SpAZ"),C=n("7+OI"),S=n("4I5i"),x=n("sVev"),O=n("9ppp"),M=n("pjAE"),T=n("Y6u4"),E=n("KQm4"),P=n("lJxs"),A=n("8Qeq"),j=n("DH7j"),I=n("z+Ro");function D(t,e,n){if(e){if(!Object(I.a)(e))return function(){return D(t,n).apply(void 0,arguments).pipe(Object(P.a)((function(t){return Object(j.a)(t)?e.apply(void 0,Object(E.a)(t)):e(t)})))};n=e}return function(){for(var e=arguments.length,r=new Array(e),o=0;o<e;o++)r[o]=arguments[o];var a,s=this,c={context:s,subject:a,callbackFunc:t,scheduler:n};return new i.a((function(e){if(n)return n.schedule(R,0,{args:r,subscriber:e,params:c});if(!a){a=new u.a;try{t.apply(s,[].concat(r,[function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];a.next(e.length<=1?e[0]:e),a.complete()}]))}catch(i){Object(A.a)(a)?a.error(i):console.warn(i)}}return a.subscribe(e)}))}}function R(t){var e=this,n=t.args,i=t.subscriber,r=t.params,o=r.callbackFunc,a=r.context,s=r.scheduler,c=r.subject;if(!c){c=r.subject=new u.a;try{o.apply(a,[].concat(Object(E.a)(n),[function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];var r=n.length<=1?n[0]:n;e.add(s.schedule(L,0,{value:r,subject:c}))}]))}catch(l){c.error(l)}}this.add(c.subscribe(i))}function L(t){var e=t.subject;e.next(t.value),e.complete()}function F(t,e,n){if(e){if(!Object(I.a)(e))return function(){return F(t,n).apply(void 0,arguments).pipe(Object(P.a)((function(t){return Object(j.a)(t)?e.apply(void 0,Object(E.a)(t)):e(t)})))};n=e}return function(){for(var e=arguments.length,r=new Array(e),o=0;o<e;o++)r[o]=arguments[o];var a={subject:void 0,args:r,callbackFunc:t,scheduler:n,context:this};return new i.a((function(e){var i=a.context,o=a.subject;if(n)return n.schedule(N,0,{params:a,subscriber:e,context:i});if(!o){o=a.subject=new u.a;try{t.apply(i,[].concat(r,[function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var i=e.shift();i?o.error(i):(o.next(e.length<=1?e[0]:e),o.complete())}]))}catch(s){Object(A.a)(o)?o.error(s):console.warn(s)}}return o.subscribe(e)}))}}function N(t){var e=this,n=t.params,i=t.subscriber,r=t.context,o=n.callbackFunc,a=n.args,s=n.scheduler,c=n.subject;if(!c){c=n.subject=new u.a;try{o.apply(r,[].concat(Object(E.a)(a),[function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];var r=n.shift();if(r)e.add(s.schedule(H,0,{err:r,subject:c}));else{var o=n.length<=1?n[0]:n;e.add(s.schedule(B,0,{value:o,subject:c}))}}]))}catch(l){this.add(s.schedule(H,0,{err:l,subject:c}))}}this.add(c.subscribe(i))}function B(t){var e=t.subject;e.next(t.value),e.complete()}function H(t){t.subject.error(t.err)}var z=n("itXk"),V=n("GyhO"),U=n("NXyV"),q=n("EY2u"),G=n("cp0P"),W=n("Cfvw"),K=n("xgIS"),X=n("n6bG");function Y(t,e,n){return n?Y(t,e).pipe(Object(P.a)((function(t){return Object(j.a)(t)?n.apply(void 0,Object(E.a)(t)):n(t)}))):new i.a((function(n){var i,r=function(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return n.next(1===e.length?e[0]:e)};try{i=t(r)}catch(o){return void n.error(o)}if(Object(X.a)(e))return function(){return e(r,i)}}))}function Z(t,e,n,r,o){var a,s;return 1==arguments.length?(s=t.initialState,e=t.condition,n=t.iterate,a=t.resultSelector||k.a,o=t.scheduler):void 0===r||Object(I.a)(r)?(s=t,a=k.a,o=r):(s=t,a=r),new i.a((function(t){var i=s;if(o)return o.schedule(Q,0,{subscriber:t,iterate:n,condition:e,resultSelector:a,state:i});for(;;){if(e){var r=void 0;try{r=e(i)}catch(l){return void t.error(l)}if(!r){t.complete();break}}var c=void 0;try{c=a(i)}catch(l){return void t.error(l)}if(t.next(c),t.closed)break;try{i=n(i)}catch(l){return void t.error(l)}}}))}function Q(t){var e=t.subscriber,n=t.condition;if(!e.closed){if(t.needIterate)try{t.state=t.iterate(t.state)}catch(o){return void e.error(o)}else t.needIterate=!0;if(n){var i;try{i=n(t.state)}catch(o){return void e.error(o)}if(!i)return void e.complete();if(e.closed)return}var r;try{r=t.resultSelector(t.state)}catch(o){return void e.error(o)}if(!e.closed&&(e.next(r),!e.closed))return this.schedule(t)}}function $(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:q.a,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:q.a;return Object(U.a)((function(){return t()?e:n}))}var J=n("l5mm"),tt=n("VRyK"),et=new i.a(w.a);function nt(){return et}var it=n("LRne");function rt(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if(0===e.length)return q.a;var r=e[0],o=e.slice(1);return 1===e.length&&Object(j.a)(r)?rt.apply(void 0,Object(E.a)(r)):new i.a((function(t){var e=function(){return t.add(rt.apply(void 0,Object(E.a)(o)).subscribe(t))};return Object(W.a)(r).subscribe({next:function(e){t.next(e)},error:e,complete:e})}))}function ot(t,e){return new i.a(e?function(n){var i=Object.keys(t),r=new v.a;return r.add(e.schedule(at,0,{keys:i,index:0,subscriber:n,subscription:r,obj:t})),r}:function(e){for(var n=Object.keys(t),i=0;i<n.length&&!e.closed;i++){var r=n[i];t.hasOwnProperty(r)&&e.next([r,t[r]])}e.complete()})}function at(t){var e=t.keys,n=t.index,i=t.subscriber,r=t.subscription,o=t.obj;if(!i.closed)if(n<e.length){var a=e[n];i.next([a,o[a]]),r.add(this.schedule({keys:e,index:n+1,subscriber:i,subscription:r,obj:o}))}else i.complete()}var st=n("F97/"),ct=n("SeVD"),lt=n("pLZG");function ut(t,e,n){return[Object(lt.a)(e,n)(new i.a(Object(ct.a)(t))),Object(lt.a)(Object(st.a)(e,n))(new i.a(Object(ct.a)(t)))]}var ht=n("Nv8m"),dt=n("NNCq"),ft=n("z6cu"),pt=n("PqYM");function mt(t,e){return new i.a((function(n){var i,r;try{i=t()}catch(a){return void n.error(a)}try{r=e(i)}catch(a){return void n.error(a)}var o=(r?Object(W.a)(r):q.a).subscribe(n);return function(){o.unsubscribe(),i&&i.unsubscribe()}}))}var gt=n("1uah"),vt=n("7HRe"),bt=n("2fFW")},qIMP:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.pairwise=function(){return i.pairwise()(this)}},qgXg:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i=n("1OyB"),r=n("vuIU"),o=n("ReuC"),a=n("foSv"),s=n("Ji7U"),c=n("LK+K"),l=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,r){var o;return Object(i.a)(this,n),(o=e.call(this,t,r)).scheduler=t,o.work=r,o}return Object(r.a)(n,[{key:"schedule",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return e>0?Object(o.a)(Object(a.a)(n.prototype),"schedule",this).call(this,t,e):(this.delay=e,this.state=t,this.scheduler.flush(this),this)}},{key:"execute",value:function(t,e){return e>0||this.closed?Object(o.a)(Object(a.a)(n.prototype),"execute",this).call(this,t,e):this._execute(t,e)}},{key:"requestAsyncId",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return null!==i&&i>0||null===i&&this.delay>0?Object(o.a)(Object(a.a)(n.prototype),"requestAsyncId",this).call(this,t,e,i):t.flush(this)}}]),n}(n("3N8a").a),u=new(function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(){return Object(i.a)(this,n),e.apply(this,arguments)}return n}(n("IjjT").a))(l)},quSY:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("1OyB"),r=n("vuIU"),o=n("DH7j"),a=n("XoHu"),s=n("n6bG"),c=n("pjAE"),l=function(){var t,e=function(){function t(e){Object(i.a)(this,t),this.closed=!1,this._parentOrParents=null,this._subscriptions=null,e&&(this._unsubscribe=e)}return Object(r.a)(t,[{key:"unsubscribe",value:function(){var e;if(!this.closed){var n=this._parentOrParents,i=this._unsubscribe,r=this._subscriptions;if(this.closed=!0,this._parentOrParents=null,this._subscriptions=null,n instanceof t)n.remove(this);else if(null!==n)for(var l=0;l<n.length;++l)n[l].remove(this);if(Object(s.a)(i))try{i.call(this)}catch(p){e=p instanceof c.a?u(p.errors):[p]}if(Object(o.a)(r))for(var h=-1,d=r.length;++h<d;){var f=r[h];if(Object(a.a)(f))try{f.unsubscribe()}catch(p){e=e||[],p instanceof c.a?e=e.concat(u(p.errors)):e.push(p)}}if(e)throw new c.a(e)}}},{key:"add",value:function(e){var n=e;if(!e)return t.EMPTY;switch(typeof e){case"function":n=new t(e);case"object":if(n===this||n.closed||"function"!=typeof n.unsubscribe)return n;if(this.closed)return n.unsubscribe(),n;if(!(n instanceof t)){var i=n;(n=new t)._subscriptions=[i]}break;default:throw new Error("unrecognized teardown "+e+" added to Subscription.")}var r=n._parentOrParents;if(null===r)n._parentOrParents=this;else if(r instanceof t){if(r===this)return n;n._parentOrParents=[r,this]}else{if(-1!==r.indexOf(this))return n;r.push(this)}var o=this._subscriptions;return null===o?this._subscriptions=[n]:o.push(n),n}},{key:"remove",value:function(t){var e=this._subscriptions;if(e){var n=e.indexOf(t);-1!==n&&e.splice(n,1)}}}]),t}();return e.EMPTY=((t=new e).closed=!0,t),e}();function u(t){return t.reduce((function(t,e){return t.concat(e instanceof c.a?e.errors:e)}),[])}},"r+37":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.takeUntil=function(t){return i.takeUntil(t)(this)}},r0WS:function(t,e,n){"use strict";n.d(e,"b",(function(){return a})),n.d(e,"a",(function(){return s}));var i=n("1OyB"),r=n("D0XW"),o=n("lJxs");function a(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:r.a;return Object(o.a)((function(e){return new s(e,t.now())}))}var s=function t(e,n){Object(i.a)(this,t),this.value=e,this.timestamp=n}},r1XK:function(t,e,n){var i=n("vd7W").TYPE.String;t.exports={name:"String",structure:{value:String},parse:function(){return{type:"String",loc:this.getLocation(this.scanner.tokenStart,this.scanner.tokenEnd),value:this.consume(i)}},generate:function(t){this.chunk(t.value)}}},rSqW:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("8LQU");i.Observable.prototype.subscribeOn=r.subscribeOn},rqY6:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("zDpS");i.Observable.prototype.timeoutWith=r.timeoutWith},s4An:function(t,e,n){"use strict";function i(t,e){return(i=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}n.d(e,"a",(function(){return i}))},sNY3:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.combineLatest=i.combineLatest},sQiz:function(t,e,n){var i=n("Cbry");function r(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}r.prototype.unsortedForEach=function(t,e){this._array.forEach(t,e)},r.prototype.add=function(t){var e,n,r,o;(o=(n=t).generatedLine)>(r=(e=this._last).generatedLine)||o==r&&n.generatedColumn>=e.generatedColumn||i.compareByGeneratedPositionsInflated(e,n)<=0?(this._last=t,this._array.push(t)):(this._sorted=!1,this._array.push(t))},r.prototype.toArray=function(){return this._sorted||(this._array.sort(i.compareByGeneratedPositionsInflated),this._sorted=!0),this._array},e.MappingList=r},sRqT:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("xwTN");i.Observable.prototype.flatMapTo=r.mergeMapTo,i.Observable.prototype.mergeMapTo=r.mergeMapTo},sVev:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){function t(){return Error.call(this),this.message="no elements in sequence",this.name="EmptyError",this}return t.prototype=Object.create(Error.prototype),t}()},sjkp:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("6mJ0");i.Observable.prototype.findIndex=r.findIndex},t0XI:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.onErrorResumeNext=i.onErrorResumeNext},t1UP:function(t,e){var n=Object.prototype.hasOwnProperty,i=Object.create(null),r=Object.create(null);function o(t,e){return t.length-(e=e||0)>=2&&45===t.charCodeAt(e)&&45===t.charCodeAt(e+1)}function a(t,e){if(t.length-(e=e||0)>=3&&45===t.charCodeAt(e)&&45!==t.charCodeAt(e+1)){var n=t.indexOf("-",e+2);if(-1!==n)return t.substring(e,n+1)}return""}t.exports={keyword:function(t){if(n.call(i,t))return i[t];var e=t.toLowerCase();if(n.call(i,e))return i[t]=i[e];var r=o(e,0),s=r?"":a(e,0);return i[t]=Object.freeze({basename:e.substr(s.length),name:e,vendor:s,prefix:s,custom:r})},property:function(t){if(n.call(r,t))return r[t];var e=t,i=t[0];"/"===i?i="/"===t[1]?"//":"/":"_"!==i&&"*"!==i&&"$"!==i&&"#"!==i&&"+"!==i&&"&"!==i&&(i="");var s=o(e,i.length);if(!s&&(e=e.toLowerCase(),n.call(r,e)))return r[t]=r[e];var c=s?"":a(e,i.length),l=e.substr(0,i.length+c.length);return r[t]=Object.freeze({basename:e.substr(l.length),name:e.substr(i.length),hack:i,vendor:c,prefix:l,custom:s})},isCustomProperty:o,vendorPrefix:a}},tZmI:function(t,e,n){var i=n("eWth"),r=function(t){for(var e="function"==typeof Uint32Array?new Uint32Array(128):new Array(128),n=0;n<128;n++)e[n]=(i=String.fromCharCode(n),/[a-zA-Z0-9\-]/.test(i)?1:0);var i;return e}(),o={" ":1,"&&":2,"||":3,"|":4};function a(t){return t.substringToPos(t.findWsEnd(t.pos))}function s(t){for(var e=t.pos;e<t.str.length;e++){var n=t.str.charCodeAt(e);if(n>=128||0===r[n])break}return t.pos===e&&t.error("Expect a keyword"),t.substringToPos(e)}function c(t){for(var e=t.pos;e<t.str.length;e++){var n=t.str.charCodeAt(e);if(n<48||n>57)break}return t.pos===e&&t.error("Expect a number"),t.substringToPos(e)}function l(t){var e=t.str.indexOf("'",t.pos+1);return-1===e&&(t.pos=t.str.length,t.error("Expect an apostrophe")),t.substringToPos(e+1)}function u(t){var e,n=null;return t.eat(123),e=c(t),44===t.charCode()?(t.pos++,125!==t.charCode()&&(n=c(t))):n=e,t.eat(125),{min:Number(e),max:n?Number(n):0}}function h(t,e){var n=function(t){var e=null,n=!1;switch(t.charCode()){case 42:t.pos++,e={min:0,max:0};break;case 43:t.pos++,e={min:1,max:0};break;case 63:t.pos++,e={min:0,max:1};break;case 35:t.pos++,n=!0,e=123===t.charCode()?u(t):{min:1,max:0};break;case 123:e=u(t);break;default:return null}return{type:"Multiplier",comma:n,min:e.min,max:e.max,term:null}}(t);return null!==n?(n.term=e,n):e}function d(t){var e=t.peek();return""===e?null:{type:"Token",value:e}}function f(t,e){function n(t,e){return{type:"Group",terms:t,combinator:e,disallowEmpty:!1,explicit:!1}}for(e=Object.keys(e).sort((function(t,e){return o[t]-o[e]}));e.length>0;){for(var i=e.shift(),r=0,a=0;r<t.length;r++){var s=t[r];"Combinator"===s.type&&(s.value===i?(-1===a&&(a=r-1),t.splice(r,1),r--):(-1!==a&&r-a>1&&(t.splice(a,r-a,n(t.slice(a,r),i)),r=a+1),a=-1))}-1!==a&&e.length&&t.splice(a,r-a,n(t.slice(a,r),i))}return i}function p(t){for(var e,n=[],i={},r=null,o=t.pos;e=m(t);)"Spaces"!==e.type&&("Combinator"===e.type?(null!==r&&"Combinator"!==r.type||(t.pos=o,t.error("Unexpected combinator")),i[e.value]=!0):null!==r&&"Combinator"!==r.type&&(i[" "]=!0,n.push({type:"Combinator",value:" "})),n.push(e),r=e,o=t.pos);return null!==r&&"Combinator"===r.type&&(t.pos-=o,t.error("Unexpected combinator")),{type:"Group",terms:n,combinator:f(n,i)||" ",disallowEmpty:!1,explicit:!1}}function m(t){var e=t.charCode();if(e<128&&1===r[e])return function(t){var e;return e=s(t),40===t.charCode()?(t.pos++,{type:"Function",name:e}):h(t,{type:"Keyword",name:e})}(t);switch(e){case 93:break;case 91:return h(t,function(t){var e;return t.eat(91),e=p(t),t.eat(93),e.explicit=!0,33===t.charCode()&&(t.pos++,e.disallowEmpty=!0),e}(t));case 60:return 39===t.nextCharCode()?function(t){var e;return t.eat(60),t.eat(39),e=s(t),t.eat(39),t.eat(62),h(t,{type:"Property",name:e})}(t):function(t){var e,n=null;return t.eat(60),e=s(t),40===t.charCode()&&41===t.nextCharCode()&&(t.pos+=2,e+="()"),91===t.charCodeAt(t.findWsEnd(t.pos))&&(a(t),n=function(t){var e=null,n=null,i=1;return t.eat(91),45===t.charCode()&&(t.peek(),i=-1),-1==i&&8734===t.charCode()?t.peek():e=i*Number(c(t)),a(t),t.eat(44),a(t),8734===t.charCode()?t.peek():(i=1,45===t.charCode()&&(t.peek(),i=-1),n=i*Number(c(t))),t.eat(93),null===e&&null===n?null:{type:"Range",min:e,max:n}}(t)),t.eat(62),h(t,{type:"Type",name:e,opts:n})}(t);case 124:return{type:"Combinator",value:t.substringToPos(124===t.nextCharCode()?t.pos+2:t.pos+1)};case 38:return t.pos++,t.eat(38),{type:"Combinator",value:"&&"};case 44:return t.pos++,{type:"Comma"};case 39:return h(t,{type:"String",value:l(t)});case 32:case 9:case 10:case 13:case 12:return{type:"Spaces",value:a(t)};case 64:return(e=t.nextCharCode())<128&&1===r[e]?(t.pos++,{type:"AtKeyword",name:s(t)}):d(t);case 42:case 43:case 63:case 35:case 33:break;case 123:if((e=t.nextCharCode())<48||e>57)return d(t);break;default:return d(t)}}function g(t){var e=new i(t),n=p(e);return e.pos!==t.length&&e.error("Unexpected input"),1===n.terms.length&&"Group"===n.terms[0].type&&(n=n.terms[0]),n}g("[a&&<b>#|<'c'>*||e() f{2} /,(% g#{1,2} h{2,})]!"),t.exports=g},"te+T":function(t,e){t.exports={parse:function(){return this.createSingleNodeList(this.SelectorList())}}},tnsW:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("l7GE"),c=n("ZUHj");function l(t){return function(e){return e.lift(new u(t))}}var u=function(){function t(e){Object(o.a)(this,t),this.durationSelector=e}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new h(t,this.durationSelector))}}]),t}(),h=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).durationSelector=i,r.hasValue=!1,r}return Object(a.a)(n,[{key:"_next",value:function(t){if(this.value=t,this.hasValue=!0,!this.throttled){var e;try{e=(0,this.durationSelector)(t)}catch(i){return this.destination.error(i)}var n=Object(c.a)(this,e);!n||n.closed?this.clearThrottle():this.add(this.throttled=n)}}},{key:"clearThrottle",value:function(){var t=this.value,e=this.hasValue,n=this.throttled;n&&(this.remove(n),this.throttled=null,n.unsubscribe()),e&&(this.value=null,this.hasValue=!1,this.destination.next(t))}},{key:"notifyNext",value:function(t,e,n,i){this.clearThrottle()}},{key:"notifyComplete",value:function(){this.clearThrottle()}}]),n}(s.a)},twQA:function(t,e){var n={EOF:0,Ident:1,Function:2,AtKeyword:3,Hash:4,String:5,BadString:6,Url:7,BadUrl:8,Delim:9,Number:10,Percentage:11,Dimension:12,WhiteSpace:13,CDO:14,CDC:15,Colon:16,Semicolon:17,Comma:18,LeftSquareBracket:19,RightSquareBracket:20,LeftParenthesis:21,RightParenthesis:22,LeftCurlyBracket:23,RightCurlyBracket:24,Comment:25},i=Object.keys(n).reduce((function(t,e){return t[n[e]]=e,t}),{});t.exports={TYPE:n,NAME:i}},twrC:function(t,e,n){t.exports=n("errG")},u5kB:function(t,e,n){var i=n("KjDf"),r=n("1aLD"),o=n("8wsT"),a=n("O36p"),s=n("vd7W"),c=n("twQA"),l=n("P3uw").findWhiteSpaceStart,u=n("OohF"),h=function(){},d=c.TYPE,f=c.NAME,p=d.WhiteSpace,m=d.Ident,g=d.Function,v=d.Url,b=d.Hash,y=d.Percentage,_=d.Number;function w(t){return function(){return this[t]()}}t.exports=function(t){var e={scanner:new o,locationMap:new i,filename:"<unknown>",needPositions:!1,onParseError:h,onParseErrorThrow:!1,parseAtrulePrelude:!0,parseRulePrelude:!0,parseValue:!0,parseCustomProperty:!1,readSequence:u,createList:function(){return new a},createSingleNodeList:function(t){return(new a).appendData(t)},getFirstListNode:function(t){return t&&t.first()},getLastListNode:function(t){return t.last()},parseWithFallback:function(t,e){var n=this.scanner.tokenIndex;try{return t.call(this)}catch(r){if(this.onParseErrorThrow)throw r;var i=e.call(this,n);return this.onParseErrorThrow=!0,this.onParseError(r,i),this.onParseErrorThrow=!1,i}},lookupNonWSType:function(t){do{var e=this.scanner.lookupType(t++);if(e!==p)return e}while(0!==e);return 0},eat:function(t){if(this.scanner.tokenType!==t){var e=this.scanner.tokenStart,n=f[t]+" is expected";switch(t){case m:this.scanner.tokenType===g||this.scanner.tokenType===v?(e=this.scanner.tokenEnd-1,n="Identifier is expected but function found"):n="Identifier is expected";break;case b:this.scanner.isDelim(35)&&(this.scanner.next(),e++,n="Name is expected");break;case y:this.scanner.tokenType===_&&(e=this.scanner.tokenEnd,n="Percent sign is expected");break;default:this.scanner.source.charCodeAt(this.scanner.tokenStart)===t&&(e+=1)}this.error(n,e)}this.scanner.next()},consume:function(t){var e=this.scanner.getTokenValue();return this.eat(t),e},consumeFunctionName:function(){var t=this.scanner.source.substring(this.scanner.tokenStart,this.scanner.tokenEnd-1);return this.eat(g),t},getLocation:function(t,e){return this.needPositions?this.locationMap.getLocationRange(t,e,this.filename):null},getLocationFromList:function(t){if(this.needPositions){var e=this.getFirstListNode(t),n=this.getLastListNode(t);return this.locationMap.getLocationRange(null!==e?e.loc.start.offset-this.locationMap.startOffset:this.scanner.tokenStart,null!==n?n.loc.end.offset-this.locationMap.startOffset:this.scanner.tokenStart,this.filename)}return null},error:function(t,e){var n=this.locationMap.getLocation(void 0!==e&&e<this.scanner.source.length?e:this.scanner.eof?l(this.scanner.source,this.scanner.source.length-1):this.scanner.tokenStart);throw new r(t||"Unexpected input",this.scanner.source,n.offset,n.line,n.column)}};for(var n in t=function(t){var e={context:{},scope:{},atrule:{},pseudo:{}};if(t.parseContext)for(var n in t.parseContext)switch(typeof t.parseContext[n]){case"function":e.context[n]=t.parseContext[n];break;case"string":e.context[n]=w(t.parseContext[n])}if(t.scope)for(var n in t.scope)e.scope[n]=t.scope[n];if(t.atrule)for(var n in t.atrule){var i=t.atrule[n];i.parse&&(e.atrule[n]=i.parse)}if(t.pseudo)for(var n in t.pseudo){var r=t.pseudo[n];r.parse&&(e.pseudo[n]=r.parse)}if(t.node)for(var n in t.node)e[n]=t.node[n].parse;return e}(t||{}))e[n]=t[n];return function(t,n){var i,r=(n=n||{}).context||"default";if(s(t,e.scanner),e.locationMap.setSource(t,n.offset,n.line,n.column),e.filename=n.filename||"<unknown>",e.needPositions=Boolean(n.positions),e.onParseError="function"==typeof n.onParseError?n.onParseError:h,e.onParseErrorThrow=!1,e.parseAtrulePrelude=!("parseAtrulePrelude"in n)||Boolean(n.parseAtrulePrelude),e.parseRulePrelude=!("parseRulePrelude"in n)||Boolean(n.parseRulePrelude),e.parseValue=!("parseValue"in n)||Boolean(n.parseValue),e.parseCustomProperty="parseCustomProperty"in n&&Boolean(n.parseCustomProperty),!e.context.hasOwnProperty(r))throw new Error("Unknown context `"+r+"`");return i=e.context[r].call(e,n),e.scanner.eof||e.error(),i}}},uARb:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.debounce=function(t){return i.debounce(t)(this)}},uGYe:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp");i.Observable.if=i.iif},uMIJ:function(t,e,n){t.exports="function"==typeof Array.from?Array.from:n("lipz")},uMcE:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.shareReplay=function(t,e,n){return t&&"object"==typeof t?i.shareReplay(t)(this):i.shareReplay(t,e,n)(this)}},uO2z:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("3uOa");i.Observable.webSocket=r.webSocket},uzHG:function(t,e,n){"use strict";var i,r=void 0;"function"!=typeof Object.create?(i=function(){},r=function(t,e){if(t!==Object(t)&&null!==t)throw TypeError("Argument must be an object, or null");i.prototype=t||{};var n=new i;return i.prototype=null,void 0!==e&&Object.defineProperties(n,e),null===t&&(n.__proto__=null),n}):r=Object.create;var o=r,a=["altKey","button","buttons","clientX","clientY","ctrlKey","metaKey","movementX","movementY","offsetX","offsetY","pageX","pageY","region","relatedTarget","screenX","screenY","shiftKey","which","x","y"];function s(t,e){e=e||{};for(var n=o(t),i=0;i<a.length;i++)void 0!==e[a[i]]&&(n[a[i]]=e[a[i]]);return n}function c(t,e){console.log("data ",e),t.data=e||{},t.dispatched="mousemove"}t.exports=function(t){var e={screenX:0,screenY:0,clientX:0,clientY:0,ctrlKey:!1,shiftKey:!1,altKey:!1,metaKey:!1,button:0,buttons:1,relatedTarget:null,region:null};function n(t){for(var n=0;n<a.length;n++)e[a[n]]=t[a[n]]}return void 0!==t&&t.addEventListener("mousemove",n),{destroy:function(){t&&t.removeEventListener("mousemove",n,!1),e=null},dispatch:MouseEvent?function(t,n,i){var r=new MouseEvent("mousemove",s(e,n));return c(r,i),t.dispatchEvent(r)}:"function"==typeof document.createEvent?function(t,n,i){var r=s(e,n),o=document.createEvent("MouseEvents");return o.initMouseEvent("mousemove",!0,!0,window,0,r.screenX,r.screenY,r.clientX,r.clientY,r.ctrlKey,r.altKey,r.shiftKey,r.metaKey,r.button,r.relatedTarget),c(o,i),t.dispatchEvent(o)}:"function"==typeof document.createEventObject?function(t,n,i){var r=document.createEventObject(),o=s(e,n);for(var a in o)r[a]=o[a];return c(r,i),t.dispatchEvent(r)}:void 0}}},v87U:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.single=function(t){return i.single(t)(this)}},vAVA:function(t,e,n){"use strict";var i;!function(){var n=e||{}||this||window;void 0===(i=(function(){return n}).apply(e,[]))||(t.exports=i),n.default=n;var r="http://www.w3.org/2000/xmlns/",o="http://www.w3.org/2000/svg",a=/url\(["']?(.+?)["']?\)/,s={woff2:"font/woff2",woff:"font/woff",otf:"application/x-font-opentype",ttf:"application/x-font-ttf",eot:"application/vnd.ms-fontobject",sfnt:"application/font-sfnt",svg:"image/svg+xml"},c=function(t){return t instanceof HTMLElement||t instanceof SVGElement},l=function(t){if(!c(t))throw new Error("an HTMLElement or SVGElement is required; got "+t)},u=function(t){return new Promise((function(e,n){c(t)?e(t):n(new Error("an HTMLElement or SVGElement is required; got "+t))}))},h=function(t,e,n){var i=t.viewBox&&t.viewBox.baseVal&&t.viewBox.baseVal[n]||null!==e.getAttribute(n)&&!e.getAttribute(n).match(/%$/)&&parseInt(e.getAttribute(n))||t.getBoundingClientRect()[n]||parseInt(e.style[n])||parseInt(window.getComputedStyle(t).getPropertyValue(n));return null==i||isNaN(parseFloat(i))?0:i},d=function(t){for(var e=window.atob(t.split(",")[1]),n=t.split(",")[0].split(":")[1].split(";")[0],i=new ArrayBuffer(e.length),r=new Uint8Array(i),o=0;o<e.length;o++)r[o]=e.charCodeAt(o);return new Blob([i],{type:n})},f={},p=null,m=function(){if(!navigator.msSaveOrOpenBlob&&!("download"in document.createElement("a")))return{popup:window.open()}};n.prepareSvg=function(t,e,n){l(t);var i=e||{},c=i.left,u=void 0===c?0:c,d=i.top,m=void 0===d?0:d,g=i.width,v=i.height,b=i.scale,y=void 0===b?1:b,_=i.responsive,w=void 0!==_&&_,k=i.excludeCss,C=void 0!==k&&k;return function(t){return Promise.all(Array.from(t.querySelectorAll("image")).map((function(t){var e,n=t.getAttributeNS("http://www.w3.org/1999/xlink","href")||t.getAttribute("href");return n?((e=n)&&0===e.lastIndexOf("http",0)&&-1===e.lastIndexOf(window.location.host)&&(n+=(-1===n.indexOf("?")?"?":"&")+"t="+(new Date).valueOf()),new Promise((function(e,i){var r=document.createElement("canvas"),o=new Image;o.crossOrigin="anonymous",o.src=n,o.onerror=function(){return i(new Error("Could not load "+n))},o.onload=function(){r.width=o.width,r.height=o.height,r.getContext("2d").drawImage(o,0,0),t.setAttributeNS("http://www.w3.org/1999/xlink","href",r.toDataURL("image/png")),e(!0)}}))):Promise.resolve(null)})))}(t).then((function(){var i=t.cloneNode(!0);i.style.backgroundColor=(e||{}).backgroundColor||t.style.backgroundColor;var c=function(t,e,n,i){if("svg"===t.tagName)return{width:n||h(t,e,"width"),height:i||h(t,e,"height")};if(t.getBBox){var r=t.getBBox();return{width:r.x+r.width,height:r.y+r.height}}}(t,i,g,v),l=c.width,d=c.height;if("svg"!==t.tagName){if(!t.getBBox)return void console.error("Attempted to render non-SVG element",t);null!=i.getAttribute("transform")&&i.setAttribute("transform",i.getAttribute("transform").replace(/translate\(.*?\)/,""));var b=document.createElementNS("http://www.w3.org/2000/svg","svg");b.appendChild(i),i=b}if(i.setAttribute("version","1.1"),i.setAttribute("viewBox",[u,m,l,d].join(" ")),i.getAttribute("xmlns")||i.setAttributeNS(r,"xmlns",o),i.getAttribute("xmlns:xlink")||i.setAttributeNS(r,"xmlns:xlink","http://www.w3.org/1999/xlink"),w?(i.removeAttribute("width"),i.removeAttribute("height"),i.setAttribute("preserveAspectRatio","xMinYMin meet")):(i.setAttribute("width",l*y),i.setAttribute("height",d*y)),Array.from(i.querySelectorAll("foreignObject > *")).forEach((function(t){t.setAttributeNS(r,"xmlns","svg"===t.tagName?o:"http://www.w3.org/1999/xhtml")})),!C)return function(t,e){var n=e||{},i=n.selectorRemap,r=n.modifyStyle,o=n.fonts,c=n.excludeUnusedCss,l=n.modifyCss||function(t,e){return(i?i(t):t)+"{"+(r?r(e):e)+"}\n"},u=[],h=void 0===o,d=o||[];return(p||(p=Array.from(document.styleSheets).map((function(t){try{return{rules:t.cssRules,href:t.href}}catch(e){return console.warn("Stylesheet could not be loaded: "+t.href,e),{}}})))).forEach((function(e){var n=e.rules,i=e.href;n&&Array.from(n).forEach((function(e){if(void 0!==e.style)if(function(t,e){if(e)try{return t.querySelector(e)||t.parentNode&&t.parentNode.querySelector(e)}catch(n){console.warn('Invalid CSS selector "'+e+'"',n)}}(t,e.selectorText))u.push(l(e.selectorText,e.style.cssText));else if(h&&e.cssText.match(/^@font-face/)){var n=function(t,e){var n=t.cssText.match(a),i=n&&n[1]||"";if(i&&!i.match(/^data:/)&&"about:blank"!==i){var r,o,c=i.startsWith("../")?e+"/../"+i:i.startsWith("./")?e+"/."+i:i;return{text:t.cssText,format:(r=c,o=Object.keys(s).filter((function(t){return r.indexOf("."+t)>0})).map((function(t){return s[t]})),o?o[0]:(console.error("Unknown font format for "+r+". Fonts may not be working correctly."),"application/octet-stream")),url:c}}}(e,i);n&&d.push(n)}else c||u.push(e.cssText)}))})),function(t){return Promise.all(t.map((function(t){return new Promise((function(e,n){if(f[t.url])return e(f[t.url]);var i=new XMLHttpRequest;i.addEventListener("load",(function(){var n=function(t){for(var e="",n=new Uint8Array(t),i=0;i<n.byteLength;i++)e+=String.fromCharCode(n[i]);return window.btoa(e)}(i.response),r=t.text.replace(a,'url("data:'+t.format+";base64,"+n+'")')+"\n";f[t.url]=r,e(r)})),i.addEventListener("error",(function(n){console.warn("Failed to load font from: "+t.url,n),f[t.url]=null,e(null)})),i.addEventListener("abort",(function(n){console.warn("Aborted loading font from: "+t.url,n),e(null)})),i.open("GET",t.url),i.responseType="arraybuffer",i.send()}))}))).then((function(t){return t.filter((function(t){return t})).join("")}))}(d).then((function(t){return u.join("\n")+t}))}(t,e).then((function(t){var e=document.createElement("style");e.setAttribute("type","text/css"),e.innerHTML="<![CDATA[\n"+t+"\n]]>";var r=document.createElement("defs");r.appendChild(e),i.insertBefore(r,i.firstChild);var o=document.createElement("div");o.appendChild(i);var a=o.innerHTML.replace(/NS\d+:href/gi,'xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href');if("function"!=typeof n)return{src:a,width:l,height:d};n(a,l,d)}));var _=document.createElement("div");_.appendChild(i);var k=_.innerHTML;if("function"!=typeof n)return{src:k,width:l,height:d};n(k,l,d)}))},n.svgAsDataUri=function(t,e,i){return l(t),n.prepareSvg(t,e).then((function(t){var e=t.width,n=t.height,r="data:image/svg+xml;base64,"+window.btoa(decodeURIComponent(encodeURIComponent('<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [<!ENTITY nbsp "&#160;">]>'+t.src).replace(/%([0-9A-F]{2})/g,(function(t,e){var n=String.fromCharCode("0x"+e);return"%"===n?"%25":n}))));return"function"==typeof i&&i(r,e,n),r}))},n.svgAsPngUri=function(t,e,i){l(t);var r=e||{},o=r.encoderType,a=void 0===o?"image/png":o,s=r.encoderOptions,c=void 0===s?.8:s,u=r.canvg,h=function(t){var e=t.src,n=t.width,r=t.height,o=document.createElement("canvas"),s=o.getContext("2d"),l=window.devicePixelRatio||1;o.width=n*l,o.height=r*l,o.style.width=o.width+"px",o.style.height=o.height+"px",s.setTransform(l,0,0,l,0,0),u?u(o,e):s.drawImage(e,0,0);var h=void 0;try{h=o.toDataURL(a,c)}catch(d){if("undefined"!=typeof SecurityError&&d instanceof SecurityError||"SecurityError"===d.name)return void console.error("Rendered SVG images cannot be downloaded in this browser.");throw d}return"function"==typeof i&&i(h,o.width,o.height),Promise.resolve(h)};return u?n.prepareSvg(t,e).then(h):n.svgAsDataUri(t,e).then((function(t){return new Promise((function(e,n){var i=new Image;i.onload=function(){return e(h({src:i,width:i.width,height:i.height}))},i.onerror=function(){n("There was an error loading the data URI as an image on the following SVG\n"+window.atob(t.slice(26))+"Open the following link to see browser's diagnosis\n"+t)},i.src=t}))}))},n.download=function(t,e,n){if(navigator.msSaveOrOpenBlob)navigator.msSaveOrOpenBlob(d(e),t);else{var i=document.createElement("a");if("download"in i){i.download=t,i.style.display="none",document.body.appendChild(i);try{var r=d(e),o=URL.createObjectURL(r);i.href=o,i.onclick=function(){return requestAnimationFrame((function(){return URL.revokeObjectURL(o)}))}}catch(a){console.error(a),console.warn("Error while getting object URL. Falling back to string URL."),i.href=e}i.click(),document.body.removeChild(i)}else n&&n.popup&&(n.popup.document.title=t,n.popup.location.replace(e))}},n.saveSvg=function(t,e,i){var r=m();return u(t).then((function(t){return n.svgAsDataUri(t,i||{})})).then((function(t){return n.download(e,t,r)}))},n.saveSvgAsPng=function(t,e,i){var r=m();return u(t).then((function(t){return n.svgAsPngUri(t,i||{})})).then((function(t){return n.download(e,t,r)}))}}()},vI5D:function(t,e){function n(t){return t}t.exports=function(t,e){var i=n,r=!1,o=!1;return"function"==typeof e?i=e:e&&(r=Boolean(e.forceBraces),o=Boolean(e.compact),"function"==typeof e.decorate&&(i=e.decorate)),function t(e,n,i,r){var o,a;switch(e.type){case"Group":o=function(e,n,i,r){var o=" "===e.combinator||r?e.combinator:" "+e.combinator+" ",a=e.terms.map((function(e){return t(e,n,i,r)})).join(o);return(e.explicit||i)&&(a=(r||","===a[0]?"[":"[ ")+a+(r?"]":" ]")),a}(e,n,i,r)+(e.disallowEmpty?"!":"");break;case"Multiplier":return t(e.term,n,i,r)+n(0===(a=e).min&&0===a.max?"*":0===a.min&&1===a.max?"?":1===a.min&&0===a.max?a.comma?"#":"+":1===a.min&&1===a.max?"":(a.comma?"#":"")+(a.min===a.max?"{"+a.min+"}":"{"+a.min+","+(0!==a.max?a.max:"")+"}"),e);case"Type":o="<"+e.name+(e.opts?n(function(t){switch(t.type){case"Range":return" ["+(null===t.min?"-\u221e":t.min)+","+(null===t.max?"\u221e":t.max)+"]";default:throw new Error("Unknown node type `"+t.type+"`")}}(e.opts),e.opts):"")+">";break;case"Property":o="<'"+e.name+"'>";break;case"Keyword":o=e.name;break;case"AtKeyword":o="@"+e.name;break;case"Function":o=e.name+"(";break;case"String":case"Token":o=e.value;break;case"Comma":o=",";break;default:throw new Error("Unknown node type `"+e.type+"`")}return n(o,e)}(t,i,r,o)}},vQc4:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("itJ+");i.Observable.prototype.bufferCount=r.bufferCount},vTln:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.distinct=function(t,e){return i.distinct(t,e)(this)}},vd7W:function(t,e,n){var i=n("8wsT"),r=n("Sean"),o=n("twQA"),a=o.TYPE,s=n("3XNy"),c=s.isNewline,l=s.isName,u=s.isValidEscape,h=s.isNumberStart,d=s.isIdentifierStart,f=s.charCodeCategory,p=s.isBOM,m=n("P3uw"),g=m.cmpStr,v=m.getNewlineLength,b=m.findWhiteSpaceEnd,y=m.consumeEscaped,_=m.consumeName,w=m.consumeNumber,k=m.consumeBadUrlRemnants;function C(t,e){function n(e){return e<C?t.charCodeAt(e):0}function o(){return T=w(t,T),d(n(T),n(T+1),n(T+2))?(I=a.Dimension,void(T=_(t,T))):37===n(T)?(I=a.Percentage,void T++):void(I=a.Number)}function s(){var e=T;return T=_(t,T),g(t,e,T,"url")&&40===n(T)?34===n(T=b(t,T+1))||39===n(T)?(I=a.Function,void(T=e+4)):void function(){for(I=a.Url,T=b(t,T);T<t.length;T++){var e=t.charCodeAt(T);switch(f(e)){case 41:return void T++;case f.Eof:return;case f.WhiteSpace:return 41===n(T=b(t,T))||T>=t.length?void(T<t.length&&T++):(T=k(t,T),void(I=a.BadUrl));case 34:case 39:case 40:case f.NonPrintable:return T=k(t,T),void(I=a.BadUrl);case 92:if(u(e,n(T+1))){T=y(t,T)-1;break}return T=k(t,T),void(I=a.BadUrl)}}}():40===n(T)?(I=a.Function,void T++):void(I=a.Ident)}function m(e){for(e||(e=n(T++)),I=a.String;T<t.length;T++){var i=t.charCodeAt(T);switch(f(i)){case e:return void T++;case f.Eof:return;case f.WhiteSpace:if(c(i))return T+=v(t,T,i),void(I=a.BadString);break;case 92:if(T===t.length-1)break;var r=n(T+1);c(r)?T+=v(t,T+1,r):u(i,r)&&(T=y(t,T)-1)}}}e||(e=new i);for(var C=(t=String(t||"")).length,S=r(e.offsetAndType,C+1),x=r(e.balance,C+1),O=0,M=p(n(0)),T=M,E=0,P=0,A=0;T<C;){var j=t.charCodeAt(T),I=0;switch(x[O]=C,f(j)){case f.WhiteSpace:I=a.WhiteSpace,T=b(t,T+1);break;case 34:m();break;case 35:l(n(T+1))||u(n(T+1),n(T+2))?(I=a.Hash,T=_(t,T+1)):(I=a.Delim,T++);break;case 39:m();break;case 40:I=a.LeftParenthesis,T++;break;case 41:I=a.RightParenthesis,T++;break;case 43:h(j,n(T+1),n(T+2))?o():(I=a.Delim,T++);break;case 44:I=a.Comma,T++;break;case 45:h(j,n(T+1),n(T+2))?o():45===n(T+1)&&62===n(T+2)?(I=a.CDC,T+=3):d(j,n(T+1),n(T+2))?s():(I=a.Delim,T++);break;case 46:h(j,n(T+1),n(T+2))?o():(I=a.Delim,T++);break;case 47:42===n(T+1)?(I=a.Comment,1===(T=t.indexOf("*/",T+2)+2)&&(T=t.length)):(I=a.Delim,T++);break;case 58:I=a.Colon,T++;break;case 59:I=a.Semicolon,T++;break;case 60:33===n(T+1)&&45===n(T+2)&&45===n(T+3)?(I=a.CDO,T+=4):(I=a.Delim,T++);break;case 64:d(n(T+1),n(T+2),n(T+3))?(I=a.AtKeyword,T=_(t,T+1)):(I=a.Delim,T++);break;case 91:I=a.LeftSquareBracket,T++;break;case 92:u(j,n(T+1))?s():(I=a.Delim,T++);break;case 93:I=a.RightSquareBracket,T++;break;case 123:I=a.LeftCurlyBracket,T++;break;case 125:I=a.RightCurlyBracket,T++;break;case f.Digit:o();break;case f.NameStart:s();break;case f.Eof:break;default:I=a.Delim,T++}switch(I){case E:for(E=(P=x[A=16777215&P])>>24,x[O]=A,x[A++]=O;A<O;A++)x[A]===C&&(x[A]=O);break;case a.LeftParenthesis:case a.Function:x[O]=P,P=(E=a.RightParenthesis)<<24|O;break;case a.LeftSquareBracket:x[O]=P,P=(E=a.RightSquareBracket)<<24|O;break;case a.LeftCurlyBracket:x[O]=P,P=(E=a.RightCurlyBracket)<<24|O}S[O++]=I<<24|T}for(S[O]=a.EOF<<24|T,x[O]=C,x[C]=C;0!==P;)P=x[A=16777215&P],x[A]=C;return e.source=t,e.firstCharOffset=M,e.offsetAndType=S,e.tokenCount=O,e.balance=x,e.reset(),e.next(),e}Object.keys(o).forEach((function(t){C[t]=o[t]})),Object.keys(s).forEach((function(t){C[t]=s[t]})),Object.keys(m).forEach((function(t){C[t]=m[t]})),t.exports=C},vkgz:function(t,e,n){"use strict";n.d(e,"a",(function(){return h}));var i=n("JX7q"),r=n("Ji7U"),o=n("LK+K"),a=n("1OyB"),s=n("vuIU"),c=n("7o/Q"),l=n("KqfI"),u=n("n6bG");function h(t,e,n){return function(i){return i.lift(new d(t,e,n))}}var d=function(){function t(e,n,i){Object(a.a)(this,t),this.nextOrObserver=e,this.error=n,this.complete=i}return Object(s.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new f(t,this.nextOrObserver,this.error,this.complete))}}]),t}(),f=function(t){Object(r.a)(n,t);var e=Object(o.a)(n);function n(t,r,o,s){var c;return Object(a.a)(this,n),(c=e.call(this,t))._tapNext=l.a,c._tapError=l.a,c._tapComplete=l.a,c._tapError=o||l.a,c._tapComplete=s||l.a,Object(u.a)(r)?(c._context=Object(i.a)(c),c._tapNext=r):r&&(c._context=r,c._tapNext=r.next||l.a,c._tapError=r.error||l.a,c._tapComplete=r.complete||l.a),c}return Object(s.a)(n,[{key:"_next",value:function(t){try{this._tapNext.call(this._context,t)}catch(e){return void this.destination.error(e)}this.destination.next(t)}},{key:"_error",value:function(t){try{this._tapError.call(this._context,t)}catch(t){return void this.destination.error(t)}this.destination.error(t)}},{key:"_complete",value:function(){try{this._tapComplete.call(this._context)}catch(t){return void this.destination.error(t)}return this.destination.complete()}}]),n}(c.a)},vuIU:function(t,e,n){"use strict";function i(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function r(t,e,n){return e&&i(t.prototype,e),n&&i(t,n),t}n.d(e,"a",(function(){return r}))},"w0v+":function(t,e,n){"use strict";n.r(e),n.d(e,"config",(function(){return i.a})),n.d(e,"InnerSubscriber",(function(){return r.a})),n.d(e,"OuterSubscriber",(function(){return o.a})),n.d(e,"Scheduler",(function(){return a.a})),n.d(e,"AnonymousSubject",(function(){return s.a})),n.d(e,"SubjectSubscription",(function(){return c.a})),n.d(e,"Subscriber",(function(){return l.a})),n.d(e,"fromPromise",(function(){return f})),n.d(e,"fromIterable",(function(){return g})),n.d(e,"ajax",(function(){return b.a})),n.d(e,"webSocket",(function(){return y.a})),n.d(e,"ajaxGet",(function(){return _.g})),n.d(e,"ajaxPost",(function(){return _.j})),n.d(e,"ajaxDelete",(function(){return _.f})),n.d(e,"ajaxPut",(function(){return _.k})),n.d(e,"ajaxPatch",(function(){return _.i})),n.d(e,"ajaxGetJSON",(function(){return _.h})),n.d(e,"AjaxObservable",(function(){return _.b})),n.d(e,"AjaxSubscriber",(function(){return _.d})),n.d(e,"AjaxResponse",(function(){return _.c})),n.d(e,"AjaxError",(function(){return _.a})),n.d(e,"AjaxTimeoutError",(function(){return _.e})),n.d(e,"WebSocketSubject",(function(){return w.a})),n.d(e,"CombineLatestOperator",(function(){return k.a})),n.d(e,"dispatch",(function(){return C.a})),n.d(e,"SubscribeOnObservable",(function(){return S.a})),n.d(e,"Timestamp",(function(){return x.a})),n.d(e,"TimeInterval",(function(){return O.a})),n.d(e,"GroupedObservable",(function(){return M.a})),n.d(e,"defaultThrottleConfig",(function(){return T.a})),n.d(e,"rxSubscriber",(function(){return E.a})),n.d(e,"iterator",(function(){return P.a})),n.d(e,"observable",(function(){return A.a})),n.d(e,"ArgumentOutOfRangeError",(function(){return j.a})),n.d(e,"EmptyError",(function(){return I.a})),n.d(e,"Immediate",(function(){return D.a})),n.d(e,"ObjectUnsubscribedError",(function(){return R.a})),n.d(e,"TimeoutError",(function(){return L.a})),n.d(e,"UnsubscriptionError",(function(){return F.a})),n.d(e,"applyMixins",(function(){return N.a})),n.d(e,"errorObject",(function(){return B})),n.d(e,"hostReportError",(function(){return H.a})),n.d(e,"identity",(function(){return z.a})),n.d(e,"isArray",(function(){return V.a})),n.d(e,"isArrayLike",(function(){return U.a})),n.d(e,"isDate",(function(){return q.a})),n.d(e,"isFunction",(function(){return G.a})),n.d(e,"isIterable",(function(){return W.a})),n.d(e,"isNumeric",(function(){return K.a})),n.d(e,"isObject",(function(){return X.a})),n.d(e,"isObservable",(function(){return Y.a})),n.d(e,"isPromise",(function(){return Z.a})),n.d(e,"isScheduler",(function(){return Q.a})),n.d(e,"noop",(function(){return $.a})),n.d(e,"not",(function(){return J.a})),n.d(e,"pipe",(function(){return tt.a})),n.d(e,"root",(function(){return et.a})),n.d(e,"subscribeTo",(function(){return nt.a})),n.d(e,"subscribeToArray",(function(){return it.a})),n.d(e,"subscribeToIterable",(function(){return p.a})),n.d(e,"subscribeToObservable",(function(){return rt.a})),n.d(e,"subscribeToPromise",(function(){return h.a})),n.d(e,"subscribeToResult",(function(){return ot.a})),n.d(e,"toSubscriber",(function(){return at.a})),n.d(e,"tryCatch",(function(){return ct}));var i=n("2fFW"),r=n("51Dv"),o=n("l7GE"),a=n("Y/cZ"),s=n("XNiG"),c=n("Ylt2"),l=n("7o/Q"),u=n("HDdC"),h=n("a7t3"),d=n("4yVj");function f(t,e){return e?Object(d.a)(t,e):new u.a(Object(h.a)(t))}var p=n("pLzU"),m=n("MBAA");function g(t,e){if(!t)throw new Error("Iterable cannot be null");return e?Object(m.a)(t,e):new u.a(Object(p.a)(t))}var v,b=n("19/K"),y=n("lcII"),_=n("Sj+y"),w=n("wxn8"),k=n("itXk"),C=n("NNCq"),S=n("O4y0"),x=n("r0WS"),O=n("4hIw"),M=n("OQgR"),T=n("yuhW"),E=n("2QA8"),P=n("Lhse"),A=n("kJWO"),j=n("4I5i"),I=n("sVev"),D=n("c7jc"),R=n("9ppp"),L=n("Y6u4"),F=n("pjAE"),N=n("Of7M"),B={e:{}},H=n("NJ4a"),z=n("SpAZ"),V=n("DH7j"),U=n("I55L"),q=n("mlxB"),G=n("n6bG"),W=n("CMyj"),K=n("Y7HM"),X=n("XoHu"),Y=n("QIAL"),Z=n("c2HN"),Q=n("z+Ro"),$=n("KqfI"),J=n("F97/"),tt=n("mCNh"),et=n("xJj7"),nt=n("SeVD"),it=n("ngJS"),rt=n("CRDf"),ot=n("ZUHj"),at=n("WyKG");function st(){B.e=void 0;try{return v.apply(this,arguments)}catch(t){return B.e=t,B}finally{v=void 0}}function ct(t){return v=t,st}},w1tV:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("oB13"),r=n("x+ZX"),o=n("XNiG");function a(){return new o.b}function s(){return function(t){return Object(r.a)()(Object(i.a)(a)(t))}}},wDXs:function(t,e,n){t.exports=n("2pxp")},wGW3:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("iD44");i.Observable.prototype.mergeMap=r.mergeMap,i.Observable.prototype.flatMap=r.mergeMap},wWu8:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("Lsvf");i.Observable.prototype.ignoreElements=r.ignoreElements},wfyD:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("lXds");i.Observable.prototype.delayWhen=r.delayWhen},wxn8:function(t,e,n){"use strict";n.d(e,"a",(function(){return m}));var i=n("1OyB"),r=n("vuIU"),o=n("ReuC"),a=n("foSv"),s=n("Ji7U"),c=n("LK+K"),l=n("XNiG"),u=n("7o/Q"),h=n("HDdC"),d=n("quSY"),f=n("jtHE"),p={url:"",deserializer:function(t){return JSON.parse(t.data)},serializer:function(t){return JSON.stringify(t)}},m=function(t){Object(s.a)(n,t);var e=Object(c.a)(n);function n(t,r){var o;if(Object(i.a)(this,n),o=e.call(this),t instanceof h.a)o.destination=r,o.source=t;else{var a=o._config=Object.assign({},p);if(o._output=new l.b,"string"==typeof t)a.url=t;else for(var s in t)t.hasOwnProperty(s)&&(a[s]=t[s]);if(!a.WebSocketCtor&&WebSocket)a.WebSocketCtor=WebSocket;else if(!a.WebSocketCtor)throw new Error("no WebSocket constructor can be found");o.destination=new f.a}return o}return Object(r.a)(n,[{key:"lift",value:function(t){var e=new n(this._config,this.destination);return e.operator=t,e.source=this,e}},{key:"_resetState",value:function(){this._socket=null,this.source||(this.destination=new f.a),this._output=new l.b}},{key:"multiplex",value:function(t,e,n){var i=this;return new h.a((function(r){try{i.next(t())}catch(a){r.error(a)}var o=i.subscribe((function(t){try{n(t)&&r.next(t)}catch(a){r.error(a)}}),(function(t){return r.error(t)}),(function(){return r.complete()}));return function(){try{i.next(e())}catch(a){r.error(a)}o.unsubscribe()}}))}},{key:"_connectSocket",value:function(){var t=this,e=this._config,n=e.WebSocketCtor,i=e.protocol,r=e.url,o=e.binaryType,a=this._output,s=null;try{s=i?new n(r,i):new n(r),this._socket=s,o&&(this._socket.binaryType=o)}catch(l){return void a.error(l)}var c=new d.a((function(){t._socket=null,s&&1===s.readyState&&s.close()}));s.onopen=function(e){if(!t._socket)return s.close(),void t._resetState();var n=t._config.openObserver;n&&n.next(e);var i=t.destination;t.destination=u.a.create((function(n){if(1===s.readyState)try{s.send((0,t._config.serializer)(n))}catch(e){t.destination.error(e)}}),(function(e){var n=t._config.closingObserver;n&&n.next(void 0),e&&e.code?s.close(e.code,e.reason):a.error(new TypeError("WebSocketSubject.error must be called with an object with an error code, and an optional reason: { code: number, reason: string }")),t._resetState()}),(function(){var e=t._config.closingObserver;e&&e.next(void 0),s.close(),t._resetState()})),i&&i instanceof f.a&&c.add(i.subscribe(t.destination))},s.onerror=function(e){t._resetState(),a.error(e)},s.onclose=function(e){t._resetState();var n=t._config.closeObserver;n&&n.next(e),e.wasClean?a.complete():a.error(e)},s.onmessage=function(e){try{a.next((0,t._config.deserializer)(e))}catch(n){a.error(n)}}}},{key:"_subscribe",value:function(t){var e=this,n=this.source;return n?n.subscribe(t):(this._socket||this._connectSocket(),this._output.subscribe(t),t.add((function(){var t=e._socket;0===e._output.observers.length&&(t&&1===t.readyState&&t.close(),e._resetState())})),t)}},{key:"unsubscribe",value:function(){var t=this._socket;t&&1===t.readyState&&t.close(),this._resetState(),Object(o.a)(Object(a.a)(n.prototype),"unsubscribe",this).call(this)}}]),n}(l.a)},"x+ZX":function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q");function c(){return function(t){return t.lift(new l(t))}}var l=function(){function t(e){Object(o.a)(this,t),this.connectable=e}return Object(a.a)(t,[{key:"call",value:function(t,e){var n=this.connectable;n._refCount++;var i=new u(t,n),r=e.subscribe(i);return i.closed||(i.connection=n.connect()),r}}]),t}(),u=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).connectable=i,r}return Object(a.a)(n,[{key:"_unsubscribe",value:function(){var t=this.connectable;if(t){this.connectable=null;var e=t._refCount;if(e<=0)this.connection=null;else if(t._refCount=e-1,e>1)this.connection=null;else{var n=this.connection,i=t._connection;this.connection=null,!i||n&&i!==n||i.unsubscribe()}}else this.connection=null}}]),n}(s.a)},xDdU:function(t,e,n){var i,r,o=n("4fRq"),a=n("I2ZF"),s=0,c=0;t.exports=function(t,e,n){var l=e&&n||0,u=e||[],h=(t=t||{}).node||i,d=void 0!==t.clockseq?t.clockseq:r;if(null==h||null==d){var f=o();null==h&&(h=i=[1|f[0],f[1],f[2],f[3],f[4],f[5]]),null==d&&(d=r=16383&(f[6]<<8|f[7]))}var p=void 0!==t.msecs?t.msecs:(new Date).getTime(),m=void 0!==t.nsecs?t.nsecs:c+1,g=p-s+(m-c)/1e4;if(g<0&&void 0===t.clockseq&&(d=d+1&16383),(g<0||p>s)&&void 0===t.nsecs&&(m=0),m>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");s=p,c=m,r=d;var v=(1e4*(268435455&(p+=122192928e5))+m)%4294967296;u[l++]=v>>>24&255,u[l++]=v>>>16&255,u[l++]=v>>>8&255,u[l++]=255&v;var b=p/4294967296*1e4&268435455;u[l++]=b>>>8&255,u[l++]=255&b,u[l++]=b>>>24&15|16,u[l++]=b>>>16&255,u[l++]=d>>>8|128,u[l++]=255&d;for(var y=0;y<6;++y)u[l+y]=h[y];return e||a(u)}},xJj7:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i="undefined"!=typeof window&&window,r="undefined"!=typeof self&&"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&self,o="undefined"!=typeof global&&global,a=i||o||r},xODi:function(t,e){t.exports={parse:{prelude:null,block:function(){return this.Block(!0)}}}},xbPD:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q");function c(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return function(e){return e.lift(new l(t))}}var l=function(){function t(e){Object(o.a)(this,t),this.defaultValue=e}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new u(t,this.defaultValue))}}]),t}(),u=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).defaultValue=i,r.isEmpty=!0,r}return Object(a.a)(n,[{key:"_next",value:function(t){this.isEmpty=!1,this.destination.next(t)}},{key:"_complete",value:function(){this.isEmpty&&this.destination.next(this.defaultValue),this.destination.complete()}}]),n}(s.a)},xgIS:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("KQm4"),r=n("HDdC"),o=n("DH7j"),a=n("n6bG"),s=n("lJxs");function c(t,e,n,l){return Object(a.a)(n)&&(l=n,n=void 0),l?c(t,e,n).pipe(Object(s.a)((function(t){return Object(o.a)(t)?l.apply(void 0,Object(i.a)(t)):l(t)}))):new r.a((function(i){!function t(e,n,i,r,o){var a;if(function(t){return t&&"function"==typeof t.addEventListener&&"function"==typeof t.removeEventListener}(e)){var s=e;e.addEventListener(n,i,o),a=function(){return s.removeEventListener(n,i,o)}}else if(function(t){return t&&"function"==typeof t.on&&"function"==typeof t.off}(e)){var c=e;e.on(n,i),a=function(){return c.off(n,i)}}else if(function(t){return t&&"function"==typeof t.addListener&&"function"==typeof t.removeListener}(e)){var l=e;e.addListener(n,i),a=function(){return l.removeListener(n,i)}}else{if(!e||!e.length)throw new TypeError("Invalid event target");for(var u=0,h=e.length;u<h;u++)t(e[u],n,i,r,o)}r.add(a)}(t,e,(function(t){i.next(arguments.length>1?Array.prototype.slice.call(arguments):t)}),i,n)}))}},xijO:function(t,e,n){"use strict";n.r(e);var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol?"symbol":typeof t};e.default=function(t){return null!=t&&"object"===(void 0===t?"undefined":i(t))&&1===t.nodeType&&"object"===i(t.style)&&"object"===i(t.ownerDocument)}},xk4V:function(t,e,n){var i=n("4fRq"),r=n("I2ZF");t.exports=function(t,e,n){var o=e&&n||0;"string"==typeof t&&(e="binary"===t?new Array(16):null,t=null);var a=(t=t||{}).random||(t.rng||i)();if(a[6]=15&a[6]|64,a[8]=63&a[8]|128,e)for(var s=0;s<16;++s)e[o+s]=a[s];return e||r(a)}},xwTN:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("kU1M");e.mergeMapTo=function(t,e){return void 0===e&&(e=Number.POSITIVE_INFINITY),i.mergeMapTo(t,e)(this)}},yCtX:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("HDdC"),r=n("ngJS"),o=n("jZKg");function a(t,e){return e?Object(o.a)(t,e):new i.a(Object(r.a)(t))}},yJif:function(t,e,n){t.exports=n("errG")},yTw5:function(t,e,n){var i=n("vd7W").TYPE,r=n("4njK").mode,o=i.LeftCurlyBracket;function a(t){return this.Raw(t,r.leftCurlyBracket,!0)}function s(){var t=this.SelectorList();return"Raw"!==t.type&&!1===this.scanner.eof&&this.scanner.tokenType!==o&&this.error(),t}t.exports={name:"Rule",structure:{prelude:["SelectorList","Raw"],block:["Block"]},parse:function(){var t,e,n=this.scanner.tokenIndex,i=this.scanner.tokenStart;return t=this.parseRulePrelude?this.parseWithFallback(s,a):a.call(this,n),e=this.Block(!0),{type:"Rule",loc:this.getLocation(i,this.scanner.tokenStart),prelude:t,block:e}},generate:function(t){this.node(t.prelude),this.node(t.block)},walkContext:"rule"}},yuhW:function(t,e,n){"use strict";n.d(e,"a",(function(){return l})),n.d(e,"b",(function(){return u}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("l7GE"),c=n("ZUHj"),l={leading:!0,trailing:!1};function u(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l;return function(n){return n.lift(new h(t,e.leading,e.trailing))}}var h=function(){function t(e,n,i){Object(o.a)(this,t),this.durationSelector=e,this.leading=n,this.trailing=i}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new d(t,this.durationSelector,this.leading,this.trailing))}}]),t}(),d=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i,r,a){var s;return Object(o.a)(this,n),(s=e.call(this,t)).destination=t,s.durationSelector=i,s._leading=r,s._trailing=a,s._hasValue=!1,s}return Object(a.a)(n,[{key:"_next",value:function(t){this._hasValue=!0,this._sendValue=t,this._throttled||(this._leading?this.send():this.throttle(t))}},{key:"send",value:function(){var t=this._sendValue;this._hasValue&&(this.destination.next(t),this.throttle(t)),this._hasValue=!1,this._sendValue=null}},{key:"throttle",value:function(t){var e=this.tryDurationSelector(t);e&&this.add(this._throttled=Object(c.a)(this,e))}},{key:"tryDurationSelector",value:function(t){try{return this.durationSelector(t)}catch(e){return this.destination.error(e),null}}},{key:"throttlingDone",value:function(){var t=this._throttled,e=this._trailing;t&&t.unsubscribe(),this._throttled=null,e&&this.send()}},{key:"notifyNext",value:function(t,e,n,i,r){this.throttlingDone()}},{key:"notifyComplete",value:function(){this.throttlingDone()}}]),n}(s.a)},"z+Ro":function(t,e,n){"use strict";function i(t){return t&&"function"==typeof t.schedule}n.d(e,"a",(function(){return i}))},z6cu:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("HDdC");function r(t,e){return new i.a(e?function(n){return e.schedule(o,0,{error:t,subscriber:n})}:function(e){return e.error(t)})}function o(t){t.subscriber.error(t.error)}},zDpS:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("qCKp"),r=n("kU1M");e.timeoutWith=function(t,e,n){return void 0===n&&(n=i.asyncScheduler),r.timeoutWith(t,e,n)(this)}},zNuj:function(t,e,n){"use strict";(function(t){n.d(e,"i",(function(){return r})),n.d(e,"f",(function(){return a})),n.d(e,"m",(function(){return s})),n.d(e,"k",(function(){return c})),n.d(e,"d",(function(){return l})),n.d(e,"c",(function(){return u})),n.d(e,"b",(function(){return h})),n.d(e,"a",(function(){return d})),n.d(e,"g",(function(){return f})),n.d(e,"h",(function(){return p})),n.d(e,"l",(function(){return _})),n.d(e,"j",(function(){return w})),n.d(e,"e",(function(){return k}));var i=n("Gqt4");function r(){return"[object process]"===Object.prototype.toString.call("undefined"!=typeof process?process:0)}n("7Ki+");var o={};function a(){return r()?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:o}function s(){var t=a(),e=t.crypto||t.msCrypto;if(void 0!==e&&e.getRandomValues){var n=new Uint16Array(8);e.getRandomValues(n),n[3]=4095&n[3]|16384,n[4]=16383&n[4]|32768;var i=function(t){for(var e=t.toString(16);e.length<4;)e="0"+e;return e};return i(n[0])+i(n[1])+i(n[2])+i(n[3])+i(n[4])+i(n[5])+i(n[6])+i(n[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,(function(t){var e=16*Math.random()|0;return("x"===t?e:3&e|8).toString(16)}))}function c(t){if(!t)return{};var e=t.match(/^(([^:\/?#]+):)?(\/\/([^\/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);return e?{host:e[4],path:e[5],protocol:e[2],relative:e[5]+(e[6]||"")+(e[8]||"")}:{}}function l(t){if(t.message)return t.message;if(t.exception&&t.exception.values&&t.exception.values[0]){var e=t.exception.values[0];return e.type&&e.value?e.type+": "+e.value:e.type||e.value||t.event_id||"<unknown>"}return t.event_id||"<unknown>"}function u(t){var e=a();if(!("console"in e))return t();var n=e.console,i={};["debug","info","warn","error","log","assert"].forEach((function(t){t in e.console&&n[t].__sentry_original__&&(i[t]=n[t],n[t]=n[t].__sentry_original__)}));var r=t();return Object.keys(i).forEach((function(t){n[t]=i[t]})),r}function h(t,e,n){t.exception=t.exception||{},t.exception.values=t.exception.values||[],t.exception.values[0]=t.exception.values[0]||{},t.exception.values[0].value=t.exception.values[0].value||e||"",t.exception.values[0].type=t.exception.values[0].type||n||"Error"}function d(t,e){void 0===e&&(e={});try{t.exception.values[0].mechanism=t.exception.values[0].mechanism||{},Object.keys(e).forEach((function(n){t.exception.values[0].mechanism[n]=e[n]}))}catch(n){}}function f(){try{return document.location.href}catch(t){return""}}function p(t){try{for(var e=t,n=[],i=0,r=0,o=" > ".length,a=void 0;e&&i++<5&&!("html"===(a=m(e))||i>1&&r+n.length*o+a.length>=80);)n.push(a),r+=a.length,e=e.parentNode;return n.reverse().join(" > ")}catch(s){return"<unknown>"}}function m(t){var e,n,r,o,a,s=t,c=[];if(!s||!s.tagName)return"";if(c.push(s.tagName.toLowerCase()),s.id&&c.push("#"+s.id),(e=s.className)&&Object(i.k)(e))for(n=e.split(/\s+/),a=0;a<n.length;a++)c.push("."+n[a]);var l=["type","name","title","alt"];for(a=0;a<l.length;a++)(o=s.getAttribute(r=l[a]))&&c.push("["+r+'="'+o+'"]');return c.join("")}var g=Date.now(),v=0,b={now:function(){var t=Date.now()-g;return t<v&&(t=v),v=t,t},timeOrigin:g},y=function(){if(r())try{return t.require("perf_hooks").performance}catch(n){return b}var e=a().performance;return e&&e.now?(void 0===e.timeOrigin&&(e.timeOrigin=e.timing&&e.timing.navigationStart||g),e):b}();function _(){return(y.timeOrigin+y.now())/1e3}function w(t,e){if(!e)return 6e4;var n=parseInt(""+e,10);if(!isNaN(n))return 1e3*n;var i=Date.parse(""+e);return isNaN(i)?6e4:i-t}function k(t){try{return t&&"function"==typeof t&&t.name||"<anonymous>"}catch(e){return"<anonymous>"}}}).call(this,n("3UD+")(t))},zP0r:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Ji7U"),r=n("LK+K"),o=n("1OyB"),a=n("vuIU"),s=n("7o/Q");function c(t){return function(e){return e.lift(new l(t))}}var l=function(){function t(e){Object(o.a)(this,t),this.total=e}return Object(a.a)(t,[{key:"call",value:function(t,e){return e.subscribe(new u(t,this.total))}}]),t}(),u=function(t){Object(i.a)(n,t);var e=Object(r.a)(n);function n(t,i){var r;return Object(o.a)(this,n),(r=e.call(this,t)).total=i,r.count=0,r}return Object(a.a)(n,[{key:"_next",value:function(t){++this.count>this.total&&this.destination.next(t)}}]),n}(s.a)},zUnb:function(t,e,n){"use strict";n.r(e);var i={};n.r(i),n.d(i,"bisect",(function(){return jy})),n.d(i,"bisectRight",(function(){return Py})),n.d(i,"bisectLeft",(function(){return Ay})),n.d(i,"ascending",(function(){return My})),n.d(i,"bisector",(function(){return Ty})),n.d(i,"cross",(function(){return Ry})),n.d(i,"descending",(function(){return Ly})),n.d(i,"deviation",(function(){return By})),n.d(i,"extent",(function(){return Hy})),n.d(i,"histogram",(function(){return t_})),n.d(i,"thresholdFreedmanDiaconis",(function(){return n_})),n.d(i,"thresholdScott",(function(){return i_})),n.d(i,"thresholdSturges",(function(){return Jy})),n.d(i,"max",(function(){return r_})),n.d(i,"mean",(function(){return o_})),n.d(i,"median",(function(){return a_})),n.d(i,"merge",(function(){return s_})),n.d(i,"min",(function(){return c_})),n.d(i,"pairs",(function(){return Iy})),n.d(i,"permute",(function(){return l_})),n.d(i,"quantile",(function(){return e_})),n.d(i,"range",(function(){return Wy})),n.d(i,"scan",(function(){return u_})),n.d(i,"shuffle",(function(){return h_})),n.d(i,"sum",(function(){return d_})),n.d(i,"ticks",(function(){return Zy})),n.d(i,"tickIncrement",(function(){return Qy})),n.d(i,"tickStep",(function(){return $y})),n.d(i,"transpose",(function(){return f_})),n.d(i,"variance",(function(){return Ny})),n.d(i,"zip",(function(){return m_})),n.d(i,"axisTop",(function(){return S_})),n.d(i,"axisRight",(function(){return x_})),n.d(i,"axisBottom",(function(){return O_})),n.d(i,"axisLeft",(function(){return M_})),n.d(i,"brush",(function(){return DS})),n.d(i,"brushX",(function(){return jS})),n.d(i,"brushY",(function(){return IS})),n.d(i,"brushSelection",(function(){return AS})),n.d(i,"chord",(function(){return US})),n.d(i,"ribbon",(function(){return ix})),n.d(i,"nest",(function(){return sx})),n.d(i,"set",(function(){return mx})),n.d(i,"map",(function(){return ax})),n.d(i,"keys",(function(){return gx})),n.d(i,"values",(function(){return vx})),n.d(i,"entries",(function(){return bx})),n.d(i,"color",(function(){return Dx})),n.d(i,"rgb",(function(){return Nx})),n.d(i,"hsl",(function(){return Vx})),n.d(i,"lab",(function(){return Xx})),n.d(i,"hcl",(function(){return eO})),n.d(i,"cubehelix",(function(){return cO})),n.d(i,"contours",(function(){return bO})),n.d(i,"contourDensity",(function(){return CO})),n.d(i,"dispatch",(function(){return D_})),n.d(i,"drag",(function(){return AO})),n.d(i,"dragDisable",(function(){return Yw})),n.d(i,"dragEnable",(function(){return Zw})),n.d(i,"dsvFormat",(function(){return RO})),n.d(i,"csvParse",(function(){return FO})),n.d(i,"csvParseRows",(function(){return NO})),n.d(i,"csvFormat",(function(){return BO})),n.d(i,"csvFormatRows",(function(){return HO})),n.d(i,"tsvParse",(function(){return VO})),n.d(i,"tsvParseRows",(function(){return UO})),n.d(i,"tsvFormat",(function(){return qO})),n.d(i,"tsvFormatRows",(function(){return GO})),n.d(i,"easeLinear",(function(){return WO})),n.d(i,"easeQuad",(function(){return YO})),n.d(i,"easeQuadIn",(function(){return KO})),n.d(i,"easeQuadOut",(function(){return XO})),n.d(i,"easeQuadInOut",(function(){return YO})),n.d(i,"easeCubic",(function(){return sS})),n.d(i,"easeCubicIn",(function(){return oS})),n.d(i,"easeCubicOut",(function(){return aS})),n.d(i,"easeCubicInOut",(function(){return sS})),n.d(i,"easePoly",(function(){return $O})),n.d(i,"easePolyIn",(function(){return ZO})),n.d(i,"easePolyOut",(function(){return QO})),n.d(i,"easePolyInOut",(function(){return $O})),n.d(i,"easeSin",(function(){return iM})),n.d(i,"easeSinIn",(function(){return eM})),n.d(i,"easeSinOut",(function(){return nM})),n.d(i,"easeSinInOut",(function(){return iM})),n.d(i,"easeExp",(function(){return aM})),n.d(i,"easeExpIn",(function(){return rM})),n.d(i,"easeExpOut",(function(){return oM})),n.d(i,"easeExpInOut",(function(){return aM})),n.d(i,"easeCircle",(function(){return lM})),n.d(i,"easeCircleIn",(function(){return sM})),n.d(i,"easeCircleOut",(function(){return cM})),n.d(i,"easeCircleInOut",(function(){return lM})),n.d(i,"easeBounce",(function(){return hM})),n.d(i,"easeBounceIn",(function(){return uM})),n.d(i,"easeBounceOut",(function(){return hM})),n.d(i,"easeBounceInOut",(function(){return dM})),n.d(i,"easeBack",(function(){return mM})),n.d(i,"easeBackIn",(function(){return fM})),n.d(i,"easeBackOut",(function(){return pM})),n.d(i,"easeBackInOut",(function(){return mM})),n.d(i,"easeElastic",(function(){return bM})),n.d(i,"easeElasticIn",(function(){return vM})),n.d(i,"easeElasticOut",(function(){return bM})),n.d(i,"easeElasticInOut",(function(){return yM})),n.d(i,"forceCenter",(function(){return _M})),n.d(i,"forceCollide",(function(){return IM})),n.d(i,"forceLink",(function(){return LM})),n.d(i,"forceManyBody",(function(){return VM})),n.d(i,"forceRadial",(function(){return UM})),n.d(i,"forceSimulation",(function(){return zM})),n.d(i,"forceX",(function(){return qM})),n.d(i,"forceY",(function(){return GM})),n.d(i,"formatDefaultLocale",(function(){return oT})),n.d(i,"format",(function(){return tT})),n.d(i,"formatPrefix",(function(){return eT})),n.d(i,"formatLocale",(function(){return rT})),n.d(i,"formatSpecifier",(function(){return QM})),n.d(i,"precisionFixed",(function(){return aT})),n.d(i,"precisionPrefix",(function(){return sT})),n.d(i,"precisionRound",(function(){return cT})),n.d(i,"geoArea",(function(){return JT})),n.d(i,"geoBounds",(function(){return GE})),n.d(i,"geoCentroid",(function(){return iP})),n.d(i,"geoCircle",(function(){return pP})),n.d(i,"geoClipAntimeridian",(function(){return xP})),n.d(i,"geoClipCircle",(function(){return OP})),n.d(i,"geoClipExtent",(function(){return AP})),n.d(i,"geoClipRectangle",(function(){return MP})),n.d(i,"geoContains",(function(){return YP})),n.d(i,"geoDistance",(function(){return HP})),n.d(i,"geoGraticule",(function(){return $P})),n.d(i,"geoGraticule10",(function(){return JP})),n.d(i,"geoInterpolate",(function(){return rA})),n.d(i,"geoLength",(function(){return FP})),n.d(i,"geoPath",(function(){return nj})),n.d(i,"geoAlbers",(function(){return wj})),n.d(i,"geoAlbersUsa",(function(){return kj})),n.d(i,"geoAzimuthalEqualArea",(function(){return Oj})),n.d(i,"geoAzimuthalEqualAreaRaw",(function(){return xj})),n.d(i,"geoAzimuthalEquidistant",(function(){return Tj})),n.d(i,"geoAzimuthalEquidistantRaw",(function(){return Mj})),n.d(i,"geoConicConformal",(function(){return Dj})),n.d(i,"geoConicConformalRaw",(function(){return Ij})),n.d(i,"geoConicEqualArea",(function(){return _j})),n.d(i,"geoConicEqualAreaRaw",(function(){return yj})),n.d(i,"geoConicEquidistant",(function(){return Nj})),n.d(i,"geoConicEquidistantRaw",(function(){return Fj})),n.d(i,"geoEquirectangular",(function(){return Lj})),n.d(i,"geoEquirectangularRaw",(function(){return Rj})),n.d(i,"geoGnomonic",(function(){return Hj})),n.d(i,"geoGnomonicRaw",(function(){return Bj})),n.d(i,"geoIdentity",(function(){return Vj})),n.d(i,"geoProjection",(function(){return gj})),n.d(i,"geoProjectionMutator",(function(){return vj})),n.d(i,"geoMercator",(function(){return Pj})),n.d(i,"geoMercatorRaw",(function(){return Ej})),n.d(i,"geoNaturalEarth1",(function(){return qj})),n.d(i,"geoNaturalEarth1Raw",(function(){return Uj})),n.d(i,"geoOrthographic",(function(){return Wj})),n.d(i,"geoOrthographicRaw",(function(){return Gj})),n.d(i,"geoStereographic",(function(){return Xj})),n.d(i,"geoStereographicRaw",(function(){return Kj})),n.d(i,"geoTransverseMercator",(function(){return Zj})),n.d(i,"geoTransverseMercatorRaw",(function(){return Yj})),n.d(i,"geoRotation",(function(){return hP})),n.d(i,"geoStream",(function(){return GT})),n.d(i,"geoTransform",(function(){return ij})),n.d(i,"cluster",(function(){return tI})),n.d(i,"hierarchy",(function(){return nI})),n.d(i,"pack",(function(){return MI})),n.d(i,"packSiblings",(function(){return wI})),n.d(i,"packEnclose",(function(){return cI})),n.d(i,"partition",(function(){return II})),n.d(i,"stratify",(function(){return NI})),n.d(i,"tree",(function(){return GI})),n.d(i,"treemap",(function(){return ZI})),n.d(i,"treemapBinary",(function(){return QI})),n.d(i,"treemapDice",(function(){return jI})),n.d(i,"treemapSlice",(function(){return WI})),n.d(i,"treemapSliceDice",(function(){return $I})),n.d(i,"treemapSquarify",(function(){return YI})),n.d(i,"treemapResquarify",(function(){return JI})),n.d(i,"interpolate",(function(){return kD})),n.d(i,"interpolateArray",(function(){return mD})),n.d(i,"interpolateBasis",(function(){return eD})),n.d(i,"interpolateBasisClosed",(function(){return nD})),n.d(i,"interpolateDate",(function(){return gD})),n.d(i,"interpolateNumber",(function(){return vD})),n.d(i,"interpolateObject",(function(){return bD})),n.d(i,"interpolateRound",(function(){return CD})),n.d(i,"interpolateString",(function(){return wD})),n.d(i,"interpolateTransformCss",(function(){return TD})),n.d(i,"interpolateTransformSvg",(function(){return ED})),n.d(i,"interpolateZoom",(function(){return jD})),n.d(i,"interpolateRgb",(function(){return sD})),n.d(i,"interpolateRgbBasis",(function(){return fD})),n.d(i,"interpolateRgbBasisClosed",(function(){return pD})),n.d(i,"interpolateHsl",(function(){return DD})),n.d(i,"interpolateHslLong",(function(){return RD})),n.d(i,"interpolateLab",(function(){return YD})),n.d(i,"interpolateHcl",(function(){return QD})),n.d(i,"interpolateHclLong",(function(){return $D})),n.d(i,"interpolateCubehelix",(function(){return iR})),n.d(i,"interpolateCubehelixLong",(function(){return rR})),n.d(i,"quantize",(function(){return oR})),n.d(i,"path",(function(){return QS})),n.d(i,"polygonArea",(function(){return aR})),n.d(i,"polygonCentroid",(function(){return sR})),n.d(i,"polygonHull",(function(){return uR})),n.d(i,"polygonContains",(function(){return hR})),n.d(i,"polygonLength",(function(){return dR})),n.d(i,"quadtree",(function(){return MM})),n.d(i,"randomUniform",(function(){return pR})),n.d(i,"randomNormal",(function(){return mR})),n.d(i,"randomLogNormal",(function(){return gR})),n.d(i,"randomBates",(function(){return bR})),n.d(i,"randomIrwinHall",(function(){return vR})),n.d(i,"randomExponential",(function(){return yR})),n.d(i,"scaleBand",(function(){return xR})),n.d(i,"scalePoint",(function(){return OR})),n.d(i,"scaleIdentity",(function(){return $R})),n.d(i,"scaleLinear",(function(){return QR})),n.d(i,"scaleLog",(function(){return aL})),n.d(i,"scaleOrdinal",(function(){return SR})),n.d(i,"scaleImplicit",(function(){return CR})),n.d(i,"scalePow",(function(){return cL})),n.d(i,"scaleSqrt",(function(){return lL})),n.d(i,"scaleQuantile",(function(){return uL})),n.d(i,"scaleQuantize",(function(){return hL})),n.d(i,"scaleThreshold",(function(){return dL})),n.d(i,"scaleTime",(function(){return nN})),n.d(i,"scaleUtc",(function(){return aN})),n.d(i,"scaleSequential",(function(){return sN})),n.d(i,"schemeCategory10",(function(){return lN})),n.d(i,"schemeAccent",(function(){return uN})),n.d(i,"schemeDark2",(function(){return hN})),n.d(i,"schemePaired",(function(){return dN})),n.d(i,"schemePastel1",(function(){return fN})),n.d(i,"schemePastel2",(function(){return pN})),n.d(i,"schemeSet1",(function(){return mN})),n.d(i,"schemeSet2",(function(){return gN})),n.d(i,"schemeSet3",(function(){return vN})),n.d(i,"interpolateBrBG",(function(){return _N})),n.d(i,"schemeBrBG",(function(){return yN})),n.d(i,"interpolatePRGn",(function(){return kN})),n.d(i,"schemePRGn",(function(){return wN})),n.d(i,"interpolatePiYG",(function(){return SN})),n.d(i,"schemePiYG",(function(){return CN})),n.d(i,"interpolatePuOr",(function(){return ON})),n.d(i,"schemePuOr",(function(){return xN})),n.d(i,"interpolateRdBu",(function(){return TN})),n.d(i,"schemeRdBu",(function(){return MN})),n.d(i,"interpolateRdGy",(function(){return PN})),n.d(i,"schemeRdGy",(function(){return EN})),n.d(i,"interpolateRdYlBu",(function(){return jN})),n.d(i,"schemeRdYlBu",(function(){return AN})),n.d(i,"interpolateRdYlGn",(function(){return DN})),n.d(i,"schemeRdYlGn",(function(){return IN})),n.d(i,"interpolateSpectral",(function(){return LN})),n.d(i,"schemeSpectral",(function(){return RN})),n.d(i,"interpolateBuGn",(function(){return NN})),n.d(i,"schemeBuGn",(function(){return FN})),n.d(i,"interpolateBuPu",(function(){return HN})),n.d(i,"schemeBuPu",(function(){return BN})),n.d(i,"interpolateGnBu",(function(){return VN})),n.d(i,"schemeGnBu",(function(){return zN})),n.d(i,"interpolateOrRd",(function(){return qN})),n.d(i,"schemeOrRd",(function(){return UN})),n.d(i,"interpolatePuBuGn",(function(){return WN})),n.d(i,"schemePuBuGn",(function(){return GN})),n.d(i,"interpolatePuBu",(function(){return XN})),n.d(i,"schemePuBu",(function(){return KN})),n.d(i,"interpolatePuRd",(function(){return ZN})),n.d(i,"schemePuRd",(function(){return YN})),n.d(i,"interpolateRdPu",(function(){return $N})),n.d(i,"schemeRdPu",(function(){return QN})),n.d(i,"interpolateYlGnBu",(function(){return tB})),n.d(i,"schemeYlGnBu",(function(){return JN})),n.d(i,"interpolateYlGn",(function(){return nB})),n.d(i,"schemeYlGn",(function(){return eB})),n.d(i,"interpolateYlOrBr",(function(){return rB})),n.d(i,"schemeYlOrBr",(function(){return iB})),n.d(i,"interpolateYlOrRd",(function(){return aB})),n.d(i,"schemeYlOrRd",(function(){return oB})),n.d(i,"interpolateBlues",(function(){return cB})),n.d(i,"schemeBlues",(function(){return sB})),n.d(i,"interpolateGreens",(function(){return uB})),n.d(i,"schemeGreens",(function(){return lB})),n.d(i,"interpolateGreys",(function(){return dB})),n.d(i,"schemeGreys",(function(){return hB})),n.d(i,"interpolatePurples",(function(){return pB})),n.d(i,"schemePurples",(function(){return fB})),n.d(i,"interpolateReds",(function(){return gB})),n.d(i,"schemeReds",(function(){return mB})),n.d(i,"interpolateOranges",(function(){return bB})),n.d(i,"schemeOranges",(function(){return vB})),n.d(i,"interpolateCubehelixDefault",(function(){return wB})),n.d(i,"interpolateRainbow",(function(){return xB})),n.d(i,"interpolateWarm",(function(){return kB})),n.d(i,"interpolateCool",(function(){return CB})),n.d(i,"interpolateViridis",(function(){return MB})),n.d(i,"interpolateMagma",(function(){return TB})),n.d(i,"interpolateInferno",(function(){return EB})),n.d(i,"interpolatePlasma",(function(){return PB})),n.d(i,"create",(function(){return GH})),n.d(i,"creator",(function(){return RB})),n.d(i,"local",(function(){return KH})),n.d(i,"matcher",(function(){return UB})),n.d(i,"mouse",(function(){return QH})),n.d(i,"namespace",(function(){return jB})),n.d(i,"namespaces",(function(){return AB})),n.d(i,"clientPoint",(function(){return ZH})),n.d(i,"select",(function(){return qH})),n.d(i,"selectAll",(function(){return $H})),n.d(i,"selection",(function(){return UH})),n.d(i,"selector",(function(){return FB})),n.d(i,"selectorAll",(function(){return BB})),n.d(i,"style",(function(){return oH})),n.d(i,"touch",(function(){return JH})),n.d(i,"touches",(function(){return tz})),n.d(i,"window",(function(){return eH})),n.d(i,"event",(function(){return PH})),n.d(i,"customEvent",(function(){return LH})),n.d(i,"arc",(function(){return Az})),n.d(i,"area",(function(){return Fz})),n.d(i,"line",(function(){return Lz})),n.d(i,"pie",(function(){return Hz})),n.d(i,"areaRadial",(function(){return Wz})),n.d(i,"radialArea",(function(){return Wz})),n.d(i,"lineRadial",(function(){return Gz})),n.d(i,"radialLine",(function(){return Gz})),n.d(i,"pointRadial",(function(){return Kz})),n.d(i,"linkHorizontal",(function(){return eV})),n.d(i,"linkVertical",(function(){return nV})),n.d(i,"linkRadial",(function(){return iV})),n.d(i,"symbol",(function(){return wV})),n.d(i,"symbols",(function(){return _V})),n.d(i,"symbolCircle",(function(){return rV})),n.d(i,"symbolCross",(function(){return oV})),n.d(i,"symbolDiamond",(function(){return cV})),n.d(i,"symbolSquare",(function(){return fV})),n.d(i,"symbolStar",(function(){return dV})),n.d(i,"symbolTriangle",(function(){return mV})),n.d(i,"symbolWye",(function(){return yV})),n.d(i,"curveBasisClosed",(function(){return MV})),n.d(i,"curveBasisOpen",(function(){return EV})),n.d(i,"curveBasis",(function(){return xV})),n.d(i,"curveBundle",(function(){return AV})),n.d(i,"curveCardinalClosed",(function(){return LV})),n.d(i,"curveCardinalOpen",(function(){return NV})),n.d(i,"curveCardinal",(function(){return DV})),n.d(i,"curveCatmullRomClosed",(function(){return UV})),n.d(i,"curveCatmullRomOpen",(function(){return GV})),n.d(i,"curveCatmullRom",(function(){return zV})),n.d(i,"curveLinearClosed",(function(){return KV})),n.d(i,"curveLinear",(function(){return Iz})),n.d(i,"curveMonotoneX",(function(){return eU})),n.d(i,"curveMonotoneY",(function(){return nU})),n.d(i,"curveNatural",(function(){return oU})),n.d(i,"curveStep",(function(){return sU})),n.d(i,"curveStepAfter",(function(){return lU})),n.d(i,"curveStepBefore",(function(){return cU})),n.d(i,"stack",(function(){return fU})),n.d(i,"stackOffsetExpand",(function(){return pU})),n.d(i,"stackOffsetDiverging",(function(){return mU})),n.d(i,"stackOffsetNone",(function(){return uU})),n.d(i,"stackOffsetSilhouette",(function(){return gU})),n.d(i,"stackOffsetWiggle",(function(){return vU})),n.d(i,"stackOrderAscending",(function(){return bU})),n.d(i,"stackOrderDescending",(function(){return _U})),n.d(i,"stackOrderInsideOut",(function(){return wU})),n.d(i,"stackOrderNone",(function(){return hU})),n.d(i,"stackOrderReverse",(function(){return kU})),n.d(i,"timeInterval",(function(){return xU})),n.d(i,"timeMillisecond",(function(){return MU})),n.d(i,"timeMilliseconds",(function(){return TU})),n.d(i,"utcMillisecond",(function(){return MU})),n.d(i,"utcMilliseconds",(function(){return TU})),n.d(i,"timeSecond",(function(){return PU})),n.d(i,"timeSeconds",(function(){return AU})),n.d(i,"utcSecond",(function(){return PU})),n.d(i,"utcSeconds",(function(){return AU})),n.d(i,"timeMinute",(function(){return IU})),n.d(i,"timeMinutes",(function(){return DU})),n.d(i,"timeHour",(function(){return LU})),n.d(i,"timeHours",(function(){return FU})),n.d(i,"timeDay",(function(){return BU})),n.d(i,"timeDays",(function(){return HU})),n.d(i,"timeWeek",(function(){return VU})),n.d(i,"timeWeeks",(function(){return YU})),n.d(i,"timeSunday",(function(){return VU})),n.d(i,"timeSundays",(function(){return YU})),n.d(i,"timeMonday",(function(){return UU})),n.d(i,"timeMondays",(function(){return ZU})),n.d(i,"timeTuesday",(function(){return qU})),n.d(i,"timeTuesdays",(function(){return QU})),n.d(i,"timeWednesday",(function(){return GU})),n.d(i,"timeWednesdays",(function(){return $U})),n.d(i,"timeThursday",(function(){return WU})),n.d(i,"timeThursdays",(function(){return JU})),n.d(i,"timeFriday",(function(){return KU})),n.d(i,"timeFridays",(function(){return tq})),n.d(i,"timeSaturday",(function(){return XU})),n.d(i,"timeSaturdays",(function(){return eq})),n.d(i,"timeMonth",(function(){return iq})),n.d(i,"timeMonths",(function(){return rq})),n.d(i,"timeYear",(function(){return aq})),n.d(i,"timeYears",(function(){return sq})),n.d(i,"utcMinute",(function(){return lq})),n.d(i,"utcMinutes",(function(){return uq})),n.d(i,"utcHour",(function(){return dq})),n.d(i,"utcHours",(function(){return fq})),n.d(i,"utcDay",(function(){return mq})),n.d(i,"utcDays",(function(){return gq})),n.d(i,"utcWeek",(function(){return bq})),n.d(i,"utcWeeks",(function(){return xq})),n.d(i,"utcSunday",(function(){return bq})),n.d(i,"utcSundays",(function(){return xq})),n.d(i,"utcMonday",(function(){return yq})),n.d(i,"utcMondays",(function(){return Oq})),n.d(i,"utcTuesday",(function(){return _q})),n.d(i,"utcTuesdays",(function(){return Mq})),n.d(i,"utcWednesday",(function(){return wq})),n.d(i,"utcWednesdays",(function(){return Tq})),n.d(i,"utcThursday",(function(){return kq})),n.d(i,"utcThursdays",(function(){return Eq})),n.d(i,"utcFriday",(function(){return Cq})),n.d(i,"utcFridays",(function(){return Pq})),n.d(i,"utcSaturday",(function(){return Sq})),n.d(i,"utcSaturdays",(function(){return Aq})),n.d(i,"utcMonth",(function(){return Iq})),n.d(i,"utcMonths",(function(){return Dq})),n.d(i,"utcYear",(function(){return Lq})),n.d(i,"utcYears",(function(){return Fq})),n.d(i,"timeFormatDefaultLocale",(function(){return iW})),n.d(i,"timeFormat",(function(){return Uq})),n.d(i,"timeParse",(function(){return qq})),n.d(i,"utcFormat",(function(){return Gq})),n.d(i,"utcParse",(function(){return Wq})),n.d(i,"timeFormatLocale",(function(){return zq})),n.d(i,"isoFormat",(function(){return rW})),n.d(i,"isoParse",(function(){return oW})),n.d(i,"now",(function(){return nC})),n.d(i,"timer",(function(){return oC})),n.d(i,"timerFlush",(function(){return aC})),n.d(i,"timeout",(function(){return uC})),n.d(i,"interval",(function(){return aW})),n.d(i,"transition",(function(){return LW})),n.d(i,"active",(function(){return VW})),n.d(i,"interrupt",(function(){return fW})),n.d(i,"voronoi",(function(){return MK})),n.d(i,"zoom",(function(){return qK})),n.d(i,"zoomTransform",(function(){return RK})),n.d(i,"zoomIdentity",(function(){return DK}));var r={};n.r(r),n.d(r,"FunctionToString",(function(){return Dyt})),n.d(r,"InboundFilters",(function(){return Fyt}));var o=n("ReuC"),a=n("foSv"),s=n("JX7q"),c=n("BsWD");function l(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t)){var n=[],i=!0,r=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(i=(a=s.next()).done)&&(n.push(a.value),!e||n.length!==e);i=!0);}catch(c){r=!0,o=c}finally{try{i||null==s.return||s.return()}finally{if(r)throw o}}return n}}(t,e)||Object(c.a)(t,e)||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.")}()}var u=n("KQm4");function h(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function d(t){if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(t=Object(c.a)(t))){var e=0,n=function(){};return{s:n,n:function(){return e>=t.length?{done:!0}:{done:!1,value:t[e++]}},e:function(t){throw t},f:n}}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 i,r,o=!0,a=!1;return{s:function(){i=t[Symbol.iterator]()},n:function(){var t=i.next();return o=t.done,t},e:function(t){a=!0,r=t},f:function(){try{o||null==i.return||i.return()}finally{if(a)throw r}}}}n("25BE");var f=n("Ji7U"),p=n("LK+K"),m=n("1OyB"),g=n("vuIU"),v=n("s4An"),b=n("2WcH");function y(t,e,n){return(y=Object(b.a)()?Reflect.construct:function(t,e,n){var i=[null];i.push.apply(i,e);var r=new(Function.bind.apply(t,i));return n&&Object(v.a)(r,n.prototype),r}).apply(null,arguments)}var _=n("quSY"),w=n("XNiG"),k=n("HDdC"),C=n("VRyK"),S=n("w1tV");function x(t){return{toString:t}.toString()}var O="__parameters__";function M(t,e,n){return x((function(){var i=function(t){return function(){if(t){var e=t.apply(void 0,arguments);for(var n in e)this[n]=e[n]}}}(e);function r(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if(this instanceof r)return i.apply(this,e),this;var o=y(r,e);return a.annotation=o,a;function a(t,e,n){for(var i=t.hasOwnProperty(O)?t[O]:Object.defineProperty(t,O,{value:[]})[O];i.length<=n;)i.push(null);return(i[n]=i[n]||[]).push(o),t}}return n&&(r.prototype=Object.create(n.prototype)),r.prototype.ngMetadataName=t,r.annotationCls=r,r}))}var T=M("Inject",(function(t){return{token:t}})),E=M("Optional"),P=M("Self"),A=M("SkipSelf"),j=function(t){return t[t.Default=0]="Default",t[t.Host=1]="Host",t[t.Self=2]="Self",t[t.SkipSelf=4]="SkipSelf",t[t.Optional=8]="Optional",t}({});function I(t){for(var e in t)if(t[e]===I)return e;throw Error("Could not find renamed property on target object.")}function D(t,e){for(var n in e)e.hasOwnProperty(n)&&!t.hasOwnProperty(n)&&(t[n]=e[n])}function R(t){return{token:t.token,providedIn:t.providedIn||null,factory:t.factory,value:void 0}}var L=R;function F(t){return{factory:t.factory,providers:t.providers||[],imports:t.imports||[]}}function N(t){return B(t,t[z])||B(t,t[q])}function B(t,e){return e&&e.token===t?e:null}function H(t){return t&&(t.hasOwnProperty(V)||t.hasOwnProperty(G))?t[V]:null}var z=I({"\u0275prov":I}),V=I({"\u0275inj":I}),U=I({"\u0275provFallback":I}),q=I({ngInjectableDef:I}),G=I({ngInjectorDef:I});function W(t){if("string"==typeof t)return t;if(Array.isArray(t))return"["+t.map(W).join(", ")+"]";if(null==t)return""+t;if(t.overriddenName)return"".concat(t.overriddenName);if(t.name)return"".concat(t.name);var e=t.toString();if(null==e)return""+e;var n=e.indexOf("\n");return-1===n?e:e.substring(0,n)}function K(t,e){return null==t||""===t?null===e?"":e:null==e||""===e?t:t+" "+e}var X=I({__forward_ref__:I});function Y(t){return t.__forward_ref__=Y,t.toString=function(){return W(this())},t}function Z(t){return Q(t)?t():t}function Q(t){return"function"==typeof t&&t.hasOwnProperty(X)&&t.__forward_ref__===Y}var $,J="undefined"!=typeof globalThis&&globalThis,tt="undefined"!=typeof window&&window,et="undefined"!=typeof self&&"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&self,nt="undefined"!=typeof global&&global,it=J||nt||tt||et,rt=I({"\u0275cmp":I}),ot=I({"\u0275dir":I}),at=I({"\u0275pipe":I}),st=I({"\u0275mod":I}),ct=I({"\u0275loc":I}),lt=I({"\u0275fac":I}),ut=I({__NG_ELEMENT_ID__:I}),ht=function(){function t(e,n){Object(m.a)(this,t),this._desc=e,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof n?this.__NG_ELEMENT_ID__=n:void 0!==n&&(this.\u0275prov=R({token:this,providedIn:n.providedIn||"root",factory:n.factory}))}return Object(g.a)(t,[{key:"toString",value:function(){return"InjectionToken ".concat(this._desc)}}]),t}(),dt=new ht("INJECTOR",-1),ft={},pt=/\n/gm,mt=I({provide:String,useValue:I}),gt=void 0;function vt(t){var e=gt;return gt=t,e}function bt(t){var e=$;return $=t,e}function yt(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.Default;if(void 0===gt)throw new Error("inject() must be called from an injection context");return null===gt?kt(t,void 0,e):gt.get(t,e&j.Optional?null:void 0,e)}function _t(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.Default;return($||yt)(Z(t),e)}var wt=_t;function kt(t,e,n){var i=N(t);if(i&&"root"==i.providedIn)return void 0===i.value?i.value=i.factory():i.value;if(n&j.Optional)return null;if(void 0!==e)return e;throw new Error("Injector: NOT_FOUND [".concat(W(t),"]"))}function Ct(t){for(var e=[],n=0;n<t.length;n++){var i=Z(t[n]);if(Array.isArray(i)){if(0===i.length)throw new Error("Arguments array must have arguments.");for(var r=void 0,o=j.Default,a=0;a<i.length;a++){var s=i[a];s instanceof E||"Optional"===s.ngMetadataName||s===E?o|=j.Optional:s instanceof A||"SkipSelf"===s.ngMetadataName||s===A?o|=j.SkipSelf:s instanceof P||"Self"===s.ngMetadataName||s===P?o|=j.Self:r=s instanceof T||s===T?s.token:s}e.push(_t(r,o))}else e.push(_t(i))}return e}var St=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"get",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:ft;if(e===ft){var n=new Error("NullInjectorError: No provider for ".concat(W(t),"!"));throw n.name="NullInjectorError",n}return e}}]),t}();function xt(t,e,n,i){var r=t.ngTempTokenPath;throw e.__source&&r.unshift(e.__source),t.message=function(t,e,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;t=t&&"\n"===t.charAt(0)&&"\u0275"==t.charAt(1)?t.substr(2):t;var r=W(e);if(Array.isArray(e))r=e.map(W).join(" -> ");else if("object"==typeof e){var o=[];for(var a in e)if(e.hasOwnProperty(a)){var s=e[a];o.push(a+":"+("string"==typeof s?JSON.stringify(s):W(s)))}r="{".concat(o.join(", "),"}")}return"".concat(n).concat(i?"("+i+")":"","[").concat(r,"]: ").concat(t.replace(pt,"\n "))}("\n"+t.message,r,n,i),t.ngTokenPath=r,t.ngTempTokenPath=null,t}var Ot=function t(){Object(m.a)(this,t)},Mt=function t(){Object(m.a)(this,t)};function Tt(t,e){t.forEach((function(t){return Array.isArray(t)?Tt(t,e):e(t)}))}function Et(t,e,n){e>=t.length?t.push(n):t.splice(e,0,n)}function Pt(t,e){return e>=t.length-1?t.pop():t.splice(e,1)[0]}function At(t,e){for(var n=[],i=0;i<t;i++)n.push(e);return n}function jt(t,e,n){var i=Dt(t,e);return i>=0?t[1|i]=n:function(t,e,n,i){var r=t.length;if(r==e)t.push(n,i);else if(1===r)t.push(i,t[0]),t[0]=n;else{for(r--,t.push(t[r-1],t[r]);r>e;)t[r]=t[r-2],r--;t[e]=n,t[e+1]=i}}(t,i=~i,e,n),i}function It(t,e){var n=Dt(t,e);if(n>=0)return t[1|n]}function Dt(t,e){return function(t,e,n){for(var i=0,r=t.length>>1;r!==i;){var o=i+(r-i>>1),a=t[o<<1];if(e===a)return o<<1;a>e?r=o:i=o+1}return~(r<<1)}(t,e)}var Rt=function(t){return t[t.OnPush=0]="OnPush",t[t.Default=1]="Default",t}({}),Lt=function(t){return t[t.Emulated=0]="Emulated",t[t.Native=1]="Native",t[t.None=2]="None",t[t.ShadowDom=3]="ShadowDom",t}({}),Ft={},Nt=[],Bt=0;function Ht(t){return x((function(){var e=t.type,n=e.prototype,i={},r={type:e,providersResolver:null,decls:t.decls,vars:t.vars,factory:null,template:t.template||null,consts:t.consts||null,ngContentSelectors:t.ngContentSelectors,hostBindings:t.hostBindings||null,hostVars:t.hostVars||0,hostAttrs:t.hostAttrs||null,contentQueries:t.contentQueries||null,declaredInputs:i,inputs:null,outputs:null,exportAs:t.exportAs||null,onChanges:null,onInit:n.ngOnInit||null,doCheck:n.ngDoCheck||null,afterContentInit:n.ngAfterContentInit||null,afterContentChecked:n.ngAfterContentChecked||null,afterViewInit:n.ngAfterViewInit||null,afterViewChecked:n.ngAfterViewChecked||null,onDestroy:n.ngOnDestroy||null,onPush:t.changeDetection===Rt.OnPush,directiveDefs:null,pipeDefs:null,selectors:t.selectors||Nt,viewQuery:t.viewQuery||null,features:t.features||null,data:t.data||{},encapsulation:t.encapsulation||Lt.Emulated,id:"c",styles:t.styles||Nt,_:null,setInput:null,schemas:t.schemas||null,tView:null},o=t.directives,a=t.features,s=t.pipes;return r.id+=Bt++,r.inputs=Gt(t.inputs,i),r.outputs=Gt(t.outputs),a&&a.forEach((function(t){return t(r)})),r.directiveDefs=o?function(){return("function"==typeof o?o():o).map(zt)}:null,r.pipeDefs=s?function(){return("function"==typeof s?s():s).map(Vt)}:null,r}))}function zt(t){return Xt(t)||function(t){return t[ot]||null}(t)}function Vt(t){return function(t){return t[at]||null}(t)}var Ut={};function qt(t){var e={type:t.type,bootstrap:t.bootstrap||Nt,declarations:t.declarations||Nt,imports:t.imports||Nt,exports:t.exports||Nt,transitiveCompileScopes:null,schemas:t.schemas||null,id:t.id||null};return null!=t.id&&x((function(){Ut[t.id]=t.type})),e}function Gt(t,e){if(null==t)return Ft;var n={};for(var i in t)if(t.hasOwnProperty(i)){var r=t[i],o=r;Array.isArray(r)&&(o=r[1],r=r[0]),n[r]=i,e&&(e[r]=o)}return n}var Wt=Ht;function Kt(t){return{type:t.type,name:t.name,factory:null,pure:!1!==t.pure,onDestroy:t.type.prototype.ngOnDestroy||null}}function Xt(t){return t[rt]||null}function Yt(t,e){return t.hasOwnProperty(lt)?t[lt]:null}function Zt(t,e){var n=t[st]||null;if(!n&&!0===e)throw new Error("Type ".concat(W(t)," does not have '\u0275mod' property."));return n}function Qt(t){return Array.isArray(t)&&"object"==typeof t[1]}function $t(t){return Array.isArray(t)&&!0===t[1]}function Jt(t){return 0!=(8&t.flags)}function te(t){return 2==(2&t.flags)}function ee(t){return 1==(1&t.flags)}function ne(t){return null!==t.template}function ie(t){return 0!=(512&t[2])}var re=void 0;function oe(){return void 0!==re?re:"undefined"!=typeof document?document:void 0}function ae(t){return!!t.listen}var se={createRenderer:function(t,e){return oe()}};function ce(t){for(;Array.isArray(t);)t=t[0];return t}function le(t,e){return ce(e[t+20])}function ue(t,e){return ce(e[t.index])}function he(t,e){return t.data[e+20]}function de(t,e){return t[e+20]}function fe(t,e){var n=e[t];return Qt(n)?n:n[0]}function pe(t){var e=function(t){return t.__ngContext__||null}(t);return e?Array.isArray(e)?e:e.lView:null}function me(t){return 4==(4&t[2])}function ge(t){return 128==(128&t[2])}function ve(t,e){return null===t||null==e?null:t[e]}function be(t){t[18]=0}function ye(t,e){t[5]+=e;for(var n=t,i=t[3];null!==i&&(1===e&&1===n[5]||-1===e&&0===n[5]);)i[5]+=e,n=i,i=i[3]}var _e={lFrame:Ue(null),bindingsEnabled:!0,checkNoChangesMode:!1};function we(){return _e.bindingsEnabled}function ke(){return _e.lFrame.lView}function Ce(){return _e.lFrame.tView}function Se(t){_e.lFrame.contextLView=t}function xe(){return _e.lFrame.previousOrParentTNode}function Oe(t,e){_e.lFrame.previousOrParentTNode=t,_e.lFrame.isParent=e}function Me(){return _e.lFrame.isParent}function Te(){_e.lFrame.isParent=!1}function Ee(){return _e.checkNoChangesMode}function Pe(t){_e.checkNoChangesMode=t}function Ae(){var t=_e.lFrame,e=t.bindingRootIndex;return-1===e&&(e=t.bindingRootIndex=t.tView.bindingStartIndex),e}function je(){return _e.lFrame.bindingIndex}function Ie(){return _e.lFrame.bindingIndex++}function De(t){var e=_e.lFrame,n=e.bindingIndex;return e.bindingIndex=e.bindingIndex+t,n}function Re(t,e){var n=_e.lFrame;n.bindingIndex=n.bindingRootIndex=t,Le(e)}function Le(t){_e.lFrame.currentDirectiveIndex=t}function Fe(t){var e=_e.lFrame.currentDirectiveIndex;return-1===e?null:t[e]}function Ne(){return _e.lFrame.currentQueryIndex}function Be(t){_e.lFrame.currentQueryIndex=t}function He(t,e){var n=Ve();_e.lFrame=n,n.previousOrParentTNode=e,n.lView=t}function ze(t,e){var n=Ve(),i=t[1];_e.lFrame=n,n.previousOrParentTNode=e,n.lView=t,n.tView=i,n.contextLView=t,n.bindingIndex=i.bindingStartIndex}function Ve(){var t=_e.lFrame,e=null===t?null:t.child;return null===e?Ue(t):e}function Ue(t){var e={previousOrParentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:0,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:t,child:null};return null!==t&&(t.child=e),e}function qe(){var t=_e.lFrame;return _e.lFrame=t.parent,t.previousOrParentTNode=null,t.lView=null,t}var Ge=qe;function We(){var t=qe();t.isParent=!0,t.tView=null,t.selectedIndex=0,t.contextLView=null,t.elementDepthCount=0,t.currentDirectiveIndex=-1,t.currentNamespace=null,t.bindingRootIndex=-1,t.bindingIndex=-1,t.currentQueryIndex=0}function Ke(t){return(_e.lFrame.contextLView=function(t,e){for(;t>0;)e=e[15],t--;return e}(t,_e.lFrame.contextLView))[8]}function Xe(){return _e.lFrame.selectedIndex}function Ye(t){_e.lFrame.selectedIndex=t}function Ze(){var t=_e.lFrame;return he(t.tView,t.selectedIndex)}function Qe(){_e.lFrame.currentNamespace="http://www.w3.org/2000/svg"}function $e(){_e.lFrame.currentNamespace=null}function Je(t,e){for(var n=e.directiveStart,i=e.directiveEnd;n<i;n++){var r=t.data[n];r.afterContentInit&&(t.contentHooks||(t.contentHooks=[])).push(-n,r.afterContentInit),r.afterContentChecked&&((t.contentHooks||(t.contentHooks=[])).push(n,r.afterContentChecked),(t.contentCheckHooks||(t.contentCheckHooks=[])).push(n,r.afterContentChecked)),r.afterViewInit&&(t.viewHooks||(t.viewHooks=[])).push(-n,r.afterViewInit),r.afterViewChecked&&((t.viewHooks||(t.viewHooks=[])).push(n,r.afterViewChecked),(t.viewCheckHooks||(t.viewCheckHooks=[])).push(n,r.afterViewChecked)),null!=r.onDestroy&&(t.destroyHooks||(t.destroyHooks=[])).push(n,r.onDestroy)}}function tn(t,e,n){rn(t,e,3,n)}function en(t,e,n,i){(3&t[2])===n&&rn(t,e,n,i)}function nn(t,e){var n=t[2];(3&n)===e&&(n&=2047,t[2]=n+=1)}function rn(t,e,n,i){for(var r=null!=i?i:-1,o=0,a=void 0!==i?65535&t[18]:0;a<e.length;a++)if("number"==typeof e[a+1]){if(o=e[a],null!=i&&o>=i)break}else e[a]<0&&(t[18]+=65536),(o<r||-1==r)&&(on(t,n,e,a),t[18]=(4294901760&t[18])+a+2),a++}function on(t,e,n,i){var r=n[i]<0,o=n[i+1],a=t[r?-n[i]:n[i]];r?t[2]>>11<t[18]>>16&&(3&t[2])===e&&(t[2]+=2048,o.call(a)):o.call(a)}var an=function t(e,n,i){Object(m.a)(this,t),this.factory=e,this.resolving=!1,this.canSeeViewProviders=n,this.injectImpl=i};function sn(t,e,n){for(var i=ae(t),r=0;r<n.length;){var o=n[r];if("number"==typeof o){if(0!==o)break;r++;var a=n[r++],s=n[r++],c=n[r++];i?t.setAttribute(e,s,c,a):e.setAttributeNS(a,s,c)}else{var l=o,u=n[++r];ln(l)?i&&t.setProperty(e,l,u):i?t.setAttribute(e,l,u):e.setAttribute(l,u),r++}}return r}function cn(t){return 3===t||4===t||6===t}function ln(t){return 64===t.charCodeAt(0)}function un(t,e){if(null===e||0===e.length);else if(null===t||0===t.length)t=e.slice();else for(var n=-1,i=0;i<e.length;i++){var r=e[i];"number"==typeof r?n=r:0===n||hn(t,n,r,null,-1===n||2===n?e[++i]:null)}return t}function hn(t,e,n,i,r){var o=0,a=t.length;if(-1===e)a=-1;else for(;o<t.length;){var s=t[o++];if("number"==typeof s){if(s===e){a=-1;break}if(s>e){a=o-1;break}}}for(;o<t.length;){var c=t[o];if("number"==typeof c)break;if(c===n){if(null===i)return void(null!==r&&(t[o+1]=r));if(i===t[o+1])return void(t[o+2]=r)}o++,null!==i&&o++,null!==r&&o++}-1!==a&&(t.splice(a,0,e),o=a+1),t.splice(o++,0,n),null!==i&&t.splice(o++,0,i),null!==r&&t.splice(o++,0,r)}function dn(t){return-1!==t}function fn(t){return 32767&t}function pn(t){return t>>16}function mn(t,e){for(var n=pn(t),i=e;n>0;)i=i[15],n--;return i}function gn(t){return"string"==typeof t?t:null==t?"":""+t}function vn(t){return"function"==typeof t?t.name||t.toString():"object"==typeof t&&null!=t&&"function"==typeof t.type?t.type.name||t.type.toString():gn(t)}var bn=function(){return("undefined"!=typeof requestAnimationFrame&&requestAnimationFrame||setTimeout).bind(it)}();function yn(t){return{name:"window",target:t.ownerDocument.defaultView}}function _n(t){return{name:"document",target:t.ownerDocument}}function wn(t){return{name:"body",target:t.ownerDocument.body}}function kn(t){return t instanceof Function?t():t}var Cn=!0;function Sn(t){var e=Cn;return Cn=t,e}var xn=0;function On(t,e){var n=Tn(t,e);if(-1!==n)return n;var i=e[1];i.firstCreatePass&&(t.injectorIndex=e.length,Mn(i.data,t),Mn(e,null),Mn(i.blueprint,null));var r=En(t,e),o=t.injectorIndex;if(dn(r))for(var a=fn(r),s=mn(r,e),c=s[1].data,l=0;l<8;l++)e[o+l]=s[a+l]|c[a+l];return e[o+8]=r,o}function Mn(t,e){t.push(0,0,0,0,0,0,0,0,e)}function Tn(t,e){return-1===t.injectorIndex||t.parent&&t.parent.injectorIndex===t.injectorIndex||null==e[t.injectorIndex+8]?-1:t.injectorIndex}function En(t,e){if(t.parent&&-1!==t.parent.injectorIndex)return t.parent.injectorIndex;for(var n=e[6],i=1;n&&-1===n.injectorIndex;)n=(e=e[15])?e[6]:null,i++;return n?n.injectorIndex|i<<16:-1}function Pn(t,e,n){!function(t,e,n){var i;"string"==typeof n?i=n.charCodeAt(0)||0:n.hasOwnProperty(ut)&&(i=n[ut]),null==i&&(i=n[ut]=xn++);var r=255&i,o=1<<r,a=64&r,s=32&r,c=e.data;128&r?a?s?c[t+7]|=o:c[t+6]|=o:s?c[t+5]|=o:c[t+4]|=o:a?s?c[t+3]|=o:c[t+2]|=o:s?c[t+1]|=o:c[t]|=o}(t,e,n)}function An(t,e,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:j.Default,r=arguments.length>4?arguments[4]:void 0;if(null!==t){var o=Ln(n);if("function"==typeof o){He(e,t);try{var a=o();if(null!=a||i&j.Optional)return a;throw new Error("No provider for ".concat(vn(n),"!"))}finally{Ge()}}else if("number"==typeof o){if(-1===o)return new Bn(t,e);var s=null,c=Tn(t,e),l=-1,u=i&j.Host?e[16][6]:null;for((-1===c||i&j.SkipSelf)&&(l=-1===c?En(t,e):e[c+8],Nn(i,!1)?(s=e[1],c=fn(l),e=mn(l,e)):c=-1);-1!==c;){l=e[c+8];var h=e[1];if(Fn(o,c,h.data)){var d=In(c,e,n,s,i,u);if(d!==jn)return d}Nn(i,e[1].data[c+8]===u)&&Fn(o,c,e)?(s=h,c=fn(l),e=mn(l,e)):c=-1}}}if(i&j.Optional&&void 0===r&&(r=null),0==(i&(j.Self|j.Host))){var f=e[9],p=bt(void 0);try{return f?f.get(n,r,i&j.Optional):kt(n,r,i&j.Optional)}finally{bt(p)}}if(i&j.Optional)return r;throw new Error("NodeInjector: NOT_FOUND [".concat(vn(n),"]"))}var jn={};function In(t,e,n,i,r,o){var a=e[1],s=a.data[t+8],c=Dn(s,a,n,null==i?te(s)&&Cn:i!=a&&3===s.type,r&j.Host&&o===s);return null!==c?Rn(e,a,c,s):jn}function Dn(t,e,n,i,r){for(var o=t.providerIndexes,a=e.data,s=65535&o,c=t.directiveStart,l=o>>16,u=r?s+l:t.directiveEnd,h=i?s:s+l;h<u;h++){var d=a[h];if(h<c&&n===d||h>=c&&d.type===n)return h}if(r){var f=a[c];if(f&&ne(f)&&f.type===n)return c}return null}function Rn(t,e,n,i){var r=t[n],o=e.data;if(r instanceof an){var a=r;if(a.resolving)throw new Error("Circular dep for ".concat(vn(o[n])));var s,c=Sn(a.canSeeViewProviders);a.resolving=!0,a.injectImpl&&(s=bt(a.injectImpl)),He(t,i);try{r=t[n]=a.factory(void 0,o,t,i),e.firstCreatePass&&n>=i.directiveStart&&function(t,e,n){var i=e.onChanges,r=e.onInit,o=e.doCheck;i&&((n.preOrderHooks||(n.preOrderHooks=[])).push(t,i),(n.preOrderCheckHooks||(n.preOrderCheckHooks=[])).push(t,i)),r&&(n.preOrderHooks||(n.preOrderHooks=[])).push(-t,r),o&&((n.preOrderHooks||(n.preOrderHooks=[])).push(t,o),(n.preOrderCheckHooks||(n.preOrderCheckHooks=[])).push(t,o))}(n,o[n],e)}finally{a.injectImpl&&bt(s),Sn(c),a.resolving=!1,Ge()}}return r}function Ln(t){if("string"==typeof t)return t.charCodeAt(0)||0;var e=t.hasOwnProperty(ut)?t[ut]:void 0;return"number"==typeof e&&e>0?255&e:e}function Fn(t,e,n){var i=64&t,r=32&t;return!!((128&t?i?r?n[e+7]:n[e+6]:r?n[e+5]:n[e+4]:i?r?n[e+3]:n[e+2]:r?n[e+1]:n[e])&1<<t)}function Nn(t,e){return!(t&j.Self||t&j.Host&&e)}var Bn=function(){function t(e,n){Object(m.a)(this,t),this._tNode=e,this._lView=n}return Object(g.a)(t,[{key:"get",value:function(t,e){return An(this._tNode,this._lView,t,void 0,e)}}]),t}();function Hn(t){var e=t;if(Q(t))return function(){var t=Hn(Z(e));return t?t():null};var n=Yt(e);if(null===n){var i=H(e);n=i&&i.factory}return n||null}function zn(t){return x((function(){for(var e=t.prototype.constructor,n=e[lt]||Hn(e),i=Object.prototype,r=Object.getPrototypeOf(t.prototype).constructor;r&&r!==i;){var o=r[lt]||Hn(r);if(o&&o!==n)return o;r=Object.getPrototypeOf(r)}return function(t){return new t}}))}function Vn(t){return t.ngDebugContext}function Un(t){return t.ngOriginalError}function qn(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];t.error.apply(t,n)}var Gn=function(){function t(){Object(m.a)(this,t),this._console=console}return Object(g.a)(t,[{key:"handleError",value:function(t){var e=this._findOriginalError(t),n=this._findContext(t),i=function(t){return t.ngErrorLogger||qn}(t);i(this._console,"ERROR",t),e&&i(this._console,"ORIGINAL ERROR",e),n&&i(this._console,"ERROR CONTEXT",n)}},{key:"_findContext",value:function(t){return t?Vn(t)?Vn(t):this._findContext(Un(t)):null}},{key:"_findOriginalError",value:function(t){for(var e=Un(t);e&&Un(e);)e=Un(e);return e}}]),t}(),Wn=function(){function t(e){Object(m.a)(this,t),this.changingThisBreaksApplicationSecurity=e}return Object(g.a)(t,[{key:"toString",value:function(){return"SafeValue must use [property]=binding: ".concat(this.changingThisBreaksApplicationSecurity)+" (see http://g.co/ng/security#xss)"}}]),t}(),Kn=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"getTypeName",value:function(){return"HTML"}}]),n}(Wn),Xn=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"getTypeName",value:function(){return"Style"}}]),n}(Wn),Yn=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"getTypeName",value:function(){return"Script"}}]),n}(Wn),Zn=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"getTypeName",value:function(){return"URL"}}]),n}(Wn),Qn=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"getTypeName",value:function(){return"ResourceURL"}}]),n}(Wn);function $n(t){return t instanceof Wn?t.changingThisBreaksApplicationSecurity:t}function Jn(t,e){var n=ti(t);if(null!=n&&n!==e){if("ResourceURL"===n&&"URL"===e)return!0;throw new Error("Required a safe ".concat(e,", got a ").concat(n," (see http://g.co/ng/security#xss)"))}return n===e}function ti(t){return t instanceof Wn&&t.getTypeName()||null}var ei=!0,ni=!1;function ii(){return ni=!0,ei}var ri=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"getInertBodyElement",value:function(t){t="<body><remove></remove>"+t+"</body>";try{var e=(new window.DOMParser).parseFromString(t,"text/html").body;return e.removeChild(e.firstChild),e}catch(n){return null}}}]),t}(),oi=function(){function t(e){if(Object(m.a)(this,t),this.defaultDoc=e,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert"),null==this.inertDocument.body){var n=this.inertDocument.createElement("html");this.inertDocument.appendChild(n);var i=this.inertDocument.createElement("body");n.appendChild(i)}}return Object(g.a)(t,[{key:"getInertBodyElement",value:function(t){var e=this.inertDocument.createElement("template");if("content"in e)return e.innerHTML=t,e;var n=this.inertDocument.createElement("body");return n.innerHTML=t,this.defaultDoc.documentMode&&this.stripCustomNsAttrs(n),n}},{key:"stripCustomNsAttrs",value:function(t){for(var e=t.attributes,n=e.length-1;0<n;n--){var i=e.item(n).name;"xmlns:ns1"!==i&&0!==i.indexOf("ns1:")||t.removeAttribute(i)}for(var r=t.firstChild;r;)r.nodeType===Node.ELEMENT_NODE&&this.stripCustomNsAttrs(r),r=r.nextSibling}}]),t}(),ai=/^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi,si=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+\/]+=*$/i;function ci(t){return(t=String(t)).match(ai)||t.match(si)?t:(ii()&&console.warn("WARNING: sanitizing unsafe URL value ".concat(t," (see http://g.co/ng/security#xss)")),"unsafe:"+t)}function li(t){var e,n={},i=d(t.split(","));try{for(i.s();!(e=i.n()).done;)n[e.value]=!0}catch(r){i.e(r)}finally{i.f()}return n}function ui(){for(var t={},e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];for(var r=0,o=n;r<o.length;r++){var a=o[r];for(var s in a)a.hasOwnProperty(s)&&(t[s]=!0)}return t}var hi,di=li("area,br,col,hr,img,wbr"),fi=li("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),pi=li("rp,rt"),mi=ui(pi,fi),gi=ui(di,ui(fi,li("address,article,aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul")),ui(pi,li("a,abbr,acronym,audio,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video")),mi),vi=li("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),bi=li("srcset"),yi=ui(vi,bi,li("abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,scope,scrolling,shape,size,sizes,span,srclang,start,summary,tabindex,target,title,translate,type,usemap,valign,value,vspace,width"),li("aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext")),_i=li("script,style,template"),wi=function(){function t(){Object(m.a)(this,t),this.sanitizedSomething=!1,this.buf=[]}return Object(g.a)(t,[{key:"sanitizeChildren",value:function(t){for(var e=t.firstChild,n=!0;e;)if(e.nodeType===Node.ELEMENT_NODE?n=this.startElement(e):e.nodeType===Node.TEXT_NODE?this.chars(e.nodeValue):this.sanitizedSomething=!0,n&&e.firstChild)e=e.firstChild;else for(;e;){e.nodeType===Node.ELEMENT_NODE&&this.endElement(e);var i=this.checkClobberedElement(e,e.nextSibling);if(i){e=i;break}e=this.checkClobberedElement(e,e.parentNode)}return this.buf.join("")}},{key:"startElement",value:function(t){var e,n=t.nodeName.toLowerCase();if(!gi.hasOwnProperty(n))return this.sanitizedSomething=!0,!_i.hasOwnProperty(n);this.buf.push("<"),this.buf.push(n);for(var i=t.attributes,r=0;r<i.length;r++){var o=i.item(r),a=o.name,s=a.toLowerCase();if(yi.hasOwnProperty(s)){var c=o.value;vi[s]&&(c=ci(c)),bi[s]&&(e=c,c=(e=String(e)).split(",").map((function(t){return ci(t.trim())})).join(", ")),this.buf.push(" ",a,'="',Si(c),'"')}else this.sanitizedSomething=!0}return this.buf.push(">"),!0}},{key:"endElement",value:function(t){var e=t.nodeName.toLowerCase();gi.hasOwnProperty(e)&&!di.hasOwnProperty(e)&&(this.buf.push("</"),this.buf.push(e),this.buf.push(">"))}},{key:"chars",value:function(t){this.buf.push(Si(t))}},{key:"checkClobberedElement",value:function(t,e){if(e&&(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_CONTAINED_BY)===Node.DOCUMENT_POSITION_CONTAINED_BY)throw new Error("Failed to sanitize html because the element is clobbered: ".concat(t.outerHTML));return e}}]),t}(),ki=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Ci=/([^\#-~ |!])/g;function Si(t){return t.replace(/&/g,"&amp;").replace(ki,(function(t){return"&#"+(1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320)+65536)+";"})).replace(Ci,(function(t){return"&#"+t.charCodeAt(0)+";"})).replace(/</g,"&lt;").replace(/>/g,"&gt;")}function xi(t,e){var n=null;try{hi=hi||function(t){return function(){try{return!!(new window.DOMParser).parseFromString("","text/html")}catch(t){return!1}}()?new ri:new oi(t)}(t);var i=e?String(e):"";n=hi.getInertBodyElement(i);var r=5,o=i;do{if(0===r)throw new Error("Failed to sanitize html because the input is unstable");r--,i=o,o=n.innerHTML,n=hi.getInertBodyElement(i)}while(i!==o);var a=new wi,s=a.sanitizeChildren(Oi(n)||n);return ii()&&a.sanitizedSomething&&console.warn("WARNING: sanitizing HTML stripped some content, see http://g.co/ng/security#xss"),s}finally{if(n)for(var c=Oi(n)||n;c.firstChild;)c.removeChild(c.firstChild)}}function Oi(t){return"content"in t&&function(t){return t.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===t.nodeName}(t)?t.content:null}var Mi=function(t){return t[t.NONE=0]="NONE",t[t.HTML=1]="HTML",t[t.STYLE=2]="STYLE",t[t.SCRIPT=3]="SCRIPT",t[t.URL=4]="URL",t[t.RESOURCE_URL=5]="RESOURCE_URL",t}({});function Ti(t){var e=Ai();return e?e.sanitize(Mi.HTML,t)||"":Jn(t,"HTML")?$n(t):xi(oe(),gn(t))}function Ei(t){var e=Ai();return e?e.sanitize(Mi.STYLE,t)||"":Jn(t,"Style")?$n(t):gn(t)}function Pi(t){var e=Ai();return e?e.sanitize(Mi.URL,t)||"":Jn(t,"URL")?$n(t):ci(gn(t))}function Ai(){var t=ke();return t&&t[12]}function ji(t,e){t.__ngContext__=e}function Ii(t){throw new Error("Multiple components match node with tagname ".concat(t.tagName))}function Di(){throw new Error("Cannot mix multi providers and regular providers")}function Ri(t,e,n){for(var i=t.length;;){var r=t.indexOf(e,n);if(-1===r)return r;if(0===r||t.charCodeAt(r-1)<=32){var o=e.length;if(r+o===i||t.charCodeAt(r+o)<=32)return r}n=r+1}}function Li(t,e,n){for(var i=0;i<t.length;){var r=t[i++];if(n&&"class"===r){if(-1!==Ri((r=t[i]).toLowerCase(),e,0))return!0}else if(1===r){for(;i<t.length&&"string"==typeof(r=t[i++]);)if(r.toLowerCase()===e)return!0;return!1}}return!1}function Fi(t){return 0===t.type&&"ng-template"!==t.tagName}function Ni(t,e,n){return e===(0!==t.type||n?t.tagName:"ng-template")}function Bi(t,e,n){for(var i=4,r=t.attrs||[],o=function(t){for(var e=0;e<t.length;e++)if(cn(t[e]))return e;return t.length}(r),a=!1,s=0;s<e.length;s++){var c=e[s];if("number"!=typeof c){if(!a)if(4&i){if(i=2|1&i,""!==c&&!Ni(t,c,n)||""===c&&1===e.length){if(Hi(i))return!1;a=!0}}else{var l=8&i?c:e[++s];if(8&i&&null!==t.attrs){if(!Li(t.attrs,l,n)){if(Hi(i))return!1;a=!0}continue}var u=zi(8&i?"class":c,r,Fi(t),n);if(-1===u){if(Hi(i))return!1;a=!0;continue}if(""!==l){var h;h=u>o?"":r[u+1].toLowerCase();var d=8&i?h:null;if(d&&-1!==Ri(d,l,0)||2&i&&l!==h){if(Hi(i))return!1;a=!0}}}}else{if(!a&&!Hi(i)&&!Hi(c))return!1;if(a&&Hi(c))continue;a=!1,i=c|1&i}}return Hi(i)||a}function Hi(t){return 0==(1&t)}function zi(t,e,n,i){if(null===e)return-1;var r=0;if(i||!n){for(var o=!1;r<e.length;){var a=e[r];if(a===t)return r;if(3===a||6===a)o=!0;else{if(1===a||2===a){for(var s=e[++r];"string"==typeof s;)s=e[++r];continue}if(4===a)break;if(0===a){r+=4;continue}}r+=o?1:2}return-1}return function(t,e){var n=t.indexOf(4);if(n>-1)for(n++;n<t.length;){var i=t[n];if("number"==typeof i)return-1;if(i===e)return n;n++}return-1}(e,t)}function Vi(t,e){for(var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=0;i<e.length;i++)if(Bi(t,e[i],n))return!0;return!1}function Ui(t,e){t:for(var n=0;n<e.length;n++){var i=e[n];if(t.length===i.length){for(var r=0;r<t.length;r++)if(t[r]!==i[r])continue t;return!0}}return!1}function qi(t,e){return t?":not("+e.trim()+")":e}function Gi(t){for(var e=t[0],n=1,i=2,r="",o=!1;n<t.length;){var a=t[n];if("string"==typeof a)if(2&i){var s=t[++n];r+="["+a+(s.length>0?'="'+s+'"':"")+"]"}else 8&i?r+="."+a:4&i&&(r+=" "+a);else""===r||Hi(a)||(e+=qi(o,r),r=""),i=a,o=o||!Hi(i);n++}return""!==r&&(e+=qi(o,r)),e}var Wi={};function Ki(t){var e=t[3];return $t(e)?e[3]:e}function Xi(t){return Zi(t[13])}function Yi(t){return Zi(t[4])}function Zi(t){for(;null!==t&&!$t(t);)t=t[4];return t}function Qi(t){$i(Ce(),ke(),Xe()+t,Ee())}function $i(t,e,n,i){if(!i)if(3==(3&e[2])){var r=t.preOrderCheckHooks;null!==r&&tn(e,r,n)}else{var o=t.preOrderHooks;null!==o&&en(e,o,0,n)}Ye(n)}function Ji(t,e){return t<<17|e<<2}function tr(t){return t>>17&32767}function er(t){return 2|t}function nr(t){return(131068&t)>>2}function ir(t,e){return-131069&t|e<<2}function rr(t){return 1|t}function or(t,e){var n=t.contentQueries;if(null!==n)for(var i=0;i<n.length;i+=2){var r=n[i+1];if(-1!==r){var o=t.data[r];Be(n[i]),o.contentQueries(2,e[r],r)}}}function ar(t,e,n){return ae(e)?e.createElement(t,n):null===n?e.createElement(t):e.createElementNS(n,t)}function sr(t,e,n,i,r,o,a,s,c,l){var u=e.blueprint.slice();return u[0]=r,u[2]=140|i,be(u),u[3]=u[15]=t,u[8]=n,u[10]=a||t&&t[10],u[11]=s||t&&t[11],u[12]=c||t&&t[12]||null,u[9]=l||t&&t[9]||null,u[6]=o,u[16]=2==e.type?t[16]:u,u}function cr(t,e,n,i,r,o){var a=n+20,s=t.data[a]||function(t,e,n,i,r,o){var a=xe(),s=Me(),c=s?a:a&&a.parent,l=t.data[n]=yr(0,c&&c!==e?c:null,i,n,r,o);return null===t.firstChild&&(t.firstChild=l),a&&(!s||null!=a.child||null===l.parent&&2!==a.type?s||(a.next=l):a.child=l),l}(t,e,a,i,r,o);return Oe(s,!0),s}function lr(t,e,n){ze(e,e[6]);try{var i=t.viewQuery;null!==i&&Vr(1,i,n);var r=t.template;null!==r&&dr(t,e,r,1,n),t.firstCreatePass&&(t.firstCreatePass=!1),t.staticContentQueries&&or(t,e),t.staticViewQueries&&Vr(2,t.viewQuery,n);var o=t.components;null!==o&&function(t,e){for(var n=0;n<e.length;n++)Fr(t,e[n])}(e,o)}catch(a){throw t.firstCreatePass&&(t.incompleteFirstPass=!0),a}finally{e[2]&=-5,We()}}function ur(t,e,n,i){var r=e[2];if(256!=(256&r)){ze(e,e[6]);var o=Ee();try{be(e),_e.lFrame.bindingIndex=t.bindingStartIndex,null!==n&&dr(t,e,n,2,i);var a=3==(3&r);if(!o)if(a){var s=t.preOrderCheckHooks;null!==s&&tn(e,s,null)}else{var c=t.preOrderHooks;null!==c&&en(e,c,0,null),nn(e,0)}if(function(t){for(var e=Xi(t);null!==e;e=Yi(e))if(e[2])for(var n=e[9],i=0;i<n.length;i++){var r=n[i];0==(1024&r[2])&&ye(r[3],1),r[2]|=1024}}(e),function(t){for(var e=Xi(t);null!==e;e=Yi(e))for(var n=10;n<e.length;n++){var i=e[n],r=i[1];ge(i)&&ur(r,i,r.template,i[8])}}(e),null!==t.contentQueries&&or(t,e),!o)if(a){var l=t.contentCheckHooks;null!==l&&tn(e,l)}else{var u=t.contentHooks;null!==u&&en(e,u,1),nn(e,1)}!function(t,e){try{var n=t.expandoInstructions;if(null!==n)for(var i=t.expandoStartIndex,r=-1,o=0;o<n.length;o++){var a=n[o];"number"==typeof a?a<=0?(Ye(0-a),r=i+=9+n[++o]):i+=a:(null!==a&&(Re(i,r),a(2,e[r])),r++)}}finally{Ye(-1)}}(t,e);var h=t.components;null!==h&&function(t,e){for(var n=0;n<e.length;n++)Lr(t,e[n])}(e,h);var d=t.viewQuery;if(null!==d&&Vr(2,d,i),!o)if(a){var f=t.viewCheckHooks;null!==f&&tn(e,f)}else{var p=t.viewHooks;null!==p&&en(e,p,2),nn(e,2)}!0===t.firstUpdatePass&&(t.firstUpdatePass=!1),o||(e[2]&=-73),1024&e[2]&&(e[2]&=-1025,ye(e[3],-1))}finally{We()}}}function hr(t,e,n,i){var r=e[10],o=!Ee(),a=me(e);try{o&&!a&&r.begin&&r.begin(),a&&lr(t,e,i),ur(t,e,n,i)}finally{o&&!a&&r.end&&r.end()}}function dr(t,e,n,i,r){var o=Xe();try{Ye(-1),2&i&&e.length>20&&$i(t,e,0,Ee()),n(i,r)}finally{Ye(o)}}function fr(t,e,n){if(Jt(e))for(var i=e.directiveEnd,r=e.directiveStart;r<i;r++){var o=t.data[r];o.contentQueries&&o.contentQueries(1,n[r],r)}}function pr(t,e,n){we()&&(function(t,e,n,i){var r=n.directiveStart,o=n.directiveEnd;t.firstCreatePass||On(n,e),ji(i,e);for(var a=n.initialInputs,s=r;s<o;s++){var c=t.data[s],l=ne(c);l&&Ar(e,n,c);var u=Rn(e,t,s,n);ji(u,e),null!==a&&Ir(0,s-r,u,c,0,a),l&&(fe(n.index,e)[8]=u)}}(t,e,n,ue(n,e)),128==(128&n.flags)&&function(t,e,n){var i=n.directiveStart,r=n.directiveEnd,o=t.expandoInstructions,a=t.firstCreatePass,s=n.index-20,c=_e.lFrame.currentDirectiveIndex;try{Ye(s);for(var l=i;l<r;l++){var u=t.data[l],h=e[l];Le(l),null!==u.hostBindings||0!==u.hostVars||null!==u.hostAttrs?xr(u,h):a&&o.push(null)}}finally{Ye(-1),Le(c)}}(t,e,n))}function mr(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:ue,i=e.localNames;if(null!==i)for(var r=e.index+1,o=0;o<i.length;o+=2){var a=i[o+1],s=-1===a?n(e,t):t[a];t[r++]=s}}function gr(t){var e=t.tView;return null===e||e.incompleteFirstPass?t.tView=vr(1,-1,t.template,t.decls,t.vars,t.directiveDefs,t.pipeDefs,t.viewQuery,t.schemas,t.consts):e}function vr(t,e,n,i,r,o,a,s,c,l){var u=20+i,h=u+r,d=function(t,e){for(var n=[],i=0;i<e;i++)n.push(i<t?null:Wi);return n}(u,h);return d[1]={type:t,id:e,blueprint:d,template:n,queries:null,viewQuery:s,node:null,data:d.slice().fill(null,u),bindingStartIndex:u,expandoStartIndex:h,expandoInstructions:null,firstCreatePass:!0,firstUpdatePass:!0,staticViewQueries:!1,staticContentQueries:!1,preOrderHooks:null,preOrderCheckHooks:null,contentHooks:null,contentCheckHooks:null,viewHooks:null,viewCheckHooks:null,destroyHooks:null,cleanup:null,contentQueries:null,components:null,directiveRegistry:"function"==typeof o?o():o,pipeRegistry:"function"==typeof a?a():a,firstChild:null,schemas:c,consts:l,incompleteFirstPass:!1}}function br(t,e,n,i){var r=qr(e);r.push(n),t.firstCreatePass&&function(t){return t.cleanup||(t.cleanup=[])}(t).push(i,r.length-1)}function yr(t,e,n,i,r,o){return{type:n,index:i,injectorIndex:e?e.injectorIndex:-1,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,propertyBindings:null,flags:0,providerIndexes:0,tagName:r,attrs:o,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tViews:null,next:null,projectionNext:null,child:null,parent:e,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}function _r(t,e,n){for(var i in t)if(t.hasOwnProperty(i)){var r=t[i];(n=null===n?{}:n).hasOwnProperty(i)?n[i].push(e,r):n[i]=[e,r]}return n}function wr(t,e,n,i,r,o,a,s){var c,l,u=ue(e,n),h=e.inputs;!s&&null!=h&&(c=h[i])?(Kr(t,n,c,i,r),te(e)&&function(t,e){var n=fe(e,t);16&n[2]||(n[2]|=64)}(n,e.index)):3===e.type&&(i="class"===(l=i)?"className":"for"===l?"htmlFor":"formaction"===l?"formAction":"innerHtml"===l?"innerHTML":"readonly"===l?"readOnly":"tabindex"===l?"tabIndex":l,r=null!=a?a(r,e.tagName||"",i):r,ae(o)?o.setProperty(u,i,r):ln(i)||(u.setProperty?u.setProperty(i,r):u[i]=r))}function kr(t,e,n,i){var r=!1;if(we()){var o=function(t,e,n){var i=t.directiveRegistry,r=null;if(i)for(var o=0;o<i.length;o++){var a=i[o];Vi(n,a.selectors,!1)&&(r||(r=[]),Pn(On(n,e),t,a.type),ne(a)?(2&n.flags&&Ii(n),Mr(t,n),r.unshift(a)):r.push(a))}return r}(t,e,n),a=null===i?null:{"":-1};if(null!==o){var s=0;r=!0,Er(n,t.data.length,o.length);for(var c=0;c<o.length;c++){var l=o[c];l.providersResolver&&l.providersResolver(l)}Or(t,n,o.length);for(var u=!1,h=!1,d=0;d<o.length;d++){var f=o[d];n.mergedAttrs=un(n.mergedAttrs,f.hostAttrs),Pr(t,e,f),Tr(t.data.length-1,f,a),null!==f.contentQueries&&(n.flags|=8),null===f.hostBindings&&null===f.hostAttrs&&0===f.hostVars||(n.flags|=128),!u&&(f.onChanges||f.onInit||f.doCheck)&&((t.preOrderHooks||(t.preOrderHooks=[])).push(n.index-20),u=!0),h||!f.onChanges&&!f.doCheck||((t.preOrderCheckHooks||(t.preOrderCheckHooks=[])).push(n.index-20),h=!0),Cr(t,f),s+=f.hostVars}!function(t,e){for(var n=e.directiveEnd,i=t.data,r=e.attrs,o=[],a=null,s=null,c=e.directiveStart;c<n;c++){var l=i[c],u=l.inputs,h=null===r||Fi(e)?null:Dr(u,r);o.push(h),a=_r(u,c,a),s=_r(l.outputs,c,s)}null!==a&&(a.hasOwnProperty("class")&&(e.flags|=16),a.hasOwnProperty("style")&&(e.flags|=32)),e.initialInputs=o,e.inputs=a,e.outputs=s}(t,n),Sr(t,e,s)}a&&function(t,e,n){if(e)for(var i=t.localNames=[],r=0;r<e.length;r+=2){var o=n[e[r+1]];if(null==o)throw new Error("Export of name '".concat(e[r+1],"' not found!"));i.push(e[r],o)}}(n,i,a)}return n.mergedAttrs=un(n.mergedAttrs,n.attrs),r}function Cr(t,e){var n=t.expandoInstructions;n.push(e.hostBindings),0!==e.hostVars&&n.push(e.hostVars)}function Sr(t,e,n){for(var i=0;i<n;i++)e.push(Wi),t.blueprint.push(Wi),t.data.push(null)}function xr(t,e){null!==t.hostBindings&&t.hostBindings(1,e)}function Or(t,e,n){var i=20-e.index,r=t.data.length-(65535&e.providerIndexes);(t.expandoInstructions||(t.expandoInstructions=[])).push(i,r,n)}function Mr(t,e){e.flags|=2,(t.components||(t.components=[])).push(e.index)}function Tr(t,e,n){if(n){if(e.exportAs)for(var i=0;i<e.exportAs.length;i++)n[e.exportAs[i]]=t;ne(e)&&(n[""]=t)}}function Er(t,e,n){t.flags|=1,t.directiveStart=e,t.directiveEnd=e+n,t.providerIndexes=e}function Pr(t,e,n){t.data.push(n);var i=n.factory||(n.factory=Yt(n.type)),r=new an(i,ne(n),null);t.blueprint.push(r),e.push(r)}function Ar(t,e,n){var i=ue(e,t),r=gr(n),o=t[10],a=Nr(t,sr(t,r,null,n.onPush?64:16,i,e,o,o.createRenderer(i,n)));t[e.index]=a}function jr(t,e,n,i,r,o){var a=ue(t,e),s=e[11];if(null==i)ae(s)?s.removeAttribute(a,n,o):a.removeAttribute(n);else{var c=null==r?gn(i):r(i,t.tagName||"",n);ae(s)?s.setAttribute(a,n,c,o):o?a.setAttributeNS(o,n,c):a.setAttribute(n,c)}}function Ir(t,e,n,i,r,o){var a=o[e];if(null!==a)for(var s=i.setInput,c=0;c<a.length;){var l=a[c++],u=a[c++],h=a[c++];null!==s?i.setInput(n,h,l,u):n[u]=h}}function Dr(t,e){for(var n=null,i=0;i<e.length;){var r=e[i];if(0!==r)if(5!==r){if("number"==typeof r)break;t.hasOwnProperty(r)&&(null===n&&(n=[]),n.push(r,t[r],e[i+1])),i+=2}else i+=2;else i+=4}return n}function Rr(t,e,n,i){return new Array(t,!0,!1,e,null,0,i,n,null,null)}function Lr(t,e){var n=fe(e,t);if(ge(n)){var i=n[1];80&n[2]?ur(i,n,i.template,n[8]):n[5]>0&&function t(e){for(var n=Xi(e);null!==n;n=Yi(n))for(var i=10;i<n.length;i++){var r=n[i];if(1024&r[2]){var o=r[1];ur(o,r,o.template,r[8])}else r[5]>0&&t(r)}var a=e[1].components;if(null!==a)for(var s=0;s<a.length;s++){var c=fe(a[s],e);ge(c)&&c[5]>0&&t(c)}}(n)}}function Fr(t,e){var n=fe(e,t),i=n[1];!function(t,e){for(var n=e.length;n<t.blueprint.length;n++)e.push(t.blueprint[n])}(i,n),lr(i,n,n[8])}function Nr(t,e){return t[13]?t[14][4]=e:t[13]=e,t[14]=e,e}function Br(t){for(;t;){t[2]|=64;var e=Ki(t);if(ie(t)&&!e)return t;t=e}return null}function Hr(t,e,n){var i=e[10];i.begin&&i.begin();try{ur(t,e,t.template,n)}catch(r){throw Wr(e,r),r}finally{i.end&&i.end()}}function zr(t){!function(t){for(var e=0;e<t.components.length;e++){var n=t.components[e],i=pe(n),r=i[1];hr(r,i,r.template,n)}}(t[8])}function Vr(t,e,n){Be(0),e(t,n)}var Ur=function(){return Promise.resolve(null)}();function qr(t){return t[7]||(t[7]=[])}function Gr(t,e,n){return(null===t||ne(t))&&(n=function(t){for(;Array.isArray(t);){if("object"==typeof t[1])return t;t=t[0]}return null}(n[e.index])),n[11]}function Wr(t,e){var n=t[9],i=n?n.get(Gn,null):null;i&&i.handleError(e)}function Kr(t,e,n,i,r){for(var o=0;o<n.length;){var a=n[o++],s=n[o++],c=e[a],l=t.data[a];null!==l.setInput?l.setInput(c,r,i,s):c[s]=r}}function Xr(t,e,n){var i=le(e,t),r=t[11];ae(r)?r.setValue(i,n):i.textContent=n}function Yr(t,e){var n=e[3];return-1===t.index?$t(n)?n:null:n}function Zr(t,e){var n=Yr(t,e);return n?lo(e[11],n[7]):null}function Qr(t,e,n,i,r){if(null!=i){var o,a=!1;$t(i)?o=i:Qt(i)&&(a=!0,i=i[0]);var s=ce(i);0===t&&null!==n?null==r?so(e,n,s):ao(e,n,s,r||null):1===t&&null!==n?ao(e,n,s,r||null):2===t?function(t,e,n){var i=lo(t,e);i&&function(t,e,n,i){ae(t)?t.removeChild(e,n,i):e.removeChild(n)}(t,i,e,n)}(e,s,a):3===t&&e.destroyNode(s),null!=o&&function(t,e,n,i,r){var o=n[7];o!==ce(n)&&Qr(e,t,i,o,r);for(var a=10;a<n.length;a++){var s=n[a];mo(s[1],s,t,e,i,o)}}(e,t,o,n,r)}}function $r(t,e){return ae(e)?e.createText(t):e.createTextNode(t)}function Jr(t,e,n,i){var r=Zr(t.node,e);r&&mo(t,e,e[11],n?1:2,r,i)}function to(t,e){var n=t[9],i=n.indexOf(e);1024&e[2]&&ye(e[3],-1),n.splice(i,1)}function eo(t,e){if(!(t.length<=10)){var n=10+e,i=t[n];if(i){var r=i[17];null!==r&&r!==t&&to(r,i),e>0&&(t[n-1][4]=i[4]);var o=Pt(t,10+e);Jr(i[1],i,!1,null);var a=o[19];null!==a&&a.detachView(o[1]),i[3]=null,i[4]=null,i[2]&=-129}return i}}function no(t,e){if(!(256&e[2])){var n=e[11];ae(n)&&n.destroyNode&&mo(t,e,n,3,null,null),function(t){var e=t[13];if(!e)return ro(t[1],t);for(;e;){var n=null;if(Qt(e))n=e[13];else{var i=e[10];i&&(n=i)}if(!n){for(;e&&!e[4]&&e!==t;)Qt(e)&&ro(e[1],e),e=io(e,t);null===e&&(e=t),Qt(e)&&ro(e[1],e),n=e&&e[4]}e=n}}(e)}}function io(t,e){var n;return Qt(t)&&(n=t[6])&&2===n.type?Yr(n,t):t[3]===e?null:t[3]}function ro(t,e){if(!(256&e[2])){e[2]&=-129,e[2]|=256,function(t,e){var n;if(null!=t&&null!=(n=t.destroyHooks))for(var i=0;i<n.length;i+=2){var r=e[n[i]];if(!(r instanceof an)){var o=n[i+1];if(Array.isArray(o))for(var a=0;a<o.length;a+=2)o[a+1].call(r[o[a]]);else o.call(r)}}}(t,e),function(t,e){var n=t.cleanup;if(null!==n){for(var i=e[7],r=0;r<n.length-1;r+=2)if("string"==typeof n[r]){var o=n[r+1],a="function"==typeof o?o(e):ce(e[o]),s=n[r+3];"boolean"==typeof s?a.removeEventListener(n[r],i[n[r+2]],s):s>=0?i[s]():i[-s].unsubscribe(),r+=2}else n[r].call(i[n[r+1]]);e[7]=null}}(t,e);var n=e[6];n&&3===n.type&&ae(e[11])&&e[11].destroy();var i=e[17];if(null!==i&&$t(e[3])){i!==e[3]&&to(i,e);var r=e[19];null!==r&&r.detachView(t)}}}function oo(t,e,n){for(var i=e.parent;null!=i&&(4===i.type||5===i.type);)i=(e=i).parent;if(null==i){var r=n[6];return 2===r.type?Zr(r,n):n[0]}if(e&&5===e.type&&4&e.flags)return ue(e,n).parentNode;if(2&i.flags){var o=t.data,a=o[o[i.index].directiveStart].encapsulation;if(a!==Lt.ShadowDom&&a!==Lt.Native)return null}return ue(i,n)}function ao(t,e,n,i){ae(t)?t.insertBefore(e,n,i):e.insertBefore(n,i,!0)}function so(t,e,n){ae(t)?t.appendChild(e,n):e.appendChild(n)}function co(t,e,n,i){null!==i?ao(t,e,n,i):so(t,e,n)}function lo(t,e){return ae(t)?t.parentNode(e):e.parentNode}function uo(t,e){if(2===t.type){var n=Yr(t,e);return null===n?null:fo(n.indexOf(e,10)-10,n)}return 4===t.type||5===t.type?ue(t,e):null}function ho(t,e,n,i){var r=oo(t,i,e);if(null!=r){var o=e[11],a=uo(i.parent||e[6],e);if(Array.isArray(n))for(var s=0;s<n.length;s++)co(o,r,n[s],a);else co(o,r,n,a)}}function fo(t,e){var n=10+t+1;if(n<e.length){var i=e[n],r=i[1].firstChild;if(null!==r)return function t(e,n){if(null!==n){var i=n.type;if(3===i)return ue(n,e);if(0===i)return fo(-1,e[n.index]);if(4===i||5===i){var r=n.child;if(null!==r)return t(e,r);var o=e[n.index];return $t(o)?fo(-1,o):ce(o)}var a=e[16],s=a[6],c=Ki(a),l=s.projection[n.projection];return null!=l?t(c,l):t(e,n.next)}return null}(i,r)}return e[7]}function po(t,e,n,i,r,o,a){for(;null!=n;){var s=i[n.index],c=n.type;a&&0===e&&(s&&ji(ce(s),i),n.flags|=4),64!=(64&n.flags)&&(4===c||5===c?(po(t,e,n.child,i,r,o,!1),Qr(e,t,r,s,o)):1===c?vo(t,e,i,n,r,o):Qr(e,t,r,s,o)),n=a?n.projectionNext:n.next}}function mo(t,e,n,i,r,o){po(n,i,t.node.child,e,r,o,!1)}function go(t,e,n){vo(e[11],0,e,n,oo(t,n,e),uo(n.parent||e[6],e))}function vo(t,e,n,i,r,o){var a=n[16],s=a[6].projection[i.projection];if(Array.isArray(s))for(var c=0;c<s.length;c++)Qr(e,t,r,s[c],o);else po(t,e,s,a[3],r,o,!0)}function bo(t,e,n){ae(t)?t.setAttribute(e,"style",n):e.style.cssText=n}function yo(t,e,n){ae(t)?""===n?t.removeAttribute(e,"class"):t.setAttribute(e,"class",n):e.className=n}var _o,wo,ko,Co=function(){function t(e,n){Object(m.a)(this,t),this._lView=e,this._cdRefInjectingView=n,this._appRef=null,this._viewContainerRef=null}return Object(g.a)(t,[{key:"destroy",value:function(){if(this._appRef)this._appRef.detachView(this);else if(this._viewContainerRef){var t=this._viewContainerRef.indexOf(this);t>-1&&this._viewContainerRef.detach(t),this._viewContainerRef=null}no(this._lView[1],this._lView)}},{key:"onDestroy",value:function(t){br(this._lView[1],this._lView,null,t)}},{key:"markForCheck",value:function(){Br(this._cdRefInjectingView||this._lView)}},{key:"detach",value:function(){this._lView[2]&=-129}},{key:"reattach",value:function(){this._lView[2]|=128}},{key:"detectChanges",value:function(){Hr(this._lView[1],this._lView,this.context)}},{key:"checkNoChanges",value:function(){!function(t,e,n){Pe(!0);try{Hr(t,e,n)}finally{Pe(!1)}}(this._lView[1],this._lView,this.context)}},{key:"attachToViewContainerRef",value:function(t){if(this._appRef)throw new Error("This view is already attached directly to the ApplicationRef!");this._viewContainerRef=t}},{key:"detachFromAppRef",value:function(){var t;this._appRef=null,mo(this._lView[1],t=this._lView,t[11],2,null,null)}},{key:"attachToAppRef",value:function(t){if(this._viewContainerRef)throw new Error("This view is already attached to a ViewContainer!");this._appRef=t}},{key:"rootNodes",get:function(){var t=this._lView;return null==t[0]?function t(e,n,i,r){for(var o=arguments.length>4&&void 0!==arguments[4]&&arguments[4];null!==i;){var a=n[i.index];if(null!==a&&r.push(ce(a)),$t(a))for(var s=10;s<a.length;s++){var c=a[s],l=c[1].firstChild;null!==l&&t(c[1],c,l,r)}var h=i.type;if(4===h||5===h)t(e,n,i.child,r);else if(1===h){var d=n[16],f=d[6],p=i.projection,m=f.projection[p];if(Array.isArray(m))r.push.apply(r,Object(u.a)(m));else{var g=Ki(d);t(g[1],g,m,r,!0)}}i=o?i.projectionNext:i.next}return r}(t[1],t,t[6].child,[]):[]}},{key:"context",get:function(){return this._lView[8]}},{key:"destroyed",get:function(){return 256==(256&this._lView[2])}}]),t}(),So=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this,t))._view=t,i}return Object(g.a)(n,[{key:"detectChanges",value:function(){zr(this._view)}},{key:"checkNoChanges",value:function(){!function(t){Pe(!0);try{zr(t)}finally{Pe(!1)}}(this._view)}},{key:"context",get:function(){return null}}]),n}(Co);function xo(t,e,n){return _o||(_o=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(t)),new _o(ue(e,n))}function Oo(t,e,n,i){return wo||(wo=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this))._declarationView=t,o._declarationTContainer=i,o.elementRef=r,o}return Object(g.a)(n,[{key:"createEmbeddedView",value:function(t){var e=this._declarationTContainer.tViews,n=sr(this._declarationView,e,t,16,null,e.node);n[17]=this._declarationView[this._declarationTContainer.index];var i=this._declarationView[19];return null!==i&&(n[19]=i.createEmbeddedView(e)),lr(e,n,t),new Co(n)}}]),n}(t)),0===n.type?new wo(i,n,xo(e,n,i)):null}function Mo(t,e,n,i){var r;ko||(ko=function(t){Object(f.a)(i,t);var n=Object(p.a)(i);function i(t,e,r){var o;return Object(m.a)(this,i),(o=n.call(this))._lContainer=t,o._hostTNode=e,o._hostView=r,o}return Object(g.a)(i,[{key:"clear",value:function(){for(;this.length>0;)this.remove(this.length-1)}},{key:"get",value:function(t){return null!==this._lContainer[8]&&this._lContainer[8][t]||null}},{key:"createEmbeddedView",value:function(t,e,n){var i=t.createEmbeddedView(e||{});return this.insert(i,n),i}},{key:"createComponent",value:function(t,e,n,i,r){var o=n||this.parentInjector;if(!r&&null==t.ngModule&&o){var a=o.get(Ot,null);a&&(r=a)}var s=t.create(o,i,void 0,r);return this.insert(s.hostView,e),s}},{key:"insert",value:function(t,e){var n=t._lView,i=n[1];if(t.destroyed)throw new Error("Cannot insert a destroyed View in a ViewContainer!");if(this.allocateContainerIfNeeded(),$t(n[3])){var r=this.indexOf(t);if(-1!==r)this.detach(r);else{var o=n[3],a=new ko(o,o[6],o[3]);a.detach(a.indexOf(t))}}var s=this._adjustIndex(e);return function(t,e,n,i){var r=10+i,o=n.length;i>0&&(n[r-1][4]=e),i<o-10?(e[4]=n[r],Et(n,10+i,e)):(n.push(e),e[4]=null),e[3]=n;var a=e[17];null!==a&&n!==a&&function(t,e){var n=t[9];e[16]!==e[3][3][16]&&(t[2]=!0),null===n?t[9]=[e]:n.push(e)}(a,e);var s=e[19];null!==s&&s.insertView(t),e[2]|=128}(i,n,this._lContainer,s),Jr(i,n,!0,fo(s,this._lContainer)),t.attachToViewContainerRef(this),Et(this._lContainer[8],s,t),t}},{key:"move",value:function(t,e){if(t.destroyed)throw new Error("Cannot move a destroyed View in a ViewContainer!");return this.insert(t,e)}},{key:"indexOf",value:function(t){var e=this._lContainer[8];return null!==e?e.indexOf(t):-1}},{key:"remove",value:function(t){this.allocateContainerIfNeeded();var e=this._adjustIndex(t,-1);!function(t,e){var n=eo(t,e);n&&no(n[1],n)}(this._lContainer,e),Pt(this._lContainer[8],e)}},{key:"detach",value:function(t){this.allocateContainerIfNeeded();var e=this._adjustIndex(t,-1),n=eo(this._lContainer,e);return n&&null!=Pt(this._lContainer[8],e)?new Co(n):null}},{key:"_adjustIndex",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return null==t?this.length+e:t}},{key:"allocateContainerIfNeeded",value:function(){null===this._lContainer[8]&&(this._lContainer[8]=[])}},{key:"element",get:function(){return xo(e,this._hostTNode,this._hostView)}},{key:"injector",get:function(){return new Bn(this._hostTNode,this._hostView)}},{key:"parentInjector",get:function(){var t=En(this._hostTNode,this._hostView),e=mn(t,this._hostView),n=function(t,e,n){if(n.parent&&-1!==n.parent.injectorIndex){for(var i=n.parent.injectorIndex,r=n.parent;null!=r.parent&&i==r.parent.injectorIndex;)r=r.parent;return r}for(var o=pn(t),a=e,s=e[6];o>1;)s=(a=a[15])[6],o--;return s}(t,this._hostView,this._hostTNode);return dn(t)&&null!=n?new Bn(n,e):new Bn(null,this._hostView)}},{key:"length",get:function(){return this._lContainer.length-10}}]),i}(t));var o=i[n.index];if($t(o))r=o;else{var a;if(4===n.type)a=ce(o);else if(a=i[11].createComment(""),ie(i)){var s=i[11],c=ue(n,i);ao(s,lo(s,c),a,function(t,e){return ae(t)?t.nextSibling(e):e.nextSibling}(s,c))}else ho(i[1],i,a,n);i[n.index]=r=Rr(o,i,a,n),Nr(i,r)}return new ko(r,n,i)}function To(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return Eo(xe(),ke(),t)}function Eo(t,e,n){if(!n&&te(t)){var i=fe(t.index,e);return new Co(i,i)}return 3===t.type||0===t.type||4===t.type||5===t.type?new Co(e[16],e):null}var Po=function(){var t=function t(){Object(m.a)(this,t)};return t.__NG_ELEMENT_ID__=function(){return Ao()},t}(),Ao=To,jo=Function,Io=new ht("Set Injector scope."),Do={},Ro={},Lo=[],Fo=void 0;function No(){return void 0===Fo&&(Fo=new St),Fo}function Bo(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,i=arguments.length>3?arguments[3]:void 0;return new Ho(t,n,e||No(),i)}var Ho=function(){function t(e,n,i){var r=this,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;Object(m.a)(this,t),this.parent=i,this.records=new Map,this.injectorDefTypes=new Set,this.onDestroy=new Set,this._destroyed=!1;var a=[];n&&Tt(n,(function(t){return r.processProvider(t,e,n)})),Tt([e],(function(t){return r.processInjectorType(t,[],a)})),this.records.set(dt,Uo(void 0,this));var s=this.records.get(Io);this.scope=null!=s?s.value:null,this.source=o||("object"==typeof e?null:W(e))}return Object(g.a)(t,[{key:"destroy",value:function(){this.assertNotDestroyed(),this._destroyed=!0;try{this.onDestroy.forEach((function(t){return t.ngOnDestroy()}))}finally{this.records.clear(),this.onDestroy.clear(),this.injectorDefTypes.clear()}}},{key:"get",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:ft,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:j.Default;this.assertNotDestroyed();var i=vt(this);try{if(!(n&j.SkipSelf)){var r=this.records.get(t);if(void 0===r){var o=Wo(t)&&N(t);r=o&&this.injectableDefInScope(o)?Uo(zo(t),Do):null,this.records.set(t,r)}if(null!=r)return this.hydrate(t,r)}var a=n&j.Self?No():this.parent;return a.get(t,e=n&j.Optional&&e===ft?null:e)}catch(c){if("NullInjectorError"===c.name){var s=c.ngTempTokenPath=c.ngTempTokenPath||[];if(s.unshift(W(t)),i)throw c;return xt(c,t,"R3InjectorError",this.source)}throw c}finally{vt(i)}}},{key:"_resolveInjectorDefTypes",value:function(){var t=this;this.injectorDefTypes.forEach((function(e){return t.get(e)}))}},{key:"toString",value:function(){var t=[];return this.records.forEach((function(e,n){return t.push(W(n))})),"R3Injector[".concat(t.join(", "),"]")}},{key:"assertNotDestroyed",value:function(){if(this._destroyed)throw new Error("Injector has already been destroyed.")}},{key:"processInjectorType",value:function(t,e,n){var i=this;if(!(t=Z(t)))return!1;var r=H(t),o=null==r&&t.ngModule||void 0,a=void 0===o?t:o,s=-1!==n.indexOf(a);if(void 0!==o&&(r=H(o)),null==r)return!1;if(null!=r.imports&&!s){var c;n.push(a);try{Tt(r.imports,(function(t){i.processInjectorType(t,e,n)&&(void 0===c&&(c=[]),c.push(t))}))}finally{}if(void 0!==c)for(var l=function(t){var e=c[t],n=e.ngModule,r=e.providers;Tt(r,(function(t){return i.processProvider(t,n,r||Lo)}))},u=0;u<c.length;u++)l(u)}this.injectorDefTypes.add(a),this.records.set(a,Uo(r.factory,Do));var h=r.providers;if(null!=h&&!s){var d=t;Tt(h,(function(t){return i.processProvider(t,d,h)}))}return void 0!==o&&void 0!==t.providers}},{key:"processProvider",value:function(t,e,n){var i=Go(t=Z(t))?t:Z(t&&t.provide),r=function(t,e,n){return qo(t)?Uo(void 0,t.useValue):Uo(Vo(t,e,n),Do)}(t,e,n);if(Go(t)||!0!==t.multi){var o=this.records.get(i);o&&void 0!==o.multi&&Di()}else{var a=this.records.get(i);a?void 0===a.multi&&Di():((a=Uo(void 0,Do,!0)).factory=function(){return Ct(a.multi)},this.records.set(i,a)),i=t,a.multi.push(t)}this.records.set(i,r)}},{key:"hydrate",value:function(t,e){var n;return e.value===Ro?function(t){throw new Error("Cannot instantiate cyclic dependency! ".concat(t))}(W(t)):e.value===Do&&(e.value=Ro,e.value=e.factory()),"object"==typeof e.value&&e.value&&null!==(n=e.value)&&"object"==typeof n&&"function"==typeof n.ngOnDestroy&&this.onDestroy.add(e.value),e.value}},{key:"injectableDefInScope",value:function(t){return!!t.providedIn&&("string"==typeof t.providedIn?"any"===t.providedIn||t.providedIn===this.scope:this.injectorDefTypes.has(t.providedIn))}},{key:"destroyed",get:function(){return this._destroyed}}]),t}();function zo(t){var e=N(t),n=null!==e?e.factory:Yt(t);if(null!==n)return n;var i=H(t);if(null!==i)return i.factory;if(t instanceof ht)throw new Error("Token ".concat(W(t)," is missing a \u0275prov definition."));if(t instanceof Function)return function(t){var e=t.length;if(e>0){var n=At(e,"?");throw new Error("Can't resolve all parameters for ".concat(W(t),": (").concat(n.join(", "),")."))}var i=function(t){var e=t&&(t[z]||t[q]||t[U]&&t[U]());if(e){var n=function(t){if(t.hasOwnProperty("name"))return t.name;var e=(""+t).match(/^function\s*([^\s(]+)/);return null===e?"":e[1]}(t);return console.warn('DEPRECATED: DI is instantiating a token "'.concat(n,'" that inherits its @Injectable decorator but does not provide one itself.\n')+'This will become an error in a future version of Angular. Please add @Injectable() to the "'.concat(n,'" class.')),e}return null}(t);return null!==i?function(){return i.factory(t)}:function(){return new t}}(t);throw new Error("unreachable")}function Vo(t,e,n){var i,r=void 0;if(Go(t)){var o=Z(t);return Yt(o)||zo(o)}if(qo(t))r=function(){return Z(t.useValue)};else if((i=t)&&i.useFactory)r=function(){return t.useFactory.apply(t,Object(u.a)(Ct(t.deps||[])))};else if(function(t){return!(!t||!t.useExisting)}(t))r=function(){return _t(Z(t.useExisting))};else{var a=Z(t&&(t.useClass||t.provide));if(a||function(t,e,n){var i="";if(t&&e){var r=e.map((function(t){return t==n?"?"+n+"?":"..."}));i=" - only instances of Provider and Type are allowed, got: [".concat(r.join(", "),"]")}throw new Error("Invalid provider for the NgModule '".concat(W(t),"'")+i)}(e,n,t),!function(t){return!!t.deps}(t))return Yt(a)||zo(a);r=function(){return y(a,Object(u.a)(Ct(t.deps)))}}return r}function Uo(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return{factory:t,value:e,multi:n?[]:void 0}}function qo(t){return null!==t&&"object"==typeof t&&mt in t}function Go(t){return"function"==typeof t}function Wo(t){return"function"==typeof t||"object"==typeof t&&t instanceof ht}var Ko=function(t,e,n){return function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,i=arguments.length>3?arguments[3]:void 0,r=Bo(t,e,n,i);return r._resolveInjectorDefTypes(),r}({name:n},e,t,n)},Xo=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"create",value:function(t,e){return Array.isArray(t)?Ko(t,e,""):Ko(t.providers,t.parent,t.name||"")}}]),t}();return t.THROW_IF_NOT_FOUND=ft,t.NULL=new St,t.\u0275prov=R({token:t,providedIn:"any",factory:function(){return _t(dt)}}),t.__NG_ELEMENT_ID__=-1,t}(),Yo=new ht("AnalyzeForEntryComponents");function Zo(t,e,n){var i=n?t.styles:null,r=n?t.classes:null,o=0;if(null!==e)for(var a=0;a<e.length;a++){var s=e[a];"number"==typeof s?o=s:1==o?r=K(r,s):2==o&&(i=K(i,s+": "+e[++a]+";"))}n?t.styles=i:t.stylesWithoutHost=i,n?t.classes=r:t.classesWithoutHost=r}var Qo=null;function $o(){if(!Qo){var t=it.Symbol;if(t&&t.iterator)Qo=t.iterator;else for(var e=Object.getOwnPropertyNames(Map.prototype),n=0;n<e.length;++n){var i=e[n];"entries"!==i&&"size"!==i&&Map.prototype[i]===Map.prototype.entries&&(Qo=i)}}return Qo}var Jo=function(){function t(e){Object(m.a)(this,t),this.wrapped=e}return Object(g.a)(t,null,[{key:"wrap",value:function(e){return new t(e)}},{key:"unwrap",value:function(e){return t.isWrapped(e)?e.wrapped:e}},{key:"isWrapped",value:function(e){return e instanceof t}}]),t}();function ta(t){return!!ea(t)&&(Array.isArray(t)||!(t instanceof Map)&&$o()in t)}function ea(t){return null!==t&&("function"==typeof t||"object"==typeof t)}function na(t,e,n){return t[e]=n}function ia(t,e,n){return!Object.is(t[e],n)&&(t[e]=n,!0)}function ra(t,e,n,i){var r=ia(t,e,n);return ia(t,e+1,i)||r}function oa(t,e,n,i){var r=ke();return ia(r,Ie(),e)&&(Ce(),jr(Ze(),r,t,e,n,i)),oa}function aa(t,e,n,i){return ia(t,Ie(),n)?e+gn(n)+i:Wi}function sa(t,e,n,i,r,o){var a=ra(t,je(),n,r);return De(2),a?e+gn(n)+i+gn(r)+o:Wi}function ca(t,e,n,i,r,o){var a=ke(),s=aa(a,e,n,i);return s!==Wi&&jr(Ze(),a,t,s,r,o),ca}function la(t,e,n,i,r,o,a,s){var c=ke(),l=sa(c,e,n,i,r,o);return l!==Wi&&jr(Ze(),c,t,l,a,s),la}function ua(t,e,n,i,r,o,a,s){var c=ke(),l=Ce(),u=t+20,h=l.firstCreatePass?function(t,e,n,i,r,o,a,s,c){var l=e.consts,u=cr(e,n[6],t,0,a||null,ve(l,s));kr(e,n,u,ve(l,c)),Je(e,u);var h=u.tViews=vr(2,-1,i,r,o,e.directiveRegistry,e.pipeRegistry,null,e.schemas,l),d=yr(0,null,2,-1,null,null);return d.injectorIndex=u.injectorIndex,h.node=d,null!==e.queries&&(e.queries.template(e,u),h.queries=e.queries.embeddedTView(u)),u}(t,l,c,e,n,i,r,o,a):l.data[u];Oe(h,!1);var d=c[11].createComment("");ho(l,c,d,h),ji(d,c),Nr(c,c[u]=Rr(d,c,d,h)),ee(h)&&pr(l,c,h),null!=a&&mr(c,h,s)}function ha(t){return de(_e.lFrame.contextLView,t)}function da(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.Default,n=ke();if(null==n)return _t(t,e);var i=xe();return An(i,n,Z(t),e)}function fa(t){return function(t,e){if("class"===e)return t.classes;if("style"===e)return t.styles;var n=t.attrs;if(n)for(var i=n.length,r=0;r<i;){var o=n[r];if(cn(o))break;if(0===o)r+=2;else if("number"==typeof o)for(r++;r<i&&"string"==typeof n[r];)r++;else{if(o===e)return n[r+1];r+=2}}return null}(xe(),t)}function pa(t,e,n){var i=ke();return ia(i,Ie(),e)&&wr(Ce(),Ze(),i,t,e,i[11],n,!1),pa}function ma(t,e,n,i,r){var o=r?"class":"style";Kr(t,n,e.inputs[o],o,i)}function ga(t,e,n,i){var r=ke(),o=Ce(),a=20+t,s=r[11],c=r[a]=ar(e,s,_e.lFrame.currentNamespace),l=o.firstCreatePass?function(t,e,n,i,r,o,a){var s=e.consts,c=ve(s,o),l=cr(e,n[6],t,3,r,c);return kr(e,n,l,ve(s,a)),null!==l.attrs&&Zo(l,l.attrs,!1),null!==l.mergedAttrs&&Zo(l,l.mergedAttrs,!0),null!==e.queries&&e.queries.elementStart(e,l),l}(t,o,r,0,e,n,i):o.data[a];Oe(l,!0);var u=l.mergedAttrs;null!==u&&sn(s,c,u);var h=l.classes;null!==h&&yo(s,c,h);var d=l.styles;null!==d&&bo(s,c,d),ho(o,r,c,l),0===_e.lFrame.elementDepthCount&&ji(c,r),_e.lFrame.elementDepthCount++,ee(l)&&(pr(o,r,l),fr(o,l,r)),null!==i&&mr(r,l)}function va(){var t=xe();Me()?Te():Oe(t=t.parent,!1);var e=t;_e.lFrame.elementDepthCount--;var n=Ce();n.firstCreatePass&&(Je(n,t),Jt(t)&&n.queries.elementEnd(t)),null!=e.classesWithoutHost&&function(t){return 0!=(16&t.flags)}(e)&&ma(n,e,ke(),e.classesWithoutHost,!0),null!=e.stylesWithoutHost&&function(t){return 0!=(32&t.flags)}(e)&&ma(n,e,ke(),e.stylesWithoutHost,!1)}function ba(t,e,n,i){ga(t,e,n,i),va()}function ya(t,e,n){var i=ke(),r=Ce(),o=t+20,a=r.firstCreatePass?function(t,e,n,i,r){var o=e.consts,a=ve(o,i),s=cr(e,n[6],t,4,"ng-container",a);return null!==a&&Zo(s,a,!0),kr(e,n,s,ve(o,r)),null!==e.queries&&e.queries.elementStart(e,s),s}(t,r,i,e,n):r.data[o];Oe(a,!0);var s=i[o]=i[11].createComment("");ho(r,i,s,a),ji(s,i),ee(a)&&(pr(r,i,a),fr(r,a,i)),null!=n&&mr(i,a)}function _a(){var t=xe(),e=Ce();Me()?Te():Oe(t=t.parent,!1),e.firstCreatePass&&(Je(e,t),Jt(t)&&e.queries.elementEnd(t))}function wa(t,e,n){ya(t,e,n),_a()}function ka(){return ke()}function Ca(t){return!!t&&"function"==typeof t.then}function Sa(t){return!!t&&"function"==typeof t.subscribe}function xa(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=arguments.length>3?arguments[3]:void 0,r=ke(),o=Ce(),a=xe();return Ta(o,r,r[11],a,t,e,n,i),xa}function Oa(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=arguments.length>3?arguments[3]:void 0,r=xe(),o=ke(),a=Ce(),s=Fe(a.data),c=Gr(s,r,o);return Ta(a,o,c,r,t,e,n,i),Oa}function Ma(t,e,n,i){var r=t.cleanup;if(null!=r)for(var o=0;o<r.length-1;o+=2){var a=r[o];if(a===n&&r[o+1]===i){var s=e[7],c=r[o+2];return s.length>c?s[c]:null}"string"==typeof a&&(o+=2)}return null}function Ta(t,e,n,i,r,o){var a=arguments.length>6&&void 0!==arguments[6]&&arguments[6],s=arguments.length>7?arguments[7]:void 0,c=ee(i),l=t.firstCreatePass,u=l&&(t.cleanup||(t.cleanup=[])),h=qr(e),d=!0;if(3===i.type){var f=ue(i,e),p=s?s(f):Ft,m=p.target||f,g=h.length,v=s?function(t){return s(ce(t[i.index])).target}:i.index;if(ae(n)){var b=null;if(!s&&c&&(b=Ma(t,e,r,i.index)),null!==b){var y=b.__ngLastListenerFn__||b;y.__ngNextListenerFn__=o,b.__ngLastListenerFn__=o,d=!1}else{o=Pa(i,e,o,!1);var _=n.listen(p.name||m,r,o);h.push(o,_),u&&u.push(r,v,g,g+1)}}else o=Pa(i,e,o,!0),m.addEventListener(r,o,a),h.push(o),u&&u.push(r,v,g,a)}var w,k=i.outputs;if(d&&null!==k&&(w=k[r])){var C=w.length;if(C)for(var S=0;S<C;S+=2){var x=w[S],O=w[S+1],M=e[x],T=M[O],E=T.subscribe(o),P=h.length;h.push(o,E),u&&u.push(r,i.index,P,-(P+1))}}}function Ea(t,e,n){try{return!1!==e(n)}catch(i){return Wr(t,i),!1}}function Pa(t,e,n,i){return function r(o){if(o===Function)return n;var a=2&t.flags?fe(t.index,e):e;0==(32&e[2])&&Br(a);for(var s=Ea(e,n,o),c=r.__ngNextListenerFn__;c;)s=Ea(e,c,o)&&s,c=c.__ngNextListenerFn__;return i&&!1===s&&(o.preventDefault(),o.returnValue=!1),s}}function Aa(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;return Ke(t)}function ja(t,e){for(var n=null,i=function(t){var e=t.attrs;if(null!=e){var n=e.indexOf(5);if(0==(1&n))return e[n+1]}return null}(t),r=0;r<e.length;r++){var o=e[r];if("*"!==o){if(null===i?Vi(t,o,!0):Ui(i,o))return r}else n=r}return n}function Ia(t){var e=ke()[16][6];if(!e.projection)for(var n=e.projection=At(t?t.length:1,null),i=n.slice(),r=e.child;null!==r;){var o=t?ja(r,t):0;null!==o&&(i[o]?i[o].projectionNext=r:n[o]=r,i[o]=r),r=r.next}}function Da(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2?arguments[2]:void 0,i=ke(),r=Ce(),o=cr(r,i[6],t,1,null,n||null);null===o.projection&&(o.projection=e),Te(),go(r,i,o)}function Ra(t,e,n){return La(t,"",e,"",n),Ra}function La(t,e,n,i,r){var o=ke(),a=aa(o,e,n,i);return a!==Wi&&wr(Ce(),Ze(),o,t,a,o[11],r,!1),La}function Fa(t,e,n,i,r,o,a){var s=ke(),c=sa(s,e,n,i,r,o);return c!==Wi&&wr(Ce(),Ze(),s,t,c,s[11],a,!1),Fa}var Na=[];function Ba(t,e,n,i,r){for(var o=t[n+1],a=null===e,s=i?tr(o):nr(o),c=!1;0!==s&&(!1===c||a);){var l=t[s+1];Ha(t[s],e)&&(c=!0,t[s+1]=i?rr(l):er(l)),s=i?tr(l):nr(l)}c&&(t[n+1]=i?er(o):rr(o))}function Ha(t,e){return null===t||null==e||(Array.isArray(t)?t[1]:t)===e||!(!Array.isArray(t)||"string"!=typeof e)&&Dt(t,e)>=0}var za={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function Va(t){return t.substring(za.key,za.keyEnd)}function Ua(t){return t.substring(za.value,za.valueEnd)}function qa(t,e){var n=za.textEnd;return n===e?-1:(e=za.keyEnd=function(t,e,n){for(;e<n&&t.charCodeAt(e)>32;)e++;return e}(t,za.key=e,n),Ka(t,e,n))}function Ga(t,e){var n=za.textEnd,i=za.key=Ka(t,e,n);return n===i?-1:(i=za.keyEnd=function(t,e,n){for(var i;e<n&&(45===(i=t.charCodeAt(e))||95===i||(-33&i)>=65&&(-33&i)<=90);)e++;return e}(t,i,n),i=Xa(t,i,n),i=za.value=Ka(t,i,n),i=za.valueEnd=function(t,e,n){for(var i=-1,r=-1,o=-1,a=e,s=a;a<n;){var c=t.charCodeAt(a++);if(59===c)return s;34===c||39===c?s=a=Ya(t,c,a,n):e===a-4&&85===o&&82===r&&76===i&&40===c?s=a=Ya(t,41,a,n):c>32&&(s=a),o=r,r=i,i=-33&c}return s}(t,i,n),Xa(t,i,n))}function Wa(t){za.key=0,za.keyEnd=0,za.value=0,za.valueEnd=0,za.textEnd=t.length}function Ka(t,e,n){for(;e<n&&t.charCodeAt(e)<=32;)e++;return e}function Xa(t,e,n,i){return(e=Ka(t,e,n))<n&&e++,e}function Ya(t,e,n,i){for(var r=-1,o=n;o<i;){var a=t.charCodeAt(o++);if(a==e&&92!==r)return o;r=92==a&&92===r?0:a}throw new Error}function Za(t,e,n){return es(t,e,n,!1),Za}function Qa(t,e){return es(t,e,null,!0),Qa}function $a(t){ns(ss,Ja,t,!1)}function Ja(t,e){for(var n=function(t){return Wa(t),Ga(t,Ka(t,0,za.textEnd))}(e);n>=0;n=Ga(e,n))ss(t,Va(e),Ua(e))}function ts(t,e){for(var n=function(t){return Wa(t),qa(t,Ka(t,0,za.textEnd))}(e);n>=0;n=qa(e,n))jt(t,Va(e),!0)}function es(t,e,n,i){var r=ke(),o=Ce(),a=De(2);o.firstUpdatePass&&rs(o,t,a,i),e!==Wi&&ia(r,a,e)&&cs(o,o.data[Xe()+20],r,r[11],t,r[a+1]=function(t,e){return null==t||("string"==typeof e?t+=e:"object"==typeof t&&(t=W($n(t)))),t}(e,n),i,a)}function ns(t,e,n,i){var r=Ce(),o=De(2);r.firstUpdatePass&&rs(r,null,o,i);var a=ke();if(n!==Wi&&ia(a,o,n)){var s=r.data[Xe()+20];if(hs(s,i)&&!is(r,o)){var c=i?s.classesWithoutHost:s.stylesWithoutHost;null!==c&&(n=K(c,n||"")),ma(r,s,a,n,i)}else!function(t,e,n,i,r,o,a,s){r===Wi&&(r=Na);for(var c=0,l=0,u=0<r.length?r[0]:null,h=0<o.length?o[0]:null;null!==u||null!==h;){var d=c<r.length?r[c+1]:void 0,f=l<o.length?o[l+1]:void 0,p=null,m=void 0;u===h?(c+=2,l+=2,d!==f&&(p=h,m=f)):null===h||null!==u&&u<h?(c+=2,p=u):(l+=2,p=h,m=f),null!==p&&cs(t,e,n,i,p,m,a,s),u=c<r.length?r[c]:null,h=l<o.length?o[l]:null}}(r,s,a,a[11],a[o+1],a[o+1]=function(t,e,n){if(null==n||""===n)return Na;var i=[],r=$n(n);if(Array.isArray(r))for(var o=0;o<r.length;o++)t(i,r[o],!0);else if("object"==typeof r)for(var a in r)r.hasOwnProperty(a)&&t(i,a,r[a]);else"string"==typeof r&&e(i,r);return i}(t,e,n),i,o)}}function is(t,e){return e>=t.expandoStartIndex}function rs(t,e,n,i){var r=t.data;if(null===r[n+1]){var o=r[Xe()+20],a=is(t,n);hs(o,i)&&null===e&&!a&&(e=!1),e=function(t,e,n,i){var r=Fe(t),o=i?e.residualClasses:e.residualStyles;if(null===r)0===(i?e.classBindings:e.styleBindings)&&(n=as(n=os(null,t,e,n,i),e.attrs,i),o=null);else{var a=e.directiveStylingLast;if(-1===a||t[a]!==r)if(n=os(r,t,e,n,i),null===o){var s=function(t,e,n){var i=n?e.classBindings:e.styleBindings;if(0!==nr(i))return t[tr(i)]}(t,e,i);void 0!==s&&Array.isArray(s)&&function(t,e,n,i){t[tr(n?e.classBindings:e.styleBindings)]=i}(t,e,i,s=as(s=os(null,t,e,s[1],i),e.attrs,i))}else o=function(t,e,n){for(var i=void 0,r=e.directiveEnd,o=1+e.directiveStylingLast;o<r;o++)i=as(i,t[o].hostAttrs,n);return as(i,e.attrs,n)}(t,e,i)}return void 0!==o&&(i?e.residualClasses=o:e.residualStyles=o),n}(r,o,e,i),function(t,e,n,i,r,o){var a=o?e.classBindings:e.styleBindings,s=tr(a),c=nr(a);t[i]=n;var l,u=!1;if(Array.isArray(n)?(null===(l=n[1])||Dt(n,l)>0)&&(u=!0):l=n,r)if(0!==c){var h=tr(t[s+1]);t[i+1]=Ji(h,s),0!==h&&(t[h+1]=ir(t[h+1],i)),t[s+1]=131071&t[s+1]|i<<17}else t[i+1]=Ji(s,0),0!==s&&(t[s+1]=ir(t[s+1],i)),s=i;else t[i+1]=Ji(c,0),0===s?s=i:t[c+1]=ir(t[c+1],i),c=i;u&&(t[i+1]=er(t[i+1])),Ba(t,l,i,!0),Ba(t,l,i,!1),function(t,e,n,i,r){var o=r?t.residualClasses:t.residualStyles;null!=o&&"string"==typeof e&&Dt(o,e)>=0&&(n[i+1]=rr(n[i+1]))}(e,l,t,i,o),a=Ji(s,c),o?e.classBindings=a:e.styleBindings=a}(r,o,e,n,a,i)}}function os(t,e,n,i,r){var o=null,a=n.directiveEnd,s=n.directiveStylingLast;for(-1===s?s=n.directiveStart:s++;s<a&&(i=as(i,(o=e[s]).hostAttrs,r),o!==t);)s++;return null!==t&&(n.directiveStylingLast=s),i}function as(t,e,n){var i=n?1:2,r=-1;if(null!==e)for(var o=0;o<e.length;o++){var a=e[o];"number"==typeof a?r=a:r===i&&(Array.isArray(t)||(t=void 0===t?[]:["",t]),jt(t,a,!!n||e[++o]))}return void 0===t?null:t}function ss(t,e,n){jt(t,e,$n(n))}function cs(t,e,n,i,r,o,a,s){if(3===e.type){var c=t.data,l=c[s+1];us(1==(1&l)?ls(c,e,n,r,nr(l),a):void 0)||(us(o)||function(t){return 2==(2&t)}(l)&&(o=ls(c,null,n,r,s,a)),function(t,e,n,i,r){var o=ae(t);if(e)r?o?t.addClass(n,i):n.classList.add(i):o?t.removeClass(n,i):n.classList.remove(i);else{var a=-1==i.indexOf("-")?void 0:2;null==r?o?t.removeStyle(n,i,a):n.style.removeProperty(i):o?t.setStyle(n,i,r,a):n.style.setProperty(i,r)}}(i,a,le(Xe(),n),r,o))}}function ls(t,e,n,i,r,o){for(var a=null===e,s=void 0;r>0;){var c=t[r],l=Array.isArray(c),u=l?c[1]:c,h=null===u,d=n[r+1];d===Wi&&(d=h?Na:void 0);var f=h?It(d,i):u===i?d:void 0;if(l&&!us(f)&&(f=It(c,i)),us(f)&&(s=f,a))return s;var p=t[r+1];r=a?tr(p):nr(p)}if(null!==e){var m=o?e.residualClasses:e.residualStyles;null!=m&&(s=It(m,i))}return s}function us(t){return void 0!==t}function hs(t,e){return 0!=(t.flags&(e?16:32))}function ds(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=ke(),i=Ce(),r=t+20,o=i.firstCreatePass?cr(i,n[6],t,3,null,null):i.data[r],a=n[r]=$r(e,n[11]);ho(i,n,a,o),Oe(o,!1)}function fs(t){return ps("",t,""),fs}function ps(t,e,n){var i=ke(),r=aa(i,t,e,n);return r!==Wi&&Xr(i,Xe(),r),ps}function ms(t,e,n,i,r){var o=ke(),a=sa(o,t,e,n,i,r);return a!==Wi&&Xr(o,Xe(),a),ms}function gs(t,e,n,i,r,o,a){var s=ke(),c=function(t,e,n,i,r,o,a,s){var c=function(t,e,n,i,r){var o=ra(t,e,n,i);return ia(t,e+2,r)||o}(t,je(),n,r,a);return De(3),c?e+gn(n)+i+gn(r)+o+gn(a)+s:Wi}(s,t,e,n,i,r,o,a);return c!==Wi&&Xr(s,Xe(),c),gs}function vs(t,e,n){ns(jt,ts,aa(ke(),t,e,n),!0)}function bs(t,e,n){var i=ke();return ia(i,Ie(),e)&&wr(Ce(),Ze(),i,t,e,i[11],n,!0),bs}function ys(t,e,n){var i=ke();if(ia(i,Ie(),e)){var r=Ce(),o=Ze();wr(r,o,i,t,e,Gr(Fe(r.data),o,i),n,!0)}return ys}function _s(t,e){var n=pe(t)[1],i=n.data.length-1;Je(n,{directiveStart:i,directiveEnd:i+1})}function ws(t){for(var e=Object.getPrototypeOf(t.type.prototype).constructor,n=!0,i=[t];e;){var r=void 0;if(ne(t))r=e.\u0275cmp||e.\u0275dir;else{if(e.\u0275cmp)throw new Error("Directives cannot inherit Components");r=e.\u0275dir}if(r){if(n){i.push(r);var o=t;o.inputs=ks(t.inputs),o.declaredInputs=ks(t.declaredInputs),o.outputs=ks(t.outputs);var a=r.hostBindings;a&&xs(t,a);var s=r.viewQuery,c=r.contentQueries;if(s&&Cs(t,s),c&&Ss(t,c),D(t.inputs,r.inputs),D(t.declaredInputs,r.declaredInputs),D(t.outputs,r.outputs),ne(r)&&r.data.animation){var l=t.data;l.animation=(l.animation||[]).concat(r.data.animation)}o.afterContentChecked=o.afterContentChecked||r.afterContentChecked,o.afterContentInit=t.afterContentInit||r.afterContentInit,o.afterViewChecked=t.afterViewChecked||r.afterViewChecked,o.afterViewInit=t.afterViewInit||r.afterViewInit,o.doCheck=t.doCheck||r.doCheck,o.onDestroy=t.onDestroy||r.onDestroy,o.onInit=t.onInit||r.onInit}var u=r.features;if(u)for(var h=0;h<u.length;h++){var d=u[h];d&&d.ngInherit&&d(t),d===ws&&(n=!1)}}e=Object.getPrototypeOf(e)}!function(t){for(var e=0,n=null,i=t.length-1;i>=0;i--){var r=t[i];r.hostVars=e+=r.hostVars,r.hostAttrs=un(r.hostAttrs,n=un(n,r.hostAttrs))}}(i)}function ks(t){return t===Ft?{}:t===Nt?[]:t}function Cs(t,e){var n=t.viewQuery;t.viewQuery=n?function(t,i){e(t,i),n(t,i)}:e}function Ss(t,e){var n=t.contentQueries;t.contentQueries=n?function(t,i,r){e(t,i,r),n(t,i,r)}:e}function xs(t,e){var n=t.hostBindings;t.hostBindings=n?function(t,i){e(t,i),n(t,i)}:e}var Os=function(){function t(e,n,i){Object(m.a)(this,t),this.previousValue=e,this.currentValue=n,this.firstChange=i}return Object(g.a)(t,[{key:"isFirstChange",value:function(){return this.firstChange}}]),t}();function Ms(t){t.type.prototype.ngOnChanges&&(t.setInput=Ts,t.onChanges=function(){var t=Es(this),e=t&&t.current;if(e){var n=t.previous;if(n===Ft)t.previous=e;else for(var i in e)n[i]=e[i];t.current=null,this.ngOnChanges(e)}})}function Ts(t,e,n,i){var r=Es(t)||function(t,e){return t.__ngSimpleChanges__=e}(t,{previous:Ft,current:null}),o=r.current||(r.current={}),a=r.previous,s=this.declaredInputs[n],c=a[s];o[s]=new Os(c&&c.currentValue,e,a===Ft),t[i]=e}function Es(t){return t.__ngSimpleChanges__||null}function Ps(t,e,n){var i=Ce();if(i.firstCreatePass){var r=ne(t);As(n,i.data,i.blueprint,r,!0),As(e,i.data,i.blueprint,r,!1)}}function As(t,e,n,i,r){if(t=Z(t),Array.isArray(t))for(var o=0;o<t.length;o++)As(t[o],e,n,i,r);else{var a=Ce(),s=ke(),c=Go(t)?t:Z(t.provide),l=Vo(t),u=xe(),h=65535&u.providerIndexes,d=u.directiveStart,f=u.providerIndexes>>16;if(Go(t)||!t.multi){var p=new an(l,r,da),m=Ds(c,e,r?h:h+f,d);-1===m?(Pn(On(u,s),a,c),js(a,t,e.length),e.push(c),u.directiveStart++,u.directiveEnd++,r&&(u.providerIndexes+=65536),n.push(p),s.push(p)):(n[m]=p,s[m]=p)}else{var g=Ds(c,e,h+f,d),v=Ds(c,e,h,h+f),b=v>=0&&n[v];if(r&&!b||!r&&!(g>=0&&n[g])){Pn(On(u,s),a,c);var y=function(t,e,n,i,r){var o=new an(t,n,da);return o.multi=[],o.index=e,o.componentProviders=0,Is(o,r,i&&!n),o}(r?Ls:Rs,n.length,r,i,l);!r&&b&&(n[v].providerFactory=y),js(a,t,e.length,0),e.push(c),u.directiveStart++,u.directiveEnd++,r&&(u.providerIndexes+=65536),n.push(y),s.push(y)}else js(a,t,g>-1?g:v,Is(n[r?v:g],l,!r&&i));!r&&i&&b&&n[v].componentProviders++}}}function js(t,e,n,i){var r=Go(e);if(r||e.useClass){var o=(e.useClass||e).prototype.ngOnDestroy;if(o){var a=t.destroyHooks||(t.destroyHooks=[]);if(!r&&e.multi){var s=a.indexOf(n);-1===s?a.push(n,[i,o]):a[s+1].push(i,o)}else a.push(n,o)}}}function Is(t,e,n){return n&&t.componentProviders++,t.multi.push(e)-1}function Ds(t,e,n,i){for(var r=n;r<i;r++)if(e[r]===t)return r;return-1}function Rs(t,e,n,i){return Fs(this.multi,[])}function Ls(t,e,n,i){var r,o=this.multi;if(this.providerFactory){var a=this.providerFactory.componentProviders,s=Rn(n,n[1],this.providerFactory.index,i);Fs(o,r=s.slice(0,a));for(var c=a;c<s.length;c++)r.push(s[c])}else Fs(o,r=[]);return r}function Fs(t,e){for(var n=0;n<t.length;n++)e.push((0,t[n])());return e}function Ns(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return function(n){n.providersResolver=function(n,i){return Ps(n,i?i(t):t,e)}}}Ms.ngInherit=!0;var Bs=function t(){Object(m.a)(this,t)},Hs=function t(){Object(m.a)(this,t)},zs=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"resolveComponentFactory",value:function(t){throw function(t){var e=Error("No component factory found for ".concat(W(t),". Did you add it to @NgModule.entryComponents?"));return e.ngComponent=t,e}(t)}}]),t}(),Vs=function(){var t=function t(){Object(m.a)(this,t)};return t.NULL=new zs,t}(),Us=function(){var t=function t(e){Object(m.a)(this,t),this.nativeElement=e};return t.__NG_ELEMENT_ID__=function(){return qs(t)},t}(),qs=function(t){return xo(t,xe(),ke())},Gs=function t(){Object(m.a)(this,t)},Ws=function(t){return t[t.Important=1]="Important",t[t.DashCase=2]="DashCase",t}({}),Ks=function(){var t=function t(){Object(m.a)(this,t)};return t.__NG_ELEMENT_ID__=function(){return Xs()},t}(),Xs=function(){var t=ke(),e=fe(xe().index,t);return function(t){var e=t[11];if(ae(e))return e;throw new Error("Cannot inject Renderer2 when the application uses Renderer3!")}(Qt(e)?e:t)},Ys=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275prov=R({token:t,providedIn:"root",factory:function(){return null}}),t}(),Zs=function t(e){Object(m.a)(this,t),this.full=e,this.major=e.split(".")[0],this.minor=e.split(".")[1],this.patch=e.split(".").slice(2).join(".")},Qs=new Zs("10.0.2"),$s=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"supports",value:function(t){return ta(t)}},{key:"create",value:function(t){return new tc(t)}}]),t}(),Js=function(t,e){return e},tc=function(){function t(e){Object(m.a)(this,t),this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=e||Js}return Object(g.a)(t,[{key:"forEachItem",value:function(t){var e;for(e=this._itHead;null!==e;e=e._next)t(e)}},{key:"forEachOperation",value:function(t){for(var e=this._itHead,n=this._removalsHead,i=0,r=null;e||n;){var o=!n||e&&e.currentIndex<rc(n,i,r)?e:n,a=rc(o,i,r),s=o.currentIndex;if(o===n)i--,n=n._nextRemoved;else if(e=e._next,null==o.previousIndex)i++;else{r||(r=[]);var c=a-i,l=s-i;if(c!=l){for(var u=0;u<c;u++){var h=u<r.length?r[u]:r[u]=0,d=h+u;l<=d&&d<c&&(r[u]=h+1)}r[o.previousIndex]=l-c}}a!==s&&t(o,a,s)}}},{key:"forEachPreviousItem",value:function(t){var e;for(e=this._previousItHead;null!==e;e=e._nextPrevious)t(e)}},{key:"forEachAddedItem",value:function(t){var e;for(e=this._additionsHead;null!==e;e=e._nextAdded)t(e)}},{key:"forEachMovedItem",value:function(t){var e;for(e=this._movesHead;null!==e;e=e._nextMoved)t(e)}},{key:"forEachRemovedItem",value:function(t){var e;for(e=this._removalsHead;null!==e;e=e._nextRemoved)t(e)}},{key:"forEachIdentityChange",value:function(t){var e;for(e=this._identityChangesHead;null!==e;e=e._nextIdentityChange)t(e)}},{key:"diff",value:function(t){if(null==t&&(t=[]),!ta(t))throw new Error("Error trying to diff '".concat(W(t),"'. Only arrays and iterables are allowed"));return this.check(t)?this:null}},{key:"onDestroy",value:function(){}},{key:"check",value:function(t){var e=this;this._reset();var n,i,r,o=this._itHead,a=!1;if(Array.isArray(t)){this.length=t.length;for(var s=0;s<this.length;s++)r=this._trackByFn(s,i=t[s]),null!==o&&Object.is(o.trackById,r)?(a&&(o=this._verifyReinsertion(o,i,r,s)),Object.is(o.item,i)||this._addIdentityChange(o,i)):(o=this._mismatch(o,i,r,s),a=!0),o=o._next}else n=0,function(t,e){if(Array.isArray(t))for(var n=0;n<t.length;n++)e(t[n]);else for(var i,r=t[$o()]();!(i=r.next()).done;)e(i.value)}(t,(function(t){r=e._trackByFn(n,t),null!==o&&Object.is(o.trackById,r)?(a&&(o=e._verifyReinsertion(o,t,r,n)),Object.is(o.item,t)||e._addIdentityChange(o,t)):(o=e._mismatch(o,t,r,n),a=!0),o=o._next,n++})),this.length=n;return this._truncate(o),this.collection=t,this.isDirty}},{key:"_reset",value:function(){if(this.isDirty){var t,e;for(t=this._previousItHead=this._itHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._additionsHead;null!==t;t=t._nextAdded)t.previousIndex=t.currentIndex;for(this._additionsHead=this._additionsTail=null,t=this._movesHead;null!==t;t=e)t.previousIndex=t.currentIndex,e=t._nextMoved;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}},{key:"_mismatch",value:function(t,e,n,i){var r;return null===t?r=this._itTail:(r=t._prev,this._remove(t)),null!==(t=null===this._linkedRecords?null:this._linkedRecords.get(n,i))?(Object.is(t.item,e)||this._addIdentityChange(t,e),this._moveAfter(t,r,i)):null!==(t=null===this._unlinkedRecords?null:this._unlinkedRecords.get(n,null))?(Object.is(t.item,e)||this._addIdentityChange(t,e),this._reinsertAfter(t,r,i)):t=this._addAfter(new ec(e,n),r,i),t}},{key:"_verifyReinsertion",value:function(t,e,n,i){var r=null===this._unlinkedRecords?null:this._unlinkedRecords.get(n,null);return null!==r?t=this._reinsertAfter(r,t._prev,i):t.currentIndex!=i&&(t.currentIndex=i,this._addToMoves(t,i)),t}},{key:"_truncate",value:function(t){for(;null!==t;){var e=t._next;this._addToRemovals(this._unlink(t)),t=e}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}},{key:"_reinsertAfter",value:function(t,e,n){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(t);var i=t._prevRemoved,r=t._nextRemoved;return null===i?this._removalsHead=r:i._nextRemoved=r,null===r?this._removalsTail=i:r._prevRemoved=i,this._insertAfter(t,e,n),this._addToMoves(t,n),t}},{key:"_moveAfter",value:function(t,e,n){return this._unlink(t),this._insertAfter(t,e,n),this._addToMoves(t,n),t}},{key:"_addAfter",value:function(t,e,n){return this._insertAfter(t,e,n),this._additionsTail=null===this._additionsTail?this._additionsHead=t:this._additionsTail._nextAdded=t,t}},{key:"_insertAfter",value:function(t,e,n){var i=null===e?this._itHead:e._next;return t._next=i,t._prev=e,null===i?this._itTail=t:i._prev=t,null===e?this._itHead=t:e._next=t,null===this._linkedRecords&&(this._linkedRecords=new ic),this._linkedRecords.put(t),t.currentIndex=n,t}},{key:"_remove",value:function(t){return this._addToRemovals(this._unlink(t))}},{key:"_unlink",value:function(t){null!==this._linkedRecords&&this._linkedRecords.remove(t);var e=t._prev,n=t._next;return null===e?this._itHead=n:e._next=n,null===n?this._itTail=e:n._prev=e,t}},{key:"_addToMoves",value:function(t,e){return t.previousIndex===e||(this._movesTail=null===this._movesTail?this._movesHead=t:this._movesTail._nextMoved=t),t}},{key:"_addToRemovals",value:function(t){return null===this._unlinkedRecords&&(this._unlinkedRecords=new ic),this._unlinkedRecords.put(t),t.currentIndex=null,t._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=t,t._prevRemoved=null):(t._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=t),t}},{key:"_addIdentityChange",value:function(t,e){return t.item=e,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=t:this._identityChangesTail._nextIdentityChange=t,t}},{key:"isDirty",get:function(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}}]),t}(),ec=function t(e,n){Object(m.a)(this,t),this.item=e,this.trackById=n,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null},nc=function(){function t(){Object(m.a)(this,t),this._head=null,this._tail=null}return Object(g.a)(t,[{key:"add",value:function(t){null===this._head?(this._head=this._tail=t,t._nextDup=null,t._prevDup=null):(this._tail._nextDup=t,t._prevDup=this._tail,t._nextDup=null,this._tail=t)}},{key:"get",value:function(t,e){var n;for(n=this._head;null!==n;n=n._nextDup)if((null===e||e<=n.currentIndex)&&Object.is(n.trackById,t))return n;return null}},{key:"remove",value:function(t){var e=t._prevDup,n=t._nextDup;return null===e?this._head=n:e._nextDup=n,null===n?this._tail=e:n._prevDup=e,null===this._head}}]),t}(),ic=function(){function t(){Object(m.a)(this,t),this.map=new Map}return Object(g.a)(t,[{key:"put",value:function(t){var e=t.trackById,n=this.map.get(e);n||(n=new nc,this.map.set(e,n)),n.add(t)}},{key:"get",value:function(t,e){var n=this.map.get(t);return n?n.get(t,e):null}},{key:"remove",value:function(t){var e=t.trackById;return this.map.get(e).remove(t)&&this.map.delete(e),t}},{key:"clear",value:function(){this.map.clear()}},{key:"isEmpty",get:function(){return 0===this.map.size}}]),t}();function rc(t,e,n){var i=t.previousIndex;if(null===i)return i;var r=0;return n&&i<n.length&&(r=n[i]),i+e+r}var oc=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"supports",value:function(t){return t instanceof Map||ea(t)}},{key:"create",value:function(){return new ac}}]),t}(),ac=function(){function t(){Object(m.a)(this,t),this._records=new Map,this._mapHead=null,this._appendAfter=null,this._previousMapHead=null,this._changesHead=null,this._changesTail=null,this._additionsHead=null,this._additionsTail=null,this._removalsHead=null,this._removalsTail=null}return Object(g.a)(t,[{key:"forEachItem",value:function(t){var e;for(e=this._mapHead;null!==e;e=e._next)t(e)}},{key:"forEachPreviousItem",value:function(t){var e;for(e=this._previousMapHead;null!==e;e=e._nextPrevious)t(e)}},{key:"forEachChangedItem",value:function(t){var e;for(e=this._changesHead;null!==e;e=e._nextChanged)t(e)}},{key:"forEachAddedItem",value:function(t){var e;for(e=this._additionsHead;null!==e;e=e._nextAdded)t(e)}},{key:"forEachRemovedItem",value:function(t){var e;for(e=this._removalsHead;null!==e;e=e._nextRemoved)t(e)}},{key:"diff",value:function(t){if(t){if(!(t instanceof Map||ea(t)))throw new Error("Error trying to diff '".concat(W(t),"'. Only maps and objects are allowed"))}else t=new Map;return this.check(t)?this:null}},{key:"onDestroy",value:function(){}},{key:"check",value:function(t){var e=this;this._reset();var n=this._mapHead;if(this._appendAfter=null,this._forEach(t,(function(t,i){if(n&&n.key===i)e._maybeAddToChanges(n,t),e._appendAfter=n,n=n._next;else{var r=e._getOrCreateRecordForKey(i,t);n=e._insertBeforeOrAppend(n,r)}})),n){n._prev&&(n._prev._next=null),this._removalsHead=n;for(var i=n;null!==i;i=i._nextRemoved)i===this._mapHead&&(this._mapHead=null),this._records.delete(i.key),i._nextRemoved=i._next,i.previousValue=i.currentValue,i.currentValue=null,i._prev=null,i._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}},{key:"_insertBeforeOrAppend",value:function(t,e){if(t){var n=t._prev;return e._next=t,e._prev=n,t._prev=e,n&&(n._next=e),t===this._mapHead&&(this._mapHead=e),this._appendAfter=t,t}return this._appendAfter?(this._appendAfter._next=e,e._prev=this._appendAfter):this._mapHead=e,this._appendAfter=e,null}},{key:"_getOrCreateRecordForKey",value:function(t,e){if(this._records.has(t)){var n=this._records.get(t);this._maybeAddToChanges(n,e);var i=n._prev,r=n._next;return i&&(i._next=r),r&&(r._prev=i),n._next=null,n._prev=null,n}var o=new sc(t);return this._records.set(t,o),o.currentValue=e,this._addToAdditions(o),o}},{key:"_reset",value:function(){if(this.isDirty){var t;for(this._previousMapHead=this._mapHead,t=this._previousMapHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._changesHead;null!==t;t=t._nextChanged)t.previousValue=t.currentValue;for(t=this._additionsHead;null!=t;t=t._nextAdded)t.previousValue=t.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}},{key:"_maybeAddToChanges",value:function(t,e){Object.is(e,t.currentValue)||(t.previousValue=t.currentValue,t.currentValue=e,this._addToChanges(t))}},{key:"_addToAdditions",value:function(t){null===this._additionsHead?this._additionsHead=this._additionsTail=t:(this._additionsTail._nextAdded=t,this._additionsTail=t)}},{key:"_addToChanges",value:function(t){null===this._changesHead?this._changesHead=this._changesTail=t:(this._changesTail._nextChanged=t,this._changesTail=t)}},{key:"_forEach",value:function(t,e){t instanceof Map?t.forEach(e):Object.keys(t).forEach((function(n){return e(t[n],n)}))}},{key:"isDirty",get:function(){return null!==this._additionsHead||null!==this._changesHead||null!==this._removalsHead}}]),t}(),sc=function t(e){Object(m.a)(this,t),this.key=e,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null},cc=function(){var t=function(){function t(e){Object(m.a)(this,t),this.factories=e}return Object(g.a)(t,[{key:"find",value:function(t){var e,n=this.factories.find((function(e){return e.supports(t)}));if(null!=n)return n;throw new Error("Cannot find a differ supporting object '".concat(t,"' of type '").concat((e=t).name||typeof e,"'"))}}],[{key:"create",value:function(e,n){if(null!=n){var i=n.factories.slice();e=e.concat(i)}return new t(e)}},{key:"extend",value:function(e){return{provide:t,useFactory:function(n){if(!n)throw new Error("Cannot extend IterableDiffers without a parent injector");return t.create(e,n)},deps:[[t,new A,new E]]}}}]),t}();return t.\u0275prov=R({token:t,providedIn:"root",factory:function(){return new t([new $s])}}),t}(),lc=function(){var t=function(){function t(e){Object(m.a)(this,t),this.factories=e}return Object(g.a)(t,[{key:"find",value:function(t){var e=this.factories.find((function(e){return e.supports(t)}));if(e)return e;throw new Error("Cannot find a differ supporting object '".concat(t,"'"))}}],[{key:"create",value:function(e,n){if(n){var i=n.factories.slice();e=e.concat(i)}return new t(e)}},{key:"extend",value:function(e){return{provide:t,useFactory:function(n){if(!n)throw new Error("Cannot extend KeyValueDiffers without a parent injector");return t.create(e,n)},deps:[[t,new A,new E]]}}}]),t}();return t.\u0275prov=R({token:t,providedIn:"root",factory:function(){return new t([new oc])}}),t}(),uc=[new oc],hc=new cc([new $s]),dc=new lc(uc),fc=function(){var t=function t(){Object(m.a)(this,t)};return t.__NG_ELEMENT_ID__=function(){return pc(t,Us)},t}(),pc=function(t,e){return Oo(t,e,xe(),ke())},mc=function(){var t=function t(){Object(m.a)(this,t)};return t.__NG_ELEMENT_ID__=function(){return gc(t,Us)},t}(),gc=function(t,e){return Mo(t,e,xe(),ke())},vc={},bc=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this)).ngModule=t,i}return Object(g.a)(n,[{key:"resolveComponentFactory",value:function(t){var e=Xt(t);return new wc(e,this.ngModule)}}]),n}(Vs);function yc(t){var e=[];for(var n in t)t.hasOwnProperty(n)&&e.push({propName:t[n],templateName:n});return e}var _c=new ht("SCHEDULER_TOKEN",{providedIn:"root",factory:function(){return bn}}),wc=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this)).componentDef=t,r.ngModule=i,r.componentType=t.type,r.selector=t.selectors.map(Gi).join(","),r.ngContentSelectors=t.ngContentSelectors?t.ngContentSelectors:[],r.isBoundToModule=!!i,r}return Object(g.a)(n,[{key:"create",value:function(t,e,n,i){var r,o,a=(i=i||this.ngModule)?function(t,e){return{get:function(n,i,r){var o=t.get(n,vc,r);return o!==vc||i===vc?o:e.get(n,i,r)}}}(t,i.injector):t,s=a.get(Gs,se),c=a.get(Ys,null),l=s.createRenderer(null,this.componentDef),u=this.componentDef.selectors[0][0]||"div",h=n?function(t,e,n){if(ae(t))return t.selectRootElement(e,n===Lt.ShadowDom);var i="string"==typeof e?t.querySelector(e):e;return i.textContent="",i}(l,n,this.componentDef.encapsulation):ar(u,s.createRenderer(null,this.componentDef),function(t){var e=t.toLowerCase();return"svg"===e?"http://www.w3.org/2000/svg":"math"===e?"http://www.w3.org/1998/MathML/":null}(u)),d=this.componentDef.onPush?576:528,f={components:[],scheduler:bn,clean:Ur,playerHandler:null,flags:0},p=vr(0,-1,null,1,0,null,null,null,null,null),m=sr(null,p,f,d,null,null,s,l,c,a);ze(m,null);try{var g=function(t,e,n,i,r,o){var a=n[1];n[20]=t;var s=cr(a,null,0,3,null,null),c=s.mergedAttrs=e.hostAttrs;null!==c&&(Zo(s,c,!0),null!==t&&(sn(r,t,c),null!==s.classes&&yo(r,t,s.classes),null!==s.styles&&bo(r,t,s.styles)));var l=i.createRenderer(t,e),u=sr(n,gr(e),null,e.onPush?64:16,n[20],s,i,l,void 0);return a.firstCreatePass&&(Pn(On(s,n),a,e.type),Mr(a,s),Er(s,n.length,1)),Nr(n,u),n[20]=u}(h,this.componentDef,m,s,l);if(h)if(n)sn(l,h,["ng-version",Qs.full]);else{var v=function(t){for(var e=[],n=[],i=1,r=2;i<t.length;){var o=t[i];if("string"==typeof o)2===r?""!==o&&e.push(o,t[++i]):8===r&&n.push(o);else{if(!Hi(r))break;r=o}i++}return{attrs:e,classes:n}}(this.componentDef.selectors[0]),b=v.attrs,y=v.classes;b&&sn(l,h,b),y&&y.length>0&&yo(l,h,y.join(" "))}if(o=he(p,0),void 0!==e)for(var _=o.projection=[],w=0;w<this.ngContentSelectors.length;w++){var k=e[w];_.push(null!=k?Array.from(k):null)}r=function(t,e,n,i,r){var o=n[1],a=function(t,e,n){var i=xe();t.firstCreatePass&&(n.providersResolver&&n.providersResolver(n),Or(t,i,1),Pr(t,e,n));var r=Rn(e,t,e.length-1,i);ji(r,e);var o=ue(i,e);return o&&ji(o,e),r}(o,n,e);i.components.push(a),t[8]=a,r&&r.forEach((function(t){return t(a,e)})),e.contentQueries&&e.contentQueries(1,a,n.length-1);var s=xe();if(o.firstCreatePass&&(null!==e.hostBindings||null!==e.hostAttrs)){Ye(s.index-20);var c=n[1];Cr(c,e),Sr(c,n,e.hostVars),xr(e,a)}return a}(g,this.componentDef,m,f,[_s]),lr(p,m,null)}finally{We()}var C=new kc(this.componentType,r,xo(Us,o,m),m,o);return p.node.child=o,C}},{key:"inputs",get:function(){return yc(this.componentDef.inputs)}},{key:"outputs",get:function(){return yc(this.componentDef.outputs)}}]),n}(Hs),kc=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){var s,c,l,u;return Object(m.a)(this,n),(s=e.call(this)).location=r,s._rootLView=o,s._tNode=a,s.destroyCbs=[],s.instance=i,s.hostView=s.changeDetectorRef=new So(o),l=o,null==(u=(c=o[1]).node)&&(c.node=u=yr(0,null,2,-1,null,null)),l[6]=u,s.componentType=t,s}return Object(g.a)(n,[{key:"destroy",value:function(){this.destroyCbs&&(this.destroyCbs.forEach((function(t){return t()})),this.destroyCbs=null,!this.hostView.destroyed&&this.hostView.destroy())}},{key:"onDestroy",value:function(t){this.destroyCbs&&this.destroyCbs.push(t)}},{key:"injector",get:function(){return new Bn(this._tNode,this._rootLView)}}]),n}(Bs),Cc=["en",[["a","p"],["AM","PM"],void 0],[["AM","PM"],void 0,void 0],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],void 0,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],void 0,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",void 0,"{1} 'at' {0}",void 0],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",function(t){var e=Math.floor(Math.abs(t)),n=t.toString().replace(/^[^.]*\.?/,"").length;return 1===e&&0===n?1:5}],Sc={};function xc(t){var e=function(t){return t.toLowerCase().replace(/_/g,"-")}(t),n=Oc(e);if(n)return n;var i=e.split("-")[0];if(n=Oc(i))return n;if("en"===i)return Cc;throw new Error('Missing locale data for the locale "'.concat(t,'".'))}function Oc(t){return t in Sc||(Sc[t]=it.ng&&it.ng.common&&it.ng.common.locales&&it.ng.common.locales[t]),Sc[t]}var Mc=function(t){return t[t.LocaleId=0]="LocaleId",t[t.DayPeriodsFormat=1]="DayPeriodsFormat",t[t.DayPeriodsStandalone=2]="DayPeriodsStandalone",t[t.DaysFormat=3]="DaysFormat",t[t.DaysStandalone=4]="DaysStandalone",t[t.MonthsFormat=5]="MonthsFormat",t[t.MonthsStandalone=6]="MonthsStandalone",t[t.Eras=7]="Eras",t[t.FirstDayOfWeek=8]="FirstDayOfWeek",t[t.WeekendRange=9]="WeekendRange",t[t.DateFormat=10]="DateFormat",t[t.TimeFormat=11]="TimeFormat",t[t.DateTimeFormat=12]="DateTimeFormat",t[t.NumberSymbols=13]="NumberSymbols",t[t.NumberFormats=14]="NumberFormats",t[t.CurrencyCode=15]="CurrencyCode",t[t.CurrencySymbol=16]="CurrencySymbol",t[t.CurrencyName=17]="CurrencyName",t[t.Currencies=18]="Currencies",t[t.Directionality=19]="Directionality",t[t.PluralCase=20]="PluralCase",t[t.ExtraData=21]="ExtraData",t}({});function Tc(t){var e,n;n="Expected localeId to be defined",null==(e=t)&&function(t,e,n,i){throw new Error("ASSERTION ERROR: ".concat(t)+" [Expected=> ".concat(null," ").concat("!="," ").concat(e," <=Actual]"))}(n,e),"string"==typeof t&&t.toLowerCase().replace(/_/g,"-")}var Ec=new Map,Pc=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;Object(m.a)(this,n),(r=e.call(this))._parent=i,r._bootstrapComponents=[],r.injector=Object(s.a)(r),r.destroyCbs=[],r.componentFactoryResolver=new bc(Object(s.a)(r));var o=Zt(t),a=t[ct]||null;return a&&Tc(a),r._bootstrapComponents=kn(o.bootstrap),r._r3Injector=Bo(t,i,[{provide:Ot,useValue:Object(s.a)(r)},{provide:Vs,useValue:r.componentFactoryResolver}],W(t)),r._r3Injector._resolveInjectorDefTypes(),r.instance=r.get(t),r}return Object(g.a)(n,[{key:"get",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Xo.THROW_IF_NOT_FOUND,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:j.Default;return t===Xo||t===Ot||t===dt?this:this._r3Injector.get(t,e,n)}},{key:"destroy",value:function(){var t=this._r3Injector;!t.destroyed&&t.destroy(),this.destroyCbs.forEach((function(t){return t()})),this.destroyCbs=null}},{key:"onDestroy",value:function(t){this.destroyCbs.push(t)}}]),n}(Ot),Ac=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this)).moduleType=t,null!==Zt(t)&&function t(e){if(null!==e.\u0275mod.id){var n=e.\u0275mod.id;(function(t,e,n){if(e&&e!==n)throw new Error("Duplicate module registered for ".concat(t," - ").concat(W(e)," vs ").concat(W(e.name)))})(n,Ec.get(n),e),Ec.set(n,e)}var i=e.\u0275mod.imports;i instanceof Function&&(i=i()),i&&i.forEach((function(e){return t(e)}))}(t),i}return Object(g.a)(n,[{key:"create",value:function(t){return new Pc(this.moduleType,t)}}]),n}(Mt);function jc(t,e,n){var i=Ae()+t,r=ke();return r[i]===Wi?na(r,i,n?e.call(n):e()):function(t,e){return t[e]}(r,i)}function Ic(t,e,n,i){return Lc(ke(),Ae(),t,e,n,i)}function Dc(t,e,n,i,r){return Fc(ke(),Ae(),t,e,n,i,r)}function Rc(t,e){var n=t[e];return n===Wi?void 0:n}function Lc(t,e,n,i,r,o){var a=e+n;return ia(t,a,r)?na(t,a+1,o?i.call(o,r):i(r)):Rc(t,a+1)}function Fc(t,e,n,i,r,o,a){var s=e+n;return ra(t,s,r,o)?na(t,s+2,a?i.call(a,r,o):i(r,o)):Rc(t,s+2)}function Nc(t,e){var n,i=Ce(),r=t+20;i.firstCreatePass?(n=function(t,e){if(e)for(var n=e.length-1;n>=0;n--){var i=e[n];if(t===i.name)return i}throw new Error("The pipe '".concat(t,"' could not be found!"))}(e,i.pipeRegistry),i.data[r]=n,n.onDestroy&&(i.destroyHooks||(i.destroyHooks=[])).push(r,n.onDestroy)):n=i.data[r];var o=n.factory||(n.factory=Yt(n.type)),a=bt(da),s=Sn(!1),c=o();return Sn(s),bt(a),function(t,e,n,i){var r=n+20;r>=t.data.length&&(t.data[r]=null,t.blueprint[r]=null),e[r]=i}(i,ke(),t,c),c}function Bc(t,e,n){var i=ke(),r=de(i,t);return Vc(i,zc(i,t)?Lc(i,Ae(),e,r.transform,n,r):r.transform(n))}function Hc(t,e,n,i){var r=ke(),o=de(r,t);return Vc(r,zc(r,t)?Fc(r,Ae(),e,o.transform,n,i,o):o.transform(n,i))}function zc(t,e){return t[1].data[e+20].pure}function Vc(t,e){return Jo.isWrapped(e)&&(e=Jo.unwrap(e),t[je()]=Wi),e}var Uc=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t,i=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return Object(m.a)(this,n),(t=e.call(this)).__isAsync=i,t}return Object(g.a)(n,[{key:"emit",value:function(t){Object(o.a)(Object(a.a)(n.prototype),"next",this).call(this,t)}},{key:"subscribe",value:function(t,e,i){var r,s=function(t){return null},c=function(){return null};t&&"object"==typeof t?(r=this.__isAsync?function(e){setTimeout((function(){return t.next(e)}))}:function(e){t.next(e)},t.error&&(s=this.__isAsync?function(e){setTimeout((function(){return t.error(e)}))}:function(e){t.error(e)}),t.complete&&(c=this.__isAsync?function(){setTimeout((function(){return t.complete()}))}:function(){t.complete()})):(r=this.__isAsync?function(e){setTimeout((function(){return t(e)}))}:function(e){t(e)},e&&(s=this.__isAsync?function(t){setTimeout((function(){return e(t)}))}:function(t){e(t)}),i&&(c=this.__isAsync?function(){setTimeout((function(){return i()}))}:function(){i()}));var l=Object(o.a)(Object(a.a)(n.prototype),"subscribe",this).call(this,r,s,c);return t instanceof _.a&&t.add(l),l}}]),n}(w.b);function qc(){return this._results[$o()]()}var Gc=function(){function t(){Object(m.a)(this,t),this.dirty=!0,this._results=[],this.changes=new Uc,this.length=0;var e=$o(),n=t.prototype;n[e]||(n[e]=qc)}return Object(g.a)(t,[{key:"map",value:function(t){return this._results.map(t)}},{key:"filter",value:function(t){return this._results.filter(t)}},{key:"find",value:function(t){return this._results.find(t)}},{key:"reduce",value:function(t,e){return this._results.reduce(t,e)}},{key:"forEach",value:function(t){this._results.forEach(t)}},{key:"some",value:function(t){return this._results.some(t)}},{key:"toArray",value:function(){return this._results.slice()}},{key:"toString",value:function(){return this._results.toString()}},{key:"reset",value:function(t){this._results=function t(e,n){void 0===n&&(n=e);for(var i=0;i<e.length;i++){var r=e[i];Array.isArray(r)?(n===e&&(n=e.slice(0,i)),t(r,n)):n!==e&&n.push(r)}return n}(t),this.dirty=!1,this.length=this._results.length,this.last=this._results[this.length-1],this.first=this._results[0]}},{key:"notifyOnChanges",value:function(){this.changes.emit(this)}},{key:"setDirty",value:function(){this.dirty=!0}},{key:"destroy",value:function(){this.changes.complete(),this.changes.unsubscribe()}}]),t}(),Wc=function(){function t(e){Object(m.a)(this,t),this.queryList=e,this.matches=null}return Object(g.a)(t,[{key:"clone",value:function(){return new t(this.queryList)}},{key:"setDirty",value:function(){this.queryList.setDirty()}}]),t}(),Kc=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];Object(m.a)(this,t),this.queries=e}return Object(g.a)(t,[{key:"createEmbeddedView",value:function(e){var n=e.queries;if(null!==n){for(var i=null!==e.contentQueries?e.contentQueries[0]:n.length,r=[],o=0;o<i;o++){var a=n.getByIndex(o);r.push(this.queries[a.indexInDeclarationView].clone())}return new t(r)}return null}},{key:"insertView",value:function(t){this.dirtyQueriesWithMatches(t)}},{key:"detachView",value:function(t){this.dirtyQueriesWithMatches(t)}},{key:"dirtyQueriesWithMatches",value:function(t){for(var e=0;e<this.queries.length;e++)null!==ul(t,e).matches&&this.queries[e].setDirty()}}]),t}(),Xc=function t(e,n,i){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;Object(m.a)(this,t),this.predicate=e,this.descendants=n,this.isStatic=i,this.read=r},Yc=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];Object(m.a)(this,t),this.queries=e}return Object(g.a)(t,[{key:"elementStart",value:function(t,e){for(var n=0;n<this.queries.length;n++)this.queries[n].elementStart(t,e)}},{key:"elementEnd",value:function(t){for(var e=0;e<this.queries.length;e++)this.queries[e].elementEnd(t)}},{key:"embeddedTView",value:function(e){for(var n=null,i=0;i<this.length;i++){var r=null!==n?n.length:0,o=this.getByIndex(i).embeddedTView(e,r);o&&(o.indexInDeclarationView=i,null!==n?n.push(o):n=[o])}return null!==n?new t(n):null}},{key:"template",value:function(t,e){for(var n=0;n<this.queries.length;n++)this.queries[n].template(t,e)}},{key:"getByIndex",value:function(t){return this.queries[t]}},{key:"track",value:function(t){this.queries.push(t)}},{key:"length",get:function(){return this.queries.length}}]),t}(),Zc=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1;Object(m.a)(this,t),this.metadata=e,this.matches=null,this.indexInDeclarationView=-1,this.crossesNgTemplate=!1,this._appliesToNextNode=!0,this._declarationNodeIndex=n}return Object(g.a)(t,[{key:"elementStart",value:function(t,e){this.isApplyingToNode(e)&&this.matchTNode(t,e)}},{key:"elementEnd",value:function(t){this._declarationNodeIndex===t.index&&(this._appliesToNextNode=!1)}},{key:"template",value:function(t,e){this.elementStart(t,e)}},{key:"embeddedTView",value:function(e,n){return this.isApplyingToNode(e)?(this.crossesNgTemplate=!0,this.addMatch(-e.index,n),new t(this.metadata)):null}},{key:"isApplyingToNode",value:function(t){if(this._appliesToNextNode&&!1===this.metadata.descendants){for(var e=this._declarationNodeIndex,n=t.parent;null!==n&&4===n.type&&n.index!==e;)n=n.parent;return e===(null!==n?n.index:-1)}return this._appliesToNextNode}},{key:"matchTNode",value:function(t,e){if(Array.isArray(this.metadata.predicate))for(var n=this.metadata.predicate,i=0;i<n.length;i++)this.matchTNodeWithReadOption(t,e,Qc(e,n[i]));else{var r=this.metadata.predicate;r===fc?0===e.type&&this.matchTNodeWithReadOption(t,e,-1):this.matchTNodeWithReadOption(t,e,Dn(e,t,r,!1,!1))}}},{key:"matchTNodeWithReadOption",value:function(t,e,n){if(null!==n){var i=this.metadata.read;if(null!==i)if(i===Us||i===mc||i===fc&&0===e.type)this.addMatch(e.index,-2);else{var r=Dn(e,t,i,!1,!1);null!==r&&this.addMatch(e.index,r)}else this.addMatch(e.index,n)}}},{key:"addMatch",value:function(t,e){null===this.matches?this.matches=[t,e]:this.matches.push(t,e)}}]),t}();function Qc(t,e){var n=t.localNames;if(null!==n)for(var i=0;i<n.length;i+=2)if(n[i]===e)return n[i+1];return null}function $c(t,e,n,i){return-1===n?function(t,e){return 3===t.type||4===t.type?xo(Us,t,e):0===t.type?Oo(fc,Us,t,e):null}(e,t):-2===n?function(t,e,n){return n===Us?xo(Us,e,t):n===fc?Oo(fc,Us,e,t):n===mc?Mo(mc,Us,e,t):void 0}(t,e,i):Rn(t,t[1],n,e)}function Jc(t,e,n,i){var r=e[19].queries[i];if(null===r.matches){for(var o=t.data,a=n.matches,s=[],c=0;c<a.length;c+=2){var l=a[c];s.push(l<0?null:$c(e,o[l],a[c+1],n.metadata.read))}r.matches=s}return r.matches}function tl(t){var e=ke(),n=Ce(),i=Ne();Be(i+1);var r=ul(n,i);if(t.dirty&&me(e)===r.metadata.isStatic){if(null===r.matches)t.reset([]);else{var o=r.crossesNgTemplate?function t(e,n,i,r){var o=e.queries.getByIndex(i),a=o.matches;if(null!==a)for(var s=Jc(e,n,o,i),c=0;c<a.length;c+=2){var l=a[c];if(l>0)r.push(s[c/2]);else{for(var u=a[c+1],h=n[-l],d=10;d<h.length;d++){var f=h[d];f[17]===f[3]&&t(f[1],f,u,r)}if(null!==h[9])for(var p=h[9],m=0;m<p.length;m++){var g=p[m];t(g[1],g,u,r)}}}return r}(n,e,i,[]):Jc(n,e,r,i);t.reset(o),t.notifyOnChanges()}return!0}return!1}function el(t,e,n){il(Ce(),ke(),t,e,n,!0)}function nl(t,e,n){il(Ce(),ke(),t,e,n,!1)}function il(t,e,n,i,r,o){t.firstCreatePass&&(ll(t,new Xc(n,i,o,r),-1),o&&(t.staticViewQueries=!0)),cl(t,e)}function rl(t,e,n,i){al(Ce(),ke(),e,n,i,!1,xe(),t)}function ol(t,e,n,i){al(Ce(),ke(),e,n,i,!0,xe(),t)}function al(t,e,n,i,r,o,a,s){t.firstCreatePass&&(ll(t,new Xc(n,i,o,r),a.index),function(t,e){var n=t.contentQueries||(t.contentQueries=[]);e!==(t.contentQueries.length?n[n.length-1]:-1)&&n.push(t.queries.length-1,e)}(t,s),o&&(t.staticContentQueries=!0)),cl(t,e)}function sl(){return t=ke(),e=Ne(),t[19].queries[e].queryList;var t,e}function cl(t,e){var n=new Gc;br(t,e,n,n.destroy),null===e[19]&&(e[19]=new Kc),e[19].queries.push(new Wc(n))}function ll(t,e,n){null===t.queries&&(t.queries=new Yc),t.queries.track(new Zc(e,n))}function ul(t,e){return t.queries.getByIndex(e)}var hl=new ht("Application Initializer"),dl=function(){var t=function(){function t(e){var n=this;Object(m.a)(this,t),this.appInits=e,this.initialized=!1,this.done=!1,this.donePromise=new Promise((function(t,e){n.resolve=t,n.reject=e}))}return Object(g.a)(t,[{key:"runInitializers",value:function(){var t=this;if(!this.initialized){var e=[],n=function(){t.done=!0,t.resolve()};if(this.appInits)for(var i=0;i<this.appInits.length;i++){var r=this.appInits[i]();Ca(r)&&e.push(r)}Promise.all(e).then((function(){n()})).catch((function(e){t.reject(e)})),0===e.length&&n(),this.initialized=!0}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(hl,8))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),fl=new ht("AppId"),pl={provide:fl,useFactory:function(){return"".concat(ml()).concat(ml()).concat(ml())},deps:[]};function ml(){return String.fromCharCode(97+Math.floor(25*Math.random()))}var gl=new ht("Platform Initializer"),vl=new ht("Platform ID"),bl=new ht("appBootstrapListener"),yl=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"log",value:function(t){console.log(t)}},{key:"warn",value:function(t){console.warn(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),_l=new ht("LocaleId"),wl=new ht("DefaultCurrencyCode"),kl=function t(e,n){Object(m.a)(this,t),this.ngModuleFactory=e,this.componentFactories=n},Cl=function(t){return new Ac(t)},Sl=Cl,xl=function(t){return Promise.resolve(Cl(t))},Ol=function(t){var e=Cl(t),n=kn(Zt(t).declarations).reduce((function(t,e){var n=Xt(e);return n&&t.push(new wc(n)),t}),[]);return new kl(e,n)},Ml=Ol,Tl=function(t){return Promise.resolve(Ol(t))},El=function(){var t=function(){function t(){Object(m.a)(this,t),this.compileModuleSync=Sl,this.compileModuleAsync=xl,this.compileModuleAndAllComponentsSync=Ml,this.compileModuleAndAllComponentsAsync=Tl}return Object(g.a)(t,[{key:"clearCache",value:function(){}},{key:"clearCacheFor",value:function(t){}},{key:"getModuleId",value:function(t){}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Pl=function(){return Promise.resolve(0)}();function Al(t){"undefined"==typeof Zone?Pl.then((function(){t&&t.apply(null,null)})):Zone.current.scheduleMicroTask("scheduleMicrotask",t)}var jl=function(){function t(e){var n,i,r=e.enableLongStackTrace,o=void 0!==r&&r,a=e.shouldCoalesceEventChangeDetection,s=void 0!==a&&a;if(Object(m.a)(this,t),this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Uc(!1),this.onMicrotaskEmpty=new Uc(!1),this.onStable=new Uc(!1),this.onError=new Uc(!1),"undefined"==typeof Zone)throw new Error("In this configuration Angular requires Zone.js");Zone.assertZonePatched(),this._nesting=0,this._outer=this._inner=Zone.current,Zone.wtfZoneSpec&&(this._inner=this._inner.fork(Zone.wtfZoneSpec)),Zone.TaskTrackingZoneSpec&&(this._inner=this._inner.fork(new Zone.TaskTrackingZoneSpec)),o&&Zone.longStackTraceZoneSpec&&(this._inner=this._inner.fork(Zone.longStackTraceZoneSpec)),this.shouldCoalesceEventChangeDetection=s,this.lastRequestAnimationFrameId=-1,this.nativeRequestAnimationFrame=function(){var t=it.requestAnimationFrame,e=it.cancelAnimationFrame;if("undefined"!=typeof Zone&&t&&e){var n=t[Zone.__symbol__("OriginalDelegate")];n&&(t=n);var i=e[Zone.__symbol__("OriginalDelegate")];i&&(e=i)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,i=!!(n=this).shouldCoalesceEventChangeDetection&&n.nativeRequestAnimationFrame&&function(){!function(t){-1===t.lastRequestAnimationFrameId&&(t.lastRequestAnimationFrameId=t.nativeRequestAnimationFrame.call(it,(function(){t.fakeTopEventTask||(t.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",(function(){t.lastRequestAnimationFrameId=-1,Ll(t),Rl(t)}),void 0,(function(){}),(function(){}))),t.fakeTopEventTask.invoke()})),Ll(t))}(n)},n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0,maybeDelayChangeDetection:i},onInvokeTask:function(t,e,r,o,a,s){try{return Fl(n),t.invokeTask(r,o,a,s)}finally{i&&"eventTask"===o.type&&i(),Nl(n)}},onInvoke:function(t,e,i,r,o,a,s){try{return Fl(n),t.invoke(i,r,o,a,s)}finally{Nl(n)}},onHasTask:function(t,e,i,r){t.hasTask(i,r),e===i&&("microTask"==r.change?(n._hasPendingMicrotasks=r.microTask,Ll(n),Rl(n)):"macroTask"==r.change&&(n.hasPendingMacrotasks=r.macroTask))},onHandleError:function(t,e,i,r){return t.handleError(i,r),n.runOutsideAngular((function(){return n.onError.emit(r)})),!1}})}return Object(g.a)(t,[{key:"run",value:function(t,e,n){return this._inner.run(t,e,n)}},{key:"runTask",value:function(t,e,n,i){var r=this._inner,o=r.scheduleEventTask("NgZoneEvent: "+i,t,Dl,Il,Il);try{return r.runTask(o,e,n)}finally{r.cancelTask(o)}}},{key:"runGuarded",value:function(t,e,n){return this._inner.runGuarded(t,e,n)}},{key:"runOutsideAngular",value:function(t){return this._outer.run(t)}}],[{key:"isInAngularZone",value:function(){return!0===Zone.current.get("isAngularZone")}},{key:"assertInAngularZone",value:function(){if(!t.isInAngularZone())throw new Error("Expected to be in Angular Zone, but it is not!")}},{key:"assertNotInAngularZone",value:function(){if(t.isInAngularZone())throw new Error("Expected to not be in Angular Zone, but it is!")}}]),t}();function Il(){}var Dl={};function Rl(t){if(0==t._nesting&&!t.hasPendingMicrotasks&&!t.isStable)try{t._nesting++,t.onMicrotaskEmpty.emit(null)}finally{if(t._nesting--,!t.hasPendingMicrotasks)try{t.runOutsideAngular((function(){return t.onStable.emit(null)}))}finally{t.isStable=!0}}}function Ll(t){t.hasPendingMicrotasks=!!(t._hasPendingMicrotasks||t.shouldCoalesceEventChangeDetection&&-1!==t.lastRequestAnimationFrameId)}function Fl(t){t._nesting++,t.isStable&&(t.isStable=!1,t.onUnstable.emit(null))}function Nl(t){t._nesting--,Rl(t)}var Bl,Hl=function(){function t(){Object(m.a)(this,t),this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new Uc,this.onMicrotaskEmpty=new Uc,this.onStable=new Uc,this.onError=new Uc}return Object(g.a)(t,[{key:"run",value:function(t,e,n){return t.apply(e,n)}},{key:"runGuarded",value:function(t,e,n){return t.apply(e,n)}},{key:"runOutsideAngular",value:function(t){return t()}},{key:"runTask",value:function(t,e,n,i){return t.apply(e,n)}}]),t}(),zl=function(){var t=function(){function t(e){var n=this;Object(m.a)(this,t),this._ngZone=e,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,this._watchAngularEvents(),e.run((function(){n.taskTrackingZone="undefined"==typeof Zone?null:Zone.current.get("TaskTrackingZone")}))}return Object(g.a)(t,[{key:"_watchAngularEvents",value:function(){var t=this;this._ngZone.onUnstable.subscribe({next:function(){t._didWork=!0,t._isZoneStable=!1}}),this._ngZone.runOutsideAngular((function(){t._ngZone.onStable.subscribe({next:function(){jl.assertNotInAngularZone(),Al((function(){t._isZoneStable=!0,t._runCallbacksIfReady()}))}})}))}},{key:"increasePendingRequestCount",value:function(){return this._pendingCount+=1,this._didWork=!0,this._pendingCount}},{key:"decreasePendingRequestCount",value:function(){if(this._pendingCount-=1,this._pendingCount<0)throw new Error("pending async requests below zero");return this._runCallbacksIfReady(),this._pendingCount}},{key:"isStable",value:function(){return this._isZoneStable&&0===this._pendingCount&&!this._ngZone.hasPendingMacrotasks}},{key:"_runCallbacksIfReady",value:function(){var t=this;if(this.isStable())Al((function(){for(;0!==t._callbacks.length;){var e=t._callbacks.pop();clearTimeout(e.timeoutId),e.doneCb(t._didWork)}t._didWork=!1}));else{var e=this.getPendingTasks();this._callbacks=this._callbacks.filter((function(t){return!t.updateCb||!t.updateCb(e)||(clearTimeout(t.timeoutId),!1)})),this._didWork=!0}}},{key:"getPendingTasks",value:function(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map((function(t){return{source:t.source,creationLocation:t.creationLocation,data:t.data}})):[]}},{key:"addCallback",value:function(t,e,n){var i=this,r=-1;e&&e>0&&(r=setTimeout((function(){i._callbacks=i._callbacks.filter((function(t){return t.timeoutId!==r})),t(i._didWork,i.getPendingTasks())}),e)),this._callbacks.push({doneCb:t,timeoutId:r,updateCb:n})}},{key:"whenStable",value:function(t,e,n){if(n&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/dist/task-tracking.js" loaded?');this.addCallback(t,e,n),this._runCallbacksIfReady()}},{key:"getPendingRequestCount",value:function(){return this._pendingCount}},{key:"findProviders",value:function(t,e,n){return[]}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(jl))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Vl=function(){var t=function(){function t(){Object(m.a)(this,t),this._applications=new Map,Ul.addToWindow(this)}return Object(g.a)(t,[{key:"registerApplication",value:function(t,e){this._applications.set(t,e)}},{key:"unregisterApplication",value:function(t){this._applications.delete(t)}},{key:"unregisterAllApplications",value:function(){this._applications.clear()}},{key:"getTestability",value:function(t){return this._applications.get(t)||null}},{key:"getAllTestabilities",value:function(){return Array.from(this._applications.values())}},{key:"getAllRootElements",value:function(){return Array.from(this._applications.keys())}},{key:"findTestabilityInTree",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return Ul.findTestabilityInTree(this,t,e)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Ul=new(function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"addToWindow",value:function(t){}},{key:"findTestabilityInTree",value:function(t,e,n){return null}}]),t}()),ql=function(t,e,n){var i=new Ac(n);return Promise.resolve(i)},Gl=new ht("AllowMultipleToken"),Wl=function t(e,n){Object(m.a)(this,t),this.name=e,this.token=n};function Kl(t){if(Bl&&!Bl.destroyed&&!Bl.injector.get(Gl,!1))throw new Error("There can be only one platform. Destroy the previous one to create a new one.");Bl=t.get(Ql);var e=t.get(gl,null);return e&&e.forEach((function(t){return t()})),Bl}function Xl(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],i="Platform: ".concat(e),r=new ht(i);return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],o=Zl();if(!o||o.injector.get(Gl,!1))if(t)t(n.concat(e).concat({provide:r,useValue:!0}));else{var a=n.concat(e).concat({provide:r,useValue:!0},{provide:Io,useValue:"platform"});Kl(Xo.create({providers:a,name:i}))}return Yl(r)}}function Yl(t){var e=Zl();if(!e)throw new Error("No platform exists!");if(!e.injector.get(t,null))throw new Error("A platform with a different configuration has been created. Please destroy it first.");return e}function Zl(){return Bl&&!Bl.destroyed?Bl:null}var Ql=function(){var t=function(){function t(e){Object(m.a)(this,t),this._injector=e,this._modules=[],this._destroyListeners=[],this._destroyed=!1}return Object(g.a)(t,[{key:"bootstrapModuleFactory",value:function(t,e){var n,i,r=this,o=(i=e&&e.ngZoneEventCoalescing||!1,"noop"===(n=e?e.ngZone:void 0)?new Hl:("zone.js"===n?void 0:n)||new jl({enableLongStackTrace:ii(),shouldCoalesceEventChangeDetection:i})),a=[{provide:jl,useValue:o}];return o.run((function(){var e=Xo.create({providers:a,parent:r.injector,name:t.moduleType.name}),n=t.create(e),i=n.injector.get(Gn,null);if(!i)throw new Error("No ErrorHandler. Is platform module (BrowserModule) included?");return n.onDestroy((function(){return tu(r._modules,n)})),o.runOutsideAngular((function(){return o.onError.subscribe({next:function(t){i.handleError(t)}})})),function(t,e,i){try{var o=((a=n.injector.get(dl)).runInitializers(),a.donePromise.then((function(){return Tc(n.injector.get(_l,"en-US")||"en-US"),r._moduleDoBootstrap(n),n})));return Ca(o)?o.catch((function(n){throw e.runOutsideAngular((function(){return t.handleError(n)})),n})):o}catch(s){throw e.runOutsideAngular((function(){return t.handleError(s)})),s}var a}(i,o)}))}},{key:"bootstrapModule",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=$l({},n);return ql(0,0,t).then((function(t){return e.bootstrapModuleFactory(t,i)}))}},{key:"_moduleDoBootstrap",value:function(t){var e=t.injector.get(Jl);if(t._bootstrapComponents.length>0)t._bootstrapComponents.forEach((function(t){return e.bootstrap(t)}));else{if(!t.instance.ngDoBootstrap)throw new Error("The module ".concat(W(t.instance.constructor),' was bootstrapped, but it does not declare "@NgModule.bootstrap" components nor a "ngDoBootstrap" method. ')+"Please define one of these.");t.instance.ngDoBootstrap(e)}this._modules.push(t)}},{key:"onDestroy",value:function(t){this._destroyListeners.push(t)}},{key:"destroy",value:function(){if(this._destroyed)throw new Error("The platform has already been destroyed!");this._modules.slice().forEach((function(t){return t.destroy()})),this._destroyListeners.forEach((function(t){return t()})),this._destroyed=!0}},{key:"injector",get:function(){return this._injector}},{key:"destroyed",get:function(){return this._destroyed}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Xo))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}();function $l(t,e){return Array.isArray(e)?e.reduce($l,t):Object.assign(Object.assign({},t),e)}var Jl=function(){var t=function(){function t(e,n,i,r,o,a){var s=this;Object(m.a)(this,t),this._zone=e,this._console=n,this._injector=i,this._exceptionHandler=r,this._componentFactoryResolver=o,this._initStatus=a,this._bootstrapListeners=[],this._views=[],this._runningTick=!1,this._enforceNoNewChanges=!1,this._stable=!0,this.componentTypes=[],this.components=[],this._enforceNoNewChanges=ii(),this._zone.onMicrotaskEmpty.subscribe({next:function(){s._zone.run((function(){s.tick()}))}});var c=new k.a((function(t){s._stable=s._zone.isStable&&!s._zone.hasPendingMacrotasks&&!s._zone.hasPendingMicrotasks,s._zone.runOutsideAngular((function(){t.next(s._stable),t.complete()}))})),l=new k.a((function(t){var e;s._zone.runOutsideAngular((function(){e=s._zone.onStable.subscribe((function(){jl.assertNotInAngularZone(),Al((function(){s._stable||s._zone.hasPendingMacrotasks||s._zone.hasPendingMicrotasks||(s._stable=!0,t.next(!0))}))}))}));var n=s._zone.onUnstable.subscribe((function(){jl.assertInAngularZone(),s._stable&&(s._stable=!1,s._zone.runOutsideAngular((function(){t.next(!1)})))}));return function(){e.unsubscribe(),n.unsubscribe()}}));this.isStable=Object(C.a)(c,l.pipe(Object(S.a)()))}return Object(g.a)(t,[{key:"bootstrap",value:function(t,e){var n,i=this;if(!this._initStatus.done)throw new Error("Cannot bootstrap as there are still asynchronous initializers running. Bootstrap components in the `ngDoBootstrap` method of the root module.");n=t instanceof Hs?t:this._componentFactoryResolver.resolveComponentFactory(t),this.componentTypes.push(n.componentType);var r=n.isBoundToModule?void 0:this._injector.get(Ot),o=n.create(Xo.NULL,[],e||n.selector,r);o.onDestroy((function(){i._unloadComponent(o)}));var a=o.injector.get(zl,null);return a&&o.injector.get(Vl).registerApplication(o.location.nativeElement,a),this._loadComponent(o),ii()&&this._console.log("Angular is running in development mode. Call enableProdMode() to enable production mode."),o}},{key:"tick",value:function(){var t=this;if(this._runningTick)throw new Error("ApplicationRef.tick is called recursively");try{this._runningTick=!0;var e,n=d(this._views);try{for(n.s();!(e=n.n()).done;)e.value.detectChanges()}catch(o){n.e(o)}finally{n.f()}if(this._enforceNoNewChanges){var i,r=d(this._views);try{for(r.s();!(i=r.n()).done;)i.value.checkNoChanges()}catch(o){r.e(o)}finally{r.f()}}}catch(a){this._zone.runOutsideAngular((function(){return t._exceptionHandler.handleError(a)}))}finally{this._runningTick=!1}}},{key:"attachView",value:function(t){var e=t;this._views.push(e),e.attachToAppRef(this)}},{key:"detachView",value:function(t){var e=t;tu(this._views,e),e.detachFromAppRef()}},{key:"_loadComponent",value:function(t){this.attachView(t.hostView),this.tick(),this.components.push(t),this._injector.get(bl,[]).concat(this._bootstrapListeners).forEach((function(e){return e(t)}))}},{key:"_unloadComponent",value:function(t){this.detachView(t.hostView),tu(this.components,t)}},{key:"ngOnDestroy",value:function(){this._views.slice().forEach((function(t){return t.destroy()}))}},{key:"viewCount",get:function(){return this._views.length}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(jl),_t(yl),_t(Xo),_t(Gn),_t(Vs),_t(dl))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}();function tu(t,e){var n=t.indexOf(e);n>-1&&t.splice(n,1)}var eu=function t(){Object(m.a)(this,t)},nu=function t(){Object(m.a)(this,t)},iu={factoryPathPrefix:"",factoryPathSuffix:".ngfactory"},ru=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._compiler=e,this._config=n||iu}return Object(g.a)(t,[{key:"load",value:function(t){return this.loadAndCompile(t)}},{key:"loadAndCompile",value:function(t){var e=this,i=l(t.split("#"),2),r=i[0],o=i[1];return void 0===o&&(o="default"),n("crnd")(r).then((function(t){return t[o]})).then((function(t){return ou(t,r,o)})).then((function(t){return e._compiler.compileModuleAsync(t)}))}},{key:"loadFactory",value:function(t){var e=l(t.split("#"),2),i=e[0],r=e[1],o="NgFactory";return void 0===r&&(r="default",o=""),n("crnd")(this._config.factoryPathPrefix+i+this._config.factoryPathSuffix).then((function(t){return t[r+o]})).then((function(t){return ou(t,i,r)}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(El),_t(nu,8))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}();function ou(t,e,n){if(!t)throw new Error("Cannot find '".concat(n,"' in '").concat(e,"'"));return t}var au=Xl(null,"core",[{provide:vl,useValue:"unknown"},{provide:Ql,deps:[Xo]},{provide:Vl,deps:[]},{provide:yl,deps:[]}]),su=[{provide:Jl,useClass:Jl,deps:[jl,yl,Xo,Gn,Vs,dl]},{provide:_c,deps:[jl],useFactory:function(t){var e=[];return t.onStable.subscribe((function(){for(;e.length;)e.pop()()})),function(t){e.push(t)}}},{provide:dl,useClass:dl,deps:[[new E,hl]]},{provide:El,useClass:El,deps:[]},pl,{provide:cc,useFactory:function(){return hc},deps:[]},{provide:lc,useFactory:function(){return dc},deps:[]},{provide:_l,useFactory:function(t){return Tc(t=t||"undefined"!=typeof $localize&&$localize.locale||"en-US"),t},deps:[[new T(_l),new E,new A]]},{provide:wl,useValue:"USD"}],cu=function(){var t=function t(e){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)(_t(Jl))},providers:su}),t}(),lu=null;function uu(){return lu}var hu=function t(){Object(m.a)(this,t)},du=new ht("DocumentToken"),fu=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:pu,token:t,providedIn:"platform"}),t}();function pu(){return _t(gu)}var mu=new ht("Location Initialized"),gu=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this))._doc=t,i._init(),i}return Object(g.a)(n,[{key:"_init",value:function(){this.location=uu().getLocation(),this._history=uu().getHistory()}},{key:"getBaseHrefFromDOM",value:function(){return uu().getBaseHref(this._doc)}},{key:"onPopState",value:function(t){uu().getGlobalEventTarget(this._doc,"window").addEventListener("popstate",t,!1)}},{key:"onHashChange",value:function(t){uu().getGlobalEventTarget(this._doc,"window").addEventListener("hashchange",t,!1)}},{key:"pushState",value:function(t,e,n){vu()?this._history.pushState(t,e,n):this.location.hash=n}},{key:"replaceState",value:function(t,e,n){vu()?this._history.replaceState(t,e,n):this.location.hash=n}},{key:"forward",value:function(){this._history.forward()}},{key:"back",value:function(){this._history.back()}},{key:"getState",value:function(){return this._history.state}},{key:"href",get:function(){return this.location.href}},{key:"protocol",get:function(){return this.location.protocol}},{key:"hostname",get:function(){return this.location.hostname}},{key:"port",get:function(){return this.location.port}},{key:"pathname",get:function(){return this.location.pathname},set:function(t){this.location.pathname=t}},{key:"search",get:function(){return this.location.search}},{key:"hash",get:function(){return this.location.hash}}]),n}(fu);return t.\u0275fac=function(e){return new(e||t)(_t(du))},t.\u0275prov=R({factory:bu,token:t,providedIn:"platform"}),t}();function vu(){return!!window.history.pushState}function bu(){return new gu(_t(du))}function yu(t,e){if(0==t.length)return e;if(0==e.length)return t;var n=0;return t.endsWith("/")&&n++,e.startsWith("/")&&n++,2==n?t+e.substring(1):1==n?t+e:t+"/"+e}function _u(t){var e=t.match(/#|\?|$/),n=e&&e.index||t.length;return t.slice(0,n-("/"===t[n-1]?1:0))+t.slice(n)}function wu(t){return t&&"?"!==t[0]?"?"+t:t}var ku=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:Cu,token:t,providedIn:"root"}),t}();function Cu(t){var e=_t(du).location;return new xu(_t(fu),e&&e.origin||"")}var Su=new ht("appBaseHref"),xu=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;if(Object(m.a)(this,n),(r=e.call(this))._platformLocation=t,null==i&&(i=r._platformLocation.getBaseHrefFromDOM()),null==i)throw new Error("No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.");return r._baseHref=i,r}return Object(g.a)(n,[{key:"onPopState",value:function(t){this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t)}},{key:"getBaseHref",value:function(){return this._baseHref}},{key:"prepareExternalUrl",value:function(t){return yu(this._baseHref,t)}},{key:"path",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this._platformLocation.pathname+wu(this._platformLocation.search),n=this._platformLocation.hash;return n&&t?"".concat(e).concat(n):e}},{key:"pushState",value:function(t,e,n,i){var r=this.prepareExternalUrl(n+wu(i));this._platformLocation.pushState(t,e,r)}},{key:"replaceState",value:function(t,e,n,i){var r=this.prepareExternalUrl(n+wu(i));this._platformLocation.replaceState(t,e,r)}},{key:"forward",value:function(){this._platformLocation.forward()}},{key:"back",value:function(){this._platformLocation.back()}}]),n}(ku);return t.\u0275fac=function(e){return new(e||t)(_t(fu),_t(Su,8))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Ou=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this))._platformLocation=t,r._baseHref="",null!=i&&(r._baseHref=i),r}return Object(g.a)(n,[{key:"onPopState",value:function(t){this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t)}},{key:"getBaseHref",value:function(){return this._baseHref}},{key:"path",value:function(){var t=this._platformLocation.hash;return null==t&&(t="#"),t.length>0?t.substring(1):t}},{key:"prepareExternalUrl",value:function(t){var e=yu(this._baseHref,t);return e.length>0?"#"+e:e}},{key:"pushState",value:function(t,e,n,i){var r=this.prepareExternalUrl(n+wu(i));0==r.length&&(r=this._platformLocation.pathname),this._platformLocation.pushState(t,e,r)}},{key:"replaceState",value:function(t,e,n,i){var r=this.prepareExternalUrl(n+wu(i));0==r.length&&(r=this._platformLocation.pathname),this._platformLocation.replaceState(t,e,r)}},{key:"forward",value:function(){this._platformLocation.forward()}},{key:"back",value:function(){this._platformLocation.back()}}]),n}(ku);return t.\u0275fac=function(e){return new(e||t)(_t(fu),_t(Su,8))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Mu=function(){var t=function(){function t(e,n){var i=this;Object(m.a)(this,t),this._subject=new Uc,this._urlChangeListeners=[],this._platformStrategy=e;var r=this._platformStrategy.getBaseHref();this._platformLocation=n,this._baseHref=_u(Eu(r)),this._platformStrategy.onPopState((function(t){i._subject.emit({url:i.path(!0),pop:!0,state:t.state,type:t.type})}))}return Object(g.a)(t,[{key:"path",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.normalize(this._platformStrategy.path(t))}},{key:"getState",value:function(){return this._platformLocation.getState()}},{key:"isCurrentPathEqualTo",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return this.path()==this.normalize(t+wu(e))}},{key:"normalize",value:function(e){return t.stripTrailingSlash(function(t,e){return t&&e.startsWith(t)?e.substring(t.length):e}(this._baseHref,Eu(e)))}},{key:"prepareExternalUrl",value:function(t){return t&&"/"!==t[0]&&(t="/"+t),this._platformStrategy.prepareExternalUrl(t)}},{key:"go",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;this._platformStrategy.pushState(n,"",t,e),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+wu(e)),n)}},{key:"replaceState",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;this._platformStrategy.replaceState(n,"",t,e),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+wu(e)),n)}},{key:"forward",value:function(){this._platformStrategy.forward()}},{key:"back",value:function(){this._platformStrategy.back()}},{key:"onUrlChange",value:function(t){var e=this;this._urlChangeListeners.push(t),this._urlChangeSubscription||(this._urlChangeSubscription=this.subscribe((function(t){e._notifyUrlChangeListeners(t.url,t.state)})))}},{key:"_notifyUrlChangeListeners",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0;this._urlChangeListeners.forEach((function(n){return n(t,e)}))}},{key:"subscribe",value:function(t,e,n){return this._subject.subscribe({next:t,error:e,complete:n})}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(ku),_t(fu))},t.normalizeQueryParams=wu,t.joinWithSlash=yu,t.stripTrailingSlash=_u,t.\u0275prov=R({factory:Tu,token:t,providedIn:"root"}),t}();function Tu(){return new Mu(_t(ku),_t(fu))}function Eu(t){return t.replace(/\/index.html$/,"")}var Pu={ADP:[void 0,void 0,0],AFN:[void 0,void 0,0],ALL:[void 0,void 0,0],AMD:[void 0,void 0,2],AOA:[void 0,"Kz"],ARS:[void 0,"$"],AUD:["A$","$"],BAM:[void 0,"KM"],BBD:[void 0,"$"],BDT:[void 0,"\u09f3"],BHD:[void 0,void 0,3],BIF:[void 0,void 0,0],BMD:[void 0,"$"],BND:[void 0,"$"],BOB:[void 0,"Bs"],BRL:["R$"],BSD:[void 0,"$"],BWP:[void 0,"P"],BYN:[void 0,"\u0440.",2],BYR:[void 0,void 0,0],BZD:[void 0,"$"],CAD:["CA$","$",2],CHF:[void 0,void 0,2],CLF:[void 0,void 0,4],CLP:[void 0,"$",0],CNY:["CN\xa5","\xa5"],COP:[void 0,"$",2],CRC:[void 0,"\u20a1",2],CUC:[void 0,"$"],CUP:[void 0,"$"],CZK:[void 0,"K\u010d",2],DJF:[void 0,void 0,0],DKK:[void 0,"kr",2],DOP:[void 0,"$"],EGP:[void 0,"E\xa3"],ESP:[void 0,"\u20a7",0],EUR:["\u20ac"],FJD:[void 0,"$"],FKP:[void 0,"\xa3"],GBP:["\xa3"],GEL:[void 0,"\u20be"],GIP:[void 0,"\xa3"],GNF:[void 0,"FG",0],GTQ:[void 0,"Q"],GYD:[void 0,"$",2],HKD:["HK$","$"],HNL:[void 0,"L"],HRK:[void 0,"kn"],HUF:[void 0,"Ft",2],IDR:[void 0,"Rp",2],ILS:["\u20aa"],INR:["\u20b9"],IQD:[void 0,void 0,0],IRR:[void 0,void 0,0],ISK:[void 0,"kr",0],ITL:[void 0,void 0,0],JMD:[void 0,"$"],JOD:[void 0,void 0,3],JPY:["\xa5",void 0,0],KHR:[void 0,"\u17db"],KMF:[void 0,"CF",0],KPW:[void 0,"\u20a9",0],KRW:["\u20a9",void 0,0],KWD:[void 0,void 0,3],KYD:[void 0,"$"],KZT:[void 0,"\u20b8"],LAK:[void 0,"\u20ad",0],LBP:[void 0,"L\xa3",0],LKR:[void 0,"Rs"],LRD:[void 0,"$"],LTL:[void 0,"Lt"],LUF:[void 0,void 0,0],LVL:[void 0,"Ls"],LYD:[void 0,void 0,3],MGA:[void 0,"Ar",0],MGF:[void 0,void 0,0],MMK:[void 0,"K",0],MNT:[void 0,"\u20ae",2],MRO:[void 0,void 0,0],MUR:[void 0,"Rs",2],MXN:["MX$","$"],MYR:[void 0,"RM"],NAD:[void 0,"$"],NGN:[void 0,"\u20a6"],NIO:[void 0,"C$"],NOK:[void 0,"kr",2],NPR:[void 0,"Rs"],NZD:["NZ$","$"],OMR:[void 0,void 0,3],PHP:[void 0,"\u20b1"],PKR:[void 0,"Rs",2],PLN:[void 0,"z\u0142"],PYG:[void 0,"\u20b2",0],RON:[void 0,"lei"],RSD:[void 0,void 0,0],RUB:[void 0,"\u20bd"],RUR:[void 0,"\u0440."],RWF:[void 0,"RF",0],SBD:[void 0,"$"],SEK:[void 0,"kr",2],SGD:[void 0,"$"],SHP:[void 0,"\xa3"],SLL:[void 0,void 0,0],SOS:[void 0,void 0,0],SRD:[void 0,"$"],SSP:[void 0,"\xa3"],STD:[void 0,void 0,0],STN:[void 0,"Db"],SYP:[void 0,"\xa3",0],THB:[void 0,"\u0e3f"],TMM:[void 0,void 0,0],TND:[void 0,void 0,3],TOP:[void 0,"T$"],TRL:[void 0,void 0,0],TRY:[void 0,"\u20ba"],TTD:[void 0,"$"],TWD:["NT$","$",2],TZS:[void 0,void 0,2],UAH:[void 0,"\u20b4"],UGX:[void 0,void 0,0],USD:["$"],UYI:[void 0,void 0,0],UYU:[void 0,"$"],UYW:[void 0,void 0,4],UZS:[void 0,void 0,2],VEF:[void 0,"Bs",2],VND:["\u20ab",void 0,0],VUV:[void 0,void 0,0],XAF:["FCFA",void 0,0],XCD:["EC$","$"],XOF:["CFA",void 0,0],XPF:["CFPF",void 0,0],XXX:["\xa4"],YER:[void 0,void 0,0],ZAR:[void 0,"R"],ZMK:[void 0,void 0,0],ZMW:[void 0,"ZK"],ZWD:[void 0,void 0,0]},Au=function(t){return t[t.Decimal=0]="Decimal",t[t.Percent=1]="Percent",t[t.Currency=2]="Currency",t[t.Scientific=3]="Scientific",t}({}),ju=function(t){return t[t.Zero=0]="Zero",t[t.One=1]="One",t[t.Two=2]="Two",t[t.Few=3]="Few",t[t.Many=4]="Many",t[t.Other=5]="Other",t}({}),Iu=function(t){return t[t.Format=0]="Format",t[t.Standalone=1]="Standalone",t}({}),Du=function(t){return t[t.Narrow=0]="Narrow",t[t.Abbreviated=1]="Abbreviated",t[t.Wide=2]="Wide",t[t.Short=3]="Short",t}({}),Ru=function(t){return t[t.Short=0]="Short",t[t.Medium=1]="Medium",t[t.Long=2]="Long",t[t.Full=3]="Full",t}({}),Lu=function(t){return t[t.Decimal=0]="Decimal",t[t.Group=1]="Group",t[t.List=2]="List",t[t.PercentSign=3]="PercentSign",t[t.PlusSign=4]="PlusSign",t[t.MinusSign=5]="MinusSign",t[t.Exponential=6]="Exponential",t[t.SuperscriptingExponent=7]="SuperscriptingExponent",t[t.PerMille=8]="PerMille",t[t[1/0]=9]="Infinity",t[t.NaN=10]="NaN",t[t.TimeSeparator=11]="TimeSeparator",t[t.CurrencyDecimal=12]="CurrencyDecimal",t[t.CurrencyGroup=13]="CurrencyGroup",t}({});function Fu(t,e){return qu(xc(t)[Mc.DateFormat],e)}function Nu(t,e){return qu(xc(t)[Mc.TimeFormat],e)}function Bu(t,e){return qu(xc(t)[Mc.DateTimeFormat],e)}function Hu(t,e){var n=xc(t),i=n[Mc.NumberSymbols][e];if(void 0===i){if(e===Lu.CurrencyDecimal)return n[Mc.NumberSymbols][Lu.Decimal];if(e===Lu.CurrencyGroup)return n[Mc.NumberSymbols][Lu.Group]}return i}function zu(t,e){return xc(t)[Mc.NumberFormats][e]}function Vu(t){return xc(t)[Mc.Currencies]}function Uu(t){if(!t[Mc.ExtraData])throw new Error('Missing extra locale data for the locale "'.concat(t[Mc.LocaleId],'". Use "registerLocaleData" to load new data. See the "I18n guide" on angular.io to know more.'))}function qu(t,e){for(var n=e;n>-1;n--)if(void 0!==t[n])return t[n];throw new Error("Locale data API: locale data undefined")}function Gu(t){var e=l(t.split(":"),2);return{hours:+e[0],minutes:+e[1]}}function Wu(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"en",i=Vu(n)[t]||Pu[t]||[],r=i[1];return"narrow"===e&&"string"==typeof r?r:i[0]||t}var Ku=/^(\d{4})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,Xu={},Yu=/((?:[^GyMLwWdEabBhHmsSzZO']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/,Zu=function(t){return t[t.Short=0]="Short",t[t.ShortGMT=1]="ShortGMT",t[t.Long=2]="Long",t[t.Extended=3]="Extended",t}({}),Qu=function(t){return t[t.FullYear=0]="FullYear",t[t.Month=1]="Month",t[t.Date=2]="Date",t[t.Hours=3]="Hours",t[t.Minutes=4]="Minutes",t[t.Seconds=5]="Seconds",t[t.FractionalSeconds=6]="FractionalSeconds",t[t.Day=7]="Day",t}({}),$u=function(t){return t[t.DayPeriods=0]="DayPeriods",t[t.Days=1]="Days",t[t.Months=2]="Months",t[t.Eras=3]="Eras",t}({});function Ju(t,e,n,i){var r=function(t){if(fh(t))return t;if("number"==typeof t&&!isNaN(t))return new Date(t);if("string"==typeof t){t=t.trim();var e,n=parseFloat(t);if(!isNaN(t-n))return new Date(n);if(/^(\d{4}-\d{1,2}-\d{1,2})$/.test(t)){var i=l(t.split("-").map((function(t){return+t})),3);return new Date(i[0],i[1]-1,i[2])}if(e=t.match(Ku))return function(t){var e=new Date(0),n=0,i=0,r=t[8]?e.setUTCFullYear:e.setFullYear,o=t[8]?e.setUTCHours:e.setHours;t[9]&&(n=Number(t[9]+t[10]),i=Number(t[9]+t[11])),r.call(e,Number(t[1]),Number(t[2])-1,Number(t[3]));var a=Number(t[4]||0)-n,s=Number(t[5]||0)-i,c=Number(t[6]||0),l=Math.round(1e3*parseFloat("0."+(t[7]||0)));return o.call(e,a,s,c,l),e}(e)}var r=new Date(t);if(!fh(r))throw new Error('Unable to convert "'.concat(t,'" into a date'));return r}(t);e=function t(e,n){var i=function(t){return xc(t)[Mc.LocaleId]}(e);if(Xu[i]=Xu[i]||{},Xu[i][n])return Xu[i][n];var r="";switch(n){case"shortDate":r=Fu(e,Ru.Short);break;case"mediumDate":r=Fu(e,Ru.Medium);break;case"longDate":r=Fu(e,Ru.Long);break;case"fullDate":r=Fu(e,Ru.Full);break;case"shortTime":r=Nu(e,Ru.Short);break;case"mediumTime":r=Nu(e,Ru.Medium);break;case"longTime":r=Nu(e,Ru.Long);break;case"fullTime":r=Nu(e,Ru.Full);break;case"short":var o=t(e,"shortTime"),a=t(e,"shortDate");r=th(Bu(e,Ru.Short),[o,a]);break;case"medium":var s=t(e,"mediumTime"),c=t(e,"mediumDate");r=th(Bu(e,Ru.Medium),[s,c]);break;case"long":var l=t(e,"longTime"),u=t(e,"longDate");r=th(Bu(e,Ru.Long),[l,u]);break;case"full":var h=t(e,"fullTime"),d=t(e,"fullDate");r=th(Bu(e,Ru.Full),[h,d])}return r&&(Xu[i][n]=r),r}(n,e)||e;for(var o,a=[];e;){if(!(o=Yu.exec(e))){a.push(e);break}var s=(a=a.concat(o.slice(1))).pop();if(!s)break;e=s}var c=r.getTimezoneOffset();i&&(c=dh(i,c),r=function(t,e,n){var i=t.getTimezoneOffset();return function(t,e){return(t=new Date(t.getTime())).setMinutes(t.getMinutes()+e),t}(t,-1*(dh(e,i)-i))}(r,i));var u="";return a.forEach((function(t){var e=function(t){if(hh[t])return hh[t];var e;switch(t){case"G":case"GG":case"GGG":e=oh($u.Eras,Du.Abbreviated);break;case"GGGG":e=oh($u.Eras,Du.Wide);break;case"GGGGG":e=oh($u.Eras,Du.Narrow);break;case"y":e=ih(Qu.FullYear,1,0,!1,!0);break;case"yy":e=ih(Qu.FullYear,2,0,!0,!0);break;case"yyy":e=ih(Qu.FullYear,3,0,!1,!0);break;case"yyyy":e=ih(Qu.FullYear,4,0,!1,!0);break;case"M":case"L":e=ih(Qu.Month,1,1);break;case"MM":case"LL":e=ih(Qu.Month,2,1);break;case"MMM":e=oh($u.Months,Du.Abbreviated);break;case"MMMM":e=oh($u.Months,Du.Wide);break;case"MMMMM":e=oh($u.Months,Du.Narrow);break;case"LLL":e=oh($u.Months,Du.Abbreviated,Iu.Standalone);break;case"LLLL":e=oh($u.Months,Du.Wide,Iu.Standalone);break;case"LLLLL":e=oh($u.Months,Du.Narrow,Iu.Standalone);break;case"w":e=uh(1);break;case"ww":e=uh(2);break;case"W":e=uh(1,!0);break;case"d":e=ih(Qu.Date,1);break;case"dd":e=ih(Qu.Date,2);break;case"E":case"EE":case"EEE":e=oh($u.Days,Du.Abbreviated);break;case"EEEE":e=oh($u.Days,Du.Wide);break;case"EEEEE":e=oh($u.Days,Du.Narrow);break;case"EEEEEE":e=oh($u.Days,Du.Short);break;case"a":case"aa":case"aaa":e=oh($u.DayPeriods,Du.Abbreviated);break;case"aaaa":e=oh($u.DayPeriods,Du.Wide);break;case"aaaaa":e=oh($u.DayPeriods,Du.Narrow);break;case"b":case"bb":case"bbb":e=oh($u.DayPeriods,Du.Abbreviated,Iu.Standalone,!0);break;case"bbbb":e=oh($u.DayPeriods,Du.Wide,Iu.Standalone,!0);break;case"bbbbb":e=oh($u.DayPeriods,Du.Narrow,Iu.Standalone,!0);break;case"B":case"BB":case"BBB":e=oh($u.DayPeriods,Du.Abbreviated,Iu.Format,!0);break;case"BBBB":e=oh($u.DayPeriods,Du.Wide,Iu.Format,!0);break;case"BBBBB":e=oh($u.DayPeriods,Du.Narrow,Iu.Format,!0);break;case"h":e=ih(Qu.Hours,1,-12);break;case"hh":e=ih(Qu.Hours,2,-12);break;case"H":e=ih(Qu.Hours,1);break;case"HH":e=ih(Qu.Hours,2);break;case"m":e=ih(Qu.Minutes,1);break;case"mm":e=ih(Qu.Minutes,2);break;case"s":e=ih(Qu.Seconds,1);break;case"ss":e=ih(Qu.Seconds,2);break;case"S":e=ih(Qu.FractionalSeconds,1);break;case"SS":e=ih(Qu.FractionalSeconds,2);break;case"SSS":e=ih(Qu.FractionalSeconds,3);break;case"Z":case"ZZ":case"ZZZ":e=sh(Zu.Short);break;case"ZZZZZ":e=sh(Zu.Extended);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":e=sh(Zu.ShortGMT);break;case"OOOO":case"ZZZZ":case"zzzz":e=sh(Zu.Long);break;default:return null}return hh[t]=e,e}(t);u+=e?e(r,n,c):"''"===t?"'":t.replace(/(^'|'$)/g,"").replace(/''/g,"'")})),u}function th(t,e){return e&&(t=t.replace(/\{([^}]+)}/g,(function(t,n){return null!=e&&n in e?e[n]:t}))),t}function eh(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"-",i=arguments.length>3?arguments[3]:void 0,r=arguments.length>4?arguments[4]:void 0,o="";(t<0||r&&t<=0)&&(r?t=1-t:(t=-t,o=n));for(var a=String(t);a.length<e;)a="0"+a;return i&&(a=a.substr(a.length-e)),o+a}function nh(t,e){return eh(t,3).substr(0,e)}function ih(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=arguments.length>4&&void 0!==arguments[4]&&arguments[4];return function(o,a){var s=rh(t,o);if((n>0||s>-n)&&(s+=n),t===Qu.Hours)0===s&&-12===n&&(s=12);else if(t===Qu.FractionalSeconds)return nh(s,e);var c=Hu(a,Lu.MinusSign);return eh(s,e,c,i,r)}}function rh(t,e){switch(t){case Qu.FullYear:return e.getFullYear();case Qu.Month:return e.getMonth();case Qu.Date:return e.getDate();case Qu.Hours:return e.getHours();case Qu.Minutes:return e.getMinutes();case Qu.Seconds:return e.getSeconds();case Qu.FractionalSeconds:return e.getMilliseconds();case Qu.Day:return e.getDay();default:throw new Error('Unknown DateType value "'.concat(t,'".'))}}function oh(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Iu.Format,i=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return function(r,o){return ah(r,o,t,e,n,i)}}function ah(t,e,n,i,r,o){switch(n){case $u.Months:return function(t,e,n){var i=xc(t),r=qu([i[Mc.MonthsFormat],i[Mc.MonthsStandalone]],e);return qu(r,n)}(e,r,i)[t.getMonth()];case $u.Days:return function(t,e,n){var i=xc(t),r=qu([i[Mc.DaysFormat],i[Mc.DaysStandalone]],e);return qu(r,n)}(e,r,i)[t.getDay()];case $u.DayPeriods:var a=t.getHours(),s=t.getMinutes();if(o){var c=function(t){var e=xc(t);return Uu(e),(e[Mc.ExtraData][2]||[]).map((function(t){return"string"==typeof t?Gu(t):[Gu(t[0]),Gu(t[1])]}))}(e),u=function(t,e,n){var i=xc(t);Uu(i);var r=qu([i[Mc.ExtraData][0],i[Mc.ExtraData][1]],e)||[];return qu(r,n)||[]}(e,r,i),h=c.findIndex((function(t){if(Array.isArray(t)){var e=l(t,2),n=e[0],i=e[1],r=a>=n.hours&&s>=n.minutes,o=a<i.hours||a===i.hours&&s<i.minutes;if(n.hours<i.hours){if(r&&o)return!0}else if(r||o)return!0}else if(t.hours===a&&t.minutes===s)return!0;return!1}));if(-1!==h)return u[h]}return function(t,e,n){var i=xc(t),r=qu([i[Mc.DayPeriodsFormat],i[Mc.DayPeriodsStandalone]],e);return qu(r,n)}(e,r,i)[a<12?0:1];case $u.Eras:return function(t,e){return qu(xc(t)[Mc.Eras],e)}(e,i)[t.getFullYear()<=0?0:1];default:throw new Error("unexpected translation type ".concat(n))}}function sh(t){return function(e,n,i){var r=-1*i,o=Hu(n,Lu.MinusSign),a=r>0?Math.floor(r/60):Math.ceil(r/60);switch(t){case Zu.Short:return(r>=0?"+":"")+eh(a,2,o)+eh(Math.abs(r%60),2,o);case Zu.ShortGMT:return"GMT"+(r>=0?"+":"")+eh(a,1,o);case Zu.Long:return"GMT"+(r>=0?"+":"")+eh(a,2,o)+":"+eh(Math.abs(r%60),2,o);case Zu.Extended:return 0===i?"Z":(r>=0?"+":"")+eh(a,2,o)+":"+eh(Math.abs(r%60),2,o);default:throw new Error('Unknown zone width "'.concat(t,'"'))}}}function ch(t){var e=new Date(t,0,1).getDay();return new Date(t,0,1+(e<=4?4:11)-e)}function lh(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate()+(4-t.getDay()))}function uh(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return function(n,i){var r;if(e){var o=new Date(n.getFullYear(),n.getMonth(),1).getDay()-1,a=n.getDate();r=1+Math.floor((a+o)/7)}else{var s=ch(n.getFullYear()),c=lh(n).getTime()-s.getTime();r=1+Math.round(c/6048e5)}return eh(r,t,Hu(i,Lu.MinusSign))}}var hh={};function dh(t,e){t=t.replace(/:/g,"");var n=Date.parse("Jan 01, 1970 00:00:00 "+t)/6e4;return isNaN(n)?e:n}function fh(t){return t instanceof Date&&!isNaN(t.valueOf())}var ph=/^(\d+)?\.((\d+)(-(\d+))?)?$/;function mh(t,e,n,i,r,o){var a=arguments.length>6&&void 0!==arguments[6]&&arguments[6],s="",c=!1;if(isFinite(t)){var l=yh(t);a&&(l=bh(l));var u=e.minInt,h=e.minFrac,d=e.maxFrac;if(o){var f=o.match(ph);if(null===f)throw new Error("".concat(o," is not a valid digit info"));var p=f[1],m=f[3],g=f[5];null!=p&&(u=wh(p)),null!=m&&(h=wh(m)),null!=g?d=wh(g):null!=m&&h>d&&(d=h)}_h(l,h,d);var v=l.digits,b=l.integerLen,y=l.exponent,_=[];for(c=v.every((function(t){return!t}));b<u;b++)v.unshift(0);for(;b<0;b++)v.unshift(0);b>0?_=v.splice(b,v.length):(_=v,v=[0]);var w=[];for(v.length>=e.lgSize&&w.unshift(v.splice(-e.lgSize,v.length).join(""));v.length>e.gSize;)w.unshift(v.splice(-e.gSize,v.length).join(""));v.length&&w.unshift(v.join("")),s=w.join(Hu(n,i)),_.length&&(s+=Hu(n,r)+_.join("")),y&&(s+=Hu(n,Lu.Exponential)+"+"+y)}else s=Hu(n,Lu.Infinity);return t<0&&!c?e.negPre+s+e.negSuf:e.posPre+s+e.posSuf}function gh(t,e,n,i,r){var o=vh(zu(e,Au.Currency),Hu(e,Lu.MinusSign));return o.minFrac=function(t){var e,n=Pu[t];return n&&(e=n[2]),"number"==typeof e?e:2}(i),o.maxFrac=o.minFrac,mh(t,o,e,Lu.CurrencyGroup,Lu.CurrencyDecimal,r).replace("\xa4",n).replace("\xa4","").trim()}function vh(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"-",n={minInt:1,minFrac:0,maxFrac:0,posPre:"",posSuf:"",negPre:"",negSuf:"",gSize:0,lgSize:0},i=t.split(";"),r=i[0],o=i[1],a=-1!==r.indexOf(".")?r.split("."):[r.substring(0,r.lastIndexOf("0")+1),r.substring(r.lastIndexOf("0")+1)],s=a[0],c=a[1]||"";n.posPre=s.substr(0,s.indexOf("#"));for(var l=0;l<c.length;l++){var u=c.charAt(l);"0"===u?n.minFrac=n.maxFrac=l+1:"#"===u?n.maxFrac=l+1:n.posSuf+=u}var h=s.split(",");if(n.gSize=h[1]?h[1].length:0,n.lgSize=h[2]||h[1]?(h[2]||h[1]).length:0,o){var d=r.length-n.posPre.length-n.posSuf.length,f=o.indexOf("#");n.negPre=o.substr(0,f).replace(/'/g,""),n.negSuf=o.substr(f+d).replace(/'/g,"")}else n.negPre=e+n.posPre,n.negSuf=n.posSuf;return n}function bh(t){if(0===t.digits[0])return t;var e=t.digits.length-t.integerLen;return t.exponent?t.exponent+=2:(0===e?t.digits.push(0,0):1===e&&t.digits.push(0),t.integerLen+=2),t}function yh(t){var e,n,i,r,o,a=Math.abs(t)+"",s=0;for((n=a.indexOf("."))>-1&&(a=a.replace(".","")),(i=a.search(/e/i))>0?(n<0&&(n=i),n+=+a.slice(i+1),a=a.substring(0,i)):n<0&&(n=a.length),i=0;"0"===a.charAt(i);i++);if(i===(o=a.length))e=[0],n=1;else{for(o--;"0"===a.charAt(o);)o--;for(n-=i,e=[],r=0;i<=o;i++,r++)e[r]=Number(a.charAt(i))}return n>22&&(e=e.splice(0,21),s=n-1,n=1),{digits:e,exponent:s,integerLen:n}}function _h(t,e,n){if(e>n)throw new Error("The minimum number of digits after fraction (".concat(e,") is higher than the maximum (").concat(n,")."));var i=t.digits,r=i.length-t.integerLen,o=Math.min(Math.max(e,r),n),a=o+t.integerLen,s=i[a];if(a>0){i.splice(Math.max(t.integerLen,a));for(var c=a;c<i.length;c++)i[c]=0}else{r=Math.max(0,r),t.integerLen=1,i.length=Math.max(1,a=o+1),i[0]=0;for(var l=1;l<a;l++)i[l]=0}if(s>=5)if(a-1<0){for(var u=0;u>a;u--)i.unshift(0),t.integerLen++;i.unshift(1),t.integerLen++}else i[a-1]++;for(;r<Math.max(0,o);r++)i.push(0);var h=0!==o,d=e+t.integerLen,f=i.reduceRight((function(t,e,n,i){return i[n]=(e+=t)<10?e:e-10,h&&(0===i[n]&&n>=d?i.pop():h=!1),e>=10?1:0}),0);f&&(i.unshift(f),t.integerLen++)}function wh(t){var e=parseInt(t);if(isNaN(e))throw new Error("Invalid integer literal when parsing "+t);return e}var kh=function t(){Object(m.a)(this,t)};function Ch(t,e,n,i){var r="=".concat(t);if(e.indexOf(r)>-1)return r;if(r=n.getPluralCategory(t,i),e.indexOf(r)>-1)return r;if(e.indexOf("other")>-1)return"other";throw new Error('No plural message found for value "'.concat(t,'"'))}var Sh=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this)).locale=t,i}return Object(g.a)(n,[{key:"getPluralCategory",value:function(t,e){switch(function(t){return xc(t)[Mc.PluralCase]}(e||this.locale)(t)){case ju.Zero:return"zero";case ju.One:return"one";case ju.Two:return"two";case ju.Few:return"few";case ju.Many:return"many";default:return"other"}}}]),n}(kh);return t.\u0275fac=function(e){return new(e||t)(_t(_l))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}();function xh(t,e){e=encodeURIComponent(e);var n,i=d(t.split(";"));try{for(i.s();!(n=i.n()).done;){var r=n.value,o=r.indexOf("="),a=l(-1==o?[r,""]:[r.slice(0,o),r.slice(o+1)],2),s=a[1];if(a[0].trim()===e)return decodeURIComponent(s)}}catch(c){i.e(c)}finally{i.f()}return null}var Oh=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._iterableDiffers=e,this._keyValueDiffers=n,this._ngEl=i,this._renderer=r,this._iterableDiffer=null,this._keyValueDiffer=null,this._initialClasses=[],this._rawClass=null}return Object(g.a)(t,[{key:"ngDoCheck",value:function(){if(this._iterableDiffer){var t=this._iterableDiffer.diff(this._rawClass);t&&this._applyIterableChanges(t)}else if(this._keyValueDiffer){var e=this._keyValueDiffer.diff(this._rawClass);e&&this._applyKeyValueChanges(e)}}},{key:"_applyKeyValueChanges",value:function(t){var e=this;t.forEachAddedItem((function(t){return e._toggleClass(t.key,t.currentValue)})),t.forEachChangedItem((function(t){return e._toggleClass(t.key,t.currentValue)})),t.forEachRemovedItem((function(t){t.previousValue&&e._toggleClass(t.key,!1)}))}},{key:"_applyIterableChanges",value:function(t){var e=this;t.forEachAddedItem((function(t){if("string"!=typeof t.item)throw new Error("NgClass can only toggle CSS classes expressed as strings, got ".concat(W(t.item)));e._toggleClass(t.item,!0)})),t.forEachRemovedItem((function(t){return e._toggleClass(t.item,!1)}))}},{key:"_applyClasses",value:function(t){var e=this;t&&(Array.isArray(t)||t instanceof Set?t.forEach((function(t){return e._toggleClass(t,!0)})):Object.keys(t).forEach((function(n){return e._toggleClass(n,!!t[n])})))}},{key:"_removeClasses",value:function(t){var e=this;t&&(Array.isArray(t)||t instanceof Set?t.forEach((function(t){return e._toggleClass(t,!1)})):Object.keys(t).forEach((function(t){return e._toggleClass(t,!1)})))}},{key:"_toggleClass",value:function(t,e){var n=this;(t=t.trim())&&t.split(/\s+/g).forEach((function(t){e?n._renderer.addClass(n._ngEl.nativeElement,t):n._renderer.removeClass(n._ngEl.nativeElement,t)}))}},{key:"klass",set:function(t){this._removeClasses(this._initialClasses),this._initialClasses="string"==typeof t?t.split(/\s+/):[],this._applyClasses(this._initialClasses),this._applyClasses(this._rawClass)}},{key:"ngClass",set:function(t){this._removeClasses(this._rawClass),this._applyClasses(this._initialClasses),this._iterableDiffer=null,this._keyValueDiffer=null,this._rawClass="string"==typeof t?t.split(/\s+/):t,this._rawClass&&(ta(this._rawClass)?this._iterableDiffer=this._iterableDiffers.find(this._rawClass).create():this._keyValueDiffer=this._keyValueDiffers.find(this._rawClass).create())}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(cc),da(lc),da(Us),da(Ks))},t.\u0275dir=Wt({type:t,selectors:[["","ngClass",""]],inputs:{klass:["class","klass"],ngClass:"ngClass"}}),t}(),Mh=function(){var t=function(){function t(e){Object(m.a)(this,t),this._viewContainerRef=e,this._componentRef=null,this._moduleRef=null}return Object(g.a)(t,[{key:"ngOnChanges",value:function(t){if(this._viewContainerRef.clear(),this._componentRef=null,this.ngComponentOutlet){var e=this.ngComponentOutletInjector||this._viewContainerRef.parentInjector;if(t.ngComponentOutletNgModuleFactory)if(this._moduleRef&&this._moduleRef.destroy(),this.ngComponentOutletNgModuleFactory){var n=e.get(Ot);this._moduleRef=this.ngComponentOutletNgModuleFactory.create(n.injector)}else this._moduleRef=null;var i=(this._moduleRef?this._moduleRef.componentFactoryResolver:e.get(Vs)).resolveComponentFactory(this.ngComponentOutlet);this._componentRef=this._viewContainerRef.createComponent(i,this._viewContainerRef.length,e,this.ngComponentOutletContent)}}},{key:"ngOnDestroy",value:function(){this._moduleRef&&this._moduleRef.destroy()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(mc))},t.\u0275dir=Wt({type:t,selectors:[["","ngComponentOutlet",""]],inputs:{ngComponentOutlet:"ngComponentOutlet",ngComponentOutletInjector:"ngComponentOutletInjector",ngComponentOutletContent:"ngComponentOutletContent",ngComponentOutletNgModuleFactory:"ngComponentOutletNgModuleFactory"},features:[Ms]}),t}(),Th=function(){function t(e,n,i,r){Object(m.a)(this,t),this.$implicit=e,this.ngForOf=n,this.index=i,this.count=r}return Object(g.a)(t,[{key:"first",get:function(){return 0===this.index}},{key:"last",get:function(){return this.index===this.count-1}},{key:"even",get:function(){return this.index%2==0}},{key:"odd",get:function(){return!this.even}}]),t}(),Eh=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._viewContainer=e,this._template=n,this._differs=i,this._ngForOf=null,this._ngForOfDirty=!0,this._differ=null}return Object(g.a)(t,[{key:"ngDoCheck",value:function(){if(this._ngForOfDirty){this._ngForOfDirty=!1;var t=this._ngForOf;if(!this._differ&&t)try{this._differ=this._differs.find(t).create(this.ngForTrackBy)}catch(i){throw new Error("Cannot find a differ supporting object '".concat(t,"' of type '").concat((e=t).name||typeof e,"'. NgFor only supports binding to Iterables such as Arrays."))}}var e;if(this._differ){var n=this._differ.diff(this._ngForOf);n&&this._applyChanges(n)}}},{key:"_applyChanges",value:function(t){var e=this,n=[];t.forEachOperation((function(t,i,r){if(null==t.previousIndex){var o=e._viewContainer.createEmbeddedView(e._template,new Th(null,e._ngForOf,-1,-1),null===r?void 0:r),a=new Ph(t,o);n.push(a)}else if(null==r)e._viewContainer.remove(null===i?void 0:i);else if(null!==i){var s=e._viewContainer.get(i);e._viewContainer.move(s,r);var c=new Ph(t,s);n.push(c)}}));for(var i=0;i<n.length;i++)this._perViewChange(n[i].view,n[i].record);for(var r=0,o=this._viewContainer.length;r<o;r++){var a=this._viewContainer.get(r);a.context.index=r,a.context.count=o,a.context.ngForOf=this._ngForOf}t.forEachIdentityChange((function(t){e._viewContainer.get(t.currentIndex).context.$implicit=t.item}))}},{key:"_perViewChange",value:function(t,e){t.context.$implicit=e.item}},{key:"ngForOf",set:function(t){this._ngForOf=t,this._ngForOfDirty=!0}},{key:"ngForTrackBy",set:function(t){ii()&&null!=t&&"function"!=typeof t&&console&&console.warn&&console.warn("trackBy must be a function, but received ".concat(JSON.stringify(t),". ")+"See https://angular.io/api/common/NgForOf#change-propagation for more information."),this._trackByFn=t},get:function(){return this._trackByFn}},{key:"ngForTemplate",set:function(t){t&&(this._template=t)}}],[{key:"ngTemplateContextGuard",value:function(t,e){return!0}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(mc),da(fc),da(cc))},t.\u0275dir=Wt({type:t,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"}}),t}(),Ph=function t(e,n){Object(m.a)(this,t),this.record=e,this.view=n},Ah=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._viewContainer=e,this._context=new jh,this._thenTemplateRef=null,this._elseTemplateRef=null,this._thenViewRef=null,this._elseViewRef=null,this._thenTemplateRef=n}return Object(g.a)(t,[{key:"_updateView",value:function(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}},{key:"ngIf",set:function(t){this._context.$implicit=this._context.ngIf=t,this._updateView()}},{key:"ngIfThen",set:function(t){Ih("ngIfThen",t),this._thenTemplateRef=t,this._thenViewRef=null,this._updateView()}},{key:"ngIfElse",set:function(t){Ih("ngIfElse",t),this._elseTemplateRef=t,this._elseViewRef=null,this._updateView()}}],[{key:"ngTemplateContextGuard",value:function(t,e){return!0}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(mc),da(fc))},t.\u0275dir=Wt({type:t,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"}}),t}(),jh=function t(){Object(m.a)(this,t),this.$implicit=null,this.ngIf=null};function Ih(t,e){if(e&&!e.createEmbeddedView)throw new Error("".concat(t," must be a TemplateRef, but received '").concat(W(e),"'."))}var Dh=function(){function t(e,n){Object(m.a)(this,t),this._viewContainerRef=e,this._templateRef=n,this._created=!1}return Object(g.a)(t,[{key:"create",value:function(){this._created=!0,this._viewContainerRef.createEmbeddedView(this._templateRef)}},{key:"destroy",value:function(){this._created=!1,this._viewContainerRef.clear()}},{key:"enforceState",value:function(t){t&&!this._created?this.create():!t&&this._created&&this.destroy()}}]),t}(),Rh=function(){var t=function(){function t(){Object(m.a)(this,t),this._defaultUsed=!1,this._caseCount=0,this._lastCaseCheckIndex=0,this._lastCasesMatched=!1}return Object(g.a)(t,[{key:"_addCase",value:function(){return this._caseCount++}},{key:"_addDefault",value:function(t){this._defaultViews||(this._defaultViews=[]),this._defaultViews.push(t)}},{key:"_matchCase",value:function(t){var e=t==this._ngSwitch;return this._lastCasesMatched=this._lastCasesMatched||e,this._lastCaseCheckIndex++,this._lastCaseCheckIndex===this._caseCount&&(this._updateDefaultCases(!this._lastCasesMatched),this._lastCaseCheckIndex=0,this._lastCasesMatched=!1),e}},{key:"_updateDefaultCases",value:function(t){if(this._defaultViews&&t!==this._defaultUsed){this._defaultUsed=t;for(var e=0;e<this._defaultViews.length;e++)this._defaultViews[e].enforceState(t)}}},{key:"ngSwitch",set:function(t){this._ngSwitch=t,0===this._caseCount&&this._updateDefaultCases(!0)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","ngSwitch",""]],inputs:{ngSwitch:"ngSwitch"}}),t}(),Lh=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this.ngSwitch=i,i._addCase(),this._view=new Dh(e,n)}return Object(g.a)(t,[{key:"ngDoCheck",value:function(){this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(mc),da(fc),da(Rh,1))},t.\u0275dir=Wt({type:t,selectors:[["","ngSwitchCase",""]],inputs:{ngSwitchCase:"ngSwitchCase"}}),t}(),Fh=function(){var t=function t(e,n,i){Object(m.a)(this,t),i._addDefault(new Dh(e,n))};return t.\u0275fac=function(e){return new(e||t)(da(mc),da(fc),da(Rh,1))},t.\u0275dir=Wt({type:t,selectors:[["","ngSwitchDefault",""]]}),t}(),Nh=function(){var t=function(){function t(e){Object(m.a)(this,t),this._localization=e,this._caseViews={}}return Object(g.a)(t,[{key:"addCase",value:function(t,e){this._caseViews[t]=e}},{key:"_updateView",value:function(){this._clearViews();var t=Object.keys(this._caseViews),e=Ch(this._switchValue,t,this._localization);this._activateView(this._caseViews[e])}},{key:"_clearViews",value:function(){this._activeView&&this._activeView.destroy()}},{key:"_activateView",value:function(t){t&&(this._activeView=t,this._activeView.create())}},{key:"ngPlural",set:function(t){this._switchValue=t,this._updateView()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(kh))},t.\u0275dir=Wt({type:t,selectors:[["","ngPlural",""]],inputs:{ngPlural:"ngPlural"}}),t}(),Bh=function(){var t=function t(e,n,i,r){Object(m.a)(this,t),this.value=e;var o=!isNaN(Number(e));r.addCase(o?"=".concat(e):e,new Dh(i,n))};return t.\u0275fac=function(e){return new(e||t)(fa("ngPluralCase"),da(fc),da(mc),da(Nh,1))},t.\u0275dir=Wt({type:t,selectors:[["","ngPluralCase",""]]}),t}(),Hh=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._ngEl=e,this._differs=n,this._renderer=i,this._ngStyle=null,this._differ=null}return Object(g.a)(t,[{key:"ngDoCheck",value:function(){if(this._differ){var t=this._differ.diff(this._ngStyle);t&&this._applyChanges(t)}}},{key:"_setStyle",value:function(t,e){var n=l(t.split("."),2),i=n[0],r=n[1];null!=(e=null!=e&&r?"".concat(e).concat(r):e)?this._renderer.setStyle(this._ngEl.nativeElement,i,e):this._renderer.removeStyle(this._ngEl.nativeElement,i)}},{key:"_applyChanges",value:function(t){var e=this;t.forEachRemovedItem((function(t){return e._setStyle(t.key,null)})),t.forEachAddedItem((function(t){return e._setStyle(t.key,t.currentValue)})),t.forEachChangedItem((function(t){return e._setStyle(t.key,t.currentValue)}))}},{key:"ngStyle",set:function(t){this._ngStyle=t,!this._differ&&t&&(this._differ=this._differs.find(t).create())}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(lc),da(Ks))},t.\u0275dir=Wt({type:t,selectors:[["","ngStyle",""]],inputs:{ngStyle:"ngStyle"}}),t}(),zh=function(){var t=function(){function t(e){Object(m.a)(this,t),this._viewContainerRef=e,this._viewRef=null,this.ngTemplateOutletContext=null,this.ngTemplateOutlet=null}return Object(g.a)(t,[{key:"ngOnChanges",value:function(t){if(this._shouldRecreateView(t)){var e=this._viewContainerRef;this._viewRef&&e.remove(e.indexOf(this._viewRef)),this._viewRef=this.ngTemplateOutlet?e.createEmbeddedView(this.ngTemplateOutlet,this.ngTemplateOutletContext):null}else this._viewRef&&this.ngTemplateOutletContext&&this._updateExistingContext(this.ngTemplateOutletContext)}},{key:"_shouldRecreateView",value:function(t){var e=t.ngTemplateOutletContext;return!!t.ngTemplateOutlet||e&&this._hasContextShapeChanged(e)}},{key:"_hasContextShapeChanged",value:function(t){var e=Object.keys(t.previousValue||{}),n=Object.keys(t.currentValue||{});if(e.length===n.length){var i,r=d(n);try{for(r.s();!(i=r.n()).done;)if(-1===e.indexOf(i.value))return!0}catch(o){r.e(o)}finally{r.f()}return!1}return!0}},{key:"_updateExistingContext",value:function(t){for(var e=0,n=Object.keys(t);e<n.length;e++){var i=n[e];this._viewRef.context[i]=this.ngTemplateOutletContext[i]}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(mc))},t.\u0275dir=Wt({type:t,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet"},features:[Ms]}),t}();function Vh(t,e){return Error("InvalidPipeArgument: '".concat(e,"' for pipe '").concat(W(t),"'"))}var Uh=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"createSubscription",value:function(t,e){return t.subscribe({next:e,error:function(t){throw t}})}},{key:"dispose",value:function(t){t.unsubscribe()}},{key:"onDestroy",value:function(t){t.unsubscribe()}}]),t}(),qh=new(function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"createSubscription",value:function(t,e){return t.then(e,(function(t){throw t}))}},{key:"dispose",value:function(t){}},{key:"onDestroy",value:function(t){}}]),t}()),Gh=new Uh,Wh=function(){var t=function(){function t(e){Object(m.a)(this,t),this._ref=e,this._latestValue=null,this._subscription=null,this._obj=null,this._strategy=null}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this._subscription&&this._dispose()}},{key:"transform",value:function(t){return this._obj?t!==this._obj?(this._dispose(),this.transform(t)):this._latestValue:(t&&this._subscribe(t),this._latestValue)}},{key:"_subscribe",value:function(t){var e=this;this._obj=t,this._strategy=this._selectStrategy(t),this._subscription=this._strategy.createSubscription(t,(function(n){return e._updateLatestValue(t,n)}))}},{key:"_selectStrategy",value:function(e){if(Ca(e))return qh;if(Sa(e))return Gh;throw Vh(t,e)}},{key:"_dispose",value:function(){this._strategy.dispose(this._subscription),this._latestValue=null,this._subscription=null,this._obj=null}},{key:"_updateLatestValue",value:function(t,e){t===this._obj&&(this._latestValue=e,this._ref.markForCheck())}}]),t}();return t.\u0275fac=function(e){return new(e||t)(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.Default,e=To(!0);if(null!=e||t&j.Optional)return e;throw new Error("No provider for ChangeDetectorRef!")}())},t.\u0275pipe=Kt({name:"async",type:t,pure:!1}),t}(),Kh=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"transform",value:function(e){if(!e)return e;if("string"!=typeof e)throw Vh(t,e);return e.toLowerCase()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"lowercase",type:t,pure:!0}),t}(),Xh=/(?:[A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF40\uDF42-\uDF49\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D])\S*/g,Yh=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"transform",value:function(e){if(!e)return e;if("string"!=typeof e)throw Vh(t,e);return e.replace(Xh,(function(t){return t[0].toUpperCase()+t.substr(1).toLowerCase()}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"titlecase",type:t,pure:!0}),t}(),Zh=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"transform",value:function(e){if(!e)return e;if("string"!=typeof e)throw Vh(t,e);return e.toUpperCase()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"uppercase",type:t,pure:!0}),t}(),Qh=function(){var t=function(){function t(e){Object(m.a)(this,t),this.locale=e}return Object(g.a)(t,[{key:"transform",value:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"mediumDate",i=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;if(null==e||""===e||e!=e)return null;try{return Ju(e,n,r||this.locale,i)}catch(o){throw Vh(t,o.message)}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(_l))},t.\u0275pipe=Kt({name:"date",type:t,pure:!0}),t}(),$h=/#/g,Jh=function(){var t=function(){function t(e){Object(m.a)(this,t),this._localization=e}return Object(g.a)(t,[{key:"transform",value:function(e,n,i){if(null==e)return"";if("object"!=typeof n||null===n)throw Vh(t,n);return n[Ch(e,Object.keys(n),this._localization,i)].replace($h,e.toString())}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(kh))},t.\u0275pipe=Kt({name:"i18nPlural",type:t,pure:!0}),t}(),td=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"transform",value:function(e,n){if(null==e)return"";if("object"!=typeof n||"string"!=typeof e)throw Vh(t,n);return n.hasOwnProperty(e)?n[e]:n.hasOwnProperty("other")?n.other:""}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"i18nSelect",type:t,pure:!0}),t}(),ed=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"transform",value:function(t){return JSON.stringify(t,null,2)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"json",type:t,pure:!1}),t}();function nd(t,e){return{key:t,value:e}}var id=function(){var t=function(){function t(e){Object(m.a)(this,t),this.differs=e,this.keyValues=[]}return Object(g.a)(t,[{key:"transform",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:rd;if(!t||!(t instanceof Map)&&"object"!=typeof t)return null;this.differ||(this.differ=this.differs.find(t).create());var i=this.differ.diff(t);return i&&(this.keyValues=[],i.forEachItem((function(t){e.keyValues.push(nd(t.key,t.currentValue))})),this.keyValues.sort(n)),this.keyValues}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(lc))},t.\u0275pipe=Kt({name:"keyvalue",type:t,pure:!1}),t}();function rd(t,e){var n=t.key,i=e.key;if(n===i)return 0;if(void 0===n)return 1;if(void 0===i)return-1;if(null===n)return 1;if(null===i)return-1;if("string"==typeof n&&"string"==typeof i)return n<i?-1:1;if("number"==typeof n&&"number"==typeof i)return n-i;if("boolean"==typeof n&&"boolean"==typeof i)return n<i?-1:1;var r=String(n),o=String(i);return r==o?0:r<o?-1:1}var od=function(){var t=function(){function t(e){Object(m.a)(this,t),this._locale=e}return Object(g.a)(t,[{key:"transform",value:function(e,n,i){if(cd(e))return null;i=i||this._locale;try{return function(t,e,n){return mh(t,vh(zu(e,Au.Decimal),Hu(e,Lu.MinusSign)),e,Lu.Group,Lu.Decimal,n)}(ld(e),i,n)}catch(r){throw Vh(t,r.message)}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(_l))},t.\u0275pipe=Kt({name:"number",type:t,pure:!0}),t}(),ad=function(){var t=function(){function t(e){Object(m.a)(this,t),this._locale=e}return Object(g.a)(t,[{key:"transform",value:function(e,n,i){if(cd(e))return null;i=i||this._locale;try{return function(t,e,n){return mh(t,vh(zu(e,Au.Percent),Hu(e,Lu.MinusSign)),e,Lu.Group,Lu.Decimal,n,!0).replace(new RegExp("%","g"),Hu(e,Lu.PercentSign))}(ld(e),i,n)}catch(r){throw Vh(t,r.message)}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(_l))},t.\u0275pipe=Kt({name:"percent",type:t,pure:!0}),t}(),sd=function(){var t=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"USD";Object(m.a)(this,t),this._locale=e,this._defaultCurrencyCode=n}return Object(g.a)(t,[{key:"transform",value:function(e,n){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"symbol",r=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0;if(cd(e))return null;o=o||this._locale,"boolean"==typeof i&&(console&&console.warn&&console.warn('Warning: the currency pipe has been changed in Angular v5. The symbolDisplay option (third parameter) is now a string instead of a boolean. The accepted values are "code", "symbol" or "symbol-narrow".'),i=i?"symbol":"code");var a=n||this._defaultCurrencyCode;"code"!==i&&(a="symbol"===i||"symbol-narrow"===i?Wu(a,"symbol"===i?"wide":"narrow",o):i);try{var s=ld(e);return gh(s,o,a,n,r)}catch(c){throw Vh(t,c.message)}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(_l),da(wl))},t.\u0275pipe=Kt({name:"currency",type:t,pure:!0}),t}();function cd(t){return null==t||""===t||t!=t}function ld(t){if("string"==typeof t&&!isNaN(Number(t)-parseFloat(t)))return Number(t);if("number"!=typeof t)throw new Error("".concat(t," is not a number"));return t}var ud=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"transform",value:function(e,n,i){if(null==e)return e;if(!this.supports(e))throw Vh(t,e);return e.slice(n,i)}},{key:"supports",value:function(t){return"string"==typeof t||Array.isArray(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"slice",type:t,pure:!1}),t}(),hd=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[{provide:kh,useClass:Sh}]}),t}();function dd(t){return"browser"===t}var fd,pd=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275prov=R({token:t,providedIn:"root",factory:function(){return new md(_t(du),window,_t(Gn))}}),t}(),md=function(){function t(e,n,i){Object(m.a)(this,t),this.document=e,this.window=n,this.errorHandler=i,this.offset=function(){return[0,0]}}return Object(g.a)(t,[{key:"setOffset",value:function(t){this.offset=Array.isArray(t)?function(){return t}:t}},{key:"getScrollPosition",value:function(){return this.supportScrollRestoration()?[this.window.scrollX,this.window.scrollY]:[0,0]}},{key:"scrollToPosition",value:function(t){this.supportScrollRestoration()&&this.window.scrollTo(t[0],t[1])}},{key:"scrollToAnchor",value:function(t){if(this.supportScrollRestoration()){t=this.window.CSS&&this.window.CSS.escape?this.window.CSS.escape(t):t.replace(/(\"|\'\ |:|\.|\[|\]|,|=)/g,"\\$1");try{var e=this.document.querySelector("#".concat(t));if(e)return void this.scrollToElement(e);var n=this.document.querySelector("[name='".concat(t,"']"));if(n)return void this.scrollToElement(n)}catch(i){this.errorHandler.handleError(i)}}}},{key:"setHistoryScrollRestoration",value:function(t){if(this.supportScrollRestoration()){var e=this.window.history;e&&e.scrollRestoration&&(e.scrollRestoration=t)}}},{key:"scrollToElement",value:function(t){var e=t.getBoundingClientRect(),n=e.left+this.window.pageXOffset,i=e.top+this.window.pageYOffset,r=this.offset();this.window.scrollTo(n-r[0],i-r[1])}},{key:"supportScrollRestoration",value:function(){try{return!!this.window&&!!this.window.scrollTo}catch(t){return!1}}}]),t}(),gd=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"getProperty",value:function(t,e){return t[e]}},{key:"log",value:function(t){window.console&&window.console.log&&window.console.log(t)}},{key:"logGroup",value:function(t){window.console&&window.console.group&&window.console.group(t)}},{key:"logGroupEnd",value:function(){window.console&&window.console.groupEnd&&window.console.groupEnd()}},{key:"onAndCancel",value:function(t,e,n){return t.addEventListener(e,n,!1),function(){t.removeEventListener(e,n,!1)}}},{key:"dispatchEvent",value:function(t,e){t.dispatchEvent(e)}},{key:"remove",value:function(t){return t.parentNode&&t.parentNode.removeChild(t),t}},{key:"getValue",value:function(t){return t.value}},{key:"createElement",value:function(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}},{key:"createHtmlDocument",value:function(){return document.implementation.createHTMLDocument("fakeTitle")}},{key:"getDefaultDocument",value:function(){return document}},{key:"isElementNode",value:function(t){return t.nodeType===Node.ELEMENT_NODE}},{key:"isShadowRoot",value:function(t){return t instanceof DocumentFragment}},{key:"getGlobalEventTarget",value:function(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}},{key:"getHistory",value:function(){return window.history}},{key:"getLocation",value:function(){return window.location}},{key:"getBaseHref",value:function(t){var e,n=vd||(vd=document.querySelector("base"))?vd.getAttribute("href"):null;return null==n?null:(e=n,fd||(fd=document.createElement("a")),fd.setAttribute("href",e),"/"===fd.pathname.charAt(0)?fd.pathname:"/"+fd.pathname)}},{key:"resetBaseElement",value:function(){vd=null}},{key:"getUserAgent",value:function(){return window.navigator.userAgent}},{key:"performanceNow",value:function(){return window.performance&&window.performance.now?window.performance.now():(new Date).getTime()}},{key:"supportsCookies",value:function(){return!0}},{key:"getCookie",value:function(t){return xh(document.cookie,t)}}],[{key:"makeCurrent",value:function(){var t;t=new n,lu||(lu=t)}}]),n}(function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.call(this)}return Object(g.a)(n,[{key:"supportsDOMEvents",value:function(){return!0}}]),n}(hu)),vd=null,bd=new ht("TRANSITION_ID"),yd=[{provide:hl,useFactory:function(t,e,n){return function(){n.get(dl).donePromise.then((function(){var n=uu();Array.prototype.slice.apply(e.querySelectorAll("style[ng-transition]")).filter((function(e){return e.getAttribute("ng-transition")===t})).forEach((function(t){return n.remove(t)}))}))}},deps:[bd,du,Xo],multi:!0}],_d=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"addToWindow",value:function(t){it.getAngularTestability=function(e){var n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=t.findTestabilityInTree(e,n);if(null==i)throw new Error("Could not find testability for element.");return i},it.getAllAngularTestabilities=function(){return t.getAllTestabilities()},it.getAllAngularRootElements=function(){return t.getAllRootElements()},it.frameworkStabilizers||(it.frameworkStabilizers=[]),it.frameworkStabilizers.push((function(t){var e=it.getAllAngularTestabilities(),n=e.length,i=!1,r=function(e){i=i||e,0==--n&&t(i)};e.forEach((function(t){t.whenStable(r)}))}))}},{key:"findTestabilityInTree",value:function(t,e,n){if(null==e)return null;var i=t.getTestability(e);return null!=i?i:n?uu().isShadowRoot(e)?this.findTestabilityInTree(t,e.host,!0):this.findTestabilityInTree(t,e.parentElement,!0):null}}],[{key:"init",value:function(){var e;e=new t,Ul=e}}]),t}(),wd=new ht("EventManagerPlugins"),kd=function(){var t=function(){function t(e,n){var i=this;Object(m.a)(this,t),this._zone=n,this._eventNameToPlugin=new Map,e.forEach((function(t){return t.manager=i})),this._plugins=e.slice().reverse()}return Object(g.a)(t,[{key:"addEventListener",value:function(t,e,n){return this._findPluginFor(e).addEventListener(t,e,n)}},{key:"addGlobalEventListener",value:function(t,e,n){return this._findPluginFor(e).addGlobalEventListener(t,e,n)}},{key:"getZone",value:function(){return this._zone}},{key:"_findPluginFor",value:function(t){var e=this._eventNameToPlugin.get(t);if(e)return e;for(var n=this._plugins,i=0;i<n.length;i++){var r=n[i];if(r.supports(t))return this._eventNameToPlugin.set(t,r),r}throw new Error("No event manager plugin found for event ".concat(t))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(wd),_t(jl))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Cd=function(){function t(e){Object(m.a)(this,t),this._doc=e}return Object(g.a)(t,[{key:"addGlobalEventListener",value:function(t,e,n){var i=uu().getGlobalEventTarget(this._doc,t);if(!i)throw new Error("Unsupported event target ".concat(i," for event ").concat(e));return this.addEventListener(i,e,n)}}]),t}(),Sd=function(){var t=function(){function t(){Object(m.a)(this,t),this._stylesSet=new Set}return Object(g.a)(t,[{key:"addStyles",value:function(t){var e=this,n=new Set;t.forEach((function(t){e._stylesSet.has(t)||(e._stylesSet.add(t),n.add(t))})),this.onStylesAdded(n)}},{key:"onStylesAdded",value:function(t){}},{key:"getAllStyles",value:function(){return Array.from(this._stylesSet)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),xd=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this))._doc=t,i._hostNodes=new Set,i._styleNodes=new Set,i._hostNodes.add(t.head),i}return Object(g.a)(n,[{key:"_addStylesToHost",value:function(t,e){var n=this;t.forEach((function(t){var i=n._doc.createElement("style");i.textContent=t,n._styleNodes.add(e.appendChild(i))}))}},{key:"addHost",value:function(t){this._addStylesToHost(this._stylesSet,t),this._hostNodes.add(t)}},{key:"removeHost",value:function(t){this._hostNodes.delete(t)}},{key:"onStylesAdded",value:function(t){var e=this;this._hostNodes.forEach((function(n){return e._addStylesToHost(t,n)}))}},{key:"ngOnDestroy",value:function(){this._styleNodes.forEach((function(t){return uu().remove(t)}))}}]),n}(Sd);return t.\u0275fac=function(e){return new(e||t)(_t(du))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Od={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},Md=/%COMP%/g,Td="_nghost-".concat("%COMP%"),Ed="_ngcontent-".concat("%COMP%");function Pd(t,e,n){for(var i=0;i<e.length;i++){var r=e[i];Array.isArray(r)?Pd(t,r,n):(r=r.replace(Md,t),n.push(r))}return n}function Ad(t){return function(e){if("__ngUnwrap__"===e)return t;!1===t(e)&&(e.preventDefault(),e.returnValue=!1)}}var jd=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this.eventManager=e,this.sharedStylesHost=n,this.appId=i,this.rendererByCompId=new Map,this.defaultRenderer=new Id(e)}return Object(g.a)(t,[{key:"createRenderer",value:function(t,e){if(!t||!e)return this.defaultRenderer;switch(e.encapsulation){case Lt.Emulated:var n=this.rendererByCompId.get(e.id);return n||(n=new Dd(this.eventManager,this.sharedStylesHost,e,this.appId),this.rendererByCompId.set(e.id,n)),n.applyToHost(t),n;case Lt.Native:case Lt.ShadowDom:return new Rd(this.eventManager,this.sharedStylesHost,t,e);default:if(!this.rendererByCompId.has(e.id)){var i=Pd(e.id,e.styles,[]);this.sharedStylesHost.addStyles(i),this.rendererByCompId.set(e.id,this.defaultRenderer)}return this.defaultRenderer}}},{key:"begin",value:function(){}},{key:"end",value:function(){}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(kd),_t(xd),_t(fl))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Id=function(){function t(e){Object(m.a)(this,t),this.eventManager=e,this.data=Object.create(null)}return Object(g.a)(t,[{key:"destroy",value:function(){}},{key:"createElement",value:function(t,e){return e?document.createElementNS(Od[e]||e,t):document.createElement(t)}},{key:"createComment",value:function(t){return document.createComment(t)}},{key:"createText",value:function(t){return document.createTextNode(t)}},{key:"appendChild",value:function(t,e){t.appendChild(e)}},{key:"insertBefore",value:function(t,e,n){t&&t.insertBefore(e,n)}},{key:"removeChild",value:function(t,e){t&&t.removeChild(e)}},{key:"selectRootElement",value:function(t,e){var n="string"==typeof t?document.querySelector(t):t;if(!n)throw new Error('The selector "'.concat(t,'" did not match any elements'));return e||(n.textContent=""),n}},{key:"parentNode",value:function(t){return t.parentNode}},{key:"nextSibling",value:function(t){return t.nextSibling}},{key:"setAttribute",value:function(t,e,n,i){if(i){e=i+":"+e;var r=Od[i];r?t.setAttributeNS(r,e,n):t.setAttribute(e,n)}else t.setAttribute(e,n)}},{key:"removeAttribute",value:function(t,e,n){if(n){var i=Od[n];i?t.removeAttributeNS(i,e):t.removeAttribute("".concat(n,":").concat(e))}else t.removeAttribute(e)}},{key:"addClass",value:function(t,e){t.classList.add(e)}},{key:"removeClass",value:function(t,e){t.classList.remove(e)}},{key:"setStyle",value:function(t,e,n,i){i&Ws.DashCase?t.style.setProperty(e,n,i&Ws.Important?"important":""):t.style[e]=n}},{key:"removeStyle",value:function(t,e,n){n&Ws.DashCase?t.style.removeProperty(e):t.style[e]=""}},{key:"setProperty",value:function(t,e,n){t[e]=n}},{key:"setValue",value:function(t,e){t.nodeValue=e}},{key:"listen",value:function(t,e,n){return"string"==typeof t?this.eventManager.addGlobalEventListener(t,e,Ad(n)):this.eventManager.addEventListener(t,e,Ad(n))}}]),t}(),Dd=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;Object(m.a)(this,n),(a=e.call(this,t)).component=r;var s=Pd(o+"-"+r.id,r.styles,[]);return i.addStyles(s),a.contentAttr=Ed.replace(Md,o+"-"+r.id),a.hostAttr=function(t){return Td.replace(Md,t)}(o+"-"+r.id),a}return Object(g.a)(n,[{key:"applyToHost",value:function(t){Object(o.a)(Object(a.a)(n.prototype),"setAttribute",this).call(this,t,this.hostAttr,"")}},{key:"createElement",value:function(t,e){var i=Object(o.a)(Object(a.a)(n.prototype),"createElement",this).call(this,t,e);return Object(o.a)(Object(a.a)(n.prototype),"setAttribute",this).call(this,i,this.contentAttr,""),i}}]),n}(Id),Rd=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;Object(m.a)(this,n),(a=e.call(this,t)).sharedStylesHost=i,a.hostEl=r,a.component=o,a.shadowRoot=o.encapsulation===Lt.ShadowDom?r.attachShadow({mode:"open"}):r.createShadowRoot(),a.sharedStylesHost.addHost(a.shadowRoot);for(var s=Pd(o.id,o.styles,[]),c=0;c<s.length;c++){var l=document.createElement("style");l.textContent=s[c],a.shadowRoot.appendChild(l)}return a}return Object(g.a)(n,[{key:"nodeOrShadowRoot",value:function(t){return t===this.hostEl?this.shadowRoot:t}},{key:"destroy",value:function(){this.sharedStylesHost.removeHost(this.shadowRoot)}},{key:"appendChild",value:function(t,e){return Object(o.a)(Object(a.a)(n.prototype),"appendChild",this).call(this,this.nodeOrShadowRoot(t),e)}},{key:"insertBefore",value:function(t,e,i){return Object(o.a)(Object(a.a)(n.prototype),"insertBefore",this).call(this,this.nodeOrShadowRoot(t),e,i)}},{key:"removeChild",value:function(t,e){return Object(o.a)(Object(a.a)(n.prototype),"removeChild",this).call(this,this.nodeOrShadowRoot(t),e)}},{key:"parentNode",value:function(t){return this.nodeOrShadowRoot(Object(o.a)(Object(a.a)(n.prototype),"parentNode",this).call(this,this.nodeOrShadowRoot(t)))}}]),n}(Id),Ld=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){return Object(m.a)(this,n),e.call(this,t)}return Object(g.a)(n,[{key:"supports",value:function(t){return!0}},{key:"addEventListener",value:function(t,e,n){var i=this;return t.addEventListener(e,n,!1),function(){return i.removeEventListener(t,e,n)}}},{key:"removeEventListener",value:function(t,e,n){return t.removeEventListener(e,n)}}]),n}(Cd);return t.\u0275fac=function(e){return new(e||t)(_t(du))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Fd=["alt","control","meta","shift"],Nd={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Bd={A:"1",B:"2",C:"3",D:"4",E:"5",F:"6",G:"7",H:"8",I:"9",J:"*",K:"+",M:"-",N:".",O:"/","`":"0","\x90":"NumLock"},Hd={alt:function(t){return t.altKey},control:function(t){return t.ctrlKey},meta:function(t){return t.metaKey},shift:function(t){return t.shiftKey}},zd=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){return Object(m.a)(this,n),e.call(this,t)}return Object(g.a)(n,[{key:"supports",value:function(t){return null!=n.parseEventName(t)}},{key:"addEventListener",value:function(t,e,i){var r=n.parseEventName(e),o=n.eventCallback(r.fullKey,i,this.manager.getZone());return this.manager.getZone().runOutsideAngular((function(){return uu().onAndCancel(t,r.domEventName,o)}))}}],[{key:"parseEventName",value:function(t){var e=t.toLowerCase().split("."),i=e.shift();if(0===e.length||"keydown"!==i&&"keyup"!==i)return null;var r=n._normalizeKey(e.pop()),o="";if(Fd.forEach((function(t){var n=e.indexOf(t);n>-1&&(e.splice(n,1),o+=t+".")})),o+=r,0!=e.length||0===r.length)return null;var a={};return a.domEventName=i,a.fullKey=o,a}},{key:"getEventFullKey",value:function(t){var e="",n=function(t){var e=t.key;if(null==e){if(null==(e=t.keyIdentifier))return"Unidentified";e.startsWith("U+")&&(e=String.fromCharCode(parseInt(e.substring(2),16)),3===t.location&&Bd.hasOwnProperty(e)&&(e=Bd[e]))}return Nd[e]||e}(t);return" "===(n=n.toLowerCase())?n="space":"."===n&&(n="dot"),Fd.forEach((function(i){i!=n&&(0,Hd[i])(t)&&(e+=i+".")})),e+=n}},{key:"eventCallback",value:function(t,e,i){return function(r){n.getEventFullKey(r)===t&&i.runGuarded((function(){return e(r)}))}}},{key:"_normalizeKey",value:function(t){switch(t){case"esc":return"escape";default:return t}}}]),n}(Cd);return t.\u0275fac=function(e){return new(e||t)(_t(du))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Vd=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:function(){return _t(Ud)},token:t,providedIn:"root"}),t}(),Ud=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this))._doc=t,i}return Object(g.a)(n,[{key:"sanitize",value:function(t,e){if(null==e)return null;switch(t){case Mi.NONE:return e;case Mi.HTML:return Jn(e,"HTML")?$n(e):xi(this._doc,String(e));case Mi.STYLE:return Jn(e,"Style")?$n(e):e;case Mi.SCRIPT:if(Jn(e,"Script"))return $n(e);throw new Error("unsafe value used in a script context");case Mi.URL:return ti(e),Jn(e,"URL")?$n(e):ci(String(e));case Mi.RESOURCE_URL:if(Jn(e,"ResourceURL"))return $n(e);throw new Error("unsafe value used in a resource URL context (see http://g.co/ng/security#xss)");default:throw new Error("Unexpected SecurityContext ".concat(t," (see http://g.co/ng/security#xss)"))}}},{key:"bypassSecurityTrustHtml",value:function(t){return new Kn(t)}},{key:"bypassSecurityTrustStyle",value:function(t){return new Xn(t)}},{key:"bypassSecurityTrustScript",value:function(t){return new Yn(t)}},{key:"bypassSecurityTrustUrl",value:function(t){return new Zn(t)}},{key:"bypassSecurityTrustResourceUrl",value:function(t){return new Qn(t)}}]),n}(Vd);return t.\u0275fac=function(e){return new(e||t)(_t(du))},t.\u0275prov=R({factory:function(){return t=_t(dt),new Ud(t.get(du));var t},token:t,providedIn:"root"}),t}(),qd=Xl(au,"browser",[{provide:vl,useValue:"browser"},{provide:gl,useValue:function(){gd.makeCurrent(),_d.init()},multi:!0},{provide:du,useFactory:function(){return function(t){re=t}(document),document},deps:[]}]),Gd=[[],{provide:Io,useValue:"root"},{provide:Gn,useFactory:function(){return new Gn},deps:[]},{provide:wd,useClass:Ld,multi:!0,deps:[du,jl,vl]},{provide:wd,useClass:zd,multi:!0,deps:[du]},[],{provide:jd,useClass:jd,deps:[kd,xd,fl]},{provide:Gs,useExisting:jd},{provide:Sd,useExisting:xd},{provide:xd,useClass:xd,deps:[du]},{provide:zl,useClass:zl,deps:[jl]},{provide:kd,useClass:kd,deps:[wd,jl]},[]],Wd=function(){var t=function(){function t(e){if(Object(m.a)(this,t),e)throw new Error("BrowserModule has already been loaded. If you need access to common directives such as NgIf and NgFor from a lazy loaded module, import CommonModule instead.")}return Object(g.a)(t,null,[{key:"withServerTransition",value:function(e){return{ngModule:t,providers:[{provide:fl,useValue:e.appId},{provide:bd,useExisting:fl},yd]}}}]),t}();return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)(_t(t,12))},providers:Gd,imports:[hd,cu]}),t}();function Kd(){return new Yd(_t(du))}var Xd,Yd=function(){var t=function(){function t(e){Object(m.a)(this,t),this._doc=e}return Object(g.a)(t,[{key:"getTitle",value:function(){return this._doc.title}},{key:"setTitle",value:function(t){this._doc.title=t||""}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(du))},t.\u0275prov=R({factory:Kd,token:t,providedIn:"root"}),t}(),Zd="undefined"!=typeof window&&window||{},Qd=function t(e,n){Object(m.a)(this,t),this.msPerTick=e,this.numTicks=n},$d=function(){function t(e){Object(m.a)(this,t),this.appRef=e.injector.get(Jl)}return Object(g.a)(t,[{key:"timeChangeDetection",value:function(t){var e=t&&t.record,n=null!=Zd.console.profile;e&&n&&Zd.console.profile("Change Detection");for(var i=uu().performanceNow(),r=0;r<5||uu().performanceNow()-i<500;)this.appRef.tick(),r++;var o=uu().performanceNow();e&&n&&Zd.console.profileEnd("Change Detection");var a=(o-i)/r;return Zd.console.log("ran ".concat(r," change detection cycles")),Zd.console.log("".concat(a.toFixed(2)," ms per check")),new Qd(a,r)}}]),t}();n("md7G"),"undefined"!=typeof window&&window,"undefined"!=typeof self&&"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&self,"undefined"!=typeof global&&global,"_nghost-".concat("%COMP%"),"_ngcontent-".concat("%COMP%"),"[^".concat(" \f\n\r\t\v\u1680\u180e\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff","]"),"[".concat(" \f\n\r\t\v\u1680\u180e\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff","]{2,}"),h(Xd={},4,4),h(Xd,1,1),h(Xd,2,2),h(Xd,0,0),h(Xd,3,3);var Jd=n("cp0P"),tf=n("Cfvw"),ef=n("lJxs"),nf=new ht("NgValueAccessor"),rf={provide:nf,useExisting:Y((function(){return of})),multi:!0},of=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._renderer=e,this._elementRef=n,this.onChange=function(t){},this.onTouched=function(){}}return Object(g.a)(t,[{key:"writeValue",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"checked",t)}},{key:"registerOnChange",value:function(t){this.onChange=t}},{key:"registerOnTouched",value:function(t){this.onTouched=t}},{key:"setDisabledState",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Ks),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["input","type","checkbox","formControlName",""],["input","type","checkbox","formControl",""],["input","type","checkbox","ngModel",""]],hostBindings:function(t,e){1&t&&xa("change",(function(t){return e.onChange(t.target.checked)}))("blur",(function(){return e.onTouched()}))},features:[Ns([rf])]}),t}(),af={provide:nf,useExisting:Y((function(){return cf})),multi:!0},sf=new ht("CompositionEventMode"),cf=function(){var t=function(){function t(e,n,i){var r;Object(m.a)(this,t),this._renderer=e,this._elementRef=n,this._compositionMode=i,this.onChange=function(t){},this.onTouched=function(){},this._composing=!1,null==this._compositionMode&&(this._compositionMode=(r=uu()?uu().getUserAgent():"",!/android (\d+)/.test(r.toLowerCase())))}return Object(g.a)(t,[{key:"writeValue",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"value",null==t?"":t)}},{key:"registerOnChange",value:function(t){this.onChange=t}},{key:"registerOnTouched",value:function(t){this.onTouched=t}},{key:"setDisabledState",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",t)}},{key:"_handleInput",value:function(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}},{key:"_compositionStart",value:function(){this._composing=!0}},{key:"_compositionEnd",value:function(t){this._composing=!1,this._compositionMode&&this.onChange(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Ks),da(Us),da(sf,8))},t.\u0275dir=Wt({type:t,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(t,e){1&t&&xa("input",(function(t){return e._handleInput(t.target.value)}))("blur",(function(){return e.onTouched()}))("compositionstart",(function(){return e._compositionStart()}))("compositionend",(function(t){return e._compositionEnd(t.target.value)}))},features:[Ns([af])]}),t}(),lf=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"reset",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;this.control&&this.control.reset(t)}},{key:"hasError",value:function(t,e){return!!this.control&&this.control.hasError(t,e)}},{key:"getError",value:function(t,e){return this.control?this.control.getError(t,e):null}},{key:"value",get:function(){return this.control?this.control.value:null}},{key:"valid",get:function(){return this.control?this.control.valid:null}},{key:"invalid",get:function(){return this.control?this.control.invalid:null}},{key:"pending",get:function(){return this.control?this.control.pending:null}},{key:"disabled",get:function(){return this.control?this.control.disabled:null}},{key:"enabled",get:function(){return this.control?this.control.enabled:null}},{key:"errors",get:function(){return this.control?this.control.errors:null}},{key:"pristine",get:function(){return this.control?this.control.pristine:null}},{key:"dirty",get:function(){return this.control?this.control.dirty:null}},{key:"touched",get:function(){return this.control?this.control.touched:null}},{key:"status",get:function(){return this.control?this.control.status:null}},{key:"untouched",get:function(){return this.control?this.control.untouched:null}},{key:"statusChanges",get:function(){return this.control?this.control.statusChanges:null}},{key:"valueChanges",get:function(){return this.control?this.control.valueChanges:null}},{key:"path",get:function(){return null}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t}),t}(),uf=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"formDirective",get:function(){return null}},{key:"path",get:function(){return null}}]),n}(lf);return t.\u0275fac=function(e){return hf(e||t)},t.\u0275dir=Wt({type:t,features:[ws]}),t}(),hf=zn(uf);function df(){throw new Error("unimplemented")}var ff=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments))._parent=null,t.name=null,t.valueAccessor=null,t._rawValidators=[],t._rawAsyncValidators=[],t}return Object(g.a)(n,[{key:"validator",get:function(){return df()}},{key:"asyncValidator",get:function(){return df()}}]),n}(lf),pf=function(){function t(e){Object(m.a)(this,t),this._cd=e}return Object(g.a)(t,[{key:"ngClassUntouched",get:function(){return!!this._cd.control&&this._cd.control.untouched}},{key:"ngClassTouched",get:function(){return!!this._cd.control&&this._cd.control.touched}},{key:"ngClassPristine",get:function(){return!!this._cd.control&&this._cd.control.pristine}},{key:"ngClassDirty",get:function(){return!!this._cd.control&&this._cd.control.dirty}},{key:"ngClassValid",get:function(){return!!this._cd.control&&this._cd.control.valid}},{key:"ngClassInvalid",get:function(){return!!this._cd.control&&this._cd.control.invalid}},{key:"ngClassPending",get:function(){return!!this._cd.control&&this._cd.control.pending}}]),t}(),mf=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){return Object(m.a)(this,n),e.call(this,t)}return n}(pf);return t.\u0275fac=function(e){return new(e||t)(da(ff,2))},t.\u0275dir=Wt({type:t,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(t,e){2&t&&Qa("ng-untouched",e.ngClassUntouched)("ng-touched",e.ngClassTouched)("ng-pristine",e.ngClassPristine)("ng-dirty",e.ngClassDirty)("ng-valid",e.ngClassValid)("ng-invalid",e.ngClassInvalid)("ng-pending",e.ngClassPending)},features:[ws]}),t}(),gf=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){return Object(m.a)(this,n),e.call(this,t)}return n}(pf);return t.\u0275fac=function(e){return new(e||t)(da(uf,2))},t.\u0275dir=Wt({type:t,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:14,hostBindings:function(t,e){2&t&&Qa("ng-untouched",e.ngClassUntouched)("ng-touched",e.ngClassTouched)("ng-pristine",e.ngClassPristine)("ng-dirty",e.ngClassDirty)("ng-valid",e.ngClassValid)("ng-invalid",e.ngClassInvalid)("ng-pending",e.ngClassPending)},features:[ws]}),t}();function vf(t){return null==t||0===t.length}function bf(t){return null!=t&&"number"==typeof t.length}var yf=new ht("NgValidators"),_f=new ht("NgAsyncValidators"),wf=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,kf=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"min",value:function(t){return function(e){if(vf(e.value)||vf(t))return null;var n=parseFloat(e.value);return!isNaN(n)&&n<t?{min:{min:t,actual:e.value}}:null}}},{key:"max",value:function(t){return function(e){if(vf(e.value)||vf(t))return null;var n=parseFloat(e.value);return!isNaN(n)&&n>t?{max:{max:t,actual:e.value}}:null}}},{key:"required",value:function(t){return vf(t.value)?{required:!0}:null}},{key:"requiredTrue",value:function(t){return!0===t.value?null:{required:!0}}},{key:"email",value:function(t){return vf(t.value)||wf.test(t.value)?null:{email:!0}}},{key:"minLength",value:function(t){return function(e){return vf(e.value)||!bf(e.value)?null:e.value.length<t?{minlength:{requiredLength:t,actualLength:e.value.length}}:null}}},{key:"maxLength",value:function(t){return function(e){return bf(e.value)&&e.value.length>t?{maxlength:{requiredLength:t,actualLength:e.value.length}}:null}}},{key:"pattern",value:function(e){return e?("string"==typeof e?(i="","^"!==e.charAt(0)&&(i+="^"),i+=e,"$"!==e.charAt(e.length-1)&&(i+="$"),n=new RegExp(i)):(i=e.toString(),n=e),function(t){if(vf(t.value))return null;var e=t.value;return n.test(e)?null:{pattern:{requiredPattern:i,actualValue:e}}}):t.nullValidator;var n,i}},{key:"nullValidator",value:function(t){return null}},{key:"compose",value:function(t){if(!t)return null;var e=t.filter(Cf);return 0==e.length?null:function(t){return xf(function(t,e){return e.map((function(e){return e(t)}))}(t,e))}}},{key:"composeAsync",value:function(t){if(!t)return null;var e=t.filter(Cf);return 0==e.length?null:function(t){var n=function(t,e){return e.map((function(e){return e(t)}))}(t,e).map(Sf);return Object(Jd.a)(n).pipe(Object(ef.a)(xf))}}}]),t}();function Cf(t){return null!=t}function Sf(t){var e=Ca(t)?Object(tf.a)(t):t;if(!Sa(e))throw new Error("Expected validator to return Promise or Observable.");return e}function xf(t){var e={};return t.forEach((function(t){e=null!=t?Object.assign(Object.assign({},e),t):e})),0===Object.keys(e).length?null:e}function Of(t){return t.validate?function(e){return t.validate(e)}:t}function Mf(t){return t.validate?function(e){return t.validate(e)}:t}var Tf={provide:nf,useExisting:Y((function(){return Ef})),multi:!0},Ef=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._renderer=e,this._elementRef=n,this.onChange=function(t){},this.onTouched=function(){}}return Object(g.a)(t,[{key:"writeValue",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"value",null==t?"":t)}},{key:"registerOnChange",value:function(t){this.onChange=function(e){t(""==e?null:parseFloat(e))}}},{key:"registerOnTouched",value:function(t){this.onTouched=t}},{key:"setDisabledState",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Ks),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["input","type","number","formControlName",""],["input","type","number","formControl",""],["input","type","number","ngModel",""]],hostBindings:function(t,e){1&t&&xa("input",(function(t){return e.onChange(t.target.value)}))("blur",(function(){return e.onTouched()}))},features:[Ns([Tf])]}),t}(),Pf={provide:nf,useExisting:Y((function(){return jf})),multi:!0},Af=function(){var t=function(){function t(){Object(m.a)(this,t),this._accessors=[]}return Object(g.a)(t,[{key:"add",value:function(t,e){this._accessors.push([t,e])}},{key:"remove",value:function(t){for(var e=this._accessors.length-1;e>=0;--e)if(this._accessors[e][1]===t)return void this._accessors.splice(e,1)}},{key:"select",value:function(t){var e=this;this._accessors.forEach((function(n){e._isSameGroup(n,t)&&n[1]!==t&&n[1].fireUncheck(t.value)}))}},{key:"_isSameGroup",value:function(t,e){return!!t[0].control&&t[0]._parent===e._control._parent&&t[1].name===e.name}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),jf=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._renderer=e,this._elementRef=n,this._registry=i,this._injector=r,this.onChange=function(){},this.onTouched=function(){}}return Object(g.a)(t,[{key:"ngOnInit",value:function(){this._control=this._injector.get(ff),this._checkName(),this._registry.add(this._control,this)}},{key:"ngOnDestroy",value:function(){this._registry.remove(this)}},{key:"writeValue",value:function(t){this._state=t===this.value,this._renderer.setProperty(this._elementRef.nativeElement,"checked",this._state)}},{key:"registerOnChange",value:function(t){var e=this;this._fn=t,this.onChange=function(){t(e.value),e._registry.select(e)}}},{key:"fireUncheck",value:function(t){this.writeValue(t)}},{key:"registerOnTouched",value:function(t){this.onTouched=t}},{key:"setDisabledState",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",t)}},{key:"_checkName",value:function(){this.name&&this.formControlName&&this.name!==this.formControlName&&this._throwNameError(),!this.name&&this.formControlName&&(this.name=this.formControlName)}},{key:"_throwNameError",value:function(){throw new Error('\n If you define both a name and a formControlName attribute on your radio button, their values\n must match. Ex: <input type="radio" formControlName="food" name="food">\n ')}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Ks),da(Us),da(Af),da(Xo))},t.\u0275dir=Wt({type:t,selectors:[["input","type","radio","formControlName",""],["input","type","radio","formControl",""],["input","type","radio","ngModel",""]],hostBindings:function(t,e){1&t&&xa("change",(function(){return e.onChange()}))("blur",(function(){return e.onTouched()}))},inputs:{name:"name",formControlName:"formControlName",value:"value"},features:[Ns([Pf])]}),t}(),If={provide:nf,useExisting:Y((function(){return Df})),multi:!0},Df=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._renderer=e,this._elementRef=n,this.onChange=function(t){},this.onTouched=function(){}}return Object(g.a)(t,[{key:"writeValue",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"value",parseFloat(t))}},{key:"registerOnChange",value:function(t){this.onChange=function(e){t(""==e?null:parseFloat(e))}}},{key:"registerOnTouched",value:function(t){this.onTouched=t}},{key:"setDisabledState",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Ks),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["input","type","range","formControlName",""],["input","type","range","formControl",""],["input","type","range","ngModel",""]],hostBindings:function(t,e){1&t&&xa("change",(function(t){return e.onChange(t.target.value)}))("input",(function(t){return e.onChange(t.target.value)}))("blur",(function(){return e.onTouched()}))},features:[Ns([If])]}),t}(),Rf='\n <div [formGroup]="myGroup">\n <input formControlName="firstName">\n </div>\n\n In your class:\n\n this.myGroup = new FormGroup({\n firstName: new FormControl()\n });',Lf='\n <div [formGroup]="myGroup">\n <div formGroupName="person">\n <input formControlName="firstName">\n </div>\n </div>\n\n In your class:\n\n this.myGroup = new FormGroup({\n person: new FormGroup({ firstName: new FormControl() })\n });',Ff='\n <form>\n <div ngModelGroup="person">\n <input [(ngModel)]="person.name" name="firstName">\n </div>\n </form>',Nf=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"controlParentException",value:function(){throw new Error("formControlName must be used with a parent formGroup directive. You'll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n Example:\n\n ".concat(Rf))}},{key:"ngModelGroupException",value:function(){throw new Error('formControlName cannot be used with an ngModelGroup parent. It is only compatible with parents\n that also have a "form" prefix: formGroupName, formArrayName, or formGroup.\n\n Option 1: Update the parent to be formGroupName (reactive form strategy)\n\n '.concat(Lf,"\n\n Option 2: Use ngModel instead of formControlName (template-driven strategy)\n\n ").concat(Ff))}},{key:"missingFormException",value:function(){throw new Error("formGroup expects a FormGroup instance. Please pass one in.\n\n Example:\n\n ".concat(Rf))}},{key:"groupParentException",value:function(){throw new Error("formGroupName must be used with a parent formGroup directive. You'll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n Example:\n\n ".concat(Lf))}},{key:"arrayParentException",value:function(){throw new Error("formArrayName must be used with a parent formGroup directive. You'll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n Example:\n\n ".concat('\n <div [formGroup]="myGroup">\n <div formArrayName="cities">\n <div *ngFor="let city of cityArray.controls; index as i">\n <input [formControlName]="i">\n </div>\n </div>\n </div>\n\n In your class:\n\n this.cityArray = new FormArray([new FormControl(\'SF\')]);\n this.myGroup = new FormGroup({\n cities: this.cityArray\n });'))}},{key:"disabledAttrWarning",value:function(){console.warn("\n It looks like you're using the disabled attribute with a reactive form directive. If you set disabled to true\n when you set up this control in your component class, the disabled attribute will actually be set in the DOM for\n you. We recommend using this approach to avoid 'changed after checked' errors.\n\n Example:\n form = new FormGroup({\n first: new FormControl({value: 'Nancy', disabled: true}, Validators.required),\n last: new FormControl('Drew', Validators.required)\n });\n ")}},{key:"ngModelWarning",value:function(t){console.warn("\n It looks like you're using ngModel on the same form field as ".concat(t,".\n Support for using the ngModel input property and ngModelChange event with\n reactive form directives has been deprecated in Angular v6 and will be removed\n in a future version of Angular.\n\n For more information on this, see our API docs here:\n https://angular.io/api/forms/").concat("formControl"===t?"FormControlDirective":"FormControlName","#use-with-ngmodel\n "))}}]),t}(),Bf={provide:nf,useExisting:Y((function(){return zf})),multi:!0};function Hf(t,e){return null==t?"".concat(e):(e&&"object"==typeof e&&(e="Object"),"".concat(t,": ").concat(e).slice(0,50))}var zf=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._renderer=e,this._elementRef=n,this._optionMap=new Map,this._idCounter=0,this.onChange=function(t){},this.onTouched=function(){},this._compareWith=Object.is}return Object(g.a)(t,[{key:"writeValue",value:function(t){this.value=t;var e=this._getOptionId(t);null==e&&this._renderer.setProperty(this._elementRef.nativeElement,"selectedIndex",-1);var n=Hf(e,t);this._renderer.setProperty(this._elementRef.nativeElement,"value",n)}},{key:"registerOnChange",value:function(t){var e=this;this.onChange=function(n){e.value=e._getOptionValue(n),t(e.value)}}},{key:"registerOnTouched",value:function(t){this.onTouched=t}},{key:"setDisabledState",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",t)}},{key:"_registerOption",value:function(){return(this._idCounter++).toString()}},{key:"_getOptionId",value:function(t){for(var e=0,n=Array.from(this._optionMap.keys());e<n.length;e++){var i=n[e];if(this._compareWith(this._optionMap.get(i),t))return i}return null}},{key:"_getOptionValue",value:function(t){var e=function(t){return t.split(":")[0]}(t);return this._optionMap.has(e)?this._optionMap.get(e):t}},{key:"compareWith",set:function(t){if("function"!=typeof t)throw new Error("compareWith must be a function, but received ".concat(JSON.stringify(t)));this._compareWith=t}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Ks),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["select","formControlName","",3,"multiple",""],["select","formControl","",3,"multiple",""],["select","ngModel","",3,"multiple",""]],hostBindings:function(t,e){1&t&&xa("change",(function(t){return e.onChange(t.target.value)}))("blur",(function(){return e.onTouched()}))},inputs:{compareWith:"compareWith"},features:[Ns([Bf])]}),t}(),Vf=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._element=e,this._renderer=n,this._select=i,this._select&&(this.id=this._select._registerOption())}return Object(g.a)(t,[{key:"_setElementValue",value:function(t){this._renderer.setProperty(this._element.nativeElement,"value",t)}},{key:"ngOnDestroy",value:function(){this._select&&(this._select._optionMap.delete(this.id),this._select.writeValue(this._select.value))}},{key:"ngValue",set:function(t){null!=this._select&&(this._select._optionMap.set(this.id,t),this._setElementValue(Hf(this.id,t)),this._select.writeValue(this._select.value))}},{key:"value",set:function(t){this._setElementValue(t),this._select&&this._select.writeValue(this._select.value)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Ks),da(zf,9))},t.\u0275dir=Wt({type:t,selectors:[["option"]],inputs:{ngValue:"ngValue",value:"value"}}),t}(),Uf={provide:nf,useExisting:Y((function(){return Gf})),multi:!0};function qf(t,e){return null==t?"".concat(e):("string"==typeof e&&(e="'".concat(e,"'")),e&&"object"==typeof e&&(e="Object"),"".concat(t,": ").concat(e).slice(0,50))}var Gf=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._renderer=e,this._elementRef=n,this._optionMap=new Map,this._idCounter=0,this.onChange=function(t){},this.onTouched=function(){},this._compareWith=Object.is}return Object(g.a)(t,[{key:"writeValue",value:function(t){var e,n=this;if(this.value=t,Array.isArray(t)){var i=t.map((function(t){return n._getOptionId(t)}));e=function(t,e){t._setSelected(i.indexOf(e.toString())>-1)}}else e=function(t,e){t._setSelected(!1)};this._optionMap.forEach(e)}},{key:"registerOnChange",value:function(t){var e=this;this.onChange=function(n){var i=[];if(void 0!==n.selectedOptions)for(var r=n.selectedOptions,o=0;o<r.length;o++){var a=r.item(o),s=e._getOptionValue(a.value);i.push(s)}else for(var c=n.options,l=0;l<c.length;l++){var u=c.item(l);if(u.selected){var h=e._getOptionValue(u.value);i.push(h)}}e.value=i,t(i)}}},{key:"registerOnTouched",value:function(t){this.onTouched=t}},{key:"setDisabledState",value:function(t){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",t)}},{key:"_registerOption",value:function(t){var e=(this._idCounter++).toString();return this._optionMap.set(e,t),e}},{key:"_getOptionId",value:function(t){for(var e=0,n=Array.from(this._optionMap.keys());e<n.length;e++){var i=n[e];if(this._compareWith(this._optionMap.get(i)._value,t))return i}return null}},{key:"_getOptionValue",value:function(t){var e=function(t){return t.split(":")[0]}(t);return this._optionMap.has(e)?this._optionMap.get(e)._value:t}},{key:"compareWith",set:function(t){if("function"!=typeof t)throw new Error("compareWith must be a function, but received ".concat(JSON.stringify(t)));this._compareWith=t}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Ks),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["select","multiple","","formControlName",""],["select","multiple","","formControl",""],["select","multiple","","ngModel",""]],hostBindings:function(t,e){1&t&&xa("change",(function(t){return e.onChange(t.target)}))("blur",(function(){return e.onTouched()}))},inputs:{compareWith:"compareWith"},features:[Ns([Uf])]}),t}(),Wf=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._element=e,this._renderer=n,this._select=i,this._select&&(this.id=this._select._registerOption(this))}return Object(g.a)(t,[{key:"_setElementValue",value:function(t){this._renderer.setProperty(this._element.nativeElement,"value",t)}},{key:"_setSelected",value:function(t){this._renderer.setProperty(this._element.nativeElement,"selected",t)}},{key:"ngOnDestroy",value:function(){this._select&&(this._select._optionMap.delete(this.id),this._select.writeValue(this._select.value))}},{key:"ngValue",set:function(t){null!=this._select&&(this._value=t,this._setElementValue(qf(this.id,t)),this._select.writeValue(this._select.value))}},{key:"value",set:function(t){this._select?(this._value=t,this._setElementValue(qf(this.id,t)),this._select.writeValue(this._select.value)):this._setElementValue(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Ks),da(Gf,9))},t.\u0275dir=Wt({type:t,selectors:[["option"]],inputs:{ngValue:"ngValue",value:"value"}}),t}();function Kf(t,e){return[].concat(Object(u.a)(e.path),[t])}function Xf(t,e){t||$f(e,"Cannot find control with"),e.valueAccessor||$f(e,"No value accessor for form control with"),t.validator=kf.compose([t.validator,e.validator]),t.asyncValidator=kf.composeAsync([t.asyncValidator,e.asyncValidator]),e.valueAccessor.writeValue(t.value),function(t,e){e.valueAccessor.registerOnChange((function(n){t._pendingValue=n,t._pendingChange=!0,t._pendingDirty=!0,"change"===t.updateOn&&Yf(t,e)}))}(t,e),function(t,e){t.registerOnChange((function(t,n){e.valueAccessor.writeValue(t),n&&e.viewToModelUpdate(t)}))}(t,e),function(t,e){e.valueAccessor.registerOnTouched((function(){t._pendingTouched=!0,"blur"===t.updateOn&&t._pendingChange&&Yf(t,e),"submit"!==t.updateOn&&t.markAsTouched()}))}(t,e),e.valueAccessor.setDisabledState&&t.registerOnDisabledChange((function(t){e.valueAccessor.setDisabledState(t)})),e._rawValidators.forEach((function(e){e.registerOnValidatorChange&&e.registerOnValidatorChange((function(){return t.updateValueAndValidity()}))})),e._rawAsyncValidators.forEach((function(e){e.registerOnValidatorChange&&e.registerOnValidatorChange((function(){return t.updateValueAndValidity()}))}))}function Yf(t,e){t._pendingDirty&&t.markAsDirty(),t.setValue(t._pendingValue,{emitModelToViewChange:!1}),e.viewToModelUpdate(t._pendingValue),t._pendingChange=!1}function Zf(t,e){null==t&&$f(e,"Cannot find control with"),t.validator=kf.compose([t.validator,e.validator]),t.asyncValidator=kf.composeAsync([t.asyncValidator,e.asyncValidator])}function Qf(t){return $f(t,"There is no FormControl instance attached to form control element with")}function $f(t,e){var n;throw n=t.path.length>1?"path: '".concat(t.path.join(" -> "),"'"):t.path[0]?"name: '".concat(t.path,"'"):"unspecified name attribute",new Error("".concat(e," ").concat(n))}function Jf(t){return null!=t?kf.compose(t.map(Of)):null}function tp(t){return null!=t?kf.composeAsync(t.map(Mf)):null}function ep(t,e){if(!t.hasOwnProperty("model"))return!1;var n=t.model;return!!n.isFirstChange()||!Object.is(e,n.currentValue)}var np=[of,Df,Ef,zf,Gf,jf];function ip(t,e){t._syncPendingControls(),e.forEach((function(t){var e=t.control;"submit"===e.updateOn&&e._pendingChange&&(t.viewToModelUpdate(e._pendingValue),e._pendingChange=!1)}))}function rp(t,e){if(!e)return null;Array.isArray(e)||$f(t,"Value accessor was not provided as an array for form control with");var n=void 0,i=void 0,r=void 0;return e.forEach((function(e){var o;e.constructor===cf?n=e:(o=e,np.some((function(t){return o.constructor===t}))?(i&&$f(t,"More than one built-in value accessor matches form control with"),i=e):(r&&$f(t,"More than one custom value accessor matches form control with"),r=e))})),r||i||n||($f(t,"No valid value accessor for form control with"),null)}function op(t,e){var n=t.indexOf(e);n>-1&&t.splice(n,1)}function ap(t,e,n,i){ii()&&"never"!==i&&((null!==i&&"once"!==i||e._ngModelWarningSentOnce)&&("always"!==i||n._ngModelWarningSent)||(Nf.ngModelWarning(t),e._ngModelWarningSentOnce=!0,n._ngModelWarningSent=!0))}function sp(t){var e=lp(t)?t.validators:t;return Array.isArray(e)?Jf(e):e||null}function cp(t,e){var n=lp(e)?e.asyncValidators:t;return Array.isArray(n)?tp(n):n||null}function lp(t){return null!=t&&!Array.isArray(t)&&"object"==typeof t}var up=function(){function t(e,n){Object(m.a)(this,t),this.validator=e,this.asyncValidator=n,this._onCollectionChange=function(){},this.pristine=!0,this.touched=!1,this._onDisabledChange=[]}return Object(g.a)(t,[{key:"setValidators",value:function(t){this.validator=sp(t)}},{key:"setAsyncValidators",value:function(t){this.asyncValidator=cp(t)}},{key:"clearValidators",value:function(){this.validator=null}},{key:"clearAsyncValidators",value:function(){this.asyncValidator=null}},{key:"markAsTouched",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.touched=!0,this._parent&&!t.onlySelf&&this._parent.markAsTouched(t)}},{key:"markAllAsTouched",value:function(){this.markAsTouched({onlySelf:!0}),this._forEachChild((function(t){return t.markAllAsTouched()}))}},{key:"markAsUntouched",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.touched=!1,this._pendingTouched=!1,this._forEachChild((function(t){t.markAsUntouched({onlySelf:!0})})),this._parent&&!t.onlySelf&&this._parent._updateTouched(t)}},{key:"markAsDirty",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.pristine=!1,this._parent&&!t.onlySelf&&this._parent.markAsDirty(t)}},{key:"markAsPristine",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.pristine=!0,this._pendingDirty=!1,this._forEachChild((function(t){t.markAsPristine({onlySelf:!0})})),this._parent&&!t.onlySelf&&this._parent._updatePristine(t)}},{key:"markAsPending",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.status="PENDING",!1!==t.emitEvent&&this.statusChanges.emit(this.status),this._parent&&!t.onlySelf&&this._parent.markAsPending(t)}},{key:"disable",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this._parentMarkedDirty(t.onlySelf);this.status="DISABLED",this.errors=null,this._forEachChild((function(e){e.disable(Object.assign(Object.assign({},t),{onlySelf:!0}))})),this._updateValue(),!1!==t.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(Object.assign(Object.assign({},t),{skipPristineCheck:e})),this._onDisabledChange.forEach((function(t){return t(!0)}))}},{key:"enable",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this._parentMarkedDirty(t.onlySelf);this.status="VALID",this._forEachChild((function(e){e.enable(Object.assign(Object.assign({},t),{onlySelf:!0}))})),this.updateValueAndValidity({onlySelf:!0,emitEvent:t.emitEvent}),this._updateAncestors(Object.assign(Object.assign({},t),{skipPristineCheck:e})),this._onDisabledChange.forEach((function(t){return t(!1)}))}},{key:"_updateAncestors",value:function(t){this._parent&&!t.onlySelf&&(this._parent.updateValueAndValidity(t),t.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}},{key:"setParent",value:function(t){this._parent=t}},{key:"updateValueAndValidity",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),"VALID"!==this.status&&"PENDING"!==this.status||this._runAsyncValidator(t.emitEvent)),!1!==t.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!t.onlySelf&&this._parent.updateValueAndValidity(t)}},{key:"_updateTreeValidity",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{emitEvent:!0};this._forEachChild((function(e){return e._updateTreeValidity(t)})),this.updateValueAndValidity({onlySelf:!0,emitEvent:t.emitEvent})}},{key:"_setInitialStatus",value:function(){this.status=this._allControlsDisabled()?"DISABLED":"VALID"}},{key:"_runValidator",value:function(){return this.validator?this.validator(this):null}},{key:"_runAsyncValidator",value:function(t){var e=this;if(this.asyncValidator){this.status="PENDING";var n=Sf(this.asyncValidator(this));this._asyncValidationSubscription=n.subscribe((function(n){return e.setErrors(n,{emitEvent:t})}))}}},{key:"_cancelExistingSubscription",value:function(){this._asyncValidationSubscription&&this._asyncValidationSubscription.unsubscribe()}},{key:"setErrors",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.errors=t,this._updateControlsErrors(!1!==e.emitEvent)}},{key:"get",value:function(t){return function(t,e,n){if(null==e)return null;if(Array.isArray(e)||(e=e.split(".")),Array.isArray(e)&&0===e.length)return null;var i=t;return e.forEach((function(t){i=i instanceof dp?i.controls.hasOwnProperty(t)?i.controls[t]:null:i instanceof fp&&i.at(t)||null})),i}(this,t)}},{key:"getError",value:function(t,e){var n=e?this.get(e):this;return n&&n.errors?n.errors[t]:null}},{key:"hasError",value:function(t,e){return!!this.getError(t,e)}},{key:"_updateControlsErrors",value:function(t){this.status=this._calculateStatus(),t&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(t)}},{key:"_initObservables",value:function(){this.valueChanges=new Uc,this.statusChanges=new Uc}},{key:"_calculateStatus",value:function(){return this._allControlsDisabled()?"DISABLED":this.errors?"INVALID":this._anyControlsHaveStatus("PENDING")?"PENDING":this._anyControlsHaveStatus("INVALID")?"INVALID":"VALID"}},{key:"_anyControlsHaveStatus",value:function(t){return this._anyControls((function(e){return e.status===t}))}},{key:"_anyControlsDirty",value:function(){return this._anyControls((function(t){return t.dirty}))}},{key:"_anyControlsTouched",value:function(){return this._anyControls((function(t){return t.touched}))}},{key:"_updatePristine",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.pristine=!this._anyControlsDirty(),this._parent&&!t.onlySelf&&this._parent._updatePristine(t)}},{key:"_updateTouched",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.touched=this._anyControlsTouched(),this._parent&&!t.onlySelf&&this._parent._updateTouched(t)}},{key:"_isBoxedValue",value:function(t){return"object"==typeof t&&null!==t&&2===Object.keys(t).length&&"value"in t&&"disabled"in t}},{key:"_registerOnCollectionChange",value:function(t){this._onCollectionChange=t}},{key:"_setUpdateStrategy",value:function(t){lp(t)&&null!=t.updateOn&&(this._updateOn=t.updateOn)}},{key:"_parentMarkedDirty",value:function(t){return!t&&this._parent&&this._parent.dirty&&!this._parent._anyControlsDirty()}},{key:"parent",get:function(){return this._parent}},{key:"valid",get:function(){return"VALID"===this.status}},{key:"invalid",get:function(){return"INVALID"===this.status}},{key:"pending",get:function(){return"PENDING"==this.status}},{key:"disabled",get:function(){return"DISABLED"===this.status}},{key:"enabled",get:function(){return"DISABLED"!==this.status}},{key:"dirty",get:function(){return!this.pristine}},{key:"untouched",get:function(){return!this.touched}},{key:"updateOn",get:function(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}},{key:"root",get:function(){for(var t=this;t._parent;)t=t._parent;return t}}]),t}(),hp=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,r=arguments.length>1?arguments[1]:void 0,o=arguments.length>2?arguments[2]:void 0;return Object(m.a)(this,n),(t=e.call(this,sp(r),cp(o,r)))._onChange=[],t._applyFormState(i),t._setUpdateStrategy(r),t.updateValueAndValidity({onlySelf:!0,emitEvent:!1}),t._initObservables(),t}return Object(g.a)(n,[{key:"setValue",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.value=this._pendingValue=t,this._onChange.length&&!1!==n.emitModelToViewChange&&this._onChange.forEach((function(t){return t(e.value,!1!==n.emitViewToModelChange)})),this.updateValueAndValidity(n)}},{key:"patchValue",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.setValue(t,e)}},{key:"reset",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this._applyFormState(t),this.markAsPristine(e),this.markAsUntouched(e),this.setValue(this.value,e),this._pendingChange=!1}},{key:"_updateValue",value:function(){}},{key:"_anyControls",value:function(t){return!1}},{key:"_allControlsDisabled",value:function(){return this.disabled}},{key:"registerOnChange",value:function(t){this._onChange.push(t)}},{key:"_clearChangeFns",value:function(){this._onChange=[],this._onDisabledChange=[],this._onCollectionChange=function(){}}},{key:"registerOnDisabledChange",value:function(t){this._onDisabledChange.push(t)}},{key:"_forEachChild",value:function(t){}},{key:"_syncPendingControls",value:function(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}},{key:"_applyFormState",value:function(t){this._isBoxedValue(t)?(this.value=this._pendingValue=t.value,t.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=t}}]),n}(up),dp=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,sp(i),cp(r,i))).controls=t,o._initObservables(),o._setUpdateStrategy(i),o._setUpControls(),o.updateValueAndValidity({onlySelf:!0,emitEvent:!1}),o}return Object(g.a)(n,[{key:"registerControl",value:function(t,e){return this.controls[t]?this.controls[t]:(this.controls[t]=e,e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange),e)}},{key:"addControl",value:function(t,e){this.registerControl(t,e),this.updateValueAndValidity(),this._onCollectionChange()}},{key:"removeControl",value:function(t){this.controls[t]&&this.controls[t]._registerOnCollectionChange((function(){})),delete this.controls[t],this.updateValueAndValidity(),this._onCollectionChange()}},{key:"setControl",value:function(t,e){this.controls[t]&&this.controls[t]._registerOnCollectionChange((function(){})),delete this.controls[t],e&&this.registerControl(t,e),this.updateValueAndValidity(),this._onCollectionChange()}},{key:"contains",value:function(t){return this.controls.hasOwnProperty(t)&&this.controls[t].enabled}},{key:"setValue",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this._checkAllValuesPresent(t),Object.keys(t).forEach((function(i){e._throwIfControlMissing(i),e.controls[i].setValue(t[i],{onlySelf:!0,emitEvent:n.emitEvent})})),this.updateValueAndValidity(n)}},{key:"patchValue",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object.keys(t).forEach((function(i){e.controls[i]&&e.controls[i].patchValue(t[i],{onlySelf:!0,emitEvent:n.emitEvent})})),this.updateValueAndValidity(n)}},{key:"reset",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this._forEachChild((function(n,i){n.reset(t[i],{onlySelf:!0,emitEvent:e.emitEvent})})),this._updatePristine(e),this._updateTouched(e),this.updateValueAndValidity(e)}},{key:"getRawValue",value:function(){return this._reduceChildren({},(function(t,e,n){return t[n]=e instanceof hp?e.value:e.getRawValue(),t}))}},{key:"_syncPendingControls",value:function(){var t=this._reduceChildren(!1,(function(t,e){return!!e._syncPendingControls()||t}));return t&&this.updateValueAndValidity({onlySelf:!0}),t}},{key:"_throwIfControlMissing",value:function(t){if(!Object.keys(this.controls).length)throw new Error("\n There are no form controls registered with this group yet. If you're using ngModel,\n you may want to check next tick (e.g. use setTimeout).\n ");if(!this.controls[t])throw new Error("Cannot find form control with name: ".concat(t,"."))}},{key:"_forEachChild",value:function(t){var e=this;Object.keys(this.controls).forEach((function(n){return t(e.controls[n],n)}))}},{key:"_setUpControls",value:function(){var t=this;this._forEachChild((function(e){e.setParent(t),e._registerOnCollectionChange(t._onCollectionChange)}))}},{key:"_updateValue",value:function(){this.value=this._reduceValue()}},{key:"_anyControls",value:function(t){for(var e=0,n=Object.keys(this.controls);e<n.length;e++){var i=n[e],r=this.controls[i];if(this.contains(i)&&t(r))return!0}return!1}},{key:"_reduceValue",value:function(){var t=this;return this._reduceChildren({},(function(e,n,i){return(n.enabled||t.disabled)&&(e[i]=n.value),e}))}},{key:"_reduceChildren",value:function(t,e){var n=t;return this._forEachChild((function(t,i){n=e(n,t,i)})),n}},{key:"_allControlsDisabled",value:function(){for(var t=0,e=Object.keys(this.controls);t<e.length;t++)if(this.controls[e[t]].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}},{key:"_checkAllValuesPresent",value:function(t){this._forEachChild((function(e,n){if(void 0===t[n])throw new Error("Must supply a value for form control with name: '".concat(n,"'."))}))}}]),n}(up),fp=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,sp(i),cp(r,i))).controls=t,o._initObservables(),o._setUpdateStrategy(i),o._setUpControls(),o.updateValueAndValidity({onlySelf:!0,emitEvent:!1}),o}return Object(g.a)(n,[{key:"at",value:function(t){return this.controls[t]}},{key:"push",value:function(t){this.controls.push(t),this._registerControl(t),this.updateValueAndValidity(),this._onCollectionChange()}},{key:"insert",value:function(t,e){this.controls.splice(t,0,e),this._registerControl(e),this.updateValueAndValidity()}},{key:"removeAt",value:function(t){this.controls[t]&&this.controls[t]._registerOnCollectionChange((function(){})),this.controls.splice(t,1),this.updateValueAndValidity()}},{key:"setControl",value:function(t,e){this.controls[t]&&this.controls[t]._registerOnCollectionChange((function(){})),this.controls.splice(t,1),e&&(this.controls.splice(t,0,e),this._registerControl(e)),this.updateValueAndValidity(),this._onCollectionChange()}},{key:"setValue",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this._checkAllValuesPresent(t),t.forEach((function(t,i){e._throwIfControlMissing(i),e.at(i).setValue(t,{onlySelf:!0,emitEvent:n.emitEvent})})),this.updateValueAndValidity(n)}},{key:"patchValue",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t.forEach((function(t,i){e.at(i)&&e.at(i).patchValue(t,{onlySelf:!0,emitEvent:n.emitEvent})})),this.updateValueAndValidity(n)}},{key:"reset",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this._forEachChild((function(n,i){n.reset(t[i],{onlySelf:!0,emitEvent:e.emitEvent})})),this._updatePristine(e),this._updateTouched(e),this.updateValueAndValidity(e)}},{key:"getRawValue",value:function(){return this.controls.map((function(t){return t instanceof hp?t.value:t.getRawValue()}))}},{key:"clear",value:function(){this.controls.length<1||(this._forEachChild((function(t){return t._registerOnCollectionChange((function(){}))})),this.controls.splice(0),this.updateValueAndValidity())}},{key:"_syncPendingControls",value:function(){var t=this.controls.reduce((function(t,e){return!!e._syncPendingControls()||t}),!1);return t&&this.updateValueAndValidity({onlySelf:!0}),t}},{key:"_throwIfControlMissing",value:function(t){if(!this.controls.length)throw new Error("\n There are no form controls registered with this array yet. If you're using ngModel,\n you may want to check next tick (e.g. use setTimeout).\n ");if(!this.at(t))throw new Error("Cannot find form control at index ".concat(t))}},{key:"_forEachChild",value:function(t){this.controls.forEach((function(e,n){t(e,n)}))}},{key:"_updateValue",value:function(){var t=this;this.value=this.controls.filter((function(e){return e.enabled||t.disabled})).map((function(t){return t.value}))}},{key:"_anyControls",value:function(t){return this.controls.some((function(e){return e.enabled&&t(e)}))}},{key:"_setUpControls",value:function(){var t=this;this._forEachChild((function(e){return t._registerControl(e)}))}},{key:"_checkAllValuesPresent",value:function(t){this._forEachChild((function(e,n){if(void 0===t[n])throw new Error("Must supply a value for form control at index: ".concat(n,"."))}))}},{key:"_allControlsDisabled",value:function(){var t,e=d(this.controls);try{for(e.s();!(t=e.n()).done;)if(t.value.enabled)return!1}catch(n){e.e(n)}finally{e.f()}return this.controls.length>0||this.disabled}},{key:"_registerControl",value:function(t){t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange)}},{key:"length",get:function(){return this.controls.length}}]),n}(up),pp={provide:uf,useExisting:Y((function(){return gp}))},mp=function(){return Promise.resolve(null)}(),gp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this)).submitted=!1,r._directives=[],r.ngSubmit=new Uc,r.form=new dp({},Jf(t),tp(i)),r}return Object(g.a)(n,[{key:"ngAfterViewInit",value:function(){this._setUpdateStrategy()}},{key:"addControl",value:function(t){var e=this;mp.then((function(){var n=e._findContainer(t.path);t.control=n.registerControl(t.name,t.control),Xf(t.control,t),t.control.updateValueAndValidity({emitEvent:!1}),e._directives.push(t)}))}},{key:"getControl",value:function(t){return this.form.get(t.path)}},{key:"removeControl",value:function(t){var e=this;mp.then((function(){var n=e._findContainer(t.path);n&&n.removeControl(t.name),op(e._directives,t)}))}},{key:"addFormGroup",value:function(t){var e=this;mp.then((function(){var n=e._findContainer(t.path),i=new dp({});Zf(i,t),n.registerControl(t.name,i),i.updateValueAndValidity({emitEvent:!1})}))}},{key:"removeFormGroup",value:function(t){var e=this;mp.then((function(){var n=e._findContainer(t.path);n&&n.removeControl(t.name)}))}},{key:"getFormGroup",value:function(t){return this.form.get(t.path)}},{key:"updateModel",value:function(t,e){var n=this;mp.then((function(){n.form.get(t.path).setValue(e)}))}},{key:"setValue",value:function(t){this.control.setValue(t)}},{key:"onSubmit",value:function(t){return this.submitted=!0,ip(this.form,this._directives),this.ngSubmit.emit(t),!1}},{key:"onReset",value:function(){this.resetForm()}},{key:"resetForm",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;this.form.reset(t),this.submitted=!1}},{key:"_setUpdateStrategy",value:function(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}},{key:"_findContainer",value:function(t){return t.pop(),t.length?this.form.get(t):this.form}},{key:"formDirective",get:function(){return this}},{key:"control",get:function(){return this.form}},{key:"path",get:function(){return[]}},{key:"controls",get:function(){return this.form.controls}}]),n}(uf);return t.\u0275fac=function(e){return new(e||t)(da(yf,10),da(_f,10))},t.\u0275dir=Wt({type:t,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(t,e){1&t&&xa("submit",(function(t){return e.onSubmit(t)}))("reset",(function(){return e.onReset()}))},inputs:{options:["ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Ns([pp]),ws]}),t}(),vp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"ngOnInit",value:function(){this._checkParentType(),this.formDirective.addFormGroup(this)}},{key:"ngOnDestroy",value:function(){this.formDirective&&this.formDirective.removeFormGroup(this)}},{key:"_checkParentType",value:function(){}},{key:"control",get:function(){return this.formDirective.getFormGroup(this)}},{key:"path",get:function(){return Kf(null==this.name?this.name:this.name.toString(),this._parent)}},{key:"formDirective",get:function(){return this._parent?this._parent.formDirective:null}},{key:"validator",get:function(){return Jf(this._validators)}},{key:"asyncValidator",get:function(){return tp(this._asyncValidators)}}]),n}(uf);return t.\u0275fac=function(e){return bp(e||t)},t.\u0275dir=Wt({type:t,features:[ws]}),t}(),bp=zn(vp),yp=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"modelParentException",value:function(){throw new Error('\n ngModel cannot be used to register form controls with a parent formGroup directive. Try using\n formGroup\'s partner directive "formControlName" instead. Example:\n\n '.concat(Rf,"\n\n Or, if you'd like to avoid registering this form control, indicate that it's standalone in ngModelOptions:\n\n Example:\n\n ").concat('\n <div [formGroup]="myGroup">\n <input formControlName="firstName">\n <input [(ngModel)]="showMoreControls" [ngModelOptions]="{standalone: true}">\n </div>\n '))}},{key:"formGroupNameException",value:function(){throw new Error("\n ngModel cannot be used to register form controls with a parent formGroupName or formArrayName directive.\n\n Option 1: Use formControlName instead of ngModel (reactive strategy):\n\n ".concat(Lf,"\n\n Option 2: Update ngModel's parent be ngModelGroup (template-driven strategy):\n\n ").concat(Ff))}},{key:"missingNameException",value:function(){throw new Error('If ngModel is used within a form tag, either the name attribute must be set or the form\n control must be defined as \'standalone\' in ngModelOptions.\n\n Example 1: <input [(ngModel)]="person.firstName" name="first">\n Example 2: <input [(ngModel)]="person.firstName" [ngModelOptions]="{standalone: true}">')}},{key:"modelGroupParentException",value:function(){throw new Error("\n ngModelGroup cannot be used with a parent formGroup directive.\n\n Option 1: Use formGroupName instead of ngModelGroup (reactive strategy):\n\n ".concat(Lf,"\n\n Option 2: Use a regular form tag instead of the formGroup directive (template-driven strategy):\n\n ").concat(Ff))}}]),t}(),_p={provide:uf,useExisting:Y((function(){return wp}))},wp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this))._parent=t,o._validators=i,o._asyncValidators=r,o}return Object(g.a)(n,[{key:"_checkParentType",value:function(){this._parent instanceof n||this._parent instanceof gp||yp.modelGroupParentException()}}]),n}(vp);return t.\u0275fac=function(e){return new(e||t)(da(uf,5),da(yf,10),da(_f,10))},t.\u0275dir=Wt({type:t,selectors:[["","ngModelGroup",""]],inputs:{name:["ngModelGroup","name"]},exportAs:["ngModelGroup"],features:[Ns([_p]),ws]}),t}(),kp={provide:ff,useExisting:Y((function(){return Sp}))},Cp=function(){return Promise.resolve(null)}(),Sp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this)).control=new hp,a._registered=!1,a.update=new Uc,a._parent=t,a._rawValidators=i||[],a._rawAsyncValidators=r||[],a.valueAccessor=rp(Object(s.a)(a),o),a}return Object(g.a)(n,[{key:"ngOnChanges",value:function(t){this._checkForErrors(),this._registered||this._setUpControl(),"isDisabled"in t&&this._updateDisabled(t),ep(t,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}},{key:"ngOnDestroy",value:function(){this.formDirective&&this.formDirective.removeControl(this)}},{key:"viewToModelUpdate",value:function(t){this.viewModel=t,this.update.emit(t)}},{key:"_setUpControl",value:function(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}},{key:"_setUpdateStrategy",value:function(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}},{key:"_isStandalone",value:function(){return!this._parent||!(!this.options||!this.options.standalone)}},{key:"_setUpStandalone",value:function(){Xf(this.control,this),this.control.updateValueAndValidity({emitEvent:!1})}},{key:"_checkForErrors",value:function(){this._isStandalone()||this._checkParentType(),this._checkName()}},{key:"_checkParentType",value:function(){!(this._parent instanceof wp)&&this._parent instanceof vp?yp.formGroupNameException():this._parent instanceof wp||this._parent instanceof gp||yp.modelParentException()}},{key:"_checkName",value:function(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()||this.name||yp.missingNameException()}},{key:"_updateValue",value:function(t){var e=this;Cp.then((function(){e.control.setValue(t,{emitViewToModelChange:!1})}))}},{key:"_updateDisabled",value:function(t){var e=this,n=t.isDisabled.currentValue,i=""===n||n&&"false"!==n;Cp.then((function(){i&&!e.control.disabled?e.control.disable():!i&&e.control.disabled&&e.control.enable()}))}},{key:"path",get:function(){return this._parent?Kf(this.name,this._parent):[this.name]}},{key:"formDirective",get:function(){return this._parent?this._parent.formDirective:null}},{key:"validator",get:function(){return Jf(this._rawValidators)}},{key:"asyncValidator",get:function(){return tp(this._rawAsyncValidators)}}]),n}(ff);return t.\u0275fac=function(e){return new(e||t)(da(uf,9),da(yf,10),da(_f,10),da(nf,10))},t.\u0275dir=Wt({type:t,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:["disabled","isDisabled"],model:["ngModel","model"],options:["ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],features:[Ns([kp]),ws,Ms]}),t}(),xp=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""]}),t}(),Op=new ht("NgModelWithFormControlWarning"),Mp={provide:ff,useExisting:Y((function(){return Tp}))},Tp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this))._ngModelWarningConfig=o,a.update=new Uc,a._ngModelWarningSent=!1,a._rawValidators=t||[],a._rawAsyncValidators=i||[],a.valueAccessor=rp(Object(s.a)(a),r),a}return Object(g.a)(n,[{key:"ngOnChanges",value:function(t){this._isControlChanged(t)&&(Xf(this.form,this),this.control.disabled&&this.valueAccessor.setDisabledState&&this.valueAccessor.setDisabledState(!0),this.form.updateValueAndValidity({emitEvent:!1})),ep(t,this.viewModel)&&(ap("formControl",n,this,this._ngModelWarningConfig),this.form.setValue(this.model),this.viewModel=this.model)}},{key:"viewToModelUpdate",value:function(t){this.viewModel=t,this.update.emit(t)}},{key:"_isControlChanged",value:function(t){return t.hasOwnProperty("form")}},{key:"isDisabled",set:function(t){Nf.disabledAttrWarning()}},{key:"path",get:function(){return[]}},{key:"validator",get:function(){return Jf(this._rawValidators)}},{key:"asyncValidator",get:function(){return tp(this._rawAsyncValidators)}},{key:"control",get:function(){return this.form}}]),n}(ff);return t.\u0275fac=function(e){return new(e||t)(da(yf,10),da(_f,10),da(nf,10),da(Op,8))},t.\u0275dir=Wt({type:t,selectors:[["","formControl",""]],inputs:{isDisabled:["disabled","isDisabled"],form:["formControl","form"],model:["ngModel","model"]},outputs:{update:"ngModelChange"},exportAs:["ngForm"],features:[Ns([Mp]),ws,Ms]}),t._ngModelWarningSentOnce=!1,t}(),Ep={provide:uf,useExisting:Y((function(){return Pp}))},Pp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this))._validators=t,r._asyncValidators=i,r.submitted=!1,r.directives=[],r.form=null,r.ngSubmit=new Uc,r}return Object(g.a)(n,[{key:"ngOnChanges",value:function(t){this._checkFormPresent(),t.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations())}},{key:"addControl",value:function(t){var e=this.form.get(t.path);return Xf(e,t),e.updateValueAndValidity({emitEvent:!1}),this.directives.push(t),e}},{key:"getControl",value:function(t){return this.form.get(t.path)}},{key:"removeControl",value:function(t){op(this.directives,t)}},{key:"addFormGroup",value:function(t){var e=this.form.get(t.path);Zf(e,t),e.updateValueAndValidity({emitEvent:!1})}},{key:"removeFormGroup",value:function(t){}},{key:"getFormGroup",value:function(t){return this.form.get(t.path)}},{key:"addFormArray",value:function(t){var e=this.form.get(t.path);Zf(e,t),e.updateValueAndValidity({emitEvent:!1})}},{key:"removeFormArray",value:function(t){}},{key:"getFormArray",value:function(t){return this.form.get(t.path)}},{key:"updateModel",value:function(t,e){this.form.get(t.path).setValue(e)}},{key:"onSubmit",value:function(t){return this.submitted=!0,ip(this.form,this.directives),this.ngSubmit.emit(t),!1}},{key:"onReset",value:function(){this.resetForm()}},{key:"resetForm",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;this.form.reset(t),this.submitted=!1}},{key:"_updateDomValue",value:function(){var t=this;this.directives.forEach((function(e){var n=t.form.get(e.path);e.control!==n&&(function(t,e){e.valueAccessor.registerOnChange((function(){return Qf(e)})),e.valueAccessor.registerOnTouched((function(){return Qf(e)})),e._rawValidators.forEach((function(t){t.registerOnValidatorChange&&t.registerOnValidatorChange(null)})),e._rawAsyncValidators.forEach((function(t){t.registerOnValidatorChange&&t.registerOnValidatorChange(null)})),t&&t._clearChangeFns()}(e.control,e),n&&Xf(n,e),e.control=n)})),this.form._updateTreeValidity({emitEvent:!1})}},{key:"_updateRegistrations",value:function(){var t=this;this.form._registerOnCollectionChange((function(){return t._updateDomValue()})),this._oldForm&&this._oldForm._registerOnCollectionChange((function(){})),this._oldForm=this.form}},{key:"_updateValidators",value:function(){var t=Jf(this._validators);this.form.validator=kf.compose([this.form.validator,t]);var e=tp(this._asyncValidators);this.form.asyncValidator=kf.composeAsync([this.form.asyncValidator,e])}},{key:"_checkFormPresent",value:function(){this.form||Nf.missingFormException()}},{key:"formDirective",get:function(){return this}},{key:"control",get:function(){return this.form}},{key:"path",get:function(){return[]}}]),n}(uf);return t.\u0275fac=function(e){return new(e||t)(da(yf,10),da(_f,10))},t.\u0275dir=Wt({type:t,selectors:[["","formGroup",""]],hostBindings:function(t,e){1&t&&xa("submit",(function(t){return e.onSubmit(t)}))("reset",(function(){return e.onReset()}))},inputs:{form:["formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Ns([Ep]),ws,Ms]}),t}(),Ap={provide:uf,useExisting:Y((function(){return jp}))},jp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this))._parent=t,o._validators=i,o._asyncValidators=r,o}return Object(g.a)(n,[{key:"_checkParentType",value:function(){Rp(this._parent)&&Nf.groupParentException()}}]),n}(vp);return t.\u0275fac=function(e){return new(e||t)(da(uf,13),da(yf,10),da(_f,10))},t.\u0275dir=Wt({type:t,selectors:[["","formGroupName",""]],inputs:{name:["formGroupName","name"]},features:[Ns([Ap]),ws]}),t}(),Ip={provide:uf,useExisting:Y((function(){return Dp}))},Dp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this))._parent=t,o._validators=i,o._asyncValidators=r,o}return Object(g.a)(n,[{key:"ngOnInit",value:function(){this._checkParentType(),this.formDirective.addFormArray(this)}},{key:"ngOnDestroy",value:function(){this.formDirective&&this.formDirective.removeFormArray(this)}},{key:"_checkParentType",value:function(){Rp(this._parent)&&Nf.arrayParentException()}},{key:"control",get:function(){return this.formDirective.getFormArray(this)}},{key:"formDirective",get:function(){return this._parent?this._parent.formDirective:null}},{key:"path",get:function(){return Kf(null==this.name?this.name:this.name.toString(),this._parent)}},{key:"validator",get:function(){return Jf(this._validators)}},{key:"asyncValidator",get:function(){return tp(this._asyncValidators)}}]),n}(uf);return t.\u0275fac=function(e){return new(e||t)(da(uf,13),da(yf,10),da(_f,10))},t.\u0275dir=Wt({type:t,selectors:[["","formArrayName",""]],inputs:{name:["formArrayName","name"]},features:[Ns([Ip]),ws]}),t}();function Rp(t){return!(t instanceof jp||t instanceof Pp||t instanceof Dp)}var Lp={provide:ff,useExisting:Y((function(){return Fp}))},Fp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){var c;return Object(m.a)(this,n),(c=e.call(this))._ngModelWarningConfig=a,c._added=!1,c.update=new Uc,c._ngModelWarningSent=!1,c._parent=t,c._rawValidators=i||[],c._rawAsyncValidators=r||[],c.valueAccessor=rp(Object(s.a)(c),o),c}return Object(g.a)(n,[{key:"ngOnChanges",value:function(t){this._added||this._setUpControl(),ep(t,this.viewModel)&&(ap("formControlName",n,this,this._ngModelWarningConfig),this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}},{key:"ngOnDestroy",value:function(){this.formDirective&&this.formDirective.removeControl(this)}},{key:"viewToModelUpdate",value:function(t){this.viewModel=t,this.update.emit(t)}},{key:"_checkParentType",value:function(){!(this._parent instanceof jp)&&this._parent instanceof vp?Nf.ngModelGroupException():this._parent instanceof jp||this._parent instanceof Pp||this._parent instanceof Dp||Nf.controlParentException()}},{key:"_setUpControl",value:function(){this._checkParentType(),this.control=this.formDirective.addControl(this),this.control.disabled&&this.valueAccessor.setDisabledState&&this.valueAccessor.setDisabledState(!0),this._added=!0}},{key:"isDisabled",set:function(t){Nf.disabledAttrWarning()}},{key:"path",get:function(){return Kf(null==this.name?this.name:this.name.toString(),this._parent)}},{key:"formDirective",get:function(){return this._parent?this._parent.formDirective:null}},{key:"validator",get:function(){return Jf(this._rawValidators)}},{key:"asyncValidator",get:function(){return tp(this._rawAsyncValidators)}}]),n}(ff);return t.\u0275fac=function(e){return new(e||t)(da(uf,13),da(yf,10),da(_f,10),da(nf,10),da(Op,8))},t.\u0275dir=Wt({type:t,selectors:[["","formControlName",""]],inputs:{isDisabled:["disabled","isDisabled"],name:["formControlName","name"],model:["ngModel","model"]},outputs:{update:"ngModelChange"},features:[Ns([Lp]),ws,Ms]}),t._ngModelWarningSentOnce=!1,t}(),Np={provide:yf,useExisting:Y((function(){return Hp})),multi:!0},Bp={provide:yf,useExisting:Y((function(){return zp})),multi:!0},Hp=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"validate",value:function(t){return this.required?kf.required(t):null}},{key:"registerOnValidatorChange",value:function(t){this._onChange=t}},{key:"required",get:function(){return this._required},set:function(t){this._required=null!=t&&!1!==t&&"false"!=="".concat(t),this._onChange&&this._onChange()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(t,e){2&t&&oa("required",e.required?"":null)},inputs:{required:"required"},features:[Ns([Np])]}),t}(),zp=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"validate",value:function(t){return this.required?kf.requiredTrue(t):null}}]),n}(Hp);return t.\u0275fac=function(e){return Vp(e||t)},t.\u0275dir=Wt({type:t,selectors:[["input","type","checkbox","required","","formControlName",""],["input","type","checkbox","required","","formControl",""],["input","type","checkbox","required","","ngModel",""]],hostVars:1,hostBindings:function(t,e){2&t&&oa("required",e.required?"":null)},features:[Ns([Bp]),ws]}),t}(),Vp=zn(zp),Up={provide:yf,useExisting:Y((function(){return qp})),multi:!0},qp=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"validate",value:function(t){return this._enabled?kf.email(t):null}},{key:"registerOnValidatorChange",value:function(t){this._onChange=t}},{key:"email",set:function(t){this._enabled=""===t||!0===t||"true"===t,this._onChange&&this._onChange()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","email","","formControlName",""],["","email","","formControl",""],["","email","","ngModel",""]],inputs:{email:"email"},features:[Ns([Up])]}),t}(),Gp={provide:yf,useExisting:Y((function(){return Wp})),multi:!0},Wp=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"ngOnChanges",value:function(t){"minlength"in t&&(this._createValidator(),this._onChange&&this._onChange())}},{key:"validate",value:function(t){return null==this.minlength?null:this._validator(t)}},{key:"registerOnValidatorChange",value:function(t){this._onChange=t}},{key:"_createValidator",value:function(){this._validator=kf.minLength("number"==typeof this.minlength?this.minlength:parseInt(this.minlength,10))}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","minlength","","formControlName",""],["","minlength","","formControl",""],["","minlength","","ngModel",""]],hostVars:1,hostBindings:function(t,e){2&t&&oa("minlength",e.minlength?e.minlength:null)},inputs:{minlength:"minlength"},features:[Ns([Gp]),Ms]}),t}(),Kp={provide:yf,useExisting:Y((function(){return Xp})),multi:!0},Xp=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"ngOnChanges",value:function(t){"maxlength"in t&&(this._createValidator(),this._onChange&&this._onChange())}},{key:"validate",value:function(t){return null!=this.maxlength?this._validator(t):null}},{key:"registerOnValidatorChange",value:function(t){this._onChange=t}},{key:"_createValidator",value:function(){this._validator=kf.maxLength("number"==typeof this.maxlength?this.maxlength:parseInt(this.maxlength,10))}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","maxlength","","formControlName",""],["","maxlength","","formControl",""],["","maxlength","","ngModel",""]],hostVars:1,hostBindings:function(t,e){2&t&&oa("maxlength",e.maxlength?e.maxlength:null)},inputs:{maxlength:"maxlength"},features:[Ns([Kp]),Ms]}),t}(),Yp={provide:yf,useExisting:Y((function(){return Zp})),multi:!0},Zp=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"ngOnChanges",value:function(t){"pattern"in t&&(this._createValidator(),this._onChange&&this._onChange())}},{key:"validate",value:function(t){return this._validator(t)}},{key:"registerOnValidatorChange",value:function(t){this._onChange=t}},{key:"_createValidator",value:function(){this._validator=kf.pattern(this.pattern)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","pattern","","formControlName",""],["","pattern","","formControl",""],["","pattern","","ngModel",""]],hostVars:1,hostBindings:function(t,e){2&t&&oa("pattern",e.pattern?e.pattern:null)},inputs:{pattern:"pattern"},features:[Ns([Yp]),Ms]}),t}(),Qp=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}();function $p(t){return void 0!==t.asyncValidators||void 0!==t.validators||void 0!==t.updateOn}var Jp=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"group",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=this._reduceControls(t),i=null,r=null,o=void 0;return null!=e&&($p(e)?(i=null!=e.validators?e.validators:null,r=null!=e.asyncValidators?e.asyncValidators:null,o=null!=e.updateOn?e.updateOn:void 0):(i=null!=e.validator?e.validator:null,r=null!=e.asyncValidator?e.asyncValidator:null)),new dp(n,{asyncValidators:r,updateOn:o,validators:i})}},{key:"control",value:function(t,e,n){return new hp(t,e,n)}},{key:"array",value:function(t,e,n){var i=this,r=t.map((function(t){return i._createControl(t)}));return new fp(r,e,n)}},{key:"_reduceControls",value:function(t){var e=this,n={};return Object.keys(t).forEach((function(i){n[i]=e._createControl(t[i])})),n}},{key:"_createControl",value:function(t){return t instanceof hp||t instanceof dp||t instanceof fp?t:Array.isArray(t)?this.control(t[0],t.length>1?t[1]:null,t.length>2?t[2]:null):this.control(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),tm=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[Af],imports:[Qp]}),t}(),em=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"withConfig",value:function(e){return{ngModule:t,providers:[{provide:Op,useValue:e.warnOnNgModelWithFormControl}]}}}]),t}();return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[Jp,Af],imports:[Qp]}),t}();function nm(t){return null!=t&&"false"!=="".concat(t)}function im(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return rm(t)?Number(t):e}function rm(t){return!isNaN(parseFloat(t))&&!isNaN(Number(t))}function om(t){return Array.isArray(t)?t:[t]}function am(t){return null==t?"":"string"==typeof t?t:"".concat(t,"px")}function sm(t){return t instanceof Us?t.nativeElement:t}var cm=n("7+OI"),lm=n("LRne"),um=function t(){Object(m.a)(this,t)};function hm(t){return t&&"function"==typeof t.connect}var dm,fm=function(){function t(){var e=this,n=arguments.length>0&&void 0!==arguments[0]&&arguments[0],i=arguments.length>1?arguments[1]:void 0,r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];Object(m.a)(this,t),this._multiple=n,this._emitChanges=r,this._selection=new Set,this._deselectedToEmit=[],this._selectedToEmit=[],this.changed=new w.b,i&&i.length&&(n?i.forEach((function(t){return e._markSelected(t)})):this._markSelected(i[0]),this._selectedToEmit.length=0)}return Object(g.a)(t,[{key:"select",value:function(){for(var t=this,e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];this._verifyValueAssignment(n),n.forEach((function(e){return t._markSelected(e)})),this._emitChangeEvent()}},{key:"deselect",value:function(){for(var t=this,e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];this._verifyValueAssignment(n),n.forEach((function(e){return t._unmarkSelected(e)})),this._emitChangeEvent()}},{key:"toggle",value:function(t){this.isSelected(t)?this.deselect(t):this.select(t)}},{key:"clear",value:function(){this._unmarkAll(),this._emitChangeEvent()}},{key:"isSelected",value:function(t){return this._selection.has(t)}},{key:"isEmpty",value:function(){return 0===this._selection.size}},{key:"hasValue",value:function(){return!this.isEmpty()}},{key:"sort",value:function(t){this._multiple&&this.selected&&this._selected.sort(t)}},{key:"isMultipleSelection",value:function(){return this._multiple}},{key:"_emitChangeEvent",value:function(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}},{key:"_markSelected",value:function(t){this.isSelected(t)||(this._multiple||this._unmarkAll(),this._selection.add(t),this._emitChanges&&this._selectedToEmit.push(t))}},{key:"_unmarkSelected",value:function(t){this.isSelected(t)&&(this._selection.delete(t),this._emitChanges&&this._deselectedToEmit.push(t))}},{key:"_unmarkAll",value:function(){var t=this;this.isEmpty()||this._selection.forEach((function(e){return t._unmarkSelected(e)}))}},{key:"_verifyValueAssignment",value:function(t){if(t.length>1&&!this._multiple)throw Error("Cannot pass multiple values into SelectionModel with single-value mode.")}},{key:"selected",get:function(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}}]),t}(),pm=function(){var t=function(){function t(){Object(m.a)(this,t),this._listeners=[]}return Object(g.a)(t,[{key:"notify",value:function(t,e){var n,i=d(this._listeners);try{for(i.s();!(n=i.n()).done;)(0,n.value)(t,e)}catch(r){i.e(r)}finally{i.f()}}},{key:"listen",value:function(t){var e=this;return this._listeners.push(t),function(){e._listeners=e._listeners.filter((function(e){return t!==e}))}}},{key:"ngOnDestroy",value:function(){this._listeners=[]}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:function(){return new t},token:t,providedIn:"root"}),t}(),mm=new ht("cdk-dir-doc",{providedIn:"root",factory:function(){return wt(du)}}),gm=function(){var t=function(){function t(e){if(Object(m.a)(this,t),this.value="ltr",this.change=new Uc,e){var n=(e.body?e.body.dir:null)||(e.documentElement?e.documentElement.dir:null);this.value="ltr"===n||"rtl"===n?n:"ltr"}}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this.change.complete()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(mm,8))},t.\u0275prov=R({factory:function(){return new t(_t(mm,8))},token:t,providedIn:"root"}),t}(),vm=function(){var t=function(){function t(){Object(m.a)(this,t),this._dir="ltr",this._isInitialized=!1,this.change=new Uc}return Object(g.a)(t,[{key:"ngAfterContentInit",value:function(){this._isInitialized=!0}},{key:"ngOnDestroy",value:function(){this.change.complete()}},{key:"dir",get:function(){return this._dir},set:function(t){var e=this._dir,n=t?t.toLowerCase():t;this._rawDir=t,this._dir="ltr"===n||"rtl"===n?n:"ltr",e!==this._dir&&this._isInitialized&&this.change.emit(this._dir)}},{key:"value",get:function(){return this.dir}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","dir",""]],hostVars:1,hostBindings:function(t,e){2&t&&oa("dir",e._rawDir)},inputs:{dir:"dir"},outputs:{change:"dirChange"},exportAs:["dir"],features:[Ns([{provide:gm,useExisting:t}])]}),t}(),bm=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}();try{dm="undefined"!=typeof Intl&&Intl.v8BreakIterator}catch(MCt){dm=!1}var ym,_m,wm,km,Cm=function(){var t=function t(e){Object(m.a)(this,t),this._platformId=e,this.isBrowser=this._platformId?dd(this._platformId):"object"==typeof document&&!!document,this.EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent),this.TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent),this.BLINK=this.isBrowser&&!(!window.chrome&&!dm)&&"undefined"!=typeof CSS&&!this.EDGE&&!this.TRIDENT,this.WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT,this.IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window),this.FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent),this.ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT,this.SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT};return t.\u0275fac=function(e){return new(e||t)(_t(vl))},t.\u0275prov=R({factory:function(){return new t(_t(vl))},token:t,providedIn:"root"}),t}(),Sm=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}(),xm=["color","button","checkbox","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"];function Om(){if(ym)return ym;if("object"!=typeof document||!document)return ym=new Set(xm);var t=document.createElement("input");return ym=new Set(xm.filter((function(e){return t.setAttribute("type",e),t.type===e})))}function Mm(t){return function(){if(null==_m&&"undefined"!=typeof window)try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:function(){return _m=!0}}))}finally{_m=_m||!1}return _m}()?t:!!t.capture}function Tm(){if("object"!=typeof document||!document)return 0;if(null==wm){var t=document.createElement("div"),e=t.style;t.dir="rtl",e.height="1px",e.width="1px",e.overflow="auto",e.visibility="hidden",e.pointerEvents="none",e.position="absolute";var n=document.createElement("div"),i=n.style;i.width="2px",i.height="1px",t.appendChild(n),document.body.appendChild(t),wm=0,0===t.scrollLeft&&(t.scrollLeft=1,wm=0===t.scrollLeft?1:2),t.parentNode.removeChild(t)}return wm}function Em(t){if(function(){if(null==km){var t="undefined"!=typeof document?document.head:null;km=!(!t||!t.createShadowRoot&&!t.attachShadow)}return km}()){var e=t.getRootNode?t.getRootNode():null;if("undefined"!=typeof ShadowRoot&&ShadowRoot&&e instanceof ShadowRoot)return e}return null}var Pm=n("2Vo4"),Am=n("1G5W"),jm=[[["caption"]],[["colgroup"],["col"]]],Im=["caption","colgroup, col"];function Dm(t,e){if(1&t&&(ga(0,"th",3),ds(1),va()),2&t){var n=Aa();Za("text-align",n.justify),Qi(1),ps(" ",n.headerText," ")}}function Rm(t,e){if(1&t&&(ga(0,"td",4),ds(1),va()),2&t){var n=e.$implicit,i=Aa();Za("text-align",i.justify),Qi(1),ps(" ",i.dataAccessor(n,i.name)," ")}}function Lm(t){return function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;Object(m.a)(this,n);for(var i=arguments.length,r=new Array(i),o=0;o<i;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r)))._sticky=!1,t._hasStickyChanged=!1,t}return Object(g.a)(n,[{key:"hasStickyChanged",value:function(){var t=this._hasStickyChanged;return this._hasStickyChanged=!1,t}},{key:"resetStickyChanged",value:function(){this._hasStickyChanged=!1}},{key:"sticky",get:function(){return this._sticky},set:function(t){var e=this._sticky;this._sticky=nm(t),this._hasStickyChanged=e!==this._sticky}}]),n}(t)}var Fm=new ht("CDK_TABLE"),Nm=new ht("text-column-options"),Bm=function(){var t=function t(e){Object(m.a)(this,t),this.template=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["","cdkCellDef",""]]}),t}(),Hm=function(){var t=function t(e){Object(m.a)(this,t),this.template=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["","cdkHeaderCellDef",""]]}),t}(),zm=function(){var t=function t(e){Object(m.a)(this,t),this.template=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["","cdkFooterCellDef",""]]}),t}(),Vm=Lm((function t(){Object(m.a)(this,t)})),Um=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this))._table=t,i._stickyEnd=!1,i}return Object(g.a)(n,[{key:"name",get:function(){return this._name},set:function(t){t&&(this._name=t,this.cssClassFriendlyName=t.replace(/[^a-z0-9_-]/gi,"-"))}},{key:"stickyEnd",get:function(){return this._stickyEnd},set:function(t){var e=this._stickyEnd;this._stickyEnd=nm(t),this._hasStickyChanged=e!==this._stickyEnd}}]),n}(Vm);return t.\u0275fac=function(e){return new(e||t)(da(Fm,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdkColumnDef",""]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,Bm,!0),rl(n,Hm,!0),rl(n,zm,!0)),2&t&&(tl(i=sl())&&(e.cell=i.first),tl(i=sl())&&(e.headerCell=i.first),tl(i=sl())&&(e.footerCell=i.first))},inputs:{sticky:"sticky",name:["cdkColumnDef","name"],stickyEnd:"stickyEnd"},features:[Ns([{provide:"MAT_SORT_HEADER_COLUMN_DEF",useExisting:t}]),ws]}),t}(),qm=function t(e,n){Object(m.a)(this,t);var i="cdk-column-".concat(e.cssClassFriendlyName);n.nativeElement.classList.add(i)},Gm=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){return Object(m.a)(this,n),e.call(this,t,i)}return n}(qm);return t.\u0275fac=function(e){return new(e||t)(da(Um),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["cdk-header-cell"],["th","cdk-header-cell",""]],hostAttrs:["role","columnheader",1,"cdk-header-cell"],features:[ws]}),t}(),Wm=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){return Object(m.a)(this,n),e.call(this,t,i)}return n}(qm);return t.\u0275fac=function(e){return new(e||t)(da(Um),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["cdk-footer-cell"],["td","cdk-footer-cell",""]],hostAttrs:["role","gridcell",1,"cdk-footer-cell"],features:[ws]}),t}(),Km=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){return Object(m.a)(this,n),e.call(this,t,i)}return n}(qm);return t.\u0275fac=function(e){return new(e||t)(da(Um),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["cdk-cell"],["td","cdk-cell",""]],hostAttrs:["role","gridcell",1,"cdk-cell"],features:[ws]}),t}(),Xm=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this.template=e,this._differs=n}return Object(g.a)(t,[{key:"ngOnChanges",value:function(t){if(!this._columnsDiffer){var e=t.columns&&t.columns.currentValue||[];this._columnsDiffer=this._differs.find(e).create(),this._columnsDiffer.diff(e)}}},{key:"getColumnsDiff",value:function(){return this._columnsDiffer.diff(this.columns)}},{key:"extractCellTemplate",value:function(t){return this instanceof Zm?t.headerCell.template:this instanceof $m?t.footerCell.template:t.cell.template}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(fc),da(cc))},t.\u0275dir=Wt({type:t,features:[Ms]}),t}(),Ym=Lm(function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Xm)),Zm=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,i))._table=r,o}return Object(g.a)(n,[{key:"ngOnChanges",value:function(t){Object(o.a)(Object(a.a)(n.prototype),"ngOnChanges",this).call(this,t)}}]),n}(Ym);return t.\u0275fac=function(e){return new(e||t)(da(fc),da(cc),da(Fm,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdkHeaderRowDef",""]],inputs:{columns:["cdkHeaderRowDef","columns"],sticky:["cdkHeaderRowDefSticky","sticky"]},features:[ws,Ms]}),t}(),Qm=Lm(function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Xm)),$m=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,i))._table=r,o}return Object(g.a)(n,[{key:"ngOnChanges",value:function(t){Object(o.a)(Object(a.a)(n.prototype),"ngOnChanges",this).call(this,t)}}]),n}(Qm);return t.\u0275fac=function(e){return new(e||t)(da(fc),da(cc),da(Fm,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdkFooterRowDef",""]],inputs:{columns:["cdkFooterRowDef","columns"],sticky:["cdkFooterRowDefSticky","sticky"]},features:[ws,Ms]}),t}(),Jm=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,i))._table=r,o}return n}(Xm);return t.\u0275fac=function(e){return new(e||t)(da(fc),da(cc),da(Fm,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdkRowDef",""]],inputs:{columns:["cdkRowDefColumns","columns"],when:["cdkRowDefWhen","when"]},features:[ws]}),t}(),tg=function(){var t=function(){function t(e){Object(m.a)(this,t),this._viewContainer=e,t.mostRecentCellOutlet=this}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){t.mostRecentCellOutlet===this&&(t.mostRecentCellOutlet=null)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(mc))},t.\u0275dir=Wt({type:t,selectors:[["","cdkCellOutlet",""]]}),t.mostRecentCellOutlet=null,t}(),eg=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["cdk-header-row"],["tr","cdk-header-row",""]],hostAttrs:["role","row",1,"cdk-header-row"],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,e){1&t&&wa(0,0)},directives:[tg],encapsulation:2}),t}(),ng=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["cdk-footer-row"],["tr","cdk-footer-row",""]],hostAttrs:["role","row",1,"cdk-footer-row"],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,e){1&t&&wa(0,0)},directives:[tg],encapsulation:2}),t}(),ig=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["cdk-row"],["tr","cdk-row",""]],hostAttrs:["role","row",1,"cdk-row"],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,e){1&t&&wa(0,0)},directives:[tg],encapsulation:2}),t}(),rg=function(){var t=function t(e){Object(m.a)(this,t),this.templateRef=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["ng-template","cdkNoDataRow",""]]}),t}(),og=["top","bottom","left","right"],ag=function(){function t(e,n,i){var r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];Object(m.a)(this,t),this._isNativeHtmlTable=e,this._stickCellCss=n,this.direction=i,this._isBrowser=r}return Object(g.a)(t,[{key:"clearStickyPositioning",value:function(t,e){var n,i=d(t);try{for(i.s();!(n=i.n()).done;){var r=n.value;if(r.nodeType===r.ELEMENT_NODE){this._removeStickyStyle(r,e);for(var o=0;o<r.children.length;o++)this._removeStickyStyle(r.children[o],e)}}}catch(a){i.e(a)}finally{i.f()}}},{key:"updateStickyColumns",value:function(t,e,n){var i=e.some((function(t){return t}))||n.some((function(t){return t}));if(t.length&&i&&this._isBrowser){var r,o=t[0],a=o.children.length,s=this._getCellWidths(o),c=this._getStickyStartColumnPositions(s,e),l=this._getStickyEndColumnPositions(s,n),u="rtl"===this.direction,h=d(t);try{for(h.s();!(r=h.n()).done;)for(var f=r.value,p=0;p<a;p++){var m=f.children[p];e[p]&&this._addStickyStyle(m,u?"right":"left",c[p]),n[p]&&this._addStickyStyle(m,u?"left":"right",l[p])}}catch(g){h.e(g)}finally{h.f()}}}},{key:"stickRows",value:function(t,e,n){if(this._isBrowser)for(var i="bottom"===n?t.slice().reverse():t,r="bottom"===n?e.slice().reverse():e,o=0,a=0;a<i.length;a++)if(r[a]){var s=i[a];if(this._isNativeHtmlTable)for(var c=0;c<s.children.length;c++)this._addStickyStyle(s.children[c],n,o);else this._addStickyStyle(s,n,o);if(a===i.length-1)return;o+=s.getBoundingClientRect().height}}},{key:"updateStickyFooterContainer",value:function(t,e){if(this._isNativeHtmlTable){var n=t.querySelector("tfoot");e.some((function(t){return!t}))?this._removeStickyStyle(n,["bottom"]):this._addStickyStyle(n,"bottom",0)}}},{key:"_removeStickyStyle",value:function(t,e){var n,i=d(e);try{for(i.s();!(n=i.n()).done;)t.style[n.value]=""}catch(r){i.e(r)}finally{i.f()}t.style.zIndex=this._getCalculatedZIndex(t),og.some((function(e){return!!t.style[e]}))||(t.style.position="",t.classList.remove(this._stickCellCss))}},{key:"_addStickyStyle",value:function(t,e,n){t.classList.add(this._stickCellCss),t.style[e]="".concat(n,"px"),t.style.cssText+="position: -webkit-sticky; position: sticky; ",t.style.zIndex=this._getCalculatedZIndex(t)}},{key:"_getCalculatedZIndex",value:function(t){var e,n={top:100,bottom:10,left:1,right:1},i=0,r=d(og);try{for(r.s();!(e=r.n()).done;){var o=e.value;t.style[o]&&(i+=n[o])}}catch(a){r.e(a)}finally{r.f()}return i?"".concat(i):""}},{key:"_getCellWidths",value:function(t){for(var e=[],n=t.children,i=0;i<n.length;i++)e.push(n[i].getBoundingClientRect().width);return e}},{key:"_getStickyStartColumnPositions",value:function(t,e){for(var n=[],i=0,r=0;r<t.length;r++)e[r]&&(n[r]=i,i+=t[r]);return n}},{key:"_getStickyEndColumnPositions",value:function(t,e){for(var n=[],i=0,r=t.length;r>0;r--)e[r]&&(n[r]=i,i+=t[r]);return n}}]),t}();function sg(t){return Error('Could not find column with id "'.concat(t,'".'))}var cg=function(){var t=function t(e,n){Object(m.a)(this,t),this.viewContainer=e,this.elementRef=n};return t.\u0275fac=function(e){return new(e||t)(da(mc),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","rowOutlet",""]]}),t}(),lg=function(){var t=function t(e,n){Object(m.a)(this,t),this.viewContainer=e,this.elementRef=n};return t.\u0275fac=function(e){return new(e||t)(da(mc),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","headerRowOutlet",""]]}),t}(),ug=function(){var t=function t(e,n){Object(m.a)(this,t),this.viewContainer=e,this.elementRef=n};return t.\u0275fac=function(e){return new(e||t)(da(mc),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","footerRowOutlet",""]]}),t}(),hg=function(){var t=function t(e,n){Object(m.a)(this,t),this.viewContainer=e,this.elementRef=n};return t.\u0275fac=function(e){return new(e||t)(da(mc),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","noDataRowOutlet",""]]}),t}(),dg=function(){var t=function(){function t(e,n,i,r,o,a,s){Object(m.a)(this,t),this._differs=e,this._changeDetectorRef=n,this._elementRef=i,this._dir=o,this._platform=s,this._onDestroy=new w.b,this._columnDefsByName=new Map,this._customColumnDefs=new Set,this._customRowDefs=new Set,this._customHeaderRowDefs=new Set,this._customFooterRowDefs=new Set,this._headerRowDefChanged=!0,this._footerRowDefChanged=!0,this._cachedRenderRowsMap=new Map,this.stickyCssClass="cdk-table-sticky",this._isShowingNoDataRow=!1,this._multiTemplateDataRows=!1,this.viewChange=new Pm.a({start:0,end:Number.MAX_VALUE}),r||this._elementRef.nativeElement.setAttribute("role","grid"),this._document=a,this._isNativeHtmlTable="TABLE"===this._elementRef.nativeElement.nodeName}return Object(g.a)(t,[{key:"ngOnInit",value:function(){var t=this;this._setupStickyStyler(),this._isNativeHtmlTable&&this._applyNativeTableSections(),this._dataDiffer=this._differs.find([]).create((function(e,n){return t.trackBy?t.trackBy(n.dataIndex,n.data):n}))}},{key:"ngAfterContentChecked",value:function(){if(this._cacheRowDefs(),this._cacheColumnDefs(),!this._headerRowDefs.length&&!this._footerRowDefs.length&&!this._rowDefs.length)throw Error("Missing definitions for header, footer, and row; cannot determine which columns should be rendered.");this._renderUpdatedColumns(),this._headerRowDefChanged&&(this._forceRenderHeaderRows(),this._headerRowDefChanged=!1),this._footerRowDefChanged&&(this._forceRenderFooterRows(),this._footerRowDefChanged=!1),this.dataSource&&this._rowDefs.length>0&&!this._renderChangeSubscription&&this._observeRenderChanges(),this._checkStickyStates()}},{key:"ngOnDestroy",value:function(){this._rowOutlet.viewContainer.clear(),this._noDataRowOutlet.viewContainer.clear(),this._headerRowOutlet.viewContainer.clear(),this._footerRowOutlet.viewContainer.clear(),this._cachedRenderRowsMap.clear(),this._onDestroy.next(),this._onDestroy.complete(),hm(this.dataSource)&&this.dataSource.disconnect(this)}},{key:"renderRows",value:function(){var t=this;this._renderRows=this._getAllRenderRows();var e=this._dataDiffer.diff(this._renderRows);if(e){var n=this._rowOutlet.viewContainer;e.forEachOperation((function(e,i,r){if(null==e.previousIndex)t._insertRow(e.item,r);else if(null==r)n.remove(i);else{var o=n.get(i);n.move(o,r)}})),this._updateRowIndexContext(),e.forEachIdentityChange((function(t){n.get(t.currentIndex).context.$implicit=t.item.data})),this._updateNoDataRow(),this.updateStickyColumnStyles()}}},{key:"addColumnDef",value:function(t){this._customColumnDefs.add(t)}},{key:"removeColumnDef",value:function(t){this._customColumnDefs.delete(t)}},{key:"addRowDef",value:function(t){this._customRowDefs.add(t)}},{key:"removeRowDef",value:function(t){this._customRowDefs.delete(t)}},{key:"addHeaderRowDef",value:function(t){this._customHeaderRowDefs.add(t),this._headerRowDefChanged=!0}},{key:"removeHeaderRowDef",value:function(t){this._customHeaderRowDefs.delete(t),this._headerRowDefChanged=!0}},{key:"addFooterRowDef",value:function(t){this._customFooterRowDefs.add(t),this._footerRowDefChanged=!0}},{key:"removeFooterRowDef",value:function(t){this._customFooterRowDefs.delete(t),this._footerRowDefChanged=!0}},{key:"updateStickyHeaderRowStyles",value:function(){var t=this._getRenderedRows(this._headerRowOutlet),e=this._elementRef.nativeElement.querySelector("thead");e&&(e.style.display=t.length?"":"none");var n=this._headerRowDefs.map((function(t){return t.sticky}));this._stickyStyler.clearStickyPositioning(t,["top"]),this._stickyStyler.stickRows(t,n,"top"),this._headerRowDefs.forEach((function(t){return t.resetStickyChanged()}))}},{key:"updateStickyFooterRowStyles",value:function(){var t=this._getRenderedRows(this._footerRowOutlet),e=this._elementRef.nativeElement.querySelector("tfoot");e&&(e.style.display=t.length?"":"none");var n=this._footerRowDefs.map((function(t){return t.sticky}));this._stickyStyler.clearStickyPositioning(t,["bottom"]),this._stickyStyler.stickRows(t,n,"bottom"),this._stickyStyler.updateStickyFooterContainer(this._elementRef.nativeElement,n),this._footerRowDefs.forEach((function(t){return t.resetStickyChanged()}))}},{key:"updateStickyColumnStyles",value:function(){var t=this,e=this._getRenderedRows(this._headerRowOutlet),n=this._getRenderedRows(this._rowOutlet),i=this._getRenderedRows(this._footerRowOutlet);this._stickyStyler.clearStickyPositioning([].concat(Object(u.a)(e),Object(u.a)(n),Object(u.a)(i)),["left","right"]),e.forEach((function(e,n){t._addStickyColumnStyles([e],t._headerRowDefs[n])})),this._rowDefs.forEach((function(e){for(var i=[],r=0;r<n.length;r++)t._renderRows[r].rowDef===e&&i.push(n[r]);t._addStickyColumnStyles(i,e)})),i.forEach((function(e,n){t._addStickyColumnStyles([e],t._footerRowDefs[n])})),Array.from(this._columnDefsByName.values()).forEach((function(t){return t.resetStickyChanged()}))}},{key:"_getAllRenderRows",value:function(){var t=[],e=this._cachedRenderRowsMap;this._cachedRenderRowsMap=new Map;for(var n=0;n<this._data.length;n++){var i=this._data[n],r=this._getRenderRowsForData(i,n,e.get(i));this._cachedRenderRowsMap.has(i)||this._cachedRenderRowsMap.set(i,new WeakMap);for(var o=0;o<r.length;o++){var a=r[o],s=this._cachedRenderRowsMap.get(a.data);s.has(a.rowDef)?s.get(a.rowDef).push(a):s.set(a.rowDef,[a]),t.push(a)}}return t}},{key:"_getRenderRowsForData",value:function(t,e,n){return this._getRowDefs(t,e).map((function(i){var r=n&&n.has(i)?n.get(i):[];if(r.length){var o=r.shift();return o.dataIndex=e,o}return{data:t,rowDef:i,dataIndex:e}}))}},{key:"_cacheColumnDefs",value:function(){var t=this;this._columnDefsByName.clear(),fg(this._getOwnDefs(this._contentColumnDefs),this._customColumnDefs).forEach((function(e){if(t._columnDefsByName.has(e.name))throw Error('Duplicate column definition name provided: "'.concat(e.name,'".'));t._columnDefsByName.set(e.name,e)}))}},{key:"_cacheRowDefs",value:function(){this._headerRowDefs=fg(this._getOwnDefs(this._contentHeaderRowDefs),this._customHeaderRowDefs),this._footerRowDefs=fg(this._getOwnDefs(this._contentFooterRowDefs),this._customFooterRowDefs),this._rowDefs=fg(this._getOwnDefs(this._contentRowDefs),this._customRowDefs);var t=this._rowDefs.filter((function(t){return!t.when}));if(!this.multiTemplateDataRows&&t.length>1)throw Error("There can only be one default row without a when predicate function.");this._defaultRowDef=t[0]}},{key:"_renderUpdatedColumns",value:function(){var t=function(t,e){return t||!!e.getColumnsDiff()};this._rowDefs.reduce(t,!1)&&this._forceRenderDataRows(),this._headerRowDefs.reduce(t,!1)&&this._forceRenderHeaderRows(),this._footerRowDefs.reduce(t,!1)&&this._forceRenderFooterRows()}},{key:"_switchDataSource",value:function(t){this._data=[],hm(this.dataSource)&&this.dataSource.disconnect(this),this._renderChangeSubscription&&(this._renderChangeSubscription.unsubscribe(),this._renderChangeSubscription=null),t||(this._dataDiffer&&this._dataDiffer.diff([]),this._rowOutlet.viewContainer.clear()),this._dataSource=t}},{key:"_observeRenderChanges",value:function(){var t=this;if(this.dataSource){var e;if(hm(this.dataSource)?e=this.dataSource.connect(this):Object(cm.a)(this.dataSource)?e=this.dataSource:Array.isArray(this.dataSource)&&(e=Object(lm.a)(this.dataSource)),void 0===e)throw Error("Provided data source did not match an array, Observable, or DataSource");this._renderChangeSubscription=e.pipe(Object(Am.a)(this._onDestroy)).subscribe((function(e){t._data=e||[],t.renderRows()}))}}},{key:"_forceRenderHeaderRows",value:function(){var t=this;this._headerRowOutlet.viewContainer.length>0&&this._headerRowOutlet.viewContainer.clear(),this._headerRowDefs.forEach((function(e,n){return t._renderRow(t._headerRowOutlet,e,n)})),this.updateStickyHeaderRowStyles(),this.updateStickyColumnStyles()}},{key:"_forceRenderFooterRows",value:function(){var t=this;this._footerRowOutlet.viewContainer.length>0&&this._footerRowOutlet.viewContainer.clear(),this._footerRowDefs.forEach((function(e,n){return t._renderRow(t._footerRowOutlet,e,n)})),this.updateStickyFooterRowStyles(),this.updateStickyColumnStyles()}},{key:"_addStickyColumnStyles",value:function(t,e){var n=this,i=Array.from(e.columns||[]).map((function(t){var e=n._columnDefsByName.get(t);if(!e)throw sg(t);return e})),r=i.map((function(t){return t.sticky})),o=i.map((function(t){return t.stickyEnd}));this._stickyStyler.updateStickyColumns(t,r,o)}},{key:"_getRenderedRows",value:function(t){for(var e=[],n=0;n<t.viewContainer.length;n++){var i=t.viewContainer.get(n);e.push(i.rootNodes[0])}return e}},{key:"_getRowDefs",value:function(t,e){if(1==this._rowDefs.length)return[this._rowDefs[0]];var n=[];if(this.multiTemplateDataRows)n=this._rowDefs.filter((function(n){return!n.when||n.when(e,t)}));else{var i=this._rowDefs.find((function(n){return n.when&&n.when(e,t)}))||this._defaultRowDef;i&&n.push(i)}if(!n.length)throw function(t){return Error("Could not find a matching row definition for the"+"provided row data: ".concat(JSON.stringify(t)))}(t);return n}},{key:"_insertRow",value:function(t,e){this._renderRow(this._rowOutlet,t.rowDef,e,{$implicit:t.data})}},{key:"_renderRow",value:function(t,e,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};t.viewContainer.createEmbeddedView(e.template,i,n);var r,o=d(this._getCellTemplates(e));try{for(o.s();!(r=o.n()).done;){var a=r.value;tg.mostRecentCellOutlet&&tg.mostRecentCellOutlet._viewContainer.createEmbeddedView(a,i)}}catch(s){o.e(s)}finally{o.f()}this._changeDetectorRef.markForCheck()}},{key:"_updateRowIndexContext",value:function(){for(var t=this._rowOutlet.viewContainer,e=0,n=t.length;e<n;e++){var i=t.get(e).context;i.count=n,i.first=0===e,i.last=e===n-1,i.even=e%2==0,i.odd=!i.even,this.multiTemplateDataRows?(i.dataIndex=this._renderRows[e].dataIndex,i.renderIndex=e):i.index=this._renderRows[e].dataIndex}}},{key:"_getCellTemplates",value:function(t){var e=this;return t&&t.columns?Array.from(t.columns,(function(n){var i=e._columnDefsByName.get(n);if(!i)throw sg(n);return t.extractCellTemplate(i)})):[]}},{key:"_applyNativeTableSections",value:function(){for(var t=this._document.createDocumentFragment(),e=0,n=[{tag:"thead",outlets:[this._headerRowOutlet]},{tag:"tbody",outlets:[this._rowOutlet,this._noDataRowOutlet]},{tag:"tfoot",outlets:[this._footerRowOutlet]}];e<n.length;e++){var i=n[e],r=this._document.createElement(i.tag);r.setAttribute("role","rowgroup");var o,a=d(i.outlets);try{for(a.s();!(o=a.n()).done;)r.appendChild(o.value.elementRef.nativeElement)}catch(s){a.e(s)}finally{a.f()}t.appendChild(r)}this._elementRef.nativeElement.appendChild(t)}},{key:"_forceRenderDataRows",value:function(){this._dataDiffer.diff([]),this._rowOutlet.viewContainer.clear(),this.renderRows(),this.updateStickyColumnStyles()}},{key:"_checkStickyStates",value:function(){var t=function(t,e){return t||e.hasStickyChanged()};this._headerRowDefs.reduce(t,!1)&&this.updateStickyHeaderRowStyles(),this._footerRowDefs.reduce(t,!1)&&this.updateStickyFooterRowStyles(),Array.from(this._columnDefsByName.values()).reduce(t,!1)&&this.updateStickyColumnStyles()}},{key:"_setupStickyStyler",value:function(){var t=this;this._stickyStyler=new ag(this._isNativeHtmlTable,this.stickyCssClass,this._dir?this._dir.value:"ltr",this._platform.isBrowser),(this._dir?this._dir.change:Object(lm.a)()).pipe(Object(Am.a)(this._onDestroy)).subscribe((function(e){t._stickyStyler.direction=e,t.updateStickyColumnStyles()}))}},{key:"_getOwnDefs",value:function(t){var e=this;return t.filter((function(t){return!t._table||t._table===e}))}},{key:"_updateNoDataRow",value:function(){if(this._noDataRow){var t=0===this._rowOutlet.viewContainer.length;if(t!==this._isShowingNoDataRow){var e=this._noDataRowOutlet.viewContainer;t?e.createEmbeddedView(this._noDataRow.templateRef):e.clear(),this._isShowingNoDataRow=t}}}},{key:"trackBy",get:function(){return this._trackByFn},set:function(t){ii()&&null!=t&&"function"!=typeof t&&console&&console.warn&&console.warn("trackBy must be a function, but received ".concat(JSON.stringify(t),".")),this._trackByFn=t}},{key:"dataSource",get:function(){return this._dataSource},set:function(t){this._dataSource!==t&&this._switchDataSource(t)}},{key:"multiTemplateDataRows",get:function(){return this._multiTemplateDataRows},set:function(t){this._multiTemplateDataRows=nm(t),this._rowOutlet&&this._rowOutlet.viewContainer.length&&this._forceRenderDataRows()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(cc),da(Po),da(Us),fa("role"),da(gm,8),da(du),da(Cm))},t.\u0275cmp=Ht({type:t,selectors:[["cdk-table"],["table","cdk-table",""]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,rg,!0),rl(n,Um,!0),rl(n,Jm,!0),rl(n,Zm,!0),rl(n,$m,!0)),2&t&&(tl(i=sl())&&(e._noDataRow=i.first),tl(i=sl())&&(e._contentColumnDefs=i),tl(i=sl())&&(e._contentRowDefs=i),tl(i=sl())&&(e._contentHeaderRowDefs=i),tl(i=sl())&&(e._contentFooterRowDefs=i))},viewQuery:function(t,e){var n;1&t&&(el(cg,!0),el(lg,!0),el(ug,!0),el(hg,!0)),2&t&&(tl(n=sl())&&(e._rowOutlet=n.first),tl(n=sl())&&(e._headerRowOutlet=n.first),tl(n=sl())&&(e._footerRowOutlet=n.first),tl(n=sl())&&(e._noDataRowOutlet=n.first))},hostAttrs:[1,"cdk-table"],inputs:{trackBy:"trackBy",dataSource:"dataSource",multiTemplateDataRows:"multiTemplateDataRows"},exportAs:["cdkTable"],features:[Ns([{provide:Fm,useExisting:t}])],ngContentSelectors:Im,decls:6,vars:0,consts:[["headerRowOutlet",""],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(t,e){1&t&&(Ia(jm),Da(0),Da(1,1),wa(2,0),wa(3,1),wa(4,2),wa(5,3))},directives:[lg,cg,hg,ug],encapsulation:2}),t}();function fg(t,e){return t.concat(Array.from(e))}var pg=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._table=e,this._options=n,this.justify="start",this._options=n||{}}return Object(g.a)(t,[{key:"ngOnInit",value:function(){if(this._syncColumnDefName(),void 0===this.headerText&&(this.headerText=this._createDefaultHeaderText()),this.dataAccessor||(this.dataAccessor=this._options.defaultDataAccessor||function(t,e){return t[e]}),!this._table)throw Error("Text column could not find a parent table for registration.");this.columnDef.cell=this.cell,this.columnDef.headerCell=this.headerCell,this._table.addColumnDef(this.columnDef)}},{key:"ngOnDestroy",value:function(){this._table&&this._table.removeColumnDef(this.columnDef)}},{key:"_createDefaultHeaderText",value:function(){var t=this.name;if(ii()&&!t)throw Error("Table text column must have a name.");return this._options&&this._options.defaultHeaderTextTransform?this._options.defaultHeaderTextTransform(t):t[0].toUpperCase()+t.slice(1)}},{key:"_syncColumnDefName",value:function(){this.columnDef&&(this.columnDef.name=this.name)}},{key:"name",get:function(){return this._name},set:function(t){this._name=t,this._syncColumnDefName()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(dg,8),da(Nm,8))},t.\u0275cmp=Ht({type:t,selectors:[["cdk-text-column"]],viewQuery:function(t,e){var n;1&t&&(el(Um,!0),el(Bm,!0),el(Hm,!0)),2&t&&(tl(n=sl())&&(e.columnDef=n.first),tl(n=sl())&&(e.cell=n.first),tl(n=sl())&&(e.headerCell=n.first))},inputs:{justify:"justify",name:"name",headerText:"headerText",dataAccessor:"dataAccessor"},decls:3,vars:0,consts:[["cdkColumnDef",""],["cdk-header-cell","",3,"text-align",4,"cdkHeaderCellDef"],["cdk-cell","",3,"text-align",4,"cdkCellDef"],["cdk-header-cell",""],["cdk-cell",""]],template:function(t,e){1&t&&(ya(0,0),ua(1,Dm,2,3,"th",1),ua(2,Rm,2,3,"td",2),_a())},directives:[Um,Hm,Bm,Gm,Km],encapsulation:2}),t}(),mg=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}(),gg=n("bOdf"),vg=n("pLZG"),bg=function t(){Object(m.a)(this,t)},yg=function t(){Object(m.a)(this,t)},_g=function(){function t(e){var n=this;Object(m.a)(this,t),this.normalizedNames=new Map,this.lazyUpdate=null,e?this.lazyInit="string"==typeof e?function(){n.headers=new Map,e.split("\n").forEach((function(t){var e=t.indexOf(":");if(e>0){var i=t.slice(0,e),r=i.toLowerCase(),o=t.slice(e+1).trim();n.maybeSetNormalizedName(i,r),n.headers.has(r)?n.headers.get(r).push(o):n.headers.set(r,[o])}}))}:function(){n.headers=new Map,Object.keys(e).forEach((function(t){var i=e[t],r=t.toLowerCase();"string"==typeof i&&(i=[i]),i.length>0&&(n.headers.set(r,i),n.maybeSetNormalizedName(t,r))}))}:this.headers=new Map}return Object(g.a)(t,[{key:"has",value:function(t){return this.init(),this.headers.has(t.toLowerCase())}},{key:"get",value:function(t){this.init();var e=this.headers.get(t.toLowerCase());return e&&e.length>0?e[0]:null}},{key:"keys",value:function(){return this.init(),Array.from(this.normalizedNames.values())}},{key:"getAll",value:function(t){return this.init(),this.headers.get(t.toLowerCase())||null}},{key:"append",value:function(t,e){return this.clone({name:t,value:e,op:"a"})}},{key:"set",value:function(t,e){return this.clone({name:t,value:e,op:"s"})}},{key:"delete",value:function(t,e){return this.clone({name:t,value:e,op:"d"})}},{key:"maybeSetNormalizedName",value:function(t,e){this.normalizedNames.has(e)||this.normalizedNames.set(e,t)}},{key:"init",value:function(){var e=this;this.lazyInit&&(this.lazyInit instanceof t?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach((function(t){return e.applyUpdate(t)})),this.lazyUpdate=null))}},{key:"copyFrom",value:function(t){var e=this;t.init(),Array.from(t.headers.keys()).forEach((function(n){e.headers.set(n,t.headers.get(n)),e.normalizedNames.set(n,t.normalizedNames.get(n))}))}},{key:"clone",value:function(e){var n=new t;return n.lazyInit=this.lazyInit&&this.lazyInit instanceof t?this.lazyInit:this,n.lazyUpdate=(this.lazyUpdate||[]).concat([e]),n}},{key:"applyUpdate",value:function(t){var e=t.name.toLowerCase();switch(t.op){case"a":case"s":var n=t.value;if("string"==typeof n&&(n=[n]),0===n.length)return;this.maybeSetNormalizedName(t.name,e);var i=("a"===t.op?this.headers.get(e):void 0)||[];i.push.apply(i,Object(u.a)(n)),this.headers.set(e,i);break;case"d":var r=t.value;if(r){var o=this.headers.get(e);if(!o)return;0===(o=o.filter((function(t){return-1===r.indexOf(t)}))).length?(this.headers.delete(e),this.normalizedNames.delete(e)):this.headers.set(e,o)}else this.headers.delete(e),this.normalizedNames.delete(e)}}},{key:"forEach",value:function(t){var e=this;this.init(),Array.from(this.normalizedNames.keys()).forEach((function(n){return t(e.normalizedNames.get(n),e.headers.get(n))}))}}]),t}(),wg=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"encodeKey",value:function(t){return Cg(t)}},{key:"encodeValue",value:function(t){return Cg(t)}},{key:"decodeKey",value:function(t){return decodeURIComponent(t)}},{key:"decodeValue",value:function(t){return decodeURIComponent(t)}}]),t}();function kg(t,e){var n=new Map;return t.length>0&&t.split("&").forEach((function(t){var i=t.indexOf("="),r=l(-1==i?[e.decodeKey(t),""]:[e.decodeKey(t.slice(0,i)),e.decodeValue(t.slice(i+1))],2),o=r[0],a=r[1],s=n.get(o)||[];s.push(a),n.set(o,s)})),n}function Cg(t){return encodeURIComponent(t).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/gi,"$").replace(/%2C/gi,",").replace(/%3B/gi,";").replace(/%2B/gi,"+").replace(/%3D/gi,"=").replace(/%3F/gi,"?").replace(/%2F/gi,"/")}var Sg=function(){function t(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(Object(m.a)(this,t),this.updates=null,this.cloneFrom=null,this.encoder=n.encoder||new wg,n.fromString){if(n.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=kg(n.fromString,this.encoder)}else n.fromObject?(this.map=new Map,Object.keys(n.fromObject).forEach((function(t){var i=n.fromObject[t];e.map.set(t,Array.isArray(i)?i:[i])}))):this.map=null}return Object(g.a)(t,[{key:"has",value:function(t){return this.init(),this.map.has(t)}},{key:"get",value:function(t){this.init();var e=this.map.get(t);return e?e[0]:null}},{key:"getAll",value:function(t){return this.init(),this.map.get(t)||null}},{key:"keys",value:function(){return this.init(),Array.from(this.map.keys())}},{key:"append",value:function(t,e){return this.clone({param:t,value:e,op:"a"})}},{key:"set",value:function(t,e){return this.clone({param:t,value:e,op:"s"})}},{key:"delete",value:function(t,e){return this.clone({param:t,value:e,op:"d"})}},{key:"toString",value:function(){var t=this;return this.init(),this.keys().map((function(e){var n=t.encoder.encodeKey(e);return t.map.get(e).map((function(e){return n+"="+t.encoder.encodeValue(e)})).join("&")})).filter((function(t){return""!==t})).join("&")}},{key:"clone",value:function(e){var n=new t({encoder:this.encoder});return n.cloneFrom=this.cloneFrom||this,n.updates=(this.updates||[]).concat([e]),n}},{key:"init",value:function(){var t=this;null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach((function(e){return t.map.set(e,t.cloneFrom.map.get(e))})),this.updates.forEach((function(e){switch(e.op){case"a":case"s":var n=("a"===e.op?t.map.get(e.param):void 0)||[];n.push(e.value),t.map.set(e.param,n);break;case"d":if(void 0===e.value){t.map.delete(e.param);break}var i=t.map.get(e.param)||[],r=i.indexOf(e.value);-1!==r&&i.splice(r,1),i.length>0?t.map.set(e.param,i):t.map.delete(e.param)}})),this.cloneFrom=this.updates=null)}}]),t}();function xg(t){return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer}function Og(t){return"undefined"!=typeof Blob&&t instanceof Blob}function Mg(t){return"undefined"!=typeof FormData&&t instanceof FormData}var Tg=function(){function t(e,n,i,r){var o;if(Object(m.a)(this,t),this.url=n,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=e.toUpperCase(),function(t){switch(t){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||r?(this.body=void 0!==i?i:null,o=r):o=i,o&&(this.reportProgress=!!o.reportProgress,this.withCredentials=!!o.withCredentials,o.responseType&&(this.responseType=o.responseType),o.headers&&(this.headers=o.headers),o.params&&(this.params=o.params)),this.headers||(this.headers=new _g),this.params){var a=this.params.toString();if(0===a.length)this.urlWithParams=n;else{var s=n.indexOf("?");this.urlWithParams=n+(-1===s?"?":s<n.length-1?"&":"")+a}}else this.params=new Sg,this.urlWithParams=n}return Object(g.a)(t,[{key:"serializeBody",value:function(){return null===this.body?null:xg(this.body)||Og(this.body)||Mg(this.body)||"string"==typeof this.body?this.body:this.body instanceof Sg?this.body.toString():"object"==typeof this.body||"boolean"==typeof this.body||Array.isArray(this.body)?JSON.stringify(this.body):this.body.toString()}},{key:"detectContentTypeHeader",value:function(){return null===this.body||Mg(this.body)?null:Og(this.body)?this.body.type||null:xg(this.body)?null:"string"==typeof this.body?"text/plain":this.body instanceof Sg?"application/x-www-form-urlencoded;charset=UTF-8":"object"==typeof this.body||"number"==typeof this.body||Array.isArray(this.body)?"application/json":null}},{key:"clone",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.method||this.method,i=e.url||this.url,r=e.responseType||this.responseType,o=void 0!==e.body?e.body:this.body,a=void 0!==e.withCredentials?e.withCredentials:this.withCredentials,s=void 0!==e.reportProgress?e.reportProgress:this.reportProgress,c=e.headers||this.headers,l=e.params||this.params;return void 0!==e.setHeaders&&(c=Object.keys(e.setHeaders).reduce((function(t,n){return t.set(n,e.setHeaders[n])}),c)),e.setParams&&(l=Object.keys(e.setParams).reduce((function(t,n){return t.set(n,e.setParams[n])}),l)),new t(n,i,o,{params:l,headers:c,reportProgress:s,responseType:r,withCredentials:a})}}]),t}(),Eg=function(t){return t[t.Sent=0]="Sent",t[t.UploadProgress=1]="UploadProgress",t[t.ResponseHeader=2]="ResponseHeader",t[t.DownloadProgress=3]="DownloadProgress",t[t.Response=4]="Response",t[t.User=5]="User",t}({}),Pg=function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"OK";Object(m.a)(this,t),this.headers=e.headers||new _g,this.status=void 0!==e.status?e.status:n,this.statusText=e.statusText||i,this.url=e.url||null,this.ok=this.status>=200&&this.status<300},Ag=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object(m.a)(this,n),(t=e.call(this,i)).type=Eg.ResponseHeader,t}return Object(g.a)(n,[{key:"clone",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new n({headers:t.headers||this.headers,status:void 0!==t.status?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}}]),n}(Pg),jg=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object(m.a)(this,n),(t=e.call(this,i)).type=Eg.Response,t.body=void 0!==i.body?i.body:null,t}return Object(g.a)(n,[{key:"clone",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new n({body:void 0!==t.body?t.body:this.body,headers:t.headers||this.headers,status:void 0!==t.status?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}}]),n}(Pg),Ig=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this,t,0,"Unknown Error")).name="HttpErrorResponse",i.ok=!1,i.message=i.status>=200&&i.status<300?"Http failure during parsing for ".concat(t.url||"(unknown url)"):"Http failure response for ".concat(t.url||"(unknown url)",": ").concat(t.status," ").concat(t.statusText),i.error=t.error||null,i}return n}(Pg);function Dg(t,e){return{body:e,headers:t.headers,observe:t.observe,params:t.params,reportProgress:t.reportProgress,responseType:t.responseType,withCredentials:t.withCredentials}}var Rg=function(){var t=function(){function t(e){Object(m.a)(this,t),this.handler=e}return Object(g.a)(t,[{key:"request",value:function(t,e){var n,i=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(t instanceof Tg)n=t;else{var o=void 0;o=r.headers instanceof _g?r.headers:new _g(r.headers);var a=void 0;r.params&&(a=r.params instanceof Sg?r.params:new Sg({fromObject:r.params})),n=new Tg(t,e,void 0!==r.body?r.body:null,{headers:o,params:a,reportProgress:r.reportProgress,responseType:r.responseType||"json",withCredentials:r.withCredentials})}var s=Object(lm.a)(n).pipe(Object(gg.a)((function(t){return i.handler.handle(t)})));if(t instanceof Tg||"events"===r.observe)return s;var c=s.pipe(Object(vg.a)((function(t){return t instanceof jg})));switch(r.observe||"body"){case"body":switch(n.responseType){case"arraybuffer":return c.pipe(Object(ef.a)((function(t){if(null!==t.body&&!(t.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return t.body})));case"blob":return c.pipe(Object(ef.a)((function(t){if(null!==t.body&&!(t.body instanceof Blob))throw new Error("Response is not a Blob.");return t.body})));case"text":return c.pipe(Object(ef.a)((function(t){if(null!==t.body&&"string"!=typeof t.body)throw new Error("Response is not a string.");return t.body})));case"json":default:return c.pipe(Object(ef.a)((function(t){return t.body})))}case"response":return c;default:throw new Error("Unreachable: unhandled observe type ".concat(r.observe,"}"))}}},{key:"delete",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.request("DELETE",t,e)}},{key:"get",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.request("GET",t,e)}},{key:"head",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.request("HEAD",t,e)}},{key:"jsonp",value:function(t,e){return this.request("JSONP",t,{params:(new Sg).append(e,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}},{key:"options",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.request("OPTIONS",t,e)}},{key:"patch",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.request("PATCH",t,Dg(n,e))}},{key:"post",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.request("POST",t,Dg(n,e))}},{key:"put",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.request("PUT",t,Dg(n,e))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(bg))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Lg=function(){function t(e,n){Object(m.a)(this,t),this.next=e,this.interceptor=n}return Object(g.a)(t,[{key:"handle",value:function(t){return this.interceptor.intercept(t,this.next)}}]),t}(),Fg=new ht("HTTP_INTERCEPTORS"),Ng=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"intercept",value:function(t,e){return e.handle(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Bg=/^\)\]\}',?\n/,Hg=function t(){Object(m.a)(this,t)},zg=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"build",value:function(){return new XMLHttpRequest}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Vg=function(){var t=function(){function t(e){Object(m.a)(this,t),this.xhrFactory=e}return Object(g.a)(t,[{key:"handle",value:function(t){var e=this;if("JSONP"===t.method)throw new Error("Attempted to construct Jsonp request without JsonpClientModule installed.");return new k.a((function(n){var i=e.xhrFactory.build();if(i.open(t.method,t.urlWithParams),t.withCredentials&&(i.withCredentials=!0),t.headers.forEach((function(t,e){return i.setRequestHeader(t,e.join(","))})),t.headers.has("Accept")||i.setRequestHeader("Accept","application/json, text/plain, */*"),!t.headers.has("Content-Type")){var r=t.detectContentTypeHeader();null!==r&&i.setRequestHeader("Content-Type",r)}if(t.responseType){var o=t.responseType.toLowerCase();i.responseType="json"!==o?o:"text"}var a=t.serializeBody(),s=null,c=function(){if(null!==s)return s;var e=1223===i.status?204:i.status,n=i.statusText||"OK",r=new _g(i.getAllResponseHeaders()),o=function(t){return"responseURL"in t&&t.responseURL?t.responseURL:/^X-Request-URL:/m.test(t.getAllResponseHeaders())?t.getResponseHeader("X-Request-URL"):null}(i)||t.url;return s=new Ag({headers:r,status:e,statusText:n,url:o})},l=function(){var e=c(),r=e.headers,o=e.status,a=e.statusText,s=e.url,l=null;204!==o&&(l=void 0===i.response?i.responseText:i.response),0===o&&(o=l?200:0);var u=o>=200&&o<300;if("json"===t.responseType&&"string"==typeof l){var h=l;l=l.replace(Bg,"");try{l=""!==l?JSON.parse(l):null}catch(d){l=h,u&&(u=!1,l={error:d,text:l})}}u?(n.next(new jg({body:l,headers:r,status:o,statusText:a,url:s||void 0})),n.complete()):n.error(new Ig({error:l,headers:r,status:o,statusText:a,url:s||void 0}))},u=function(t){var e=c(),r=new Ig({error:t,status:i.status||0,statusText:i.statusText||"Unknown Error",url:e.url||void 0});n.error(r)},h=!1,d=function(e){h||(n.next(c()),h=!0);var r={type:Eg.DownloadProgress,loaded:e.loaded};e.lengthComputable&&(r.total=e.total),"text"===t.responseType&&i.responseText&&(r.partialText=i.responseText),n.next(r)},f=function(t){var e={type:Eg.UploadProgress,loaded:t.loaded};t.lengthComputable&&(e.total=t.total),n.next(e)};return i.addEventListener("load",l),i.addEventListener("error",u),t.reportProgress&&(i.addEventListener("progress",d),null!==a&&i.upload&&i.upload.addEventListener("progress",f)),i.send(a),n.next({type:Eg.Sent}),function(){i.removeEventListener("error",u),i.removeEventListener("load",l),t.reportProgress&&(i.removeEventListener("progress",d),null!==a&&i.upload&&i.upload.removeEventListener("progress",f)),i.readyState!==i.DONE&&i.abort()}}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Hg))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Ug=new ht("XSRF_COOKIE_NAME"),qg=new ht("XSRF_HEADER_NAME"),Gg=function t(){Object(m.a)(this,t)},Wg=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this.doc=e,this.platform=n,this.cookieName=i,this.lastCookieString="",this.lastToken=null,this.parseCount=0}return Object(g.a)(t,[{key:"getToken",value:function(){if("server"===this.platform)return null;var t=this.doc.cookie||"";return t!==this.lastCookieString&&(this.parseCount++,this.lastToken=xh(t,this.cookieName),this.lastCookieString=t),this.lastToken}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(du),_t(vl),_t(Ug))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Kg=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this.tokenService=e,this.headerName=n}return Object(g.a)(t,[{key:"intercept",value:function(t,e){var n=t.url.toLowerCase();if("GET"===t.method||"HEAD"===t.method||n.startsWith("http://")||n.startsWith("https://"))return e.handle(t);var i=this.tokenService.getToken();return null===i||t.headers.has(this.headerName)||(t=t.clone({headers:t.headers.set(this.headerName,i)})),e.handle(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Gg),_t(qg))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Xg=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this.backend=e,this.injector=n,this.chain=null}return Object(g.a)(t,[{key:"handle",value:function(t){if(null===this.chain){var e=this.injector.get(Fg,[]);this.chain=e.reduceRight((function(t,e){return new Lg(t,e)}),this.backend)}return this.chain.handle(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(yg),_t(Xo))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Yg=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"disable",value:function(){return{ngModule:t,providers:[{provide:Kg,useClass:Ng}]}}},{key:"withOptions",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return{ngModule:t,providers:[e.cookieName?{provide:Ug,useValue:e.cookieName}:[],e.headerName?{provide:qg,useValue:e.headerName}:[]]}}}]),t}();return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[Kg,{provide:Fg,useExisting:Kg,multi:!0},{provide:Gg,useClass:Wg},{provide:Ug,useValue:"XSRF-TOKEN"},{provide:qg,useValue:"X-XSRF-TOKEN"}]}),t}(),Zg=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[Rg,{provide:bg,useClass:Xg},Vg,{provide:yg,useExisting:Vg},zg,{provide:Hg,useExisting:zg}],imports:[[Yg.withOptions({cookieName:"XSRF-TOKEN",headerName:"X-XSRF-TOKEN"})]]}),t}(),Qg=function t(){Object(m.a)(this,t)},$g=function t(){Object(m.a)(this,t)};function Jg(t,e){return{type:7,name:t,definitions:e,options:{}}}function tv(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return{type:4,styles:e,timings:t}}function ev(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return{type:3,steps:t,options:e}}function nv(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return{type:2,steps:t,options:e}}function iv(t){return{type:6,styles:t,offset:null}}function rv(t,e,n){return{type:0,name:t,styles:e,options:n}}function ov(t){return{type:5,steps:t}}function av(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return{type:1,expr:t,animation:e,options:n}}function sv(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return{type:9,options:t}}function cv(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return{type:11,selector:t,animation:e,options:n}}function lv(t){Promise.resolve(null).then(t)}var uv=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;Object(m.a)(this,t),this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._started=!1,this._destroyed=!1,this._finished=!1,this.parentPlayer=null,this.totalTime=e+n}return Object(g.a)(t,[{key:"_onFinish",value:function(){this._finished||(this._finished=!0,this._onDoneFns.forEach((function(t){return t()})),this._onDoneFns=[])}},{key:"onStart",value:function(t){this._onStartFns.push(t)}},{key:"onDone",value:function(t){this._onDoneFns.push(t)}},{key:"onDestroy",value:function(t){this._onDestroyFns.push(t)}},{key:"hasStarted",value:function(){return this._started}},{key:"init",value:function(){}},{key:"play",value:function(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}},{key:"triggerMicrotask",value:function(){var t=this;lv((function(){return t._onFinish()}))}},{key:"_onStart",value:function(){this._onStartFns.forEach((function(t){return t()})),this._onStartFns=[]}},{key:"pause",value:function(){}},{key:"restart",value:function(){}},{key:"finish",value:function(){this._onFinish()}},{key:"destroy",value:function(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach((function(t){return t()})),this._onDestroyFns=[])}},{key:"reset",value:function(){}},{key:"setPosition",value:function(t){}},{key:"getPosition",value:function(){return 0}},{key:"triggerCallback",value:function(t){var e="start"==t?this._onStartFns:this._onDoneFns;e.forEach((function(t){return t()})),e.length=0}}]),t}(),hv=function(){function t(e){var n=this;Object(m.a)(this,t),this._onDoneFns=[],this._onStartFns=[],this._finished=!1,this._started=!1,this._destroyed=!1,this._onDestroyFns=[],this.parentPlayer=null,this.totalTime=0,this.players=e;var i=0,r=0,o=0,a=this.players.length;0==a?lv((function(){return n._onFinish()})):this.players.forEach((function(t){t.onDone((function(){++i==a&&n._onFinish()})),t.onDestroy((function(){++r==a&&n._onDestroy()})),t.onStart((function(){++o==a&&n._onStart()}))})),this.totalTime=this.players.reduce((function(t,e){return Math.max(t,e.totalTime)}),0)}return Object(g.a)(t,[{key:"_onFinish",value:function(){this._finished||(this._finished=!0,this._onDoneFns.forEach((function(t){return t()})),this._onDoneFns=[])}},{key:"init",value:function(){this.players.forEach((function(t){return t.init()}))}},{key:"onStart",value:function(t){this._onStartFns.push(t)}},{key:"_onStart",value:function(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach((function(t){return t()})),this._onStartFns=[])}},{key:"onDone",value:function(t){this._onDoneFns.push(t)}},{key:"onDestroy",value:function(t){this._onDestroyFns.push(t)}},{key:"hasStarted",value:function(){return this._started}},{key:"play",value:function(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach((function(t){return t.play()}))}},{key:"pause",value:function(){this.players.forEach((function(t){return t.pause()}))}},{key:"restart",value:function(){this.players.forEach((function(t){return t.restart()}))}},{key:"finish",value:function(){this._onFinish(),this.players.forEach((function(t){return t.finish()}))}},{key:"destroy",value:function(){this._onDestroy()}},{key:"_onDestroy",value:function(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach((function(t){return t.destroy()})),this._onDestroyFns.forEach((function(t){return t()})),this._onDestroyFns=[])}},{key:"reset",value:function(){this.players.forEach((function(t){return t.reset()})),this._destroyed=!1,this._finished=!1,this._started=!1}},{key:"setPosition",value:function(t){var e=t*this.totalTime;this.players.forEach((function(t){var n=t.totalTime?Math.min(1,e/t.totalTime):1;t.setPosition(n)}))}},{key:"getPosition",value:function(){var t=0;return this.players.forEach((function(e){var n=e.getPosition();t=Math.min(n,t)})),t}},{key:"beforeDestroy",value:function(){this.players.forEach((function(t){t.beforeDestroy&&t.beforeDestroy()}))}},{key:"triggerCallback",value:function(t){var e="start"==t?this._onStartFns:this._onDoneFns;e.forEach((function(t){return t()})),e.length=0}}]),t}();function dv(){return"undefined"!=typeof process&&"[object process]"==={}.toString.call(process)}function fv(t){switch(t.length){case 0:return new uv;case 1:return t[0];default:return new hv(t)}}function pv(t,e,n,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},a=[],s=[],c=-1,l=null;if(i.forEach((function(t){var n=t.offset,i=n==c,u=i&&l||{};Object.keys(t).forEach((function(n){var i=n,s=t[n];if("offset"!==n)switch(i=e.normalizePropertyName(i,a),s){case"!":s=r[n];break;case"*":s=o[n];break;default:s=e.normalizeStyleValue(n,i,s,a)}u[i]=s})),i||s.push(u),l=u,c=n})),a.length){var u="\n - ";throw new Error("Unable to animate due to the following errors:".concat(u).concat(a.join(u)))}return s}function mv(t,e,n,i){switch(e){case"start":t.onStart((function(){return i(n&&gv(n,"start",t))}));break;case"done":t.onDone((function(){return i(n&&gv(n,"done",t))}));break;case"destroy":t.onDestroy((function(){return i(n&&gv(n,"destroy",t))}))}}function gv(t,e,n){var i=n.totalTime,r=vv(t.element,t.triggerName,t.fromState,t.toState,e||t.phaseName,null==i?t.totalTime:i,!!n.disabled),o=t._data;return null!=o&&(r._data=o),r}function vv(t,e,n,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"",o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,a=arguments.length>6?arguments[6]:void 0;return{element:t,triggerName:e,fromState:n,toState:i,phaseName:r,totalTime:o,disabled:!!a}}function bv(t,e,n){var i;return t instanceof Map?(i=t.get(e))||t.set(e,i=n):(i=t[e])||(i=t[e]=n),i}function yv(t){var e=t.indexOf(":");return[t.substring(1,e),t.substr(e+1)]}var _v=function(t,e){return!1},wv=function(t,e){return!1},kv=function(t,e,n){return[]},Cv=dv();(Cv||"undefined"!=typeof Element)&&(_v=function(t,e){return t.contains(e)},wv=function(){if(Cv||Element.prototype.matches)return function(t,e){return t.matches(e)};var t=Element.prototype,e=t.matchesSelector||t.mozMatchesSelector||t.msMatchesSelector||t.oMatchesSelector||t.webkitMatchesSelector;return e?function(t,n){return e.apply(t,[n])}:wv}(),kv=function(t,e,n){var i=[];if(n)i.push.apply(i,Object(u.a)(t.querySelectorAll(e)));else{var r=t.querySelector(e);r&&i.push(r)}return i});var Sv=null,xv=!1;function Ov(t){Sv||(Sv=("undefined"!=typeof document?document.body:null)||{},xv=!!Sv.style&&"WebkitAppearance"in Sv.style);var e=!0;return Sv.style&&!function(t){return"ebkit"==t.substring(1,6)}(t)&&!(e=t in Sv.style)&&xv&&(e="Webkit"+t.charAt(0).toUpperCase()+t.substr(1)in Sv.style),e}var Mv=wv,Tv=_v,Ev=kv;function Pv(t){var e={};return Object.keys(t).forEach((function(n){var i=n.replace(/([a-z])([A-Z])/g,"$1-$2");e[i]=t[n]})),e}var Av=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"validateStyleProperty",value:function(t){return Ov(t)}},{key:"matchesElement",value:function(t,e){return Mv(t,e)}},{key:"containsElement",value:function(t,e){return Tv(t,e)}},{key:"query",value:function(t,e,n){return Ev(t,e,n)}},{key:"computeStyle",value:function(t,e,n){return n||""}},{key:"animate",value:function(t,e,n,i,r){return new uv(n,i)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),jv=function(){var t=function t(){Object(m.a)(this,t)};return t.NOOP=new Av,t}();function Iv(t){if("number"==typeof t)return t;var e=t.match(/^(-?[\.\d]+)(m?s)/);return!e||e.length<2?0:Dv(parseFloat(e[1]),e[2])}function Dv(t,e){switch(e){case"s":return 1e3*t;default:return t}}function Rv(t,e,n){return t.hasOwnProperty("duration")?t:function(t,e,n){var i,r=0,o="";if("string"==typeof t){var a=t.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===a)return e.push('The provided timing value "'.concat(t,'" is invalid.')),{duration:0,delay:0,easing:""};i=Dv(parseFloat(a[1]),a[2]);var s=a[3];null!=s&&(r=Dv(parseFloat(s),a[4]));var c=a[5];c&&(o=c)}else i=t;if(!n){var l=!1,u=e.length;i<0&&(e.push("Duration values below 0 are not allowed for this animation step."),l=!0),r<0&&(e.push("Delay values below 0 are not allowed for this animation step."),l=!0),l&&e.splice(u,0,'The provided timing value "'.concat(t,'" is invalid.'))}return{duration:i,delay:r,easing:o}}(t,e,n)}function Lv(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Object.keys(t).forEach((function(n){e[n]=t[n]})),e}function Fv(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(e)for(var i in t)n[i]=t[i];else Lv(t,n);return n}function Nv(t,e,n){return n?e+":"+n+";":""}function Bv(t){for(var e="",n=0;n<t.style.length;n++){var i=t.style.item(n);e+=Nv(0,i,t.style.getPropertyValue(i))}for(var r in t.style)t.style.hasOwnProperty(r)&&!r.startsWith("_")&&(e+=Nv(0,r.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),t.style[r]));t.setAttribute("style",e)}function Hv(t,e,n){t.style&&(Object.keys(e).forEach((function(i){var r=Xv(i);n&&!n.hasOwnProperty(i)&&(n[i]=t.style[r]),t.style[r]=e[i]})),dv()&&Bv(t))}function zv(t,e){t.style&&(Object.keys(e).forEach((function(e){var n=Xv(e);t.style[n]=""})),dv()&&Bv(t))}function Vv(t){return Array.isArray(t)?1==t.length?t[0]:nv(t):t}var Uv=new RegExp("".concat("{{","\\s*(.+?)\\s*").concat("}}"),"g");function qv(t){var e=[];if("string"==typeof t){for(var n;n=Uv.exec(t);)e.push(n[1]);Uv.lastIndex=0}return e}function Gv(t,e,n){var i=t.toString(),r=i.replace(Uv,(function(t,i){var r=e[i];return e.hasOwnProperty(i)||(n.push("Please provide a value for the animation param ".concat(i)),r=""),r.toString()}));return r==i?t:r}function Wv(t){for(var e=[],n=t.next();!n.done;)e.push(n.value),n=t.next();return e}var Kv=/-+([a-z0-9])/g;function Xv(t){return t.replace(Kv,(function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return e[1].toUpperCase()}))}function Yv(t,e){return 0===t||0===e}function Zv(t,e,n){var i=Object.keys(n);if(i.length&&e.length){var r=e[0],o=[];if(i.forEach((function(t){r.hasOwnProperty(t)||o.push(t),r[t]=n[t]})),o.length)for(var a=function(){var n=e[s];o.forEach((function(e){n[e]=$v(t,e)}))},s=1;s<e.length;s++)a()}return e}function Qv(t,e,n){switch(e.type){case 7:return t.visitTrigger(e,n);case 0:return t.visitState(e,n);case 1:return t.visitTransition(e,n);case 2:return t.visitSequence(e,n);case 3:return t.visitGroup(e,n);case 4:return t.visitAnimate(e,n);case 5:return t.visitKeyframes(e,n);case 6:return t.visitStyle(e,n);case 8:return t.visitReference(e,n);case 9:return t.visitAnimateChild(e,n);case 10:return t.visitAnimateRef(e,n);case 11:return t.visitQuery(e,n);case 12:return t.visitStagger(e,n);default:throw new Error("Unable to resolve animation metadata node #".concat(e.type))}}function $v(t,e){return window.getComputedStyle(t)[e]}var Jv=new Set(["true","1"]),tb=new Set(["false","0"]);function eb(t,e){var n=Jv.has(t)||tb.has(t),i=Jv.has(e)||tb.has(e);return function(r,o){var a="*"==t||t==r,s="*"==e||e==o;return!a&&n&&"boolean"==typeof r&&(a=r?Jv.has(t):tb.has(t)),!s&&i&&"boolean"==typeof o&&(s=o?Jv.has(e):tb.has(e)),a&&s}}var nb=new RegExp("s*".concat(":self","s*,?"),"g");function ib(t,e,n){return new rb(t).build(e,n)}var rb=function(){function t(e){Object(m.a)(this,t),this._driver=e}return Object(g.a)(t,[{key:"build",value:function(t,e){var n=new ob(e);return this._resetContextStyleTimingState(n),Qv(this,Vv(t),n)}},{key:"_resetContextStyleTimingState",value:function(t){t.currentQuerySelector="",t.collectedStyles={},t.collectedStyles[""]={},t.currentTime=0}},{key:"visitTrigger",value:function(t,e){var n=this,i=e.queryCount=0,r=e.depCount=0,o=[],a=[];return"@"==t.name.charAt(0)&&e.errors.push("animation triggers cannot be prefixed with an `@` sign (e.g. trigger('@foo', [...]))"),t.definitions.forEach((function(t){if(n._resetContextStyleTimingState(e),0==t.type){var s=t,c=s.name;c.toString().split(/\s*,\s*/).forEach((function(t){s.name=t,o.push(n.visitState(s,e))})),s.name=c}else if(1==t.type){var l=n.visitTransition(t,e);i+=l.queryCount,r+=l.depCount,a.push(l)}else e.errors.push("only state() and transition() definitions can sit inside of a trigger()")})),{type:7,name:t.name,states:o,transitions:a,queryCount:i,depCount:r,options:null}}},{key:"visitState",value:function(t,e){var n=this.visitStyle(t.styles,e),i=t.options&&t.options.params||null;if(n.containsDynamicStyles){var r=new Set,o=i||{};if(n.styles.forEach((function(t){if(ab(t)){var e=t;Object.keys(e).forEach((function(t){qv(e[t]).forEach((function(t){o.hasOwnProperty(t)||r.add(t)}))}))}})),r.size){var a=Wv(r.values());e.errors.push('state("'.concat(t.name,'", ...) must define default values for all the following style substitutions: ').concat(a.join(", ")))}}return{type:0,name:t.name,style:n,options:i?{params:i}:null}}},{key:"visitTransition",value:function(t,e){e.queryCount=0,e.depCount=0;var n,i,r,o=Qv(this,Vv(t.animation),e);return{type:1,matchers:(n=t.expr,i=e.errors,r=[],"string"==typeof n?n.split(/\s*,\s*/).forEach((function(t){return function(t,e,n){if(":"==t[0]){var i=function(t,e){switch(t){case":enter":return"void => *";case":leave":return"* => void";case":increment":return function(t,e){return parseFloat(e)>parseFloat(t)};case":decrement":return function(t,e){return parseFloat(e)<parseFloat(t)};default:return e.push('The transition alias value "'.concat(t,'" is not supported')),"* => *"}}(t,n);if("function"==typeof i)return void e.push(i);t=i}var r=t.match(/^(\*|[-\w]+)\s*(<?[=-]>)\s*(\*|[-\w]+)$/);if(null==r||r.length<4)return n.push('The provided transition expression "'.concat(t,'" is not supported')),e;var o=r[1],a=r[2],s=r[3];e.push(eb(o,s)),"<"!=a[0]||"*"==o&&"*"==s||e.push(eb(s,o))}(t,r,i)})):r.push(n),r),animation:o,queryCount:e.queryCount,depCount:e.depCount,options:sb(t.options)}}},{key:"visitSequence",value:function(t,e){var n=this;return{type:2,steps:t.steps.map((function(t){return Qv(n,t,e)})),options:sb(t.options)}}},{key:"visitGroup",value:function(t,e){var n=this,i=e.currentTime,r=0,o=t.steps.map((function(t){e.currentTime=i;var o=Qv(n,t,e);return r=Math.max(r,e.currentTime),o}));return e.currentTime=r,{type:3,steps:o,options:sb(t.options)}}},{key:"visitAnimate",value:function(t,e){var n,i=function(t,e){var n=null;if(t.hasOwnProperty("duration"))n=t;else if("number"==typeof t)return cb(Rv(t,e).duration,0,"");var i=t;if(i.split(/\s+/).some((function(t){return"{"==t.charAt(0)&&"{"==t.charAt(1)}))){var r=cb(0,0,"");return r.dynamic=!0,r.strValue=i,r}return cb((n=n||Rv(i,e)).duration,n.delay,n.easing)}(t.timings,e.errors);e.currentAnimateTimings=i;var r=t.styles?t.styles:iv({});if(5==r.type)n=this.visitKeyframes(r,e);else{var o=t.styles,a=!1;if(!o){a=!0;var s={};i.easing&&(s.easing=i.easing),o=iv(s)}e.currentTime+=i.duration+i.delay;var c=this.visitStyle(o,e);c.isEmptyStep=a,n=c}return e.currentAnimateTimings=null,{type:4,timings:i,style:n,options:null}}},{key:"visitStyle",value:function(t,e){var n=this._makeStyleAst(t,e);return this._validateStyleAst(n,e),n}},{key:"_makeStyleAst",value:function(t,e){var n=[];Array.isArray(t.styles)?t.styles.forEach((function(t){"string"==typeof t?"*"==t?n.push(t):e.errors.push("The provided style string value ".concat(t," is not allowed.")):n.push(t)})):n.push(t.styles);var i=!1,r=null;return n.forEach((function(t){if(ab(t)){var e=t,n=e.easing;if(n&&(r=n,delete e.easing),!i)for(var o in e)if(e[o].toString().indexOf("{{")>=0){i=!0;break}}})),{type:6,styles:n,easing:r,offset:t.offset,containsDynamicStyles:i,options:null}}},{key:"_validateStyleAst",value:function(t,e){var n=this,i=e.currentAnimateTimings,r=e.currentTime,o=e.currentTime;i&&o>0&&(o-=i.duration+i.delay),t.styles.forEach((function(t){"string"!=typeof t&&Object.keys(t).forEach((function(i){if(n._driver.validateStyleProperty(i)){var a,s,c,l=e.collectedStyles[e.currentQuerySelector],u=l[i],h=!0;u&&(o!=r&&o>=u.startTime&&r<=u.endTime&&(e.errors.push('The CSS property "'.concat(i,'" that exists between the times of "').concat(u.startTime,'ms" and "').concat(u.endTime,'ms" is also being animated in a parallel animation between the times of "').concat(o,'ms" and "').concat(r,'ms"')),h=!1),o=u.startTime),h&&(l[i]={startTime:o,endTime:r}),e.options&&(a=e.errors,s=e.options.params||{},(c=qv(t[i])).length&&c.forEach((function(t){s.hasOwnProperty(t)||a.push("Unable to resolve the local animation param ".concat(t," in the given list of values"))})))}else e.errors.push('The provided animation property "'.concat(i,'" is not a supported CSS property for animations'))}))}))}},{key:"visitKeyframes",value:function(t,e){var n=this,i={type:5,styles:[],options:null};if(!e.currentAnimateTimings)return e.errors.push("keyframes() must be placed inside of a call to animate()"),i;var r=0,o=[],a=!1,s=!1,c=0,l=t.steps.map((function(t){var i=n._makeStyleAst(t,e),l=null!=i.offset?i.offset:function(t){if("string"==typeof t)return null;var e=null;if(Array.isArray(t))t.forEach((function(t){if(ab(t)&&t.hasOwnProperty("offset")){var n=t;e=parseFloat(n.offset),delete n.offset}}));else if(ab(t)&&t.hasOwnProperty("offset")){var n=t;e=parseFloat(n.offset),delete n.offset}return e}(i.styles),u=0;return null!=l&&(r++,u=i.offset=l),s=s||u<0||u>1,a=a||u<c,c=u,o.push(u),i}));s&&e.errors.push("Please ensure that all keyframe offsets are between 0 and 1"),a&&e.errors.push("Please ensure that all keyframe offsets are in order");var u=t.steps.length,h=0;r>0&&r<u?e.errors.push("Not all style() steps within the declared keyframes() contain offsets"):0==r&&(h=1/(u-1));var d=u-1,f=e.currentTime,p=e.currentAnimateTimings,m=p.duration;return l.forEach((function(t,r){var a=h>0?r==d?1:h*r:o[r],s=a*m;e.currentTime=f+p.delay+s,p.duration=s,n._validateStyleAst(t,e),t.offset=a,i.styles.push(t)})),i}},{key:"visitReference",value:function(t,e){return{type:8,animation:Qv(this,Vv(t.animation),e),options:sb(t.options)}}},{key:"visitAnimateChild",value:function(t,e){return e.depCount++,{type:9,options:sb(t.options)}}},{key:"visitAnimateRef",value:function(t,e){return{type:10,animation:this.visitReference(t.animation,e),options:sb(t.options)}}},{key:"visitQuery",value:function(t,e){var n=e.currentQuerySelector,i=t.options||{};e.queryCount++,e.currentQuery=t;var r=l(function(t){var e=!!t.split(/\s*,\s*/).find((function(t){return":self"==t}));return e&&(t=t.replace(nb,"")),[t=t.replace(/@\*/g,".ng-trigger").replace(/@\w+/g,(function(t){return".ng-trigger-"+t.substr(1)})).replace(/:animating/g,".ng-animating"),e]}(t.selector),2),o=r[0],a=r[1];e.currentQuerySelector=n.length?n+" "+o:o,bv(e.collectedStyles,e.currentQuerySelector,{});var s=Qv(this,Vv(t.animation),e);return e.currentQuery=null,e.currentQuerySelector=n,{type:11,selector:o,limit:i.limit||0,optional:!!i.optional,includeSelf:a,animation:s,originalSelector:t.selector,options:sb(t.options)}}},{key:"visitStagger",value:function(t,e){e.currentQuery||e.errors.push("stagger() can only be used inside of query()");var n="full"===t.timings?{duration:0,delay:0,easing:"full"}:Rv(t.timings,e.errors,!0);return{type:12,animation:Qv(this,Vv(t.animation),e),timings:n,options:null}}}]),t}(),ob=function t(e){Object(m.a)(this,t),this.errors=e,this.queryCount=0,this.depCount=0,this.currentTransition=null,this.currentQuery=null,this.currentQuerySelector=null,this.currentAnimateTimings=null,this.currentTime=0,this.collectedStyles={},this.options=null};function ab(t){return!Array.isArray(t)&&"object"==typeof t}function sb(t){var e;return t?(t=Lv(t)).params&&(t.params=(e=t.params)?Lv(e):null):t={},t}function cb(t,e,n){return{duration:t,delay:e,easing:n}}function lb(t,e,n,i,r,o){var a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,s=arguments.length>7&&void 0!==arguments[7]&&arguments[7];return{type:1,element:t,keyframes:e,preStyleProps:n,postStyleProps:i,duration:r,delay:o,totalTime:r+o,easing:a,subTimeline:s}}var ub=function(){function t(){Object(m.a)(this,t),this._map=new Map}return Object(g.a)(t,[{key:"consume",value:function(t){var e=this._map.get(t);return e?this._map.delete(t):e=[],e}},{key:"append",value:function(t,e){var n,i=this._map.get(t);i||this._map.set(t,i=[]),(n=i).push.apply(n,Object(u.a)(e))}},{key:"has",value:function(t){return this._map.has(t)}},{key:"clear",value:function(){this._map.clear()}}]),t}(),hb=new RegExp(":enter","g"),db=new RegExp(":leave","g");function fb(t,e,n,i,r){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:{},s=arguments.length>7?arguments[7]:void 0,c=arguments.length>8?arguments[8]:void 0,l=arguments.length>9&&void 0!==arguments[9]?arguments[9]:[];return(new pb).buildKeyframes(t,e,n,i,r,o,a,s,c,l)}var pb=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"buildKeyframes",value:function(t,e,n,i,r,o,a,s,c){var l=arguments.length>9&&void 0!==arguments[9]?arguments[9]:[];c=c||new ub;var u=new gb(t,e,c,i,r,l,[]);u.options=s,u.currentTimeline.setStyles([o],null,u.errors,s),Qv(this,n,u);var h=u.timelines.filter((function(t){return t.containsAnimation()}));if(h.length&&Object.keys(a).length){var d=h[h.length-1];d.allowOnlyTimelineStyles()||d.setStyles([a],null,u.errors,s)}return h.length?h.map((function(t){return t.buildKeyframes()})):[lb(e,[],[],[],0,0,"",!1)]}},{key:"visitTrigger",value:function(t,e){}},{key:"visitState",value:function(t,e){}},{key:"visitTransition",value:function(t,e){}},{key:"visitAnimateChild",value:function(t,e){var n=e.subInstructions.consume(e.element);if(n){var i=e.createSubContext(t.options),r=e.currentTimeline.currentTime,o=this._visitSubInstructions(n,i,i.options);r!=o&&e.transformIntoNewTimeline(o)}e.previousNode=t}},{key:"visitAnimateRef",value:function(t,e){var n=e.createSubContext(t.options);n.transformIntoNewTimeline(),this.visitReference(t.animation,n),e.transformIntoNewTimeline(n.currentTimeline.currentTime),e.previousNode=t}},{key:"_visitSubInstructions",value:function(t,e,n){var i=e.currentTimeline.currentTime,r=null!=n.duration?Iv(n.duration):null,o=null!=n.delay?Iv(n.delay):null;return 0!==r&&t.forEach((function(t){var n=e.appendInstructionToTimeline(t,r,o);i=Math.max(i,n.duration+n.delay)})),i}},{key:"visitReference",value:function(t,e){e.updateOptions(t.options,!0),Qv(this,t.animation,e),e.previousNode=t}},{key:"visitSequence",value:function(t,e){var n=this,i=e.subContextCount,r=e,o=t.options;if(o&&(o.params||o.delay)&&((r=e.createSubContext(o)).transformIntoNewTimeline(),null!=o.delay)){6==r.previousNode.type&&(r.currentTimeline.snapshotCurrentStyles(),r.previousNode=mb);var a=Iv(o.delay);r.delayNextStep(a)}t.steps.length&&(t.steps.forEach((function(t){return Qv(n,t,r)})),r.currentTimeline.applyStylesToKeyframe(),r.subContextCount>i&&r.transformIntoNewTimeline()),e.previousNode=t}},{key:"visitGroup",value:function(t,e){var n=this,i=[],r=e.currentTimeline.currentTime,o=t.options&&t.options.delay?Iv(t.options.delay):0;t.steps.forEach((function(a){var s=e.createSubContext(t.options);o&&s.delayNextStep(o),Qv(n,a,s),r=Math.max(r,s.currentTimeline.currentTime),i.push(s.currentTimeline)})),i.forEach((function(t){return e.currentTimeline.mergeTimelineCollectedStyles(t)})),e.transformIntoNewTimeline(r),e.previousNode=t}},{key:"_visitTiming",value:function(t,e){if(t.dynamic){var n=t.strValue;return Rv(e.params?Gv(n,e.params,e.errors):n,e.errors)}return{duration:t.duration,delay:t.delay,easing:t.easing}}},{key:"visitAnimate",value:function(t,e){var n=e.currentAnimateTimings=this._visitTiming(t.timings,e),i=e.currentTimeline;n.delay&&(e.incrementTime(n.delay),i.snapshotCurrentStyles());var r=t.style;5==r.type?this.visitKeyframes(r,e):(e.incrementTime(n.duration),this.visitStyle(r,e),i.applyStylesToKeyframe()),e.currentAnimateTimings=null,e.previousNode=t}},{key:"visitStyle",value:function(t,e){var n=e.currentTimeline,i=e.currentAnimateTimings;!i&&n.getCurrentStyleProperties().length&&n.forwardFrame();var r=i&&i.easing||t.easing;t.isEmptyStep?n.applyEmptyStep(r):n.setStyles(t.styles,r,e.errors,e.options),e.previousNode=t}},{key:"visitKeyframes",value:function(t,e){var n=e.currentAnimateTimings,i=e.currentTimeline.duration,r=n.duration,o=e.createSubContext().currentTimeline;o.easing=n.easing,t.styles.forEach((function(t){o.forwardTime((t.offset||0)*r),o.setStyles(t.styles,t.easing,e.errors,e.options),o.applyStylesToKeyframe()})),e.currentTimeline.mergeTimelineCollectedStyles(o),e.transformIntoNewTimeline(i+r),e.previousNode=t}},{key:"visitQuery",value:function(t,e){var n=this,i=e.currentTimeline.currentTime,r=t.options||{},o=r.delay?Iv(r.delay):0;o&&(6===e.previousNode.type||0==i&&e.currentTimeline.getCurrentStyleProperties().length)&&(e.currentTimeline.snapshotCurrentStyles(),e.previousNode=mb);var a=i,s=e.invokeQuery(t.selector,t.originalSelector,t.limit,t.includeSelf,!!r.optional,e.errors);e.currentQueryTotal=s.length;var c=null;s.forEach((function(i,r){e.currentQueryIndex=r;var s=e.createSubContext(t.options,i);o&&s.delayNextStep(o),i===e.element&&(c=s.currentTimeline),Qv(n,t.animation,s),s.currentTimeline.applyStylesToKeyframe(),a=Math.max(a,s.currentTimeline.currentTime)})),e.currentQueryIndex=0,e.currentQueryTotal=0,e.transformIntoNewTimeline(a),c&&(e.currentTimeline.mergeTimelineCollectedStyles(c),e.currentTimeline.snapshotCurrentStyles()),e.previousNode=t}},{key:"visitStagger",value:function(t,e){var n=e.parentContext,i=e.currentTimeline,r=t.timings,o=Math.abs(r.duration),a=o*(e.currentQueryTotal-1),s=o*e.currentQueryIndex;switch(r.duration<0?"reverse":r.easing){case"reverse":s=a-s;break;case"full":s=n.currentStaggerTime}var c=e.currentTimeline;s&&c.delayNextStep(s);var l=c.currentTime;Qv(this,t.animation,e),e.previousNode=t,n.currentStaggerTime=i.currentTime-l+(i.startTime-n.currentTimeline.startTime)}}]),t}(),mb={},gb=function(){function t(e,n,i,r,o,a,s,c){Object(m.a)(this,t),this._driver=e,this.element=n,this.subInstructions=i,this._enterClassName=r,this._leaveClassName=o,this.errors=a,this.timelines=s,this.parentContext=null,this.currentAnimateTimings=null,this.previousNode=mb,this.subContextCount=0,this.options={},this.currentQueryIndex=0,this.currentQueryTotal=0,this.currentStaggerTime=0,this.currentTimeline=c||new vb(this._driver,n,0),s.push(this.currentTimeline)}return Object(g.a)(t,[{key:"updateOptions",value:function(t,e){var n=this;if(t){var i=t,r=this.options;null!=i.duration&&(r.duration=Iv(i.duration)),null!=i.delay&&(r.delay=Iv(i.delay));var o=i.params;if(o){var a=r.params;a||(a=this.options.params={}),Object.keys(o).forEach((function(t){e&&a.hasOwnProperty(t)||(a[t]=Gv(o[t],a,n.errors))}))}}}},{key:"_copyOptions",value:function(){var t={};if(this.options){var e=this.options.params;if(e){var n=t.params={};Object.keys(e).forEach((function(t){n[t]=e[t]}))}}return t}},{key:"createSubContext",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1?arguments[1]:void 0,i=arguments.length>2?arguments[2]:void 0,r=n||this.element,o=new t(this._driver,r,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(r,i||0));return o.previousNode=this.previousNode,o.currentAnimateTimings=this.currentAnimateTimings,o.options=this._copyOptions(),o.updateOptions(e),o.currentQueryIndex=this.currentQueryIndex,o.currentQueryTotal=this.currentQueryTotal,o.parentContext=this,this.subContextCount++,o}},{key:"transformIntoNewTimeline",value:function(t){return this.previousNode=mb,this.currentTimeline=this.currentTimeline.fork(this.element,t),this.timelines.push(this.currentTimeline),this.currentTimeline}},{key:"appendInstructionToTimeline",value:function(t,e,n){var i={duration:null!=e?e:t.duration,delay:this.currentTimeline.currentTime+(null!=n?n:0)+t.delay,easing:""},r=new bb(this._driver,t.element,t.keyframes,t.preStyleProps,t.postStyleProps,i,t.stretchStartingKeyframe);return this.timelines.push(r),i}},{key:"incrementTime",value:function(t){this.currentTimeline.forwardTime(this.currentTimeline.duration+t)}},{key:"delayNextStep",value:function(t){t>0&&this.currentTimeline.delayNextStep(t)}},{key:"invokeQuery",value:function(t,e,n,i,r,o){var a=[];if(i&&a.push(this.element),t.length>0){t=(t=t.replace(hb,"."+this._enterClassName)).replace(db,"."+this._leaveClassName);var s=this._driver.query(this.element,t,1!=n);0!==n&&(s=n<0?s.slice(s.length+n,s.length):s.slice(0,n)),a.push.apply(a,Object(u.a)(s))}return r||0!=a.length||o.push('`query("'.concat(e,'")` returned zero elements. (Use `query("').concat(e,'", { optional: true })` if you wish to allow this.)')),a}},{key:"params",get:function(){return this.options.params}}]),t}(),vb=function(){function t(e,n,i,r){Object(m.a)(this,t),this._driver=e,this.element=n,this.startTime=i,this._elementTimelineStylesLookup=r,this.duration=0,this._previousKeyframe={},this._currentKeyframe={},this._keyframes=new Map,this._styleSummary={},this._pendingStyles={},this._backFill={},this._currentEmptyStepKeyframe=null,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._localTimelineStyles=Object.create(this._backFill,{}),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(n),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(n,this._localTimelineStyles)),this._loadKeyframe()}return Object(g.a)(t,[{key:"containsAnimation",value:function(){switch(this._keyframes.size){case 0:return!1;case 1:return this.getCurrentStyleProperties().length>0;default:return!0}}},{key:"getCurrentStyleProperties",value:function(){return Object.keys(this._currentKeyframe)}},{key:"delayNextStep",value:function(t){var e=1==this._keyframes.size&&Object.keys(this._pendingStyles).length;this.duration||e?(this.forwardTime(this.currentTime+t),e&&this.snapshotCurrentStyles()):this.startTime+=t}},{key:"fork",value:function(e,n){return this.applyStylesToKeyframe(),new t(this._driver,e,n||this.currentTime,this._elementTimelineStylesLookup)}},{key:"_loadKeyframe",value:function(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=Object.create(this._backFill,{}),this._keyframes.set(this.duration,this._currentKeyframe))}},{key:"forwardFrame",value:function(){this.duration+=1,this._loadKeyframe()}},{key:"forwardTime",value:function(t){this.applyStylesToKeyframe(),this.duration=t,this._loadKeyframe()}},{key:"_updateStyle",value:function(t,e){this._localTimelineStyles[t]=e,this._globalTimelineStyles[t]=e,this._styleSummary[t]={time:this.currentTime,value:e}}},{key:"allowOnlyTimelineStyles",value:function(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}},{key:"applyEmptyStep",value:function(t){var e=this;t&&(this._previousKeyframe.easing=t),Object.keys(this._globalTimelineStyles).forEach((function(t){e._backFill[t]=e._globalTimelineStyles[t]||"*",e._currentKeyframe[t]="*"})),this._currentEmptyStepKeyframe=this._currentKeyframe}},{key:"setStyles",value:function(t,e,n,i){var r=this;e&&(this._previousKeyframe.easing=e);var o=i&&i.params||{},a=function(t,e){var n,i={};return t.forEach((function(t){"*"===t?(n=n||Object.keys(e)).forEach((function(t){i[t]="*"})):Fv(t,!1,i)})),i}(t,this._globalTimelineStyles);Object.keys(a).forEach((function(t){var e=Gv(a[t],o,n);r._pendingStyles[t]=e,r._localTimelineStyles.hasOwnProperty(t)||(r._backFill[t]=r._globalTimelineStyles.hasOwnProperty(t)?r._globalTimelineStyles[t]:"*"),r._updateStyle(t,e)}))}},{key:"applyStylesToKeyframe",value:function(){var t=this,e=this._pendingStyles,n=Object.keys(e);0!=n.length&&(this._pendingStyles={},n.forEach((function(n){t._currentKeyframe[n]=e[n]})),Object.keys(this._localTimelineStyles).forEach((function(e){t._currentKeyframe.hasOwnProperty(e)||(t._currentKeyframe[e]=t._localTimelineStyles[e])})))}},{key:"snapshotCurrentStyles",value:function(){var t=this;Object.keys(this._localTimelineStyles).forEach((function(e){var n=t._localTimelineStyles[e];t._pendingStyles[e]=n,t._updateStyle(e,n)}))}},{key:"getFinalKeyframe",value:function(){return this._keyframes.get(this.duration)}},{key:"mergeTimelineCollectedStyles",value:function(t){var e=this;Object.keys(t._styleSummary).forEach((function(n){var i=e._styleSummary[n],r=t._styleSummary[n];(!i||r.time>i.time)&&e._updateStyle(n,r.value)}))}},{key:"buildKeyframes",value:function(){var t=this;this.applyStylesToKeyframe();var e=new Set,n=new Set,i=1===this._keyframes.size&&0===this.duration,r=[];this._keyframes.forEach((function(o,a){var s=Fv(o,!0);Object.keys(s).forEach((function(t){var i=s[t];"!"==i?e.add(t):"*"==i&&n.add(t)})),i||(s.offset=a/t.duration),r.push(s)}));var o=e.size?Wv(e.values()):[],a=n.size?Wv(n.values()):[];if(i){var s=r[0],c=Lv(s);s.offset=0,c.offset=1,r=[s,c]}return lb(this.element,r,o,a,this.duration,this.startTime,this.easing,!1)}},{key:"currentTime",get:function(){return this.startTime+this.duration}},{key:"properties",get:function(){var t=[];for(var e in this._currentKeyframe)t.push(e);return t}}]),t}(),bb=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s){var c,l=arguments.length>6&&void 0!==arguments[6]&&arguments[6];return Object(m.a)(this,n),(c=e.call(this,t,i,s.delay)).element=i,c.keyframes=r,c.preStyleProps=o,c.postStyleProps=a,c._stretchStartingKeyframe=l,c.timings={duration:s.duration,delay:s.delay,easing:s.easing},c}return Object(g.a)(n,[{key:"containsAnimation",value:function(){return this.keyframes.length>1}},{key:"buildKeyframes",value:function(){var t=this.keyframes,e=this.timings,n=e.delay,i=e.duration,r=e.easing;if(this._stretchStartingKeyframe&&n){var o=[],a=i+n,s=n/a,c=Fv(t[0],!1);c.offset=0,o.push(c);var l=Fv(t[0],!1);l.offset=yb(s),o.push(l);for(var u=t.length-1,h=1;h<=u;h++){var d=Fv(t[h],!1);d.offset=yb((n+d.offset*i)/a),o.push(d)}i=a,n=0,r="",t=o}return lb(this.element,t,this.preStyleProps,this.postStyleProps,i,n,r,!0)}}]),n}(vb);function yb(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3,n=Math.pow(10,e-1);return Math.round(t*n)/n}var _b=function t(){Object(m.a)(this,t)},wb=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"normalizePropertyName",value:function(t,e){return Xv(t)}},{key:"normalizeStyleValue",value:function(t,e,n,i){var r="",o=n.toString().trim();if(kb[e]&&0!==n&&"0"!==n)if("number"==typeof n)r="px";else{var a=n.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&0==a[1].length&&i.push("Please provide a CSS unit value for ".concat(t,":").concat(n))}return o+r}}]),n}(_b),kb=function(){return t="width,height,minWidth,minHeight,maxWidth,maxHeight,left,top,bottom,right,fontSize,outlineWidth,outlineOffset,paddingTop,paddingLeft,paddingBottom,paddingRight,marginTop,marginLeft,marginBottom,marginRight,borderRadius,borderWidth,borderTopWidth,borderLeftWidth,borderRightWidth,borderBottomWidth,textIndent,perspective".split(","),e={},t.forEach((function(t){return e[t]=!0})),e;var t,e}();function Cb(t,e,n,i,r,o,a,s,c,l,u,h,d){return{type:0,element:t,triggerName:e,isRemovalTransition:r,fromState:n,fromStyles:o,toState:i,toStyles:a,timelines:s,queriedElements:c,preStyleProps:l,postStyleProps:u,totalTime:h,errors:d}}var Sb={},xb=function(){function t(e,n,i){Object(m.a)(this,t),this._triggerName=e,this.ast=n,this._stateStyles=i}return Object(g.a)(t,[{key:"match",value:function(t,e,n,i){return function(t,e,n,i,r){return t.some((function(t){return t(e,n,i,r)}))}(this.ast.matchers,t,e,n,i)}},{key:"buildStyles",value:function(t,e,n){var i=this._stateStyles["*"],r=this._stateStyles[t],o=i?i.buildStyles(e,n):{};return r?r.buildStyles(e,n):o}},{key:"build",value:function(t,e,n,i,r,o,a,s,c,l){var u=[],h=this.ast.options&&this.ast.options.params||Sb,d=this.buildStyles(n,a&&a.params||Sb,u),f=s&&s.params||Sb,p=this.buildStyles(i,f,u),m=new Set,g=new Map,v=new Map,b="void"===i,y={params:Object.assign(Object.assign({},h),f)},_=l?[]:fb(t,e,this.ast.animation,r,o,d,p,y,c,u),w=0;if(_.forEach((function(t){w=Math.max(t.duration+t.delay,w)})),u.length)return Cb(e,this._triggerName,n,i,b,d,p,[],[],g,v,w,u);_.forEach((function(t){var n=t.element,i=bv(g,n,{});t.preStyleProps.forEach((function(t){return i[t]=!0}));var r=bv(v,n,{});t.postStyleProps.forEach((function(t){return r[t]=!0})),n!==e&&m.add(n)}));var k=Wv(m.values());return Cb(e,this._triggerName,n,i,b,d,p,_,k,g,v,w)}}]),t}(),Ob=function(){function t(e,n){Object(m.a)(this,t),this.styles=e,this.defaultParams=n}return Object(g.a)(t,[{key:"buildStyles",value:function(t,e){var n={},i=Lv(this.defaultParams);return Object.keys(t).forEach((function(e){var n=t[e];null!=n&&(i[e]=n)})),this.styles.styles.forEach((function(t){if("string"!=typeof t){var r=t;Object.keys(r).forEach((function(t){var o=r[t];o.length>1&&(o=Gv(o,i,e)),n[t]=o}))}})),n}}]),t}(),Mb=function(){function t(e,n){var i=this;Object(m.a)(this,t),this.name=e,this.ast=n,this.transitionFactories=[],this.states={},n.states.forEach((function(t){i.states[t.name]=new Ob(t.style,t.options&&t.options.params||{})})),Tb(this.states,"true","1"),Tb(this.states,"false","0"),n.transitions.forEach((function(t){i.transitionFactories.push(new xb(e,t,i.states))})),this.fallbackTransition=new xb(e,{type:1,animation:{type:2,steps:[],options:null},matchers:[function(t,e){return!0}],options:null,queryCount:0,depCount:0},this.states)}return Object(g.a)(t,[{key:"matchTransition",value:function(t,e,n,i){return this.transitionFactories.find((function(r){return r.match(t,e,n,i)}))||null}},{key:"matchStyles",value:function(t,e,n){return this.fallbackTransition.buildStyles(t,e,n)}},{key:"containsQueries",get:function(){return this.ast.queryCount>0}}]),t}();function Tb(t,e,n){t.hasOwnProperty(e)?t.hasOwnProperty(n)||(t[n]=t[e]):t.hasOwnProperty(n)&&(t[e]=t[n])}var Eb=new ub,Pb=function(){function t(e,n,i){Object(m.a)(this,t),this.bodyNode=e,this._driver=n,this._normalizer=i,this._animations={},this._playersById={},this.players=[]}return Object(g.a)(t,[{key:"register",value:function(t,e){var n=[],i=ib(this._driver,e,n);if(n.length)throw new Error("Unable to build the animation due to the following errors: ".concat(n.join("\n")));this._animations[t]=i}},{key:"_buildPlayer",value:function(t,e,n){var i=t.element,r=pv(this._driver,this._normalizer,i,t.keyframes,e,n);return this._driver.animate(i,r,t.duration,t.delay,t.easing,[],!0)}},{key:"create",value:function(t,e){var n,i=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=[],a=this._animations[t],s=new Map;if(a?(n=fb(this._driver,e,a,"ng-enter","ng-leave",{},{},r,Eb,o)).forEach((function(t){var e=bv(s,t.element,{});t.postStyleProps.forEach((function(t){return e[t]=null}))})):(o.push("The requested animation doesn't exist or has already been destroyed"),n=[]),o.length)throw new Error("Unable to create the animation due to the following errors: ".concat(o.join("\n")));s.forEach((function(t,e){Object.keys(t).forEach((function(n){t[n]=i._driver.computeStyle(e,n,"*")}))}));var c=n.map((function(t){var e=s.get(t.element);return i._buildPlayer(t,{},e)})),l=fv(c);return this._playersById[t]=l,l.onDestroy((function(){return i.destroy(t)})),this.players.push(l),l}},{key:"destroy",value:function(t){var e=this._getPlayer(t);e.destroy(),delete this._playersById[t];var n=this.players.indexOf(e);n>=0&&this.players.splice(n,1)}},{key:"_getPlayer",value:function(t){var e=this._playersById[t];if(!e)throw new Error("Unable to find the timeline player referenced by ".concat(t));return e}},{key:"listen",value:function(t,e,n,i){var r=vv(e,"","","");return mv(this._getPlayer(t),n,r,i),function(){}}},{key:"command",value:function(t,e,n,i){if("register"!=n)if("create"!=n){var r=this._getPlayer(t);switch(n){case"play":r.play();break;case"pause":r.pause();break;case"reset":r.reset();break;case"restart":r.restart();break;case"finish":r.finish();break;case"init":r.init();break;case"setPosition":r.setPosition(parseFloat(i[0]));break;case"destroy":this.destroy(t)}}else this.create(t,e,i[0]||{});else this.register(t,i[0])}}]),t}(),Ab=[],jb={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},Ib={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},Db=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";Object(m.a)(this,t),this.namespaceId=n;var i=e&&e.hasOwnProperty("value"),r=i?e.value:e;if(this.value=Bb(r),i){var o=Lv(e);delete o.value,this.options=o}else this.options={};this.options.params||(this.options.params={})}return Object(g.a)(t,[{key:"absorbOptions",value:function(t){var e=t.params;if(e){var n=this.options.params;Object.keys(e).forEach((function(t){null==n[t]&&(n[t]=e[t])}))}}},{key:"params",get:function(){return this.options.params}}]),t}(),Rb=new Db("void"),Lb=function(){function t(e,n,i){Object(m.a)(this,t),this.id=e,this.hostElement=n,this._engine=i,this.players=[],this._triggers={},this._queue=[],this._elementListeners=new Map,this._hostClassName="ng-tns-"+e,qb(n,this._hostClassName)}return Object(g.a)(t,[{key:"listen",value:function(t,e,n,i){var r,o=this;if(!this._triggers.hasOwnProperty(e))throw new Error('Unable to listen on the animation trigger event "'.concat(n,'" because the animation trigger "').concat(e,"\" doesn't exist!"));if(null==n||0==n.length)throw new Error('Unable to listen on the animation trigger "'.concat(e,'" because the provided event is undefined!'));if("start"!=(r=n)&&"done"!=r)throw new Error('The provided animation trigger event "'.concat(n,'" for the animation trigger "').concat(e,'" is not supported!'));var a=bv(this._elementListeners,t,[]),s={name:e,phase:n,callback:i};a.push(s);var c=bv(this._engine.statesByElement,t,{});return c.hasOwnProperty(e)||(qb(t,"ng-trigger"),qb(t,"ng-trigger-"+e),c[e]=Rb),function(){o._engine.afterFlush((function(){var t=a.indexOf(s);t>=0&&a.splice(t,1),o._triggers[e]||delete c[e]}))}}},{key:"register",value:function(t,e){return!this._triggers[t]&&(this._triggers[t]=e,!0)}},{key:"_getTrigger",value:function(t){var e=this._triggers[t];if(!e)throw new Error('The provided animation trigger "'.concat(t,'" has not been registered!'));return e}},{key:"trigger",value:function(t,e,n){var i=this,r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],o=this._getTrigger(e),a=new Nb(this.id,e,t),s=this._engine.statesByElement.get(t);s||(qb(t,"ng-trigger"),qb(t,"ng-trigger-"+e),this._engine.statesByElement.set(t,s={}));var c=s[e],l=new Db(n,this.id),u=n&&n.hasOwnProperty("value");!u&&c&&l.absorbOptions(c.options),s[e]=l,c||(c=Rb);var h="void"===l.value;if(h||c.value!==l.value){var d=bv(this._engine.playersByElement,t,[]);d.forEach((function(t){t.namespaceId==i.id&&t.triggerName==e&&t.queued&&t.destroy()}));var f=o.matchTransition(c.value,l.value,t,l.params),p=!1;if(!f){if(!r)return;f=o.fallbackTransition,p=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:t,triggerName:e,transition:f,fromState:c,toState:l,player:a,isFallbackTransition:p}),p||(qb(t,"ng-animate-queued"),a.onStart((function(){Gb(t,"ng-animate-queued")}))),a.onDone((function(){var e=i.players.indexOf(a);e>=0&&i.players.splice(e,1);var n=i._engine.playersByElement.get(t);if(n){var r=n.indexOf(a);r>=0&&n.splice(r,1)}})),this.players.push(a),d.push(a),a}if(!Kb(c.params,l.params)){var m=[],g=o.matchStyles(c.value,c.params,m),v=o.matchStyles(l.value,l.params,m);m.length?this._engine.reportError(m):this._engine.afterFlush((function(){zv(t,g),Hv(t,v)}))}}},{key:"deregister",value:function(t){var e=this;delete this._triggers[t],this._engine.statesByElement.forEach((function(e,n){delete e[t]})),this._elementListeners.forEach((function(n,i){e._elementListeners.set(i,n.filter((function(e){return e.name!=t})))}))}},{key:"clearElementCache",value:function(t){this._engine.statesByElement.delete(t),this._elementListeners.delete(t);var e=this._engine.playersByElement.get(t);e&&(e.forEach((function(t){return t.destroy()})),this._engine.playersByElement.delete(t))}},{key:"_signalRemovalForInnerTriggers",value:function(t,e){var n=this,i=this._engine.driver.query(t,".ng-trigger",!0);i.forEach((function(t){if(!t.__ng_removed){var i=n._engine.fetchNamespacesByElement(t);i.size?i.forEach((function(n){return n.triggerLeaveAnimation(t,e,!1,!0)})):n.clearElementCache(t)}})),this._engine.afterFlushAnimationsDone((function(){return i.forEach((function(t){return n.clearElementCache(t)}))}))}},{key:"triggerLeaveAnimation",value:function(t,e,n,i){var r=this,o=this._engine.statesByElement.get(t);if(o){var a=[];if(Object.keys(o).forEach((function(e){if(r._triggers[e]){var n=r.trigger(t,e,"void",i);n&&a.push(n)}})),a.length)return this._engine.markElementAsRemoved(this.id,t,!0,e),n&&fv(a).onDone((function(){return r._engine.processLeaveNode(t)})),!0}return!1}},{key:"prepareLeaveAnimationListeners",value:function(t){var e=this,n=this._elementListeners.get(t);if(n){var i=new Set;n.forEach((function(n){var r=n.name;if(!i.has(r)){i.add(r);var o=e._triggers[r].fallbackTransition,a=e._engine.statesByElement.get(t)[r]||Rb,s=new Db("void"),c=new Nb(e.id,r,t);e._engine.totalQueuedPlayers++,e._queue.push({element:t,triggerName:r,transition:o,fromState:a,toState:s,player:c,isFallbackTransition:!0})}}))}}},{key:"removeNode",value:function(t,e){var n=this,i=this._engine;if(t.childElementCount&&this._signalRemovalForInnerTriggers(t,e),!this.triggerLeaveAnimation(t,e,!0)){var r=!1;if(i.totalAnimations){var o=i.players.length?i.playersByQueriedElement.get(t):[];if(o&&o.length)r=!0;else for(var a=t;a=a.parentNode;)if(i.statesByElement.get(a)){r=!0;break}}if(this.prepareLeaveAnimationListeners(t),r)i.markElementAsRemoved(this.id,t,!1,e);else{var s=t.__ng_removed;s&&s!==jb||(i.afterFlush((function(){return n.clearElementCache(t)})),i.destroyInnerAnimations(t),i._onRemovalComplete(t,e))}}}},{key:"insertNode",value:function(t,e){qb(t,this._hostClassName)}},{key:"drainQueuedTransitions",value:function(t){var e=this,n=[];return this._queue.forEach((function(i){var r=i.player;if(!r.destroyed){var o=i.element,a=e._elementListeners.get(o);a&&a.forEach((function(e){if(e.name==i.triggerName){var n=vv(o,i.triggerName,i.fromState.value,i.toState.value);n._data=t,mv(i.player,e.phase,n,e.callback)}})),r.markedForDestroy?e._engine.afterFlush((function(){r.destroy()})):n.push(i)}})),this._queue=[],n.sort((function(t,n){var i=t.transition.ast.depCount,r=n.transition.ast.depCount;return 0==i||0==r?i-r:e._engine.driver.containsElement(t.element,n.element)?1:-1}))}},{key:"destroy",value:function(t){this.players.forEach((function(t){return t.destroy()})),this._signalRemovalForInnerTriggers(this.hostElement,t)}},{key:"elementContainsData",value:function(t){var e=!1;return this._elementListeners.has(t)&&(e=!0),!!this._queue.find((function(e){return e.element===t}))||e}}]),t}(),Fb=function(){function t(e,n,i){Object(m.a)(this,t),this.bodyNode=e,this.driver=n,this._normalizer=i,this.players=[],this.newHostElements=new Map,this.playersByElement=new Map,this.playersByQueriedElement=new Map,this.statesByElement=new Map,this.disabledNodes=new Set,this.totalAnimations=0,this.totalQueuedPlayers=0,this._namespaceLookup={},this._namespaceList=[],this._flushFns=[],this._whenQuietFns=[],this.namespacesByHostElement=new Map,this.collectedEnterElements=[],this.collectedLeaveElements=[],this.onRemovalComplete=function(t,e){}}return Object(g.a)(t,[{key:"_onRemovalComplete",value:function(t,e){this.onRemovalComplete(t,e)}},{key:"createNamespace",value:function(t,e){var n=new Lb(t,e,this);return e.parentNode?this._balanceNamespaceList(n,e):(this.newHostElements.set(e,n),this.collectEnterElement(e)),this._namespaceLookup[t]=n}},{key:"_balanceNamespaceList",value:function(t,e){var n=this._namespaceList.length-1;if(n>=0){for(var i=!1,r=n;r>=0;r--)if(this.driver.containsElement(this._namespaceList[r].hostElement,e)){this._namespaceList.splice(r+1,0,t),i=!0;break}i||this._namespaceList.splice(0,0,t)}else this._namespaceList.push(t);return this.namespacesByHostElement.set(e,t),t}},{key:"register",value:function(t,e){var n=this._namespaceLookup[t];return n||(n=this.createNamespace(t,e)),n}},{key:"registerTrigger",value:function(t,e,n){var i=this._namespaceLookup[t];i&&i.register(e,n)&&this.totalAnimations++}},{key:"destroy",value:function(t,e){var n=this;if(t){var i=this._fetchNamespace(t);this.afterFlush((function(){n.namespacesByHostElement.delete(i.hostElement),delete n._namespaceLookup[t];var e=n._namespaceList.indexOf(i);e>=0&&n._namespaceList.splice(e,1)})),this.afterFlushAnimationsDone((function(){return i.destroy(e)}))}}},{key:"_fetchNamespace",value:function(t){return this._namespaceLookup[t]}},{key:"fetchNamespacesByElement",value:function(t){var e=new Set,n=this.statesByElement.get(t);if(n)for(var i=Object.keys(n),r=0;r<i.length;r++){var o=n[i[r]].namespaceId;if(o){var a=this._fetchNamespace(o);a&&e.add(a)}}return e}},{key:"trigger",value:function(t,e,n,i){if(Hb(e)){var r=this._fetchNamespace(t);if(r)return r.trigger(e,n,i),!0}return!1}},{key:"insertNode",value:function(t,e,n,i){if(Hb(e)){var r=e.__ng_removed;if(r&&r.setForRemoval){r.setForRemoval=!1,r.setForMove=!0;var o=this.collectedLeaveElements.indexOf(e);o>=0&&this.collectedLeaveElements.splice(o,1)}if(t){var a=this._fetchNamespace(t);a&&a.insertNode(e,n)}i&&this.collectEnterElement(e)}}},{key:"collectEnterElement",value:function(t){this.collectedEnterElements.push(t)}},{key:"markElementAsDisabled",value:function(t,e){e?this.disabledNodes.has(t)||(this.disabledNodes.add(t),qb(t,"ng-animate-disabled")):this.disabledNodes.has(t)&&(this.disabledNodes.delete(t),Gb(t,"ng-animate-disabled"))}},{key:"removeNode",value:function(t,e,n,i){if(Hb(e)){var r=t?this._fetchNamespace(t):null;if(r?r.removeNode(e,i):this.markElementAsRemoved(t,e,!1,i),n){var o=this.namespacesByHostElement.get(e);o&&o.id!==t&&o.removeNode(e,i)}}else this._onRemovalComplete(e,i)}},{key:"markElementAsRemoved",value:function(t,e,n,i){this.collectedLeaveElements.push(e),e.__ng_removed={namespaceId:t,setForRemoval:i,hasAnimation:n,removedBeforeQueried:!1}}},{key:"listen",value:function(t,e,n,i,r){return Hb(e)?this._fetchNamespace(t).listen(e,n,i,r):function(){}}},{key:"_buildInstruction",value:function(t,e,n,i,r){return t.transition.build(this.driver,t.element,t.fromState.value,t.toState.value,n,i,t.fromState.options,t.toState.options,e,r)}},{key:"destroyInnerAnimations",value:function(t){var e=this,n=this.driver.query(t,".ng-trigger",!0);n.forEach((function(t){return e.destroyActiveAnimationsForElement(t)})),0!=this.playersByQueriedElement.size&&(n=this.driver.query(t,".ng-animating",!0)).forEach((function(t){return e.finishActiveQueriedAnimationOnElement(t)}))}},{key:"destroyActiveAnimationsForElement",value:function(t){var e=this.playersByElement.get(t);e&&e.forEach((function(t){t.queued?t.markedForDestroy=!0:t.destroy()}))}},{key:"finishActiveQueriedAnimationOnElement",value:function(t){var e=this.playersByQueriedElement.get(t);e&&e.forEach((function(t){return t.finish()}))}},{key:"whenRenderingDone",value:function(){var t=this;return new Promise((function(e){if(t.players.length)return fv(t.players).onDone((function(){return e()}));e()}))}},{key:"processLeaveNode",value:function(t){var e=this,n=t.__ng_removed;if(n&&n.setForRemoval){if(t.__ng_removed=jb,n.namespaceId){this.destroyInnerAnimations(t);var i=this._fetchNamespace(n.namespaceId);i&&i.clearElementCache(t)}this._onRemovalComplete(t,n.setForRemoval)}this.driver.matchesElement(t,".ng-animate-disabled")&&this.markElementAsDisabled(t,!1),this.driver.query(t,".ng-animate-disabled",!0).forEach((function(t){e.markElementAsDisabled(t,!1)}))}},{key:"flush",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-1,n=[];if(this.newHostElements.size&&(this.newHostElements.forEach((function(e,n){return t._balanceNamespaceList(e,n)})),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(var i=0;i<this.collectedEnterElements.length;i++){var r=this.collectedEnterElements[i];qb(r,"ng-star-inserted")}if(this._namespaceList.length&&(this.totalQueuedPlayers||this.collectedLeaveElements.length)){var o=[];try{n=this._flushAnimations(o,e)}finally{for(var a=0;a<o.length;a++)o[a]()}}else for(var s=0;s<this.collectedLeaveElements.length;s++){var c=this.collectedLeaveElements[s];this.processLeaveNode(c)}if(this.totalQueuedPlayers=0,this.collectedEnterElements.length=0,this.collectedLeaveElements.length=0,this._flushFns.forEach((function(t){return t()})),this._flushFns=[],this._whenQuietFns.length){var l=this._whenQuietFns;this._whenQuietFns=[],n.length?fv(n).onDone((function(){l.forEach((function(t){return t()}))})):l.forEach((function(t){return t()}))}}},{key:"reportError",value:function(t){throw new Error("Unable to process animations due to the following failed trigger transitions\n ".concat(t.join("\n")))}},{key:"_flushAnimations",value:function(t,e){var n=this,i=new ub,r=[],o=new Map,a=[],s=new Map,c=new Map,l=new Map,h=new Set;this.disabledNodes.forEach((function(t){h.add(t);for(var e=n.driver.query(t,".ng-animate-queued",!0),i=0;i<e.length;i++)h.add(e[i])}));var d=this.bodyNode,f=Array.from(this.statesByElement.keys()),p=Ub(f,this.collectedEnterElements),m=new Map,g=0;p.forEach((function(t,e){var n="ng-enter"+g++;m.set(e,n),t.forEach((function(t){return qb(t,n)}))}));for(var v=[],b=new Set,y=new Set,_=0;_<this.collectedLeaveElements.length;_++){var w=this.collectedLeaveElements[_],k=w.__ng_removed;k&&k.setForRemoval&&(v.push(w),b.add(w),k.hasAnimation?this.driver.query(w,".ng-star-inserted",!0).forEach((function(t){return b.add(t)})):y.add(w))}var C=new Map,S=Ub(f,Array.from(b));S.forEach((function(t,e){var n="ng-leave"+g++;C.set(e,n),t.forEach((function(t){return qb(t,n)}))})),t.push((function(){p.forEach((function(t,e){var n=m.get(e);t.forEach((function(t){return Gb(t,n)}))})),S.forEach((function(t,e){var n=C.get(e);t.forEach((function(t){return Gb(t,n)}))})),v.forEach((function(t){n.processLeaveNode(t)}))}));for(var x=[],O=[],M=this._namespaceList.length-1;M>=0;M--)this._namespaceList[M].drainQueuedTransitions(e).forEach((function(t){var e=t.player,o=t.element;if(x.push(e),n.collectedEnterElements.length){var u=o.__ng_removed;if(u&&u.setForMove)return void e.destroy()}var h=!d||!n.driver.containsElement(d,o),f=C.get(o),p=m.get(o),g=n._buildInstruction(t,i,p,f,h);if(g.errors&&g.errors.length)O.push(g);else{if(h)return e.onStart((function(){return zv(o,g.fromStyles)})),e.onDestroy((function(){return Hv(o,g.toStyles)})),void r.push(e);if(t.isFallbackTransition)return e.onStart((function(){return zv(o,g.fromStyles)})),e.onDestroy((function(){return Hv(o,g.toStyles)})),void r.push(e);g.timelines.forEach((function(t){return t.stretchStartingKeyframe=!0})),i.append(o,g.timelines),a.push({instruction:g,player:e,element:o}),g.queriedElements.forEach((function(t){return bv(s,t,[]).push(e)})),g.preStyleProps.forEach((function(t,e){var n=Object.keys(t);if(n.length){var i=c.get(e);i||c.set(e,i=new Set),n.forEach((function(t){return i.add(t)}))}})),g.postStyleProps.forEach((function(t,e){var n=Object.keys(t),i=l.get(e);i||l.set(e,i=new Set),n.forEach((function(t){return i.add(t)}))}))}}));if(O.length){var T=[];O.forEach((function(t){T.push("@".concat(t.triggerName," has failed due to:\n")),t.errors.forEach((function(t){return T.push("- ".concat(t,"\n"))}))})),x.forEach((function(t){return t.destroy()})),this.reportError(T)}var E=new Map,P=new Map;a.forEach((function(t){var e=t.element;i.has(e)&&(P.set(e,e),n._beforeAnimationBuild(t.player.namespaceId,t.instruction,E))})),r.forEach((function(t){var e=t.element;n._getPreviousPlayers(e,!1,t.namespaceId,t.triggerName,null).forEach((function(t){bv(E,e,[]).push(t),t.destroy()}))}));var A=v.filter((function(t){return Xb(t,c,l)})),j=new Map;Vb(j,this.driver,y,l,"*").forEach((function(t){Xb(t,c,l)&&A.push(t)}));var I=new Map;p.forEach((function(t,e){Vb(I,n.driver,new Set(t),c,"!")})),A.forEach((function(t){var e=j.get(t),n=I.get(t);j.set(t,Object.assign(Object.assign({},e),n))}));var D=[],R=[],L={};a.forEach((function(t){var e=t.element,a=t.player,s=t.instruction;if(i.has(e)){if(h.has(e))return a.onDestroy((function(){return Hv(e,s.toStyles)})),a.disabled=!0,a.overrideTotalTime(s.totalTime),void r.push(a);var c=L;if(P.size>1){for(var l=e,u=[];l=l.parentNode;){var d=P.get(l);if(d){c=d;break}u.push(l)}u.forEach((function(t){return P.set(t,c)}))}var f=n._buildAnimation(a.namespaceId,s,E,o,I,j);if(a.setRealPlayer(f),c===L)D.push(a);else{var p=n.playersByElement.get(c);p&&p.length&&(a.parentPlayer=fv(p)),r.push(a)}}else zv(e,s.fromStyles),a.onDestroy((function(){return Hv(e,s.toStyles)})),R.push(a),h.has(e)&&r.push(a)})),R.forEach((function(t){var e=o.get(t.element);if(e&&e.length){var n=fv(e);t.setRealPlayer(n)}})),r.forEach((function(t){t.parentPlayer?t.syncPlayerEvents(t.parentPlayer):t.destroy()}));for(var F=0;F<v.length;F++){var N=v[F],B=N.__ng_removed;if(Gb(N,"ng-leave"),!B||!B.hasAnimation){var H=[];if(s.size){var z=s.get(N);z&&z.length&&H.push.apply(H,Object(u.a)(z));for(var V=this.driver.query(N,".ng-animating",!0),U=0;U<V.length;U++){var q=s.get(V[U]);q&&q.length&&H.push.apply(H,Object(u.a)(q))}}var G=H.filter((function(t){return!t.destroyed}));G.length?Wb(this,N,G):this.processLeaveNode(N)}}return v.length=0,D.forEach((function(t){n.players.push(t),t.onDone((function(){t.destroy();var e=n.players.indexOf(t);n.players.splice(e,1)})),t.play()})),D}},{key:"elementContainsData",value:function(t,e){var n=!1,i=e.__ng_removed;return i&&i.setForRemoval&&(n=!0),this.playersByElement.has(e)&&(n=!0),this.playersByQueriedElement.has(e)&&(n=!0),this.statesByElement.has(e)&&(n=!0),this._fetchNamespace(t).elementContainsData(e)||n}},{key:"afterFlush",value:function(t){this._flushFns.push(t)}},{key:"afterFlushAnimationsDone",value:function(t){this._whenQuietFns.push(t)}},{key:"_getPreviousPlayers",value:function(t,e,n,i,r){var o=[];if(e){var a=this.playersByQueriedElement.get(t);a&&(o=a)}else{var s=this.playersByElement.get(t);if(s){var c=!r||"void"==r;s.forEach((function(t){t.queued||(c||t.triggerName==i)&&o.push(t)}))}}return(n||i)&&(o=o.filter((function(t){return!(n&&n!=t.namespaceId||i&&i!=t.triggerName)}))),o}},{key:"_beforeAnimationBuild",value:function(t,e,n){var i,r=this,o=e.element,a=e.isRemovalTransition?void 0:t,s=e.isRemovalTransition?void 0:e.triggerName,c=d(e.timelines);try{var l=function(){var t=i.value.element,c=t!==o,l=bv(n,t,[]);r._getPreviousPlayers(t,c,a,s,e.toState).forEach((function(t){var e=t.getRealPlayer();e.beforeDestroy&&e.beforeDestroy(),t.destroy(),l.push(t)}))};for(c.s();!(i=c.n()).done;)l()}catch(u){c.e(u)}finally{c.f()}zv(o,e.fromStyles)}},{key:"_buildAnimation",value:function(t,e,n,i,r,o){var a=this,s=e.triggerName,c=e.element,l=[],u=new Set,h=new Set,d=e.timelines.map((function(e){var d=e.element;u.add(d);var f=d.__ng_removed;if(f&&f.removedBeforeQueried)return new uv(e.duration,e.delay);var p,m,g=d!==c,v=(p=(n.get(d)||Ab).map((function(t){return t.getRealPlayer()})),m=[],function t(e,n){for(var i=0;i<e.length;i++){var r=e[i];r instanceof hv?t(r.players,n):n.push(r)}}(p,m),m).filter((function(t){return!!t.element&&t.element===d})),b=r.get(d),y=o.get(d),_=pv(a.driver,a._normalizer,d,e.keyframes,b,y),w=a._buildPlayer(e,_,v);if(e.subTimeline&&i&&h.add(d),g){var k=new Nb(t,s,d);k.setRealPlayer(w),l.push(k)}return w}));l.forEach((function(t){bv(a.playersByQueriedElement,t.element,[]).push(t),t.onDone((function(){return function(t,e,n){var i;if(t instanceof Map){if(i=t.get(e)){if(i.length){var r=i.indexOf(n);i.splice(r,1)}0==i.length&&t.delete(e)}}else if(i=t[e]){if(i.length){var o=i.indexOf(n);i.splice(o,1)}0==i.length&&delete t[e]}return i}(a.playersByQueriedElement,t.element,t)}))})),u.forEach((function(t){return qb(t,"ng-animating")}));var f=fv(d);return f.onDestroy((function(){u.forEach((function(t){return Gb(t,"ng-animating")})),Hv(c,e.toStyles)})),h.forEach((function(t){bv(i,t,[]).push(f)})),f}},{key:"_buildPlayer",value:function(t,e,n){return e.length>0?this.driver.animate(t.element,e,t.duration,t.delay,t.easing,n):new uv(t.duration,t.delay)}},{key:"queuedPlayers",get:function(){var t=[];return this._namespaceList.forEach((function(e){e.players.forEach((function(e){e.queued&&t.push(e)}))})),t}}]),t}(),Nb=function(){function t(e,n,i){Object(m.a)(this,t),this.namespaceId=e,this.triggerName=n,this.element=i,this._player=new uv,this._containsRealPlayer=!1,this._queuedCallbacks={},this.destroyed=!1,this.markedForDestroy=!1,this.disabled=!1,this.queued=!0,this.totalTime=0}return Object(g.a)(t,[{key:"setRealPlayer",value:function(t){var e=this;this._containsRealPlayer||(this._player=t,Object.keys(this._queuedCallbacks).forEach((function(n){e._queuedCallbacks[n].forEach((function(e){return mv(t,n,void 0,e)}))})),this._queuedCallbacks={},this._containsRealPlayer=!0,this.overrideTotalTime(t.totalTime),this.queued=!1)}},{key:"getRealPlayer",value:function(){return this._player}},{key:"overrideTotalTime",value:function(t){this.totalTime=t}},{key:"syncPlayerEvents",value:function(t){var e=this,n=this._player;n.triggerCallback&&t.onStart((function(){return n.triggerCallback("start")})),t.onDone((function(){return e.finish()})),t.onDestroy((function(){return e.destroy()}))}},{key:"_queueEvent",value:function(t,e){bv(this._queuedCallbacks,t,[]).push(e)}},{key:"onDone",value:function(t){this.queued&&this._queueEvent("done",t),this._player.onDone(t)}},{key:"onStart",value:function(t){this.queued&&this._queueEvent("start",t),this._player.onStart(t)}},{key:"onDestroy",value:function(t){this.queued&&this._queueEvent("destroy",t),this._player.onDestroy(t)}},{key:"init",value:function(){this._player.init()}},{key:"hasStarted",value:function(){return!this.queued&&this._player.hasStarted()}},{key:"play",value:function(){!this.queued&&this._player.play()}},{key:"pause",value:function(){!this.queued&&this._player.pause()}},{key:"restart",value:function(){!this.queued&&this._player.restart()}},{key:"finish",value:function(){this._player.finish()}},{key:"destroy",value:function(){this.destroyed=!0,this._player.destroy()}},{key:"reset",value:function(){!this.queued&&this._player.reset()}},{key:"setPosition",value:function(t){this.queued||this._player.setPosition(t)}},{key:"getPosition",value:function(){return this.queued?0:this._player.getPosition()}},{key:"triggerCallback",value:function(t){var e=this._player;e.triggerCallback&&e.triggerCallback(t)}}]),t}();function Bb(t){return null!=t?t:null}function Hb(t){return t&&1===t.nodeType}function zb(t,e){var n=t.style.display;return t.style.display=null!=e?e:"none",n}function Vb(t,e,n,i,r){var o=[];n.forEach((function(t){return o.push(zb(t))}));var a=[];i.forEach((function(n,i){var o={};n.forEach((function(t){var n=o[t]=e.computeStyle(i,t,r);n&&0!=n.length||(i.__ng_removed=Ib,a.push(i))})),t.set(i,o)}));var s=0;return n.forEach((function(t){return zb(t,o[s++])})),a}function Ub(t,e){var n=new Map;if(t.forEach((function(t){return n.set(t,[])})),0==e.length)return n;var i=new Set(e),r=new Map;return e.forEach((function(t){var e=function t(e){if(!e)return 1;var o=r.get(e);if(o)return o;var a=e.parentNode;return o=n.has(a)?a:i.has(a)?1:t(a),r.set(e,o),o}(t);1!==e&&n.get(e).push(t)})),n}function qb(t,e){if(t.classList)t.classList.add(e);else{var n=t.$$classes;n||(n=t.$$classes={}),n[e]=!0}}function Gb(t,e){if(t.classList)t.classList.remove(e);else{var n=t.$$classes;n&&delete n[e]}}function Wb(t,e,n){fv(n).onDone((function(){return t.processLeaveNode(e)}))}function Kb(t,e){var n=Object.keys(t),i=Object.keys(e);if(n.length!=i.length)return!1;for(var r=0;r<n.length;r++){var o=n[r];if(!e.hasOwnProperty(o)||t[o]!==e[o])return!1}return!0}function Xb(t,e,n){var i=n.get(t);if(!i)return!1;var r=e.get(t);return r?i.forEach((function(t){return r.add(t)})):e.set(t,i),n.delete(t),!0}var Yb=function(){function t(e,n,i){var r=this;Object(m.a)(this,t),this.bodyNode=e,this._driver=n,this._triggerCache={},this.onRemovalComplete=function(t,e){},this._transitionEngine=new Fb(e,n,i),this._timelineEngine=new Pb(e,n,i),this._transitionEngine.onRemovalComplete=function(t,e){return r.onRemovalComplete(t,e)}}return Object(g.a)(t,[{key:"registerTrigger",value:function(t,e,n,i,r){var o=t+"-"+i,a=this._triggerCache[o];if(!a){var s=[],c=ib(this._driver,r,s);if(s.length)throw new Error('The animation trigger "'.concat(i,'" has failed to build due to the following errors:\n - ').concat(s.join("\n - ")));a=function(t,e){return new Mb(t,e)}(i,c),this._triggerCache[o]=a}this._transitionEngine.registerTrigger(e,i,a)}},{key:"register",value:function(t,e){this._transitionEngine.register(t,e)}},{key:"destroy",value:function(t,e){this._transitionEngine.destroy(t,e)}},{key:"onInsert",value:function(t,e,n,i){this._transitionEngine.insertNode(t,e,n,i)}},{key:"onRemove",value:function(t,e,n,i){this._transitionEngine.removeNode(t,e,i||!1,n)}},{key:"disableAnimations",value:function(t,e){this._transitionEngine.markElementAsDisabled(t,e)}},{key:"process",value:function(t,e,n,i){if("@"==n.charAt(0)){var r=l(yv(n),2);this._timelineEngine.command(r[0],e,r[1],i)}else this._transitionEngine.trigger(t,e,n,i)}},{key:"listen",value:function(t,e,n,i,r){if("@"==n.charAt(0)){var o=l(yv(n),2);return this._timelineEngine.listen(o[0],e,o[1],r)}return this._transitionEngine.listen(t,e,n,i,r)}},{key:"flush",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-1;this._transitionEngine.flush(t)}},{key:"whenRenderingDone",value:function(){return this._transitionEngine.whenRenderingDone()}},{key:"players",get:function(){return this._transitionEngine.players.concat(this._timelineEngine.players)}}]),t}();function Zb(t,e){var n=null,i=null;return Array.isArray(e)&&e.length?(n=$b(e[0]),e.length>1&&(i=$b(e[e.length-1]))):e&&(n=$b(e)),n||i?new Qb(t,n,i):null}var Qb=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._element=e,this._startStyles=n,this._endStyles=i,this._state=0;var r=t.initialStylesByElement.get(e);r||t.initialStylesByElement.set(e,r={}),this._initialStyles=r}return Object(g.a)(t,[{key:"start",value:function(){this._state<1&&(this._startStyles&&Hv(this._element,this._startStyles,this._initialStyles),this._state=1)}},{key:"finish",value:function(){this.start(),this._state<2&&(Hv(this._element,this._initialStyles),this._endStyles&&(Hv(this._element,this._endStyles),this._endStyles=null),this._state=1)}},{key:"destroy",value:function(){this.finish(),this._state<3&&(t.initialStylesByElement.delete(this._element),this._startStyles&&(zv(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(zv(this._element,this._endStyles),this._endStyles=null),Hv(this._element,this._initialStyles),this._state=3)}}]),t}();return t.initialStylesByElement=new WeakMap,t}();function $b(t){for(var e=null,n=Object.keys(t),i=0;i<n.length;i++){var r=n[i];Jb(r)&&((e=e||{})[r]=t[r])}return e}function Jb(t){return"display"===t||"position"===t}var ty=function(){function t(e,n,i,r,o,a,s){var c=this;Object(m.a)(this,t),this._element=e,this._name=n,this._duration=i,this._delay=r,this._easing=o,this._fillMode=a,this._onDoneFn=s,this._finished=!1,this._destroyed=!1,this._startTime=0,this._position=0,this._eventFn=function(t){return c._handleCallback(t)}}return Object(g.a)(t,[{key:"apply",value:function(){var t,e,n;t=this._element,e="".concat(this._duration,"ms ").concat(this._easing," ").concat(this._delay,"ms 1 normal ").concat(this._fillMode," ").concat(this._name),(n=ay(t,"").trim()).length&&(function(t,e){for(var n=0;n<t.length;n++)","===t.charAt(n)&&0}(n),e="".concat(n,", ").concat(e)),oy(t,"",e),ry(this._element,this._eventFn,!1),this._startTime=Date.now()}},{key:"pause",value:function(){ey(this._element,this._name,"paused")}},{key:"resume",value:function(){ey(this._element,this._name,"running")}},{key:"setPosition",value:function(t){var e=ny(this._element,this._name);this._position=t*this._duration,oy(this._element,"Delay","-".concat(this._position,"ms"),e)}},{key:"getPosition",value:function(){return this._position}},{key:"_handleCallback",value:function(t){var e=t._ngTestManualTimestamp||Date.now(),n=1e3*parseFloat(t.elapsedTime.toFixed(3));t.animationName==this._name&&Math.max(e-this._startTime,0)>=this._delay&&n>=this._duration&&this.finish()}},{key:"finish",value:function(){this._finished||(this._finished=!0,this._onDoneFn(),ry(this._element,this._eventFn,!0))}},{key:"destroy",value:function(){var t,e,n,i;this._destroyed||(this._destroyed=!0,this.finish(),e=this._name,(i=iy(n=ay(t=this._element,"").split(","),e))>=0&&(n.splice(i,1),oy(t,"",n.join(","))))}}]),t}();function ey(t,e,n){oy(t,"PlayState",n,ny(t,e))}function ny(t,e){var n=ay(t,"");return n.indexOf(",")>0?iy(n.split(","),e):iy([n],e)}function iy(t,e){for(var n=0;n<t.length;n++)if(t[n].indexOf(e)>=0)return n;return-1}function ry(t,e,n){n?t.removeEventListener("animationend",e):t.addEventListener("animationend",e)}function oy(t,e,n,i){var r="animation"+e;if(null!=i){var o=t.style[r];if(o.length){var a=o.split(",");a[i]=n,n=a.join(",")}}t.style[r]=n}function ay(t,e){return t.style["animation"+e]}var sy=function(){function t(e,n,i,r,o,a,s,c){Object(m.a)(this,t),this.element=e,this.keyframes=n,this.animationName=i,this._duration=r,this._delay=o,this._finalStyles=s,this._specialStyles=c,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._started=!1,this.currentSnapshot={},this._state=0,this.easing=a||"linear",this.totalTime=r+o,this._buildStyler()}return Object(g.a)(t,[{key:"onStart",value:function(t){this._onStartFns.push(t)}},{key:"onDone",value:function(t){this._onDoneFns.push(t)}},{key:"onDestroy",value:function(t){this._onDestroyFns.push(t)}},{key:"destroy",value:function(){this.init(),this._state>=4||(this._state=4,this._styler.destroy(),this._flushStartFns(),this._flushDoneFns(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach((function(t){return t()})),this._onDestroyFns=[])}},{key:"_flushDoneFns",value:function(){this._onDoneFns.forEach((function(t){return t()})),this._onDoneFns=[]}},{key:"_flushStartFns",value:function(){this._onStartFns.forEach((function(t){return t()})),this._onStartFns=[]}},{key:"finish",value:function(){this.init(),this._state>=3||(this._state=3,this._styler.finish(),this._flushStartFns(),this._specialStyles&&this._specialStyles.finish(),this._flushDoneFns())}},{key:"setPosition",value:function(t){this._styler.setPosition(t)}},{key:"getPosition",value:function(){return this._styler.getPosition()}},{key:"hasStarted",value:function(){return this._state>=2}},{key:"init",value:function(){this._state>=1||(this._state=1,this._styler.apply(),this._delay&&this._styler.pause())}},{key:"play",value:function(){this.init(),this.hasStarted()||(this._flushStartFns(),this._state=2,this._specialStyles&&this._specialStyles.start()),this._styler.resume()}},{key:"pause",value:function(){this.init(),this._styler.pause()}},{key:"restart",value:function(){this.reset(),this.play()}},{key:"reset",value:function(){this._styler.destroy(),this._buildStyler(),this._styler.apply()}},{key:"_buildStyler",value:function(){var t=this;this._styler=new ty(this.element,this.animationName,this._duration,this._delay,this.easing,"forwards",(function(){return t.finish()}))}},{key:"triggerCallback",value:function(t){var e="start"==t?this._onStartFns:this._onDoneFns;e.forEach((function(t){return t()})),e.length=0}},{key:"beforeDestroy",value:function(){var t=this;this.init();var e={};if(this.hasStarted()){var n=this._state>=3;Object.keys(this._finalStyles).forEach((function(i){"offset"!=i&&(e[i]=n?t._finalStyles[i]:$v(t.element,i))}))}this.currentSnapshot=e}}]),t}(),cy=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this)).element=t,r._startingStyles={},r.__initialized=!1,r._styles=Pv(i),r}return Object(g.a)(n,[{key:"init",value:function(){var t=this;!this.__initialized&&this._startingStyles&&(this.__initialized=!0,Object.keys(this._styles).forEach((function(e){t._startingStyles[e]=t.element.style[e]})),Object(o.a)(Object(a.a)(n.prototype),"init",this).call(this))}},{key:"play",value:function(){var t=this;this._startingStyles&&(this.init(),Object.keys(this._styles).forEach((function(e){return t.element.style.setProperty(e,t._styles[e])})),Object(o.a)(Object(a.a)(n.prototype),"play",this).call(this))}},{key:"destroy",value:function(){var t=this;this._startingStyles&&(Object.keys(this._startingStyles).forEach((function(e){var n=t._startingStyles[e];n?t.element.style.setProperty(e,n):t.element.style.removeProperty(e)})),this._startingStyles=null,Object(o.a)(Object(a.a)(n.prototype),"destroy",this).call(this))}}]),n}(uv),ly=function(){function t(){Object(m.a)(this,t),this._count=0,this._head=document.querySelector("head"),this._warningIssued=!1}return Object(g.a)(t,[{key:"validateStyleProperty",value:function(t){return Ov(t)}},{key:"matchesElement",value:function(t,e){return Mv(t,e)}},{key:"containsElement",value:function(t,e){return Tv(t,e)}},{key:"query",value:function(t,e,n){return Ev(t,e,n)}},{key:"computeStyle",value:function(t,e,n){return window.getComputedStyle(t)[e]}},{key:"buildKeyframeElement",value:function(t,e,n){n=n.map((function(t){return Pv(t)}));var i="@keyframes ".concat(e," {\n"),r="";n.forEach((function(t){r=" ";var e=parseFloat(t.offset);i+="".concat(r).concat(100*e,"% {\n"),r+=" ",Object.keys(t).forEach((function(e){var n=t[e];switch(e){case"offset":return;case"easing":return void(n&&(i+="".concat(r,"animation-timing-function: ").concat(n,";\n")));default:return void(i+="".concat(r).concat(e,": ").concat(n,";\n"))}})),i+="".concat(r,"}\n")})),i+="}\n";var o=document.createElement("style");return o.innerHTML=i,o}},{key:"animate",value:function(t,e,n,i,r){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:[],a=arguments.length>6?arguments[6]:void 0;a&&this._notifyFaultyScrubber();var s=o.filter((function(t){return t instanceof sy})),c={};Yv(n,i)&&s.forEach((function(t){var e=t.currentSnapshot;Object.keys(e).forEach((function(t){return c[t]=e[t]}))}));var l=uy(e=Zv(t,e,c));if(0==n)return new cy(t,l);var u="".concat("gen_css_kf_").concat(this._count++),h=this.buildKeyframeElement(t,u,e);document.querySelector("head").appendChild(h);var d=Zb(t,e),f=new sy(t,e,u,n,i,r,l,d);return f.onDestroy((function(){return hy(h)})),f}},{key:"_notifyFaultyScrubber",value:function(){this._warningIssued||(console.warn("@angular/animations: please load the web-animations.js polyfill to allow programmatic access...\n"," visit http://bit.ly/IWukam to learn more about using the web-animation-js polyfill."),this._warningIssued=!0)}}]),t}();function uy(t){var e={};return t&&(Array.isArray(t)?t:[t]).forEach((function(t){Object.keys(t).forEach((function(n){"offset"!=n&&"easing"!=n&&(e[n]=t[n])}))})),e}function hy(t){t.parentNode.removeChild(t)}var dy=function(){function t(e,n,i,r){Object(m.a)(this,t),this.element=e,this.keyframes=n,this.options=i,this._specialStyles=r,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._initialized=!1,this._finished=!1,this._started=!1,this._destroyed=!1,this.time=0,this.parentPlayer=null,this.currentSnapshot={},this._duration=i.duration,this._delay=i.delay||0,this.time=this._duration+this._delay}return Object(g.a)(t,[{key:"_onFinish",value:function(){this._finished||(this._finished=!0,this._onDoneFns.forEach((function(t){return t()})),this._onDoneFns=[])}},{key:"init",value:function(){this._buildPlayer(),this._preparePlayerBeforeStart()}},{key:"_buildPlayer",value:function(){var t=this;if(!this._initialized){this._initialized=!0;var e=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,e,this.options),this._finalKeyframe=e.length?e[e.length-1]:{},this.domPlayer.addEventListener("finish",(function(){return t._onFinish()}))}}},{key:"_preparePlayerBeforeStart",value:function(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}},{key:"_triggerWebAnimation",value:function(t,e,n){return t.animate(e,n)}},{key:"onStart",value:function(t){this._onStartFns.push(t)}},{key:"onDone",value:function(t){this._onDoneFns.push(t)}},{key:"onDestroy",value:function(t){this._onDestroyFns.push(t)}},{key:"play",value:function(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach((function(t){return t()})),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}},{key:"pause",value:function(){this.init(),this.domPlayer.pause()}},{key:"finish",value:function(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}},{key:"reset",value:function(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1}},{key:"_resetDomPlayerState",value:function(){this.domPlayer&&this.domPlayer.cancel()}},{key:"restart",value:function(){this.reset(),this.play()}},{key:"hasStarted",value:function(){return this._started}},{key:"destroy",value:function(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach((function(t){return t()})),this._onDestroyFns=[])}},{key:"setPosition",value:function(t){this.domPlayer.currentTime=t*this.time}},{key:"getPosition",value:function(){return this.domPlayer.currentTime/this.time}},{key:"beforeDestroy",value:function(){var t=this,e={};this.hasStarted()&&Object.keys(this._finalKeyframe).forEach((function(n){"offset"!=n&&(e[n]=t._finished?t._finalKeyframe[n]:$v(t.element,n))})),this.currentSnapshot=e}},{key:"triggerCallback",value:function(t){var e="start"==t?this._onStartFns:this._onDoneFns;e.forEach((function(t){return t()})),e.length=0}},{key:"totalTime",get:function(){return this._delay+this._duration}}]),t}(),fy=function(){function t(){Object(m.a)(this,t),this._isNativeImpl=/\{\s*\[native\s+code\]\s*\}/.test(py().toString()),this._cssKeyframesDriver=new ly}return Object(g.a)(t,[{key:"validateStyleProperty",value:function(t){return Ov(t)}},{key:"matchesElement",value:function(t,e){return Mv(t,e)}},{key:"containsElement",value:function(t,e){return Tv(t,e)}},{key:"query",value:function(t,e,n){return Ev(t,e,n)}},{key:"computeStyle",value:function(t,e,n){return window.getComputedStyle(t)[e]}},{key:"overrideWebAnimationsSupport",value:function(t){this._isNativeImpl=t}},{key:"animate",value:function(t,e,n,i,r){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:[],a=arguments.length>6?arguments[6]:void 0,s=!a&&!this._isNativeImpl;if(s)return this._cssKeyframesDriver.animate(t,e,n,i,r,o);var c=0==i?"both":"forwards",l={duration:n,delay:i,fill:c};r&&(l.easing=r);var u={},h=o.filter((function(t){return t instanceof dy}));Yv(n,i)&&h.forEach((function(t){var e=t.currentSnapshot;Object.keys(e).forEach((function(t){return u[t]=e[t]}))}));var d=Zb(t,e=Zv(t,e=e.map((function(t){return Fv(t,!1)})),u));return new dy(t,e,l,d)}}]),t}();function py(){return"undefined"!=typeof window&&void 0!==window.document&&Element.prototype.animate||{}}var my=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this))._nextAnimationId=0,r._renderer=t.createRenderer(i.body,{id:"0",encapsulation:Lt.None,styles:[],data:{animation:[]}}),r}return Object(g.a)(n,[{key:"build",value:function(t){var e=this._nextAnimationId.toString();this._nextAnimationId++;var n=Array.isArray(t)?nv(t):t;return by(this._renderer,null,e,"register",[n]),new gy(e,this._renderer)}}]),n}(Qg);return t.\u0275fac=function(e){return new(e||t)(_t(Gs),_t(du))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),gy=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this))._id=t,r._renderer=i,r}return Object(g.a)(n,[{key:"create",value:function(t,e){return new vy(this._id,t,e||{},this._renderer)}}]),n}($g),vy=function(){function t(e,n,i,r){Object(m.a)(this,t),this.id=e,this.element=n,this._renderer=r,this.parentPlayer=null,this._started=!1,this.totalTime=0,this._command("create",i)}return Object(g.a)(t,[{key:"_listen",value:function(t,e){return this._renderer.listen(this.element,"@@".concat(this.id,":").concat(t),e)}},{key:"_command",value:function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];return by(this._renderer,this.element,this.id,t,n)}},{key:"onDone",value:function(t){this._listen("done",t)}},{key:"onStart",value:function(t){this._listen("start",t)}},{key:"onDestroy",value:function(t){this._listen("destroy",t)}},{key:"init",value:function(){this._command("init")}},{key:"hasStarted",value:function(){return this._started}},{key:"play",value:function(){this._command("play"),this._started=!0}},{key:"pause",value:function(){this._command("pause")}},{key:"restart",value:function(){this._command("restart")}},{key:"finish",value:function(){this._command("finish")}},{key:"destroy",value:function(){this._command("destroy")}},{key:"reset",value:function(){this._command("reset")}},{key:"setPosition",value:function(t){this._command("setPosition",t)}},{key:"getPosition",value:function(){return 0}}]),t}();function by(t,e,n,i,r){return t.setProperty(e,"@@".concat(n,":").concat(i),r)}var yy=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this.delegate=e,this.engine=n,this._zone=i,this._currentId=0,this._microtaskId=1,this._animationCallbacksBuffer=[],this._rendererCache=new Map,this._cdRecurDepth=0,this.promise=Promise.resolve(0),n.onRemovalComplete=function(t,e){e&&e.parentNode(t)&&e.removeChild(t.parentNode,t)}}return Object(g.a)(t,[{key:"createRenderer",value:function(t,e){var n=this,i=this.delegate.createRenderer(t,e);if(!(t&&e&&e.data&&e.data.animation)){var r=this._rendererCache.get(i);return r||(r=new _y("",i,this.engine),this._rendererCache.set(i,r)),r}var o=e.id,a=e.id+"-"+this._currentId;return this._currentId++,this.engine.register(a,t),e.data.animation.forEach((function e(i){Array.isArray(i)?i.forEach(e):n.engine.registerTrigger(o,a,t,i.name,i)})),new wy(this,a,i,this.engine)}},{key:"begin",value:function(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}},{key:"_scheduleCountTask",value:function(){var t=this;this.promise.then((function(){t._microtaskId++}))}},{key:"scheduleListenerCallback",value:function(t,e,n){var i=this;t>=0&&t<this._microtaskId?this._zone.run((function(){return e(n)})):(0==this._animationCallbacksBuffer.length&&Promise.resolve(null).then((function(){i._zone.run((function(){i._animationCallbacksBuffer.forEach((function(t){var e=l(t,2);(0,e[0])(e[1])})),i._animationCallbacksBuffer=[]}))})),this._animationCallbacksBuffer.push([e,n]))}},{key:"end",value:function(){var t=this;this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular((function(){t._scheduleCountTask(),t.engine.flush(t._microtaskId)})),this.delegate.end&&this.delegate.end()}},{key:"whenRenderingDone",value:function(){return this.engine.whenRenderingDone()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Gs),_t(Yb),_t(jl))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),_y=function(){function t(e,n,i){Object(m.a)(this,t),this.namespaceId=e,this.delegate=n,this.engine=i,this.destroyNode=this.delegate.destroyNode?function(t){return n.destroyNode(t)}:null}return Object(g.a)(t,[{key:"destroy",value:function(){this.engine.destroy(this.namespaceId,this.delegate),this.delegate.destroy()}},{key:"createElement",value:function(t,e){return this.delegate.createElement(t,e)}},{key:"createComment",value:function(t){return this.delegate.createComment(t)}},{key:"createText",value:function(t){return this.delegate.createText(t)}},{key:"appendChild",value:function(t,e){this.delegate.appendChild(t,e),this.engine.onInsert(this.namespaceId,e,t,!1)}},{key:"insertBefore",value:function(t,e,n){this.delegate.insertBefore(t,e,n),this.engine.onInsert(this.namespaceId,e,t,!0)}},{key:"removeChild",value:function(t,e,n){this.engine.onRemove(this.namespaceId,e,this.delegate,n)}},{key:"selectRootElement",value:function(t,e){return this.delegate.selectRootElement(t,e)}},{key:"parentNode",value:function(t){return this.delegate.parentNode(t)}},{key:"nextSibling",value:function(t){return this.delegate.nextSibling(t)}},{key:"setAttribute",value:function(t,e,n,i){this.delegate.setAttribute(t,e,n,i)}},{key:"removeAttribute",value:function(t,e,n){this.delegate.removeAttribute(t,e,n)}},{key:"addClass",value:function(t,e){this.delegate.addClass(t,e)}},{key:"removeClass",value:function(t,e){this.delegate.removeClass(t,e)}},{key:"setStyle",value:function(t,e,n,i){this.delegate.setStyle(t,e,n,i)}},{key:"removeStyle",value:function(t,e,n){this.delegate.removeStyle(t,e,n)}},{key:"setProperty",value:function(t,e,n){"@"==e.charAt(0)&&"@.disabled"==e?this.disableAnimations(t,!!n):this.delegate.setProperty(t,e,n)}},{key:"setValue",value:function(t,e){this.delegate.setValue(t,e)}},{key:"listen",value:function(t,e,n){return this.delegate.listen(t,e,n)}},{key:"disableAnimations",value:function(t,e){this.engine.disableAnimations(t,e)}},{key:"data",get:function(){return this.delegate.data}}]),t}(),wy=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,i,r,o)).factory=t,a.namespaceId=i,a}return Object(g.a)(n,[{key:"setProperty",value:function(t,e,n){"@"==e.charAt(0)?"."==e.charAt(1)&&"@.disabled"==e?this.disableAnimations(t,n=void 0===n||!!n):this.engine.process(this.namespaceId,t,e.substr(1),n):this.delegate.setProperty(t,e,n)}},{key:"listen",value:function(t,e,n){var i,r,o=this;if("@"==e.charAt(0)){var a=function(t){switch(t){case"body":return document.body;case"document":return document;case"window":return window;default:return t}}(t),s=e.substr(1),c="";if("@"!=s.charAt(0)){var u=l((r=(i=s).indexOf("."),[i.substring(0,r),i.substr(r+1)]),2);s=u[0],c=u[1]}return this.engine.listen(this.namespaceId,a,s,c,(function(t){o.factory.scheduleListenerCallback(t._data||-1,n,t)}))}return this.delegate.listen(t,e,n)}}]),n}(_y),ky=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){return Object(m.a)(this,n),e.call(this,t.body,i,r)}return n}(Yb);return t.\u0275fac=function(e){return new(e||t)(_t(du),_t(jv),_t(_b))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),Cy=new ht("AnimationModuleType"),Sy=[{provide:Qg,useClass:my},{provide:_b,useFactory:function(){return new wb}},{provide:Yb,useClass:ky},{provide:Gs,useFactory:function(t,e,n){return new yy(t,e,n)},deps:[jd,Yb,jl]}],xy=[{provide:jv,useFactory:function(){return"function"==typeof py()?new fy:new ly}},{provide:Cy,useValue:"BrowserAnimations"}].concat(Sy),Oy=([{provide:jv,useClass:Av},{provide:Cy,useValue:"NoopAnimations"}].concat(Sy),function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:xy,imports:[Wd]}),t}()),My=function(t,e){return t<e?-1:t>e?1:t>=e?0:NaN},Ty=function(t){var e;return 1===t.length&&(e=t,t=function(t,n){return My(e(t),n)}),{left:function(e,n,i,r){for(null==i&&(i=0),null==r&&(r=e.length);i<r;){var o=i+r>>>1;t(e[o],n)<0?i=o+1:r=o}return i},right:function(e,n,i,r){for(null==i&&(i=0),null==r&&(r=e.length);i<r;){var o=i+r>>>1;t(e[o],n)>0?r=o:i=o+1}return i}}},Ey=Ty(My),Py=Ey.right,Ay=Ey.left,jy=Py,Iy=function(t,e){null==e&&(e=Dy);for(var n=0,i=t.length-1,r=t[0],o=new Array(i<0?0:i);n<i;)o[n]=e(r,r=t[++n]);return o};function Dy(t,e){return[t,e]}var Ry=function(t,e,n){var i,r,o,a,s=t.length,c=e.length,l=new Array(s*c);for(null==n&&(n=Dy),i=o=0;i<s;++i)for(a=t[i],r=0;r<c;++r,++o)l[o]=n(a,e[r]);return l},Ly=function(t,e){return e<t?-1:e>t?1:e>=t?0:NaN},Fy=function(t){return null===t?NaN:+t},Ny=function(t,e){var n,i,r=t.length,o=0,a=-1,s=0,c=0;if(null==e)for(;++a<r;)isNaN(n=Fy(t[a]))||(c+=(i=n-s)*(n-(s+=i/++o)));else for(;++a<r;)isNaN(n=Fy(e(t[a],a,t)))||(c+=(i=n-s)*(n-(s+=i/++o)));if(o>1)return c/(o-1)},By=function(t,e){var n=Ny(t,e);return n?Math.sqrt(n):n},Hy=function(t,e){var n,i,r,o=t.length,a=-1;if(null==e){for(;++a<o;)if(null!=(n=t[a])&&n>=n)for(i=r=n;++a<o;)null!=(n=t[a])&&(i>n&&(i=n),r<n&&(r=n))}else for(;++a<o;)if(null!=(n=e(t[a],a,t))&&n>=n)for(i=r=n;++a<o;)null!=(n=e(t[a],a,t))&&(i>n&&(i=n),r<n&&(r=n));return[i,r]},zy=Array.prototype,Vy=zy.slice,Uy=zy.map,qy=function(t){return function(){return t}},Gy=function(t){return t},Wy=function(t,e,n){t=+t,e=+e,n=(r=arguments.length)<2?(e=t,t=0,1):r<3?1:+n;for(var i=-1,r=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(r);++i<r;)o[i]=t+i*n;return o},Ky=Math.sqrt(50),Xy=Math.sqrt(10),Yy=Math.sqrt(2),Zy=function(t,e,n){var i,r,o,a,s=-1;if(n=+n,(t=+t)==(e=+e)&&n>0)return[t];if((i=e<t)&&(r=t,t=e,e=r),0===(a=Qy(t,e,n))||!isFinite(a))return[];if(a>0)for(t=Math.ceil(t/a),e=Math.floor(e/a),o=new Array(r=Math.ceil(e-t+1));++s<r;)o[s]=(t+s)*a;else for(t=Math.floor(t*a),e=Math.ceil(e*a),o=new Array(r=Math.ceil(t-e+1));++s<r;)o[s]=(t-s)/a;return i&&o.reverse(),o};function Qy(t,e,n){var i=(e-t)/Math.max(0,n),r=Math.floor(Math.log(i)/Math.LN10),o=i/Math.pow(10,r);return r>=0?(o>=Ky?10:o>=Xy?5:o>=Yy?2:1)*Math.pow(10,r):-Math.pow(10,-r)/(o>=Ky?10:o>=Xy?5:o>=Yy?2:1)}function $y(t,e,n){var i=Math.abs(e-t)/Math.max(0,n),r=Math.pow(10,Math.floor(Math.log(i)/Math.LN10)),o=i/r;return o>=Ky?r*=10:o>=Xy?r*=5:o>=Yy&&(r*=2),e<t?-r:r}var Jy=function(t){return Math.ceil(Math.log(t.length)/Math.LN2)+1},t_=function(){var t=Gy,e=Hy,n=Jy;function i(i){var r,o,a=i.length,s=new Array(a);for(r=0;r<a;++r)s[r]=t(i[r],r,i);var c=e(s),l=c[0],u=c[1],h=n(s,l,u);Array.isArray(h)||(h=$y(l,u,h),h=Wy(Math.ceil(l/h)*h,u,h));for(var d=h.length;h[0]<=l;)h.shift(),--d;for(;h[d-1]>u;)h.pop(),--d;var f,p=new Array(d+1);for(r=0;r<=d;++r)(f=p[r]=[]).x0=r>0?h[r-1]:l,f.x1=r<d?h[r]:u;for(r=0;r<a;++r)l<=(o=s[r])&&o<=u&&p[jy(h,o,0,d)].push(i[r]);return p}return i.value=function(e){return arguments.length?(t="function"==typeof e?e:qy(e),i):t},i.domain=function(t){return arguments.length?(e="function"==typeof t?t:qy([t[0],t[1]]),i):e},i.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:Array.isArray(t)?qy(Vy.call(t)):qy(t),i):n},i},e_=function(t,e,n){if(null==n&&(n=Fy),i=t.length){if((e=+e)<=0||i<2)return+n(t[0],0,t);if(e>=1)return+n(t[i-1],i-1,t);var i,r=(i-1)*e,o=Math.floor(r),a=+n(t[o],o,t);return a+(+n(t[o+1],o+1,t)-a)*(r-o)}},n_=function(t,e,n){return t=Uy.call(t,Fy).sort(My),Math.ceil((n-e)/(2*(e_(t,.75)-e_(t,.25))*Math.pow(t.length,-1/3)))},i_=function(t,e,n){return Math.ceil((n-e)/(3.5*By(t)*Math.pow(t.length,-1/3)))},r_=function(t,e){var n,i,r=t.length,o=-1;if(null==e){for(;++o<r;)if(null!=(n=t[o])&&n>=n)for(i=n;++o<r;)null!=(n=t[o])&&n>i&&(i=n)}else for(;++o<r;)if(null!=(n=e(t[o],o,t))&&n>=n)for(i=n;++o<r;)null!=(n=e(t[o],o,t))&&n>i&&(i=n);return i},o_=function(t,e){var n,i=t.length,r=i,o=-1,a=0;if(null==e)for(;++o<i;)isNaN(n=Fy(t[o]))?--r:a+=n;else for(;++o<i;)isNaN(n=Fy(e(t[o],o,t)))?--r:a+=n;if(r)return a/r},a_=function(t,e){var n,i=t.length,r=-1,o=[];if(null==e)for(;++r<i;)isNaN(n=Fy(t[r]))||o.push(n);else for(;++r<i;)isNaN(n=Fy(e(t[r],r,t)))||o.push(n);return e_(o.sort(My),.5)},s_=function(t){for(var e,n,i,r=t.length,o=-1,a=0;++o<r;)a+=t[o].length;for(n=new Array(a);--r>=0;)for(e=(i=t[r]).length;--e>=0;)n[--a]=i[e];return n},c_=function(t,e){var n,i,r=t.length,o=-1;if(null==e){for(;++o<r;)if(null!=(n=t[o])&&n>=n)for(i=n;++o<r;)null!=(n=t[o])&&i>n&&(i=n)}else for(;++o<r;)if(null!=(n=e(t[o],o,t))&&n>=n)for(i=n;++o<r;)null!=(n=e(t[o],o,t))&&i>n&&(i=n);return i},l_=function(t,e){for(var n=e.length,i=new Array(n);n--;)i[n]=t[e[n]];return i},u_=function(t,e){if(n=t.length){var n,i,r=0,o=0,a=t[o];for(null==e&&(e=My);++r<n;)(e(i=t[r],a)<0||0!==e(a,a))&&(a=i,o=r);return 0===e(a,a)?o:void 0}},h_=function(t,e,n){for(var i,r,o=(null==n?t.length:n)-(e=null==e?0:+e);o;)r=Math.random()*o--|0,i=t[o+e],t[o+e]=t[r+e],t[r+e]=i;return t},d_=function(t,e){var n,i=t.length,r=-1,o=0;if(null==e)for(;++r<i;)(n=+t[r])&&(o+=n);else for(;++r<i;)(n=+e(t[r],r,t))&&(o+=n);return o},f_=function(t){if(!(r=t.length))return[];for(var e=-1,n=c_(t,p_),i=new Array(n);++e<n;)for(var r,o=-1,a=i[e]=new Array(r);++o<r;)a[o]=t[o][e];return i};function p_(t){return t.length}var m_=function(){return f_(arguments)},g_=Array.prototype.slice,v_=function(t){return t};function b_(t){return"translate("+(t+.5)+",0)"}function y_(t){return"translate(0,"+(t+.5)+")"}function __(t){return function(e){return+t(e)}}function w_(t){var e=Math.max(0,t.bandwidth()-1)/2;return t.round()&&(e=Math.round(e)),function(n){return+t(n)+e}}function k_(){return!this.__axis}function C_(t,e){var n=[],i=null,r=null,o=6,a=6,s=3,c=1===t||4===t?-1:1,l=4===t||2===t?"x":"y",u=1===t||3===t?b_:y_;function h(h){var d=null==i?e.ticks?e.ticks.apply(e,n):e.domain():i,f=null==r?e.tickFormat?e.tickFormat.apply(e,n):v_:r,p=Math.max(o,0)+s,m=e.range(),g=+m[0]+.5,v=+m[m.length-1]+.5,b=(e.bandwidth?w_:__)(e.copy()),y=h.selection?h.selection():h,_=y.selectAll(".domain").data([null]),w=y.selectAll(".tick").data(d,e).order(),k=w.exit(),C=w.enter().append("g").attr("class","tick"),S=w.select("line"),x=w.select("text");_=_.merge(_.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),w=w.merge(C),S=S.merge(C.append("line").attr("stroke","currentColor").attr(l+"2",c*o)),x=x.merge(C.append("text").attr("fill","currentColor").attr(l,c*p).attr("dy",1===t?"0em":3===t?"0.71em":"0.32em")),h!==y&&(_=_.transition(h),w=w.transition(h),S=S.transition(h),x=x.transition(h),k=k.transition(h).attr("opacity",1e-6).attr("transform",(function(t){return isFinite(t=b(t))?u(t):this.getAttribute("transform")})),C.attr("opacity",1e-6).attr("transform",(function(t){var e=this.parentNode.__axis;return u(e&&isFinite(e=e(t))?e:b(t))}))),k.remove(),_.attr("d",4===t||2==t?a?"M"+c*a+","+g+"H0.5V"+v+"H"+c*a:"M0.5,"+g+"V"+v:a?"M"+g+","+c*a+"V0.5H"+v+"V"+c*a:"M"+g+",0.5H"+v),w.attr("opacity",1).attr("transform",(function(t){return u(b(t))})),S.attr(l+"2",c*o),x.attr(l,c*p).text(f),y.filter(k_).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",2===t?"start":4===t?"end":"middle"),y.each((function(){this.__axis=b}))}return h.scale=function(t){return arguments.length?(e=t,h):e},h.ticks=function(){return n=g_.call(arguments),h},h.tickArguments=function(t){return arguments.length?(n=null==t?[]:g_.call(t),h):n.slice()},h.tickValues=function(t){return arguments.length?(i=null==t?null:g_.call(t),h):i&&i.slice()},h.tickFormat=function(t){return arguments.length?(r=t,h):r},h.tickSize=function(t){return arguments.length?(o=a=+t,h):o},h.tickSizeInner=function(t){return arguments.length?(o=+t,h):o},h.tickSizeOuter=function(t){return arguments.length?(a=+t,h):a},h.tickPadding=function(t){return arguments.length?(s=+t,h):s},h}function S_(t){return C_(1,t)}function x_(t){return C_(2,t)}function O_(t){return C_(3,t)}function M_(t){return C_(4,t)}var T_={value:function(){}};function E_(){for(var t,e=0,n=arguments.length,i={};e<n;++e){if(!(t=arguments[e]+"")||t in i||/[\s.]/.test(t))throw new Error("illegal type: "+t);i[t]=[]}return new P_(i)}function P_(t){this._=t}function A_(t,e){return t.trim().split(/^|\s+/).map((function(t){var n="",i=t.indexOf(".");if(i>=0&&(n=t.slice(i+1),t=t.slice(0,i)),t&&!e.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))}function j_(t,e){for(var n,i=0,r=t.length;i<r;++i)if((n=t[i]).name===e)return n.value}function I_(t,e,n){for(var i=0,r=t.length;i<r;++i)if(t[i].name===e){t[i]=T_,t=t.slice(0,i).concat(t.slice(i+1));break}return null!=n&&t.push({name:e,value:n}),t}P_.prototype=E_.prototype={constructor:P_,on:function(t,e){var n,i=this._,r=A_(t+"",i),o=-1,a=r.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++o<a;)if(n=(t=r[o]).type)i[n]=I_(i[n],t.name,e);else if(null==e)for(n in i)i[n]=I_(i[n],t.name,null);return this}for(;++o<a;)if((n=(t=r[o]).type)&&(n=j_(i[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new P_(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,i,r=new Array(n),o=0;o<n;++o)r[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=0,n=(i=this._[t]).length;o<n;++o)i[o].value.apply(e,r)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var i=this._[t],r=0,o=i.length;r<o;++r)i[r].value.apply(e,n)}};var D_=E_;function R_(){}var L_=function(t){return null==t?R_:function(){return this.querySelector(t)}};function F_(){return[]}var N_=function(t){return null==t?F_:function(){return this.querySelectorAll(t)}},B_=function(t){return function(){return this.matches(t)}},H_=function(t){return new Array(t.length)};function z_(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function V_(t,e,n,i,r,o){for(var a,s=0,c=e.length,l=o.length;s<l;++s)(a=e[s])?(a.__data__=o[s],i[s]=a):n[s]=new z_(t,o[s]);for(;s<c;++s)(a=e[s])&&(r[s]=a)}function U_(t,e,n,i,r,o,a){var s,c,l,u={},h=e.length,d=o.length,f=new Array(h);for(s=0;s<h;++s)(c=e[s])&&(f[s]=l="$"+a.call(c,c.__data__,s,e),l in u?r[s]=c:u[l]=c);for(s=0;s<d;++s)(c=u[l="$"+a.call(t,o[s],s,o)])?(i[s]=c,c.__data__=o[s],u[l]=null):n[s]=new z_(t,o[s]);for(s=0;s<h;++s)(c=e[s])&&u[f[s]]===c&&(r[s]=c)}function q_(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}z_.prototype={constructor:z_,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var G_="http://www.w3.org/1999/xhtml",W_={svg:"http://www.w3.org/2000/svg",xhtml:G_,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},K_=function(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),W_.hasOwnProperty(e)?{space:W_[e],local:t}:t};function X_(t){return function(){this.removeAttribute(t)}}function Y_(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Z_(t,e){return function(){this.setAttribute(t,e)}}function Q_(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function $_(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function J_(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}var tw=function(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView};function ew(t){return function(){this.style.removeProperty(t)}}function nw(t,e,n){return function(){this.style.setProperty(t,e,n)}}function iw(t,e,n){return function(){var i=e.apply(this,arguments);null==i?this.style.removeProperty(t):this.style.setProperty(t,i,n)}}function rw(t,e){return t.style.getPropertyValue(e)||tw(t).getComputedStyle(t,null).getPropertyValue(e)}function ow(t){return function(){delete this[t]}}function aw(t,e){return function(){this[t]=e}}function sw(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function cw(t){return t.trim().split(/^|\s+/)}function lw(t){return t.classList||new uw(t)}function uw(t){this._node=t,this._names=cw(t.getAttribute("class")||"")}function hw(t,e){for(var n=lw(t),i=-1,r=e.length;++i<r;)n.add(e[i])}function dw(t,e){for(var n=lw(t),i=-1,r=e.length;++i<r;)n.remove(e[i])}function fw(t){return function(){hw(this,t)}}function pw(t){return function(){dw(this,t)}}function mw(t,e){return function(){(e.apply(this,arguments)?hw:dw)(this,t)}}function gw(){this.textContent=""}function vw(t){return function(){this.textContent=t}}function bw(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function yw(){this.innerHTML=""}function _w(t){return function(){this.innerHTML=t}}function ww(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function kw(){this.nextSibling&&this.parentNode.appendChild(this)}function Cw(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Sw(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===G_&&e.documentElement.namespaceURI===G_?e.createElement(t):e.createElementNS(n,t)}}function xw(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}uw.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var Ow=function(t){var e=K_(t);return(e.local?xw:Sw)(e)};function Mw(){return null}function Tw(){var t=this.parentNode;t&&t.removeChild(this)}function Ew(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Pw(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}var Aw={},jw=null;function Iw(t,e,n){return t=Dw(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function Dw(t,e,n){return function(i){var r=jw;jw=i;try{t.call(this,this.__data__,e,n)}finally{jw=r}}}function Rw(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}function Lw(t){return function(){var e=this.__on;if(e){for(var n,i=0,r=-1,o=e.length;i<o;++i)n=e[i],t.type&&n.type!==t.type||n.name!==t.name?e[++r]=n:this.removeEventListener(n.type,n.listener,n.capture);++r?e.length=r:delete this.__on}}}function Fw(t,e,n){var i=Aw.hasOwnProperty(t.type)?Iw:Dw;return function(r,o,a){var s,c=this.__on,l=i(e,o,a);if(c)for(var u=0,h=c.length;u<h;++u)if((s=c[u]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=l,s.capture=n),void(s.value=e);this.addEventListener(t.type,l,n),s={type:t.type,name:t.name,value:e,listener:l,capture:n},c?c.push(s):this.__on=[s]}}function Nw(t,e,n,i){var r=jw;t.sourceEvent=jw,jw=t;try{return e.apply(n,i)}finally{jw=r}}function Bw(t,e,n){var i=tw(t),r=i.CustomEvent;"function"==typeof r?r=new r(e,n):(r=i.document.createEvent("Event"),n?(r.initEvent(e,n.bubbles,n.cancelable),r.detail=n.detail):r.initEvent(e,!1,!1)),t.dispatchEvent(r)}function Hw(t,e){return function(){return Bw(this,t,e)}}function zw(t,e){return function(){return Bw(this,t,e.apply(this,arguments))}}"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(Aw={mouseenter:"mouseover",mouseleave:"mouseout"}));var Vw=[null];function Uw(t,e){this._groups=t,this._parents=e}function qw(){return new Uw([[document.documentElement]],Vw)}Uw.prototype=qw.prototype={constructor:Uw,select:function(t){"function"!=typeof t&&(t=L_(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o,a,s=e[r],c=s.length,l=i[r]=new Array(c),u=0;u<c;++u)(o=s[u])&&(a=t.call(o,o.__data__,u,s))&&("__data__"in o&&(a.__data__=o.__data__),l[u]=a);return new Uw(i,this._parents)},selectAll:function(t){"function"!=typeof t&&(t=N_(t));for(var e=this._groups,n=e.length,i=[],r=[],o=0;o<n;++o)for(var a,s=e[o],c=s.length,l=0;l<c;++l)(a=s[l])&&(i.push(t.call(a,a.__data__,l,s)),r.push(a));return new Uw(i,r)},filter:function(t){"function"!=typeof t&&(t=B_(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o,a=e[r],s=a.length,c=i[r]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&c.push(o);return new Uw(i,this._parents)},data:function(t,e){if(!t)return p=new Array(this.size()),u=-1,this.each((function(t){p[++u]=t})),p;var n,i=e?U_:V_,r=this._parents,o=this._groups;"function"!=typeof t&&(n=t,t=function(){return n});for(var a=o.length,s=new Array(a),c=new Array(a),l=new Array(a),u=0;u<a;++u){var h=r[u],d=o[u],f=d.length,p=t.call(h,h&&h.__data__,u,r),m=p.length,g=c[u]=new Array(m),v=s[u]=new Array(m);i(h,d,g,v,l[u]=new Array(f),p,e);for(var b,y,_=0,w=0;_<m;++_)if(b=g[_]){for(_>=w&&(w=_+1);!(y=v[w])&&++w<m;);b._next=y||null}}return(s=new Uw(s,r))._enter=c,s._exit=l,s},enter:function(){return new Uw(this._enter||this._groups.map(H_),this._parents)},exit:function(){return new Uw(this._exit||this._groups.map(H_),this._parents)},join:function(t,e,n){var i=this.enter(),r=this,o=this.exit();return i="function"==typeof t?t(i):i.append(t+""),null!=e&&(r=e(r)),null==n?o.remove():n(o),i&&r?i.merge(r).order():r},merge:function(t){for(var e=this._groups,n=t._groups,i=e.length,r=Math.min(i,n.length),o=new Array(i),a=0;a<r;++a)for(var s,c=e[a],l=n[a],u=c.length,h=o[a]=new Array(u),d=0;d<u;++d)(s=c[d]||l[d])&&(h[d]=s);for(;a<i;++a)o[a]=e[a];return new Uw(o,this._parents)},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var i,r=t[e],o=r.length-1,a=r[o];--o>=0;)(i=r[o])&&(a&&4^i.compareDocumentPosition(a)&&a.parentNode.insertBefore(i,a),a=i);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=q_);for(var n=this._groups,i=n.length,r=new Array(i),o=0;o<i;++o){for(var a,s=n[o],c=s.length,l=r[o]=new Array(c),u=0;u<c;++u)(a=s[u])&&(l[u]=a);l.sort(e)}return new Uw(r,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){var t=new Array(this.size()),e=-1;return this.each((function(){t[++e]=this})),t},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var i=t[e],r=0,o=i.length;r<o;++r){var a=i[r];if(a)return a}return null},size:function(){var t=0;return this.each((function(){++t})),t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,i=e.length;n<i;++n)for(var r,o=e[n],a=0,s=o.length;a<s;++a)(r=o[a])&&t.call(r,r.__data__,a,o);return this},attr:function(t,e){var n=K_(t);if(arguments.length<2){var i=this.node();return n.local?i.getAttributeNS(n.space,n.local):i.getAttribute(n)}return this.each((null==e?n.local?Y_:X_:"function"==typeof e?n.local?J_:$_:n.local?Q_:Z_)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?ew:"function"==typeof e?iw:nw)(t,e,null==n?"":n)):rw(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?ow:"function"==typeof e?sw:aw)(t,e)):this.node()[t]},classed:function(t,e){var n=cw(t+"");if(arguments.length<2){for(var i=lw(this.node()),r=-1,o=n.length;++r<o;)if(!i.contains(n[r]))return!1;return!0}return this.each(("function"==typeof e?mw:e?fw:pw)(n,e))},text:function(t){return arguments.length?this.each(null==t?gw:("function"==typeof t?bw:vw)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?yw:("function"==typeof t?ww:_w)(t)):this.node().innerHTML},raise:function(){return this.each(kw)},lower:function(){return this.each(Cw)},append:function(t){var e="function"==typeof t?t:Ow(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:Ow(t),i=null==e?Mw:"function"==typeof e?e:L_(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)}))},remove:function(){return this.each(Tw)},clone:function(t){return this.select(t?Pw:Ew)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var i,r,o=Rw(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?Fw:Lw,null==n&&(n=!1),i=0;i<a;++i)this.each(s(o[i],e,n));return this}var s=this.node().__on;if(s)for(var c,l=0,u=s.length;l<u;++l)for(i=0,c=s[l];i<a;++i)if((r=o[i]).type===c.type&&r.name===c.name)return c.value},dispatch:function(t,e){return this.each(("function"==typeof e?zw:Hw)(t,e))}};var Gw=qw,Ww=function(t){return"string"==typeof t?new Uw([[document.querySelector(t)]],[document.documentElement]):new Uw([[t]],Vw)};function Kw(){jw.stopImmediatePropagation()}var Xw=function(){jw.preventDefault(),jw.stopImmediatePropagation()},Yw=function(t){var e=t.document.documentElement,n=Ww(t).on("dragstart.drag",Xw,!0);"onselectstart"in e?n.on("selectstart.drag",Xw,!0):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")};function Zw(t,e){var n=t.document.documentElement,i=Ww(t).on("dragstart.drag",null);e&&(i.on("click.drag",Xw,!0),setTimeout((function(){i.on("click.drag",null)}),0)),"onselectstart"in n?i.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}var Qw=function(t,e,n){t.prototype=e.prototype=n,n.constructor=t};function $w(t,e){var n=Object.create(t.prototype);for(var i in e)n[i]=e[i];return n}function Jw(){}var tk="\\s*([+-]?\\d+)\\s*",ek="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",nk="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",ik=/^#([0-9a-f]{3,8})$/,rk=new RegExp("^rgb\\("+[tk,tk,tk]+"\\)$"),ok=new RegExp("^rgb\\("+[nk,nk,nk]+"\\)$"),ak=new RegExp("^rgba\\("+[tk,tk,tk,ek]+"\\)$"),sk=new RegExp("^rgba\\("+[nk,nk,nk,ek]+"\\)$"),ck=new RegExp("^hsl\\("+[ek,nk,nk]+"\\)$"),lk=new RegExp("^hsla\\("+[ek,nk,nk,ek]+"\\)$"),uk={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function hk(){return this.rgb().formatHex()}function dk(){return this.rgb().formatRgb()}function fk(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=ik.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?pk(e):3===n?new bk(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?mk(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?mk(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=rk.exec(t))?new bk(e[1],e[2],e[3],1):(e=ok.exec(t))?new bk(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=ak.exec(t))?mk(e[1],e[2],e[3],e[4]):(e=sk.exec(t))?mk(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=ck.exec(t))?kk(e[1],e[2]/100,e[3]/100,1):(e=lk.exec(t))?kk(e[1],e[2]/100,e[3]/100,e[4]):uk.hasOwnProperty(t)?pk(uk[t]):"transparent"===t?new bk(NaN,NaN,NaN,0):null}function pk(t){return new bk(t>>16&255,t>>8&255,255&t,1)}function mk(t,e,n,i){return i<=0&&(t=e=n=NaN),new bk(t,e,n,i)}function gk(t){return t instanceof Jw||(t=fk(t)),t?new bk((t=t.rgb()).r,t.g,t.b,t.opacity):new bk}function vk(t,e,n,i){return 1===arguments.length?gk(t):new bk(t,e,n,null==i?1:i)}function bk(t,e,n,i){this.r=+t,this.g=+e,this.b=+n,this.opacity=+i}function yk(){return"#"+wk(this.r)+wk(this.g)+wk(this.b)}function _k(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function wk(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function kk(t,e,n,i){return i<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new xk(t,e,n,i)}function Ck(t){if(t instanceof xk)return new xk(t.h,t.s,t.l,t.opacity);if(t instanceof Jw||(t=fk(t)),!t)return new xk;if(t instanceof xk)return t;var e=(t=t.rgb()).r/255,n=t.g/255,i=t.b/255,r=Math.min(e,n,i),o=Math.max(e,n,i),a=NaN,s=o-r,c=(o+r)/2;return s?(a=e===o?(n-i)/s+6*(n<i):n===o?(i-e)/s+2:(e-n)/s+4,s/=c<.5?o+r:2-o-r,a*=60):s=c>0&&c<1?0:a,new xk(a,s,c,t.opacity)}function Sk(t,e,n,i){return 1===arguments.length?Ck(t):new xk(t,e,n,null==i?1:i)}function xk(t,e,n,i){this.h=+t,this.s=+e,this.l=+n,this.opacity=+i}function Ok(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function Mk(t,e,n,i,r){var o=t*t,a=o*t;return((1-3*t+3*o-a)*e+(4-6*o+3*a)*n+(1+3*t+3*o-3*a)*i+a*r)/6}Qw(Jw,fk,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:hk,formatHex:hk,formatHsl:function(){return Ck(this).formatHsl()},formatRgb:dk,toString:dk}),Qw(bk,vk,$w(Jw,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new bk(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new bk(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:yk,formatHex:yk,formatRgb:_k,toString:_k})),Qw(xk,Sk,$w(Jw,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new xk(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new xk(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*e,r=2*n-i;return new bk(Ok(t>=240?t-240:t+120,r,i),Ok(t,r,i),Ok(t<120?t+240:t-120,r,i),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var Tk=function(t){return function(){return t}};function Ek(t,e){return function(n){return t+n*e}}function Pk(t,e){var n=e-t;return n?Ek(t,n):Tk(isNaN(t)?e:t)}var Ak=function t(e){var n=function(t){return 1==(t=+t)?Pk:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(i){return Math.pow(t+i*e,n)}}(e,n,t):Tk(isNaN(e)?n:e)}}(e);function i(t,e){var i=n((t=vk(t)).r,(e=vk(e)).r),r=n(t.g,e.g),o=n(t.b,e.b),a=Pk(t.opacity,e.opacity);return function(e){return t.r=i(e),t.g=r(e),t.b=o(e),t.opacity=a(e),t+""}}return i.gamma=t,i}(1);function jk(t){return function(e){var n,i,r=e.length,o=new Array(r),a=new Array(r),s=new Array(r);for(n=0;n<r;++n)i=vk(e[n]),o[n]=i.r||0,a[n]=i.g||0,s[n]=i.b||0;return o=t(o),a=t(a),s=t(s),i.opacity=1,function(t){return i.r=o(t),i.g=a(t),i.b=s(t),i+""}}}var Ik=jk((function(t){var e=t.length-1;return function(n){var i=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),r=t[i],o=t[i+1];return Mk((n-i/e)*e,i>0?t[i-1]:2*r-o,r,o,i<e-1?t[i+2]:2*o-r)}})),Dk=(jk((function(t){var e=t.length;return function(n){var i=Math.floor(((n%=1)<0?++n:n)*e);return Mk((n-i/e)*e,t[(i+e-1)%e],t[i%e],t[(i+1)%e],t[(i+2)%e])}})),function(t,e){e||(e=[]);var n,i=t?Math.min(e.length,t.length):0,r=e.slice();return function(o){for(n=0;n<i;++n)r[n]=t[n]*(1-o)+e[n]*o;return r}});function Rk(t,e){var n,i=e?e.length:0,r=t?Math.min(i,t.length):0,o=new Array(r),a=new Array(i);for(n=0;n<r;++n)o[n]=qk(t[n],e[n]);for(;n<i;++n)a[n]=e[n];return function(t){for(n=0;n<r;++n)a[n]=o[n](t);return a}}var Lk,Fk,Nk=function(t,e){var n=new Date;return t=+t,e=+e,function(i){return n.setTime(t*(1-i)+e*i),n}},Bk=function(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}},Hk=function(t,e){var n,i={},r={};for(n in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)n in t?i[n]=qk(t[n],e[n]):r[n]=e[n];return function(t){for(n in i)r[n]=i[n](t);return r}},zk=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Vk=new RegExp(zk.source,"g"),Uk=function(t,e){var n,i,r,o=zk.lastIndex=Vk.lastIndex=0,a=-1,s=[],c=[];for(t+="",e+="";(n=zk.exec(t))&&(i=Vk.exec(e));)(r=i.index)>o&&(r=e.slice(o,r),s[a]?s[a]+=r:s[++a]=r),(n=n[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,c.push({i:a,x:Bk(n,i)})),o=Vk.lastIndex;return o<e.length&&(r=e.slice(o),s[a]?s[a]+=r:s[++a]=r),s.length<2?c[0]?function(t){return function(e){return t(e)+""}}(c[0].x):function(t){return function(){return t}}(e):(e=c.length,function(t){for(var n,i=0;i<e;++i)s[(n=c[i]).i]=n.x(t);return s.join("")})},qk=function(t,e){var n,i,r=typeof e;return null==e||"boolean"===r?Tk(e):("number"===r?Bk:"string"===r?(n=fk(e))?(e=n,Ak):Uk:e instanceof fk?Ak:e instanceof Date?Nk:(i=e,!ArrayBuffer.isView(i)||i instanceof DataView?Array.isArray(e)?Rk:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?Hk:Bk:Dk))(t,e)},Gk=function(){for(var t,e=jw;t=e.sourceEvent;)e=t;return e},Wk=function(t,e){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var i=n.createSVGPoint();return i.x=e.clientX,i.y=e.clientY,[(i=i.matrixTransform(t.getScreenCTM().inverse())).x,i.y]}var r=t.getBoundingClientRect();return[e.clientX-r.left-t.clientLeft,e.clientY-r.top-t.clientTop]},Kk=function(t){var e=Gk();return e.changedTouches&&(e=e.changedTouches[0]),Wk(t,e)},Xk=0,Yk=0,Zk=0,Qk=0,$k=0,Jk=0,tC="object"==typeof performance&&performance.now?performance:Date,eC="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function nC(){return $k||(eC(iC),$k=tC.now()+Jk)}function iC(){$k=0}function rC(){this._call=this._time=this._next=null}function oC(t,e,n){var i=new rC;return i.restart(t,e,n),i}function aC(){nC(),++Xk;for(var t,e=Lk;e;)(t=$k-e._time)>=0&&e._call.call(null,t),e=e._next;--Xk}function sC(){$k=(Qk=tC.now())+Jk,Xk=Yk=0;try{aC()}finally{Xk=0,function(){for(var t,e,n=Lk,i=1/0;n;)n._call?(i>n._time&&(i=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:Lk=e);Fk=t,lC(i)}(),$k=0}}function cC(){var t=tC.now(),e=t-Qk;e>1e3&&(Jk-=e,Qk=t)}function lC(t){Xk||(Yk&&(Yk=clearTimeout(Yk)),t-$k>24?(t<1/0&&(Yk=setTimeout(sC,t-tC.now()-Jk)),Zk&&(Zk=clearInterval(Zk))):(Zk||(Qk=tC.now(),Zk=setInterval(cC,1e3)),Xk=1,eC(sC)))}rC.prototype=oC.prototype={constructor:rC,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?nC():+n)+(null==e?0:+e),this._next||Fk===this||(Fk?Fk._next=this:Lk=this,Fk=this),this._call=t,this._time=n,lC()},stop:function(){this._call&&(this._call=null,this._time=1/0,lC())}};var uC=function(t,e,n){var i=new rC;return i.restart((function(n){i.stop(),t(n+e)}),e=null==e?0:+e,n),i},hC=D_("start","end","cancel","interrupt"),dC=[],fC=function(t,e,n,i,r,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var i,r=t.__transition;function o(c){var l,u,h,d;if(1!==n.state)return s();for(l in r)if((d=r[l]).name===n.name){if(3===d.state)return uC(o);4===d.state?(d.state=6,d.timer.stop(),d.on.call("interrupt",t,t.__data__,d.index,d.group),delete r[l]):+l<e&&(d.state=6,d.timer.stop(),d.on.call("cancel",t,t.__data__,d.index,d.group),delete r[l])}if(uC((function(){3===n.state&&(n.state=4,n.timer.restart(a,n.delay,n.time),a(c))})),n.state=2,n.on.call("start",t,t.__data__,n.index,n.group),2===n.state){for(n.state=3,i=new Array(h=n.tween.length),l=0,u=-1;l<h;++l)(d=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(i[++u]=d);i.length=u+1}}function a(e){for(var r=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(s),n.state=5,1),o=-1,a=i.length;++o<a;)i[o].call(t,r);5===n.state&&(n.on.call("end",t,t.__data__,n.index,n.group),s())}function s(){for(var i in n.state=6,n.timer.stop(),delete r[e],r)return;delete t.__transition}r[e]=n,n.timer=oC((function(t){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=t&&o(t-n.delay)}),0,n.time)}(t,n,{name:e,index:i,group:r,on:hC,tween:dC,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})};function pC(t,e){var n=gC(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function mC(t,e){var n=gC(t,e);if(n.state>3)throw new Error("too late; already running");return n}function gC(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}var vC,bC,yC,_C,wC=function(t,e){var n,i,r,o=t.__transition,a=!0;if(o){for(r in e=null==e?null:e+"",o)(n=o[r]).name===e?(i=n.state>2&&n.state<5,n.state=6,n.timer.stop(),n.on.call(i?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete o[r]):a=!1;a&&delete t.__transition}},kC=180/Math.PI,CC={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1},SC=function(t,e,n,i,r,o){var a,s,c;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(c=t*n+e*i)&&(n-=t*c,i-=e*c),(s=Math.sqrt(n*n+i*i))&&(n/=s,i/=s,c/=s),t*i<e*n&&(t=-t,e=-e,c=-c,a=-a),{translateX:r,translateY:o,rotate:Math.atan2(e,t)*kC,skewX:Math.atan(c)*kC,scaleX:a,scaleY:s}};function xC(t,e,n,i){function r(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],c=[];return o=t(o),a=t(a),function(t,i,r,o,a,s){if(t!==r||i!==o){var c=a.push("translate(",null,e,null,n);s.push({i:c-4,x:Bk(t,r)},{i:c-2,x:Bk(i,o)})}else(r||o)&&a.push("translate("+r+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,c),function(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(r(n)+"rotate(",null,i)-2,x:Bk(t,e)})):e&&n.push(r(n)+"rotate("+e+i)}(o.rotate,a.rotate,s,c),function(t,e,n,o){t!==e?o.push({i:n.push(r(n)+"skewX(",null,i)-2,x:Bk(t,e)}):e&&n.push(r(n)+"skewX("+e+i)}(o.skewX,a.skewX,s,c),function(t,e,n,i,o,a){if(t!==n||e!==i){var s=o.push(r(o)+"scale(",null,",",null,")");a.push({i:s-4,x:Bk(t,n)},{i:s-2,x:Bk(e,i)})}else 1===n&&1===i||o.push(r(o)+"scale("+n+","+i+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,c),o=a=null,function(t){for(var e,n=-1,i=c.length;++n<i;)s[(e=c[n]).i]=e.x(t);return s.join("")}}}var OC=xC((function(t){return"none"===t?CC:(vC||(vC=document.createElement("DIV"),bC=document.documentElement,yC=document.defaultView),vC.style.transform=t,t=yC.getComputedStyle(bC.appendChild(vC),null).getPropertyValue("transform"),bC.removeChild(vC),t=t.slice(7,-1).split(","),SC(+t[0],+t[1],+t[2],+t[3],+t[4],+t[5]))}),"px, ","px)","deg)"),MC=xC((function(t){return null==t?CC:(_C||(_C=document.createElementNS("http://www.w3.org/2000/svg","g")),_C.setAttribute("transform",t),(t=_C.transform.baseVal.consolidate())?SC((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):CC)}),", ",")",")");function TC(t,e){var n,i;return function(){var r=mC(this,t),o=r.tween;if(o!==n)for(var a=0,s=(i=n=o).length;a<s;++a)if(i[a].name===e){(i=i.slice()).splice(a,1);break}r.tween=i}}function EC(t,e,n){var i,r;if("function"!=typeof n)throw new Error;return function(){var o=mC(this,t),a=o.tween;if(a!==i){r=(i=a).slice();for(var s={name:e,value:n},c=0,l=r.length;c<l;++c)if(r[c].name===e){r[c]=s;break}c===l&&r.push(s)}o.tween=r}}function PC(t,e,n){var i=t._id;return t.each((function(){var t=mC(this,i);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return gC(t,i).value[e]}}var AC=function(t,e){var n;return("number"==typeof e?Bk:e instanceof fk?Ak:(n=fk(e))?(e=n,Ak):Uk)(t,e)};function jC(t){return function(){this.removeAttribute(t)}}function IC(t){return function(){this.removeAttributeNS(t.space,t.local)}}function DC(t,e,n){var i,r,o=n+"";return function(){var a=this.getAttribute(t);return a===o?null:a===i?r:r=e(i=a,n)}}function RC(t,e,n){var i,r,o=n+"";return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===i?r:r=e(i=a,n)}}function LC(t,e,n){var i,r,o;return function(){var a,s,c=n(this);if(null!=c)return(a=this.getAttribute(t))===(s=c+"")?null:a===i&&s===r?o:(r=s,o=e(i=a,c));this.removeAttribute(t)}}function FC(t,e,n){var i,r,o;return function(){var a,s,c=n(this);if(null!=c)return(a=this.getAttributeNS(t.space,t.local))===(s=c+"")?null:a===i&&s===r?o:(r=s,o=e(i=a,c));this.removeAttributeNS(t.space,t.local)}}function NC(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function BC(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function HC(t,e){var n,i;function r(){var r=e.apply(this,arguments);return r!==i&&(n=(i=r)&&BC(t,r)),n}return r._value=e,r}function zC(t,e){var n,i;function r(){var r=e.apply(this,arguments);return r!==i&&(n=(i=r)&&NC(t,r)),n}return r._value=e,r}function VC(t,e){return function(){pC(this,t).delay=+e.apply(this,arguments)}}function UC(t,e){return e=+e,function(){pC(this,t).delay=e}}function qC(t,e){return function(){mC(this,t).duration=+e.apply(this,arguments)}}function GC(t,e){return e=+e,function(){mC(this,t).duration=e}}function WC(t,e){if("function"!=typeof e)throw new Error;return function(){mC(this,t).ease=e}}function KC(t,e,n){var i,r,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?pC:mC;return function(){var a=o(this,t),s=a.on;s!==i&&(r=(i=s).copy()).on(e,n),a.on=r}}var XC=Gw.prototype.constructor;function YC(t){return function(){this.style.removeProperty(t)}}function ZC(t,e,n){return function(i){this.style.setProperty(t,e.call(this,i),n)}}function QC(t,e,n){var i,r;function o(){var o=e.apply(this,arguments);return o!==r&&(i=(r=o)&&ZC(t,o,n)),i}return o._value=e,o}function $C(t){return function(e){this.textContent=t.call(this,e)}}function JC(t){var e,n;function i(){var i=t.apply(this,arguments);return i!==n&&(e=(n=i)&&$C(i)),e}return i._value=t,i}var tS=0;function eS(t,e,n,i){this._groups=t,this._parents=e,this._name=n,this._id=i}function nS(t){return Gw().transition(t)}function iS(){return++tS}var rS=Gw.prototype;function oS(t){return t*t*t}function aS(t){return--t*t*t+1}function sS(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}eS.prototype=nS.prototype={constructor:eS,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=L_(t));for(var i=this._groups,r=i.length,o=new Array(r),a=0;a<r;++a)for(var s,c,l=i[a],u=l.length,h=o[a]=new Array(u),d=0;d<u;++d)(s=l[d])&&(c=t.call(s,s.__data__,d,l))&&("__data__"in s&&(c.__data__=s.__data__),h[d]=c,fC(h[d],e,n,d,h,gC(s,n)));return new eS(o,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=N_(t));for(var i=this._groups,r=i.length,o=[],a=[],s=0;s<r;++s)for(var c,l=i[s],u=l.length,h=0;h<u;++h)if(c=l[h]){for(var d,f=t.call(c,c.__data__,h,l),p=gC(c,n),m=0,g=f.length;m<g;++m)(d=f[m])&&fC(d,e,n,m,f,p);o.push(f),a.push(c)}return new eS(o,a,e,n)},filter:function(t){"function"!=typeof t&&(t=B_(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o,a=e[r],s=a.length,c=i[r]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&c.push(o);return new eS(i,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,i=e.length,r=Math.min(i,n.length),o=new Array(i),a=0;a<r;++a)for(var s,c=e[a],l=n[a],u=c.length,h=o[a]=new Array(u),d=0;d<u;++d)(s=c[d]||l[d])&&(h[d]=s);for(;a<i;++a)o[a]=e[a];return new eS(o,this._parents,this._name,this._id)},selection:function(){return new XC(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=iS(),i=this._groups,r=i.length,o=0;o<r;++o)for(var a,s=i[o],c=s.length,l=0;l<c;++l)if(a=s[l]){var u=gC(a,e);fC(a,t,n,l,s,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new eS(i,this._parents,t,n)},call:rS.call,nodes:rS.nodes,node:rS.node,size:rS.size,empty:rS.empty,each:rS.each,on:function(t,e){var n=this._id;return arguments.length<2?gC(this.node(),n).on.on(t):this.each(KC(n,t,e))},attr:function(t,e){var n=K_(t),i="transform"===n?MC:AC;return this.attrTween(t,"function"==typeof e?(n.local?FC:LC)(n,i,PC(this,"attr."+t,e)):null==e?(n.local?IC:jC)(n):(n.local?RC:DC)(n,i,e))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var i=K_(t);return this.tween(n,(i.local?HC:zC)(i,e))},style:function(t,e,n){var i="transform"==(t+="")?OC:AC;return null==e?this.styleTween(t,function(t,e){var n,i,r;return function(){var o=rw(this,t),a=(this.style.removeProperty(t),rw(this,t));return o===a?null:o===n&&a===i?r:r=e(n=o,i=a)}}(t,i)).on("end.style."+t,YC(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var i,r,o;return function(){var a=rw(this,t),s=n(this),c=s+"";return null==s&&(this.style.removeProperty(t),c=s=rw(this,t)),a===c?null:a===i&&c===r?o:(r=c,o=e(i=a,s))}}(t,i,PC(this,"style."+t,e))).each(function(t,e){var n,i,r,o,a="style."+e,s="end."+a;return function(){var c=mC(this,t),l=c.on,u=null==c.value[a]?o||(o=YC(e)):void 0;l===n&&r===u||(i=(n=l).copy()).on(s,r=u),c.on=i}}(this._id,t)):this.styleTween(t,function(t,e,n){var i,r,o=n+"";return function(){var a=rw(this,t);return a===o?null:a===i?r:r=e(i=a,n)}}(t,i,e),n).on("end.style."+t,null)},styleTween:function(t,e,n){var i="style."+(t+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(null==e)return this.tween(i,null);if("function"!=typeof e)throw new Error;return this.tween(i,QC(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(PC(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!=typeof t)throw new Error;return this.tween(e,JC(t))},remove:function(){return this.on("end.remove",(t=this._id,function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}));var t},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var i,r=gC(this.node(),n).tween,o=0,a=r.length;o<a;++o)if((i=r[o]).name===t)return i.value;return null}return this.each((null==e?TC:EC)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?VC:UC)(e,t)):gC(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?qC:GC)(e,t)):gC(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(WC(e,t)):gC(this.node(),e).ease},end:function(){var t,e,n=this,i=n._id,r=n.size();return new Promise((function(o,a){var s={value:a},c={value:function(){0==--r&&o()}};n.each((function(){var n=mC(this,i),r=n.on;r!==t&&((e=(t=r).copy())._.cancel.push(s),e._.interrupt.push(s),e._.end.push(c)),n.on=e}))}))}};var cS={time:null,delay:0,duration:250,ease:sS};function lS(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))return cS.time=nC(),cS;return n}Gw.prototype.interrupt=function(t){return this.each((function(){wC(this,t)}))},Gw.prototype.transition=function(t){var e,n;t instanceof eS?(e=t._id,t=t._name):(e=iS(),(n=cS).time=nC(),t=null==t?null:t+"");for(var i=this._groups,r=i.length,o=0;o<r;++o)for(var a,s=i[o],c=s.length,l=0;l<c;++l)(a=s[l])&&fC(a,t,e,l,s,n||lS(a,e));return new eS(i,this._parents,t,e)};var uS=function(t){return function(){return t}},hS=function(t,e,n){this.target=t,this.type=e,this.selection=n};function dS(){jw.stopImmediatePropagation()}var fS=function(){jw.preventDefault(),jw.stopImmediatePropagation()},pS={name:"drag"},mS={name:"space"},gS={name:"handle"},vS={name:"center"},bS={name:"x",handles:["e","w"].map(OS),input:function(t,e){return t&&[[t[0],e[0][1]],[t[1],e[1][1]]]},output:function(t){return t&&[t[0][0],t[1][0]]}},yS={name:"y",handles:["n","s"].map(OS),input:function(t,e){return t&&[[e[0][0],t[0]],[e[1][0],t[1]]]},output:function(t){return t&&[t[0][1],t[1][1]]}},_S={name:"xy",handles:["n","e","s","w","nw","ne","se","sw"].map(OS),input:function(t){return t},output:function(t){return t}},wS={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},kS={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},CS={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},SS={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},xS={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function OS(t){return{type:t}}function MS(){return!jw.button}function TS(){var t=this.ownerSVGElement||this;return[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]}function ES(t){for(;!t.__brush;)if(!(t=t.parentNode))return;return t.__brush}function PS(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}function AS(t){var e=t.__brush;return e?e.dim.output(e.selection):null}function jS(){return RS(bS)}function IS(){return RS(yS)}var DS=function(){return RS(_S)};function RS(t){var e,n=TS,i=MS,r=D_(a,"start","brush","end"),o=6;function a(e){var n=e.property("__brush",h).selectAll(".overlay").data([OS("overlay")]);n.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",wS.overlay).merge(n).each((function(){var t=ES(this).extent;Ww(this).attr("x",t[0][0]).attr("y",t[0][1]).attr("width",t[1][0]-t[0][0]).attr("height",t[1][1]-t[0][1])})),e.selectAll(".selection").data([OS("selection")]).enter().append("rect").attr("class","selection").attr("cursor",wS.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var i=e.selectAll(".handle").data(t.handles,(function(t){return t.type}));i.exit().remove(),i.enter().append("rect").attr("class",(function(t){return"handle handle--"+t.type})).attr("cursor",(function(t){return wS[t.type]})),e.each(s).attr("fill","none").attr("pointer-events","all").style("-webkit-tap-highlight-color","rgba(0,0,0,0)").on("mousedown.brush touchstart.brush",u)}function s(){var t=Ww(this),e=ES(this).selection;e?(t.selectAll(".selection").style("display",null).attr("x",e[0][0]).attr("y",e[0][1]).attr("width",e[1][0]-e[0][0]).attr("height",e[1][1]-e[0][1]),t.selectAll(".handle").style("display",null).attr("x",(function(t){return"e"===t.type[t.type.length-1]?e[1][0]-o/2:e[0][0]-o/2})).attr("y",(function(t){return"s"===t.type[0]?e[1][1]-o/2:e[0][1]-o/2})).attr("width",(function(t){return"n"===t.type||"s"===t.type?e[1][0]-e[0][0]+o:o})).attr("height",(function(t){return"e"===t.type||"w"===t.type?e[1][1]-e[0][1]+o:o}))):t.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function c(t,e){return t.__brush.emitter||new l(t,e)}function l(t,e){this.that=t,this.args=e,this.state=t.__brush,this.active=0}function u(){if(jw.touches){if(jw.changedTouches.length<jw.touches.length)return fS()}else if(e)return;if(i.apply(this,arguments)){var n,r,o,a,l,u,h,d,f,p,m,g,v,b=this,y=jw.target.__data__.type,_="selection"===(jw.metaKey?y="overlay":y)?pS:jw.altKey?vS:gS,w=t===yS?null:SS[y],k=t===bS?null:xS[y],C=ES(b),S=C.extent,x=C.selection,O=S[0][0],M=S[0][1],T=S[1][0],E=S[1][1],P=w&&k&&jw.shiftKey,A=Kk(b),j=A,I=c(b,arguments).beforestart();"overlay"===y?C.selection=x=[[n=t===yS?O:A[0],o=t===bS?M:A[1]],[l=t===yS?T:n,h=t===bS?E:o]]:(n=x[0][0],o=x[0][1],l=x[1][0],h=x[1][1]),r=n,a=o,u=l,d=h;var D=Ww(b).attr("pointer-events","none"),R=D.selectAll(".overlay").attr("cursor",wS[y]);if(jw.touches)D.on("touchmove.brush",F,!0).on("touchend.brush touchcancel.brush",B,!0);else{var L=Ww(jw.view).on("keydown.brush",H,!0).on("keyup.brush",z,!0).on("mousemove.brush",F,!0).on("mouseup.brush",B,!0);Yw(jw.view)}dS(),wC(b),s.call(b),I.start()}function F(){var t=Kk(b);!P||g||v||(Math.abs(t[0]-j[0])>Math.abs(t[1]-j[1])?v=!0:g=!0),j=t,m=!0,fS(),N()}function N(){var t;switch(f=j[0]-A[0],p=j[1]-A[1],_){case mS:case pS:w&&(f=Math.max(O-n,Math.min(T-l,f)),r=n+f,u=l+f),k&&(p=Math.max(M-o,Math.min(E-h,p)),a=o+p,d=h+p);break;case gS:w<0?(f=Math.max(O-n,Math.min(T-n,f)),r=n+f,u=l):w>0&&(f=Math.max(O-l,Math.min(T-l,f)),r=n,u=l+f),k<0?(p=Math.max(M-o,Math.min(E-o,p)),a=o+p,d=h):k>0&&(p=Math.max(M-h,Math.min(E-h,p)),a=o,d=h+p);break;case vS:w&&(r=Math.max(O,Math.min(T,n-f*w)),u=Math.max(O,Math.min(T,l+f*w))),k&&(a=Math.max(M,Math.min(E,o-p*k)),d=Math.max(M,Math.min(E,h+p*k)))}u<r&&(w*=-1,t=n,n=l,l=t,t=r,r=u,u=t,y in kS&&R.attr("cursor",wS[y=kS[y]])),d<a&&(k*=-1,t=o,o=h,h=t,t=a,a=d,d=t,y in CS&&R.attr("cursor",wS[y=CS[y]])),C.selection&&(x=C.selection),g&&(r=x[0][0],u=x[1][0]),v&&(a=x[0][1],d=x[1][1]),x[0][0]===r&&x[0][1]===a&&x[1][0]===u&&x[1][1]===d||(C.selection=[[r,a],[u,d]],s.call(b),I.brush())}function B(){if(dS(),jw.touches){if(jw.touches.length)return;e&&clearTimeout(e),e=setTimeout((function(){e=null}),500),D.on("touchmove.brush touchend.brush touchcancel.brush",null)}else Zw(jw.view,m),L.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);D.attr("pointer-events","all"),R.attr("cursor",wS.overlay),C.selection&&(x=C.selection),PS(x)&&(C.selection=null,s.call(b)),I.end()}function H(){switch(jw.keyCode){case 16:P=w&&k;break;case 18:_===gS&&(w&&(l=u-f*w,n=r+f*w),k&&(h=d-p*k,o=a+p*k),_=vS,N());break;case 32:_!==gS&&_!==vS||(w<0?l=u-f:w>0&&(n=r-f),k<0?h=d-p:k>0&&(o=a-p),_=mS,R.attr("cursor",wS.selection),N());break;default:return}fS()}function z(){switch(jw.keyCode){case 16:P&&(g=v=P=!1,N());break;case 18:_===vS&&(w<0?l=u:w>0&&(n=r),k<0?h=d:k>0&&(o=a),_=gS,N());break;case 32:_===mS&&(jw.altKey?(w&&(l=u-f*w,n=r+f*w),k&&(h=d-p*k,o=a+p*k),_=vS):(w<0?l=u:w>0&&(n=r),k<0?h=d:k>0&&(o=a),_=gS),R.attr("cursor",wS[y]),N());break;default:return}fS()}}function h(){var e=this.__brush||{selection:null};return e.extent=n.apply(this,arguments),e.dim=t,e}return a.move=function(e,n){e.selection?e.on("start.brush",(function(){c(this,arguments).beforestart().start()})).on("interrupt.brush end.brush",(function(){c(this,arguments).end()})).tween("brush",(function(){var e=this,i=e.__brush,r=c(e,arguments),o=i.selection,a=t.input("function"==typeof n?n.apply(this,arguments):n,i.extent),l=qk(o,a);function u(t){i.selection=1===t&&PS(a)?null:l(t),s.call(e),r.brush()}return o&&a?u:u(1)})):e.each((function(){var e=this,i=arguments,r=e.__brush,o=t.input("function"==typeof n?n.apply(e,i):n,r.extent),a=c(e,i).beforestart();wC(e),r.selection=null==o||PS(o)?null:o,s.call(e),a.start().brush().end()}))},l.prototype={beforestart:function(){return 1==++this.active&&(this.state.emitter=this,this.starting=!0),this},start:function(){return this.starting&&(this.starting=!1,this.emit("start")),this},brush:function(){return this.emit("brush"),this},end:function(){return 0==--this.active&&(delete this.state.emitter,this.emit("end")),this},emit:function(e){Nw(new hS(a,e,t.output(this.state.selection)),r.apply,r,[e,this.that,this.args])}},a.extent=function(t){return arguments.length?(n="function"==typeof t?t:uS([[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]]),a):n},a.filter=function(t){return arguments.length?(i="function"==typeof t?t:uS(!!t),a):i},a.handleSize=function(t){return arguments.length?(o=+t,a):o},a.on=function(){var t=r.on.apply(r,arguments);return t===r?a:t},a}var LS=Math.cos,FS=Math.sin,NS=Math.PI,BS=NS/2,HS=2*NS,zS=Math.max;function VS(t){return function(e,n){return t(e.source.value+e.target.value,n.source.value+n.target.value)}}var US=function(){var t=0,e=null,n=null,i=null;function r(r){var o,a,s,c,l,u,h=r.length,d=[],f=Wy(h),p=[],m=[],g=m.groups=new Array(h),v=new Array(h*h);for(o=0,l=-1;++l<h;){for(a=0,u=-1;++u<h;)a+=r[l][u];d.push(a),p.push(Wy(h)),o+=a}for(e&&f.sort((function(t,n){return e(d[t],d[n])})),n&&p.forEach((function(t,e){t.sort((function(t,i){return n(r[e][t],r[e][i])}))})),c=(o=zS(0,HS-t*h)/o)?t:HS/h,a=0,l=-1;++l<h;){for(s=a,u=-1;++u<h;){var b=f[l],y=p[b][u],_=r[b][y],w=a,k=a+=_*o;v[y*h+b]={index:b,subindex:y,startAngle:w,endAngle:k,value:_}}g[b]={index:b,startAngle:s,endAngle:a,value:d[b]},a+=c}for(l=-1;++l<h;)for(u=l-1;++u<h;){var C=v[u*h+l],S=v[l*h+u];(C.value||S.value)&&m.push(C.value<S.value?{source:S,target:C}:{source:C,target:S})}return i?m.sort(i):m}return r.padAngle=function(e){return arguments.length?(t=zS(0,e),r):t},r.sortGroups=function(t){return arguments.length?(e=t,r):e},r.sortSubgroups=function(t){return arguments.length?(n=t,r):n},r.sortChords=function(t){return arguments.length?(null==t?i=null:(i=VS(t))._=t,r):i&&i._},r},qS=Array.prototype.slice,GS=function(t){return function(){return t}},WS=Math.PI,KS=2*WS,XS=KS-1e-6;function YS(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function ZS(){return new YS}YS.prototype=ZS.prototype={constructor:YS,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,i){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+i)},bezierCurveTo:function(t,e,n,i,r,o){this._+="C"+ +t+","+ +e+","+ +n+","+ +i+","+(this._x1=+r)+","+(this._y1=+o)},arcTo:function(t,e,n,i,r){var o=this._x1,a=this._y1,s=(n=+n)-(t=+t),c=(i=+i)-(e=+e),l=o-t,u=a-e,h=l*l+u*u;if((r=+r)<0)throw new Error("negative radius: "+r);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(h>1e-6)if(Math.abs(u*s-c*l)>1e-6&&r){var d=n-o,f=i-a,p=s*s+c*c,m=d*d+f*f,g=Math.sqrt(p),v=Math.sqrt(h),b=r*Math.tan((WS-Math.acos((p+h-m)/(2*g*v)))/2),y=b/v,_=b/g;Math.abs(y-1)>1e-6&&(this._+="L"+(t+y*l)+","+(e+y*u)),this._+="A"+r+","+r+",0,0,"+ +(u*d>l*f)+","+(this._x1=t+_*s)+","+(this._y1=e+_*c)}else this._+="L"+(this._x1=t)+","+(this._y1=e)},arc:function(t,e,n,i,r,o){t=+t,e=+e,o=!!o;var a=(n=+n)*Math.cos(i),s=n*Math.sin(i),c=t+a,l=e+s,u=1^o,h=o?i-r:r-i;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+c+","+l:(Math.abs(this._x1-c)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+c+","+l),n&&(h<0&&(h=h%KS+KS),h>XS?this._+="A"+n+","+n+",0,1,"+u+","+(t-a)+","+(e-s)+"A"+n+","+n+",0,1,"+u+","+(this._x1=c)+","+(this._y1=l):h>1e-6&&(this._+="A"+n+","+n+",0,"+ +(h>=WS)+","+u+","+(this._x1=t+n*Math.cos(r))+","+(this._y1=e+n*Math.sin(r))))},rect:function(t,e,n,i){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +i+"h"+-n+"Z"},toString:function(){return this._}};var QS=ZS;function $S(t){return t.source}function JS(t){return t.target}function tx(t){return t.radius}function ex(t){return t.startAngle}function nx(t){return t.endAngle}var ix=function(){var t=$S,e=JS,n=tx,i=ex,r=nx,o=null;function a(){var a,s=qS.call(arguments),c=t.apply(this,s),l=e.apply(this,s),u=+n.apply(this,(s[0]=c,s)),h=i.apply(this,s)-BS,d=r.apply(this,s)-BS,f=u*LS(h),p=u*FS(h),m=+n.apply(this,(s[0]=l,s)),g=i.apply(this,s)-BS,v=r.apply(this,s)-BS;if(o||(o=a=QS()),o.moveTo(f,p),o.arc(0,0,u,h,d),h===g&&d===v||(o.quadraticCurveTo(0,0,m*LS(g),m*FS(g)),o.arc(0,0,m,g,v)),o.quadraticCurveTo(0,0,f,p),o.closePath(),a)return o=null,a+""||null}return a.radius=function(t){return arguments.length?(n="function"==typeof t?t:GS(+t),a):n},a.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:GS(+t),a):i},a.endAngle=function(t){return arguments.length?(r="function"==typeof t?t:GS(+t),a):r},a.source=function(e){return arguments.length?(t=e,a):t},a.target=function(t){return arguments.length?(e=t,a):e},a.context=function(t){return arguments.length?(o=null==t?null:t,a):o},a};function rx(){}function ox(t,e){var n=new rx;if(t instanceof rx)t.each((function(t,e){n.set(e,t)}));else if(Array.isArray(t)){var i,r=-1,o=t.length;if(null==e)for(;++r<o;)n.set(r,t[r]);else for(;++r<o;)n.set(e(i=t[r],r,t),i)}else if(t)for(var a in t)n.set(a,t[a]);return n}rx.prototype=ox.prototype={constructor:rx,has:function(t){return"$"+t in this},get:function(t){return this["$"+t]},set:function(t,e){return this["$"+t]=e,this},remove:function(t){var e="$"+t;return e in this&&delete this[e]},clear:function(){for(var t in this)"$"===t[0]&&delete this[t]},keys:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(e.slice(1));return t},values:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(this[e]);return t},entries:function(){var t=[];for(var e in this)"$"===e[0]&&t.push({key:e.slice(1),value:this[e]});return t},size:function(){var t=0;for(var e in this)"$"===e[0]&&++t;return t},empty:function(){for(var t in this)if("$"===t[0])return!1;return!0},each:function(t){for(var e in this)"$"===e[0]&&t(this[e],e.slice(1),this)}};var ax=ox,sx=function(){var t,e,n,i=[],r=[];function o(n,r,a,s){if(r>=i.length)return null!=t&&n.sort(t),null!=e?e(n):n;for(var c,l,u,h=-1,d=n.length,f=i[r++],p=ax(),m=a();++h<d;)(u=p.get(c=f(l=n[h])+""))?u.push(l):p.set(c,[l]);return p.each((function(t,e){s(m,e,o(t,r,a,s))})),m}return n={object:function(t){return o(t,0,cx,lx)},map:function(t){return o(t,0,ux,hx)},entries:function(t){return function t(n,o){if(++o>i.length)return n;var a,s=r[o-1];return null!=e&&o>=i.length?a=n.entries():(a=[],n.each((function(e,n){a.push({key:n,values:t(e,o)})}))),null!=s?a.sort((function(t,e){return s(t.key,e.key)})):a}(o(t,0,ux,hx),0)},key:function(t){return i.push(t),n},sortKeys:function(t){return r[i.length-1]=t,n},sortValues:function(e){return t=e,n},rollup:function(t){return e=t,n}}};function cx(){return{}}function lx(t,e,n){t[e]=n}function ux(){return ax()}function hx(t,e,n){t.set(e,n)}function dx(){}var fx=ax.prototype;function px(t,e){var n=new dx;if(t instanceof dx)t.each((function(t){n.add(t)}));else if(t){var i=-1,r=t.length;if(null==e)for(;++i<r;)n.add(t[i]);else for(;++i<r;)n.add(e(t[i],i,t))}return n}dx.prototype=px.prototype={constructor:dx,has:fx.has,add:function(t){return this["$"+(t+="")]=t,this},remove:fx.remove,clear:fx.clear,values:fx.keys,size:fx.size,empty:fx.empty,each:fx.each};var mx=px,gx=function(t){var e=[];for(var n in t)e.push(n);return e},vx=function(t){var e=[];for(var n in t)e.push(t[n]);return e},bx=function(t){var e=[];for(var n in t)e.push({key:n,value:t[n]});return e},yx=function(t,e,n){t.prototype=e.prototype=n,n.constructor=t};function _x(t,e){var n=Object.create(t.prototype);for(var i in e)n[i]=e[i];return n}function wx(){}var kx="\\s*([+-]?\\d+)\\s*",Cx="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",Sx="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",xx=/^#([0-9a-f]{3})$/,Ox=/^#([0-9a-f]{6})$/,Mx=new RegExp("^rgb\\("+[kx,kx,kx]+"\\)$"),Tx=new RegExp("^rgb\\("+[Sx,Sx,Sx]+"\\)$"),Ex=new RegExp("^rgba\\("+[kx,kx,kx,Cx]+"\\)$"),Px=new RegExp("^rgba\\("+[Sx,Sx,Sx,Cx]+"\\)$"),Ax=new RegExp("^hsl\\("+[Cx,Sx,Sx]+"\\)$"),jx=new RegExp("^hsla\\("+[Cx,Sx,Sx,Cx]+"\\)$"),Ix={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function Dx(t){var e;return t=(t+"").trim().toLowerCase(),(e=xx.exec(t))?new Bx((e=parseInt(e[1],16))>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):(e=Ox.exec(t))?Rx(parseInt(e[1],16)):(e=Mx.exec(t))?new Bx(e[1],e[2],e[3],1):(e=Tx.exec(t))?new Bx(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=Ex.exec(t))?Lx(e[1],e[2],e[3],e[4]):(e=Px.exec(t))?Lx(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=Ax.exec(t))?Hx(e[1],e[2]/100,e[3]/100,1):(e=jx.exec(t))?Hx(e[1],e[2]/100,e[3]/100,e[4]):Ix.hasOwnProperty(t)?Rx(Ix[t]):"transparent"===t?new Bx(NaN,NaN,NaN,0):null}function Rx(t){return new Bx(t>>16&255,t>>8&255,255&t,1)}function Lx(t,e,n,i){return i<=0&&(t=e=n=NaN),new Bx(t,e,n,i)}function Fx(t){return t instanceof wx||(t=Dx(t)),t?new Bx((t=t.rgb()).r,t.g,t.b,t.opacity):new Bx}function Nx(t,e,n,i){return 1===arguments.length?Fx(t):new Bx(t,e,n,null==i?1:i)}function Bx(t,e,n,i){this.r=+t,this.g=+e,this.b=+n,this.opacity=+i}function Hx(t,e,n,i){return i<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new Ux(t,e,n,i)}function zx(t){if(t instanceof Ux)return new Ux(t.h,t.s,t.l,t.opacity);if(t instanceof wx||(t=Dx(t)),!t)return new Ux;if(t instanceof Ux)return t;var e=(t=t.rgb()).r/255,n=t.g/255,i=t.b/255,r=Math.min(e,n,i),o=Math.max(e,n,i),a=NaN,s=o-r,c=(o+r)/2;return s?(a=e===o?(n-i)/s+6*(n<i):n===o?(i-e)/s+2:(e-n)/s+4,s/=c<.5?o+r:2-o-r,a*=60):s=c>0&&c<1?0:a,new Ux(a,s,c,t.opacity)}function Vx(t,e,n,i){return 1===arguments.length?zx(t):new Ux(t,e,n,null==i?1:i)}function Ux(t,e,n,i){this.h=+t,this.s=+e,this.l=+n,this.opacity=+i}function qx(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}yx(wx,Dx,{displayable:function(){return this.rgb().displayable()},toString:function(){return this.rgb()+""}}),yx(Bx,Nx,_x(wx,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new Bx(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new Bx(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return 0<=this.r&&this.r<=255&&0<=this.g&&this.g<=255&&0<=this.b&&this.b<=255&&0<=this.opacity&&this.opacity<=1},toString:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}})),yx(Ux,Vx,_x(wx,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new Ux(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new Ux(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*e,r=2*n-i;return new Bx(qx(t>=240?t-240:t+120,r,i),qx(t,r,i),qx(t<120?t+240:t-120,r,i),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1}}));var Gx=Math.PI/180,Wx=180/Math.PI;function Kx(t){if(t instanceof Yx)return new Yx(t.l,t.a,t.b,t.opacity);if(t instanceof nO){if(isNaN(t.h))return new Yx(t.l,0,0,t.opacity);var e=t.h*Gx;return new Yx(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}t instanceof Bx||(t=Fx(t));var n,i,r=Jx(t.r),o=Jx(t.g),a=Jx(t.b),s=Zx((.2225045*r+.7168786*o+.0606169*a)/1);return r===o&&o===a?n=i=s:(n=Zx((.4360747*r+.3850649*o+.1430804*a)/.96422),i=Zx((.0139322*r+.0971045*o+.7141733*a)/.82521)),new Yx(116*s-16,500*(n-s),200*(s-i),t.opacity)}function Xx(t,e,n,i){return 1===arguments.length?Kx(t):new Yx(t,e,n,null==i?1:i)}function Yx(t,e,n,i){this.l=+t,this.a=+e,this.b=+n,this.opacity=+i}function Zx(t){return t>6/29*(6/29)*(6/29)?Math.pow(t,1/3):t/(6/29*3*(6/29))+4/29}function Qx(t){return t>6/29?t*t*t:6/29*3*(6/29)*(t-4/29)}function $x(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Jx(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function tO(t){if(t instanceof nO)return new nO(t.h,t.c,t.l,t.opacity);if(t instanceof Yx||(t=Kx(t)),0===t.a&&0===t.b)return new nO(NaN,0,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*Wx;return new nO(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function eO(t,e,n,i){return 1===arguments.length?tO(t):new nO(t,e,n,null==i?1:i)}function nO(t,e,n,i){this.h=+t,this.c=+e,this.l=+n,this.opacity=+i}yx(Yx,Xx,_x(wx,{brighter:function(t){return new Yx(this.l+18*(null==t?1:t),this.a,this.b,this.opacity)},darker:function(t){return new Yx(this.l-18*(null==t?1:t),this.a,this.b,this.opacity)},rgb:function(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,n=isNaN(this.b)?t:t-this.b/200;return new Bx($x(3.1338561*(e=.96422*Qx(e))-1.6168667*(t=1*Qx(t))-.4906146*(n=.82521*Qx(n))),$x(-.9787684*e+1.9161415*t+.033454*n),$x(.0719453*e-.2289914*t+1.4052427*n),this.opacity)}})),yx(nO,eO,_x(wx,{brighter:function(t){return new nO(this.h,this.c,this.l+18*(null==t?1:t),this.opacity)},darker:function(t){return new nO(this.h,this.c,this.l-18*(null==t?1:t),this.opacity)},rgb:function(){return Kx(this).rgb()}}));var iO=-.29227,rO=-1.7884503806,oO=3.5172982438,aO=-.6557636667999999;function sO(t){if(t instanceof lO)return new lO(t.h,t.s,t.l,t.opacity);t instanceof Bx||(t=Fx(t));var e=t.g/255,n=t.b/255,i=(aO*n+rO*(t.r/255)-oO*e)/(aO+rO-oO),r=n-i,o=(1.97294*(e-i)-iO*r)/-.90649,a=Math.sqrt(o*o+r*r)/(1.97294*i*(1-i)),s=a?Math.atan2(o,r)*Wx-120:NaN;return new lO(s<0?s+360:s,a,i,t.opacity)}function cO(t,e,n,i){return 1===arguments.length?sO(t):new lO(t,e,n,null==i?1:i)}function lO(t,e,n,i){this.h=+t,this.s=+e,this.l=+n,this.opacity=+i}yx(lO,cO,_x(wx,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new lO(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new lO(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=isNaN(this.h)?0:(this.h+120)*Gx,e=+this.l,n=isNaN(this.s)?0:this.s*e*(1-e),i=Math.cos(t),r=Math.sin(t);return new Bx(255*(e+n*(-.14861*i+1.78277*r)),255*(e+n*(iO*i+-.90649*r)),255*(e+n*(1.97294*i)),this.opacity)}}));var uO=Array.prototype.slice,hO=function(t,e){return t-e},dO=function(t){return function(){return t}},fO=function(t,e){for(var n,i=-1,r=e.length;++i<r;)if(n=pO(t,e[i]))return n;return 0};function pO(t,e){for(var n=e[0],i=e[1],r=-1,o=0,a=t.length,s=a-1;o<a;s=o++){var c=t[o],l=c[0],u=c[1],h=t[s],d=h[0],f=h[1];if(mO(c,h,e))return 0;u>i!=f>i&&n<(d-l)*(i-u)/(f-u)+l&&(r=-r)}return r}function mO(t,e,n){var i,r,o,a;return function(t,e,n){return(e[0]-t[0])*(n[1]-t[1])==(n[0]-t[0])*(e[1]-t[1])}(t,e,n)&&(r=t[i=+(t[0]===e[0])],a=e[i],r<=(o=n[i])&&o<=a||a<=o&&o<=r)}var gO=function(){},vO=[[],[[[1,1.5],[.5,1]]],[[[1.5,1],[1,1.5]]],[[[1.5,1],[.5,1]]],[[[1,.5],[1.5,1]]],[[[1,1.5],[.5,1]],[[1,.5],[1.5,1]]],[[[1,.5],[1,1.5]]],[[[1,.5],[.5,1]]],[[[.5,1],[1,.5]]],[[[1,1.5],[1,.5]]],[[[.5,1],[1,.5]],[[1.5,1],[1,1.5]]],[[[1.5,1],[1,.5]]],[[[.5,1],[1.5,1]]],[[[1,1.5],[1.5,1]]],[[[.5,1],[1,1.5]]],[]],bO=function(){var t=1,e=1,n=Jy,i=s;function r(t){var e=n(t);if(Array.isArray(e))e=e.slice().sort(hO);else{var i=Hy(t),r=i[0],a=i[1];e=$y(r,a,e),e=Wy(Math.floor(r/e)*e,Math.floor(a/e)*e,e)}return e.map((function(e){return o(t,e)}))}function o(n,r){var o=[],s=[];return function(n,i,r){var o,s,c,l,u,h=new Array,d=new Array;for(o=s=-1,vO[(c=n[0]>=i)<<1].forEach(f);++o<t-1;)vO[c|(c=n[o+1]>=i)<<1].forEach(f);for(vO[c<<0].forEach(f);++s<e-1;){for(o=-1,vO[(c=n[s*t+t]>=i)<<1|(l=n[s*t]>=i)<<2].forEach(f);++o<t-1;)u=l,vO[c|(c=n[s*t+t+o+1]>=i)<<1|(l=n[s*t+o+1]>=i)<<2|u<<3].forEach(f);vO[c|l<<3].forEach(f)}for(o=-1,vO[(l=n[s*t]>=i)<<2].forEach(f);++o<t-1;)u=l,vO[(l=n[s*t+o+1]>=i)<<2|u<<3].forEach(f);function f(t){var e,n,i=[t[0][0]+o,t[0][1]+s],c=[t[1][0]+o,t[1][1]+s],l=a(i),u=a(c);(e=d[l])?(n=h[u])?(delete d[e.end],delete h[n.start],e===n?(e.ring.push(c),r(e.ring)):h[e.start]=d[n.end]={start:e.start,end:n.end,ring:e.ring.concat(n.ring)}):(delete d[e.end],e.ring.push(c),d[e.end=u]=e):(e=h[u])?(n=d[l])?(delete h[e.start],delete d[n.end],e===n?(e.ring.push(c),r(e.ring)):h[n.start]=d[e.end]={start:n.start,end:e.end,ring:n.ring.concat(e.ring)}):(delete h[e.start],e.ring.unshift(i),h[e.start=l]=e):h[l]=d[u]={start:l,end:u,ring:[i,c]}}vO[l<<3].forEach(f)}(n,r,(function(t){i(t,n,r),function(t){for(var e=0,n=t.length,i=t[n-1][1]*t[0][0]-t[n-1][0]*t[0][1];++e<n;)i+=t[e-1][1]*t[e][0]-t[e-1][0]*t[e][1];return i}(t)>0?o.push([t]):s.push(t)})),s.forEach((function(t){for(var e,n=0,i=o.length;n<i;++n)if(-1!==fO((e=o[n])[0],t))return void e.push(t)})),{type:"MultiPolygon",value:r,coordinates:o}}function a(e){return 2*e[0]+e[1]*(t+1)*4}function s(n,i,r){n.forEach((function(n){var o,a=n[0],s=n[1],c=0|a,l=0|s,u=i[l*t+c];a>0&&a<t&&c===a&&(n[0]=a+(r-(o=i[l*t+c-1]))/(u-o)-.5),s>0&&s<e&&l===s&&(n[1]=s+(r-(o=i[(l-1)*t+c]))/(u-o)-.5)}))}return r.contour=o,r.size=function(n){if(!arguments.length)return[t,e];var i=Math.ceil(n[0]),o=Math.ceil(n[1]);if(!(i>0&&o>0))throw new Error("invalid size");return t=i,e=o,r},r.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:Array.isArray(t)?dO(uO.call(t)):dO(t),r):n},r.smooth=function(t){return arguments.length?(i=t?s:gO,r):i===s},r};function yO(t,e,n){for(var i=t.width,r=t.height,o=1+(n<<1),a=0;a<r;++a)for(var s=0,c=0;s<i+n;++s)s<i&&(c+=t.data[s+a*i]),s>=n&&(s>=o&&(c-=t.data[s-o+a*i]),e.data[s-n+a*i]=c/Math.min(s+1,i-1+o-s,o))}function _O(t,e,n){for(var i=t.width,r=t.height,o=1+(n<<1),a=0;a<i;++a)for(var s=0,c=0;s<r+n;++s)s<r&&(c+=t.data[a+s*i]),s>=n&&(s>=o&&(c-=t.data[a+(s-o)*i]),e.data[a+(s-n)*i]=c/Math.min(s+1,r-1+o-s,o))}function wO(t){return t[0]}function kO(t){return t[1]}var CO=function(){var t=wO,e=kO,n=960,i=500,r=20,o=2,a=3*r,s=n+2*a>>o,c=i+2*a>>o,l=dO(20);function u(n){var i=new Float32Array(s*c),u=new Float32Array(s*c);n.forEach((function(n,r,l){var u=t(n,r,l)+a>>o,h=e(n,r,l)+a>>o;u>=0&&u<s&&h>=0&&h<c&&++i[u+h*s]})),yO({width:s,height:c,data:i},{width:s,height:c,data:u},r>>o),_O({width:s,height:c,data:u},{width:s,height:c,data:i},r>>o),yO({width:s,height:c,data:i},{width:s,height:c,data:u},r>>o),_O({width:s,height:c,data:u},{width:s,height:c,data:i},r>>o),yO({width:s,height:c,data:i},{width:s,height:c,data:u},r>>o),_O({width:s,height:c,data:u},{width:s,height:c,data:i},r>>o);var d=l(i);if(!Array.isArray(d)){var f=r_(i);d=$y(0,f,d),(d=Wy(0,Math.floor(f/d)*d,d)).shift()}return bO().thresholds(d).size([s,c])(i).map(h)}function h(t){return t.value*=Math.pow(2,-2*o),t.coordinates.forEach(d),t}function d(t){t.forEach(f)}function f(t){t.forEach(p)}function p(t){t[0]=t[0]*Math.pow(2,o)-a,t[1]=t[1]*Math.pow(2,o)-a}function m(){return s=n+2*(a=3*r)>>o,c=i+2*a>>o,u}return u.x=function(e){return arguments.length?(t="function"==typeof e?e:dO(+e),u):t},u.y=function(t){return arguments.length?(e="function"==typeof t?t:dO(+t),u):e},u.size=function(t){if(!arguments.length)return[n,i];var e=Math.ceil(t[0]),r=Math.ceil(t[1]);if(!(e>=0||e>=0))throw new Error("invalid size");return n=e,i=r,m()},u.cellSize=function(t){if(!arguments.length)return 1<<o;if(!((t=+t)>=1))throw new Error("invalid cell size");return o=Math.floor(Math.log(t)/Math.LN2),m()},u.thresholds=function(t){return arguments.length?(l="function"==typeof t?t:Array.isArray(t)?dO(uO.call(t)):dO(t),u):l},u.bandwidth=function(t){if(!arguments.length)return Math.sqrt(r*(r+1));if(!((t=+t)>=0))throw new Error("invalid bandwidth");return r=Math.round((Math.sqrt(4*t*t+1)-1)/2),m()},u},SO=function(t,e,n){arguments.length<3&&(n=e,e=Gk().changedTouches);for(var i,r=0,o=e?e.length:0;r<o;++r)if((i=e[r]).identifier===n)return Wk(t,i);return null},xO=function(t){return function(){return t}};function OO(t,e,n,i,r,o,a,s,c,l){this.target=t,this.type=e,this.subject=n,this.identifier=i,this.active=r,this.x=o,this.y=a,this.dx=s,this.dy=c,this._=l}function MO(){return!jw.ctrlKey&&!jw.button}function TO(){return this.parentNode}function EO(t){return null==t?{x:jw.x,y:jw.y}:t}function PO(){return navigator.maxTouchPoints||"ontouchstart"in this}OO.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};var AO=function(){var t,e,n,i,r=MO,o=TO,a=EO,s=PO,c={},l=D_("start","drag","end"),u=0,h=0;function d(t){t.on("mousedown.drag",f).filter(s).on("touchstart.drag",g).on("touchmove.drag",v).on("touchend.drag touchcancel.drag",b).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function f(){if(!i&&r.apply(this,arguments)){var a=y("mouse",o.apply(this,arguments),Kk,this,arguments);a&&(Ww(jw.view).on("mousemove.drag",p,!0).on("mouseup.drag",m,!0),Yw(jw.view),Kw(),n=!1,t=jw.clientX,e=jw.clientY,a("start"))}}function p(){if(Xw(),!n){var i=jw.clientX-t,r=jw.clientY-e;n=i*i+r*r>h}c.mouse("drag")}function m(){Ww(jw.view).on("mousemove.drag mouseup.drag",null),Zw(jw.view,n),Xw(),c.mouse("end")}function g(){if(r.apply(this,arguments)){var t,e,n=jw.changedTouches,i=o.apply(this,arguments),a=n.length;for(t=0;t<a;++t)(e=y(n[t].identifier,i,SO,this,arguments))&&(Kw(),e("start"))}}function v(){var t,e,n=jw.changedTouches,i=n.length;for(t=0;t<i;++t)(e=c[n[t].identifier])&&(Xw(),e("drag"))}function b(){var t,e,n=jw.changedTouches,r=n.length;for(i&&clearTimeout(i),i=setTimeout((function(){i=null}),500),t=0;t<r;++t)(e=c[n[t].identifier])&&(Kw(),e("end"))}function y(t,e,n,i,r){var o,s,h,f=n(e,t),p=l.copy();if(Nw(new OO(d,"beforestart",o,t,u,f[0],f[1],0,0,p),(function(){return null!=(jw.subject=o=a.apply(i,r))&&(s=o.x-f[0]||0,h=o.y-f[1]||0,!0)})))return function a(l){var m,g=f;switch(l){case"start":c[t]=a,m=u++;break;case"end":delete c[t],--u;case"drag":f=n(e,t),m=u}Nw(new OO(d,l,o,t,m,f[0]+s,f[1]+h,f[0]-g[0],f[1]-g[1],p),p.apply,p,[l,i,r])}}return d.filter=function(t){return arguments.length?(r="function"==typeof t?t:xO(!!t),d):r},d.container=function(t){return arguments.length?(o="function"==typeof t?t:xO(t),d):o},d.subject=function(t){return arguments.length?(a="function"==typeof t?t:xO(t),d):a},d.touchable=function(t){return arguments.length?(s="function"==typeof t?t:xO(!!t),d):s},d.on=function(){var t=l.on.apply(l,arguments);return t===l?d:t},d.clickDistance=function(t){return arguments.length?(h=(t=+t)*t,d):Math.sqrt(h)},d},jO={},IO={};function DO(t){return new Function("d","return {"+t.map((function(t,e){return JSON.stringify(t)+": d["+e+"]"})).join(",")+"}")}var RO=function(t){var e=new RegExp('["'+t+"\n\r]"),n=t.charCodeAt(0);function i(t,e){var i,r=[],o=t.length,a=0,s=0,c=o<=0,l=!1;function u(){if(c)return IO;if(l)return l=!1,jO;var e,i,r=a;if(34===t.charCodeAt(r)){for(;a++<o&&34!==t.charCodeAt(a)||34===t.charCodeAt(++a););return(e=a)>=o?c=!0:10===(i=t.charCodeAt(a++))?l=!0:13===i&&(l=!0,10===t.charCodeAt(a)&&++a),t.slice(r+1,e-1).replace(/""/g,'"')}for(;a<o;){if(10===(i=t.charCodeAt(e=a++)))l=!0;else if(13===i)l=!0,10===t.charCodeAt(a)&&++a;else if(i!==n)continue;return t.slice(r,e)}return c=!0,t.slice(r,o)}for(10===t.charCodeAt(o-1)&&--o,13===t.charCodeAt(o-1)&&--o;(i=u())!==IO;){for(var h=[];i!==jO&&i!==IO;)h.push(i),i=u();e&&null==(h=e(h,s++))||r.push(h)}return r}function r(e){return e.map(o).join(t)}function o(t){return null==t?"":e.test(t+="")?'"'+t.replace(/"/g,'""')+'"':t}return{parse:function(t,e){var n,r,o=i(t,(function(t,i){if(n)return n(t,i-1);r=t,n=e?function(t,e){var n=DO(t);return function(i,r){return e(n(i),r,t)}}(t,e):DO(t)}));return o.columns=r||[],o},parseRows:i,format:function(e,n){return null==n&&(n=function(t){var e=Object.create(null),n=[];return t.forEach((function(t){for(var i in t)i in e||n.push(e[i]=i)})),n}(e)),[n.map(o).join(t)].concat(e.map((function(e){return n.map((function(t){return o(e[t])})).join(t)}))).join("\n")},formatRows:function(t){return t.map(r).join("\n")}}},LO=RO(","),FO=LO.parse,NO=LO.parseRows,BO=LO.format,HO=LO.formatRows,zO=RO("\t"),VO=zO.parse,UO=zO.parseRows,qO=zO.format,GO=zO.formatRows;function WO(t){return+t}function KO(t){return t*t}function XO(t){return t*(2-t)}function YO(t){return((t*=2)<=1?t*t:--t*(2-t)+1)/2}var ZO=function t(e){function n(t){return Math.pow(t,e)}return e=+e,n.exponent=t,n}(3),QO=function t(e){function n(t){return 1-Math.pow(1-t,e)}return e=+e,n.exponent=t,n}(3),$O=function t(e){function n(t){return((t*=2)<=1?Math.pow(t,e):2-Math.pow(2-t,e))/2}return e=+e,n.exponent=t,n}(3),JO=Math.PI,tM=JO/2;function eM(t){return 1-Math.cos(t*tM)}function nM(t){return Math.sin(t*tM)}function iM(t){return(1-Math.cos(JO*t))/2}function rM(t){return Math.pow(2,10*t-10)}function oM(t){return 1-Math.pow(2,-10*t)}function aM(t){return((t*=2)<=1?Math.pow(2,10*t-10):2-Math.pow(2,10-10*t))/2}function sM(t){return 1-Math.sqrt(1-t*t)}function cM(t){return Math.sqrt(1- --t*t)}function lM(t){return((t*=2)<=1?1-Math.sqrt(1-t*t):Math.sqrt(1-(t-=2)*t)+1)/2}function uM(t){return 1-hM(1-t)}function hM(t){return(t=+t)<4/11?7.5625*t*t:t<8/11?7.5625*(t-=6/11)*t+3/4:t<10/11?7.5625*(t-=9/11)*t+15/16:7.5625*(t-=21/22)*t+63/64}function dM(t){return((t*=2)<=1?1-hM(1-t):hM(t-1)+1)/2}var fM=function t(e){function n(t){return t*t*((e+1)*t-e)}return e=+e,n.overshoot=t,n}(1.70158),pM=function t(e){function n(t){return--t*t*((e+1)*t+e)+1}return e=+e,n.overshoot=t,n}(1.70158),mM=function t(e){function n(t){return((t*=2)<1?t*t*((e+1)*t-e):(t-=2)*t*((e+1)*t+e)+2)/2}return e=+e,n.overshoot=t,n}(1.70158),gM=2*Math.PI,vM=function t(e,n){var i=Math.asin(1/(e=Math.max(1,e)))*(n/=gM);function r(t){return e*Math.pow(2,10*--t)*Math.sin((i-t)/n)}return r.amplitude=function(e){return t(e,n*gM)},r.period=function(n){return t(e,n)},r}(1,.3),bM=function t(e,n){var i=Math.asin(1/(e=Math.max(1,e)))*(n/=gM);function r(t){return 1-e*Math.pow(2,-10*(t=+t))*Math.sin((t+i)/n)}return r.amplitude=function(e){return t(e,n*gM)},r.period=function(n){return t(e,n)},r}(1,.3),yM=function t(e,n){var i=Math.asin(1/(e=Math.max(1,e)))*(n/=gM);function r(t){return((t=2*t-1)<0?e*Math.pow(2,10*t)*Math.sin((i-t)/n):2-e*Math.pow(2,-10*t)*Math.sin((i+t)/n))/2}return r.amplitude=function(e){return t(e,n*gM)},r.period=function(n){return t(e,n)},r}(1,.3),_M=function(t,e){var n;function i(){var i,r,o=n.length,a=0,s=0;for(i=0;i<o;++i)a+=(r=n[i]).x,s+=r.y;for(a=a/o-t,s=s/o-e,i=0;i<o;++i)(r=n[i]).x-=a,r.y-=s}return null==t&&(t=0),null==e&&(e=0),i.initialize=function(t){n=t},i.x=function(e){return arguments.length?(t=+e,i):t},i.y=function(t){return arguments.length?(e=+t,i):e},i},wM=function(t){return function(){return t}},kM=function(){return 1e-6*(Math.random()-.5)};function CM(t,e,n,i){if(isNaN(e)||isNaN(n))return t;var r,o,a,s,c,l,u,h,d,f=t._root,p={data:i},m=t._x0,g=t._y0,v=t._x1,b=t._y1;if(!f)return t._root=p,t;for(;f.length;)if((l=e>=(o=(m+v)/2))?m=o:v=o,(u=n>=(a=(g+b)/2))?g=a:b=a,r=f,!(f=f[h=u<<1|l]))return r[h]=p,t;if(s=+t._x.call(null,f.data),c=+t._y.call(null,f.data),e===s&&n===c)return p.next=f,r?r[h]=p:t._root=p,t;do{r=r?r[h]=new Array(4):t._root=new Array(4),(l=e>=(o=(m+v)/2))?m=o:v=o,(u=n>=(a=(g+b)/2))?g=a:b=a}while((h=u<<1|l)==(d=(c>=a)<<1|s>=o));return r[d]=f,r[h]=p,t}var SM=function(t,e,n,i,r){this.node=t,this.x0=e,this.y0=n,this.x1=i,this.y1=r};function xM(t){return t[0]}function OM(t){return t[1]}function MM(t,e,n){var i=new TM(null==e?xM:e,null==n?OM:n,NaN,NaN,NaN,NaN);return null==t?i:i.addAll(t)}function TM(t,e,n,i,r,o){this._x=t,this._y=e,this._x0=n,this._y0=i,this._x1=r,this._y1=o,this._root=void 0}function EM(t){for(var e={data:t.data},n=e;t=t.next;)n=n.next={data:t.data};return e}var PM=MM.prototype=TM.prototype;function AM(t){return t.x+t.vx}function jM(t){return t.y+t.vy}PM.copy=function(){var t,e,n=new TM(this._x,this._y,this._x0,this._y0,this._x1,this._y1),i=this._root;if(!i)return n;if(!i.length)return n._root=EM(i),n;for(t=[{source:i,target:n._root=new Array(4)}];i=t.pop();)for(var r=0;r<4;++r)(e=i.source[r])&&(e.length?t.push({source:e,target:i.target[r]=new Array(4)}):i.target[r]=EM(e));return n},PM.add=function(t){var e=+this._x.call(null,t),n=+this._y.call(null,t);return CM(this.cover(e,n),e,n,t)},PM.addAll=function(t){var e,n,i,r,o=t.length,a=new Array(o),s=new Array(o),c=1/0,l=1/0,u=-1/0,h=-1/0;for(n=0;n<o;++n)isNaN(i=+this._x.call(null,e=t[n]))||isNaN(r=+this._y.call(null,e))||(a[n]=i,s[n]=r,i<c&&(c=i),i>u&&(u=i),r<l&&(l=r),r>h&&(h=r));if(c>u||l>h)return this;for(this.cover(c,l).cover(u,h),n=0;n<o;++n)CM(this,a[n],s[n],t[n]);return this},PM.cover=function(t,e){if(isNaN(t=+t)||isNaN(e=+e))return this;var n=this._x0,i=this._y0,r=this._x1,o=this._y1;if(isNaN(n))r=(n=Math.floor(t))+1,o=(i=Math.floor(e))+1;else{for(var a,s,c=r-n,l=this._root;n>t||t>=r||i>e||e>=o;)switch(s=(e<i)<<1|t<n,(a=new Array(4))[s]=l,l=a,c*=2,s){case 0:r=n+c,o=i+c;break;case 1:n=r-c,o=i+c;break;case 2:r=n+c,i=o-c;break;case 3:n=r-c,i=o-c}this._root&&this._root.length&&(this._root=l)}return this._x0=n,this._y0=i,this._x1=r,this._y1=o,this},PM.data=function(){var t=[];return this.visit((function(e){if(!e.length)do{t.push(e.data)}while(e=e.next)})),t},PM.extent=function(t){return arguments.length?this.cover(+t[0][0],+t[0][1]).cover(+t[1][0],+t[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]},PM.find=function(t,e,n){var i,r,o,a,s,c,l,u=this._x0,h=this._y0,d=this._x1,f=this._y1,p=[],m=this._root;for(m&&p.push(new SM(m,u,h,d,f)),null==n?n=1/0:(u=t-n,h=e-n,d=t+n,f=e+n,n*=n);c=p.pop();)if(!(!(m=c.node)||(r=c.x0)>d||(o=c.y0)>f||(a=c.x1)<u||(s=c.y1)<h))if(m.length){var g=(r+a)/2,v=(o+s)/2;p.push(new SM(m[3],g,v,a,s),new SM(m[2],r,v,g,s),new SM(m[1],g,o,a,v),new SM(m[0],r,o,g,v)),(l=(e>=v)<<1|t>=g)&&(c=p[p.length-1],p[p.length-1]=p[p.length-1-l],p[p.length-1-l]=c)}else{var b=t-+this._x.call(null,m.data),y=e-+this._y.call(null,m.data),_=b*b+y*y;if(_<n){var w=Math.sqrt(n=_);u=t-w,h=e-w,d=t+w,f=e+w,i=m.data}}return i},PM.remove=function(t){if(isNaN(o=+this._x.call(null,t))||isNaN(a=+this._y.call(null,t)))return this;var e,n,i,r,o,a,s,c,l,u,h,d,f=this._root,p=this._x0,m=this._y0,g=this._x1,v=this._y1;if(!f)return this;if(f.length)for(;;){if((l=o>=(s=(p+g)/2))?p=s:g=s,(u=a>=(c=(m+v)/2))?m=c:v=c,e=f,!(f=f[h=u<<1|l]))return this;if(!f.length)break;(e[h+1&3]||e[h+2&3]||e[h+3&3])&&(n=e,d=h)}for(;f.data!==t;)if(i=f,!(f=f.next))return this;return(r=f.next)&&delete f.next,i?(r?i.next=r:delete i.next,this):e?(r?e[h]=r:delete e[h],(f=e[0]||e[1]||e[2]||e[3])&&f===(e[3]||e[2]||e[1]||e[0])&&!f.length&&(n?n[d]=f:this._root=f),this):(this._root=r,this)},PM.removeAll=function(t){for(var e=0,n=t.length;e<n;++e)this.remove(t[e]);return this},PM.root=function(){return this._root},PM.size=function(){var t=0;return this.visit((function(e){if(!e.length)do{++t}while(e=e.next)})),t},PM.visit=function(t){var e,n,i,r,o,a,s=[],c=this._root;for(c&&s.push(new SM(c,this._x0,this._y0,this._x1,this._y1));e=s.pop();)if(!t(c=e.node,i=e.x0,r=e.y0,o=e.x1,a=e.y1)&&c.length){var l=(i+o)/2,u=(r+a)/2;(n=c[3])&&s.push(new SM(n,l,u,o,a)),(n=c[2])&&s.push(new SM(n,i,u,l,a)),(n=c[1])&&s.push(new SM(n,l,r,o,u)),(n=c[0])&&s.push(new SM(n,i,r,l,u))}return this},PM.visitAfter=function(t){var e,n=[],i=[];for(this._root&&n.push(new SM(this._root,this._x0,this._y0,this._x1,this._y1));e=n.pop();){var r=e.node;if(r.length){var o,a=e.x0,s=e.y0,c=e.x1,l=e.y1,u=(a+c)/2,h=(s+l)/2;(o=r[0])&&n.push(new SM(o,a,s,u,h)),(o=r[1])&&n.push(new SM(o,u,s,c,h)),(o=r[2])&&n.push(new SM(o,a,h,u,l)),(o=r[3])&&n.push(new SM(o,u,h,c,l))}i.push(e)}for(;e=i.pop();)t(e.node,e.x0,e.y0,e.x1,e.y1);return this},PM.x=function(t){return arguments.length?(this._x=t,this):this._x},PM.y=function(t){return arguments.length?(this._y=t,this):this._y};var IM=function(t){var e,n,i=1,r=1;function o(){for(var t,o,s,c,l,u,h,d=e.length,f=0;f<r;++f)for(o=MM(e,AM,jM).visitAfter(a),t=0;t<d;++t)h=(u=n[(s=e[t]).index])*u,c=s.x+s.vx,l=s.y+s.vy,o.visit(p);function p(t,e,n,r,o){var a=t.data,d=t.r,f=u+d;if(!a)return e>c+f||r<c-f||n>l+f||o<l-f;if(a.index>s.index){var p=c-a.x-a.vx,m=l-a.y-a.vy,g=p*p+m*m;g<f*f&&(0===p&&(g+=(p=kM())*p),0===m&&(g+=(m=kM())*m),g=(f-(g=Math.sqrt(g)))/g*i,s.vx+=(p*=g)*(f=(d*=d)/(h+d)),s.vy+=(m*=g)*f,a.vx-=p*(f=1-f),a.vy-=m*f)}}}function a(t){if(t.data)return t.r=n[t.data.index];for(var e=t.r=0;e<4;++e)t[e]&&t[e].r>t.r&&(t.r=t[e].r)}function s(){if(e){var i,r,o=e.length;for(n=new Array(o),i=0;i<o;++i)n[(r=e[i]).index]=+t(r,i,e)}}return"function"!=typeof t&&(t=wM(null==t?1:+t)),o.initialize=function(t){e=t,s()},o.iterations=function(t){return arguments.length?(r=+t,o):r},o.strength=function(t){return arguments.length?(i=+t,o):i},o.radius=function(e){return arguments.length?(t="function"==typeof e?e:wM(+e),s(),o):t},o};function DM(t){return t.index}function RM(t,e){var n=t.get(e);if(!n)throw new Error("missing: "+e);return n}var LM=function(t){var e,n,i,r,o,a=DM,s=function(t){return 1/Math.min(r[t.source.index],r[t.target.index])},c=wM(30),l=1;function u(i){for(var r=0,a=t.length;r<l;++r)for(var s,c,u,h,d,f,p,m=0;m<a;++m)h=(u=(s=t[m]).target).x+u.vx-(c=s.source).x-c.vx||kM(),d=u.y+u.vy-c.y-c.vy||kM(),d*=f=((f=Math.sqrt(h*h+d*d))-n[m])/f*i*e[m],u.vx-=(h*=f)*(p=o[m]),u.vy-=d*p,c.vx+=h*(p=1-p),c.vy+=d*p}function h(){if(i){var s,c,l=i.length,u=t.length,h=ax(i,a);for(s=0,r=new Array(l);s<u;++s)(c=t[s]).index=s,"object"!=typeof c.source&&(c.source=RM(h,c.source)),"object"!=typeof c.target&&(c.target=RM(h,c.target)),r[c.source.index]=(r[c.source.index]||0)+1,r[c.target.index]=(r[c.target.index]||0)+1;for(s=0,o=new Array(u);s<u;++s)o[s]=r[(c=t[s]).source.index]/(r[c.source.index]+r[c.target.index]);e=new Array(u),d(),n=new Array(u),f()}}function d(){if(i)for(var n=0,r=t.length;n<r;++n)e[n]=+s(t[n],n,t)}function f(){if(i)for(var e=0,r=t.length;e<r;++e)n[e]=+c(t[e],e,t)}return null==t&&(t=[]),u.initialize=function(t){i=t,h()},u.links=function(e){return arguments.length?(t=e,h(),u):t},u.id=function(t){return arguments.length?(a=t,u):a},u.iterations=function(t){return arguments.length?(l=+t,u):l},u.strength=function(t){return arguments.length?(s="function"==typeof t?t:wM(+t),d(),u):s},u.distance=function(t){return arguments.length?(c="function"==typeof t?t:wM(+t),f(),u):c},u};function FM(t){return t.x}function NM(t){return t.y}var BM,HM=Math.PI*(3-Math.sqrt(5)),zM=function(t){var e,n=1,i=.001,r=1-Math.pow(i,1/300),o=0,a=.6,s=ax(),c=oC(u),l=D_("tick","end");function u(){h(),l.call("tick",e),n<i&&(c.stop(),l.call("end",e))}function h(){var e,i,c=t.length;for(n+=(o-n)*r,s.each((function(t){t(n)})),e=0;e<c;++e)null==(i=t[e]).fx?i.x+=i.vx*=a:(i.x=i.fx,i.vx=0),null==i.fy?i.y+=i.vy*=a:(i.y=i.fy,i.vy=0)}function d(){for(var e,n=0,i=t.length;n<i;++n){if((e=t[n]).index=n,isNaN(e.x)||isNaN(e.y)){var r=10*Math.sqrt(n),o=n*HM;e.x=r*Math.cos(o),e.y=r*Math.sin(o)}(isNaN(e.vx)||isNaN(e.vy))&&(e.vx=e.vy=0)}}function f(e){return e.initialize&&e.initialize(t),e}return null==t&&(t=[]),d(),e={tick:h,restart:function(){return c.restart(u),e},stop:function(){return c.stop(),e},nodes:function(n){return arguments.length?(t=n,d(),s.each(f),e):t},alpha:function(t){return arguments.length?(n=+t,e):n},alphaMin:function(t){return arguments.length?(i=+t,e):i},alphaDecay:function(t){return arguments.length?(r=+t,e):+r},alphaTarget:function(t){return arguments.length?(o=+t,e):o},velocityDecay:function(t){return arguments.length?(a=1-t,e):1-a},force:function(t,n){return arguments.length>1?(null==n?s.remove(t):s.set(t,f(n)),e):s.get(t)},find:function(e,n,i){var r,o,a,s,c,l=0,u=t.length;for(null==i?i=1/0:i*=i,l=0;l<u;++l)(a=(r=e-(s=t[l]).x)*r+(o=n-s.y)*o)<i&&(c=s,i=a);return c},on:function(t,n){return arguments.length>1?(l.on(t,n),e):l.on(t)}}},VM=function(){var t,e,n,i,r=wM(-30),o=1,a=1/0,s=.81;function c(i){var r,o=t.length,a=MM(t,FM,NM).visitAfter(u);for(n=i,r=0;r<o;++r)e=t[r],a.visit(h)}function l(){if(t){var e,n,o=t.length;for(i=new Array(o),e=0;e<o;++e)i[(n=t[e]).index]=+r(n,e,t)}}function u(t){var e,n,r,o,a,s=0,c=0;if(t.length){for(r=o=a=0;a<4;++a)(e=t[a])&&(n=Math.abs(e.value))&&(s+=e.value,c+=n,r+=n*e.x,o+=n*e.y);t.x=r/c,t.y=o/c}else{(e=t).x=e.data.x,e.y=e.data.y;do{s+=i[e.data.index]}while(e=e.next)}t.value=s}function h(t,r,c,l){if(!t.value)return!0;var u=t.x-e.x,h=t.y-e.y,d=l-r,f=u*u+h*h;if(d*d/s<f)return f<a&&(0===u&&(f+=(u=kM())*u),0===h&&(f+=(h=kM())*h),f<o&&(f=Math.sqrt(o*f)),e.vx+=u*t.value*n/f,e.vy+=h*t.value*n/f),!0;if(!(t.length||f>=a)){(t.data!==e||t.next)&&(0===u&&(f+=(u=kM())*u),0===h&&(f+=(h=kM())*h),f<o&&(f=Math.sqrt(o*f)));do{t.data!==e&&(e.vx+=u*(d=i[t.data.index]*n/f),e.vy+=h*d)}while(t=t.next)}}return c.initialize=function(e){t=e,l()},c.strength=function(t){return arguments.length?(r="function"==typeof t?t:wM(+t),l(),c):r},c.distanceMin=function(t){return arguments.length?(o=t*t,c):Math.sqrt(o)},c.distanceMax=function(t){return arguments.length?(a=t*t,c):Math.sqrt(a)},c.theta=function(t){return arguments.length?(s=t*t,c):Math.sqrt(s)},c},UM=function(t,e,n){var i,r,o,a=wM(.1);function s(t){for(var a=0,s=i.length;a<s;++a){var c=i[a],l=c.x-e||1e-6,u=c.y-n||1e-6,h=Math.sqrt(l*l+u*u),d=(o[a]-h)*r[a]*t/h;c.vx+=l*d,c.vy+=u*d}}function c(){if(i){var e,n=i.length;for(r=new Array(n),o=new Array(n),e=0;e<n;++e)o[e]=+t(i[e],e,i),r[e]=isNaN(o[e])?0:+a(i[e],e,i)}}return"function"!=typeof t&&(t=wM(+t)),null==e&&(e=0),null==n&&(n=0),s.initialize=function(t){i=t,c()},s.strength=function(t){return arguments.length?(a="function"==typeof t?t:wM(+t),c(),s):a},s.radius=function(e){return arguments.length?(t="function"==typeof e?e:wM(+e),c(),s):t},s.x=function(t){return arguments.length?(e=+t,s):e},s.y=function(t){return arguments.length?(n=+t,s):n},s},qM=function(t){var e,n,i,r=wM(.1);function o(t){for(var r,o=0,a=e.length;o<a;++o)(r=e[o]).vx+=(i[o]-r.x)*n[o]*t}function a(){if(e){var o,a=e.length;for(n=new Array(a),i=new Array(a),o=0;o<a;++o)n[o]=isNaN(i[o]=+t(e[o],o,e))?0:+r(e[o],o,e)}}return"function"!=typeof t&&(t=wM(null==t?0:+t)),o.initialize=function(t){e=t,a()},o.strength=function(t){return arguments.length?(r="function"==typeof t?t:wM(+t),a(),o):r},o.x=function(e){return arguments.length?(t="function"==typeof e?e:wM(+e),a(),o):t},o},GM=function(t){var e,n,i,r=wM(.1);function o(t){for(var r,o=0,a=e.length;o<a;++o)(r=e[o]).vy+=(i[o]-r.y)*n[o]*t}function a(){if(e){var o,a=e.length;for(n=new Array(a),i=new Array(a),o=0;o<a;++o)n[o]=isNaN(i[o]=+t(e[o],o,e))?0:+r(e[o],o,e)}}return"function"!=typeof t&&(t=wM(null==t?0:+t)),o.initialize=function(t){e=t,a()},o.strength=function(t){return arguments.length?(r="function"==typeof t?t:wM(+t),a(),o):r},o.y=function(e){return arguments.length?(t="function"==typeof e?e:wM(+e),a(),o):t},o},WM=function(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,i=t.slice(0,n);return[i.length>1?i[0]+i.slice(2):i,+t.slice(n+1)]},KM=function(t){return(t=WM(Math.abs(t)))?t[1]:NaN},XM=function(t,e){var n=WM(t,e);if(!n)return t+"";var i=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+i:i.length>r+1?i.slice(0,r+1)+"."+i.slice(r+1):i+new Array(r-i.length+2).join("0")},YM={"":function(t,e){t:for(var n,i=(t=t.toPrecision(e)).length,r=1,o=-1;r<i;++r)switch(t[r]){case".":o=n=r;break;case"0":0===o&&(o=r),n=r;break;case"e":break t;default:o>0&&(o=0)}return o>0?t.slice(0,o)+t.slice(n+1):t},"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return XM(100*t,e)},r:XM,s:function(t,e){var n=WM(t,e);if(!n)return t+"";var i=n[0],r=n[1],o=r-(BM=3*Math.max(-8,Math.min(8,Math.floor(r/3))))+1,a=i.length;return o===a?i:o>a?i+new Array(o-a+1).join("0"):o>0?i.slice(0,o)+"."+i.slice(o):"0."+new Array(1-o).join("0")+WM(t,Math.max(0,e+o-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}},ZM=/^(?:(.)?([<>=^]))?([+\-\( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?([a-z%])?$/i;function QM(t){return new $M(t)}function $M(t){if(!(e=ZM.exec(t)))throw new Error("invalid format: "+t);var e,n=e[1]||" ",i=e[2]||">",r=e[3]||"-",o=e[4]||"",a=!!e[5],s=e[6]&&+e[6],c=!!e[7],l=e[8]&&+e[8].slice(1),u=e[9]||"";"n"===u?(c=!0,u="g"):YM[u]||(u=""),(a||"0"===n&&"="===i)&&(a=!0,n="0",i="="),this.fill=n,this.align=i,this.sign=r,this.symbol=o,this.zero=a,this.width=s,this.comma=c,this.precision=l,this.type=u}QM.prototype=$M.prototype,$M.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(null==this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(null==this.precision?"":"."+Math.max(0,0|this.precision))+this.type};var JM,tT,eT,nT=function(t){return t},iT=["y","z","a","f","p","n","\xb5","m","","k","M","G","T","P","E","Z","Y"],rT=function(t){var e,n,i=t.grouping&&t.thousands?(e=t.grouping,n=t.thousands,function(t,i){for(var r=t.length,o=[],a=0,s=e[0],c=0;r>0&&s>0&&(c+s+1>i&&(s=Math.max(1,i-c)),o.push(t.substring(r-=s,r+s)),!((c+=s+1)>i));)s=e[a=(a+1)%e.length];return o.reverse().join(n)}):nT,r=t.currency,o=t.decimal,a=t.numerals?function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(t.numerals):nT,s=t.percent||"%";function c(t){var e=(t=QM(t)).fill,n=t.align,c=t.sign,l=t.symbol,u=t.zero,h=t.width,d=t.comma,f=t.precision,p=t.type,m="$"===l?r[0]:"#"===l&&/[boxX]/.test(p)?"0"+p.toLowerCase():"",g="$"===l?r[1]:/[%p]/.test(p)?s:"",v=YM[p],b=!p||/[defgprs%]/.test(p);function y(t){var r,s,l,y=m,_=g;if("c"===p)_=v(t)+_,t="";else{var w=(t=+t)<0;if(t=v(Math.abs(t),f),w&&0==+t&&(w=!1),y=(w?"("===c?c:"-":"-"===c||"("===c?"":c)+y,_=("s"===p?iT[8+BM/3]:"")+_+(w&&"("===c?")":""),b)for(r=-1,s=t.length;++r<s;)if(48>(l=t.charCodeAt(r))||l>57){_=(46===l?o+t.slice(r+1):t.slice(r))+_,t=t.slice(0,r);break}}d&&!u&&(t=i(t,1/0));var k=y.length+t.length+_.length,C=k<h?new Array(h-k+1).join(e):"";switch(d&&u&&(t=i(C+t,C.length?h-_.length:1/0),C=""),n){case"<":t=y+t+_+C;break;case"=":t=y+C+t+_;break;case"^":t=C.slice(0,k=C.length>>1)+y+t+_+C.slice(k);break;default:t=C+y+t+_}return a(t)}return f=null==f?p?6:12:/[gprs]/.test(p)?Math.max(1,Math.min(21,f)):Math.max(0,Math.min(20,f)),y.toString=function(){return t+""},y}return{format:c,formatPrefix:function(t,e){var n=c(((t=QM(t)).type="f",t)),i=3*Math.max(-8,Math.min(8,Math.floor(KM(e)/3))),r=Math.pow(10,-i),o=iT[8+i/3];return function(t){return n(r*t)+o}}}};function oT(t){return JM=rT(t),tT=JM.format,eT=JM.formatPrefix,JM}oT({decimal:".",thousands:",",grouping:[3],currency:["$",""]});var aT=function(t){return Math.max(0,-KM(Math.abs(t)))},sT=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(KM(e)/3)))-KM(Math.abs(t)))},cT=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,KM(e)-KM(t))+1},lT=function(){return new uT};function uT(){this.reset()}uT.prototype={constructor:uT,reset:function(){this.s=this.t=0},add:function(t){dT(hT,t,this.t),dT(this,hT.s,this.s),this.s?this.t+=hT.t:this.s=hT.t},valueOf:function(){return this.s}};var hT=new uT;function dT(t,e,n){var i=t.s=e+n,r=i-e;t.t=e-(i-r)+(n-r)}var fT=Math.PI,pT=fT/2,mT=fT/4,gT=2*fT,vT=180/fT,bT=fT/180,yT=Math.abs,_T=Math.atan,wT=Math.atan2,kT=Math.cos,CT=Math.ceil,ST=Math.exp,xT=(Math,Math.log),OT=Math.pow,MT=Math.sin,TT=Math.sign||function(t){return t>0?1:t<0?-1:0},ET=Math.sqrt,PT=Math.tan;function AT(t){return t>1?0:t<-1?fT:Math.acos(t)}function jT(t){return t>1?pT:t<-1?-pT:Math.asin(t)}function IT(t){return(t=MT(t/2))*t}function DT(){}function RT(t,e){t&&FT.hasOwnProperty(t.type)&&FT[t.type](t,e)}var LT={Feature:function(t,e){RT(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,i=-1,r=n.length;++i<r;)RT(n[i].geometry,e)}},FT={Sphere:function(t,e){e.sphere()},Point:function(t,e){e.point((t=t.coordinates)[0],t[1],t[2])},MultiPoint:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)e.point((t=n[i])[0],t[1],t[2])},LineString:function(t,e){NT(t.coordinates,e,0)},MultiLineString:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)NT(n[i],e,0)},Polygon:function(t,e){BT(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)BT(n[i],e)},GeometryCollection:function(t,e){for(var n=t.geometries,i=-1,r=n.length;++i<r;)RT(n[i],e)}};function NT(t,e,n){var i,r=-1,o=t.length-n;for(e.lineStart();++r<o;)e.point((i=t[r])[0],i[1],i[2]);e.lineEnd()}function BT(t,e){var n=-1,i=t.length;for(e.polygonStart();++n<i;)NT(t[n],e,1);e.polygonEnd()}var HT,zT,VT,UT,qT,GT=function(t,e){t&&LT.hasOwnProperty(t.type)?LT[t.type](t,e):RT(t,e)},WT=lT(),KT=lT(),XT={point:DT,lineStart:DT,lineEnd:DT,polygonStart:function(){WT.reset(),XT.lineStart=YT,XT.lineEnd=ZT},polygonEnd:function(){var t=+WT;KT.add(t<0?gT+t:t),this.lineStart=this.lineEnd=this.point=DT},sphere:function(){KT.add(gT)}};function YT(){XT.point=QT}function ZT(){$T(HT,zT)}function QT(t,e){XT.point=$T,HT=t,zT=e,VT=t*=bT,UT=kT(e=(e*=bT)/2+mT),qT=MT(e)}function $T(t,e){var n=(t*=bT)-VT,i=n>=0?1:-1,r=i*n,o=kT(e=(e*=bT)/2+mT),a=MT(e),s=qT*a,c=UT*o+s*kT(r),l=s*i*MT(r);WT.add(wT(l,c)),VT=t,UT=o,qT=a}var JT=function(t){return KT.reset(),GT(t,XT),2*KT};function tE(t){return[wT(t[1],t[0]),jT(t[2])]}function eE(t){var e=t[0],n=t[1],i=kT(n);return[i*kT(e),i*MT(e),MT(n)]}function nE(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function iE(t,e){return[t[1]*e[2]-t[2]*e[1],t[2]*e[0]-t[0]*e[2],t[0]*e[1]-t[1]*e[0]]}function rE(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function oE(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function aE(t){var e=ET(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}var sE,cE,lE,uE,hE,dE,fE,pE,mE,gE,vE=lT(),bE={point:yE,lineStart:wE,lineEnd:kE,polygonStart:function(){bE.point=CE,bE.lineStart=SE,bE.lineEnd=xE,vE.reset(),XT.polygonStart()},polygonEnd:function(){XT.polygonEnd(),bE.point=yE,bE.lineStart=wE,bE.lineEnd=kE,WT<0?(sE=-(lE=180),cE=-(uE=90)):vE>1e-6?uE=90:vE<-1e-6&&(cE=-90),gE[0]=sE,gE[1]=lE}};function yE(t,e){mE.push(gE=[sE=t,lE=t]),e<cE&&(cE=e),e>uE&&(uE=e)}function _E(t,e){var n=eE([t*bT,e*bT]);if(pE){var i=iE(pE,n),r=iE([i[1],-i[0],0],i);aE(r),r=tE(r);var o,a=t-hE,s=a>0?1:-1,c=r[0]*vT*s,l=yT(a)>180;l^(s*hE<c&&c<s*t)?(o=r[1]*vT)>uE&&(uE=o):l^(s*hE<(c=(c+360)%360-180)&&c<s*t)?(o=-r[1]*vT)<cE&&(cE=o):(e<cE&&(cE=e),e>uE&&(uE=e)),l?t<hE?OE(sE,t)>OE(sE,lE)&&(lE=t):OE(t,lE)>OE(sE,lE)&&(sE=t):lE>=sE?(t<sE&&(sE=t),t>lE&&(lE=t)):t>hE?OE(sE,t)>OE(sE,lE)&&(lE=t):OE(t,lE)>OE(sE,lE)&&(sE=t)}else mE.push(gE=[sE=t,lE=t]);e<cE&&(cE=e),e>uE&&(uE=e),pE=n,hE=t}function wE(){bE.point=_E}function kE(){gE[0]=sE,gE[1]=lE,bE.point=yE,pE=null}function CE(t,e){if(pE){var n=t-hE;vE.add(yT(n)>180?n+(n>0?360:-360):n)}else dE=t,fE=e;XT.point(t,e),_E(t,e)}function SE(){XT.lineStart()}function xE(){CE(dE,fE),XT.lineEnd(),yT(vE)>1e-6&&(sE=-(lE=180)),gE[0]=sE,gE[1]=lE,pE=null}function OE(t,e){return(e-=t)<0?e+360:e}function ME(t,e){return t[0]-e[0]}function TE(t,e){return t[0]<=t[1]?t[0]<=e&&e<=t[1]:e<t[0]||t[1]<e}var EE,PE,AE,jE,IE,DE,RE,LE,FE,NE,BE,HE,zE,VE,UE,qE,GE=function(t){var e,n,i,r,o,a,s;if(uE=lE=-(sE=cE=1/0),mE=[],GT(t,bE),n=mE.length){for(mE.sort(ME),e=1,o=[i=mE[0]];e<n;++e)TE(i,(r=mE[e])[0])||TE(i,r[1])?(OE(i[0],r[1])>OE(i[0],i[1])&&(i[1]=r[1]),OE(r[0],i[1])>OE(i[0],i[1])&&(i[0]=r[0])):o.push(i=r);for(a=-1/0,e=0,i=o[n=o.length-1];e<=n;i=r,++e)(s=OE(i[1],(r=o[e])[0]))>a&&(a=s,sE=r[0],lE=i[1])}return mE=gE=null,sE===1/0||cE===1/0?[[NaN,NaN],[NaN,NaN]]:[[sE,cE],[lE,uE]]},WE={sphere:DT,point:KE,lineStart:YE,lineEnd:$E,polygonStart:function(){WE.lineStart=JE,WE.lineEnd=tP},polygonEnd:function(){WE.lineStart=YE,WE.lineEnd=$E}};function KE(t,e){t*=bT;var n=kT(e*=bT);XE(n*kT(t),n*MT(t),MT(e))}function XE(t,e,n){++EE,AE+=(t-AE)/EE,jE+=(e-jE)/EE,IE+=(n-IE)/EE}function YE(){WE.point=ZE}function ZE(t,e){t*=bT;var n=kT(e*=bT);VE=n*kT(t),UE=n*MT(t),qE=MT(e),WE.point=QE,XE(VE,UE,qE)}function QE(t,e){t*=bT;var n=kT(e*=bT),i=n*kT(t),r=n*MT(t),o=MT(e),a=wT(ET((a=UE*o-qE*r)*a+(a=qE*i-VE*o)*a+(a=VE*r-UE*i)*a),VE*i+UE*r+qE*o);PE+=a,DE+=a*(VE+(VE=i)),RE+=a*(UE+(UE=r)),LE+=a*(qE+(qE=o)),XE(VE,UE,qE)}function $E(){WE.point=KE}function JE(){WE.point=eP}function tP(){nP(HE,zE),WE.point=KE}function eP(t,e){HE=t,zE=e,t*=bT,e*=bT,WE.point=nP;var n=kT(e);VE=n*kT(t),UE=n*MT(t),qE=MT(e),XE(VE,UE,qE)}function nP(t,e){t*=bT;var n=kT(e*=bT),i=n*kT(t),r=n*MT(t),o=MT(e),a=UE*o-qE*r,s=qE*i-VE*o,c=VE*r-UE*i,l=ET(a*a+s*s+c*c),u=jT(l),h=l&&-u/l;FE+=h*a,NE+=h*s,BE+=h*c,PE+=u,DE+=u*(VE+(VE=i)),RE+=u*(UE+(UE=r)),LE+=u*(qE+(qE=o)),XE(VE,UE,qE)}var iP=function(t){EE=PE=AE=jE=IE=DE=RE=LE=FE=NE=BE=0,GT(t,WE);var e=FE,n=NE,i=BE,r=e*e+n*n+i*i;return r<1e-12&&(e=DE,n=RE,i=LE,PE<1e-6&&(e=AE,n=jE,i=IE),(r=e*e+n*n+i*i)<1e-12)?[NaN,NaN]:[wT(n,e)*vT,jT(i/ET(r))*vT]},rP=function(t){return function(){return t}},oP=function(t,e){function n(n,i){return n=t(n,i),e(n[0],n[1])}return t.invert&&e.invert&&(n.invert=function(n,i){return(n=e.invert(n,i))&&t.invert(n[0],n[1])}),n};function aP(t,e){return[t>fT?t-gT:t<-fT?t+gT:t,e]}function sP(t,e,n){return(t%=gT)?e||n?oP(lP(t),uP(e,n)):lP(t):e||n?uP(e,n):aP}function cP(t){return function(e,n){return[(e+=t)>fT?e-gT:e<-fT?e+gT:e,n]}}function lP(t){var e=cP(t);return e.invert=cP(-t),e}function uP(t,e){var n=kT(t),i=MT(t),r=kT(e),o=MT(e);function a(t,e){var a=kT(e),s=kT(t)*a,c=MT(t)*a,l=MT(e),u=l*n+s*i;return[wT(c*r-u*o,s*n-l*i),jT(u*r+c*o)]}return a.invert=function(t,e){var a=kT(e),s=kT(t)*a,c=MT(t)*a,l=MT(e),u=l*r-c*o;return[wT(c*r+l*o,s*n+u*i),jT(u*n-s*i)]},a}aP.invert=aP;var hP=function(t){function e(e){return(e=t(e[0]*bT,e[1]*bT))[0]*=vT,e[1]*=vT,e}return t=sP(t[0]*bT,t[1]*bT,t.length>2?t[2]*bT:0),e.invert=function(e){return(e=t.invert(e[0]*bT,e[1]*bT))[0]*=vT,e[1]*=vT,e},e};function dP(t,e,n,i,r,o){if(n){var a=kT(e),s=MT(e),c=i*n;null==r?(r=e+i*gT,o=e-c/2):(r=fP(a,r),o=fP(a,o),(i>0?r<o:r>o)&&(r+=i*gT));for(var l,u=r;i>0?u>o:u<o;u-=c)l=tE([a,-s*kT(u),-s*MT(u)]),t.point(l[0],l[1])}}function fP(t,e){(e=eE(e))[0]-=t,aE(e);var n=AT(-e[1]);return((-e[2]<0?-n:n)+gT-1e-6)%gT}var pP=function(){var t,e,n=rP([0,0]),i=rP(90),r=rP(6),o={point:function(n,i){t.push(n=e(n,i)),n[0]*=vT,n[1]*=vT}};function a(){var a=n.apply(this,arguments),s=i.apply(this,arguments)*bT,c=r.apply(this,arguments)*bT;return t=[],e=sP(-a[0]*bT,-a[1]*bT,0).invert,dP(o,s,c,1),a={type:"Polygon",coordinates:[t]},t=e=null,a}return a.center=function(t){return arguments.length?(n="function"==typeof t?t:rP([+t[0],+t[1]]),a):n},a.radius=function(t){return arguments.length?(i="function"==typeof t?t:rP(+t),a):i},a.precision=function(t){return arguments.length?(r="function"==typeof t?t:rP(+t),a):r},a},mP=function(){var t,e=[];return{point:function(e,n){t.push([e,n])},lineStart:function(){e.push(t=[])},lineEnd:DT,rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}},gP=function(t,e){return yT(t[0]-e[0])<1e-6&&yT(t[1]-e[1])<1e-6};function vP(t,e,n,i){this.x=t,this.z=e,this.o=n,this.e=i,this.v=!1,this.n=this.p=null}var bP=function(t,e,n,i,r){var o,a,s=[],c=[];if(t.forEach((function(t){if(!((e=t.length-1)<=0)){var e,n,i=t[0],a=t[e];if(gP(i,a)){for(r.lineStart(),o=0;o<e;++o)r.point((i=t[o])[0],i[1]);r.lineEnd()}else s.push(n=new vP(i,t,null,!0)),c.push(n.o=new vP(i,null,n,!1)),s.push(n=new vP(a,t,null,!1)),c.push(n.o=new vP(a,null,n,!0))}})),s.length){for(c.sort(e),yP(s),yP(c),o=0,a=c.length;o<a;++o)c[o].e=n=!n;for(var l,u,h=s[0];;){for(var d=h,f=!0;d.v;)if((d=d.n)===h)return;l=d.z,r.lineStart();do{if(d.v=d.o.v=!0,d.e){if(f)for(o=0,a=l.length;o<a;++o)r.point((u=l[o])[0],u[1]);else i(d.x,d.n.x,1,r);d=d.n}else{if(f)for(o=(l=d.p.z).length-1;o>=0;--o)r.point((u=l[o])[0],u[1]);else i(d.x,d.p.x,-1,r);d=d.p}l=(d=d.o).z,f=!f}while(!d.v);r.lineEnd()}}};function yP(t){if(e=t.length){for(var e,n,i=0,r=t[0];++i<e;)r.n=n=t[i],n.p=r,r=n;r.n=n=t[0],n.p=r}}var _P=lT(),wP=function(t,e){var n=e[0],i=e[1],r=MT(i),o=[MT(n),-kT(n),0],a=0,s=0;_P.reset(),1===r?i=pT+1e-6:-1===r&&(i=-pT-1e-6);for(var c=0,l=t.length;c<l;++c)if(h=(u=t[c]).length)for(var u,h,d=u[h-1],f=d[0],p=d[1]/2+mT,m=MT(p),g=kT(p),v=0;v<h;++v,f=y,m=w,g=k,d=b){var b=u[v],y=b[0],_=b[1]/2+mT,w=MT(_),k=kT(_),C=y-f,S=C>=0?1:-1,x=S*C,O=x>fT,M=m*w;if(_P.add(wT(M*S*MT(x),g*k+M*kT(x))),a+=O?C+S*gT:C,O^f>=n^y>=n){var T=iE(eE(d),eE(b));aE(T);var E=iE(o,T);aE(E);var P=(O^C>=0?-1:1)*jT(E[2]);(i>P||i===P&&(T[0]||T[1]))&&(s+=O^C>=0?1:-1)}}return(a<-1e-6||a<1e-6&&_P<-1e-6)^1&s},kP=function(t,e,n,i){return function(r){var o,a,s,c=e(r),l=mP(),u=e(l),h=!1,d={point:f,lineStart:m,lineEnd:g,polygonStart:function(){d.point=v,d.lineStart=b,d.lineEnd=y,a=[],o=[]},polygonEnd:function(){d.point=f,d.lineStart=m,d.lineEnd=g,a=s_(a);var t=wP(o,i);a.length?(h||(r.polygonStart(),h=!0),bP(a,SP,t,n,r)):t&&(h||(r.polygonStart(),h=!0),r.lineStart(),n(null,null,1,r),r.lineEnd()),h&&(r.polygonEnd(),h=!1),a=o=null},sphere:function(){r.polygonStart(),r.lineStart(),n(null,null,1,r),r.lineEnd(),r.polygonEnd()}};function f(e,n){t(e,n)&&r.point(e,n)}function p(t,e){c.point(t,e)}function m(){d.point=p,c.lineStart()}function g(){d.point=f,c.lineEnd()}function v(t,e){s.push([t,e]),u.point(t,e)}function b(){u.lineStart(),s=[]}function y(){v(s[0][0],s[0][1]),u.lineEnd();var t,e,n,i,c=u.clean(),d=l.result(),f=d.length;if(s.pop(),o.push(s),s=null,f)if(1&c){if((e=(n=d[0]).length-1)>0){for(h||(r.polygonStart(),h=!0),r.lineStart(),t=0;t<e;++t)r.point((i=n[t])[0],i[1]);r.lineEnd()}}else f>1&&2&c&&d.push(d.pop().concat(d.shift())),a.push(d.filter(CP))}return d}};function CP(t){return t.length>1}function SP(t,e){return((t=t.x)[0]<0?t[1]-pT-1e-6:pT-t[1])-((e=e.x)[0]<0?e[1]-pT-1e-6:pT-e[1])}var xP=kP((function(){return!0}),(function(t){var e,n=NaN,i=NaN,r=NaN;return{lineStart:function(){t.lineStart(),e=1},point:function(o,a){var s=o>0?fT:-fT,c=yT(o-n);yT(c-fT)<1e-6?(t.point(n,i=(i+a)/2>0?pT:-pT),t.point(r,i),t.lineEnd(),t.lineStart(),t.point(s,i),t.point(o,i),e=0):r!==s&&c>=fT&&(yT(n-r)<1e-6&&(n-=1e-6*r),yT(o-s)<1e-6&&(o-=1e-6*s),i=function(t,e,n,i){var r,o,a=MT(t-n);return yT(a)>1e-6?_T((MT(e)*(o=kT(i))*MT(n)-MT(i)*(r=kT(e))*MT(t))/(r*o*a)):(e+i)/2}(n,i,o,a),t.point(r,i),t.lineEnd(),t.lineStart(),t.point(s,i),e=0),t.point(n=o,i=a),r=s},lineEnd:function(){t.lineEnd(),n=i=NaN},clean:function(){return 2-e}}}),(function(t,e,n,i){var r;if(null==t)i.point(-fT,r=n*pT),i.point(0,r),i.point(fT,r),i.point(fT,0),i.point(fT,-r),i.point(0,-r),i.point(-fT,-r),i.point(-fT,0),i.point(-fT,r);else if(yT(t[0]-e[0])>1e-6){var o=t[0]<e[0]?fT:-fT;i.point(-o,r=n*o/2),i.point(0,r),i.point(o,r)}else i.point(e[0],e[1])}),[-fT,-pT]),OP=function(t){var e=kT(t),n=6*bT,i=e>0,r=yT(e)>1e-6;function o(t,n){return kT(t)*kT(n)>e}function a(t,n,i){var r=[1,0,0],o=iE(eE(t),eE(n)),a=nE(o,o),s=o[0],c=a-s*s;if(!c)return!i&&t;var l=e*a/c,u=-e*s/c,h=iE(r,o),d=oE(r,l);rE(d,oE(o,u));var f=h,p=nE(d,f),m=nE(f,f),g=p*p-m*(nE(d,d)-1);if(!(g<0)){var v=ET(g),b=oE(f,(-p-v)/m);if(rE(b,d),b=tE(b),!i)return b;var y,_=t[0],w=n[0],k=t[1],C=n[1];w<_&&(y=_,_=w,w=y);var S=w-_,x=yT(S-fT)<1e-6;if(!x&&C<k&&(y=k,k=C,C=y),x||S<1e-6?x?k+C>0^b[1]<(yT(b[0]-_)<1e-6?k:C):k<=b[1]&&b[1]<=C:S>fT^(_<=b[0]&&b[0]<=w)){var O=oE(f,(-p+v)/m);return rE(O,d),[b,tE(O)]}}}function s(e,n){var r=i?t:fT-t,o=0;return e<-r?o|=1:e>r&&(o|=2),n<-r?o|=4:n>r&&(o|=8),o}return kP(o,(function(t){var e,n,c,l,u;return{lineStart:function(){l=c=!1,u=1},point:function(h,d){var f,p=[h,d],m=o(h,d),g=i?m?0:s(h,d):m?s(h+(h<0?fT:-fT),d):0;if(!e&&(l=c=m)&&t.lineStart(),m!==c&&(!(f=a(e,p))||gP(e,f)||gP(p,f))&&(p[0]+=1e-6,p[1]+=1e-6,m=o(p[0],p[1])),m!==c)u=0,m?(t.lineStart(),f=a(p,e),t.point(f[0],f[1])):(f=a(e,p),t.point(f[0],f[1]),t.lineEnd()),e=f;else if(r&&e&&i^m){var v;g&n||!(v=a(p,e,!0))||(u=0,i?(t.lineStart(),t.point(v[0][0],v[0][1]),t.point(v[1][0],v[1][1]),t.lineEnd()):(t.point(v[1][0],v[1][1]),t.lineEnd(),t.lineStart(),t.point(v[0][0],v[0][1])))}!m||e&&gP(e,p)||t.point(p[0],p[1]),e=p,c=m,n=g},lineEnd:function(){c&&t.lineEnd(),e=null},clean:function(){return u|(l&&c)<<1}}}),(function(e,i,r,o){dP(o,t,n,r,e,i)}),i?[0,-t]:[-fT,t-fT])};function MP(t,e,n,i){function r(r,o){return t<=r&&r<=n&&e<=o&&o<=i}function o(r,o,s,l){var u=0,h=0;if(null==r||(u=a(r,s))!==(h=a(o,s))||c(r,o)<0^s>0)do{l.point(0===u||3===u?t:n,u>1?i:e)}while((u=(u+s+4)%4)!==h);else l.point(o[0],o[1])}function a(i,r){return yT(i[0]-t)<1e-6?r>0?0:3:yT(i[0]-n)<1e-6?r>0?2:1:yT(i[1]-e)<1e-6?r>0?1:0:r>0?3:2}function s(t,e){return c(t.x,e.x)}function c(t,e){var n=a(t,1),i=a(e,1);return n!==i?n-i:0===n?e[1]-t[1]:1===n?t[0]-e[0]:2===n?t[1]-e[1]:e[0]-t[0]}return function(a){var c,l,u,h,d,f,p,m,g,v,b,y=a,_=mP(),w={point:k,lineStart:function(){w.point=C,l&&l.push(u=[]),v=!0,g=!1,p=m=NaN},lineEnd:function(){c&&(C(h,d),f&&g&&_.rejoin(),c.push(_.result())),w.point=k,g&&y.lineEnd()},polygonStart:function(){y=_,c=[],l=[],b=!0},polygonEnd:function(){var e=function(){for(var e=0,n=0,r=l.length;n<r;++n)for(var o,a,s=l[n],c=1,u=s.length,h=s[0],d=h[0],f=h[1];c<u;++c)o=d,a=f,d=(h=s[c])[0],f=h[1],a<=i?f>i&&(d-o)*(i-a)>(f-a)*(t-o)&&++e:f<=i&&(d-o)*(i-a)<(f-a)*(t-o)&&--e;return e}(),n=b&&e,r=(c=s_(c)).length;(n||r)&&(a.polygonStart(),n&&(a.lineStart(),o(null,null,1,a),a.lineEnd()),r&&bP(c,s,e,o,a),a.polygonEnd()),y=a,c=l=u=null}};function k(t,e){r(t,e)&&y.point(t,e)}function C(o,a){var s=r(o,a);if(l&&u.push([o,a]),v)h=o,d=a,f=s,v=!1,s&&(y.lineStart(),y.point(o,a));else if(s&&g)y.point(o,a);else{var c=[p=Math.max(-1e9,Math.min(1e9,p)),m=Math.max(-1e9,Math.min(1e9,m))],_=[o=Math.max(-1e9,Math.min(1e9,o)),a=Math.max(-1e9,Math.min(1e9,a))];!function(t,e,n,i,r,o){var a,s=t[0],c=t[1],l=0,u=1,h=e[0]-s,d=e[1]-c;if(a=n-s,h||!(a>0)){if(a/=h,h<0){if(a<l)return;a<u&&(u=a)}else if(h>0){if(a>u)return;a>l&&(l=a)}if(a=r-s,h||!(a<0)){if(a/=h,h<0){if(a>u)return;a>l&&(l=a)}else if(h>0){if(a<l)return;a<u&&(u=a)}if(a=i-c,d||!(a>0)){if(a/=d,d<0){if(a<l)return;a<u&&(u=a)}else if(d>0){if(a>u)return;a>l&&(l=a)}if(a=o-c,d||!(a<0)){if(a/=d,d<0){if(a>u)return;a>l&&(l=a)}else if(d>0){if(a<l)return;a<u&&(u=a)}return l>0&&(t[0]=s+l*h,t[1]=c+l*d),u<1&&(e[0]=s+u*h,e[1]=c+u*d),!0}}}}}(c,_,t,e,n,i)?s&&(y.lineStart(),y.point(o,a),b=!1):(g||(y.lineStart(),y.point(c[0],c[1])),y.point(_[0],_[1]),s||y.lineEnd(),b=!1)}p=o,m=a,g=s}return w}}var TP,EP,PP,AP=function(){var t,e,n,i=0,r=0,o=960,a=500;return n={stream:function(n){return t&&e===n?t:t=MP(i,r,o,a)(e=n)},extent:function(s){return arguments.length?(i=+s[0][0],r=+s[0][1],o=+s[1][0],a=+s[1][1],t=e=null,n):[[i,r],[o,a]]}}},jP=lT(),IP={sphere:DT,point:DT,lineStart:function(){IP.point=RP,IP.lineEnd=DP},lineEnd:DT,polygonStart:DT,polygonEnd:DT};function DP(){IP.point=IP.lineEnd=DT}function RP(t,e){TP=t*=bT,EP=MT(e*=bT),PP=kT(e),IP.point=LP}function LP(t,e){t*=bT;var n=MT(e*=bT),i=kT(e),r=yT(t-TP),o=kT(r),a=i*MT(r),s=PP*n-EP*i*o,c=EP*n+PP*i*o;jP.add(wT(ET(a*a+s*s),c)),TP=t,EP=n,PP=i}var FP=function(t){return jP.reset(),GT(t,IP),+jP},NP=[null,null],BP={type:"LineString",coordinates:NP},HP=function(t,e){return NP[0]=t,NP[1]=e,FP(BP)},zP={Feature:function(t,e){return UP(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,i=-1,r=n.length;++i<r;)if(UP(n[i].geometry,e))return!0;return!1}},VP={Sphere:function(){return!0},Point:function(t,e){return qP(t.coordinates,e)},MultiPoint:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)if(qP(n[i],e))return!0;return!1},LineString:function(t,e){return GP(t.coordinates,e)},MultiLineString:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)if(GP(n[i],e))return!0;return!1},Polygon:function(t,e){return WP(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)if(WP(n[i],e))return!0;return!1},GeometryCollection:function(t,e){for(var n=t.geometries,i=-1,r=n.length;++i<r;)if(UP(n[i],e))return!0;return!1}};function UP(t,e){return!(!t||!VP.hasOwnProperty(t.type))&&VP[t.type](t,e)}function qP(t,e){return 0===HP(t,e)}function GP(t,e){var n=HP(t[0],t[1]);return HP(t[0],e)+HP(e,t[1])<=n+1e-6}function WP(t,e){return!!wP(t.map(KP),XP(e))}function KP(t){return(t=t.map(XP)).pop(),t}function XP(t){return[t[0]*bT,t[1]*bT]}var YP=function(t,e){return(t&&zP.hasOwnProperty(t.type)?zP[t.type]:UP)(t,e)};function ZP(t,e,n){var i=Wy(t,e-1e-6,n).concat(e);return function(t){return i.map((function(e){return[t,e]}))}}function QP(t,e,n){var i=Wy(t,e-1e-6,n).concat(e);return function(t){return i.map((function(e){return[e,t]}))}}function $P(){var t,e,n,i,r,o,a,s,c,l,u,h,d=10,f=d,p=90,m=360,g=2.5;function v(){return{type:"MultiLineString",coordinates:b()}}function b(){return Wy(CT(i/p)*p,n,p).map(u).concat(Wy(CT(s/m)*m,a,m).map(h)).concat(Wy(CT(e/d)*d,t,d).filter((function(t){return yT(t%p)>1e-6})).map(c)).concat(Wy(CT(o/f)*f,r,f).filter((function(t){return yT(t%m)>1e-6})).map(l))}return v.lines=function(){return b().map((function(t){return{type:"LineString",coordinates:t}}))},v.outline=function(){return{type:"Polygon",coordinates:[u(i).concat(h(a).slice(1),u(n).reverse().slice(1),h(s).reverse().slice(1))]}},v.extent=function(t){return arguments.length?v.extentMajor(t).extentMinor(t):v.extentMinor()},v.extentMajor=function(t){return arguments.length?(s=+t[0][1],a=+t[1][1],(i=+t[0][0])>(n=+t[1][0])&&(t=i,i=n,n=t),s>a&&(t=s,s=a,a=t),v.precision(g)):[[i,s],[n,a]]},v.extentMinor=function(n){return arguments.length?(o=+n[0][1],r=+n[1][1],(e=+n[0][0])>(t=+n[1][0])&&(n=e,e=t,t=n),o>r&&(n=o,o=r,r=n),v.precision(g)):[[e,o],[t,r]]},v.step=function(t){return arguments.length?v.stepMajor(t).stepMinor(t):v.stepMinor()},v.stepMajor=function(t){return arguments.length?(p=+t[0],m=+t[1],v):[p,m]},v.stepMinor=function(t){return arguments.length?(d=+t[0],f=+t[1],v):[d,f]},v.precision=function(d){return arguments.length?(g=+d,c=ZP(o,r,90),l=QP(e,t,g),u=ZP(s,a,90),h=QP(i,n,g),v):g},v.extentMajor([[-180,-89.999999],[180,89.999999]]).extentMinor([[-180,-80.000001],[180,80.000001]])}function JP(){return $P()()}var tA,eA,nA,iA,rA=function(t,e){var n=t[0]*bT,i=t[1]*bT,r=e[0]*bT,o=e[1]*bT,a=kT(i),s=MT(i),c=kT(o),l=MT(o),u=a*kT(n),h=a*MT(n),d=c*kT(r),f=c*MT(r),p=2*jT(ET(IT(o-i)+a*c*IT(r-n))),m=MT(p),g=p?function(t){var e=MT(t*=p)/m,n=MT(p-t)/m,i=n*u+e*d,r=n*h+e*f,o=n*s+e*l;return[wT(r,i)*vT,wT(o,ET(i*i+r*r))*vT]}:function(){return[n*vT,i*vT]};return g.distance=p,g},oA=function(t){return t},aA=lT(),sA=lT(),cA={point:DT,lineStart:DT,lineEnd:DT,polygonStart:function(){cA.lineStart=lA,cA.lineEnd=dA},polygonEnd:function(){cA.lineStart=cA.lineEnd=cA.point=DT,aA.add(yT(sA)),sA.reset()},result:function(){var t=aA/2;return aA.reset(),t}};function lA(){cA.point=uA}function uA(t,e){cA.point=hA,tA=nA=t,eA=iA=e}function hA(t,e){sA.add(iA*t-nA*e),nA=t,iA=e}function dA(){hA(tA,eA)}var fA,pA,mA,gA,vA=cA,bA=1/0,yA=bA,_A=-bA,wA=_A,kA={point:function(t,e){t<bA&&(bA=t),t>_A&&(_A=t),e<yA&&(yA=e),e>wA&&(wA=e)},lineStart:DT,lineEnd:DT,polygonStart:DT,polygonEnd:DT,result:function(){var t=[[bA,yA],[_A,wA]];return _A=wA=-(yA=bA=1/0),t}},CA=0,SA=0,xA=0,OA=0,MA=0,TA=0,EA=0,PA=0,AA=0,jA={point:IA,lineStart:DA,lineEnd:FA,polygonStart:function(){jA.lineStart=NA,jA.lineEnd=BA},polygonEnd:function(){jA.point=IA,jA.lineStart=DA,jA.lineEnd=FA},result:function(){var t=AA?[EA/AA,PA/AA]:TA?[OA/TA,MA/TA]:xA?[CA/xA,SA/xA]:[NaN,NaN];return CA=SA=xA=OA=MA=TA=EA=PA=AA=0,t}};function IA(t,e){CA+=t,SA+=e,++xA}function DA(){jA.point=RA}function RA(t,e){jA.point=LA,IA(mA=t,gA=e)}function LA(t,e){var n=t-mA,i=e-gA,r=ET(n*n+i*i);OA+=r*(mA+t)/2,MA+=r*(gA+e)/2,TA+=r,IA(mA=t,gA=e)}function FA(){jA.point=IA}function NA(){jA.point=HA}function BA(){zA(fA,pA)}function HA(t,e){jA.point=zA,IA(fA=mA=t,pA=gA=e)}function zA(t,e){var n=t-mA,i=e-gA,r=ET(n*n+i*i);OA+=r*(mA+t)/2,MA+=r*(gA+e)/2,TA+=r,EA+=(r=gA*t-mA*e)*(mA+t),PA+=r*(gA+e),AA+=3*r,IA(mA=t,gA=e)}var VA=jA;function UA(t){this._context=t}UA.prototype={_radius:4.5,pointRadius:function(t){return this._radius=t,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){0===this._line&&this._context.closePath(),this._point=NaN},point:function(t,e){switch(this._point){case 0:this._context.moveTo(t,e),this._point=1;break;case 1:this._context.lineTo(t,e);break;default:this._context.moveTo(t+this._radius,e),this._context.arc(t,e,this._radius,0,gT)}},result:DT};var qA,GA,WA,KA,XA,YA=lT(),ZA={point:DT,lineStart:function(){ZA.point=QA},lineEnd:function(){qA&&$A(GA,WA),ZA.point=DT},polygonStart:function(){qA=!0},polygonEnd:function(){qA=null},result:function(){var t=+YA;return YA.reset(),t}};function QA(t,e){ZA.point=$A,GA=KA=t,WA=XA=e}function $A(t,e){YA.add(ET((KA-=t)*KA+(XA-=e)*XA)),KA=t,XA=e}var JA=ZA;function tj(){this._string=[]}function ej(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}tj.prototype={_radius:4.5,_circle:ej(4.5),pointRadius:function(t){return(t=+t)!==this._radius&&(this._radius=t,this._circle=null),this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){0===this._line&&this._string.push("Z"),this._point=NaN},point:function(t,e){switch(this._point){case 0:this._string.push("M",t,",",e),this._point=1;break;case 1:this._string.push("L",t,",",e);break;default:null==this._circle&&(this._circle=ej(this._radius)),this._string.push("M",t,",",e,this._circle)}},result:function(){if(this._string.length){var t=this._string.join("");return this._string=[],t}return null}};var nj=function(t,e){var n,i,r=4.5;function o(t){return t&&("function"==typeof r&&i.pointRadius(+r.apply(this,arguments)),GT(t,n(i))),i.result()}return o.area=function(t){return GT(t,n(vA)),vA.result()},o.measure=function(t){return GT(t,n(JA)),JA.result()},o.bounds=function(t){return GT(t,n(kA)),kA.result()},o.centroid=function(t){return GT(t,n(VA)),VA.result()},o.projection=function(e){return arguments.length?(n=null==e?(t=null,oA):(t=e).stream,o):t},o.context=function(t){return arguments.length?(i=null==t?(e=null,new tj):new UA(e=t),"function"!=typeof r&&i.pointRadius(r),o):e},o.pointRadius=function(t){return arguments.length?(r="function"==typeof t?t:(i.pointRadius(+t),+t),o):r},o.projection(t).context(e)},ij=function(t){return{stream:rj(t)}};function rj(t){return function(e){var n=new oj;for(var i in t)n[i]=t[i];return n.stream=e,n}}function oj(){}function aj(t,e,n){var i=t.clipExtent&&t.clipExtent();return t.scale(150).translate([0,0]),null!=i&&t.clipExtent(null),GT(n,t.stream(kA)),e(kA.result()),null!=i&&t.clipExtent(i),t}function sj(t,e,n){return aj(t,(function(n){var i=e[1][0]-e[0][0],r=e[1][1]-e[0][1],o=Math.min(i/(n[1][0]-n[0][0]),r/(n[1][1]-n[0][1])),a=+e[0][0]+(i-o*(n[1][0]+n[0][0]))/2,s=+e[0][1]+(r-o*(n[1][1]+n[0][1]))/2;t.scale(150*o).translate([a,s])}),n)}function cj(t,e,n){return sj(t,[[0,0],e],n)}function lj(t,e,n){return aj(t,(function(n){var i=+e,r=i/(n[1][0]-n[0][0]),o=(i-r*(n[1][0]+n[0][0]))/2,a=-r*n[0][1];t.scale(150*r).translate([o,a])}),n)}function uj(t,e,n){return aj(t,(function(n){var i=+e,r=i/(n[1][1]-n[0][1]),o=-r*n[0][0],a=(i-r*(n[1][1]+n[0][1]))/2;t.scale(150*r).translate([o,a])}),n)}oj.prototype={constructor:oj,point:function(t,e){this.stream.point(t,e)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};var hj=kT(30*bT),dj=function(t,e){return+e?function(t,e){function n(i,r,o,a,s,c,l,u,h,d,f,p,m,g){var v=l-i,b=u-r,y=v*v+b*b;if(y>4*e&&m--){var _=a+d,w=s+f,k=c+p,C=ET(_*_+w*w+k*k),S=jT(k/=C),x=yT(yT(k)-1)<1e-6||yT(o-h)<1e-6?(o+h)/2:wT(w,_),O=t(x,S),M=O[0],T=O[1],E=M-i,P=T-r,A=b*E-v*P;(A*A/y>e||yT((v*E+b*P)/y-.5)>.3||a*d+s*f+c*p<hj)&&(n(i,r,o,a,s,c,M,T,x,_/=C,w/=C,k,m,g),g.point(M,T),n(M,T,x,_,w,k,l,u,h,d,f,p,m,g))}}return function(e){var i,r,o,a,s,c,l,u,h,d,f,p,m={point:g,lineStart:v,lineEnd:y,polygonStart:function(){e.polygonStart(),m.lineStart=_},polygonEnd:function(){e.polygonEnd(),m.lineStart=v}};function g(n,i){n=t(n,i),e.point(n[0],n[1])}function v(){u=NaN,m.point=b,e.lineStart()}function b(i,r){var o=eE([i,r]),a=t(i,r);n(u,h,l,d,f,p,u=a[0],h=a[1],l=i,d=o[0],f=o[1],p=o[2],16,e),e.point(u,h)}function y(){m.point=g,e.lineEnd()}function _(){v(),m.point=w,m.lineEnd=k}function w(t,e){b(i=t,e),r=u,o=h,a=d,s=f,c=p,m.point=b}function k(){n(u,h,l,d,f,p,r,o,i,a,s,c,16,e),m.lineEnd=y,y()}return m}}(t,e):function(t){return rj({point:function(e,n){e=t(e,n),this.stream.point(e[0],e[1])}})}(t)},fj=rj({point:function(t,e){this.stream.point(t*bT,e*bT)}});function pj(t,e,n){function i(i,r){return[e+t*i,n-t*r]}return i.invert=function(i,r){return[(i-e)/t,(n-r)/t]},i}function mj(t,e,n,i){var r=kT(i),o=MT(i),a=r*t,s=o*t,c=r/t,l=o/t,u=(o*n-r*e)/t,h=(o*e+r*n)/t;function d(t,i){return[a*t-s*i+e,n-s*t-a*i]}return d.invert=function(t,e){return[c*t-l*e+u,h-l*t-c*e]},d}function gj(t){return vj((function(){return t}))()}function vj(t){var e,n,i,r,o,a,s,c,l,u,h=150,d=480,f=250,p=0,m=0,g=0,v=0,b=0,y=0,_=null,w=xP,k=null,C=oA,S=.5;function x(t){return c(t[0]*bT,t[1]*bT)}function O(t){return(t=c.invert(t[0],t[1]))&&[t[0]*vT,t[1]*vT]}function M(){var t=mj(h,0,0,y).apply(null,e(p,m)),i=(y?mj:pj)(h,d-t[0],f-t[1],y);return n=sP(g,v,b),s=oP(e,i),c=oP(n,s),a=dj(s,S),T()}function T(){return l=u=null,x}return x.stream=function(t){return l&&u===t?l:l=fj(function(t){return rj({point:function(e,n){var i=t(e,n);return this.stream.point(i[0],i[1])}})}(n)(w(a(C(u=t)))))},x.preclip=function(t){return arguments.length?(w=t,_=void 0,T()):w},x.postclip=function(t){return arguments.length?(C=t,k=i=r=o=null,T()):C},x.clipAngle=function(t){return arguments.length?(w=+t?OP(_=t*bT):(_=null,xP),T()):_*vT},x.clipExtent=function(t){return arguments.length?(C=null==t?(k=i=r=o=null,oA):MP(k=+t[0][0],i=+t[0][1],r=+t[1][0],o=+t[1][1]),T()):null==k?null:[[k,i],[r,o]]},x.scale=function(t){return arguments.length?(h=+t,M()):h},x.translate=function(t){return arguments.length?(d=+t[0],f=+t[1],M()):[d,f]},x.center=function(t){return arguments.length?(p=t[0]%360*bT,m=t[1]%360*bT,M()):[p*vT,m*vT]},x.rotate=function(t){return arguments.length?(g=t[0]%360*bT,v=t[1]%360*bT,b=t.length>2?t[2]%360*bT:0,M()):[g*vT,v*vT,b*vT]},x.angle=function(t){return arguments.length?(y=t%360*bT,M()):y*vT},x.precision=function(t){return arguments.length?(a=dj(s,S=t*t),T()):ET(S)},x.fitExtent=function(t,e){return sj(x,t,e)},x.fitSize=function(t,e){return cj(x,t,e)},x.fitWidth=function(t,e){return lj(x,t,e)},x.fitHeight=function(t,e){return uj(x,t,e)},function(){return e=t.apply(this,arguments),x.invert=e.invert&&O,M()}}function bj(t){var e=0,n=fT/3,i=vj(t),r=i(e,n);return r.parallels=function(t){return arguments.length?i(e=t[0]*bT,n=t[1]*bT):[e*vT,n*vT]},r}function yj(t,e){var n=MT(t),i=(n+MT(e))/2;if(yT(i)<1e-6)return function(t){var e=kT(t);function n(t,n){return[t*e,MT(n)/e]}return n.invert=function(t,n){return[t/e,jT(n*e)]},n}(t);var r=1+n*(2*i-n),o=ET(r)/i;function a(t,e){var n=ET(r-2*i*MT(e))/i;return[n*MT(t*=i),o-n*kT(t)]}return a.invert=function(t,e){var n=o-e;return[wT(t,yT(n))/i*TT(n),jT((r-(t*t+n*n)*i*i)/(2*i))]},a}var _j=function(){return bj(yj).scale(155.424).center([0,33.6442])},wj=function(){return _j().parallels([29.5,45.5]).scale(1070).translate([480,250]).rotate([96,0]).center([-.6,38.7])},kj=function(){var t,e,n,i,r,o,a=wj(),s=_j().rotate([154,0]).center([-2,58.5]).parallels([55,65]),c=_j().rotate([157,0]).center([-3,19.9]).parallels([8,18]),l={point:function(t,e){o=[t,e]}};function u(t){var e=t[0],a=t[1];return o=null,n.point(e,a),o||(i.point(e,a),o)||(r.point(e,a),o)}function h(){return t=e=null,u}return u.invert=function(t){var e=a.scale(),n=a.translate(),i=(t[0]-n[0])/e,r=(t[1]-n[1])/e;return(r>=.12&&r<.234&&i>=-.425&&i<-.214?s:r>=.166&&r<.234&&i>=-.214&&i<-.115?c:a).invert(t)},u.stream=function(n){return t&&e===n?t:(i=[a.stream(e=n),s.stream(n),c.stream(n)],r=i.length,t={point:function(t,e){for(var n=-1;++n<r;)i[n].point(t,e)},sphere:function(){for(var t=-1;++t<r;)i[t].sphere()},lineStart:function(){for(var t=-1;++t<r;)i[t].lineStart()},lineEnd:function(){for(var t=-1;++t<r;)i[t].lineEnd()},polygonStart:function(){for(var t=-1;++t<r;)i[t].polygonStart()},polygonEnd:function(){for(var t=-1;++t<r;)i[t].polygonEnd()}});var i,r},u.precision=function(t){return arguments.length?(a.precision(t),s.precision(t),c.precision(t),h()):a.precision()},u.scale=function(t){return arguments.length?(a.scale(t),s.scale(.35*t),c.scale(t),u.translate(a.translate())):a.scale()},u.translate=function(t){if(!arguments.length)return a.translate();var e=a.scale(),o=+t[0],u=+t[1];return n=a.translate(t).clipExtent([[o-.455*e,u-.238*e],[o+.455*e,u+.238*e]]).stream(l),i=s.translate([o-.307*e,u+.201*e]).clipExtent([[o-.425*e+1e-6,u+.12*e+1e-6],[o-.214*e-1e-6,u+.234*e-1e-6]]).stream(l),r=c.translate([o-.205*e,u+.212*e]).clipExtent([[o-.214*e+1e-6,u+.166*e+1e-6],[o-.115*e-1e-6,u+.234*e-1e-6]]).stream(l),h()},u.fitExtent=function(t,e){return sj(u,t,e)},u.fitSize=function(t,e){return cj(u,t,e)},u.fitWidth=function(t,e){return lj(u,t,e)},u.fitHeight=function(t,e){return uj(u,t,e)},u.scale(1070)};function Cj(t){return function(e,n){var i=kT(e),r=kT(n),o=t(i*r);return[o*r*MT(e),o*MT(n)]}}function Sj(t){return function(e,n){var i=ET(e*e+n*n),r=t(i),o=MT(r),a=kT(r);return[wT(e*o,i*a),jT(i&&n*o/i)]}}var xj=Cj((function(t){return ET(2/(1+t))}));xj.invert=Sj((function(t){return 2*jT(t/2)}));var Oj=function(){return gj(xj).scale(124.75).clipAngle(179.999)},Mj=Cj((function(t){return(t=AT(t))&&t/MT(t)}));Mj.invert=Sj((function(t){return t}));var Tj=function(){return gj(Mj).scale(79.4188).clipAngle(179.999)};function Ej(t,e){return[t,xT(PT((pT+e)/2))]}Ej.invert=function(t,e){return[t,2*_T(ST(e))-pT]};var Pj=function(){return Aj(Ej).scale(961/gT)};function Aj(t){var e,n,i,r=gj(t),o=r.center,a=r.scale,s=r.translate,c=r.clipExtent,l=null;function u(){var o=fT*a(),s=r(hP(r.rotate()).invert([0,0]));return c(null==l?[[s[0]-o,s[1]-o],[s[0]+o,s[1]+o]]:t===Ej?[[Math.max(s[0]-o,l),e],[Math.min(s[0]+o,n),i]]:[[l,Math.max(s[1]-o,e)],[n,Math.min(s[1]+o,i)]])}return r.scale=function(t){return arguments.length?(a(t),u()):a()},r.translate=function(t){return arguments.length?(s(t),u()):s()},r.center=function(t){return arguments.length?(o(t),u()):o()},r.clipExtent=function(t){return arguments.length?(null==t?l=e=n=i=null:(l=+t[0][0],e=+t[0][1],n=+t[1][0],i=+t[1][1]),u()):null==l?null:[[l,e],[n,i]]},u()}function jj(t){return PT((pT+t)/2)}function Ij(t,e){var n=kT(t),i=t===e?MT(t):xT(n/kT(e))/xT(jj(e)/jj(t)),r=n*OT(jj(t),i)/i;if(!i)return Ej;function o(t,e){r>0?e<1e-6-pT&&(e=1e-6-pT):e>pT-1e-6&&(e=pT-1e-6);var n=r/OT(jj(e),i);return[n*MT(i*t),r-n*kT(i*t)]}return o.invert=function(t,e){var n=r-e,o=TT(i)*ET(t*t+n*n);return[wT(t,yT(n))/i*TT(n),2*_T(OT(r/o,1/i))-pT]},o}var Dj=function(){return bj(Ij).scale(109.5).parallels([30,30])};function Rj(t,e){return[t,e]}Rj.invert=Rj;var Lj=function(){return gj(Rj).scale(152.63)};function Fj(t,e){var n=kT(t),i=t===e?MT(t):(n-kT(e))/(e-t),r=n/i+t;if(yT(i)<1e-6)return Rj;function o(t,e){var n=r-e,o=i*t;return[n*MT(o),r-n*kT(o)]}return o.invert=function(t,e){var n=r-e;return[wT(t,yT(n))/i*TT(n),r-TT(i)*ET(t*t+n*n)]},o}var Nj=function(){return bj(Fj).scale(131.154).center([0,13.9389])};function Bj(t,e){var n=kT(e),i=kT(t)*n;return[n*MT(t)/i,MT(e)/i]}Bj.invert=Sj(_T);var Hj=function(){return gj(Bj).scale(144.049).clipAngle(60)};function zj(t,e,n,i){return 1===t&&1===e&&0===n&&0===i?oA:rj({point:function(r,o){this.stream.point(r*t+n,o*e+i)}})}var Vj=function(){var t,e,n,i,r,o,a=1,s=0,c=0,l=1,u=1,h=oA,d=null,f=oA;function p(){return i=r=null,o}return o={stream:function(t){return i&&r===t?i:i=h(f(r=t))},postclip:function(i){return arguments.length?(f=i,d=t=e=n=null,p()):f},clipExtent:function(i){return arguments.length?(f=null==i?(d=t=e=n=null,oA):MP(d=+i[0][0],t=+i[0][1],e=+i[1][0],n=+i[1][1]),p()):null==d?null:[[d,t],[e,n]]},scale:function(t){return arguments.length?(h=zj((a=+t)*l,a*u,s,c),p()):a},translate:function(t){return arguments.length?(h=zj(a*l,a*u,s=+t[0],c=+t[1]),p()):[s,c]},reflectX:function(t){return arguments.length?(h=zj(a*(l=t?-1:1),a*u,s,c),p()):l<0},reflectY:function(t){return arguments.length?(h=zj(a*l,a*(u=t?-1:1),s,c),p()):u<0},fitExtent:function(t,e){return sj(o,t,e)},fitSize:function(t,e){return cj(o,t,e)},fitWidth:function(t,e){return lj(o,t,e)},fitHeight:function(t,e){return uj(o,t,e)}}};function Uj(t,e){var n=e*e,i=n*n;return[t*(.8707-.131979*n+i*(i*(.003971*n-.001529*i)-.013791)),e*(1.007226+n*(.015085+i*(.028874*n-.044475-.005916*i)))]}Uj.invert=function(t,e){var n,i=e,r=25;do{var o=i*i,a=o*o;i-=n=(i*(1.007226+o*(.015085+a*(.028874*o-.044475-.005916*a)))-e)/(1.007226+o*(.045255+a*(.259866*o-.311325-.005916*11*a)))}while(yT(n)>1e-6&&--r>0);return[t/(.8707+(o=i*i)*(o*(o*o*o*(.003971-.001529*o)-.013791)-.131979)),i]};var qj=function(){return gj(Uj).scale(175.295)};function Gj(t,e){return[kT(e)*MT(t),MT(e)]}Gj.invert=Sj(jT);var Wj=function(){return gj(Gj).scale(249.5).clipAngle(90.000001)};function Kj(t,e){var n=kT(e),i=1+kT(t)*n;return[n*MT(t)/i,MT(e)/i]}Kj.invert=Sj((function(t){return 2*_T(t)}));var Xj=function(){return gj(Kj).scale(250).clipAngle(142)};function Yj(t,e){return[xT(PT((pT+e)/2)),-t]}Yj.invert=function(t,e){return[-e,2*_T(ST(t))-pT]};var Zj=function(){var t=Aj(Yj),e=t.center,n=t.rotate;return t.center=function(t){return arguments.length?e([-t[1],t[0]]):[(t=e())[1],-t[0]]},t.rotate=function(t){return arguments.length?n([t[0],t[1],t.length>2?t[2]+90:90]):[(t=n())[0],t[1],t[2]-90]},n([0,0,90]).scale(159.155)};function Qj(t,e){return t.parent===e.parent?1:2}function $j(t,e){return t+e.x}function Jj(t,e){return Math.max(t,e.y)}var tI=function(){var t=Qj,e=1,n=1,i=!1;function r(r){var o,a=0;r.eachAfter((function(e){var n=e.children;n?(e.x=function(t){return t.reduce($j,0)/t.length}(n),e.y=function(t){return 1+t.reduce(Jj,0)}(n)):(e.x=o?a+=t(e,o):0,e.y=0,o=e)}));var s=function(t){for(var e;e=t.children;)t=e[0];return t}(r),c=function(t){for(var e;e=t.children;)t=e[e.length-1];return t}(r),l=s.x-t(s,c)/2,u=c.x+t(c,s)/2;return r.eachAfter(i?function(t){t.x=(t.x-r.x)*e,t.y=(r.y-t.y)*n}:function(t){t.x=(t.x-l)/(u-l)*e,t.y=(1-(r.y?t.y/r.y:1))*n})}return r.separation=function(e){return arguments.length?(t=e,r):t},r.size=function(t){return arguments.length?(i=!1,e=+t[0],n=+t[1],r):i?null:[e,n]},r.nodeSize=function(t){return arguments.length?(i=!0,e=+t[0],n=+t[1],r):i?[e,n]:null},r};function eI(t){var e=0,n=t.children,i=n&&n.length;if(i)for(;--i>=0;)e+=n[i].value;else e=1;t.value=e}function nI(t,e){var n,i,r,o,a,s=new aI(t),c=+t.value&&(s.value=t.value),l=[s];for(null==e&&(e=iI);n=l.pop();)if(c&&(n.value=+n.data.value),(r=e(n.data))&&(a=r.length))for(n.children=new Array(a),o=a-1;o>=0;--o)l.push(i=n.children[o]=new aI(r[o])),i.parent=n,i.depth=n.depth+1;return s.eachBefore(oI)}function iI(t){return t.children}function rI(t){t.data=t.data.data}function oI(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function aI(t){this.data=t,this.depth=this.height=0,this.parent=null}aI.prototype=nI.prototype={constructor:aI,count:function(){return this.eachAfter(eI)},each:function(t){var e,n,i,r,o=this,a=[o];do{for(e=a.reverse(),a=[];o=e.pop();)if(t(o),n=o.children)for(i=0,r=n.length;i<r;++i)a.push(n[i])}while(a.length);return this},eachAfter:function(t){for(var e,n,i,r=this,o=[r],a=[];r=o.pop();)if(a.push(r),e=r.children)for(n=0,i=e.length;n<i;++n)o.push(e[n]);for(;r=a.pop();)t(r);return this},eachBefore:function(t){for(var e,n,i=this,r=[i];i=r.pop();)if(t(i),e=i.children)for(n=e.length-1;n>=0;--n)r.push(e[n]);return this},sum:function(t){return this.eachAfter((function(e){for(var n=+t(e.data)||0,i=e.children,r=i&&i.length;--r>=0;)n+=i[r].value;e.value=n}))},sort:function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},path:function(t){for(var e=this,n=function(t,e){if(t===e)return t;var n=t.ancestors(),i=e.ancestors(),r=null;for(t=n.pop(),e=i.pop();t===e;)r=t,t=n.pop(),e=i.pop();return r}(e,t),i=[e];e!==n;)i.push(e=e.parent);for(var r=i.length;t!==n;)i.splice(r,0,t),t=t.parent;return i},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){var t=[];return this.each((function(e){t.push(e)})),t},leaves:function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},links:function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},copy:function(){return nI(this).eachBefore(rI)}};var sI=Array.prototype.slice,cI=function(t){for(var e,n,i=0,r=(t=function(t){for(var e,n,i=t.length;i;)n=Math.random()*i--|0,e=t[i],t[i]=t[n],t[n]=e;return t}(sI.call(t))).length,o=[];i<r;)e=t[i],n&&hI(n,e)?++i:(n=fI(o=lI(o,e)),i=0);return n};function lI(t,e){var n,i;if(dI(e,t))return[e];for(n=0;n<t.length;++n)if(uI(e,t[n])&&dI(pI(t[n],e),t))return[t[n],e];for(n=0;n<t.length-1;++n)for(i=n+1;i<t.length;++i)if(uI(pI(t[n],t[i]),e)&&uI(pI(t[n],e),t[i])&&uI(pI(t[i],e),t[n])&&dI(mI(t[n],t[i],e),t))return[t[n],t[i],e];throw new Error}function uI(t,e){var n=t.r-e.r,i=e.x-t.x,r=e.y-t.y;return n<0||n*n<i*i+r*r}function hI(t,e){var n=t.r-e.r+1e-6,i=e.x-t.x,r=e.y-t.y;return n>0&&n*n>i*i+r*r}function dI(t,e){for(var n=0;n<e.length;++n)if(!hI(t,e[n]))return!1;return!0}function fI(t){switch(t.length){case 1:return{x:(e=t[0]).x,y:e.y,r:e.r};case 2:return pI(t[0],t[1]);case 3:return mI(t[0],t[1],t[2])}var e}function pI(t,e){var n=t.x,i=t.y,r=t.r,o=e.x,a=e.y,s=e.r,c=o-n,l=a-i,u=s-r,h=Math.sqrt(c*c+l*l);return{x:(n+o+c/h*u)/2,y:(i+a+l/h*u)/2,r:(h+r+s)/2}}function mI(t,e,n){var i=t.x,r=t.y,o=t.r,a=e.x,s=e.y,c=e.r,l=n.x,u=n.y,h=n.r,d=i-a,f=i-l,p=r-s,m=r-u,g=c-o,v=h-o,b=i*i+r*r-o*o,y=b-a*a-s*s+c*c,_=b-l*l-u*u+h*h,w=f*p-d*m,k=(p*_-m*y)/(2*w)-i,C=(m*g-p*v)/w,S=(f*y-d*_)/(2*w)-r,x=(d*v-f*g)/w,O=C*C+x*x-1,M=2*(o+k*C+S*x),T=k*k+S*S-o*o,E=-(O?(M+Math.sqrt(M*M-4*O*T))/(2*O):T/M);return{x:i+k+C*E,y:r+S+x*E,r:E}}function gI(t,e,n){var i,r,o,a,s=t.x-e.x,c=t.y-e.y,l=s*s+c*c;l?(r=e.r+n.r,a=t.r+n.r,(r*=r)>(a*=a)?(i=(l+a-r)/(2*l),o=Math.sqrt(Math.max(0,a/l-i*i)),n.x=t.x-i*s-o*c,n.y=t.y-i*c+o*s):(i=(l+r-a)/(2*l),o=Math.sqrt(Math.max(0,r/l-i*i)),n.x=e.x+i*s-o*c,n.y=e.y+i*c+o*s)):(n.x=e.x+n.r,n.y=e.y)}function vI(t,e){var n=t.r+e.r-1e-6,i=e.x-t.x,r=e.y-t.y;return n>0&&n*n>i*i+r*r}function bI(t){var e=t._,n=t.next._,i=e.r+n.r,r=(e.x*n.r+n.x*e.r)/i,o=(e.y*n.r+n.y*e.r)/i;return r*r+o*o}function yI(t){this._=t,this.next=null,this.previous=null}function _I(t){if(!(r=t.length))return 0;var e,n,i,r,o,a,s,c,l,u,h;if((e=t[0]).x=0,e.y=0,!(r>1))return e.r;if(e.x=-(n=t[1]).r,n.x=e.r,n.y=0,!(r>2))return e.r+n.r;gI(n,e,i=t[2]),e=new yI(e),n=new yI(n),i=new yI(i),e.next=i.previous=n,n.next=e.previous=i,i.next=n.previous=e;t:for(s=3;s<r;++s){gI(e._,n._,i=t[s]),i=new yI(i),c=n.next,l=e.previous,u=n._.r,h=e._.r;do{if(u<=h){if(vI(c._,i._)){e.next=n=c,n.previous=e,--s;continue t}u+=c._.r,c=c.next}else{if(vI(l._,i._)){(e=l).next=n,n.previous=e,--s;continue t}h+=l._.r,l=l.previous}}while(c!==l.next);for(i.previous=e,i.next=n,e.next=n.previous=n=i,o=bI(e);(i=i.next)!==n;)(a=bI(i))<o&&(e=i,o=a);n=e.next}for(e=[n._],i=n;(i=i.next)!==n;)e.push(i._);for(i=cI(e),s=0;s<r;++s)(e=t[s]).x-=i.x,e.y-=i.y;return i.r}var wI=function(t){return _I(t),t};function kI(t){return null==t?null:CI(t)}function CI(t){if("function"!=typeof t)throw new Error;return t}function SI(){return 0}var xI=function(t){return function(){return t}};function OI(t){return Math.sqrt(t.value)}var MI=function(){var t=null,e=1,n=1,i=SI;function r(r){return r.x=e/2,r.y=n/2,t?r.eachBefore(TI(t)).eachAfter(EI(i,.5)).eachBefore(PI(1)):r.eachBefore(TI(OI)).eachAfter(EI(SI,1)).eachAfter(EI(i,r.r/Math.min(e,n))).eachBefore(PI(Math.min(e,n)/(2*r.r))),r}return r.radius=function(e){return arguments.length?(t=kI(e),r):t},r.size=function(t){return arguments.length?(e=+t[0],n=+t[1],r):[e,n]},r.padding=function(t){return arguments.length?(i="function"==typeof t?t:xI(+t),r):i},r};function TI(t){return function(e){e.children||(e.r=Math.max(0,+t(e)||0))}}function EI(t,e){return function(n){if(i=n.children){var i,r,o,a=i.length,s=t(n)*e||0;if(s)for(r=0;r<a;++r)i[r].r+=s;if(o=_I(i),s)for(r=0;r<a;++r)i[r].r-=s;n.r=o+s}}}function PI(t){return function(e){var n=e.parent;e.r*=t,n&&(e.x=n.x+t*e.x,e.y=n.y+t*e.y)}}var AI=function(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)},jI=function(t,e,n,i,r){for(var o,a=t.children,s=-1,c=a.length,l=t.value&&(i-e)/t.value;++s<c;)(o=a[s]).y0=n,o.y1=r,o.x0=e,o.x1=e+=o.value*l},II=function(){var t=1,e=1,n=0,i=!1;function r(r){var o=r.height+1;return r.x0=r.y0=n,r.x1=t,r.y1=e/o,r.eachBefore(function(t,e){return function(i){i.children&&jI(i,i.x0,t*(i.depth+1)/e,i.x1,t*(i.depth+2)/e);var r=i.x0,o=i.y0,a=i.x1-n,s=i.y1-n;a<r&&(r=a=(r+a)/2),s<o&&(o=s=(o+s)/2),i.x0=r,i.y0=o,i.x1=a,i.y1=s}}(e,o)),i&&r.eachBefore(AI),r}return r.round=function(t){return arguments.length?(i=!!t,r):i},r.size=function(n){return arguments.length?(t=+n[0],e=+n[1],r):[t,e]},r.padding=function(t){return arguments.length?(n=+t,r):n},r},DI={depth:-1},RI={};function LI(t){return t.id}function FI(t){return t.parentId}var NI=function(){var t=LI,e=FI;function n(n){var i,r,o,a,s,c,l,u=n.length,h=new Array(u),d={};for(r=0;r<u;++r)s=h[r]=new aI(i=n[r]),null!=(c=t(i,r,n))&&(c+="")&&(d[l="$"+(s.id=c)]=l in d?RI:s);for(r=0;r<u;++r)if(s=h[r],null!=(c=e(n[r],r,n))&&(c+="")){if(!(a=d["$"+c]))throw new Error("missing: "+c);if(a===RI)throw new Error("ambiguous: "+c);a.children?a.children.push(s):a.children=[s],s.parent=a}else{if(o)throw new Error("multiple roots");o=s}if(!o)throw new Error("no root");if(o.parent=DI,o.eachBefore((function(t){t.depth=t.parent.depth+1,--u})).eachBefore(oI),o.parent=null,u>0)throw new Error("cycle");return o}return n.id=function(e){return arguments.length?(t=CI(e),n):t},n.parentId=function(t){return arguments.length?(e=CI(t),n):e},n};function BI(t,e){return t.parent===e.parent?1:2}function HI(t){var e=t.children;return e?e[0]:t.t}function zI(t){var e=t.children;return e?e[e.length-1]:t.t}function VI(t,e,n){var i=n/(e.i-t.i);e.c-=i,e.s+=n,t.c+=i,e.z+=n,e.m+=n}function UI(t,e,n){return t.a.parent===e.parent?t.a:n}function qI(t,e){this._=t,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=e}qI.prototype=Object.create(aI.prototype);var GI=function(){var t=BI,e=1,n=1,i=null;function r(r){var c=function(t){for(var e,n,i,r,o,a=new qI(t,0),s=[a];e=s.pop();)if(i=e._.children)for(e.children=new Array(o=i.length),r=o-1;r>=0;--r)s.push(n=e.children[r]=new qI(i[r],r)),n.parent=e;return(a.parent=new qI(null,0)).children=[a],a}(r);if(c.eachAfter(o),c.parent.m=-c.z,c.eachBefore(a),i)r.eachBefore(s);else{var l=r,u=r,h=r;r.eachBefore((function(t){t.x<l.x&&(l=t),t.x>u.x&&(u=t),t.depth>h.depth&&(h=t)}));var d=l===u?1:t(l,u)/2,f=d-l.x,p=e/(u.x+d+f),m=n/(h.depth||1);r.eachBefore((function(t){t.x=(t.x+f)*p,t.y=t.depth*m}))}return r}function o(e){var n=e.children,i=e.parent.children,r=e.i?i[e.i-1]:null;if(n){!function(t){for(var e,n=0,i=0,r=t.children,o=r.length;--o>=0;)(e=r[o]).z+=n,e.m+=n,n+=e.s+(i+=e.c)}(e);var o=(n[0].z+n[n.length-1].z)/2;r?(e.z=r.z+t(e._,r._),e.m=e.z-o):e.z=o}else r&&(e.z=r.z+t(e._,r._));e.parent.A=function(e,n,i){if(n){for(var r,o=e,a=e,s=n,c=o.parent.children[0],l=o.m,u=a.m,h=s.m,d=c.m;s=zI(s),o=HI(o),s&&o;)c=HI(c),(a=zI(a)).a=e,(r=s.z+h-o.z-l+t(s._,o._))>0&&(VI(UI(s,e,i),e,r),l+=r,u+=r),h+=s.m,l+=o.m,d+=c.m,u+=a.m;s&&!zI(a)&&(a.t=s,a.m+=h-u),o&&!HI(c)&&(c.t=o,c.m+=l-d,i=e)}return i}(e,r,e.parent.A||i[0])}function a(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function s(t){t.x*=e,t.y=t.depth*n}return r.separation=function(e){return arguments.length?(t=e,r):t},r.size=function(t){return arguments.length?(i=!1,e=+t[0],n=+t[1],r):i?null:[e,n]},r.nodeSize=function(t){return arguments.length?(i=!0,e=+t[0],n=+t[1],r):i?[e,n]:null},r},WI=function(t,e,n,i,r){for(var o,a=t.children,s=-1,c=a.length,l=t.value&&(r-n)/t.value;++s<c;)(o=a[s]).x0=e,o.x1=i,o.y0=n,o.y1=n+=o.value*l},KI=(1+Math.sqrt(5))/2;function XI(t,e,n,i,r,o){for(var a,s,c,l,u,h,d,f,p,m,g,v=[],b=e.children,y=0,_=0,w=b.length,k=e.value;y<w;){c=r-n,l=o-i;do{u=b[_++].value}while(!u&&_<w);for(h=d=u,g=u*u*(m=Math.max(l/c,c/l)/(k*t)),p=Math.max(d/g,g/h);_<w;++_){if(u+=s=b[_].value,s<h&&(h=s),s>d&&(d=s),g=u*u*m,(f=Math.max(d/g,g/h))>p){u-=s;break}p=f}v.push(a={value:u,dice:c<l,children:b.slice(y,_)}),a.dice?jI(a,n,i,r,k?i+=l*u/k:o):WI(a,n,i,k?n+=c*u/k:r,o),k-=u,y=_}return v}var YI=function t(e){function n(t,n,i,r,o){XI(e,t,n,i,r,o)}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(KI),ZI=function(){var t=YI,e=!1,n=1,i=1,r=[0],o=SI,a=SI,s=SI,c=SI,l=SI;function u(t){return t.x0=t.y0=0,t.x1=n,t.y1=i,t.eachBefore(h),r=[0],e&&t.eachBefore(AI),t}function h(e){var n=r[e.depth],i=e.x0+n,u=e.y0+n,h=e.x1-n,d=e.y1-n;h<i&&(i=h=(i+h)/2),d<u&&(u=d=(u+d)/2),e.x0=i,e.y0=u,e.x1=h,e.y1=d,e.children&&(n=r[e.depth+1]=o(e)/2,i+=l(e)-n,u+=a(e)-n,(h-=s(e)-n)<i&&(i=h=(i+h)/2),(d-=c(e)-n)<u&&(u=d=(u+d)/2),t(e,i,u,h,d))}return u.round=function(t){return arguments.length?(e=!!t,u):e},u.size=function(t){return arguments.length?(n=+t[0],i=+t[1],u):[n,i]},u.tile=function(e){return arguments.length?(t=CI(e),u):t},u.padding=function(t){return arguments.length?u.paddingInner(t).paddingOuter(t):u.paddingInner()},u.paddingInner=function(t){return arguments.length?(o="function"==typeof t?t:xI(+t),u):o},u.paddingOuter=function(t){return arguments.length?u.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t):u.paddingTop()},u.paddingTop=function(t){return arguments.length?(a="function"==typeof t?t:xI(+t),u):a},u.paddingRight=function(t){return arguments.length?(s="function"==typeof t?t:xI(+t),u):s},u.paddingBottom=function(t){return arguments.length?(c="function"==typeof t?t:xI(+t),u):c},u.paddingLeft=function(t){return arguments.length?(l="function"==typeof t?t:xI(+t),u):l},u},QI=function(t,e,n,i,r){var o,a,s=t.children,c=s.length,l=new Array(c+1);for(l[0]=a=o=0;o<c;++o)l[o+1]=a+=s[o].value;!function t(e,n,i,r,o,a,c){if(e>=n-1){var u=s[e];return u.x0=r,u.y0=o,u.x1=a,void(u.y1=c)}for(var h=l[e],d=i/2+h,f=e+1,p=n-1;f<p;){var m=f+p>>>1;l[m]<d?f=m+1:p=m}d-l[f-1]<l[f]-d&&e+1<f&&--f;var g=l[f]-h,v=i-g;if(a-r>c-o){var b=(r*v+a*g)/i;t(e,f,g,r,o,b,c),t(f,n,v,b,o,a,c)}else{var y=(o*v+c*g)/i;t(e,f,g,r,o,a,y),t(f,n,v,r,y,a,c)}}(0,c,t.value,e,n,i,r)},$I=function(t,e,n,i,r){(1&t.depth?WI:jI)(t,e,n,i,r)},JI=function t(e){function n(t,n,i,r,o){if((a=t._squarify)&&a.ratio===e)for(var a,s,c,l,u,h=-1,d=a.length,f=t.value;++h<d;){for(c=(s=a[h]).children,l=s.value=0,u=c.length;l<u;++l)s.value+=c[l].value;s.dice?jI(s,n,i,r,i+=(o-i)*s.value/f):WI(s,n,i,n+=(r-n)*s.value/f,o),f-=s.value}else t._squarify=a=XI(e,t,n,i,r,o),a.ratio=e}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(KI);function tD(t,e,n,i,r){var o=t*t,a=o*t;return((1-3*t+3*o-a)*e+(4-6*o+3*a)*n+(1+3*t+3*o-3*a)*i+a*r)/6}var eD=function(t){var e=t.length-1;return function(n){var i=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),r=t[i],o=t[i+1];return tD((n-i/e)*e,i>0?t[i-1]:2*r-o,r,o,i<e-1?t[i+2]:2*o-r)}},nD=function(t){var e=t.length;return function(n){var i=Math.floor(((n%=1)<0?++n:n)*e);return tD((n-i/e)*e,t[(i+e-1)%e],t[i%e],t[(i+1)%e],t[(i+2)%e])}},iD=function(t){return function(){return t}};function rD(t,e){return function(n){return t+n*e}}function oD(t,e){var n=e-t;return n?rD(t,n>180||n<-180?n-360*Math.round(n/360):n):iD(isNaN(t)?e:t)}function aD(t,e){var n=e-t;return n?rD(t,n):iD(isNaN(t)?e:t)}var sD=function t(e){var n=function(t){return 1==(t=+t)?aD:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(i){return Math.pow(t+i*e,n)}}(e,n,t):iD(isNaN(e)?n:e)}}(e);function i(t,e){var i=n((t=vk(t)).r,(e=vk(e)).r),r=n(t.g,e.g),o=n(t.b,e.b),a=aD(t.opacity,e.opacity);return function(e){return t.r=i(e),t.g=r(e),t.b=o(e),t.opacity=a(e),t+""}}return i.gamma=t,i}(1);function cD(t){return function(e){var n,i,r=e.length,o=new Array(r),a=new Array(r),s=new Array(r);for(n=0;n<r;++n)i=vk(e[n]),o[n]=i.r||0,a[n]=i.g||0,s[n]=i.b||0;return o=t(o),a=t(a),s=t(s),i.opacity=1,function(t){return i.r=o(t),i.g=a(t),i.b=s(t),i+""}}}var lD,uD,hD,dD,fD=cD(eD),pD=cD(nD),mD=function(t,e){var n,i=e?e.length:0,r=t?Math.min(i,t.length):0,o=new Array(r),a=new Array(i);for(n=0;n<r;++n)o[n]=kD(t[n],e[n]);for(;n<i;++n)a[n]=e[n];return function(t){for(n=0;n<r;++n)a[n]=o[n](t);return a}},gD=function(t,e){var n=new Date;return e-=t=+t,function(i){return n.setTime(t+e*i),n}},vD=function(t,e){return e-=t=+t,function(n){return t+e*n}},bD=function(t,e){var n,i={},r={};for(n in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)n in t?i[n]=kD(t[n],e[n]):r[n]=e[n];return function(t){for(n in i)r[n]=i[n](t);return r}},yD=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,_D=new RegExp(yD.source,"g"),wD=function(t,e){var n,i,r,o=yD.lastIndex=_D.lastIndex=0,a=-1,s=[],c=[];for(t+="",e+="";(n=yD.exec(t))&&(i=_D.exec(e));)(r=i.index)>o&&(r=e.slice(o,r),s[a]?s[a]+=r:s[++a]=r),(n=n[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,c.push({i:a,x:vD(n,i)})),o=_D.lastIndex;return o<e.length&&(r=e.slice(o),s[a]?s[a]+=r:s[++a]=r),s.length<2?c[0]?function(t){return function(e){return t(e)+""}}(c[0].x):function(t){return function(){return t}}(e):(e=c.length,function(t){for(var n,i=0;i<e;++i)s[(n=c[i]).i]=n.x(t);return s.join("")})},kD=function(t,e){var n,i=typeof e;return null==e||"boolean"===i?iD(e):("number"===i?vD:"string"===i?(n=fk(e))?(e=n,sD):wD:e instanceof fk?sD:e instanceof Date?gD:Array.isArray(e)?mD:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?bD:vD)(t,e)},CD=function(t,e){return e-=t=+t,function(n){return Math.round(t+e*n)}},SD=180/Math.PI,xD={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1},OD=function(t,e,n,i,r,o){var a,s,c;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(c=t*n+e*i)&&(n-=t*c,i-=e*c),(s=Math.sqrt(n*n+i*i))&&(n/=s,i/=s,c/=s),t*i<e*n&&(t=-t,e=-e,c=-c,a=-a),{translateX:r,translateY:o,rotate:Math.atan2(e,t)*SD,skewX:Math.atan(c)*SD,scaleX:a,scaleY:s}};function MD(t,e,n,i){function r(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],c=[];return o=t(o),a=t(a),function(t,i,r,o,a,s){if(t!==r||i!==o){var c=a.push("translate(",null,e,null,n);s.push({i:c-4,x:vD(t,r)},{i:c-2,x:vD(i,o)})}else(r||o)&&a.push("translate("+r+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,c),function(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(r(n)+"rotate(",null,i)-2,x:vD(t,e)})):e&&n.push(r(n)+"rotate("+e+i)}(o.rotate,a.rotate,s,c),function(t,e,n,o){t!==e?o.push({i:n.push(r(n)+"skewX(",null,i)-2,x:vD(t,e)}):e&&n.push(r(n)+"skewX("+e+i)}(o.skewX,a.skewX,s,c),function(t,e,n,i,o,a){if(t!==n||e!==i){var s=o.push(r(o)+"scale(",null,",",null,")");a.push({i:s-4,x:vD(t,n)},{i:s-2,x:vD(e,i)})}else 1===n&&1===i||o.push(r(o)+"scale("+n+","+i+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,c),o=a=null,function(t){for(var e,n=-1,i=c.length;++n<i;)s[(e=c[n]).i]=e.x(t);return s.join("")}}}var TD=MD((function(t){return"none"===t?xD:(lD||(lD=document.createElement("DIV"),uD=document.documentElement,hD=document.defaultView),lD.style.transform=t,t=hD.getComputedStyle(uD.appendChild(lD),null).getPropertyValue("transform"),uD.removeChild(lD),t=t.slice(7,-1).split(","),OD(+t[0],+t[1],+t[2],+t[3],+t[4],+t[5]))}),"px, ","px)","deg)"),ED=MD((function(t){return null==t?xD:(dD||(dD=document.createElementNS("http://www.w3.org/2000/svg","g")),dD.setAttribute("transform",t),(t=dD.transform.baseVal.consolidate())?OD((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):xD)}),", ",")",")"),PD=Math.SQRT2;function AD(t){return((t=Math.exp(t))+1/t)/2}var jD=function(t,e){var n,i,r=t[0],o=t[1],a=t[2],s=e[2],c=e[0]-r,l=e[1]-o,u=c*c+l*l;if(u<1e-12)i=Math.log(s/a)/PD,n=function(t){return[r+t*c,o+t*l,a*Math.exp(PD*t*i)]};else{var h=Math.sqrt(u),d=(s*s-a*a+4*u)/(2*a*2*h),f=(s*s-a*a-4*u)/(2*s*2*h),p=Math.log(Math.sqrt(d*d+1)-d),m=Math.log(Math.sqrt(f*f+1)-f);i=(m-p)/PD,n=function(t){var e,n=t*i,s=AD(p),u=a/(2*h)*(s*(e=PD*n+p,((e=Math.exp(2*e))-1)/(e+1))-function(t){return((t=Math.exp(t))-1/t)/2}(p));return[r+u*c,o+u*l,a*s/AD(PD*n+p)]}}return n.duration=1e3*i,n};function ID(t){return function(e,n){var i=t((e=Sk(e)).h,(n=Sk(n)).h),r=aD(e.s,n.s),o=aD(e.l,n.l),a=aD(e.opacity,n.opacity);return function(t){return e.h=i(t),e.s=r(t),e.l=o(t),e.opacity=a(t),e+""}}}var DD=ID(oD),RD=ID(aD),LD=Math.PI/180,FD=180/Math.PI;function ND(t){if(t instanceof HD)return new HD(t.l,t.a,t.b,t.opacity);if(t instanceof KD)return XD(t);t instanceof bk||(t=gk(t));var e,n,i=qD(t.r),r=qD(t.g),o=qD(t.b),a=zD((.2225045*i+.7168786*r+.0606169*o)/1);return i===r&&r===o?e=n=a:(e=zD((.4360747*i+.3850649*r+.1430804*o)/.96422),n=zD((.0139322*i+.0971045*r+.7141733*o)/.82521)),new HD(116*a-16,500*(e-a),200*(a-n),t.opacity)}function BD(t,e,n,i){return 1===arguments.length?ND(t):new HD(t,e,n,null==i?1:i)}function HD(t,e,n,i){this.l=+t,this.a=+e,this.b=+n,this.opacity=+i}function zD(t){return t>6/29*(6/29)*(6/29)?Math.pow(t,1/3):t/(6/29*3*(6/29))+4/29}function VD(t){return t>6/29?t*t*t:6/29*3*(6/29)*(t-4/29)}function UD(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function qD(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function GD(t){if(t instanceof KD)return new KD(t.h,t.c,t.l,t.opacity);if(t instanceof HD||(t=ND(t)),0===t.a&&0===t.b)return new KD(NaN,0<t.l&&t.l<100?0:NaN,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*FD;return new KD(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function WD(t,e,n,i){return 1===arguments.length?GD(t):new KD(t,e,n,null==i?1:i)}function KD(t,e,n,i){this.h=+t,this.c=+e,this.l=+n,this.opacity=+i}function XD(t){if(isNaN(t.h))return new HD(t.l,0,0,t.opacity);var e=t.h*LD;return new HD(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}function YD(t,e){var n=aD((t=BD(t)).l,(e=BD(e)).l),i=aD(t.a,e.a),r=aD(t.b,e.b),o=aD(t.opacity,e.opacity);return function(e){return t.l=n(e),t.a=i(e),t.b=r(e),t.opacity=o(e),t+""}}function ZD(t){return function(e,n){var i=t((e=WD(e)).h,(n=WD(n)).h),r=aD(e.c,n.c),o=aD(e.l,n.l),a=aD(e.opacity,n.opacity);return function(t){return e.h=i(t),e.c=r(t),e.l=o(t),e.opacity=a(t),e+""}}}Qw(HD,BD,$w(Jw,{brighter:function(t){return new HD(this.l+18*(null==t?1:t),this.a,this.b,this.opacity)},darker:function(t){return new HD(this.l-18*(null==t?1:t),this.a,this.b,this.opacity)},rgb:function(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,n=isNaN(this.b)?t:t-this.b/200;return new bk(UD(3.1338561*(e=.96422*VD(e))-1.6168667*(t=1*VD(t))-.4906146*(n=.82521*VD(n))),UD(-.9787684*e+1.9161415*t+.033454*n),UD(.0719453*e-.2289914*t+1.4052427*n),this.opacity)}})),Qw(KD,WD,$w(Jw,{brighter:function(t){return new KD(this.h,this.c,this.l+18*(null==t?1:t),this.opacity)},darker:function(t){return new KD(this.h,this.c,this.l-18*(null==t?1:t),this.opacity)},rgb:function(){return XD(this).rgb()}}));var QD=ZD(oD),$D=ZD(aD);function JD(t){if(t instanceof eR)return new eR(t.h,t.s,t.l,t.opacity);t instanceof bk||(t=gk(t));var e=t.g/255,n=t.b/255,i=(-.6557636667999999*n+t.r/255*-1.7884503806-3.5172982438*e)/-5.9615122912,r=n-i,o=(1.97294*(e-i)- -.29227*r)/-.90649,a=Math.sqrt(o*o+r*r)/(1.97294*i*(1-i)),s=a?Math.atan2(o,r)*FD-120:NaN;return new eR(s<0?s+360:s,a,i,t.opacity)}function tR(t,e,n,i){return 1===arguments.length?JD(t):new eR(t,e,n,null==i?1:i)}function eR(t,e,n,i){this.h=+t,this.s=+e,this.l=+n,this.opacity=+i}function nR(t){return function e(n){function i(e,i){var r=t((e=tR(e)).h,(i=tR(i)).h),o=aD(e.s,i.s),a=aD(e.l,i.l),s=aD(e.opacity,i.opacity);return function(t){return e.h=r(t),e.s=o(t),e.l=a(Math.pow(t,n)),e.opacity=s(t),e+""}}return n=+n,i.gamma=e,i}(1)}Qw(eR,tR,$w(Jw,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new eR(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new eR(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=isNaN(this.h)?0:(this.h+120)*LD,e=+this.l,n=isNaN(this.s)?0:this.s*e*(1-e),i=Math.cos(t),r=Math.sin(t);return new bk(255*(e+n*(-.14861*i+1.78277*r)),255*(e+n*(-.29227*i+-.90649*r)),255*(e+n*(1.97294*i)),this.opacity)}}));var iR=nR(oD),rR=nR(aD),oR=function(t,e){for(var n=new Array(e),i=0;i<e;++i)n[i]=t(i/(e-1));return n},aR=function(t){for(var e,n=-1,i=t.length,r=t[i-1],o=0;++n<i;)o+=(e=r)[1]*(r=t[n])[0]-e[0]*r[1];return o/2},sR=function(t){for(var e,n,i=-1,r=t.length,o=0,a=0,s=t[r-1],c=0;++i<r;)c+=n=(e=s)[0]*(s=t[i])[1]-s[0]*e[1],o+=(e[0]+s[0])*n,a+=(e[1]+s[1])*n;return[o/(c*=3),a/c]};function cR(t,e){return t[0]-e[0]||t[1]-e[1]}function lR(t){for(var e,n,i,r=t.length,o=[0,1],a=2,s=2;s<r;++s){for(;a>1&&((n=t[o[a-1]])[0]-(e=t[o[a-2]])[0])*((i=t[s])[1]-e[1])-(n[1]-e[1])*(i[0]-e[0])<=0;)--a;o[a++]=s}return o.slice(0,a)}var uR=function(t){if((n=t.length)<3)return null;var e,n,i=new Array(n),r=new Array(n);for(e=0;e<n;++e)i[e]=[+t[e][0],+t[e][1],e];for(i.sort(cR),e=0;e<n;++e)r[e]=[i[e][0],-i[e][1]];var o=lR(i),a=lR(r),s=a[0]===o[0],c=a[a.length-1]===o[o.length-1],l=[];for(e=o.length-1;e>=0;--e)l.push(t[i[o[e]][2]]);for(e=+s;e<a.length-c;++e)l.push(t[i[a[e]][2]]);return l},hR=function(t,e){for(var n,i,r=t.length,o=t[r-1],a=e[0],s=e[1],c=o[0],l=o[1],u=!1,h=0;h<r;++h)n=(o=t[h])[0],(i=o[1])>s!=l>s&&a<(c-n)*(s-i)/(l-i)+n&&(u=!u),c=n,l=i;return u},dR=function(t){for(var e,n,i=-1,r=t.length,o=t[r-1],a=o[0],s=o[1],c=0;++i<r;)e=a,n=s,e-=a=(o=t[i])[0],n-=s=o[1],c+=Math.sqrt(e*e+n*n);return c},fR=function(){return Math.random()},pR=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,1===arguments.length?(n=t,t=0):n-=t,function(){return e()*n+t}}return n.source=t,n}(fR),mR=function t(e){function n(t,n){var i,r;return t=null==t?0:+t,n=null==n?1:+n,function(){var o;if(null!=i)o=i,i=null;else do{i=2*e()-1,o=2*e()-1,r=i*i+o*o}while(!r||r>1);return t+n*o*Math.sqrt(-2*Math.log(r)/r)}}return n.source=t,n}(fR),gR=function t(e){function n(){var t=mR.source(e).apply(this,arguments);return function(){return Math.exp(t())}}return n.source=t,n}(fR),vR=function t(e){function n(t){return function(){for(var n=0,i=0;i<t;++i)n+=e();return n}}return n.source=t,n}(fR),bR=function t(e){function n(t){var n=vR.source(e)(t);return function(){return n()/t}}return n.source=t,n}(fR),yR=function t(e){function n(t){return function(){return-Math.log(1-e())/t}}return n.source=t,n}(fR),_R=Array.prototype,wR=_R.map,kR=_R.slice,CR={name:"implicit"};function SR(t){var e=ax(),n=[],i=CR;function r(r){var o=r+"",a=e.get(o);if(!a){if(i!==CR)return i;e.set(o,a=n.push(r))}return t[(a-1)%t.length]}return t=null==t?[]:kR.call(t),r.domain=function(t){if(!arguments.length)return n.slice();n=[],e=ax();for(var i,o,a=-1,s=t.length;++a<s;)e.has(o=(i=t[a])+"")||e.set(o,n.push(i));return r},r.range=function(e){return arguments.length?(t=kR.call(e),r):t.slice()},r.unknown=function(t){return arguments.length?(i=t,r):i},r.copy=function(){return SR().domain(n).range(t).unknown(i)},r}function xR(){var t,e,n=SR().unknown(void 0),i=n.domain,r=n.range,o=[0,1],a=!1,s=0,c=0,l=.5;function u(){var n=i().length,u=o[1]<o[0],h=o[u-0],d=o[1-u];t=(d-h)/Math.max(1,n-s+2*c),a&&(t=Math.floor(t)),h+=(d-h-t*(n-s))*l,e=t*(1-s),a&&(h=Math.round(h),e=Math.round(e));var f=Wy(n).map((function(e){return h+t*e}));return r(u?f.reverse():f)}return delete n.unknown,n.domain=function(t){return arguments.length?(i(t),u()):i()},n.range=function(t){return arguments.length?(o=[+t[0],+t[1]],u()):o.slice()},n.rangeRound=function(t){return o=[+t[0],+t[1]],a=!0,u()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(a=!!t,u()):a},n.padding=function(t){return arguments.length?(s=c=Math.max(0,Math.min(1,t)),u()):s},n.paddingInner=function(t){return arguments.length?(s=Math.max(0,Math.min(1,t)),u()):s},n.paddingOuter=function(t){return arguments.length?(c=Math.max(0,Math.min(1,t)),u()):c},n.align=function(t){return arguments.length?(l=Math.max(0,Math.min(1,t)),u()):l},n.copy=function(){return xR().domain(i()).range(o).round(a).paddingInner(s).paddingOuter(c).align(l)},u()}function OR(){return function t(e){var n=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return t(n())},e}(xR().paddingInner(1))}var MR=function(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}},TR=function(t){return function(){return t}},ER=function(t){return+t},PR=[0,1];function AR(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:TR(e)}function jR(t,e,n,i){var r=t[0],o=t[1],a=e[0],s=e[1];return o<r?(r=n(o,r),a=i(s,a)):(r=n(r,o),a=i(a,s)),function(t){return a(r(t))}}function IR(t,e,n,i){var r=Math.min(t.length,e.length)-1,o=new Array(r),a=new Array(r),s=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++s<r;)o[s]=n(t[s],t[s+1]),a[s]=i(e[s],e[s+1]);return function(e){var n=jy(t,e,1,r)-1;return a[n](o[n](e))}}function DR(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp())}function RR(t,e){var n,i,r,o=PR,a=PR,s=qk,c=!1;function l(){return n=Math.min(o.length,a.length)>2?IR:jR,i=r=null,u}function u(e){return(i||(i=n(o,a,c?function(t){return function(e,n){var i=t(e=+e,n=+n);return function(t){return t<=e?0:t>=n?1:i(t)}}}(t):t,s)))(+e)}return u.invert=function(t){return(r||(r=n(a,o,AR,c?function(t){return function(e,n){var i=t(e=+e,n=+n);return function(t){return t<=0?e:t>=1?n:i(t)}}}(e):e)))(+t)},u.domain=function(t){return arguments.length?(o=wR.call(t,ER),l()):o.slice()},u.range=function(t){return arguments.length?(a=kR.call(t),l()):a.slice()},u.rangeRound=function(t){return a=kR.call(t),s=MR,l()},u.clamp=function(t){return arguments.length?(c=!!t,l()):c},u.interpolate=function(t){return arguments.length?(s=t,l()):s},l()}var LR=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function FR(t){if(!(e=LR.exec(t)))throw new Error("invalid format: "+t);var e;return new NR({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function NR(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}FR.prototype=NR.prototype,NR.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var BR,HR,zR,VR,UR=function(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,i=t.slice(0,n);return[i.length>1?i[0]+i.slice(2):i,+t.slice(n+1)]},qR=function(t){return(t=UR(Math.abs(t)))?t[1]:NaN},GR=function(t,e){var n=UR(t,e);if(!n)return t+"";var i=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+i:i.length>r+1?i.slice(0,r+1)+"."+i.slice(r+1):i+new Array(r-i.length+2).join("0")},WR={"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return GR(100*t,e)},r:GR,s:function(t,e){var n=UR(t,e);if(!n)return t+"";var i=n[0],r=n[1],o=r-(BR=3*Math.max(-8,Math.min(8,Math.floor(r/3))))+1,a=i.length;return o===a?i:o>a?i+new Array(o-a+1).join("0"):o>0?i.slice(0,o)+"."+i.slice(o):"0."+new Array(1-o).join("0")+UR(t,Math.max(0,e+o-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}},KR=function(t){return t},XR=Array.prototype.map,YR=["y","z","a","f","p","n","\xb5","m","","k","M","G","T","P","E","Z","Y"];function ZR(t){var e=t.domain;return t.ticks=function(t){var n=e();return Zy(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){return function(t,e,n){var i,r=t[0],o=t[t.length-1],a=$y(r,o,null==e?10:e);switch((n=FR(null==n?",f":n)).type){case"s":var s=Math.max(Math.abs(r),Math.abs(o));return null!=n.precision||isNaN(i=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(qR(e)/3)))-qR(Math.abs(t)))}(a,s))||(n.precision=i),VR(n,s);case"":case"e":case"g":case"p":case"r":null!=n.precision||isNaN(i=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,qR(e)-qR(t))+1}(a,Math.max(Math.abs(r),Math.abs(o))))||(n.precision=i-("e"===n.type));break;case"f":case"%":null!=n.precision||isNaN(i=function(t){return Math.max(0,-qR(Math.abs(t)))}(a))||(n.precision=i-2*("%"===n.type))}return zR(n)}(e(),t,n)},t.nice=function(n){null==n&&(n=10);var i,r=e(),o=0,a=r.length-1,s=r[o],c=r[a];return c<s&&(i=s,s=c,c=i,i=o,o=a,a=i),(i=Qy(s,c,n))>0?i=Qy(s=Math.floor(s/i)*i,c=Math.ceil(c/i)*i,n):i<0&&(i=Qy(s=Math.ceil(s*i)/i,c=Math.floor(c*i)/i,n)),i>0?(r[o]=Math.floor(s/i)*i,r[a]=Math.ceil(c/i)*i,e(r)):i<0&&(r[o]=Math.ceil(s*i)/i,r[a]=Math.floor(c*i)/i,e(r)),t},t}function QR(){var t=RR(AR,Bk);return t.copy=function(){return DR(t,QR())},ZR(t)}function $R(){var t=[0,1];function e(t){return+t}return e.invert=e,e.domain=e.range=function(n){return arguments.length?(t=wR.call(n,ER),e):t.slice()},e.copy=function(){return $R().domain(t)},ZR(e)}HR=function(t){var e,n,i=void 0===t.grouping||void 0===t.thousands?KR:(e=XR.call(t.grouping,Number),n=t.thousands+"",function(t,i){for(var r=t.length,o=[],a=0,s=e[0],c=0;r>0&&s>0&&(c+s+1>i&&(s=Math.max(1,i-c)),o.push(t.substring(r-=s,r+s)),!((c+=s+1)>i));)s=e[a=(a+1)%e.length];return o.reverse().join(n)}),r=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?KR:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(XR.call(t.numerals,String)),c=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"-":t.minus+"",u=void 0===t.nan?"NaN":t.nan+"";function h(t){var e=(t=FR(t)).fill,n=t.align,h=t.sign,d=t.symbol,f=t.zero,p=t.width,m=t.comma,g=t.precision,v=t.trim,b=t.type;"n"===b?(m=!0,b="g"):WR[b]||(void 0===g&&(g=12),v=!0,b="g"),(f||"0"===e&&"="===n)&&(f=!0,e="0",n="=");var y="$"===d?r:"#"===d&&/[boxX]/.test(b)?"0"+b.toLowerCase():"",_="$"===d?o:/[%p]/.test(b)?c:"",w=WR[b],k=/[defgprs%]/.test(b);function C(t){var r,o,c,d=y,C=_;if("c"===b)C=w(t)+C,t="";else{var S=(t=+t)<0||1/t<0;if(t=isNaN(t)?u:w(Math.abs(t),g),v&&(t=function(t){t:for(var e,n=t.length,i=1,r=-1;i<n;++i)switch(t[i]){case".":r=e=i;break;case"0":0===r&&(r=i),e=i;break;default:if(!+t[i])break t;r>0&&(r=0)}return r>0?t.slice(0,r)+t.slice(e+1):t}(t)),S&&0==+t&&"+"!==h&&(S=!1),d=(S?"("===h?h:l:"-"===h||"("===h?"":h)+d,C=("s"===b?YR[8+BR/3]:"")+C+(S&&"("===h?")":""),k)for(r=-1,o=t.length;++r<o;)if(48>(c=t.charCodeAt(r))||c>57){C=(46===c?a+t.slice(r+1):t.slice(r))+C,t=t.slice(0,r);break}}m&&!f&&(t=i(t,1/0));var x=d.length+t.length+C.length,O=x<p?new Array(p-x+1).join(e):"";switch(m&&f&&(t=i(O+t,O.length?p-C.length:1/0),O=""),n){case"<":t=d+t+C+O;break;case"=":t=d+O+t+C;break;case"^":t=O.slice(0,x=O.length>>1)+d+t+C+O.slice(x);break;default:t=O+d+t+C}return s(t)}return g=void 0===g?6:/[gprs]/.test(b)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),C.toString=function(){return t+""},C}return{format:h,formatPrefix:function(t,e){var n=h(((t=FR(t)).type="f",t)),i=3*Math.max(-8,Math.min(8,Math.floor(qR(e)/3))),r=Math.pow(10,-i),o=YR[8+i/3];return function(t){return n(r*t)+o}}}}({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),zR=HR.format,VR=HR.formatPrefix;var JR=function(t,e){var n,i=0,r=(t=t.slice()).length-1,o=t[i],a=t[r];return a<o&&(n=i,i=r,r=n,n=o,o=a,a=n),t[i]=e.floor(o),t[r]=e.ceil(a),t};function tL(t,e){return(e=Math.log(e/t))?function(n){return Math.log(n/t)/e}:TR(e)}function eL(t,e){return t<0?function(n){return-Math.pow(-e,n)*Math.pow(-t,1-n)}:function(n){return Math.pow(e,n)*Math.pow(t,1-n)}}function nL(t){return isFinite(t)?+("1e"+t):t<0?0:t}function iL(t){return 10===t?nL:t===Math.E?Math.exp:function(e){return Math.pow(t,e)}}function rL(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),function(e){return Math.log(e)/t})}function oL(t){return function(e){return-t(-e)}}function aL(){var t=RR(tL,eL).domain([1,10]),e=t.domain,n=10,i=rL(10),r=iL(10);function o(){return i=rL(n),r=iL(n),e()[0]<0&&(i=oL(i),r=oL(r)),t}return t.base=function(t){return arguments.length?(n=+t,o()):n},t.domain=function(t){return arguments.length?(e(t),o()):e()},t.ticks=function(t){var o,a=e(),s=a[0],c=a[a.length-1];(o=c<s)&&(d=s,s=c,c=d);var l,u,h,d=i(s),f=i(c),p=null==t?10:+t,m=[];if(!(n%1)&&f-d<p){if(d=Math.round(d)-1,f=Math.round(f)+1,s>0){for(;d<f;++d)for(u=1,l=r(d);u<n;++u)if(!((h=l*u)<s)){if(h>c)break;m.push(h)}}else for(;d<f;++d)for(u=n-1,l=r(d);u>=1;--u)if(!((h=l*u)<s)){if(h>c)break;m.push(h)}}else m=Zy(d,f,Math.min(f-d,p)).map(r);return o?m.reverse():m},t.tickFormat=function(e,o){if(null==o&&(o=10===n?".0e":","),"function"!=typeof o&&(o=zR(o)),e===1/0)return o;null==e&&(e=10);var a=Math.max(1,n*e/t.ticks().length);return function(t){var e=t/r(Math.round(i(t)));return e*n<n-.5&&(e*=n),e<=a?o(t):""}},t.nice=function(){return e(JR(e(),{floor:function(t){return r(Math.floor(i(t)))},ceil:function(t){return r(Math.ceil(i(t)))}}))},t.copy=function(){return DR(t,aL().base(n))},t}function sL(t,e){return t<0?-Math.pow(-t,e):Math.pow(t,e)}function cL(){var t=1,e=RR((function(e,n){return(n=sL(n,t)-(e=sL(e,t)))?function(i){return(sL(i,t)-e)/n}:TR(n)}),(function(e,n){return n=sL(n,t)-(e=sL(e,t)),function(i){return sL(e+n*i,1/t)}})),n=e.domain;return e.exponent=function(e){return arguments.length?(t=+e,n(n())):t},e.copy=function(){return DR(e,cL().exponent(t))},ZR(e)}function lL(){return cL().exponent(.5)}function uL(){var t=[],e=[],n=[];function i(){var i=0,o=Math.max(1,e.length);for(n=new Array(o-1);++i<o;)n[i-1]=e_(t,i/o);return r}function r(t){if(!isNaN(t=+t))return e[jy(n,t)]}return r.invertExtent=function(i){var r=e.indexOf(i);return r<0?[NaN,NaN]:[r>0?n[r-1]:t[0],r<n.length?n[r]:t[t.length-1]]},r.domain=function(e){if(!arguments.length)return t.slice();t=[];for(var n,r=0,o=e.length;r<o;++r)null==(n=e[r])||isNaN(n=+n)||t.push(n);return t.sort(My),i()},r.range=function(t){return arguments.length?(e=kR.call(t),i()):e.slice()},r.quantiles=function(){return n.slice()},r.copy=function(){return uL().domain(t).range(e)},r}function hL(){var t=0,e=1,n=1,i=[.5],r=[0,1];function o(t){if(t<=t)return r[jy(i,t,0,n)]}function a(){var r=-1;for(i=new Array(n);++r<n;)i[r]=((r+1)*e-(r-n)*t)/(n+1);return o}return o.domain=function(n){return arguments.length?(t=+n[0],e=+n[1],a()):[t,e]},o.range=function(t){return arguments.length?(n=(r=kR.call(t)).length-1,a()):r.slice()},o.invertExtent=function(o){var a=r.indexOf(o);return a<0?[NaN,NaN]:a<1?[t,i[0]]:a>=n?[i[n-1],e]:[i[a-1],i[a]]},o.copy=function(){return hL().domain([t,e]).range(r)},ZR(o)}function dL(){var t=[.5],e=[0,1],n=1;function i(i){if(i<=i)return e[jy(t,i,0,n)]}return i.domain=function(r){return arguments.length?(t=kR.call(r),n=Math.min(t.length,e.length-1),i):t.slice()},i.range=function(r){return arguments.length?(e=kR.call(r),n=Math.min(t.length,e.length-1),i):e.slice()},i.invertExtent=function(n){var i=e.indexOf(n);return[t[i-1],t[i]]},i.copy=function(){return dL().domain(t).range(e)},i}var fL=new Date,pL=new Date;function mL(t,e,n,i){function r(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return r.floor=function(e){return t(e=new Date(+e)),e},r.ceil=function(n){return t(n=new Date(n-1)),e(n,1),t(n),n},r.round=function(t){var e=r(t),n=r.ceil(t);return t-e<n-t?e:n},r.offset=function(t,n){return e(t=new Date(+t),null==n?1:Math.floor(n)),t},r.range=function(n,i,o){var a,s=[];if(n=r.ceil(n),o=null==o?1:Math.floor(o),!(n<i&&o>0))return s;do{s.push(a=new Date(+n)),e(n,o),t(n)}while(a<n&&n<i);return s},r.filter=function(n){return mL((function(e){if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),(function(t,i){if(t>=t)if(i<0)for(;++i<=0;)for(;e(t,-1),!n(t););else for(;--i>=0;)for(;e(t,1),!n(t););}))},n&&(r.count=function(e,i){return fL.setTime(+e),pL.setTime(+i),t(fL),t(pL),Math.floor(n(fL,pL))},r.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?r.filter(i?function(e){return i(e)%t==0}:function(e){return r.count(0,e)%t==0}):r:null}),r}var gL=mL((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));gL.every=function(t){return isFinite(t=Math.floor(t))&&t>0?mL((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,n){e.setFullYear(e.getFullYear()+n*t)})):null};var vL=gL,bL=mL((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()}));function yL(t){return mL((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var _L=yL(0),wL=yL(1),kL=(yL(2),yL(3),yL(4)),CL=(yL(5),yL(6),mL((function(t){t.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/864e5}),(function(t){return t.getDate()-1}))),SL=mL((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getHours()})),xL=mL((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getMinutes()})),OL=mL((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+1e3*e)}),(function(t,e){return(e-t)/1e3}),(function(t){return t.getUTCSeconds()})),ML=mL((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t}));ML.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?mL((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,n){e.setTime(+e+n*t)}),(function(e,n){return(n-e)/t})):ML:null};var TL=ML;function EL(t){return mL((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/6048e5}))}var PL=EL(0),AL=EL(1),jL=(EL(2),EL(3),EL(4)),IL=(EL(5),EL(6),mL((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/864e5}),(function(t){return t.getUTCDate()-1}))),DL=mL((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()}));DL.every=function(t){return isFinite(t=Math.floor(t))&&t>0?mL((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,n){e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null};var RL=DL;function LL(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function FL(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function NL(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}var BL,HL,zL,VL={"-":"",_:" ",0:"0"},UL=/^\s*\d+/,qL=/^%/,GL=/[\\^$*+?|[\]().{}]/g;function WL(t,e,n){var i=t<0?"-":"",r=(i?-t:t)+"",o=r.length;return i+(o<n?new Array(n-o+1).join(e)+r:r)}function KL(t){return t.replace(GL,"\\$&")}function XL(t){return new RegExp("^(?:"+t.map(KL).join("|")+")","i")}function YL(t){for(var e={},n=-1,i=t.length;++n<i;)e[t[n].toLowerCase()]=n;return e}function ZL(t,e,n){var i=UL.exec(e.slice(n,n+1));return i?(t.w=+i[0],n+i[0].length):-1}function QL(t,e,n){var i=UL.exec(e.slice(n,n+1));return i?(t.u=+i[0],n+i[0].length):-1}function $L(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.U=+i[0],n+i[0].length):-1}function JL(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.V=+i[0],n+i[0].length):-1}function tF(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.W=+i[0],n+i[0].length):-1}function eF(t,e,n){var i=UL.exec(e.slice(n,n+4));return i?(t.y=+i[0],n+i[0].length):-1}function nF(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.y=+i[0]+(+i[0]>68?1900:2e3),n+i[0].length):-1}function iF(t,e,n){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return i?(t.Z=i[1]?0:-(i[2]+(i[3]||"00")),n+i[0].length):-1}function rF(t,e,n){var i=UL.exec(e.slice(n,n+1));return i?(t.q=3*i[0]-3,n+i[0].length):-1}function oF(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.m=i[0]-1,n+i[0].length):-1}function aF(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.d=+i[0],n+i[0].length):-1}function sF(t,e,n){var i=UL.exec(e.slice(n,n+3));return i?(t.m=0,t.d=+i[0],n+i[0].length):-1}function cF(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.H=+i[0],n+i[0].length):-1}function lF(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.M=+i[0],n+i[0].length):-1}function uF(t,e,n){var i=UL.exec(e.slice(n,n+2));return i?(t.S=+i[0],n+i[0].length):-1}function hF(t,e,n){var i=UL.exec(e.slice(n,n+3));return i?(t.L=+i[0],n+i[0].length):-1}function dF(t,e,n){var i=UL.exec(e.slice(n,n+6));return i?(t.L=Math.floor(i[0]/1e3),n+i[0].length):-1}function fF(t,e,n){var i=qL.exec(e.slice(n,n+1));return i?n+i[0].length:-1}function pF(t,e,n){var i=UL.exec(e.slice(n));return i?(t.Q=+i[0],n+i[0].length):-1}function mF(t,e,n){var i=UL.exec(e.slice(n));return i?(t.s=+i[0],n+i[0].length):-1}function gF(t,e){return WL(t.getDate(),e,2)}function vF(t,e){return WL(t.getHours(),e,2)}function bF(t,e){return WL(t.getHours()%12||12,e,2)}function yF(t,e){return WL(1+CL.count(vL(t),t),e,3)}function _F(t,e){return WL(t.getMilliseconds(),e,3)}function wF(t,e){return _F(t,e)+"000"}function kF(t,e){return WL(t.getMonth()+1,e,2)}function CF(t,e){return WL(t.getMinutes(),e,2)}function SF(t,e){return WL(t.getSeconds(),e,2)}function xF(t){var e=t.getDay();return 0===e?7:e}function OF(t,e){return WL(_L.count(vL(t)-1,t),e,2)}function MF(t,e){var n=t.getDay();return t=n>=4||0===n?kL(t):kL.ceil(t),WL(kL.count(vL(t),t)+(4===vL(t).getDay()),e,2)}function TF(t){return t.getDay()}function EF(t,e){return WL(wL.count(vL(t)-1,t),e,2)}function PF(t,e){return WL(t.getFullYear()%100,e,2)}function AF(t,e){return WL(t.getFullYear()%1e4,e,4)}function jF(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+WL(e/60|0,"0",2)+WL(e%60,"0",2)}function IF(t,e){return WL(t.getUTCDate(),e,2)}function DF(t,e){return WL(t.getUTCHours(),e,2)}function RF(t,e){return WL(t.getUTCHours()%12||12,e,2)}function LF(t,e){return WL(1+IL.count(RL(t),t),e,3)}function FF(t,e){return WL(t.getUTCMilliseconds(),e,3)}function NF(t,e){return FF(t,e)+"000"}function BF(t,e){return WL(t.getUTCMonth()+1,e,2)}function HF(t,e){return WL(t.getUTCMinutes(),e,2)}function zF(t,e){return WL(t.getUTCSeconds(),e,2)}function VF(t){var e=t.getUTCDay();return 0===e?7:e}function UF(t,e){return WL(PL.count(RL(t)-1,t),e,2)}function qF(t,e){var n=t.getUTCDay();return t=n>=4||0===n?jL(t):jL.ceil(t),WL(jL.count(RL(t),t)+(4===RL(t).getUTCDay()),e,2)}function GF(t){return t.getUTCDay()}function WF(t,e){return WL(AL.count(RL(t)-1,t),e,2)}function KF(t,e){return WL(t.getUTCFullYear()%100,e,2)}function XF(t,e){return WL(t.getUTCFullYear()%1e4,e,4)}function YF(){return"+0000"}function ZF(){return"%"}function QF(t){return+t}function $F(t){return Math.floor(+t/1e3)}function JF(t){return new Date(t)}function tN(t){return t instanceof Date?+t:+new Date(+t)}function eN(t,e,n,i,r,o,a,s,c){var l=RR(AR,Bk),u=l.invert,h=l.domain,d=c(".%L"),f=c(":%S"),p=c("%I:%M"),m=c("%I %p"),g=c("%a %d"),v=c("%b %d"),b=c("%B"),y=c("%Y"),_=[[a,1,1e3],[a,5,5e3],[a,15,15e3],[a,30,3e4],[o,1,6e4],[o,5,3e5],[o,15,9e5],[o,30,18e5],[r,1,36e5],[r,3,108e5],[r,6,216e5],[r,12,432e5],[i,1,864e5],[i,2,1728e5],[n,1,6048e5],[e,1,2592e6],[e,3,7776e6],[t,1,31536e6]];function w(s){return(a(s)<s?d:o(s)<s?f:r(s)<s?p:i(s)<s?m:e(s)<s?n(s)<s?g:v:t(s)<s?b:y)(s)}function k(e,n,i,r){if(null==e&&(e=10),"number"==typeof e){var o=Math.abs(i-n)/e,a=Ty((function(t){return t[2]})).right(_,o);a===_.length?(r=$y(n/31536e6,i/31536e6,e),e=t):a?(r=(a=_[o/_[a-1][2]<_[a][2]/o?a-1:a])[1],e=a[0]):(r=Math.max($y(n,i,e),1),e=s)}return null==r?e:e.every(r)}return l.invert=function(t){return new Date(u(t))},l.domain=function(t){return arguments.length?h(wR.call(t,tN)):h().map(JF)},l.ticks=function(t,e){var n,i=h(),r=i[0],o=i[i.length-1],a=o<r;return a&&(n=r,r=o,o=n),n=(n=k(t,r,o,e))?n.range(r,o+1):[],a?n.reverse():n},l.tickFormat=function(t,e){return null==e?w:c(e)},l.nice=function(t,e){var n=h();return(t=k(t,n[0],n[n.length-1],e))?h(JR(n,t)):l},l.copy=function(){return DR(l,eN(t,e,n,i,r,o,a,s,c))},l}BL=function(t){var e=t.dateTime,n=t.date,i=t.time,r=t.periods,o=t.days,a=t.shortDays,s=t.months,c=t.shortMonths,l=XL(r),u=YL(r),h=XL(o),d=YL(o),f=XL(a),p=YL(a),m=XL(s),g=YL(s),v=XL(c),b=YL(c),y={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return c[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:gF,e:gF,f:wF,H:vF,I:bF,j:yF,L:_F,m:kF,M:CF,p:function(t){return r[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:QF,s:$F,S:SF,u:xF,U:OF,V:MF,w:TF,W:EF,x:null,X:null,y:PF,Y:AF,Z:jF,"%":ZF},_={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return c[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:IF,e:IF,f:NF,H:DF,I:RF,j:LF,L:FF,m:BF,M:HF,p:function(t){return r[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:QF,s:$F,S:zF,u:VF,U:UF,V:qF,w:GF,W:WF,x:null,X:null,y:KF,Y:XF,Z:YF,"%":ZF},w={a:function(t,e,n){var i=f.exec(e.slice(n));return i?(t.w=p[i[0].toLowerCase()],n+i[0].length):-1},A:function(t,e,n){var i=h.exec(e.slice(n));return i?(t.w=d[i[0].toLowerCase()],n+i[0].length):-1},b:function(t,e,n){var i=v.exec(e.slice(n));return i?(t.m=b[i[0].toLowerCase()],n+i[0].length):-1},B:function(t,e,n){var i=m.exec(e.slice(n));return i?(t.m=g[i[0].toLowerCase()],n+i[0].length):-1},c:function(t,n,i){return S(t,e,n,i)},d:aF,e:aF,f:dF,H:cF,I:cF,j:sF,L:hF,m:oF,M:lF,p:function(t,e,n){var i=l.exec(e.slice(n));return i?(t.p=u[i[0].toLowerCase()],n+i[0].length):-1},q:rF,Q:pF,s:mF,S:uF,u:QL,U:$L,V:JL,w:ZL,W:tF,x:function(t,e,i){return S(t,n,e,i)},X:function(t,e,n){return S(t,i,e,n)},y:nF,Y:eF,Z:iF,"%":fF};function k(t,e){return function(n){var i,r,o,a=[],s=-1,c=0,l=t.length;for(n instanceof Date||(n=new Date(+n));++s<l;)37===t.charCodeAt(s)&&(a.push(t.slice(c,s)),null!=(r=VL[i=t.charAt(++s)])?i=t.charAt(++s):r="e"===i?" ":"0",(o=e[i])&&(i=o(n,r)),a.push(i),c=s+1);return a.push(t.slice(c,s)),a.join("")}}function C(t,e){return function(n){var i,r,o=NL(1900,void 0,1);if(S(o,t,n+="",0)!=n.length)return null;if("Q"in o)return new Date(o.Q);if("s"in o)return new Date(1e3*o.s+("L"in o?o.L:0));if(e&&!("Z"in o)&&(o.Z=0),"p"in o&&(o.H=o.H%12+12*o.p),void 0===o.m&&(o.m="q"in o?o.q:0),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(r=(i=FL(NL(o.y,0,1))).getUTCDay(),i=r>4||0===r?AL.ceil(i):AL(i),i=IL.offset(i,7*(o.V-1)),o.y=i.getUTCFullYear(),o.m=i.getUTCMonth(),o.d=i.getUTCDate()+(o.w+6)%7):(r=(i=LL(NL(o.y,0,1))).getDay(),i=r>4||0===r?wL.ceil(i):wL(i),i=CL.offset(i,7*(o.V-1)),o.y=i.getFullYear(),o.m=i.getMonth(),o.d=i.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),r="Z"in o?FL(NL(o.y,0,1)).getUTCDay():LL(NL(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(r+5)%7:o.w+7*o.U-(r+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,FL(o)):LL(o)}}function S(t,e,n,i){for(var r,o,a=0,s=e.length,c=n.length;a<s;){if(i>=c)return-1;if(37===(r=e.charCodeAt(a++))){if(r=e.charAt(a++),!(o=w[r in VL?e.charAt(a++):r])||(i=o(t,n,i))<0)return-1}else if(r!=n.charCodeAt(i++))return-1}return i}return y.x=k(n,y),y.X=k(i,y),y.c=k(e,y),_.x=k(n,_),_.X=k(i,_),_.c=k(e,_),{format:function(t){var e=k(t+="",y);return e.toString=function(){return t},e},parse:function(t){var e=C(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=k(t+="",_);return e.toString=function(){return t},e},utcParse:function(t){var e=C(t+="",!0);return e.toString=function(){return t},e}}}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}),HL=BL.format,zL=BL.utcFormat;var nN=function(){return eN(vL,bL,_L,CL,SL,xL,OL,TL,HL).domain([new Date(2e3,0,1),new Date(2e3,0,2)])},iN=mL((function(t){t.setUTCDate(1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCMonth(t.getUTCMonth()+e)}),(function(t,e){return e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear())}),(function(t){return t.getUTCMonth()})),rN=mL((function(t){t.setUTCMinutes(0,0,0)}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getUTCHours()})),oN=mL((function(t){t.setUTCSeconds(0,0)}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getUTCMinutes()})),aN=function(){return eN(RL,iN,PL,IL,rN,oN,OL,TL,zL).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)])};function sN(t){var e=0,n=1,i=!1;function r(r){var o=(r-e)/(n-e);return t(i?Math.max(0,Math.min(1,o)):o)}return r.domain=function(t){return arguments.length?(e=+t[0],n=+t[1],r):[e,n]},r.clamp=function(t){return arguments.length?(i=!!t,r):i},r.interpolator=function(e){return arguments.length?(t=e,r):t},r.copy=function(){return sN(t).domain([e,n]).clamp(i)},ZR(r)}var cN=function(t){for(var e=t.length/6|0,n=new Array(e),i=0;i<e;)n[i]="#"+t.slice(6*i,6*++i);return n},lN=cN("1f77b4ff7f0e2ca02cd627289467bd8c564be377c27f7f7fbcbd2217becf"),uN=cN("7fc97fbeaed4fdc086ffff99386cb0f0027fbf5b17666666"),hN=cN("1b9e77d95f027570b3e7298a66a61ee6ab02a6761d666666"),dN=cN("a6cee31f78b4b2df8a33a02cfb9a99e31a1cfdbf6fff7f00cab2d66a3d9affff99b15928"),fN=cN("fbb4aeb3cde3ccebc5decbe4fed9a6ffffcce5d8bdfddaecf2f2f2"),pN=cN("b3e2cdfdcdaccbd5e8f4cae4e6f5c9fff2aef1e2cccccccc"),mN=cN("e41a1c377eb84daf4a984ea3ff7f00ffff33a65628f781bf999999"),gN=cN("66c2a5fc8d628da0cbe78ac3a6d854ffd92fe5c494b3b3b3"),vN=cN("8dd3c7ffffb3bebadafb807280b1d3fdb462b3de69fccde5d9d9d9bc80bdccebc5ffed6f"),bN=function(t){return Ik(t[t.length-1])},yN=new Array(3).concat("d8b365f5f5f55ab4ac","a6611adfc27d80cdc1018571","a6611adfc27df5f5f580cdc1018571","8c510ad8b365f6e8c3c7eae55ab4ac01665e","8c510ad8b365f6e8c3f5f5f5c7eae55ab4ac01665e","8c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e","8c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e","5430058c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e003c30","5430058c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e003c30").map(cN),_N=bN(yN),wN=new Array(3).concat("af8dc3f7f7f77fbf7b","7b3294c2a5cfa6dba0008837","7b3294c2a5cff7f7f7a6dba0008837","762a83af8dc3e7d4e8d9f0d37fbf7b1b7837","762a83af8dc3e7d4e8f7f7f7d9f0d37fbf7b1b7837","762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b7837","762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b7837","40004b762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b783700441b","40004b762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b783700441b").map(cN),kN=bN(wN),CN=new Array(3).concat("e9a3c9f7f7f7a1d76a","d01c8bf1b6dab8e1864dac26","d01c8bf1b6daf7f7f7b8e1864dac26","c51b7de9a3c9fde0efe6f5d0a1d76a4d9221","c51b7de9a3c9fde0eff7f7f7e6f5d0a1d76a4d9221","c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221","c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221","8e0152c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221276419","8e0152c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221276419").map(cN),SN=bN(CN),xN=new Array(3).concat("998ec3f7f7f7f1a340","5e3c99b2abd2fdb863e66101","5e3c99b2abd2f7f7f7fdb863e66101","542788998ec3d8daebfee0b6f1a340b35806","542788998ec3d8daebf7f7f7fee0b6f1a340b35806","5427888073acb2abd2d8daebfee0b6fdb863e08214b35806","5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b35806","2d004b5427888073acb2abd2d8daebfee0b6fdb863e08214b358067f3b08","2d004b5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b358067f3b08").map(cN),ON=bN(xN),MN=new Array(3).concat("ef8a62f7f7f767a9cf","ca0020f4a58292c5de0571b0","ca0020f4a582f7f7f792c5de0571b0","b2182bef8a62fddbc7d1e5f067a9cf2166ac","b2182bef8a62fddbc7f7f7f7d1e5f067a9cf2166ac","b2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac","b2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac","67001fb2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac053061","67001fb2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac053061").map(cN),TN=bN(MN),EN=new Array(3).concat("ef8a62ffffff999999","ca0020f4a582bababa404040","ca0020f4a582ffffffbababa404040","b2182bef8a62fddbc7e0e0e09999994d4d4d","b2182bef8a62fddbc7ffffffe0e0e09999994d4d4d","b2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d","b2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d","67001fb2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d1a1a1a","67001fb2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d1a1a1a").map(cN),PN=bN(EN),AN=new Array(3).concat("fc8d59ffffbf91bfdb","d7191cfdae61abd9e92c7bb6","d7191cfdae61ffffbfabd9e92c7bb6","d73027fc8d59fee090e0f3f891bfdb4575b4","d73027fc8d59fee090ffffbfe0f3f891bfdb4575b4","d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4","d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4","a50026d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4313695","a50026d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4313695").map(cN),jN=bN(AN),IN=new Array(3).concat("fc8d59ffffbf91cf60","d7191cfdae61a6d96a1a9641","d7191cfdae61ffffbfa6d96a1a9641","d73027fc8d59fee08bd9ef8b91cf601a9850","d73027fc8d59fee08bffffbfd9ef8b91cf601a9850","d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850","d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850","a50026d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850006837","a50026d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850006837").map(cN),DN=bN(IN),RN=new Array(3).concat("fc8d59ffffbf99d594","d7191cfdae61abdda42b83ba","d7191cfdae61ffffbfabdda42b83ba","d53e4ffc8d59fee08be6f59899d5943288bd","d53e4ffc8d59fee08bffffbfe6f59899d5943288bd","d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd","d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd","9e0142d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd5e4fa2","9e0142d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd5e4fa2").map(cN),LN=bN(RN),FN=new Array(3).concat("e5f5f999d8c92ca25f","edf8fbb2e2e266c2a4238b45","edf8fbb2e2e266c2a42ca25f006d2c","edf8fbccece699d8c966c2a42ca25f006d2c","edf8fbccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45006d2c00441b").map(cN),NN=bN(FN),BN=new Array(3).concat("e0ecf49ebcda8856a7","edf8fbb3cde38c96c688419d","edf8fbb3cde38c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d810f7c4d004b").map(cN),HN=bN(BN),zN=new Array(3).concat("e0f3dba8ddb543a2ca","f0f9e8bae4bc7bccc42b8cbe","f0f9e8bae4bc7bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe0868ac084081").map(cN),VN=bN(zN),UN=new Array(3).concat("fee8c8fdbb84e34a33","fef0d9fdcc8afc8d59d7301f","fef0d9fdcc8afc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301fb300007f0000").map(cN),qN=bN(UN),GN=new Array(3).concat("ece2f0a6bddb1c9099","f6eff7bdc9e167a9cf02818a","f6eff7bdc9e167a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016c59014636").map(cN),WN=bN(GN),KN=new Array(3).concat("ece7f2a6bddb2b8cbe","f1eef6bdc9e174a9cf0570b0","f1eef6bdc9e174a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0045a8d023858").map(cN),XN=bN(KN),YN=new Array(3).concat("e7e1efc994c7dd1c77","f1eef6d7b5d8df65b0ce1256","f1eef6d7b5d8df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125698004367001f").map(cN),ZN=bN(YN),QN=new Array(3).concat("fde0ddfa9fb5c51b8a","feebe2fbb4b9f768a1ae017e","feebe2fbb4b9f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a017749006a").map(cN),$N=bN(QN),JN=new Array(3).concat("edf8b17fcdbb2c7fb8","ffffcca1dab441b6c4225ea8","ffffcca1dab441b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea8253494081d58").map(cN),tB=bN(JN),eB=new Array(3).concat("f7fcb9addd8e31a354","ffffccc2e69978c679238443","ffffccc2e69978c67931a354006837","ffffccd9f0a3addd8e78c67931a354006837","ffffccd9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443006837004529").map(cN),nB=bN(eB),iB=new Array(3).concat("fff7bcfec44fd95f0e","ffffd4fed98efe9929cc4c02","ffffd4fed98efe9929d95f0e993404","ffffd4fee391fec44ffe9929d95f0e993404","ffffd4fee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c02993404662506").map(cN),rB=bN(iB),oB=new Array(3).concat("ffeda0feb24cf03b20","ffffb2fecc5cfd8d3ce31a1c","ffffb2fecc5cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cbd0026800026").map(cN),aB=bN(oB),sB=new Array(3).concat("deebf79ecae13182bd","eff3ffbdd7e76baed62171b5","eff3ffbdd7e76baed63182bd08519c","eff3ffc6dbef9ecae16baed63182bd08519c","eff3ffc6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b508519c08306b").map(cN),cB=bN(sB),lB=new Array(3).concat("e5f5e0a1d99b31a354","edf8e9bae4b374c476238b45","edf8e9bae4b374c47631a354006d2c","edf8e9c7e9c0a1d99b74c47631a354006d2c","edf8e9c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45006d2c00441b").map(cN),uB=bN(lB),hB=new Array(3).concat("f0f0f0bdbdbd636363","f7f7f7cccccc969696525252","f7f7f7cccccc969696636363252525","f7f7f7d9d9d9bdbdbd969696636363252525","f7f7f7d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525000000").map(cN),dB=bN(hB),fB=new Array(3).concat("efedf5bcbddc756bb1","f2f0f7cbc9e29e9ac86a51a3","f2f0f7cbc9e29e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a354278f3f007d").map(cN),pB=bN(fB),mB=new Array(3).concat("fee0d2fc9272de2d26","fee5d9fcae91fb6a4acb181d","fee5d9fcae91fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181da50f1567000d").map(cN),gB=bN(mB),vB=new Array(3).concat("fee6cefdae6be6550d","feeddefdbe85fd8d3cd94701","feeddefdbe85fd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d94801a636037f2704").map(cN),bB=bN(vB);function yB(t){return function e(n){function i(e,i){var r=t((e=tR(e)).h,(i=tR(i)).h),o=Pk(e.s,i.s),a=Pk(e.l,i.l),s=Pk(e.opacity,i.opacity);return function(t){return e.h=r(t),e.s=o(t),e.l=a(Math.pow(t,n)),e.opacity=s(t),e+""}}return n=+n,i.gamma=e,i}(1)}yB((function(t,e){var n=e-t;return n?Ek(t,n>180||n<-180?n-360*Math.round(n/360):n):Tk(isNaN(t)?e:t)}));var _B=yB(Pk),wB=_B(tR(300,.5,0),tR(-240,.5,1)),kB=_B(tR(-100,.75,.35),tR(80,1.5,.8)),CB=_B(tR(260,.75,.35),tR(80,1.5,.8)),SB=tR(),xB=function(t){(t<0||t>1)&&(t-=Math.floor(t));var e=Math.abs(t-.5);return SB.h=360*t-100,SB.s=1.5-1.5*e,SB.l=.8-.9*e,SB+""};function OB(t){var e=t.length;return function(n){return t[Math.max(0,Math.min(e-1,Math.floor(n*e)))]}}var MB=OB(cN("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725")),TB=OB(cN("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf")),EB=OB(cN("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4")),PB=OB(cN("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921")),AB={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},jB=function(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),AB.hasOwnProperty(e)?{space:AB[e],local:t}:t};function IB(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return"http://www.w3.org/1999/xhtml"===n&&"http://www.w3.org/1999/xhtml"===e.documentElement.namespaceURI?e.createElement(t):e.createElementNS(n,t)}}function DB(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}var RB=function(t){var e=jB(t);return(e.local?DB:IB)(e)};function LB(){}var FB=function(t){return null==t?LB:function(){return this.querySelector(t)}};function NB(){return[]}var BB=function(t){return null==t?NB:function(){return this.querySelectorAll(t)}},HB=function(t){return function(){return this.matches(t)}};if("undefined"!=typeof document){var zB=document.documentElement;if(!zB.matches){var VB=zB.webkitMatchesSelector||zB.msMatchesSelector||zB.mozMatchesSelector||zB.oMatchesSelector;HB=function(t){return function(){return VB.call(this,t)}}}}var UB=HB,qB=function(t){return new Array(t.length)};function GB(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function WB(t,e,n,i,r,o){for(var a,s=0,c=e.length,l=o.length;s<l;++s)(a=e[s])?(a.__data__=o[s],i[s]=a):n[s]=new GB(t,o[s]);for(;s<c;++s)(a=e[s])&&(r[s]=a)}function KB(t,e,n,i,r,o,a){var s,c,l,u={},h=e.length,d=o.length,f=new Array(h);for(s=0;s<h;++s)(c=e[s])&&(f[s]=l="$"+a.call(c,c.__data__,s,e),l in u?r[s]=c:u[l]=c);for(s=0;s<d;++s)(c=u[l="$"+a.call(t,o[s],s,o)])?(i[s]=c,c.__data__=o[s],u[l]=null):n[s]=new GB(t,o[s]);for(s=0;s<h;++s)(c=e[s])&&u[f[s]]===c&&(r[s]=c)}function XB(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function YB(t){return function(){this.removeAttribute(t)}}function ZB(t){return function(){this.removeAttributeNS(t.space,t.local)}}function QB(t,e){return function(){this.setAttribute(t,e)}}function $B(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function JB(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function tH(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}GB.prototype={constructor:GB,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var eH=function(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView};function nH(t){return function(){this.style.removeProperty(t)}}function iH(t,e,n){return function(){this.style.setProperty(t,e,n)}}function rH(t,e,n){return function(){var i=e.apply(this,arguments);null==i?this.style.removeProperty(t):this.style.setProperty(t,i,n)}}function oH(t,e){return t.style.getPropertyValue(e)||eH(t).getComputedStyle(t,null).getPropertyValue(e)}function aH(t){return function(){delete this[t]}}function sH(t,e){return function(){this[t]=e}}function cH(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function lH(t){return t.trim().split(/^|\s+/)}function uH(t){return t.classList||new hH(t)}function hH(t){this._node=t,this._names=lH(t.getAttribute("class")||"")}function dH(t,e){for(var n=uH(t),i=-1,r=e.length;++i<r;)n.add(e[i])}function fH(t,e){for(var n=uH(t),i=-1,r=e.length;++i<r;)n.remove(e[i])}function pH(t){return function(){dH(this,t)}}function mH(t){return function(){fH(this,t)}}function gH(t,e){return function(){(e.apply(this,arguments)?dH:fH)(this,t)}}function vH(){this.textContent=""}function bH(t){return function(){this.textContent=t}}function yH(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function _H(){this.innerHTML=""}function wH(t){return function(){this.innerHTML=t}}function kH(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function CH(){this.nextSibling&&this.parentNode.appendChild(this)}function SH(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function xH(){return null}function OH(){var t=this.parentNode;t&&t.removeChild(this)}function MH(){return this.parentNode.insertBefore(this.cloneNode(!1),this.nextSibling)}function TH(){return this.parentNode.insertBefore(this.cloneNode(!0),this.nextSibling)}hH.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var EH={},PH=null;function AH(t,e,n){return t=jH(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function jH(t,e,n){return function(i){var r=PH;PH=i;try{t.call(this,this.__data__,e,n)}finally{PH=r}}}function IH(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}function DH(t){return function(){var e=this.__on;if(e){for(var n,i=0,r=-1,o=e.length;i<o;++i)n=e[i],t.type&&n.type!==t.type||n.name!==t.name?e[++r]=n:this.removeEventListener(n.type,n.listener,n.capture);++r?e.length=r:delete this.__on}}}function RH(t,e,n){var i=EH.hasOwnProperty(t.type)?AH:jH;return function(r,o,a){var s,c=this.__on,l=i(e,o,a);if(c)for(var u=0,h=c.length;u<h;++u)if((s=c[u]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=l,s.capture=n),void(s.value=e);this.addEventListener(t.type,l,n),s={type:t.type,name:t.name,value:e,listener:l,capture:n},c?c.push(s):this.__on=[s]}}function LH(t,e,n,i){var r=PH;t.sourceEvent=PH,PH=t;try{return e.apply(n,i)}finally{PH=r}}function FH(t,e,n){var i=eH(t),r=i.CustomEvent;"function"==typeof r?r=new r(e,n):(r=i.document.createEvent("Event"),n?(r.initEvent(e,n.bubbles,n.cancelable),r.detail=n.detail):r.initEvent(e,!1,!1)),t.dispatchEvent(r)}function NH(t,e){return function(){return FH(this,t,e)}}function BH(t,e){return function(){return FH(this,t,e.apply(this,arguments))}}"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(EH={mouseenter:"mouseover",mouseleave:"mouseout"}));var HH=[null];function zH(t,e){this._groups=t,this._parents=e}function VH(){return new zH([[document.documentElement]],HH)}zH.prototype=VH.prototype={constructor:zH,select:function(t){"function"!=typeof t&&(t=FB(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o,a,s=e[r],c=s.length,l=i[r]=new Array(c),u=0;u<c;++u)(o=s[u])&&(a=t.call(o,o.__data__,u,s))&&("__data__"in o&&(a.__data__=o.__data__),l[u]=a);return new zH(i,this._parents)},selectAll:function(t){"function"!=typeof t&&(t=BB(t));for(var e=this._groups,n=e.length,i=[],r=[],o=0;o<n;++o)for(var a,s=e[o],c=s.length,l=0;l<c;++l)(a=s[l])&&(i.push(t.call(a,a.__data__,l,s)),r.push(a));return new zH(i,r)},filter:function(t){"function"!=typeof t&&(t=UB(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o,a=e[r],s=a.length,c=i[r]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&c.push(o);return new zH(i,this._parents)},data:function(t,e){if(!t)return p=new Array(this.size()),u=-1,this.each((function(t){p[++u]=t})),p;var n,i=e?KB:WB,r=this._parents,o=this._groups;"function"!=typeof t&&(n=t,t=function(){return n});for(var a=o.length,s=new Array(a),c=new Array(a),l=new Array(a),u=0;u<a;++u){var h=r[u],d=o[u],f=d.length,p=t.call(h,h&&h.__data__,u,r),m=p.length,g=c[u]=new Array(m),v=s[u]=new Array(m);i(h,d,g,v,l[u]=new Array(f),p,e);for(var b,y,_=0,w=0;_<m;++_)if(b=g[_]){for(_>=w&&(w=_+1);!(y=v[w])&&++w<m;);b._next=y||null}}return(s=new zH(s,r))._enter=c,s._exit=l,s},enter:function(){return new zH(this._enter||this._groups.map(qB),this._parents)},exit:function(){return new zH(this._exit||this._groups.map(qB),this._parents)},merge:function(t){for(var e=this._groups,n=t._groups,i=e.length,r=Math.min(i,n.length),o=new Array(i),a=0;a<r;++a)for(var s,c=e[a],l=n[a],u=c.length,h=o[a]=new Array(u),d=0;d<u;++d)(s=c[d]||l[d])&&(h[d]=s);for(;a<i;++a)o[a]=e[a];return new zH(o,this._parents)},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var i,r=t[e],o=r.length-1,a=r[o];--o>=0;)(i=r[o])&&(a&&a!==i.nextSibling&&a.parentNode.insertBefore(i,a),a=i);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=XB);for(var n=this._groups,i=n.length,r=new Array(i),o=0;o<i;++o){for(var a,s=n[o],c=s.length,l=r[o]=new Array(c),u=0;u<c;++u)(a=s[u])&&(l[u]=a);l.sort(e)}return new zH(r,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){var t=new Array(this.size()),e=-1;return this.each((function(){t[++e]=this})),t},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var i=t[e],r=0,o=i.length;r<o;++r){var a=i[r];if(a)return a}return null},size:function(){var t=0;return this.each((function(){++t})),t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,i=e.length;n<i;++n)for(var r,o=e[n],a=0,s=o.length;a<s;++a)(r=o[a])&&t.call(r,r.__data__,a,o);return this},attr:function(t,e){var n=jB(t);if(arguments.length<2){var i=this.node();return n.local?i.getAttributeNS(n.space,n.local):i.getAttribute(n)}return this.each((null==e?n.local?ZB:YB:"function"==typeof e?n.local?tH:JB:n.local?$B:QB)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?nH:"function"==typeof e?rH:iH)(t,e,null==n?"":n)):oH(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?aH:"function"==typeof e?cH:sH)(t,e)):this.node()[t]},classed:function(t,e){var n=lH(t+"");if(arguments.length<2){for(var i=uH(this.node()),r=-1,o=n.length;++r<o;)if(!i.contains(n[r]))return!1;return!0}return this.each(("function"==typeof e?gH:e?pH:mH)(n,e))},text:function(t){return arguments.length?this.each(null==t?vH:("function"==typeof t?yH:bH)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?_H:("function"==typeof t?kH:wH)(t)):this.node().innerHTML},raise:function(){return this.each(CH)},lower:function(){return this.each(SH)},append:function(t){var e="function"==typeof t?t:RB(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:RB(t),i=null==e?xH:"function"==typeof e?e:FB(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)}))},remove:function(){return this.each(OH)},clone:function(t){return this.select(t?TH:MH)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var i,r,o=IH(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?RH:DH,null==n&&(n=!1),i=0;i<a;++i)this.each(s(o[i],e,n));return this}var s=this.node().__on;if(s)for(var c,l=0,u=s.length;l<u;++l)for(i=0,c=s[l];i<a;++i)if((r=o[i]).type===c.type&&r.name===c.name)return c.value},dispatch:function(t,e){return this.each(("function"==typeof e?BH:NH)(t,e))}};var UH=VH,qH=function(t){return"string"==typeof t?new zH([[document.querySelector(t)]],[document.documentElement]):new zH([[t]],HH)},GH=function(t){return qH(RB(t).call(document.documentElement))},WH=0;function KH(){return new XH}function XH(){this._="@"+(++WH).toString(36)}XH.prototype=KH.prototype={constructor:XH,get:function(t){for(var e=this._;!(e in t);)if(!(t=t.parentNode))return;return t[e]},set:function(t,e){return t[this._]=e},remove:function(t){return this._ in t&&delete t[this._]},toString:function(){return this._}};var YH=function(){for(var t,e=PH;t=e.sourceEvent;)e=t;return e},ZH=function(t,e){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var i=n.createSVGPoint();return i.x=e.clientX,i.y=e.clientY,[(i=i.matrixTransform(t.getScreenCTM().inverse())).x,i.y]}var r=t.getBoundingClientRect();return[e.clientX-r.left-t.clientLeft,e.clientY-r.top-t.clientTop]},QH=function(t){var e=YH();return e.changedTouches&&(e=e.changedTouches[0]),ZH(t,e)},$H=function(t){return"string"==typeof t?new zH([document.querySelectorAll(t)],[document.documentElement]):new zH([null==t?[]:t],HH)},JH=function(t,e,n){arguments.length<3&&(n=e,e=YH().changedTouches);for(var i,r=0,o=e?e.length:0;r<o;++r)if((i=e[r]).identifier===n)return ZH(t,i);return null},tz=function(t,e){null==e&&(e=YH().touches);for(var n=0,i=e?e.length:0,r=new Array(i);n<i;++n)r[n]=ZH(t,e[n]);return r};function ez(t,e){return t.each((function(){var t=e.apply(this,arguments),n=Ww(this);for(var i in t)n.attr(i,t[i])}))}function nz(t,e){for(var n in e)t.attr(n,e[n]);return t}function iz(t,e,n){return t.each((function(){var t=e.apply(this,arguments),i=Ww(this);for(var r in t)i.style(r,t[r],n)}))}function rz(t,e,n){for(var i in e)t.style(i,e[i],n);return t}function oz(t,e){return t.each((function(){var t=e.apply(this,arguments),n=Ww(this);for(var i in t)n.property(i,t[i])}))}function az(t,e){for(var n in e)t.property(n,e[n]);return t}function sz(t,e){return t.each((function(){var n=e.apply(this,arguments),i=Ww(this).transition(t);for(var r in n)i.attr(r,n[r])}))}function cz(t,e){for(var n in e)t.attr(n,e[n]);return t}function lz(t,e,n){return t.each((function(){var i=e.apply(this,arguments),r=Ww(this).transition(t);for(var o in i)r.style(o,i[o],n)}))}function uz(t,e,n){for(var i in e)t.style(i,e[i],n);return t}Gw.prototype.attrs=function(t){return("function"==typeof t?ez:nz)(this,t)},Gw.prototype.styles=function(t,e){return("function"==typeof t?iz:rz)(this,t,null==e?"":e)},Gw.prototype.properties=function(t){return("function"==typeof t?oz:az)(this,t)},nS.prototype.attrs=function(t){return("function"==typeof t?sz:cz)(this,t)},nS.prototype.styles=function(t,e){return("function"==typeof t?lz:uz)(this,t,null==e?"":e)};var hz=function(t){return function(){return t}},dz=Math.abs,fz=Math.atan2,pz=Math.cos,mz=Math.max,gz=Math.min,vz=Math.sin,bz=Math.sqrt,yz=Math.PI,_z=yz/2,wz=2*yz;function kz(t){return t>1?0:t<-1?yz:Math.acos(t)}function Cz(t){return t>=1?_z:t<=-1?-_z:Math.asin(t)}function Sz(t){return t.innerRadius}function xz(t){return t.outerRadius}function Oz(t){return t.startAngle}function Mz(t){return t.endAngle}function Tz(t){return t&&t.padAngle}function Ez(t,e,n,i,r,o,a,s){var c=n-t,l=i-e,u=a-r,h=s-o,d=h*c-u*l;if(!(d*d<1e-12))return[t+(d=(u*(e-o)-h*(t-r))/d)*c,e+d*l]}function Pz(t,e,n,i,r,o,a){var s=t-n,c=e-i,l=(a?o:-o)/bz(s*s+c*c),u=l*c,h=-l*s,d=t+u,f=e+h,p=n+u,m=i+h,g=(d+p)/2,v=(f+m)/2,b=p-d,y=m-f,_=b*b+y*y,w=r-o,k=d*m-p*f,C=(y<0?-1:1)*bz(mz(0,w*w*_-k*k)),S=(k*y-b*C)/_,x=(-k*b-y*C)/_,O=(k*y+b*C)/_,M=(-k*b+y*C)/_,T=S-g,E=x-v,P=O-g,A=M-v;return T*T+E*E>P*P+A*A&&(S=O,x=M),{cx:S,cy:x,x01:-u,y01:-h,x11:S*(r/w-1),y11:x*(r/w-1)}}var Az=function(){var t=Sz,e=xz,n=hz(0),i=null,r=Oz,o=Mz,a=Tz,s=null;function c(){var c,l,u=+t.apply(this,arguments),h=+e.apply(this,arguments),d=r.apply(this,arguments)-_z,f=o.apply(this,arguments)-_z,p=dz(f-d),m=f>d;if(s||(s=c=QS()),h<u&&(l=h,h=u,u=l),h>1e-12)if(p>wz-1e-12)s.moveTo(h*pz(d),h*vz(d)),s.arc(0,0,h,d,f,!m),u>1e-12&&(s.moveTo(u*pz(f),u*vz(f)),s.arc(0,0,u,f,d,m));else{var g,v,b=d,y=f,_=d,w=f,k=p,C=p,S=a.apply(this,arguments)/2,x=S>1e-12&&(i?+i.apply(this,arguments):bz(u*u+h*h)),O=gz(dz(h-u)/2,+n.apply(this,arguments)),M=O,T=O;if(x>1e-12){var E=Cz(x/u*vz(S)),P=Cz(x/h*vz(S));(k-=2*E)>1e-12?(_+=E*=m?1:-1,w-=E):(k=0,_=w=(d+f)/2),(C-=2*P)>1e-12?(b+=P*=m?1:-1,y-=P):(C=0,b=y=(d+f)/2)}var A=h*pz(b),j=h*vz(b),I=u*pz(w),D=u*vz(w);if(O>1e-12){var R,L=h*pz(y),F=h*vz(y),N=u*pz(_),B=u*vz(_);if(p<=wz-1e-12&&(R=Ez(A,j,N,B,L,F,I,D))){var H=A-R[0],z=j-R[1],V=L-R[0],U=F-R[1],q=1/vz(kz((H*V+z*U)/(bz(H*H+z*z)*bz(V*V+U*U)))/2),G=bz(R[0]*R[0]+R[1]*R[1]);M=gz(O,(u-G)/(q-1)),T=gz(O,(h-G)/(q+1))}}C>1e-12?T>1e-12?(g=Pz(N,B,A,j,h,T,m),v=Pz(L,F,I,D,h,T,m),s.moveTo(g.cx+g.x01,g.cy+g.y01),T<O?s.arc(g.cx,g.cy,T,fz(g.y01,g.x01),fz(v.y01,v.x01),!m):(s.arc(g.cx,g.cy,T,fz(g.y01,g.x01),fz(g.y11,g.x11),!m),s.arc(0,0,h,fz(g.cy+g.y11,g.cx+g.x11),fz(v.cy+v.y11,v.cx+v.x11),!m),s.arc(v.cx,v.cy,T,fz(v.y11,v.x11),fz(v.y01,v.x01),!m))):(s.moveTo(A,j),s.arc(0,0,h,b,y,!m)):s.moveTo(A,j),u>1e-12&&k>1e-12?M>1e-12?(g=Pz(I,D,L,F,u,-M,m),v=Pz(A,j,N,B,u,-M,m),s.lineTo(g.cx+g.x01,g.cy+g.y01),M<O?s.arc(g.cx,g.cy,M,fz(g.y01,g.x01),fz(v.y01,v.x01),!m):(s.arc(g.cx,g.cy,M,fz(g.y01,g.x01),fz(g.y11,g.x11),!m),s.arc(0,0,u,fz(g.cy+g.y11,g.cx+g.x11),fz(v.cy+v.y11,v.cx+v.x11),m),s.arc(v.cx,v.cy,M,fz(v.y11,v.x11),fz(v.y01,v.x01),!m))):s.arc(0,0,u,w,_,m):s.lineTo(I,D)}else s.moveTo(0,0);if(s.closePath(),c)return s=null,c+""||null}return c.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,i=(+r.apply(this,arguments)+ +o.apply(this,arguments))/2-yz/2;return[pz(i)*n,vz(i)*n]},c.innerRadius=function(e){return arguments.length?(t="function"==typeof e?e:hz(+e),c):t},c.outerRadius=function(t){return arguments.length?(e="function"==typeof t?t:hz(+t),c):e},c.cornerRadius=function(t){return arguments.length?(n="function"==typeof t?t:hz(+t),c):n},c.padRadius=function(t){return arguments.length?(i=null==t?null:"function"==typeof t?t:hz(+t),c):i},c.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:hz(+t),c):r},c.endAngle=function(t){return arguments.length?(o="function"==typeof t?t:hz(+t),c):o},c.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:hz(+t),c):a},c.context=function(t){return arguments.length?(s=null==t?null:t,c):s},c};function jz(t){this._context=t}jz.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}};var Iz=function(t){return new jz(t)};function Dz(t){return t[0]}function Rz(t){return t[1]}var Lz=function(){var t=Dz,e=Rz,n=hz(!0),i=null,r=Iz,o=null;function a(a){var s,c,l,u=a.length,h=!1;for(null==i&&(o=r(l=QS())),s=0;s<=u;++s)!(s<u&&n(c=a[s],s,a))===h&&((h=!h)?o.lineStart():o.lineEnd()),h&&o.point(+t(c,s,a),+e(c,s,a));if(l)return o=null,l+""||null}return a.x=function(e){return arguments.length?(t="function"==typeof e?e:hz(+e),a):t},a.y=function(t){return arguments.length?(e="function"==typeof t?t:hz(+t),a):e},a.defined=function(t){return arguments.length?(n="function"==typeof t?t:hz(!!t),a):n},a.curve=function(t){return arguments.length?(r=t,null!=i&&(o=r(i)),a):r},a.context=function(t){return arguments.length?(null==t?i=o=null:o=r(i=t),a):i},a},Fz=function(){var t=Dz,e=null,n=hz(0),i=Rz,r=hz(!0),o=null,a=Iz,s=null;function c(c){var l,u,h,d,f,p=c.length,m=!1,g=new Array(p),v=new Array(p);for(null==o&&(s=a(f=QS())),l=0;l<=p;++l){if(!(l<p&&r(d=c[l],l,c))===m)if(m=!m)u=l,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),h=l-1;h>=u;--h)s.point(g[h],v[h]);s.lineEnd(),s.areaEnd()}m&&(g[l]=+t(d,l,c),v[l]=+n(d,l,c),s.point(e?+e(d,l,c):g[l],i?+i(d,l,c):v[l]))}if(f)return s=null,f+""||null}function l(){return Lz().defined(r).curve(a).context(o)}return c.x=function(n){return arguments.length?(t="function"==typeof n?n:hz(+n),e=null,c):t},c.x0=function(e){return arguments.length?(t="function"==typeof e?e:hz(+e),c):t},c.x1=function(t){return arguments.length?(e=null==t?null:"function"==typeof t?t:hz(+t),c):e},c.y=function(t){return arguments.length?(n="function"==typeof t?t:hz(+t),i=null,c):n},c.y0=function(t){return arguments.length?(n="function"==typeof t?t:hz(+t),c):n},c.y1=function(t){return arguments.length?(i=null==t?null:"function"==typeof t?t:hz(+t),c):i},c.lineX0=c.lineY0=function(){return l().x(t).y(n)},c.lineY1=function(){return l().x(t).y(i)},c.lineX1=function(){return l().x(e).y(n)},c.defined=function(t){return arguments.length?(r="function"==typeof t?t:hz(!!t),c):r},c.curve=function(t){return arguments.length?(a=t,null!=o&&(s=a(o)),c):a},c.context=function(t){return arguments.length?(null==t?o=s=null:s=a(o=t),c):o},c},Nz=function(t,e){return e<t?-1:e>t?1:e>=t?0:NaN},Bz=function(t){return t},Hz=function(){var t=Bz,e=Nz,n=null,i=hz(0),r=hz(wz),o=hz(0);function a(a){var s,c,l,u,h,d=a.length,f=0,p=new Array(d),m=new Array(d),g=+i.apply(this,arguments),v=Math.min(wz,Math.max(-wz,r.apply(this,arguments)-g)),b=Math.min(Math.abs(v)/d,o.apply(this,arguments)),y=b*(v<0?-1:1);for(s=0;s<d;++s)(h=m[p[s]=s]=+t(a[s],s,a))>0&&(f+=h);for(null!=e?p.sort((function(t,n){return e(m[t],m[n])})):null!=n&&p.sort((function(t,e){return n(a[t],a[e])})),s=0,l=f?(v-d*y)/f:0;s<d;++s,g=u)m[c=p[s]]={data:a[c],index:s,value:h=m[c],startAngle:g,endAngle:u=g+(h>0?h*l:0)+y,padAngle:b};return m}return a.value=function(e){return arguments.length?(t="function"==typeof e?e:hz(+e),a):t},a.sortValues=function(t){return arguments.length?(e=t,n=null,a):e},a.sort=function(t){return arguments.length?(n=t,e=null,a):n},a.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:hz(+t),a):i},a.endAngle=function(t){return arguments.length?(r="function"==typeof t?t:hz(+t),a):r},a.padAngle=function(t){return arguments.length?(o="function"==typeof t?t:hz(+t),a):o},a},zz=Uz(Iz);function Vz(t){this._curve=t}function Uz(t){function e(e){return new Vz(t(e))}return e._curve=t,e}function qz(t){var e=t.curve;return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(Uz(t)):e()._curve},t}Vz.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(t,e){this._curve.point(e*Math.sin(t),e*-Math.cos(t))}};var Gz=function(){return qz(Lz().curve(zz))},Wz=function(){var t=Fz().curve(zz),e=t.curve,n=t.lineX0,i=t.lineX1,r=t.lineY0,o=t.lineY1;return t.angle=t.x,delete t.x,t.startAngle=t.x0,delete t.x0,t.endAngle=t.x1,delete t.x1,t.radius=t.y,delete t.y,t.innerRadius=t.y0,delete t.y0,t.outerRadius=t.y1,delete t.y1,t.lineStartAngle=function(){return qz(n())},delete t.lineX0,t.lineEndAngle=function(){return qz(i())},delete t.lineX1,t.lineInnerRadius=function(){return qz(r())},delete t.lineY0,t.lineOuterRadius=function(){return qz(o())},delete t.lineY1,t.curve=function(t){return arguments.length?e(Uz(t)):e()._curve},t},Kz=function(t,e){return[(e=+e)*Math.cos(t-=Math.PI/2),e*Math.sin(t)]},Xz=Array.prototype.slice;function Yz(t){return t.source}function Zz(t){return t.target}function Qz(t){var e=Yz,n=Zz,i=Dz,r=Rz,o=null;function a(){var a,s=Xz.call(arguments),c=e.apply(this,s),l=n.apply(this,s);if(o||(o=a=QS()),t(o,+i.apply(this,(s[0]=c,s)),+r.apply(this,s),+i.apply(this,(s[0]=l,s)),+r.apply(this,s)),a)return o=null,a+""||null}return a.source=function(t){return arguments.length?(e=t,a):e},a.target=function(t){return arguments.length?(n=t,a):n},a.x=function(t){return arguments.length?(i="function"==typeof t?t:hz(+t),a):i},a.y=function(t){return arguments.length?(r="function"==typeof t?t:hz(+t),a):r},a.context=function(t){return arguments.length?(o=null==t?null:t,a):o},a}function $z(t,e,n,i,r){t.moveTo(e,n),t.bezierCurveTo(e=(e+i)/2,n,e,r,i,r)}function Jz(t,e,n,i,r){t.moveTo(e,n),t.bezierCurveTo(e,n=(n+r)/2,i,n,i,r)}function tV(t,e,n,i,r){var o=Kz(e,n),a=Kz(e,n=(n+r)/2),s=Kz(i,n),c=Kz(i,r);t.moveTo(o[0],o[1]),t.bezierCurveTo(a[0],a[1],s[0],s[1],c[0],c[1])}function eV(){return Qz($z)}function nV(){return Qz(Jz)}function iV(){var t=Qz(tV);return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t}var rV={draw:function(t,e){var n=Math.sqrt(e/yz);t.moveTo(n,0),t.arc(0,0,n,0,wz)}},oV={draw:function(t,e){var n=Math.sqrt(e/5)/2;t.moveTo(-3*n,-n),t.lineTo(-n,-n),t.lineTo(-n,-3*n),t.lineTo(n,-3*n),t.lineTo(n,-n),t.lineTo(3*n,-n),t.lineTo(3*n,n),t.lineTo(n,n),t.lineTo(n,3*n),t.lineTo(-n,3*n),t.lineTo(-n,n),t.lineTo(-3*n,n),t.closePath()}},aV=Math.sqrt(1/3),sV=2*aV,cV={draw:function(t,e){var n=Math.sqrt(e/sV),i=n*aV;t.moveTo(0,-n),t.lineTo(i,0),t.lineTo(0,n),t.lineTo(-i,0),t.closePath()}},lV=Math.sin(yz/10)/Math.sin(7*yz/10),uV=Math.sin(wz/10)*lV,hV=-Math.cos(wz/10)*lV,dV={draw:function(t,e){var n=Math.sqrt(.8908130915292852*e),i=uV*n,r=hV*n;t.moveTo(0,-n),t.lineTo(i,r);for(var o=1;o<5;++o){var a=wz*o/5,s=Math.cos(a),c=Math.sin(a);t.lineTo(c*n,-s*n),t.lineTo(s*i-c*r,c*i+s*r)}t.closePath()}},fV={draw:function(t,e){var n=Math.sqrt(e),i=-n/2;t.rect(i,i,n,n)}},pV=Math.sqrt(3),mV={draw:function(t,e){var n=-Math.sqrt(e/(3*pV));t.moveTo(0,2*n),t.lineTo(-pV*n,-n),t.lineTo(pV*n,-n),t.closePath()}},gV=Math.sqrt(3)/2,vV=1/Math.sqrt(12),bV=3*(vV/2+1),yV={draw:function(t,e){var n=Math.sqrt(e/bV),i=n/2,r=n*vV,o=i,a=n*vV+n,s=-o,c=a;t.moveTo(i,r),t.lineTo(o,a),t.lineTo(s,c),t.lineTo(-.5*i-gV*r,gV*i+-.5*r),t.lineTo(-.5*o-gV*a,gV*o+-.5*a),t.lineTo(-.5*s-gV*c,gV*s+-.5*c),t.lineTo(-.5*i+gV*r,-.5*r-gV*i),t.lineTo(-.5*o+gV*a,-.5*a-gV*o),t.lineTo(-.5*s+gV*c,-.5*c-gV*s),t.closePath()}},_V=[rV,oV,cV,fV,dV,mV,yV],wV=function(){var t=hz(rV),e=hz(64),n=null;function i(){var i;if(n||(n=i=QS()),t.apply(this,arguments).draw(n,+e.apply(this,arguments)),i)return n=null,i+""||null}return i.type=function(e){return arguments.length?(t="function"==typeof e?e:hz(e),i):t},i.size=function(t){return arguments.length?(e="function"==typeof t?t:hz(+t),i):e},i.context=function(t){return arguments.length?(n=null==t?null:t,i):n},i},kV=function(){};function CV(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function SV(t){this._context=t}SV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:CV(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:CV(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var xV=function(t){return new SV(t)};function OV(t){this._context=t}OV.prototype={areaStart:kV,areaEnd:kV,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:CV(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var MV=function(t){return new OV(t)};function TV(t){this._context=t}TV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,i=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,i):this._context.moveTo(n,i);break;case 3:this._point=4;default:CV(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var EV=function(t){return new TV(t)};function PV(t,e){this._basis=new SV(t),this._beta=e}PV.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var i,r=t[0],o=e[0],a=t[n]-r,s=e[n]-o,c=-1;++c<=n;)this._basis.point(this._beta*t[c]+(1-this._beta)*(r+(i=c/n)*a),this._beta*e[c]+(1-this._beta)*(o+i*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var AV=function t(e){function n(t){return 1===e?new SV(t):new PV(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function jV(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function IV(t,e){this._context=t,this._k=(1-e)/6}IV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:jV(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:jV(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var DV=function t(e){function n(t){return new IV(t,e)}return n.tension=function(e){return t(+e)},n}(0);function RV(t,e){this._context=t,this._k=(1-e)/6}RV.prototype={areaStart:kV,areaEnd:kV,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:jV(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var LV=function t(e){function n(t){return new RV(t,e)}return n.tension=function(e){return t(+e)},n}(0);function FV(t,e){this._context=t,this._k=(1-e)/6}FV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:jV(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var NV=function t(e){function n(t){return new FV(t,e)}return n.tension=function(e){return t(+e)},n}(0);function BV(t,e,n){var i=t._x1,r=t._y1,o=t._x2,a=t._y2;if(t._l01_a>1e-12){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,c=3*t._l01_a*(t._l01_a+t._l12_a);i=(i*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/c,r=(r*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/c}if(t._l23_a>1e-12){var l=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,u=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*l+t._x1*t._l23_2a-e*t._l12_2a)/u,a=(a*l+t._y1*t._l23_2a-n*t._l12_2a)/u}t._context.bezierCurveTo(i,r,o,a,t._x2,t._y2)}function HV(t,e){this._context=t,this._alpha=e}HV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:BV(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var zV=function t(e){function n(t){return e?new HV(t,e):new IV(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function VV(t,e){this._context=t,this._alpha=e}VV.prototype={areaStart:kV,areaEnd:kV,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:BV(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var UV=function t(e){function n(t){return e?new VV(t,e):new RV(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function qV(t,e){this._context=t,this._alpha=e}qV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:BV(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var GV=function t(e){function n(t){return e?new qV(t,e):new FV(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function WV(t){this._context=t}WV.prototype={areaStart:kV,areaEnd:kV,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}};var KV=function(t){return new WV(t)};function XV(t){return t<0?-1:1}function YV(t,e,n){var i=t._x1-t._x0,r=e-t._x1,o=(t._y1-t._y0)/(i||r<0&&-0),a=(n-t._y1)/(r||i<0&&-0),s=(o*r+a*i)/(i+r);return(XV(o)+XV(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function ZV(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function QV(t,e,n){var i=t._x0,r=t._x1,o=t._y1,a=(r-i)/3;t._context.bezierCurveTo(i+a,t._y0+a*e,r-a,o-a*n,r,o)}function $V(t){this._context=t}function JV(t){this._context=new tU(t)}function tU(t){this._context=t}function eU(t){return new $V(t)}function nU(t){return new JV(t)}function iU(t){this._context=t}function rU(t){var e,n,i=t.length-1,r=new Array(i),o=new Array(i),a=new Array(i);for(r[0]=0,o[0]=2,a[0]=t[0]+2*t[1],e=1;e<i-1;++e)r[e]=1,o[e]=4,a[e]=4*t[e]+2*t[e+1];for(r[i-1]=2,o[i-1]=7,a[i-1]=8*t[i-1]+t[i],e=1;e<i;++e)o[e]-=n=r[e]/o[e-1],a[e]-=n*a[e-1];for(r[i-1]=a[i-1]/o[i-1],e=i-2;e>=0;--e)r[e]=(a[e]-r[e+1])/o[e];for(o[i-1]=(t[i]+r[i-1])/2,e=0;e<i-1;++e)o[e]=2*t[e+1]-r[e+1];return[r,o]}$V.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:QV(this,this._t0,ZV(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(e=+e,(t=+t)!==this._x1||e!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,QV(this,ZV(this,n=YV(this,t,e)),n);break;default:QV(this,this._t0,n=YV(this,t,e))}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(JV.prototype=Object.create($V.prototype)).point=function(t,e){$V.prototype.point.call(this,e,t)},tU.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,i,r,o){this._context.bezierCurveTo(e,t,i,n,o,r)}},iU.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),2===n)this._context.lineTo(t[1],e[1]);else for(var i=rU(t),r=rU(e),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(i[0][o],r[0][o],i[1][o],r[1][o],t[a],e[a]);(this._line||0!==this._line&&1===n)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var oU=function(t){return new iU(t)};function aU(t,e){this._context=t,this._t=e}aU.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}}this._x=t,this._y=e}};var sU=function(t){return new aU(t,.5)};function cU(t){return new aU(t,0)}function lU(t){return new aU(t,1)}var uU=function(t,e){if((r=t.length)>1)for(var n,i,r,o=1,a=t[e[0]],s=a.length;o<r;++o)for(i=a,a=t[e[o]],n=0;n<s;++n)a[n][1]+=a[n][0]=isNaN(i[n][1])?i[n][0]:i[n][1]},hU=function(t){for(var e=t.length,n=new Array(e);--e>=0;)n[e]=e;return n};function dU(t,e){return t[e]}var fU=function(){var t=hz([]),e=hU,n=uU,i=dU;function r(r){var o,a,s=t.apply(this,arguments),c=r.length,l=s.length,u=new Array(l);for(o=0;o<l;++o){for(var h,d=s[o],f=u[o]=new Array(c),p=0;p<c;++p)f[p]=h=[0,+i(r[p],d,p,r)],h.data=r[p];f.key=d}for(o=0,a=e(u);o<l;++o)u[a[o]].index=o;return n(u,a),u}return r.keys=function(e){return arguments.length?(t="function"==typeof e?e:hz(Xz.call(e)),r):t},r.value=function(t){return arguments.length?(i="function"==typeof t?t:hz(+t),r):i},r.order=function(t){return arguments.length?(e=null==t?hU:"function"==typeof t?t:hz(Xz.call(t)),r):e},r.offset=function(t){return arguments.length?(n=null==t?uU:t,r):n},r},pU=function(t,e){if((i=t.length)>0){for(var n,i,r,o=0,a=t[0].length;o<a;++o){for(r=n=0;n<i;++n)r+=t[n][o][1]||0;if(r)for(n=0;n<i;++n)t[n][o][1]/=r}uU(t,e)}},mU=function(t,e){if((s=t.length)>1)for(var n,i,r,o,a,s,c=0,l=t[e[0]].length;c<l;++c)for(o=a=0,n=0;n<s;++n)(r=(i=t[e[n]][c])[1]-i[0])>=0?(i[0]=o,i[1]=o+=r):r<0?(i[1]=a,i[0]=a+=r):i[0]=o},gU=function(t,e){if((n=t.length)>0){for(var n,i=0,r=t[e[0]],o=r.length;i<o;++i){for(var a=0,s=0;a<n;++a)s+=t[a][i][1]||0;r[i][1]+=r[i][0]=-s/2}uU(t,e)}},vU=function(t,e){if((r=t.length)>0&&(i=(n=t[e[0]]).length)>0){for(var n,i,r,o=0,a=1;a<i;++a){for(var s=0,c=0,l=0;s<r;++s){for(var u=t[e[s]],h=u[a][1]||0,d=(h-(u[a-1][1]||0))/2,f=0;f<s;++f){var p=t[e[f]];d+=(p[a][1]||0)-(p[a-1][1]||0)}c+=h,l+=d*h}n[a-1][1]+=n[a-1][0]=o,c&&(o-=l/c)}n[a-1][1]+=n[a-1][0]=o,uU(t,e)}},bU=function(t){var e=t.map(yU);return hU(t).sort((function(t,n){return e[t]-e[n]}))};function yU(t){for(var e,n=0,i=-1,r=t.length;++i<r;)(e=+t[i][1])&&(n+=e);return n}var _U=function(t){return bU(t).reverse()},wU=function(t){var e,n,i=t.length,r=t.map(yU),o=hU(t).sort((function(t,e){return r[e]-r[t]})),a=0,s=0,c=[],l=[];for(e=0;e<i;++e)n=o[e],a<s?(a+=r[n],c.push(n)):(s+=r[n],l.push(n));return l.reverse().concat(c)},kU=function(t){return hU(t).reverse()},CU=new Date,SU=new Date;function xU(t,e,n,i){function r(e){return t(e=new Date(+e)),e}return r.floor=r,r.ceil=function(n){return t(n=new Date(n-1)),e(n,1),t(n),n},r.round=function(t){var e=r(t),n=r.ceil(t);return t-e<n-t?e:n},r.offset=function(t,n){return e(t=new Date(+t),null==n?1:Math.floor(n)),t},r.range=function(n,i,o){var a,s=[];if(n=r.ceil(n),o=null==o?1:Math.floor(o),!(n<i&&o>0))return s;do{s.push(a=new Date(+n)),e(n,o),t(n)}while(a<n&&n<i);return s},r.filter=function(n){return xU((function(e){if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),(function(t,i){if(t>=t)if(i<0)for(;++i<=0;)for(;e(t,-1),!n(t););else for(;--i>=0;)for(;e(t,1),!n(t););}))},n&&(r.count=function(e,i){return CU.setTime(+e),SU.setTime(+i),t(CU),t(SU),Math.floor(n(CU,SU))},r.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?r.filter(i?function(e){return i(e)%t==0}:function(e){return r.count(0,e)%t==0}):r:null}),r}var OU=xU((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t}));OU.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?xU((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,n){e.setTime(+e+n*t)}),(function(e,n){return(n-e)/t})):OU:null};var MU=OU,TU=OU.range,EU=xU((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+1e3*e)}),(function(t,e){return(e-t)/1e3}),(function(t){return t.getUTCSeconds()})),PU=EU,AU=EU.range,jU=xU((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getMinutes()})),IU=jU,DU=jU.range,RU=xU((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getHours()})),LU=RU,FU=RU.range,NU=xU((function(t){t.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/864e5}),(function(t){return t.getDate()-1})),BU=NU,HU=NU.range;function zU(t){return xU((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var VU=zU(0),UU=zU(1),qU=zU(2),GU=zU(3),WU=zU(4),KU=zU(5),XU=zU(6),YU=VU.range,ZU=UU.range,QU=qU.range,$U=GU.range,JU=WU.range,tq=KU.range,eq=XU.range,nq=xU((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()})),iq=nq,rq=nq.range,oq=xU((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));oq.every=function(t){return isFinite(t=Math.floor(t))&&t>0?xU((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,n){e.setFullYear(e.getFullYear()+n*t)})):null};var aq=oq,sq=oq.range,cq=xU((function(t){t.setUTCSeconds(0,0)}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getUTCMinutes()})),lq=cq,uq=cq.range,hq=xU((function(t){t.setUTCMinutes(0,0,0)}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getUTCHours()})),dq=hq,fq=hq.range,pq=xU((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/864e5}),(function(t){return t.getUTCDate()-1})),mq=pq,gq=pq.range;function vq(t){return xU((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/6048e5}))}var bq=vq(0),yq=vq(1),_q=vq(2),wq=vq(3),kq=vq(4),Cq=vq(5),Sq=vq(6),xq=bq.range,Oq=yq.range,Mq=_q.range,Tq=wq.range,Eq=kq.range,Pq=Cq.range,Aq=Sq.range,jq=xU((function(t){t.setUTCDate(1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCMonth(t.getUTCMonth()+e)}),(function(t,e){return e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear())}),(function(t){return t.getUTCMonth()})),Iq=jq,Dq=jq.range,Rq=xU((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()}));Rq.every=function(t){return isFinite(t=Math.floor(t))&&t>0?xU((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,n){e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null};var Lq=Rq,Fq=Rq.range;function Nq(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function Bq(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function Hq(t){return{y:t,m:0,d:1,H:0,M:0,S:0,L:0}}function zq(t){var e=t.dateTime,n=t.date,i=t.time,r=t.periods,o=t.days,a=t.shortDays,s=t.months,c=t.shortMonths,l=Jq(r),u=tG(r),h=Jq(o),d=tG(o),f=Jq(a),p=tG(a),m=Jq(s),g=tG(s),v=Jq(c),b=tG(c),y={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return c[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:_G,e:_G,f:xG,H:wG,I:kG,j:CG,L:SG,m:OG,M:MG,p:function(t){return r[+(t.getHours()>=12)]},Q:eW,s:nW,S:TG,u:EG,U:PG,V:AG,w:jG,W:IG,x:null,X:null,y:DG,Y:RG,Z:LG,"%":tW},_={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return c[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:FG,e:FG,f:VG,H:NG,I:BG,j:HG,L:zG,m:UG,M:qG,p:function(t){return r[+(t.getUTCHours()>=12)]},Q:eW,s:nW,S:GG,u:WG,U:KG,V:XG,w:YG,W:ZG,x:null,X:null,y:QG,Y:$G,Z:JG,"%":tW},w={a:function(t,e,n){var i=f.exec(e.slice(n));return i?(t.w=p[i[0].toLowerCase()],n+i[0].length):-1},A:function(t,e,n){var i=h.exec(e.slice(n));return i?(t.w=d[i[0].toLowerCase()],n+i[0].length):-1},b:function(t,e,n){var i=v.exec(e.slice(n));return i?(t.m=b[i[0].toLowerCase()],n+i[0].length):-1},B:function(t,e,n){var i=m.exec(e.slice(n));return i?(t.m=g[i[0].toLowerCase()],n+i[0].length):-1},c:function(t,n,i){return S(t,e,n,i)},d:uG,e:uG,f:gG,H:dG,I:dG,j:hG,L:mG,m:lG,M:fG,p:function(t,e,n){var i=l.exec(e.slice(n));return i?(t.p=u[i[0].toLowerCase()],n+i[0].length):-1},Q:bG,s:yG,S:pG,u:nG,U:iG,V:rG,w:eG,W:oG,x:function(t,e,i){return S(t,n,e,i)},X:function(t,e,n){return S(t,i,e,n)},y:sG,Y:aG,Z:cG,"%":vG};function k(t,e){return function(n){var i,r,o,a=[],s=-1,c=0,l=t.length;for(n instanceof Date||(n=new Date(+n));++s<l;)37===t.charCodeAt(s)&&(a.push(t.slice(c,s)),null!=(r=Kq[i=t.charAt(++s)])?i=t.charAt(++s):r="e"===i?" ":"0",(o=e[i])&&(i=o(n,r)),a.push(i),c=s+1);return a.push(t.slice(c,s)),a.join("")}}function C(t,e){return function(n){var i,r,o=Hq(1900);if(S(o,t,n+="",0)!=n.length)return null;if("Q"in o)return new Date(o.Q);if("p"in o&&(o.H=o.H%12+12*o.p),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(r=(i=Bq(Hq(o.y))).getUTCDay(),i=r>4||0===r?AL.ceil(i):AL(i),i=IL.offset(i,7*(o.V-1)),o.y=i.getUTCFullYear(),o.m=i.getUTCMonth(),o.d=i.getUTCDate()+(o.w+6)%7):(r=(i=e(Hq(o.y))).getDay(),i=r>4||0===r?wL.ceil(i):wL(i),i=CL.offset(i,7*(o.V-1)),o.y=i.getFullYear(),o.m=i.getMonth(),o.d=i.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),r="Z"in o?Bq(Hq(o.y)).getUTCDay():e(Hq(o.y)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(r+5)%7:o.w+7*o.U-(r+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,Bq(o)):e(o)}}function S(t,e,n,i){for(var r,o,a=0,s=e.length,c=n.length;a<s;){if(i>=c)return-1;if(37===(r=e.charCodeAt(a++))){if(r=e.charAt(a++),!(o=w[r in Kq?e.charAt(a++):r])||(i=o(t,n,i))<0)return-1}else if(r!=n.charCodeAt(i++))return-1}return i}return y.x=k(n,y),y.X=k(i,y),y.c=k(e,y),_.x=k(n,_),_.X=k(i,_),_.c=k(e,_),{format:function(t){var e=k(t+="",y);return e.toString=function(){return t},e},parse:function(t){var e=C(t+="",Nq);return e.toString=function(){return t},e},utcFormat:function(t){var e=k(t+="",_);return e.toString=function(){return t},e},utcParse:function(t){var e=C(t,Bq);return e.toString=function(){return t},e}}}var Vq,Uq,qq,Gq,Wq,Kq={"-":"",_:" ",0:"0"},Xq=/^\s*\d+/,Yq=/^%/,Zq=/[\\^$*+?|[\]().{}]/g;function Qq(t,e,n){var i=t<0?"-":"",r=(i?-t:t)+"",o=r.length;return i+(o<n?new Array(n-o+1).join(e)+r:r)}function $q(t){return t.replace(Zq,"\\$&")}function Jq(t){return new RegExp("^(?:"+t.map($q).join("|")+")","i")}function tG(t){for(var e={},n=-1,i=t.length;++n<i;)e[t[n].toLowerCase()]=n;return e}function eG(t,e,n){var i=Xq.exec(e.slice(n,n+1));return i?(t.w=+i[0],n+i[0].length):-1}function nG(t,e,n){var i=Xq.exec(e.slice(n,n+1));return i?(t.u=+i[0],n+i[0].length):-1}function iG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.U=+i[0],n+i[0].length):-1}function rG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.V=+i[0],n+i[0].length):-1}function oG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.W=+i[0],n+i[0].length):-1}function aG(t,e,n){var i=Xq.exec(e.slice(n,n+4));return i?(t.y=+i[0],n+i[0].length):-1}function sG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.y=+i[0]+(+i[0]>68?1900:2e3),n+i[0].length):-1}function cG(t,e,n){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return i?(t.Z=i[1]?0:-(i[2]+(i[3]||"00")),n+i[0].length):-1}function lG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.m=i[0]-1,n+i[0].length):-1}function uG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.d=+i[0],n+i[0].length):-1}function hG(t,e,n){var i=Xq.exec(e.slice(n,n+3));return i?(t.m=0,t.d=+i[0],n+i[0].length):-1}function dG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.H=+i[0],n+i[0].length):-1}function fG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.M=+i[0],n+i[0].length):-1}function pG(t,e,n){var i=Xq.exec(e.slice(n,n+2));return i?(t.S=+i[0],n+i[0].length):-1}function mG(t,e,n){var i=Xq.exec(e.slice(n,n+3));return i?(t.L=+i[0],n+i[0].length):-1}function gG(t,e,n){var i=Xq.exec(e.slice(n,n+6));return i?(t.L=Math.floor(i[0]/1e3),n+i[0].length):-1}function vG(t,e,n){var i=Yq.exec(e.slice(n,n+1));return i?n+i[0].length:-1}function bG(t,e,n){var i=Xq.exec(e.slice(n));return i?(t.Q=+i[0],n+i[0].length):-1}function yG(t,e,n){var i=Xq.exec(e.slice(n));return i?(t.Q=1e3*+i[0],n+i[0].length):-1}function _G(t,e){return Qq(t.getDate(),e,2)}function wG(t,e){return Qq(t.getHours(),e,2)}function kG(t,e){return Qq(t.getHours()%12||12,e,2)}function CG(t,e){return Qq(1+CL.count(vL(t),t),e,3)}function SG(t,e){return Qq(t.getMilliseconds(),e,3)}function xG(t,e){return SG(t,e)+"000"}function OG(t,e){return Qq(t.getMonth()+1,e,2)}function MG(t,e){return Qq(t.getMinutes(),e,2)}function TG(t,e){return Qq(t.getSeconds(),e,2)}function EG(t){var e=t.getDay();return 0===e?7:e}function PG(t,e){return Qq(_L.count(vL(t),t),e,2)}function AG(t,e){var n=t.getDay();return t=n>=4||0===n?kL(t):kL.ceil(t),Qq(kL.count(vL(t),t)+(4===vL(t).getDay()),e,2)}function jG(t){return t.getDay()}function IG(t,e){return Qq(wL.count(vL(t),t),e,2)}function DG(t,e){return Qq(t.getFullYear()%100,e,2)}function RG(t,e){return Qq(t.getFullYear()%1e4,e,4)}function LG(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Qq(e/60|0,"0",2)+Qq(e%60,"0",2)}function FG(t,e){return Qq(t.getUTCDate(),e,2)}function NG(t,e){return Qq(t.getUTCHours(),e,2)}function BG(t,e){return Qq(t.getUTCHours()%12||12,e,2)}function HG(t,e){return Qq(1+IL.count(RL(t),t),e,3)}function zG(t,e){return Qq(t.getUTCMilliseconds(),e,3)}function VG(t,e){return zG(t,e)+"000"}function UG(t,e){return Qq(t.getUTCMonth()+1,e,2)}function qG(t,e){return Qq(t.getUTCMinutes(),e,2)}function GG(t,e){return Qq(t.getUTCSeconds(),e,2)}function WG(t){var e=t.getUTCDay();return 0===e?7:e}function KG(t,e){return Qq(PL.count(RL(t),t),e,2)}function XG(t,e){var n=t.getUTCDay();return t=n>=4||0===n?jL(t):jL.ceil(t),Qq(jL.count(RL(t),t)+(4===RL(t).getUTCDay()),e,2)}function YG(t){return t.getUTCDay()}function ZG(t,e){return Qq(AL.count(RL(t),t),e,2)}function QG(t,e){return Qq(t.getUTCFullYear()%100,e,2)}function $G(t,e){return Qq(t.getUTCFullYear()%1e4,e,4)}function JG(){return"+0000"}function tW(){return"%"}function eW(t){return+t}function nW(t){return Math.floor(+t/1e3)}function iW(t){return Vq=zq(t),Uq=Vq.format,qq=Vq.parse,Gq=Vq.utcFormat,Wq=Vq.utcParse,Vq}iW({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});var rW=Date.prototype.toISOString?function(t){return t.toISOString()}:Gq("%Y-%m-%dT%H:%M:%S.%LZ"),oW=+new Date("2000-01-01T00:00:00.000Z")?function(t){var e=new Date(t);return isNaN(e)?null:e}:Wq("%Y-%m-%dT%H:%M:%S.%LZ"),aW=function(t,e,n){var i=new rC,r=e;return null==e?(i.restart(t,e,n),i):(e=+e,n=null==n?nC():+n,i.restart((function o(a){a+=r,i.restart(o,r+=e,n),t(a)}),e,n),i)},sW=D_("start","end","interrupt"),cW=[],lW=function(t,e,n,i,r,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var i,r=t.__transition;function o(c){var l,u,h,d;if(1!==n.state)return s();for(l in r)if((d=r[l]).name===n.name){if(3===d.state)return uC(o);4===d.state?(d.state=6,d.timer.stop(),d.on.call("interrupt",t,t.__data__,d.index,d.group),delete r[l]):+l<e&&(d.state=6,d.timer.stop(),delete r[l])}if(uC((function(){3===n.state&&(n.state=4,n.timer.restart(a,n.delay,n.time),a(c))})),n.state=2,n.on.call("start",t,t.__data__,n.index,n.group),2===n.state){for(n.state=3,i=new Array(h=n.tween.length),l=0,u=-1;l<h;++l)(d=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(i[++u]=d);i.length=u+1}}function a(e){for(var r=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(s),n.state=5,1),o=-1,a=i.length;++o<a;)i[o].call(null,r);5===n.state&&(n.on.call("end",t,t.__data__,n.index,n.group),s())}function s(){for(var i in n.state=6,n.timer.stop(),delete r[e],r)return;delete t.__transition}r[e]=n,n.timer=oC((function(t){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=t&&o(t-n.delay)}),0,n.time)}(t,n,{name:e,index:i,group:r,on:sW,tween:cW,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})};function uW(t,e){var n=dW(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function hW(t,e){var n=dW(t,e);if(n.state>2)throw new Error("too late; already started");return n}function dW(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}var fW=function(t,e){var n,i,r,o=t.__transition,a=!0;if(o){for(r in e=null==e?null:e+"",o)(n=o[r]).name===e?(i=n.state>2&&n.state<5,n.state=6,n.timer.stop(),i&&n.on.call("interrupt",t,t.__data__,n.index,n.group),delete o[r]):a=!1;a&&delete t.__transition}};function pW(t,e){var n,i;return function(){var r=hW(this,t),o=r.tween;if(o!==n)for(var a=0,s=(i=n=o).length;a<s;++a)if(i[a].name===e){(i=i.slice()).splice(a,1);break}r.tween=i}}function mW(t,e,n){var i,r;if("function"!=typeof n)throw new Error;return function(){var o=hW(this,t),a=o.tween;if(a!==i){r=(i=a).slice();for(var s={name:e,value:n},c=0,l=r.length;c<l;++c)if(r[c].name===e){r[c]=s;break}c===l&&r.push(s)}o.tween=r}}function gW(t,e,n){var i=t._id;return t.each((function(){var t=hW(this,i);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return dW(t,i).value[e]}}var vW=function(t,e){var n;return("number"==typeof e?Bk:e instanceof fk?Ak:(n=fk(e))?(e=n,Ak):Uk)(t,e)};function bW(t){return function(){this.removeAttribute(t)}}function yW(t){return function(){this.removeAttributeNS(t.space,t.local)}}function _W(t,e,n){var i,r;return function(){var o=this.getAttribute(t);return o===n?null:o===i?r:r=e(i=o,n)}}function wW(t,e,n){var i,r;return function(){var o=this.getAttributeNS(t.space,t.local);return o===n?null:o===i?r:r=e(i=o,n)}}function kW(t,e,n){var i,r,o;return function(){var a,s=n(this);if(null!=s)return(a=this.getAttribute(t))===s?null:a===i&&s===r?o:o=e(i=a,r=s);this.removeAttribute(t)}}function CW(t,e,n){var i,r,o;return function(){var a,s=n(this);if(null!=s)return(a=this.getAttributeNS(t.space,t.local))===s?null:a===i&&s===r?o:o=e(i=a,r=s);this.removeAttributeNS(t.space,t.local)}}function SW(t,e){function n(){var n=this,i=e.apply(n,arguments);return i&&function(e){n.setAttributeNS(t.space,t.local,i(e))}}return n._value=e,n}function xW(t,e){function n(){var n=this,i=e.apply(n,arguments);return i&&function(e){n.setAttribute(t,i(e))}}return n._value=e,n}function OW(t,e){return function(){uW(this,t).delay=+e.apply(this,arguments)}}function MW(t,e){return e=+e,function(){uW(this,t).delay=e}}function TW(t,e){return function(){hW(this,t).duration=+e.apply(this,arguments)}}function EW(t,e){return e=+e,function(){hW(this,t).duration=e}}function PW(t,e){if("function"!=typeof e)throw new Error;return function(){hW(this,t).ease=e}}function AW(t,e,n){var i,r,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?uW:hW;return function(){var a=o(this,t),s=a.on;s!==i&&(r=(i=s).copy()).on(e,n),a.on=r}}var jW=Gw.prototype.constructor;function IW(t,e,n){function i(){var i=this,r=e.apply(i,arguments);return r&&function(e){i.style.setProperty(t,r(e),n)}}return i._value=e,i}var DW=0;function RW(t,e,n,i){this._groups=t,this._parents=e,this._name=n,this._id=i}function LW(t){return Gw().transition(t)}function FW(){return++DW}var NW=Gw.prototype;RW.prototype=LW.prototype={constructor:RW,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=L_(t));for(var i=this._groups,r=i.length,o=new Array(r),a=0;a<r;++a)for(var s,c,l=i[a],u=l.length,h=o[a]=new Array(u),d=0;d<u;++d)(s=l[d])&&(c=t.call(s,s.__data__,d,l))&&("__data__"in s&&(c.__data__=s.__data__),h[d]=c,lW(h[d],e,n,d,h,dW(s,n)));return new RW(o,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=N_(t));for(var i=this._groups,r=i.length,o=[],a=[],s=0;s<r;++s)for(var c,l=i[s],u=l.length,h=0;h<u;++h)if(c=l[h]){for(var d,f=t.call(c,c.__data__,h,l),p=dW(c,n),m=0,g=f.length;m<g;++m)(d=f[m])&&lW(d,e,n,m,f,p);o.push(f),a.push(c)}return new RW(o,a,e,n)},filter:function(t){"function"!=typeof t&&(t=B_(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o,a=e[r],s=a.length,c=i[r]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&c.push(o);return new RW(i,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,i=e.length,r=Math.min(i,n.length),o=new Array(i),a=0;a<r;++a)for(var s,c=e[a],l=n[a],u=c.length,h=o[a]=new Array(u),d=0;d<u;++d)(s=c[d]||l[d])&&(h[d]=s);for(;a<i;++a)o[a]=e[a];return new RW(o,this._parents,this._name,this._id)},selection:function(){return new jW(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=FW(),i=this._groups,r=i.length,o=0;o<r;++o)for(var a,s=i[o],c=s.length,l=0;l<c;++l)if(a=s[l]){var u=dW(a,e);lW(a,t,n,l,s,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new RW(i,this._parents,t,n)},call:NW.call,nodes:NW.nodes,node:NW.node,size:NW.size,empty:NW.empty,each:NW.each,on:function(t,e){var n=this._id;return arguments.length<2?dW(this.node(),n).on.on(t):this.each(AW(n,t,e))},attr:function(t,e){var n=K_(t),i="transform"===n?MC:vW;return this.attrTween(t,"function"==typeof e?(n.local?CW:kW)(n,i,gW(this,"attr."+t,e)):null==e?(n.local?yW:bW)(n):(n.local?wW:_W)(n,i,e+""))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var i=K_(t);return this.tween(n,(i.local?SW:xW)(i,e))},style:function(t,e,n){var i="transform"==(t+="")?OC:vW;return null==e?this.styleTween(t,function(t,e){var n,i,r;return function(){var o=rw(this,t),a=(this.style.removeProperty(t),rw(this,t));return o===a?null:o===n&&a===i?r:r=e(n=o,i=a)}}(t,i)).on("end.style."+t,function(t){return function(){this.style.removeProperty(t)}}(t)):this.styleTween(t,"function"==typeof e?function(t,e,n){var i,r,o;return function(){var a=rw(this,t),s=n(this);return null==s&&(this.style.removeProperty(t),s=rw(this,t)),a===s?null:a===i&&s===r?o:o=e(i=a,r=s)}}(t,i,gW(this,"style."+t,e)):function(t,e,n){var i,r;return function(){var o=rw(this,t);return o===n?null:o===i?r:r=e(i=o,n)}}(t,i,e+""),n)},styleTween:function(t,e,n){var i="style."+(t+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(null==e)return this.tween(i,null);if("function"!=typeof e)throw new Error;return this.tween(i,IW(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(gW(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},remove:function(){return this.on("end.remove",(t=this._id,function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}));var t},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var i,r=dW(this.node(),n).tween,o=0,a=r.length;o<a;++o)if((i=r[o]).name===t)return i.value;return null}return this.each((null==e?pW:mW)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?OW:MW)(e,t)):dW(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?TW:EW)(e,t)):dW(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(PW(e,t)):dW(this.node(),e).ease}};var BW={time:null,delay:0,duration:250,ease:sS};function HW(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))return BW.time=nC(),BW;return n}Gw.prototype.interrupt=function(t){return this.each((function(){fW(this,t)}))},Gw.prototype.transition=function(t){var e,n;t instanceof RW?(e=t._id,t=t._name):(e=FW(),(n=BW).time=nC(),t=null==t?null:t+"");for(var i=this._groups,r=i.length,o=0;o<r;++o)for(var a,s=i[o],c=s.length,l=0;l<c;++l)(a=s[l])&&lW(a,t,e,l,s,n||HW(a,e));return new RW(i,this._parents,t,e)};var zW=[null],VW=function(t,e){var n,i,r=t.__transition;if(r)for(i in e=null==e?null:e+"",r)if((n=r[i]).state>1&&n.name===e)return new RW([[t]],zW,e,+i);return null},UW=function(t){return function(){return t}};function qW(t){return t[0]}function GW(t){return t[1]}function WW(){this._=null}function KW(t){t.U=t.C=t.L=t.R=t.P=t.N=null}function XW(t,e){var n=e,i=e.R,r=n.U;r?r.L===n?r.L=i:r.R=i:t._=i,i.U=r,n.U=i,n.R=i.L,n.R&&(n.R.U=n),i.L=n}function YW(t,e){var n=e,i=e.L,r=n.U;r?r.L===n?r.L=i:r.R=i:t._=i,i.U=r,n.U=i,n.L=i.R,n.L&&(n.L.U=n),i.R=n}function ZW(t){for(;t.L;)t=t.L;return t}WW.prototype={constructor:WW,insert:function(t,e){var n,i,r;if(t){if(e.P=t,e.N=t.N,t.N&&(t.N.P=e),t.N=e,t.R){for(t=t.R;t.L;)t=t.L;t.L=e}else t.R=e;n=t}else this._?(t=ZW(this._),e.P=null,e.N=t,t.P=t.L=e,n=t):(e.P=e.N=null,this._=e,n=null);for(e.L=e.R=null,e.U=n,e.C=!0,t=e;n&&n.C;)n===(i=n.U).L?(r=i.R)&&r.C?(n.C=r.C=!1,i.C=!0,t=i):(t===n.R&&(XW(this,n),n=(t=n).U),n.C=!1,i.C=!0,YW(this,i)):(r=i.L)&&r.C?(n.C=r.C=!1,i.C=!0,t=i):(t===n.L&&(YW(this,n),n=(t=n).U),n.C=!1,i.C=!0,XW(this,i)),n=t.U;this._.C=!1},remove:function(t){t.N&&(t.N.P=t.P),t.P&&(t.P.N=t.N),t.N=t.P=null;var e,n,i,r=t.U,o=t.L,a=t.R;if(n=o?a?ZW(a):o:a,r?r.L===t?r.L=n:r.R=n:this._=n,o&&a?(i=n.C,n.C=t.C,n.L=o,o.U=n,n!==a?(r=n.U,n.U=t.U,r.L=t=n.R,n.R=a,a.U=n):(n.U=r,r=n,t=n.R)):(i=t.C,t=n),t&&(t.U=r),!i)if(t&&t.C)t.C=!1;else{do{if(t===this._)break;if(t===r.L){if((e=r.R).C&&(e.C=!1,r.C=!0,XW(this,r),e=r.R),e.L&&e.L.C||e.R&&e.R.C){e.R&&e.R.C||(e.L.C=!1,e.C=!0,YW(this,e),e=r.R),e.C=r.C,r.C=e.R.C=!1,XW(this,r),t=this._;break}}else if((e=r.L).C&&(e.C=!1,r.C=!0,YW(this,r),e=r.L),e.L&&e.L.C||e.R&&e.R.C){e.L&&e.L.C||(e.R.C=!1,e.C=!0,XW(this,e),e=r.L),e.C=r.C,r.C=e.L.C=!1,YW(this,r),t=this._;break}e.C=!0,t=r,r=r.U}while(!t.C);t&&(t.C=!1)}}};var QW=WW;function $W(t,e,n,i){var r=[null,null],o=kK.push(r)-1;return r.left=t,r.right=e,n&&tK(r,t,e,n),i&&tK(r,e,t,i),_K[t.index].halfedges.push(o),_K[e.index].halfedges.push(o),r}function JW(t,e,n){var i=[e,n];return i.left=t,i}function tK(t,e,n,i){t[0]||t[1]?t.left===n?t[1]=i:t[0]=i:(t[0]=i,t.left=e,t.right=n)}function eK(t,e,n,i,r){var o,a=t[0],s=t[1],c=a[0],l=a[1],u=0,h=1,d=s[0]-c,f=s[1]-l;if(o=e-c,d||!(o>0)){if(o/=d,d<0){if(o<u)return;o<h&&(h=o)}else if(d>0){if(o>h)return;o>u&&(u=o)}if(o=i-c,d||!(o<0)){if(o/=d,d<0){if(o>h)return;o>u&&(u=o)}else if(d>0){if(o<u)return;o<h&&(h=o)}if(o=n-l,f||!(o>0)){if(o/=f,f<0){if(o<u)return;o<h&&(h=o)}else if(f>0){if(o>h)return;o>u&&(u=o)}if(o=r-l,f||!(o<0)){if(o/=f,f<0){if(o>h)return;o>u&&(u=o)}else if(f>0){if(o<u)return;o<h&&(h=o)}return!(u>0||h<1)||(u>0&&(t[0]=[c+u*d,l+u*f]),h<1&&(t[1]=[c+h*d,l+h*f]),!0)}}}}}function nK(t,e,n,i,r){var o=t[1];if(o)return!0;var a,s,c=t[0],l=t.left,u=t.right,h=l[0],d=l[1],f=u[0],p=u[1],m=(h+f)/2;if(p===d){if(m<e||m>=i)return;if(h>f){if(c){if(c[1]>=r)return}else c=[m,n];o=[m,r]}else{if(c){if(c[1]<n)return}else c=[m,r];o=[m,n]}}else if(s=(d+p)/2-(a=(h-f)/(p-d))*m,a<-1||a>1)if(h>f){if(c){if(c[1]>=r)return}else c=[(n-s)/a,n];o=[(r-s)/a,r]}else{if(c){if(c[1]<n)return}else c=[(r-s)/a,r];o=[(n-s)/a,n]}else if(d<p){if(c){if(c[0]>=i)return}else c=[e,a*e+s];o=[i,a*i+s]}else{if(c){if(c[0]<e)return}else c=[i,a*i+s];o=[e,a*e+s]}return t[0]=c,t[1]=o,!0}function iK(t,e){var n=t.site,i=e.left,r=e.right;return n===r&&(r=i,i=n),r?Math.atan2(r[1]-i[1],r[0]-i[0]):(n===i?(i=e[1],r=e[0]):(i=e[0],r=e[1]),Math.atan2(i[0]-r[0],r[1]-i[1]))}function rK(t,e){return e[+(e.left!==t.site)]}function oK(t,e){return e[+(e.left===t.site)]}var aK,sK=[];function cK(){KW(this),this.x=this.y=this.arc=this.site=this.cy=null}function lK(t){var e=t.P,n=t.N;if(e&&n){var i=e.site,r=t.site,o=n.site;if(i!==o){var a=r[0],s=r[1],c=i[0]-a,l=i[1]-s,u=o[0]-a,h=o[1]-s,d=2*(c*h-l*u);if(!(d>=-SK)){var f=c*c+l*l,p=u*u+h*h,m=(h*f-l*p)/d,g=(c*p-u*f)/d,v=sK.pop()||new cK;v.arc=t,v.site=r,v.x=m+a,v.y=(v.cy=g+s)+Math.sqrt(m*m+g*g),t.circle=v;for(var b=null,y=wK._;y;)if(v.y<y.y||v.y===y.y&&v.x<=y.x){if(!y.L){b=y.P;break}y=y.L}else{if(!y.R){b=y;break}y=y.R}wK.insert(b,v),b||(aK=v)}}}}function uK(t){var e=t.circle;e&&(e.P||(aK=e.N),wK.remove(e),sK.push(e),KW(e),t.circle=null)}var hK=[];function dK(){KW(this),this.edge=this.site=this.circle=null}function fK(t){var e=hK.pop()||new dK;return e.site=t,e}function pK(t){uK(t),yK.remove(t),hK.push(t),KW(t)}function mK(t){var e=t.circle,n=e.x,i=e.cy,r=[n,i],o=t.P,a=t.N,s=[t];pK(t);for(var c=o;c.circle&&Math.abs(n-c.circle.x)<CK&&Math.abs(i-c.circle.cy)<CK;)o=c.P,s.unshift(c),pK(c),c=o;s.unshift(c),uK(c);for(var l=a;l.circle&&Math.abs(n-l.circle.x)<CK&&Math.abs(i-l.circle.cy)<CK;)a=l.N,s.push(l),pK(l),l=a;s.push(l),uK(l);var u,h=s.length;for(u=1;u<h;++u)tK((l=s[u]).edge,(c=s[u-1]).site,l.site,r);(l=s[h-1]).edge=$W((c=s[0]).site,l.site,null,r),lK(c),lK(l)}function gK(t){for(var e,n,i,r,o=t[0],a=t[1],s=yK._;s;)if((i=vK(s,a)-o)>CK)s=s.L;else{if(!((r=o-bK(s,a))>CK)){i>-CK?(e=s.P,n=s):r>-CK?(e=s,n=s.N):e=n=s;break}if(!s.R){e=s;break}s=s.R}!function(t){_K[t.index]={site:t,halfedges:[]}}(t);var c=fK(t);if(yK.insert(e,c),e||n){if(e===n)return uK(e),n=fK(e.site),yK.insert(c,n),c.edge=n.edge=$W(e.site,c.site),lK(e),void lK(n);if(n){uK(e),uK(n);var l=e.site,u=l[0],h=l[1],d=t[0]-u,f=t[1]-h,p=n.site,m=p[0]-u,g=p[1]-h,v=2*(d*g-f*m),b=d*d+f*f,y=m*m+g*g,_=[(g*b-f*y)/v+u,(d*y-m*b)/v+h];tK(n.edge,l,p,_),c.edge=$W(l,t,null,_),n.edge=$W(t,p,null,_),lK(e),lK(n)}else c.edge=$W(e.site,c.site)}}function vK(t,e){var n=t.site,i=n[0],r=n[1],o=r-e;if(!o)return i;var a=t.P;if(!a)return-1/0;var s=(n=a.site)[0],c=n[1],l=c-e;if(!l)return s;var u=s-i,h=1/o-1/l,d=u/l;return h?(-d+Math.sqrt(d*d-2*h*(u*u/(-2*l)-c+l/2+r-o/2)))/h+i:(i+s)/2}function bK(t,e){var n=t.N;if(n)return vK(n,e);var i=t.site;return i[1]===e?i[0]:1/0}var yK,_K,wK,kK,CK=1e-6,SK=1e-12;function xK(t,e){return e[1]-t[1]||e[0]-t[0]}function OK(t,e){var n,i,r,o=t.sort(xK).pop();for(kK=[],_K=new Array(t.length),yK=new QW,wK=new QW;;)if(r=aK,o&&(!r||o[1]<r.y||o[1]===r.y&&o[0]<r.x))o[0]===n&&o[1]===i||(gK(o),n=o[0],i=o[1]),o=t.pop();else{if(!r)break;mK(r.arc)}if(function(){for(var t,e,n,i,r=0,o=_K.length;r<o;++r)if((t=_K[r])&&(i=(e=t.halfedges).length)){var a=new Array(i),s=new Array(i);for(n=0;n<i;++n)a[n]=n,s[n]=iK(t,kK[e[n]]);for(a.sort((function(t,e){return s[e]-s[t]})),n=0;n<i;++n)s[n]=e[a[n]];for(n=0;n<i;++n)e[n]=s[n]}}(),e){var a=+e[0][0],s=+e[0][1],c=+e[1][0],l=+e[1][1];!function(t,e,n,i){for(var r,o=kK.length;o--;)nK(r=kK[o],t,e,n,i)&&eK(r,t,e,n,i)&&(Math.abs(r[0][0]-r[1][0])>CK||Math.abs(r[0][1]-r[1][1])>CK)||delete kK[o]}(a,s,c,l),function(t,e,n,i){var r,o,a,s,c,l,u,h,d,f,p,m,g=_K.length,v=!0;for(r=0;r<g;++r)if(o=_K[r]){for(a=o.site,s=(c=o.halfedges).length;s--;)kK[c[s]]||c.splice(s,1);for(s=0,l=c.length;s<l;)p=(f=oK(o,kK[c[s]]))[0],m=f[1],h=(u=rK(o,kK[c[++s%l]]))[0],d=u[1],(Math.abs(p-h)>CK||Math.abs(m-d)>CK)&&(c.splice(s,0,kK.push(JW(a,f,Math.abs(p-t)<CK&&i-m>CK?[t,Math.abs(h-t)<CK?d:i]:Math.abs(m-i)<CK&&n-p>CK?[Math.abs(d-i)<CK?h:n,i]:Math.abs(p-n)<CK&&m-e>CK?[n,Math.abs(h-n)<CK?d:e]:Math.abs(m-e)<CK&&p-t>CK?[Math.abs(d-e)<CK?h:t,e]:null))-1),++l);l&&(v=!1)}if(v){var b,y,_,w=1/0;for(r=0,v=null;r<g;++r)(o=_K[r])&&(_=(b=(a=o.site)[0]-t)*b+(y=a[1]-e)*y)<w&&(w=_,v=o);if(v){var k=[t,e],C=[t,i],S=[n,i],x=[n,e];v.halfedges.push(kK.push(JW(a=v.site,k,C))-1,kK.push(JW(a,C,S))-1,kK.push(JW(a,S,x))-1,kK.push(JW(a,x,k))-1)}}for(r=0;r<g;++r)(o=_K[r])&&(o.halfedges.length||delete _K[r])}(a,s,c,l)}this.edges=kK,this.cells=_K,yK=wK=kK=_K=null}OK.prototype={constructor:OK,polygons:function(){var t=this.edges;return this.cells.map((function(e){var n=e.halfedges.map((function(n){return rK(e,t[n])}));return n.data=e.site.data,n}))},triangles:function(){var t=[],e=this.edges;return this.cells.forEach((function(n,i){if(o=(r=n.halfedges).length)for(var r,o,a,s,c,l,u=n.site,h=-1,d=e[r[o-1]],f=d.left===u?d.right:d.left;++h<o;)a=f,f=(d=e[r[h]]).left===u?d.right:d.left,a&&f&&i<a.index&&i<f.index&&((s=u)[0]-(l=f)[0])*((c=a)[1]-s[1])-(s[0]-c[0])*(l[1]-s[1])<0&&t.push([u.data,a.data,f.data])})),t},links:function(){return this.edges.filter((function(t){return t.right})).map((function(t){return{source:t.left.data,target:t.right.data}}))},find:function(t,e,n){for(var i,r,o=this,a=o._found||0,s=o.cells.length;!(r=o.cells[a]);)if(++a>=s)return null;var c=t-r.site[0],l=e-r.site[1],u=c*c+l*l;do{r=o.cells[i=a],a=null,r.halfedges.forEach((function(n){var i=o.edges[n],s=i.left;if(s!==r.site&&s||(s=i.right)){var c=t-s[0],l=e-s[1],h=c*c+l*l;h<u&&(u=h,a=s.index)}}))}while(null!==a);return o._found=i,null==n||u<=n*n?r.site:null}};var MK=function(){var t=qW,e=GW,n=null;function i(i){return new OK(i.map((function(n,r){var o=[Math.round(t(n,r,i)/CK)*CK,Math.round(e(n,r,i)/CK)*CK];return o.index=r,o.data=n,o})),n)}return i.polygons=function(t){return i(t).polygons()},i.links=function(t){return i(t).links()},i.triangles=function(t){return i(t).triangles()},i.x=function(e){return arguments.length?(t="function"==typeof e?e:UW(+e),i):t},i.y=function(t){return arguments.length?(e="function"==typeof t?t:UW(+t),i):e},i.extent=function(t){return arguments.length?(n=null==t?null:[[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]],i):n&&[[n[0][0],n[0][1]],[n[1][0],n[1][1]]]},i.size=function(t){return arguments.length?(n=null==t?null:[[0,0],[+t[0],+t[1]]],i):n&&[n[1][0]-n[0][0],n[1][1]-n[0][1]]},i},TK=Math.SQRT2;function EK(t){return((t=Math.exp(t))+1/t)/2}var PK=function(t,e){var n,i,r=t[0],o=t[1],a=t[2],s=e[2],c=e[0]-r,l=e[1]-o,u=c*c+l*l;if(u<1e-12)i=Math.log(s/a)/TK,n=function(t){return[r+t*c,o+t*l,a*Math.exp(TK*t*i)]};else{var h=Math.sqrt(u),d=(s*s-a*a+4*u)/(2*a*2*h),f=(s*s-a*a-4*u)/(2*s*2*h),p=Math.log(Math.sqrt(d*d+1)-d),m=Math.log(Math.sqrt(f*f+1)-f);i=(m-p)/TK,n=function(t){var e,n=t*i,s=EK(p),u=a/(2*h)*(s*(e=TK*n+p,((e=Math.exp(2*e))-1)/(e+1))-function(t){return((t=Math.exp(t))-1/t)/2}(p));return[r+u*c,o+u*l,a*s/EK(TK*n+p)]}}return n.duration=1e3*i,n},AK=function(t){return function(){return t}};function jK(t,e,n){this.target=t,this.type=e,this.transform=n}function IK(t,e,n){this.k=t,this.x=e,this.y=n}IK.prototype={constructor:IK,scale:function(t){return 1===t?this:new IK(this.k*t,this.x,this.y)},translate:function(t,e){return 0===t&0===e?this:new IK(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var DK=new IK(1,0,0);function RK(t){return t.__zoom||DK}function LK(){jw.stopImmediatePropagation()}RK.prototype=IK.prototype;var FK=function(){jw.preventDefault(),jw.stopImmediatePropagation()};function NK(){return!jw.ctrlKey&&!jw.button}function BK(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t).hasAttribute("viewBox")?[[(t=t.viewBox.baseVal).x,t.y],[t.x+t.width,t.y+t.height]]:[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]:[[0,0],[t.clientWidth,t.clientHeight]]}function HK(){return this.__zoom||DK}function zK(){return-jw.deltaY*(1===jw.deltaMode?.05:jw.deltaMode?1:.002)}function VK(){return navigator.maxTouchPoints||"ontouchstart"in this}function UK(t,e,n){var i=t.invertX(e[0][0])-n[0][0],r=t.invertX(e[1][0])-n[1][0],o=t.invertY(e[0][1])-n[0][1],a=t.invertY(e[1][1])-n[1][1];return t.translate(r>i?(i+r)/2:Math.min(0,i)||Math.max(0,r),a>o?(o+a)/2:Math.min(0,o)||Math.max(0,a))}var qK=function(){var t,e,n=NK,i=BK,r=UK,o=zK,a=VK,s=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],l=250,u=PK,h=D_("start","zoom","end"),d=0;function f(t){t.property("__zoom",HK).on("wheel.zoom",_).on("mousedown.zoom",w).on("dblclick.zoom",k).filter(a).on("touchstart.zoom",C).on("touchmove.zoom",S).on("touchend.zoom touchcancel.zoom",x).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function p(t,e){return(e=Math.max(s[0],Math.min(s[1],e)))===t.k?t:new IK(e,t.x,t.y)}function m(t,e,n){var i=e[0]-n[0]*t.k,r=e[1]-n[1]*t.k;return i===t.x&&r===t.y?t:new IK(t.k,i,r)}function g(t){return[(+t[0][0]+ +t[1][0])/2,(+t[0][1]+ +t[1][1])/2]}function v(t,e,n){t.on("start.zoom",(function(){b(this,arguments).start()})).on("interrupt.zoom end.zoom",(function(){b(this,arguments).end()})).tween("zoom",(function(){var t=this,r=arguments,o=b(t,r),a=i.apply(t,r),s=n||g(a),c=Math.max(a[1][0]-a[0][0],a[1][1]-a[0][1]),l=t.__zoom,h="function"==typeof e?e.apply(t,r):e,d=u(l.invert(s).concat(c/l.k),h.invert(s).concat(c/h.k));return function(t){if(1===t)t=h;else{var e=d(t),n=c/e[2];t=new IK(n,s[0]-e[0]*n,s[1]-e[1]*n)}o.zoom(null,t)}}))}function b(t,e,n){return!n&&t.__zooming||new y(t,e)}function y(t,e){this.that=t,this.args=e,this.active=0,this.extent=i.apply(t,e),this.taps=0}function _(){if(n.apply(this,arguments)){var t=b(this,arguments),e=this.__zoom,i=Math.max(s[0],Math.min(s[1],e.k*Math.pow(2,o.apply(this,arguments)))),a=Kk(this);e.k!==i&&(t.wheel?(t.mouse[0][0]===a[0]&&t.mouse[0][1]===a[1]||(t.mouse[1]=e.invert(t.mouse[0]=a)),clearTimeout(t.wheel)):(t.mouse=[a,e.invert(a)],wC(this),t.start()),FK(),t.wheel=setTimeout(l,150),t.zoom("mouse",r(m(p(e,i),t.mouse[0],t.mouse[1]),t.extent,c)))}function l(){t.wheel=null,t.end()}}function w(){if(!e&&n.apply(this,arguments)){var t=b(this,arguments,!0),i=Ww(jw.view).on("mousemove.zoom",l,!0).on("mouseup.zoom",u,!0),o=Kk(this),a=jw.clientX,s=jw.clientY;Yw(jw.view),LK(),t.mouse=[o,this.__zoom.invert(o)],wC(this),t.start()}function l(){if(FK(),!t.moved){var e=jw.clientX-a,n=jw.clientY-s;t.moved=e*e+n*n>d}t.zoom("mouse",r(m(t.that.__zoom,t.mouse[0]=Kk(t.that),t.mouse[1]),t.extent,c))}function u(){i.on("mousemove.zoom mouseup.zoom",null),Zw(jw.view,t.moved),FK(),t.end()}}function k(){if(n.apply(this,arguments)){var t=this.__zoom,e=Kk(this),o=t.invert(e),a=t.k*(jw.shiftKey?.5:2),s=r(m(p(t,a),e,o),i.apply(this,arguments),c);FK(),l>0?Ww(this).transition().duration(l).call(v,s,e):Ww(this).call(f.transform,s)}}function C(){if(n.apply(this,arguments)){var e,i,r,o,a=jw.touches,s=a.length,c=b(this,arguments,jw.changedTouches.length===s);for(LK(),i=0;i<s;++i)o=[o=SO(this,a,(r=a[i]).identifier),this.__zoom.invert(o),r.identifier],c.touch0?c.touch1||(c.touch1=o,c.taps=0):(c.touch0=o,e=!0,c.taps=1+!!t);t&&(t=clearTimeout(t)),e&&(c.taps<2&&(t=setTimeout((function(){t=null}),500)),wC(this),c.start())}}function S(){if(this.__zooming){var e,n,i,o,a=b(this,arguments),s=jw.changedTouches,l=s.length;for(FK(),t&&(t=clearTimeout(t)),a.taps=0,e=0;e<l;++e)i=SO(this,s,(n=s[e]).identifier),a.touch0&&a.touch0[2]===n.identifier?a.touch0[0]=i:a.touch1&&a.touch1[2]===n.identifier&&(a.touch1[0]=i);if(n=a.that.__zoom,a.touch1){var u=a.touch0[0],h=a.touch0[1],d=a.touch1[0],f=a.touch1[1],g=(g=d[0]-u[0])*g+(g=d[1]-u[1])*g,v=(v=f[0]-h[0])*v+(v=f[1]-h[1])*v;n=p(n,Math.sqrt(g/v)),i=[(u[0]+d[0])/2,(u[1]+d[1])/2],o=[(h[0]+f[0])/2,(h[1]+f[1])/2]}else{if(!a.touch0)return;i=a.touch0[0],o=a.touch0[1]}a.zoom("touch",r(m(n,i,o),a.extent,c))}}function x(){if(this.__zooming){var t,n,i=b(this,arguments),r=jw.changedTouches,o=r.length;for(LK(),e&&clearTimeout(e),e=setTimeout((function(){e=null}),500),t=0;t<o;++t)n=r[t],i.touch0&&i.touch0[2]===n.identifier?delete i.touch0:i.touch1&&i.touch1[2]===n.identifier&&delete i.touch1;if(i.touch1&&!i.touch0&&(i.touch0=i.touch1,delete i.touch1),i.touch0)i.touch0[1]=this.__zoom.invert(i.touch0[0]);else if(i.end(),2===i.taps){var a=Ww(this).on("dblclick.zoom");a&&a.apply(this,arguments)}}}return f.transform=function(t,e){var n=t.selection?t.selection():t;n.property("__zoom",HK),t!==n?v(t,e):n.interrupt().each((function(){b(this,arguments).start().zoom(null,"function"==typeof e?e.apply(this,arguments):e).end()}))},f.scaleBy=function(t,e){f.scaleTo(t,(function(){var t=this.__zoom.k,n="function"==typeof e?e.apply(this,arguments):e;return t*n}))},f.scaleTo=function(t,e){f.transform(t,(function(){var t=i.apply(this,arguments),n=this.__zoom,o=g(t),a=n.invert(o),s="function"==typeof e?e.apply(this,arguments):e;return r(m(p(n,s),o,a),t,c)}))},f.translateBy=function(t,e,n){f.transform(t,(function(){return r(this.__zoom.translate("function"==typeof e?e.apply(this,arguments):e,"function"==typeof n?n.apply(this,arguments):n),i.apply(this,arguments),c)}))},f.translateTo=function(t,e,n){f.transform(t,(function(){var t=i.apply(this,arguments),o=this.__zoom,a=g(t);return r(DK.translate(a[0],a[1]).scale(o.k).translate("function"==typeof e?-e.apply(this,arguments):-e,"function"==typeof n?-n.apply(this,arguments):-n),t,c)}))},y.prototype={start:function(){return 1==++this.active&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(t,e){return this.mouse&&"mouse"!==t&&(this.mouse[1]=e.invert(this.mouse[0])),this.touch0&&"touch"!==t&&(this.touch0[1]=e.invert(this.touch0[0])),this.touch1&&"touch"!==t&&(this.touch1[1]=e.invert(this.touch1[0])),this.that.__zoom=e,this.emit("zoom"),this},end:function(){return 0==--this.active&&(delete this.that.__zooming,this.emit("end")),this},emit:function(t){Nw(new jK(f,t,this.that.__zoom),h.apply,h,[t,this.that,this.args])}},f.wheelDelta=function(t){return arguments.length?(o="function"==typeof t?t:AK(+t),f):o},f.filter=function(t){return arguments.length?(n="function"==typeof t?t:AK(!!t),f):n},f.touchable=function(t){return arguments.length?(a="function"==typeof t?t:AK(!!t),f):a},f.extent=function(t){return arguments.length?(i="function"==typeof t?t:AK([[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]]),f):i},f.scaleExtent=function(t){return arguments.length?(s[0]=+t[0],s[1]=+t[1],f):[s[0],s[1]]},f.translateExtent=function(t){return arguments.length?(c[0][0]=+t[0][0],c[1][0]=+t[1][0],c[0][1]=+t[0][1],c[1][1]=+t[1][1],f):[[c[0][0],c[0][1]],[c[1][0],c[1][1]]]},f.constrain=function(t){return arguments.length?(r=t,f):r},f.duration=function(t){return arguments.length?(l=+t,f):l},f.interpolate=function(t){return arguments.length?(u=t,f):u},f.on=function(){var t=h.on.apply(h,arguments);return t===h?f:t},f.clickDistance=function(t){return arguments.length?(d=(t=+t)*t,f):Math.sqrt(d)},f},GK=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"getD3",value:function(){return i}}]),t}();function WK(t,e){if(1&t&&(ga(0,"span",8),ds(1),va()),2&t){var n=e.$implicit;Qi(1),fs(n)}}function KK(t,e){if(1&t&&(ga(0,"tr"),ga(1,"td",5),ua(2,WK,2,1,"span",6),va(),ga(3,"td",7),ds(4),va(),va()),2&t){var n=e.$implicit;Qi(2),pa("ngForOf",n.formatted),Qi(2),fs(n.description)}}n("imBb");var XK,YK=function(t){return{in:t}},ZK=function(){function t(e,n,i,r,o,a){Object(m.a)(this,t),this.combo=e,this.callback=n,this.allowIn=i,this.description=r,this.action=o,this.persistent=a,this.combo=Array.isArray(e)?e:[e],this.allowIn=i||[],this.description=r||""}return Object(g.a)(t,[{key:"formatted",get:function(){if(!this.formattedHotkey){for(var e=this.combo,n=0;n<e.length;n++)e[n]=t.symbolize(e[n]);this.formattedHotkey=e}return this.formattedHotkey}}],[{key:"symbolize",value:function(t){for(var e={command:"\u2318",shift:"\u21e7",left:"\u2190",right:"\u2192",up:"\u2191",down:"\u2193",return:"\u23ce",backspace:"\u232b"},n=t.split("+"),i=0;i<n.length;i++)"mod"===n[i]&&(n[i]=window.navigator&&window.navigator.platform.indexOf("Mac")>=0?"command":"ctrl"),n[i]=e[n[i]]||n[i];return n.join(" + ")}}]),t}(),QK=new ht("HotkeyOptions"),$K=function(){var t=function(){function t(e){Object(m.a)(this,t),this.options=e,this.hotkeys=[],this.pausedHotkeys=[],this.cheatSheetToggle=new w.b,this.preventIn=["INPUT","SELECT","TEXTAREA"],Mousetrap.prototype.stopCallback=function(t,e,n,i){return!((" "+e.className+" ").indexOf(" mousetrap ")>-1)&&e.contentEditable&&"true"===e.contentEditable},this.mousetrap=new Mousetrap,this.options.disableCheatSheet||this.add(new ZK(this.options.cheatSheetHotkey||"?",(function(t){this.cheatSheetToggle.next()}).bind(this),[],this.options.cheatSheetDescription||"Show / hide this help menu")),this.options.cheatSheetCloseEsc&&this.add(new ZK("esc",(function(t){this.cheatSheetToggle.next(!1)}).bind(this),["HOTKEYS-CHEATSHEET"],this.options.cheatSheetCloseEscDescription||"Hide this help menu"))}return Object(g.a)(t,[{key:"add",value:function(t,e){var n=this;if(Array.isArray(t)){var i,r=[],o=d(t);try{for(o.s();!(i=o.n()).done;)r.push(this.add(i.value,e))}catch(a){o.e(a)}finally{o.f()}return r}return this.remove(t),this.hotkeys.push(t),this.mousetrap.bind(t.combo,(function(e,i){var r=!0;if(e){var o=e.target||e.srcElement,a=o.nodeName.toUpperCase();(" "+o.className+" ").indexOf(" mousetrap ")>-1?r=!0:n.preventIn.indexOf(a)>-1&&-1===t.allowIn.map((function(t){return t.toUpperCase()})).indexOf(a)&&(r=!1)}if(r)return t.callback.apply(n,[e,i])}),e),t}},{key:"remove",value:function(t){var e=[];if(!t){var n,i=d(this.hotkeys);try{for(i.s();!(n=i.n()).done;)e.push(this.remove(n.value))}catch(s){i.e(s)}finally{i.f()}return e}if(Array.isArray(t)){var r,o=d(t);try{for(o.s();!(r=o.n()).done;)e.push(this.remove(r.value))}catch(s){o.e(s)}finally{o.f()}return e}var a=this.findHotkey(t);return a>-1?(this.hotkeys.splice(a,1),this.mousetrap.unbind(t.combo),t):null}},{key:"get",value:function(t){if(!t)return this.hotkeys;if(Array.isArray(t)){var e,n=[],i=d(t);try{for(i.s();!(e=i.n()).done;)n.push(this.get(e.value))}catch(s){i.e(s)}finally{i.f()}return n}var r,o=d(this.hotkeys);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(a.combo.indexOf(t)>-1)return a}}catch(s){o.e(s)}finally{o.f()}return null}},{key:"pause",value:function(t){if(!t)return this.pause(this.hotkeys);if(Array.isArray(t)){var e,n=[],i=d(t);try{for(i.s();!(e=i.n()).done;)n.push(this.pause(e.value))}catch(r){i.e(r)}finally{i.f()}return n}return this.remove(t),this.pausedHotkeys.push(t),t}},{key:"unpause",value:function(t){if(!t)return this.unpause(this.pausedHotkeys);if(Array.isArray(t)){var e,n=[],i=d(t);try{for(i.s();!(e=i.n()).done;)n.push(this.unpause(e.value))}catch(o){i.e(o)}finally{i.f()}return n}var r=this.pausedHotkeys.indexOf(t);return r>-1?(this.add(t),this.pausedHotkeys.splice(r,1)):null}},{key:"reset",value:function(){this.mousetrap.reset()}},{key:"findHotkey",value:function(t){return this.hotkeys.indexOf(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(QK))},t.\u0275prov=R({factory:function(){return new t(_t(QK))},token:t,providedIn:"root"}),t}(),JK=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this.hotkeysService=e,this.elementRef=n,this.hotkeysList=[],this.oldHotkeys=[],this.mousetrap=new Mousetrap(this.elementRef.nativeElement)}return Object(g.a)(t,[{key:"ngOnInit",value:function(){var t,e=d(this.hotkeys);try{for(e.s();!(t=e.n()).done;){var n=t.value,i=Object.keys(n)[0],r=new ZK(i,n[i]),o=this.hotkeysService.get(i);null!==o&&(this.oldHotkeys.push(o),this.hotkeysService.remove(o)),this.hotkeysList.push(r),this.mousetrap.bind(r.combo,r.callback)}}catch(a){e.e(a)}finally{e.f()}}},{key:"ngOnDestroy",value:function(){var t,e=d(this.hotkeysList);try{for(e.s();!(t=e.n()).done;)this.mousetrap.unbind(t.value.combo)}catch(n){e.e(n)}finally{e.f()}this.hotkeysService.add(this.oldHotkeys)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da($K),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","hotkeys",""]],inputs:{hotkeys:"hotkeys"},features:[Ns([$K])]}),t}(),tX=function(){var t=function(){function t(e){Object(m.a)(this,t),this.hotkeysService=e,this.helpVisible=!1,this.title="Keyboard Shortcuts:"}return Object(g.a)(t,[{key:"ngOnInit",value:function(){var t=this;this.subscription=this.hotkeysService.cheatSheetToggle.subscribe((function(e){!1!==e&&(t.hotkeys=t.hotkeysService.hotkeys.filter((function(t){return t.description}))),!1===e?t.helpVisible=!1:t.toggleCheatSheet()}))}},{key:"ngOnDestroy",value:function(){this.subscription&&this.subscription.unsubscribe()}},{key:"toggleCheatSheet",value:function(){this.helpVisible=!this.helpVisible}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da($K))},t.\u0275cmp=Ht({type:t,selectors:[["hotkeys-cheatsheet"]],inputs:{title:"title"},decls:9,vars:5,consts:[[1,"cfp-hotkeys-container","fade",2,"display","none",3,"ngClass"],[1,"cfp-hotkeys"],[1,"cfp-hotkeys-title"],[4,"ngFor","ngForOf"],[1,"cfp-hotkeys-close",3,"click"],[1,"cfp-hotkeys-keys"],["class","cfp-hotkeys-key",4,"ngFor","ngForOf"],[1,"cfp-hotkeys-text"],[1,"cfp-hotkeys-key"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"h4",2),ds(3),va(),ga(4,"table"),ga(5,"tbody"),ua(6,KK,5,2,"tr",3),va(),va(),ga(7,"div",4),xa("click",(function(){return e.toggleCheatSheet()})),ds(8,"\xd7"),va(),va(),va()),2&t&&(pa("ngClass",Ic(3,YK,e.helpVisible)),Qi(3),fs(e.title),Qi(3),pa("ngForOf",e.hotkeys))},directives:[Oh,Eh],styles:[".cfp-hotkeys-container[_ngcontent-%COMP%]{display:table!important;position:fixed;width:100%;height:100%;top:0;left:0;color:#333;font-size:1em;background-color:rgba(255,255,255,.9)}.cfp-hotkeys-container.fade[_ngcontent-%COMP%]{z-index:-1024;visibility:hidden;opacity:0;-webkit-transition:opacity .15s linear;transition:opacity .15s linear}.cfp-hotkeys-container.fade.in[_ngcontent-%COMP%]{z-index:10002;visibility:visible;opacity:1}.cfp-hotkeys-title[_ngcontent-%COMP%]{font-weight:700;text-align:center;font-size:1.2em}.cfp-hotkeys[_ngcontent-%COMP%]{width:100%;height:100%;display:table-cell;vertical-align:middle}.cfp-hotkeys[_ngcontent-%COMP%] table[_ngcontent-%COMP%]{margin:auto;color:#333}.cfp-content[_ngcontent-%COMP%]{display:table-cell;vertical-align:middle}.cfp-hotkeys-keys[_ngcontent-%COMP%]{padding:5px;text-align:right}.cfp-hotkeys-key[_ngcontent-%COMP%]{display:inline-block;color:#fff;background-color:#333;border:1px solid #333;border-radius:5px;text-align:center;margin-right:5px;box-shadow:inset 0 1px 0 #666,0 1px 0 #bbb;padding:5px 9px;font-size:1em}.cfp-hotkeys-text[_ngcontent-%COMP%]{padding-left:10px;font-size:1em}.cfp-hotkeys-close[_ngcontent-%COMP%]{position:fixed;top:20px;right:20px;font-size:2em;font-weight:700;padding:5px 10px;border:1px solid #ddd;border-radius:5px;min-height:45px;min-width:45px;text-align:center}.cfp-hotkeys-close[_ngcontent-%COMP%]:hover{background-color:#fff;cursor:pointer}@media all and (max-width:500px){.cfp-hotkeys[_ngcontent-%COMP%]{font-size:.8em}}@media all and (min-width:750px){.cfp-hotkeys[_ngcontent-%COMP%]{font-size:1.2em}}"]}),t}(),eX=function(){var t=XK=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"forRoot",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return{ngModule:XK,providers:[$K,{provide:QK,useValue:t}]}}}]),t}();return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd]]}),t}(),nX=function(){var t={MEMORY:0,IMMUTABLE_MEMORY:1,SESSION:2,LOCAL:3};return t[t.MEMORY]="MEMORY",t[t.IMMUTABLE_MEMORY]="IMMUTABLE_MEMORY",t[t.SESSION]="SESSION",t[t.LOCAL]="LOCAL",t}(),iX=function(){function t(t,e,n,i){var r=this;void 0===i&&(i={}),this._loader=e;var o=i.type||nX.MEMORY;n.defineProperty(this,"_value",t,i),this._changes=n.changes({key:t,type:o}).map((function(t){return r._value})).publishBehavior(this._value).refCount()}return t.prototype.get=function(){var t=this,e=this._value;if(void 0===e){var n=this._cachedObservable;if(void 0!==n)return n;var i=this._loader();if(i&&i instanceof k.a){var r=i.publishLast().refCount().do((function(e){return t._value=e})).do((function(e){return t._cachedObservable=void 0}));return this._cachedObservable=r,r}this._value=e=i}return k.a.of(e)},t.prototype.changes=function(){return this._changes},t.prototype.clear=function(){this._value=void 0},t}(),rX=function(){function t(t,e){this._namespace=t,this._container=e;var n=e.get(this._namespace);if(n&&("object"!=typeof n||!n.__INFO))throw new Error("Potential attribute conflict detected")}return t.prototype.addAttribute=function(t){var e=this._getInfo();e[t]=!0,this._setInfo(e)},t.prototype.removeAttribute=function(t){var e=this._getInfo();delete e[t],this._setInfo(e)},t.prototype.getAttributes=function(){return Object.keys(this._getInfo()).filter((function(t){return"__INFO"!==t}))},t.prototype.available=function(){var t=this._container.get(this._namespace);return!t||"object"==typeof t&&t.__INFO},t.prototype._getInfo=function(){var t=this._container.get(this._namespace);return t||((t={}).__INFO=!0),t},t.prototype._setInfo=function(t){Object.keys(t).length<=1?this._container.remove(this._namespace):this._container.set(this._namespace,t)},t}(),oX=function(){function t(t,e,n){void 0===n&&(n=!0),this._namespace=t,this._root=e,this._available=n,this._info=new rX(t,e)}return t.prototype.set=function(t,e){if(!this._available)return!1;var n=this._root.set(this._getNamespacedKey(t),e);return this._info.addAttribute(t),n},t.prototype.get=function(t){if(this._available){var e=this._root.get(this._getNamespacedKey(t));return void 0===e&&this._info.removeAttribute(t),e}},t.prototype.remove=function(t){if(this._available)return this._info.removeAttribute(t),this._root.remove(this._getNamespacedKey(t))},t.prototype.removeAll=function(){var t=this;this._info.getAttributes().forEach((function(e){t.remove(e)}))},t.prototype.available=function(){return this._available&&this._info.available()},t.prototype.exists=function(t){return void 0!==this.get(t)},t.prototype.keys=function(){var t=this;return this._info.getAttributes().filter((function(e){return t.exists(e)}))},t.prototype._getNamespacedKey=function(t){return this._namespace+"::"+t},t}(),aX=function(){function t(t){this._storage=t}return t.prototype.set=function(t,e){try{null===e&&(e="_____NULL_VALUE_____"),void 0===e?this._storage.removeItem(t):this._storage.setItem(t,JSON.stringify(e))}catch(n){return!1}return!0},t.prototype.get=function(t){var e=this._storage.getItem(t);if(null!==e){var n=JSON.parse(e);return"_____NULL_VALUE_____"===n?null:n}},t.prototype.remove=function(t){var e=this.get(t);return void 0!==e&&this._storage.removeItem(t),e},t.prototype.removeAll=function(){this._storage.clear()},t}(),sX=function(t){function e(e){t.call(this,"ANGULAR_PERSISTENCE_STORAGE",new aX(e),!!e)}return function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);function i(){this.constructor=t}t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}(e,t),e}(oX),cX=function(t){function e(){t.call(this,sessionStorage)}return function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);function i(){this.constructor=t}t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}(e,t),e}(sX),lX=function(t){function e(){t.call(this,localStorage)}return function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);function i(){this.constructor=t}t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}(e,t),e}(sX),uX=function(){function t(){this._data={}}return t.prototype.available=function(){return!0},t.prototype.set=function(t,e){return void 0===e?delete this._data[t]:this._data[t]=e,!0},t.prototype.get=function(t){return this._data[t]},t.prototype.exists=function(t){return void 0!==this._data[t]},t.prototype.remove=function(t){delete this._data[t]},t.prototype.removeAll=function(){var t=Object.keys(this._data);return this._data={},t},t.prototype.keys=function(){return Object.keys(this._data)},t}(),hX=function(t){function e(){t.apply(this,arguments)}return function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);function i(){this.constructor=t}t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}(e,t),e.prototype.set=function(e,n){return void 0!==n&&(n=JSON.stringify(n)),t.prototype.set.call(this,e,n)},e.prototype.get=function(e){var n=t.prototype.get.call(this,e);if(void 0!==n)return JSON.parse(n)},e}(uX),dX=function(){function t(){this._storages=[]}return t.getStorage=function(){return new t},t.prototype.of=function(t){var e=this._storages[t];if(!e){switch(t){case nX.MEMORY:e=new uX,this._storages[t]=e;break;case nX.IMMUTABLE_MEMORY:e=new hX;break;case nX.LOCAL:e=new lX;break;case nX.SESSION:e=new cX}if(!e||!e.available())throw new Error("Storage type not available");this._storages[t]=e}return e},t}(),fX=function(){function t(){this._emitter=new Uc,this._storage=dX.getStorage()}return t.prototype.changes=function(t){void 0===t&&(t={});var e=this._emitter.asObservable();return t.key&&(e=e.filter((function(e){return e.key===t.key}))),t.type&&(e=e.filter((function(e){return e.type===t.type}))),e},t.prototype.get=function(t,e){void 0===e&&(e=nX.MEMORY);var n=this._getStorage(e),i=n.get(t);if(i){var r=Date.now();if(i.expireAfter&&i.created+i.expireAfter<r)return n.remove(t),void this._emitter.emit({key:t,type:e});if(i.oneUse)return n.remove(t),this._emitter.emit({key:t,type:e}),i.data;if(i.timeout){if(i.lastAccessed+i.timeout<r)return n.remove(t),void this._emitter.emit({key:t,type:e});i.lastAccessed=r,n.set(t,i)}return i.data}},t.prototype.set=function(t,e,n){if(void 0===n&&(n={}),n.type||(n.type=nX.MEMORY),void 0===!e)return this.remove(t),this._emitter.emit({key:t,type:n.type}),!0;var i=this._getStorage(n.type),r=Date.now(),o=i.set(t,{data:e,expireAfter:n.expireAfter,timeout:n.timeout,oneUse:!!n.oneUse,created:r,lastAccessed:r});return o?this._emitter.emit({key:t,type:n.type}):i.remove(t),o},t.prototype.remove=function(t,e){void 0===e&&(e=nX.MEMORY);var n=this._getStorage(e),i=this.get(t,e);return void 0!==i&&(n.remove(t),this._emitter.emit({key:t,type:e})),i},t.prototype.removeAll=function(t){var e=this;void 0===t&&(t=nX.MEMORY);var n=this._getStorage(t).keys();this._getStorage(t).removeAll(),n.forEach((function(n){return e._emitter.emit({key:n,type:t})}))},t.prototype.clean=function(t){void 0===t&&(t=nX.MEMORY);for(var e=this._getStorage(t),n=e.keys(),i=Date.now(),r=0,o=n;r<o.length;r++){var a=o[r],s=e.get(a);s&&(s.expireAfter&&s.created+s.expireAfter<i||s.timeout&&s.lastAccessed+s.timeout<i)&&this.remove(a)}},t.prototype.defineProperty=function(t,e,n,i){var r=this;void 0===i&&(i={});var o=i.type||nX.MEMORY;Object.defineProperty(t,e,{enumerable:!0,configurable:!0,get:function(){return r.get(n,o)},set:function(t){r.set(n,t,i)}})},t.prototype.createContainer=function(t,e){void 0===e&&(e={});var n=this,i={oneUse:e.oneUse,expireAfter:e.expireAfter,timeout:e.timeout,type:e.type||nX.MEMORY};return new oX(t,{get:function(t){return n.get(t,i.type)},set:function(t,e){return n.set(t,e,i)},remove:function(t){return n.remove(t,i.type)},removeAll:function(){return n.removeAll()}},!0)},t.prototype.createCache=function(t,e,n){return void 0===n&&(n={}),new iX(t,e,this,{type:n.type||nX.MEMORY,expireAfter:n.expireAfter,timeout:n.timeout})},t.prototype._getStorage=function(t){return this._storage.of(t)},t.prototype._calculateExpires=function(t){return t?Date.now()+t:void 0},t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:function(e){return t.\u0275fac(e)}}),t}(),pX=function(){function t(){}return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[fX]}),t}(),mX=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"electron",get:function(){return this._electron?this._electron:window&&window.require?(this._electron=window.require("electron"),this._electron):null}},{key:"isElectronApp",get:function(){return!!window.navigator.userAgent.match(/Electron/)}},{key:"isMacOS",get:function(){return this.isElectronApp&&"darwin"===process.platform}},{key:"isWindows",get:function(){return this.isElectronApp&&"win32"===process.platform}},{key:"isLinux",get:function(){return this.isElectronApp&&"linux"===process.platform}},{key:"isX86",get:function(){return this.isElectronApp&&"ia32"===process.arch}},{key:"isX64",get:function(){return this.isElectronApp&&"x64"===process.arch}},{key:"isArm",get:function(){return this.isElectronApp&&"arm"===process.arch}},{key:"desktopCapturer",get:function(){return this.electron?this.electron.desktopCapturer:null}},{key:"ipcRenderer",get:function(){return this.electron?this.electron.ipcRenderer:null}},{key:"remote",get:function(){return this.electron?this.electron.remote:null}},{key:"webFrame",get:function(){return this.electron?this.electron.webFrame:null}},{key:"clipboard",get:function(){return this.electron?this.electron.clipboard:null}},{key:"crashReporter",get:function(){return this.electron?this.electron.crashReporter:null}},{key:"process",get:function(){return this.remote?this.remote.process:null}},{key:"nativeImage",get:function(){return this.electron?this.electron.nativeImage:null}},{key:"screen",get:function(){return this.electron?this.remote.screen:null}},{key:"shell",get:function(){return this.electron?this.electron.shell:null}}]),t}(),gX=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.call(this)}return n}(mX);return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),vX=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[{provide:mX,useClass:gX}]}),t}(),bX=function(){function t(e){Object(m.a)(this,t),this.rawFile=e;var n,i=(n=e)&&(n.nodeName||n.prop&&n.attr&&n.find)?e.value:e;this["_createFrom"+("string"==typeof i?"FakePath":"Object")](i)}return Object(g.a)(t,[{key:"_createFromFakePath",value:function(t){this.lastModifiedDate=void 0,this.size=void 0,this.type="like/"+t.slice(t.lastIndexOf(".")+1).toLowerCase(),this.name=t.slice(t.lastIndexOf("/")+t.lastIndexOf("\\")+2)}},{key:"_createFromObject",value:function(t){this.size=t.size,this.type=t.type,this.name=t.name}}]),t}(),yX=function(){function t(e,n,i){Object(m.a)(this,t),this.url="/",this.headers=[],this.withCredentials=!0,this.formData=[],this.isReady=!1,this.isUploading=!1,this.isUploaded=!1,this.isSuccess=!1,this.isCancel=!1,this.isError=!1,this.progress=0,this.index=void 0,this.uploader=e,this.some=n,this.options=i,this.file=new bX(n),this._file=n,e.options&&(this.method=e.options.method||"POST",this.alias=e.options.itemAlias||"file"),this.url=e.options.url}return Object(g.a)(t,[{key:"upload",value:function(){try{this.uploader.uploadItem(this)}catch(t){this.uploader._onCompleteItem(this,"",0,{}),this.uploader._onErrorItem(this,"",0,{})}}},{key:"cancel",value:function(){this.uploader.cancelItem(this)}},{key:"remove",value:function(){this.uploader.removeFromQueue(this)}},{key:"onBeforeUpload",value:function(){}},{key:"onBuildForm",value:function(t){return{form:t}}},{key:"onProgress",value:function(t){return{progress:t}}},{key:"onSuccess",value:function(t,e,n){return{response:t,status:e,headers:n}}},{key:"onError",value:function(t,e,n){return{response:t,status:e,headers:n}}},{key:"onCancel",value:function(t,e,n){return{response:t,status:e,headers:n}}},{key:"onComplete",value:function(t,e,n){return{response:t,status:e,headers:n}}},{key:"_onBeforeUpload",value:function(){this.isReady=!0,this.isUploading=!0,this.isUploaded=!1,this.isSuccess=!1,this.isCancel=!1,this.isError=!1,this.progress=0,this.onBeforeUpload()}},{key:"_onBuildForm",value:function(t){this.onBuildForm(t)}},{key:"_onProgress",value:function(t){this.progress=t,this.onProgress(t)}},{key:"_onSuccess",value:function(t,e,n){this.isReady=!1,this.isUploading=!1,this.isUploaded=!0,this.isSuccess=!0,this.isCancel=!1,this.isError=!1,this.progress=100,this.index=void 0,this.onSuccess(t,e,n)}},{key:"_onError",value:function(t,e,n){this.isReady=!1,this.isUploading=!1,this.isUploaded=!0,this.isSuccess=!1,this.isCancel=!1,this.isError=!0,this.progress=0,this.index=void 0,this.onError(t,e,n)}},{key:"_onCancel",value:function(t,e,n){this.isReady=!1,this.isUploading=!1,this.isUploaded=!1,this.isSuccess=!1,this.isCancel=!0,this.isError=!1,this.progress=0,this.index=void 0,this.onCancel(t,e,n)}},{key:"_onComplete",value:function(t,e,n){this.onComplete(t,e,n),this.uploader.options.removeAfterUpload&&this.remove()}},{key:"_prepareToUploading",value:function(){this.index=this.index||++this.uploader._nextIndex,this.isReady=!0}}]),t}(),_X=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"getMimeClass",value:function(t){var e="application";return-1!==this.mime_psd.indexOf(t.type)||t.type.match("image.*")?e="image":t.type.match("video.*")?e="video":t.type.match("audio.*")?e="audio":"application/pdf"===t.type?e="pdf":-1!==this.mime_compress.indexOf(t.type)?e="compress":-1!==this.mime_doc.indexOf(t.type)?e="doc":-1!==this.mime_xsl.indexOf(t.type)?e="xls":-1!==this.mime_ppt.indexOf(t.type)&&(e="ppt"),"application"===e&&(e=this.fileTypeDetection(t.name)),e}},{key:"fileTypeDetection",value:function(t){var e={jpg:"image",jpeg:"image",tif:"image",psd:"image",bmp:"image",png:"image",nef:"image",tiff:"image",cr2:"image",dwg:"image",cdr:"image",ai:"image",indd:"image",pin:"image",cdp:"image",skp:"image",stp:"image","3dm":"image",mp3:"audio",wav:"audio",wma:"audio",mod:"audio",m4a:"audio",compress:"compress",zip:"compress",rar:"compress","7z":"compress",lz:"compress",z01:"compress",bz2:"compress",gz:"compress",pdf:"pdf",xls:"xls",xlsx:"xls",ods:"xls",mp4:"video",avi:"video",wmv:"video",mpg:"video",mts:"video",flv:"video","3gp":"video",vob:"video",m4v:"video",mpeg:"video",m2ts:"video",mov:"video",doc:"doc",docx:"doc",eps:"doc",txt:"doc",odt:"doc",rtf:"doc",ppt:"ppt",pptx:"ppt",pps:"ppt",ppsx:"ppt",odp:"ppt"},n=t.split(".");if(n.length<2)return"application";var i=n[n.length-1].toLowerCase();return void 0===e[i]?"application":e[i]}}]),t}();return t.mime_doc=["application/msword","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.openxmlformats-officedocument.wordprocessingml.template","application/vnd.ms-word.document.macroEnabled.12","application/vnd.ms-word.template.macroEnabled.12"],t.mime_xsl=["application/vnd.ms-excel","application/vnd.ms-excel","application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.openxmlformats-officedocument.spreadsheetml.template","application/vnd.ms-excel.sheet.macroEnabled.12","application/vnd.ms-excel.template.macroEnabled.12","application/vnd.ms-excel.addin.macroEnabled.12","application/vnd.ms-excel.sheet.binary.macroEnabled.12"],t.mime_ppt=["application/vnd.ms-powerpoint","application/vnd.ms-powerpoint","application/vnd.ms-powerpoint","application/vnd.ms-powerpoint","application/vnd.openxmlformats-officedocument.presentationml.presentation","application/vnd.openxmlformats-officedocument.presentationml.template","application/vnd.openxmlformats-officedocument.presentationml.slideshow","application/vnd.ms-powerpoint.addin.macroEnabled.12","application/vnd.ms-powerpoint.presentation.macroEnabled.12","application/vnd.ms-powerpoint.presentation.macroEnabled.12","application/vnd.ms-powerpoint.slideshow.macroEnabled.12"],t.mime_psd=["image/photoshop","image/x-photoshop","image/psd","application/photoshop","application/psd","zz-application/zz-winassoc-psd"],t.mime_compress=["application/x-gtar","application/x-gcompress","application/compress","application/x-tar","application/x-rar-compressed","application/octet-stream","application/x-zip-compressed","application/zip-compressed","application/x-7z-compressed","application/gzip","application/x-bzip2"],t}(),wX=function(){function t(e){Object(m.a)(this,t),this.isUploading=!1,this.queue=[],this.progress=0,this._nextIndex=0,this.options={autoUpload:!1,isHTML5:!0,filters:[],removeAfterUpload:!1,disableMultipart:!1,formatDataFunction:function(t){return t._file},formatDataFunctionIsAsync:!1},this.setOptions(e),this.response=new Uc}return Object(g.a)(t,[{key:"setOptions",value:function(t){this.options=Object.assign(this.options,t),this.authToken=this.options.authToken,this.authTokenHeader=this.options.authTokenHeader||"Authorization",this.autoUpload=this.options.autoUpload,this.options.filters.unshift({name:"queueLimit",fn:this._queueLimitFilter}),this.options.maxFileSize&&this.options.filters.unshift({name:"fileSize",fn:this._fileSizeFilter}),this.options.allowedFileType&&this.options.filters.unshift({name:"fileType",fn:this._fileTypeFilter}),this.options.allowedMimeType&&this.options.filters.unshift({name:"mimeType",fn:this._mimeTypeFilter});for(var e=0;e<this.queue.length;e++)this.queue[e].url=this.options.url}},{key:"addToQueue",value:function(t,e,n){var i,r=this,o=[],a=d(t);try{for(a.s();!(i=a.n()).done;)o.push(i.value)}catch(u){a.e(u)}finally{a.f()}var s=this._getFilters(n),c=this.queue.length,l=[];o.map((function(t){e||(e=r.options);var n=new bX(t);if(r._isValidFile(n,s,e)){var i=new yX(r,t,e);l.push(i),r.queue.push(i),r._onAfterAddingFile(i)}else r._onWhenAddingFileFailed(n,s[r._failFilterIndex],e)})),this.queue.length!==c&&(this._onAfterAddingAll(l),this.progress=this._getTotalProgress()),this._render(),this.options.autoUpload&&this.uploadAll()}},{key:"removeFromQueue",value:function(t){var e=this.getIndexOfItem(t),n=this.queue[e];n.isUploading&&n.cancel(),this.queue.splice(e,1),this.progress=this._getTotalProgress()}},{key:"clearQueue",value:function(){for(;this.queue.length;)this.queue[0].remove();this.progress=0}},{key:"uploadItem",value:function(t){var e=this.getIndexOfItem(t),n=this.queue[e],i=this.options.isHTML5?"_xhrTransport":"_iframeTransport";n._prepareToUploading(),this.isUploading||(this.isUploading=!0,this[i](n))}},{key:"cancelItem",value:function(t){var e=this.getIndexOfItem(t),n=this.queue[e];n&&n.isUploading&&(this.options.isHTML5?n._xhr:n._form).abort()}},{key:"uploadAll",value:function(){var t=this.getNotUploadedItems().filter((function(t){return!t.isUploading}));t.length&&(t.map((function(t){return t._prepareToUploading()})),t[0].upload())}},{key:"cancelAll",value:function(){this.getNotUploadedItems().map((function(t){return t.cancel()}))}},{key:"isFile",value:function(t){return function(t){return File&&t instanceof File}(t)}},{key:"isFileLikeObject",value:function(t){return t instanceof bX}},{key:"getIndexOfItem",value:function(t){return"number"==typeof t?t:this.queue.indexOf(t)}},{key:"getNotUploadedItems",value:function(){return this.queue.filter((function(t){return!t.isUploaded}))}},{key:"getReadyItems",value:function(){return this.queue.filter((function(t){return t.isReady&&!t.isUploading})).sort((function(t,e){return t.index-e.index}))}},{key:"destroy",value:function(){}},{key:"onAfterAddingAll",value:function(t){return{fileItems:t}}},{key:"onBuildItemForm",value:function(t,e){return{fileItem:t,form:e}}},{key:"onAfterAddingFile",value:function(t){return{fileItem:t}}},{key:"onWhenAddingFileFailed",value:function(t,e,n){return{item:t,filter:e,options:n}}},{key:"onBeforeUploadItem",value:function(t){return{fileItem:t}}},{key:"onProgressItem",value:function(t,e){return{fileItem:t,progress:e}}},{key:"onProgressAll",value:function(t){return{progress:t}}},{key:"onSuccessItem",value:function(t,e,n,i){return{item:t,response:e,status:n,headers:i}}},{key:"onErrorItem",value:function(t,e,n,i){return{item:t,response:e,status:n,headers:i}}},{key:"onCancelItem",value:function(t,e,n,i){return{item:t,response:e,status:n,headers:i}}},{key:"onCompleteItem",value:function(t,e,n,i){return{item:t,response:e,status:n,headers:i}}},{key:"onCompleteAll",value:function(){}},{key:"_mimeTypeFilter",value:function(t){return!(this.options.allowedMimeType&&-1===this.options.allowedMimeType.indexOf(t.type))}},{key:"_fileSizeFilter",value:function(t){return!(this.options.maxFileSize&&t.size>this.options.maxFileSize)}},{key:"_fileTypeFilter",value:function(t){return!(this.options.allowedFileType&&-1===this.options.allowedFileType.indexOf(_X.getMimeClass(t)))}},{key:"_onErrorItem",value:function(t,e,n,i){t._onError(e,n,i),this.onErrorItem(t,e,n,i)}},{key:"_onCompleteItem",value:function(t,e,n,i){t._onComplete(e,n,i),this.onCompleteItem(t,e,n,i);var r=this.getReadyItems()[0];this.isUploading=!1,r?r.upload():(this.onCompleteAll(),this.progress=this._getTotalProgress(),this._render())}},{key:"_headersGetter",value:function(t){return function(e){return e?t[e.toLowerCase()]||void 0:t}}},{key:"_xhrTransport",value:function(t){var e,n=this,i=this,r=t._xhr=new XMLHttpRequest;if(this._onBeforeUploadItem(t),"number"!=typeof t._file.size)throw new TypeError("The file specified is no longer valid");if(this.options.disableMultipart)e=this.options.formatDataFunction(t);else{e=new FormData,this._onBuildItemForm(t,e);var o=function(){return e.append(t.alias,t._file,t.file.name)};this.options.parametersBeforeFiles||o(),void 0!==this.options.additionalParameter&&Object.keys(this.options.additionalParameter).forEach((function(i){var r=n.options.additionalParameter[i];"string"==typeof r&&r.indexOf("{{file_name}}")>=0&&(r=r.replace("{{file_name}}",t.file.name)),e.append(i,r)})),this.options.parametersBeforeFiles&&o()}if(r.upload.onprogress=function(e){var i=Math.round(e.lengthComputable?100*e.loaded/e.total:0);n._onProgressItem(t,i)},r.onload=function(){var e=n._parseHeaders(r.getAllResponseHeaders()),i=n._transformResponse(r.response,e),o=n._isSuccessCode(r.status)?"Success":"Error";n["_on"+o+"Item"](t,i,r.status,e),n._onCompleteItem(t,i,r.status,e)},r.onerror=function(){var e=n._parseHeaders(r.getAllResponseHeaders()),i=n._transformResponse(r.response,e);n._onErrorItem(t,i,r.status,e),n._onCompleteItem(t,i,r.status,e)},r.onabort=function(){var e=n._parseHeaders(r.getAllResponseHeaders()),i=n._transformResponse(r.response,e);n._onCancelItem(t,i,r.status,e),n._onCompleteItem(t,i,r.status,e)},r.open(t.method,t.url,!0),r.withCredentials=t.withCredentials,this.options.headers){var a,s=d(this.options.headers);try{for(s.s();!(a=s.n()).done;){var c=a.value;r.setRequestHeader(c.name,c.value)}}catch(f){s.e(f)}finally{s.f()}}if(t.headers.length){var l,u=d(t.headers);try{for(u.s();!(l=u.n()).done;){var h=l.value;r.setRequestHeader(h.name,h.value)}}catch(f){u.e(f)}finally{u.f()}}this.authToken&&r.setRequestHeader(this.authTokenHeader,this.authToken),r.onreadystatechange=function(){r.readyState==XMLHttpRequest.DONE&&i.response.emit(r.responseText)},this.options.formatDataFunctionIsAsync?e.then((function(t){return r.send(JSON.stringify(t))})):r.send(e),this._render()}},{key:"_getTotalProgress",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;if(this.options.removeAfterUpload)return t;var e=this.getNotUploadedItems().length,n=e?this.queue.length-e:this.queue.length,i=100/this.queue.length,r=t*i/100;return Math.round(n*i+r)}},{key:"_getFilters",value:function(t){if(!t)return this.options.filters;if(Array.isArray(t))return t;if("string"==typeof t){var e=t.match(/[^\s,]+/g);return this.options.filters.filter((function(t){return-1!==e.indexOf(t.name)}))}return this.options.filters}},{key:"_render",value:function(){}},{key:"_queueLimitFilter",value:function(){return void 0===this.options.queueLimit||this.queue.length<this.options.queueLimit}},{key:"_isValidFile",value:function(t,e,n){var i=this;return this._failFilterIndex=-1,!e.length||e.every((function(e){return i._failFilterIndex++,e.fn.call(i,t,n)}))}},{key:"_isSuccessCode",value:function(t){return t>=200&&t<300||304===t}},{key:"_transformResponse",value:function(t,e){return t}},{key:"_parseHeaders",value:function(t){var e,n,i,r={};return t?(t.split("\n").map((function(t){i=t.indexOf(":"),e=t.slice(0,i).trim().toLowerCase(),n=t.slice(i+1).trim(),e&&(r[e]=r[e]?r[e]+", "+n:n)})),r):r}},{key:"_onWhenAddingFileFailed",value:function(t,e,n){this.onWhenAddingFileFailed(t,e,n)}},{key:"_onAfterAddingFile",value:function(t){this.onAfterAddingFile(t)}},{key:"_onAfterAddingAll",value:function(t){this.onAfterAddingAll(t)}},{key:"_onBeforeUploadItem",value:function(t){t._onBeforeUpload(),this.onBeforeUploadItem(t)}},{key:"_onBuildItemForm",value:function(t,e){t._onBuildForm(e),this.onBuildItemForm(t,e)}},{key:"_onProgressItem",value:function(t,e){var n=this._getTotalProgress(e);this.progress=n,t._onProgress(e),this.onProgressItem(t,e),this.onProgressAll(n),this._render()}},{key:"_onSuccessItem",value:function(t,e,n,i){t._onSuccess(e,n,i),this.onSuccessItem(t,e,n,i)}},{key:"_onCancelItem",value:function(t,e,n,i){t._onCancel(e,n,i),this.onCancelItem(t,e,n,i)}}]),t}(),kX=function(){var t=function(){function t(e){Object(m.a)(this,t),this.onFileSelected=new Uc,this.element=e}return Object(g.a)(t,[{key:"getOptions",value:function(){return this.uploader.options}},{key:"getFilters",value:function(){return{}}},{key:"isEmptyAfterSelection",value:function(){return!!this.element.nativeElement.attributes.multiple}},{key:"onChange",value:function(){var t=this.element.nativeElement.files,e=this.getOptions(),n=this.getFilters();this.uploader.addToQueue(t,e,n),this.onFileSelected.emit(t),this.isEmptyAfterSelection()&&(this.element.nativeElement.value="")}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","ng2FileSelect",""]],hostBindings:function(t,e){1&t&&xa("change",(function(){return e.onChange()}))},inputs:{uploader:"uploader"},outputs:{onFileSelected:"onFileSelected"}}),t}(),CX=function(){var t=function(){function t(e){Object(m.a)(this,t),this.fileOver=new Uc,this.onFileDrop=new Uc,this.element=e}return Object(g.a)(t,[{key:"getOptions",value:function(){return this.uploader.options}},{key:"getFilters",value:function(){return{}}},{key:"onDrop",value:function(t){var e=this._getTransfer(t);if(e){var n=this.getOptions(),i=this.getFilters();this._preventAndStop(t),this.uploader.addToQueue(e.files,n,i),this.fileOver.emit(!1),this.onFileDrop.emit(e.files)}}},{key:"onDragOver",value:function(t){var e=this._getTransfer(t);this._haveFiles(e.types)&&(e.dropEffect="copy",this._preventAndStop(t),this.fileOver.emit(!0))}},{key:"onDragLeave",value:function(t){this.element&&t.currentTarget===this.element[0]||(this._preventAndStop(t),this.fileOver.emit(!1))}},{key:"_getTransfer",value:function(t){return t.dataTransfer?t.dataTransfer:t.originalEvent.dataTransfer}},{key:"_preventAndStop",value:function(t){t.preventDefault(),t.stopPropagation()}},{key:"_haveFiles",value:function(t){return!!t&&(t.indexOf?-1!==t.indexOf("Files"):!!t.contains&&t.contains("Files"))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","ng2FileDrop",""]],hostBindings:function(t,e){1&t&&xa("drop",(function(t){return e.onDrop(t)}))("dragover",(function(t){return e.onDragOver(t)}))("dragleave",(function(t){return e.onDragLeave(t)}))},inputs:{uploader:"uploader"},outputs:{fileOver:"fileOver",onFileDrop:"onFileDrop"}}),t}(),SX=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd]]}),t}(),xX=n("sVev"),OX=n("itXk"),MX=n("NXyV"),TX=n("EY2u"),EX=n("0EUg"),PX=n("NJ9Y"),AX=n("JIr8"),jX=n("SxV6"),IX=n("5+tZ"),DX=n("vkgz"),RX=n("Gi4w"),LX=n("eIep"),FX=n("IzEk"),NX=n("JX91"),BX=n("Kqap"),HX=n("BFxc"),zX=n("nYR2"),VX=n("bHdf"),UX=function t(e,n){Object(m.a)(this,t),this.id=e,this.url=n},qX=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"imperative",a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;return Object(m.a)(this,n),(r=e.call(this,t,i)).navigationTrigger=o,r.restoredState=a,r}return Object(g.a)(n,[{key:"toString",value:function(){return"NavigationStart(id: ".concat(this.id,", url: '").concat(this.url,"')")}}]),n}(UX),GX=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,i)).urlAfterRedirects=r,o}return Object(g.a)(n,[{key:"toString",value:function(){return"NavigationEnd(id: ".concat(this.id,", url: '").concat(this.url,"', urlAfterRedirects: '").concat(this.urlAfterRedirects,"')")}}]),n}(UX),WX=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,i)).reason=r,o}return Object(g.a)(n,[{key:"toString",value:function(){return"NavigationCancel(id: ".concat(this.id,", url: '").concat(this.url,"')")}}]),n}(UX),KX=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,i)).error=r,o}return Object(g.a)(n,[{key:"toString",value:function(){return"NavigationError(id: ".concat(this.id,", url: '").concat(this.url,"', error: ").concat(this.error,")")}}]),n}(UX),XX=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,t,i)).urlAfterRedirects=r,a.state=o,a}return Object(g.a)(n,[{key:"toString",value:function(){return"RoutesRecognized(id: ".concat(this.id,", url: '").concat(this.url,"', urlAfterRedirects: '").concat(this.urlAfterRedirects,"', state: ").concat(this.state,")")}}]),n}(UX),YX=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,t,i)).urlAfterRedirects=r,a.state=o,a}return Object(g.a)(n,[{key:"toString",value:function(){return"GuardsCheckStart(id: ".concat(this.id,", url: '").concat(this.url,"', urlAfterRedirects: '").concat(this.urlAfterRedirects,"', state: ").concat(this.state,")")}}]),n}(UX),ZX=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){var s;return Object(m.a)(this,n),(s=e.call(this,t,i)).urlAfterRedirects=r,s.state=o,s.shouldActivate=a,s}return Object(g.a)(n,[{key:"toString",value:function(){return"GuardsCheckEnd(id: ".concat(this.id,", url: '").concat(this.url,"', urlAfterRedirects: '").concat(this.urlAfterRedirects,"', state: ").concat(this.state,", shouldActivate: ").concat(this.shouldActivate,")")}}]),n}(UX),QX=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,t,i)).urlAfterRedirects=r,a.state=o,a}return Object(g.a)(n,[{key:"toString",value:function(){return"ResolveStart(id: ".concat(this.id,", url: '").concat(this.url,"', urlAfterRedirects: '").concat(this.urlAfterRedirects,"', state: ").concat(this.state,")")}}]),n}(UX),$X=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,t,i)).urlAfterRedirects=r,a.state=o,a}return Object(g.a)(n,[{key:"toString",value:function(){return"ResolveEnd(id: ".concat(this.id,", url: '").concat(this.url,"', urlAfterRedirects: '").concat(this.urlAfterRedirects,"', state: ").concat(this.state,")")}}]),n}(UX),JX=function(){function t(e){Object(m.a)(this,t),this.route=e}return Object(g.a)(t,[{key:"toString",value:function(){return"RouteConfigLoadStart(path: ".concat(this.route.path,")")}}]),t}(),tY=function(){function t(e){Object(m.a)(this,t),this.route=e}return Object(g.a)(t,[{key:"toString",value:function(){return"RouteConfigLoadEnd(path: ".concat(this.route.path,")")}}]),t}(),eY=function(){function t(e){Object(m.a)(this,t),this.snapshot=e}return Object(g.a)(t,[{key:"toString",value:function(){return"ChildActivationStart(path: '".concat(this.snapshot.routeConfig&&this.snapshot.routeConfig.path||"","')")}}]),t}(),nY=function(){function t(e){Object(m.a)(this,t),this.snapshot=e}return Object(g.a)(t,[{key:"toString",value:function(){return"ChildActivationEnd(path: '".concat(this.snapshot.routeConfig&&this.snapshot.routeConfig.path||"","')")}}]),t}(),iY=function(){function t(e){Object(m.a)(this,t),this.snapshot=e}return Object(g.a)(t,[{key:"toString",value:function(){return"ActivationStart(path: '".concat(this.snapshot.routeConfig&&this.snapshot.routeConfig.path||"","')")}}]),t}(),rY=function(){function t(e){Object(m.a)(this,t),this.snapshot=e}return Object(g.a)(t,[{key:"toString",value:function(){return"ActivationEnd(path: '".concat(this.snapshot.routeConfig&&this.snapshot.routeConfig.path||"","')")}}]),t}(),oY=function(){function t(e,n,i){Object(m.a)(this,t),this.routerEvent=e,this.position=n,this.anchor=i}return Object(g.a)(t,[{key:"toString",value:function(){var t=this.position?"".concat(this.position[0],", ").concat(this.position[1]):null;return"Scroll(anchor: '".concat(this.anchor,"', position: '").concat(t,"')")}}]),t}(),aY=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["ng-component"]],decls:1,vars:0,template:function(t,e){1&t&&ba(0,"router-outlet")},directives:function(){return[mQ]},encapsulation:2}),t}(),sY=function(){function t(e){Object(m.a)(this,t),this.params=e||{}}return Object(g.a)(t,[{key:"has",value:function(t){return Object.prototype.hasOwnProperty.call(this.params,t)}},{key:"get",value:function(t){if(this.has(t)){var e=this.params[t];return Array.isArray(e)?e[0]:e}return null}},{key:"getAll",value:function(t){if(this.has(t)){var e=this.params[t];return Array.isArray(e)?e:[e]}return[]}},{key:"keys",get:function(){return Object.keys(this.params)}}]),t}();function cY(t){return new sY(t)}function lY(t){var e=Error("NavigationCancelingError: "+t);return e.ngNavigationCancelingError=!0,e}function uY(t,e,n){var i=n.path.split("/");if(i.length>t.length)return null;if("full"===n.pathMatch&&(e.hasChildren()||i.length<t.length))return null;for(var r={},o=0;o<i.length;o++){var a=i[o],s=t[o];if(a.startsWith(":"))r[a.substring(1)]=s;else if(a!==s.path)return null}return{consumed:t.slice(0,i.length),posParams:r}}var hY=function t(e,n){Object(m.a)(this,t),this.routes=e,this.module=n};function dY(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=0;n<t.length;n++){var i=t[n],r=pY(e,i);fY(i,r)}}function fY(t,e){if(!t)throw new Error("\n Invalid configuration of route '".concat(e,"': Encountered undefined route.\n The reason might be an extra comma.\n\n Example:\n const routes: Routes = [\n { path: '', redirectTo: '/dashboard', pathMatch: 'full' },\n { path: 'dashboard', component: DashboardComponent },, << two commas\n { path: 'detail/:id', component: HeroDetailComponent }\n ];\n "));if(Array.isArray(t))throw new Error("Invalid configuration of route '".concat(e,"': Array cannot be specified"));if(!t.component&&!t.children&&!t.loadChildren&&t.outlet&&"primary"!==t.outlet)throw new Error("Invalid configuration of route '".concat(e,"': a componentless route without children or loadChildren cannot have a named outlet set"));if(t.redirectTo&&t.children)throw new Error("Invalid configuration of route '".concat(e,"': redirectTo and children cannot be used together"));if(t.redirectTo&&t.loadChildren)throw new Error("Invalid configuration of route '".concat(e,"': redirectTo and loadChildren cannot be used together"));if(t.children&&t.loadChildren)throw new Error("Invalid configuration of route '".concat(e,"': children and loadChildren cannot be used together"));if(t.redirectTo&&t.component)throw new Error("Invalid configuration of route '".concat(e,"': redirectTo and component cannot be used together"));if(t.path&&t.matcher)throw new Error("Invalid configuration of route '".concat(e,"': path and matcher cannot be used together"));if(void 0===t.redirectTo&&!t.component&&!t.children&&!t.loadChildren)throw new Error("Invalid configuration of route '".concat(e,"'. One of the following must be provided: component, redirectTo, children or loadChildren"));if(void 0===t.path&&void 0===t.matcher)throw new Error("Invalid configuration of route '".concat(e,"': routes must have either a path or a matcher specified"));if("string"==typeof t.path&&"/"===t.path.charAt(0))throw new Error("Invalid configuration of route '".concat(e,"': path cannot start with a slash"));if(""===t.path&&void 0!==t.redirectTo&&void 0===t.pathMatch)throw new Error("Invalid configuration of route '{path: \"".concat(e,'", redirectTo: "').concat(t.redirectTo,"\"}': please provide 'pathMatch'. ").concat("The default value of 'pathMatch' is 'prefix', but often the intent is to use 'full'."));if(void 0!==t.pathMatch&&"full"!==t.pathMatch&&"prefix"!==t.pathMatch)throw new Error("Invalid configuration of route '".concat(e,"': pathMatch can only be set to 'prefix' or 'full'"));t.children&&dY(t.children,e)}function pY(t,e){return e?t||e.path?t&&!e.path?"".concat(t,"/"):!t&&e.path?e.path:"".concat(t,"/").concat(e.path):"":t}function mY(t){var e=t.children&&t.children.map(mY),n=e?Object.assign(Object.assign({},t),{children:e}):Object.assign({},t);return!n.component&&(e||n.loadChildren)&&n.outlet&&"primary"!==n.outlet&&(n.component=aY),n}function gY(t,e){var n,i=Object.keys(t),r=Object.keys(e);if(!i||!r||i.length!=r.length)return!1;for(var o=0;o<i.length;o++)if(!vY(t[n=i[o]],e[n]))return!1;return!0}function vY(t,e){return Array.isArray(t)&&Array.isArray(e)?t.length==e.length&&t.every((function(t){return e.indexOf(t)>-1})):t===e}function bY(t){return Array.prototype.concat.apply([],t)}function yY(t){return t.length>0?t[t.length-1]:null}function _Y(t,e){for(var n in t)t.hasOwnProperty(n)&&e(t[n],n)}function wY(t){return Sa(t)?t:Ca(t)?Object(tf.a)(Promise.resolve(t)):Object(lm.a)(t)}function kY(t,e,n){return n?function(t,e){return gY(t,e)}(t.queryParams,e.queryParams)&&function t(e,n){if(!OY(e.segments,n.segments))return!1;if(e.numberOfChildren!==n.numberOfChildren)return!1;for(var i in n.children){if(!e.children[i])return!1;if(!t(e.children[i],n.children[i]))return!1}return!0}(t.root,e.root):function(t,e){return Object.keys(e).length<=Object.keys(t).length&&Object.keys(e).every((function(n){return vY(t[n],e[n])}))}(t.queryParams,e.queryParams)&&function t(e,n){return function e(n,i,r){if(n.segments.length>r.length)return!!OY(n.segments.slice(0,r.length),r)&&!i.hasChildren();if(n.segments.length===r.length){if(!OY(n.segments,r))return!1;for(var o in i.children){if(!n.children[o])return!1;if(!t(n.children[o],i.children[o]))return!1}return!0}var a=r.slice(0,n.segments.length),s=r.slice(n.segments.length);return!!OY(n.segments,a)&&!!n.children.primary&&e(n.children.primary,i,s)}(e,n,n.segments)}(t.root,e.root)}var CY=function(){function t(e,n,i){Object(m.a)(this,t),this.root=e,this.queryParams=n,this.fragment=i}return Object(g.a)(t,[{key:"toString",value:function(){return PY.serialize(this)}},{key:"queryParamMap",get:function(){return this._queryParamMap||(this._queryParamMap=cY(this.queryParams)),this._queryParamMap}}]),t}(),SY=function(){function t(e,n){var i=this;Object(m.a)(this,t),this.segments=e,this.children=n,this.parent=null,_Y(n,(function(t,e){return t.parent=i}))}return Object(g.a)(t,[{key:"hasChildren",value:function(){return this.numberOfChildren>0}},{key:"toString",value:function(){return AY(this)}},{key:"numberOfChildren",get:function(){return Object.keys(this.children).length}}]),t}(),xY=function(){function t(e,n){Object(m.a)(this,t),this.path=e,this.parameters=n}return Object(g.a)(t,[{key:"toString",value:function(){return FY(this)}},{key:"parameterMap",get:function(){return this._parameterMap||(this._parameterMap=cY(this.parameters)),this._parameterMap}}]),t}();function OY(t,e){return t.length===e.length&&t.every((function(t,n){return t.path===e[n].path}))}function MY(t,e){var n=[];return _Y(t.children,(function(t,i){"primary"===i&&(n=n.concat(e(t,i)))})),_Y(t.children,(function(t,i){"primary"!==i&&(n=n.concat(e(t,i)))})),n}var TY=function t(){Object(m.a)(this,t)},EY=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"parse",value:function(t){var e=new VY(t);return new CY(e.parseRootSegment(),e.parseQueryParams(),e.parseFragment())}},{key:"serialize",value:function(t){var e,n,i="/".concat(function t(e,n){if(!e.hasChildren())return AY(e);if(n){var i=e.children.primary?t(e.children.primary,!1):"",r=[];return _Y(e.children,(function(e,n){"primary"!==n&&r.push("".concat(n,":").concat(t(e,!1)))})),r.length>0?"".concat(i,"(").concat(r.join("//"),")"):i}var o=MY(e,(function(n,i){return"primary"===i?[t(e.children.primary,!1)]:["".concat(i,":").concat(t(n,!1))]}));return"".concat(AY(e),"/(").concat(o.join("//"),")")}(t.root,!0)),r=(e=t.queryParams,(n=Object.keys(e).map((function(t){var n=e[t];return Array.isArray(n)?n.map((function(e){return"".concat(IY(t),"=").concat(IY(e))})).join("&"):"".concat(IY(t),"=").concat(IY(n))}))).length?"?".concat(n.join("&")):""),o="string"==typeof t.fragment?"#".concat(encodeURI(t.fragment)):"";return"".concat(i).concat(r).concat(o)}}]),t}(),PY=new EY;function AY(t){return t.segments.map((function(t){return FY(t)})).join("/")}function jY(t){return encodeURIComponent(t).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function IY(t){return jY(t).replace(/%3B/gi,";")}function DY(t){return jY(t).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function RY(t){return decodeURIComponent(t)}function LY(t){return RY(t.replace(/\+/g,"%20"))}function FY(t){return"".concat(DY(t.path)).concat((e=t.parameters,Object.keys(e).map((function(t){return";".concat(DY(t),"=").concat(DY(e[t]))})).join("")));var e}var NY=/^[^\/()?;=#]+/;function BY(t){var e=t.match(NY);return e?e[0]:""}var HY=/^[^=?&#]+/,zY=/^[^?&#]+/,VY=function(){function t(e){Object(m.a)(this,t),this.url=e,this.remaining=e}return Object(g.a)(t,[{key:"parseRootSegment",value:function(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new SY([],{}):new SY([],this.parseChildren())}},{key:"parseQueryParams",value:function(){var t={};if(this.consumeOptional("?"))do{this.parseQueryParam(t)}while(this.consumeOptional("&"));return t}},{key:"parseFragment",value:function(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}},{key:"parseChildren",value:function(){if(""===this.remaining)return{};this.consumeOptional("/");var t=[];for(this.peekStartsWith("(")||t.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),t.push(this.parseSegment());var e={};this.peekStartsWith("/(")&&(this.capture("/"),e=this.parseParens(!0));var n={};return this.peekStartsWith("(")&&(n=this.parseParens(!1)),(t.length>0||Object.keys(e).length>0)&&(n.primary=new SY(t,e)),n}},{key:"parseSegment",value:function(){var t=BY(this.remaining);if(""===t&&this.peekStartsWith(";"))throw new Error("Empty path url segment cannot have parameters: '".concat(this.remaining,"'."));return this.capture(t),new xY(RY(t),this.parseMatrixParams())}},{key:"parseMatrixParams",value:function(){for(var t={};this.consumeOptional(";");)this.parseParam(t);return t}},{key:"parseParam",value:function(t){var e=BY(this.remaining);if(e){this.capture(e);var n="";if(this.consumeOptional("=")){var i=BY(this.remaining);i&&this.capture(n=i)}t[RY(e)]=RY(n)}}},{key:"parseQueryParam",value:function(t){var e,n=(e=this.remaining.match(HY))?e[0]:"";if(n){this.capture(n);var i="";if(this.consumeOptional("=")){var r=function(t){var e=t.match(zY);return e?e[0]:""}(this.remaining);r&&this.capture(i=r)}var o=LY(n),a=LY(i);if(t.hasOwnProperty(o)){var s=t[o];Array.isArray(s)||(t[o]=s=[s]),s.push(a)}else t[o]=a}}},{key:"parseParens",value:function(t){var e={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){var n=BY(this.remaining),i=this.remaining[n.length];if("/"!==i&&")"!==i&&";"!==i)throw new Error("Cannot parse url '".concat(this.url,"'"));var r=void 0;n.indexOf(":")>-1?(r=n.substr(0,n.indexOf(":")),this.capture(r),this.capture(":")):t&&(r="primary");var o=this.parseChildren();e[r]=1===Object.keys(o).length?o.primary:new SY([],o),this.consumeOptional("//")}return e}},{key:"peekStartsWith",value:function(t){return this.remaining.startsWith(t)}},{key:"consumeOptional",value:function(t){return!!this.peekStartsWith(t)&&(this.remaining=this.remaining.substring(t.length),!0)}},{key:"capture",value:function(t){if(!this.consumeOptional(t))throw new Error('Expected "'.concat(t,'".'))}}]),t}(),UY=function(){function t(e){Object(m.a)(this,t),this._root=e}return Object(g.a)(t,[{key:"parent",value:function(t){var e=this.pathFromRoot(t);return e.length>1?e[e.length-2]:null}},{key:"children",value:function(t){var e=qY(t,this._root);return e?e.children.map((function(t){return t.value})):[]}},{key:"firstChild",value:function(t){var e=qY(t,this._root);return e&&e.children.length>0?e.children[0].value:null}},{key:"siblings",value:function(t){var e=GY(t,this._root);return e.length<2?[]:e[e.length-2].children.map((function(t){return t.value})).filter((function(e){return e!==t}))}},{key:"pathFromRoot",value:function(t){return GY(t,this._root).map((function(t){return t.value}))}},{key:"root",get:function(){return this._root.value}}]),t}();function qY(t,e){if(t===e.value)return e;var n,i=d(e.children);try{for(i.s();!(n=i.n()).done;){var r=qY(t,n.value);if(r)return r}}catch(o){i.e(o)}finally{i.f()}return null}function GY(t,e){if(t===e.value)return[e];var n,i=d(e.children);try{for(i.s();!(n=i.n()).done;){var r=GY(t,n.value);if(r.length)return r.unshift(e),r}}catch(o){i.e(o)}finally{i.f()}return[]}var WY=function(){function t(e,n){Object(m.a)(this,t),this.value=e,this.children=n}return Object(g.a)(t,[{key:"toString",value:function(){return"TreeNode(".concat(this.value,")")}}]),t}();function KY(t){var e={};return t&&t.children.forEach((function(t){return e[t.value.outlet]=t})),e}var XY=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this,t)).snapshot=i,eZ(Object(s.a)(r),t),r}return Object(g.a)(n,[{key:"toString",value:function(){return this.snapshot.toString()}}]),n}(UY);function YY(t,e){var n=function(t,e){var n=new JY([],{},{},"",{},"primary",e,null,t.root,-1,{});return new tZ("",new WY(n,[]))}(t,e),i=new Pm.a([new xY("",{})]),r=new Pm.a({}),o=new Pm.a({}),a=new Pm.a({}),s=new Pm.a(""),c=new ZY(i,r,a,s,o,"primary",e,n.root);return c.snapshot=n.root,new XY(new WY(c,[]),n)}var ZY=function(){function t(e,n,i,r,o,a,s,c){Object(m.a)(this,t),this.url=e,this.params=n,this.queryParams=i,this.fragment=r,this.data=o,this.outlet=a,this.component=s,this._futureSnapshot=c}return Object(g.a)(t,[{key:"toString",value:function(){return this.snapshot?this.snapshot.toString():"Future(".concat(this._futureSnapshot,")")}},{key:"routeConfig",get:function(){return this._futureSnapshot.routeConfig}},{key:"root",get:function(){return this._routerState.root}},{key:"parent",get:function(){return this._routerState.parent(this)}},{key:"firstChild",get:function(){return this._routerState.firstChild(this)}},{key:"children",get:function(){return this._routerState.children(this)}},{key:"pathFromRoot",get:function(){return this._routerState.pathFromRoot(this)}},{key:"paramMap",get:function(){return this._paramMap||(this._paramMap=this.params.pipe(Object(ef.a)((function(t){return cY(t)})))),this._paramMap}},{key:"queryParamMap",get:function(){return this._queryParamMap||(this._queryParamMap=this.queryParams.pipe(Object(ef.a)((function(t){return cY(t)})))),this._queryParamMap}}]),t}();function QY(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"emptyOnly",n=t.pathFromRoot,i=0;if("always"!==e)for(i=n.length-1;i>=1;){var r=n[i],o=n[i-1];if(r.routeConfig&&""===r.routeConfig.path)i--;else{if(o.component)break;i--}}return $Y(n.slice(i))}function $Y(t){return t.reduce((function(t,e){return{params:Object.assign(Object.assign({},t.params),e.params),data:Object.assign(Object.assign({},t.data),e.data),resolve:Object.assign(Object.assign({},t.resolve),e._resolvedData)}}),{params:{},data:{},resolve:{}})}var JY=function(){function t(e,n,i,r,o,a,s,c,l,u,h){Object(m.a)(this,t),this.url=e,this.params=n,this.queryParams=i,this.fragment=r,this.data=o,this.outlet=a,this.component=s,this.routeConfig=c,this._urlSegment=l,this._lastPathIndex=u,this._resolve=h}return Object(g.a)(t,[{key:"toString",value:function(){var t=this.url.map((function(t){return t.toString()})).join("/"),e=this.routeConfig?this.routeConfig.path:"";return"Route(url:'".concat(t,"', path:'").concat(e,"')")}},{key:"root",get:function(){return this._routerState.root}},{key:"parent",get:function(){return this._routerState.parent(this)}},{key:"firstChild",get:function(){return this._routerState.firstChild(this)}},{key:"children",get:function(){return this._routerState.children(this)}},{key:"pathFromRoot",get:function(){return this._routerState.pathFromRoot(this)}},{key:"paramMap",get:function(){return this._paramMap||(this._paramMap=cY(this.params)),this._paramMap}},{key:"queryParamMap",get:function(){return this._queryParamMap||(this._queryParamMap=cY(this.queryParams)),this._queryParamMap}}]),t}(),tZ=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this,i)).url=t,eZ(Object(s.a)(r),i),r}return Object(g.a)(n,[{key:"toString",value:function(){return nZ(this._root)}}]),n}(UY);function eZ(t,e){e.value._routerState=t,e.children.forEach((function(e){return eZ(t,e)}))}function nZ(t){var e=t.children.length>0?" { ".concat(t.children.map(nZ).join(", ")," } "):"";return"".concat(t.value).concat(e)}function iZ(t){if(t.snapshot){var e=t.snapshot,n=t._futureSnapshot;t.snapshot=n,gY(e.queryParams,n.queryParams)||t.queryParams.next(n.queryParams),e.fragment!==n.fragment&&t.fragment.next(n.fragment),gY(e.params,n.params)||t.params.next(n.params),function(t,e){if(t.length!==e.length)return!1;for(var n=0;n<t.length;++n)if(!gY(t[n],e[n]))return!1;return!0}(e.url,n.url)||t.url.next(n.url),gY(e.data,n.data)||t.data.next(n.data)}else t.snapshot=t._futureSnapshot,t.data.next(t._futureSnapshot.data)}function rZ(t,e){var n,i;return gY(t.params,e.params)&&OY(n=t.url,i=e.url)&&n.every((function(t,e){return gY(t.parameters,i[e].parameters)}))&&!(!t.parent!=!e.parent)&&(!t.parent||rZ(t.parent,e.parent))}function oZ(t,e,n,i,r){if(0===n.length)return sZ(e.root,e.root,e,i,r);var o=function(t){if("string"==typeof t[0]&&1===t.length&&"/"===t[0])return new cZ(!0,0,t);var e=0,n=!1,i=t.reduce((function(t,i,r){if("object"==typeof i&&null!=i){if(i.outlets){var o={};return _Y(i.outlets,(function(t,e){o[e]="string"==typeof t?t.split("/"):t})),[].concat(Object(u.a)(t),[{outlets:o}])}if(i.segmentPath)return[].concat(Object(u.a)(t),[i.segmentPath])}return"string"!=typeof i?[].concat(Object(u.a)(t),[i]):0===r?(i.split("/").forEach((function(i,r){0==r&&"."===i||(0==r&&""===i?n=!0:".."===i?e++:""!=i&&t.push(i))})),t):[].concat(Object(u.a)(t),[i])}),[]);return new cZ(n,e,i)}(n);if(o.toRoot())return sZ(e.root,new SY([],{}),e,i,r);var a=function(t,e,n){if(t.isAbsolute)return new lZ(e.root,!0,0);if(-1===n.snapshot._lastPathIndex){var i=n.snapshot._urlSegment;return new lZ(i,i===e.root,0)}var r=aZ(t.commands[0])?0:1;return function(t,e,n){for(var i=t,r=e,o=n;o>r;){if(o-=r,!(i=i.parent))throw new Error("Invalid number of '../'");r=i.segments.length}return new lZ(i,!1,r-o)}(n.snapshot._urlSegment,n.snapshot._lastPathIndex+r,t.numberOfDoubleDots)}(o,e,t),s=a.processChildren?dZ(a.segmentGroup,a.index,o.commands):hZ(a.segmentGroup,a.index,o.commands);return sZ(a.segmentGroup,s,e,i,r)}function aZ(t){return"object"==typeof t&&null!=t&&!t.outlets&&!t.segmentPath}function sZ(t,e,n,i,r){var o={};return i&&_Y(i,(function(t,e){o[e]=Array.isArray(t)?t.map((function(t){return"".concat(t)})):"".concat(t)})),new CY(n.root===t?e:function t(e,n,i){var r={};return _Y(e.children,(function(e,o){r[o]=e===n?i:t(e,n,i)})),new SY(e.segments,r)}(n.root,t,e),o,r)}var cZ=function(){function t(e,n,i){if(Object(m.a)(this,t),this.isAbsolute=e,this.numberOfDoubleDots=n,this.commands=i,e&&i.length>0&&aZ(i[0]))throw new Error("Root segment cannot have matrix parameters");var r=i.find((function(t){return"object"==typeof t&&null!=t&&t.outlets}));if(r&&r!==yY(i))throw new Error("{outlets:{}} has to be the last command")}return Object(g.a)(t,[{key:"toRoot",value:function(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}]),t}(),lZ=function t(e,n,i){Object(m.a)(this,t),this.segmentGroup=e,this.processChildren=n,this.index=i};function uZ(t){return"object"==typeof t&&null!=t&&t.outlets?t.outlets.primary:"".concat(t)}function hZ(t,e,n){if(t||(t=new SY([],{})),0===t.segments.length&&t.hasChildren())return dZ(t,e,n);var i=function(t,e,n){for(var i=0,r=e,o={match:!1,pathIndex:0,commandIndex:0};r<t.segments.length;){if(i>=n.length)return o;var a=t.segments[r],s=uZ(n[i]),c=i<n.length-1?n[i+1]:null;if(r>0&&void 0===s)break;if(s&&c&&"object"==typeof c&&void 0===c.outlets){if(!gZ(s,c,a))return o;i+=2}else{if(!gZ(s,{},a))return o;i++}r++}return{match:!0,pathIndex:r,commandIndex:i}}(t,e,n),r=n.slice(i.commandIndex);if(i.match&&i.pathIndex<t.segments.length){var o=new SY(t.segments.slice(0,i.pathIndex),{});return o.children.primary=new SY(t.segments.slice(i.pathIndex),t.children),dZ(o,0,r)}return i.match&&0===r.length?new SY(t.segments,{}):i.match&&!t.hasChildren()?fZ(t,e,n):i.match?dZ(t,0,r):fZ(t,e,n)}function dZ(t,e,n){if(0===n.length)return new SY(t.segments,{});var i=function(t){return"object"==typeof t[0]&&null!==t[0]&&t[0].outlets?t[0].outlets:h({},"primary",t)}(n),r={};return _Y(i,(function(n,i){null!==n&&(r[i]=hZ(t.children[i],e,n))})),_Y(t.children,(function(t,e){void 0===i[e]&&(r[e]=t)})),new SY(t.segments,r)}function fZ(t,e,n){for(var i=t.segments.slice(0,e),r=0;r<n.length;){if("object"==typeof n[r]&&null!==n[r]&&void 0!==n[r].outlets){var o=pZ(n[r].outlets);return new SY(i,o)}if(0===r&&aZ(n[0]))i.push(new xY(t.segments[e].path,n[0])),r++;else{var a=uZ(n[r]),s=r<n.length-1?n[r+1]:null;a&&s&&aZ(s)?(i.push(new xY(a,mZ(s))),r+=2):(i.push(new xY(a,{})),r++)}}return new SY(i,{})}function pZ(t){var e={};return _Y(t,(function(t,n){null!==t&&(e[n]=fZ(new SY([],{}),0,t))})),e}function mZ(t){var e={};return _Y(t,(function(t,n){return e[n]="".concat(t)})),e}function gZ(t,e,n){return t==n.path&&gY(e,n.parameters)}var vZ=function(){function t(e,n,i,r){Object(m.a)(this,t),this.routeReuseStrategy=e,this.futureState=n,this.currState=i,this.forwardEvent=r}return Object(g.a)(t,[{key:"activate",value:function(t){var e=this.futureState._root,n=this.currState?this.currState._root:null;this.deactivateChildRoutes(e,n,t),iZ(this.futureState.root),this.activateChildRoutes(e,n,t)}},{key:"deactivateChildRoutes",value:function(t,e,n){var i=this,r=KY(e);t.children.forEach((function(t){var e=t.value.outlet;i.deactivateRoutes(t,r[e],n),delete r[e]})),_Y(r,(function(t,e){i.deactivateRouteAndItsChildren(t,n)}))}},{key:"deactivateRoutes",value:function(t,e,n){var i=t.value,r=e?e.value:null;if(i===r)if(i.component){var o=n.getContext(i.outlet);o&&this.deactivateChildRoutes(t,e,o.children)}else this.deactivateChildRoutes(t,e,n);else r&&this.deactivateRouteAndItsChildren(e,n)}},{key:"deactivateRouteAndItsChildren",value:function(t,e){this.routeReuseStrategy.shouldDetach(t.value.snapshot)?this.detachAndStoreRouteSubtree(t,e):this.deactivateRouteAndOutlet(t,e)}},{key:"detachAndStoreRouteSubtree",value:function(t,e){var n=e.getContext(t.value.outlet);if(n&&n.outlet){var i=n.outlet.detach(),r=n.children.onOutletDeactivated();this.routeReuseStrategy.store(t.value.snapshot,{componentRef:i,route:t,contexts:r})}}},{key:"deactivateRouteAndOutlet",value:function(t,e){var n=this,i=e.getContext(t.value.outlet);if(i){var r=KY(t),o=t.value.component?i.children:e;_Y(r,(function(t,e){return n.deactivateRouteAndItsChildren(t,o)})),i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated())}}},{key:"activateChildRoutes",value:function(t,e,n){var i=this,r=KY(e);t.children.forEach((function(t){i.activateRoutes(t,r[t.value.outlet],n),i.forwardEvent(new rY(t.value.snapshot))})),t.children.length&&this.forwardEvent(new nY(t.value.snapshot))}},{key:"activateRoutes",value:function(t,e,n){var i=t.value,r=e?e.value:null;if(iZ(i),i===r)if(i.component){var o=n.getOrCreateContext(i.outlet);this.activateChildRoutes(t,e,o.children)}else this.activateChildRoutes(t,e,n);else if(i.component){var a=n.getOrCreateContext(i.outlet);if(this.routeReuseStrategy.shouldAttach(i.snapshot)){var s=this.routeReuseStrategy.retrieve(i.snapshot);this.routeReuseStrategy.store(i.snapshot,null),a.children.onOutletReAttached(s.contexts),a.attachRef=s.componentRef,a.route=s.route.value,a.outlet&&a.outlet.attach(s.componentRef,s.route.value),bZ(s.route)}else{var c=function(t){for(var e=t.parent;e;e=e.parent){var n=e.routeConfig;if(n&&n._loadedConfig)return n._loadedConfig;if(n&&n.component)return null}return null}(i.snapshot),l=c?c.module.componentFactoryResolver:null;a.attachRef=null,a.route=i,a.resolver=l,a.outlet&&a.outlet.activateWith(i,l),this.activateChildRoutes(t,null,a.children)}}else this.activateChildRoutes(t,null,n)}}]),t}();function bZ(t){iZ(t.value),t.children.forEach(bZ)}function yZ(t){return"function"==typeof t}function _Z(t){return t instanceof CY}var wZ=function t(e){Object(m.a)(this,t),this.segmentGroup=e||null},kZ=function t(e){Object(m.a)(this,t),this.urlTree=e};function CZ(t){return new k.a((function(e){return e.error(new wZ(t))}))}function SZ(t){return new k.a((function(e){return e.error(new kZ(t))}))}function xZ(t){return new k.a((function(e){return e.error(new Error("Only absolute redirects can have named outlets. redirectTo: '".concat(t,"'")))}))}var OZ=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this.configLoader=n,this.urlSerializer=i,this.urlTree=r,this.config=o,this.allowRedirects=!0,this.ngModule=e.get(Ot)}return Object(g.a)(t,[{key:"apply",value:function(){var t=this;return this.expandSegmentGroup(this.ngModule,this.config,this.urlTree.root,"primary").pipe(Object(ef.a)((function(e){return t.createUrlTree(e,t.urlTree.queryParams,t.urlTree.fragment)}))).pipe(Object(AX.a)((function(e){if(e instanceof kZ)return t.allowRedirects=!1,t.match(e.urlTree);if(e instanceof wZ)throw t.noMatchError(e);throw e})))}},{key:"match",value:function(t){var e=this;return this.expandSegmentGroup(this.ngModule,this.config,t.root,"primary").pipe(Object(ef.a)((function(n){return e.createUrlTree(n,t.queryParams,t.fragment)}))).pipe(Object(AX.a)((function(t){if(t instanceof wZ)throw e.noMatchError(t);throw t})))}},{key:"noMatchError",value:function(t){return new Error("Cannot match any routes. URL Segment: '".concat(t.segmentGroup,"'"))}},{key:"createUrlTree",value:function(t,e,n){var i=t.segments.length>0?new SY([],h({},"primary",t)):t;return new CY(i,e,n)}},{key:"expandSegmentGroup",value:function(t,e,n,i){return 0===n.segments.length&&n.hasChildren()?this.expandChildren(t,e,n).pipe(Object(ef.a)((function(t){return new SY([],t)}))):this.expandSegment(t,n,e,n.segments,i,!0)}},{key:"expandChildren",value:function(t,e,n){var i=this;return function(n,r){if(0===Object.keys(n).length)return Object(lm.a)({});var o=[],a=[],s={};return _Y(n,(function(n,r){var c,l,u=(c=r,l=n,i.expandSegmentGroup(t,e,l,c)).pipe(Object(ef.a)((function(t){return s[r]=t})));"primary"===r?o.push(u):a.push(u)})),lm.a.apply(null,o.concat(a)).pipe(Object(EX.a)(),Object(PX.a)(),Object(ef.a)((function(){return s})))}(n.children)}},{key:"expandSegment",value:function(t,e,n,i,r,o){var a=this;return lm.a.apply(void 0,Object(u.a)(n)).pipe(Object(ef.a)((function(s){return a.expandSegmentAgainstRoute(t,e,n,s,i,r,o).pipe(Object(AX.a)((function(t){if(t instanceof wZ)return Object(lm.a)(null);throw t})))})),Object(EX.a)(),Object(jX.a)((function(t){return!!t})),Object(AX.a)((function(t,n){if(t instanceof xX.a||"EmptyError"===t.name){if(a.noLeftoversInUrl(e,i,r))return Object(lm.a)(new SY([],{}));throw new wZ(e)}throw t})))}},{key:"noLeftoversInUrl",value:function(t,e,n){return 0===e.length&&!t.children[n]}},{key:"expandSegmentAgainstRoute",value:function(t,e,n,i,r,o,a){return PZ(i)!==o?CZ(e):void 0===i.redirectTo?this.matchSegmentAgainstRoute(t,e,i,r):a&&this.allowRedirects?this.expandSegmentAgainstRouteUsingRedirect(t,e,n,i,r,o):CZ(e)}},{key:"expandSegmentAgainstRouteUsingRedirect",value:function(t,e,n,i,r,o){return"**"===i.path?this.expandWildCardWithParamsAgainstRouteUsingRedirect(t,n,i,o):this.expandRegularSegmentAgainstRouteUsingRedirect(t,e,n,i,r,o)}},{key:"expandWildCardWithParamsAgainstRouteUsingRedirect",value:function(t,e,n,i){var r=this,o=this.applyRedirectCommands([],n.redirectTo,{});return n.redirectTo.startsWith("/")?SZ(o):this.lineralizeSegments(n,o).pipe(Object(IX.a)((function(n){var o=new SY(n,{});return r.expandSegment(t,o,e,n,i,!1)})))}},{key:"expandRegularSegmentAgainstRouteUsingRedirect",value:function(t,e,n,i,r,o){var a=this,s=MZ(e,i,r),c=s.consumedSegments,l=s.lastChild,u=s.positionalParamSegments;if(!s.matched)return CZ(e);var h=this.applyRedirectCommands(c,i.redirectTo,u);return i.redirectTo.startsWith("/")?SZ(h):this.lineralizeSegments(i,h).pipe(Object(IX.a)((function(i){return a.expandSegment(t,e,n,i.concat(r.slice(l)),o,!1)})))}},{key:"matchSegmentAgainstRoute",value:function(t,e,n,i){var r=this;if("**"===n.path)return n.loadChildren?this.configLoader.load(t.injector,n).pipe(Object(ef.a)((function(t){return n._loadedConfig=t,new SY(i,{})}))):Object(lm.a)(new SY(i,{}));var o=MZ(e,n,i),a=o.consumedSegments,s=o.lastChild;if(!o.matched)return CZ(e);var c=i.slice(s);return this.getChildConfig(t,n,i).pipe(Object(IX.a)((function(t){var n=t.module,i=t.routes,o=function(t,e,n,i){return n.length>0&&function(t,e,n){return n.some((function(n){return EZ(t,e,n)&&"primary"!==PZ(n)}))}(t,n,i)?{segmentGroup:TZ(new SY(e,function(t,e){var n={};n.primary=e;var i,r=d(t);try{for(r.s();!(i=r.n()).done;){var o=i.value;""===o.path&&"primary"!==PZ(o)&&(n[PZ(o)]=new SY([],{}))}}catch(a){r.e(a)}finally{r.f()}return n}(i,new SY(n,t.children)))),slicedSegments:[]}:0===n.length&&function(t,e,n){return n.some((function(n){return EZ(t,e,n)}))}(t,n,i)?{segmentGroup:TZ(new SY(t.segments,function(t,e,n,i){var r,o={},a=d(n);try{for(a.s();!(r=a.n()).done;){var s=r.value;EZ(t,e,s)&&!i[PZ(s)]&&(o[PZ(s)]=new SY([],{}))}}catch(c){a.e(c)}finally{a.f()}return Object.assign(Object.assign({},i),o)}(t,n,i,t.children))),slicedSegments:n}:{segmentGroup:t,slicedSegments:n}}(e,a,c,i),s=o.segmentGroup,l=o.slicedSegments;return 0===l.length&&s.hasChildren()?r.expandChildren(n,i,s).pipe(Object(ef.a)((function(t){return new SY(a,t)}))):0===i.length&&0===l.length?Object(lm.a)(new SY(a,{})):r.expandSegment(n,s,i,l,"primary",!0).pipe(Object(ef.a)((function(t){return new SY(a.concat(t.segments),t.children)})))})))}},{key:"getChildConfig",value:function(t,e,n){var i=this;return e.children?Object(lm.a)(new hY(e.children,t)):e.loadChildren?void 0!==e._loadedConfig?Object(lm.a)(e._loadedConfig):this.runCanLoadGuards(t.injector,e,n).pipe(Object(IX.a)((function(n){return n?i.configLoader.load(t.injector,e).pipe(Object(ef.a)((function(t){return e._loadedConfig=t,t}))):function(t){return new k.a((function(e){return e.error(lY("Cannot load children because the guard of the route \"path: '".concat(t.path,"'\" returned false")))}))}(e)}))):Object(lm.a)(new hY([],t))}},{key:"runCanLoadGuards",value:function(t,e,n){var i=this,r=e.canLoad;return r&&0!==r.length?Object(tf.a)(r).pipe(Object(ef.a)((function(i){var r,o=t.get(i);if(function(t){return t&&yZ(t.canLoad)}(o))r=o.canLoad(e,n);else{if(!yZ(o))throw new Error("Invalid CanLoad guard");r=o(e,n)}return wY(r)}))).pipe(Object(EX.a)(),Object(DX.a)((function(t){if(_Z(t)){var e=lY('Redirecting to "'.concat(i.urlSerializer.serialize(t),'"'));throw e.url=t,e}})),Object(RX.a)((function(t){return!0===t}))):Object(lm.a)(!0)}},{key:"lineralizeSegments",value:function(t,e){for(var n=[],i=e.root;;){if(n=n.concat(i.segments),0===i.numberOfChildren)return Object(lm.a)(n);if(i.numberOfChildren>1||!i.children.primary)return xZ(t.redirectTo);i=i.children.primary}}},{key:"applyRedirectCommands",value:function(t,e,n){return this.applyRedirectCreatreUrlTree(e,this.urlSerializer.parse(e),t,n)}},{key:"applyRedirectCreatreUrlTree",value:function(t,e,n,i){var r=this.createSegmentGroup(t,e.root,n,i);return new CY(r,this.createQueryParams(e.queryParams,this.urlTree.queryParams),e.fragment)}},{key:"createQueryParams",value:function(t,e){var n={};return _Y(t,(function(t,i){if("string"==typeof t&&t.startsWith(":")){var r=t.substring(1);n[i]=e[r]}else n[i]=t})),n}},{key:"createSegmentGroup",value:function(t,e,n,i){var r=this,o=this.createSegments(t,e.segments,n,i),a={};return _Y(e.children,(function(e,o){a[o]=r.createSegmentGroup(t,e,n,i)})),new SY(o,a)}},{key:"createSegments",value:function(t,e,n,i){var r=this;return e.map((function(e){return e.path.startsWith(":")?r.findPosParam(t,e,i):r.findOrReturn(e,n)}))}},{key:"findPosParam",value:function(t,e,n){var i=n[e.path.substring(1)];if(!i)throw new Error("Cannot redirect to '".concat(t,"'. Cannot find '").concat(e.path,"'."));return i}},{key:"findOrReturn",value:function(t,e){var n,i=0,r=d(e);try{for(r.s();!(n=r.n()).done;){var o=n.value;if(o.path===t.path)return e.splice(i),o;i++}}catch(a){r.e(a)}finally{r.f()}return t}}]),t}();function MZ(t,e,n){if(""===e.path)return"full"===e.pathMatch&&(t.hasChildren()||n.length>0)?{matched:!1,consumedSegments:[],lastChild:0,positionalParamSegments:{}}:{matched:!0,consumedSegments:[],lastChild:0,positionalParamSegments:{}};var i=(e.matcher||uY)(n,t,e);return i?{matched:!0,consumedSegments:i.consumed,lastChild:i.consumed.length,positionalParamSegments:i.posParams}:{matched:!1,consumedSegments:[],lastChild:0,positionalParamSegments:{}}}function TZ(t){if(1===t.numberOfChildren&&t.children.primary){var e=t.children.primary;return new SY(t.segments.concat(e.segments),e.children)}return t}function EZ(t,e,n){return(!(t.hasChildren()||e.length>0)||"full"!==n.pathMatch)&&""===n.path&&void 0!==n.redirectTo}function PZ(t){return t.outlet||"primary"}var AZ=function t(e){Object(m.a)(this,t),this.path=e,this.route=this.path[this.path.length-1]},jZ=function t(e,n){Object(m.a)(this,t),this.component=e,this.route=n};function IZ(t,e,n){var i=function(t){if(!t)return null;for(var e=t.parent;e;e=e.parent){var n=e.routeConfig;if(n&&n._loadedConfig)return n._loadedConfig}return null}(e);return(i?i.module.injector:n).get(t)}function DZ(t,e,n,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{canDeactivateChecks:[],canActivateChecks:[]},o=KY(e);return t.children.forEach((function(t){RZ(t,o[t.value.outlet],n,i.concat([t.value]),r),delete o[t.value.outlet]})),_Y(o,(function(t,e){return FZ(t,n.getContext(e),r)})),r}function RZ(t,e,n,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{canDeactivateChecks:[],canActivateChecks:[]},o=t.value,a=e?e.value:null,s=n?n.getContext(t.value.outlet):null;if(a&&o.routeConfig===a.routeConfig){var c=LZ(a,o,o.routeConfig.runGuardsAndResolvers);if(c?r.canActivateChecks.push(new AZ(i)):(o.data=a.data,o._resolvedData=a._resolvedData),DZ(t,e,o.component?s?s.children:null:n,i,r),c){var l=s&&s.outlet&&s.outlet.component||null;r.canDeactivateChecks.push(new jZ(l,a))}}else a&&FZ(e,s,r),r.canActivateChecks.push(new AZ(i)),DZ(t,null,o.component?s?s.children:null:n,i,r);return r}function LZ(t,e,n){if("function"==typeof n)return n(t,e);switch(n){case"pathParamsChange":return!OY(t.url,e.url);case"pathParamsOrQueryParamsChange":return!OY(t.url,e.url)||!gY(t.queryParams,e.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!rZ(t,e)||!gY(t.queryParams,e.queryParams);case"paramsChange":default:return!rZ(t,e)}}function FZ(t,e,n){var i=KY(t),r=t.value;_Y(i,(function(t,i){FZ(t,r.component?e?e.children.getContext(i):null:e,n)})),n.canDeactivateChecks.push(new jZ(r.component&&e&&e.outlet&&e.outlet.isActivated?e.outlet.component:null,r))}var NZ=Symbol("INITIAL_VALUE");function BZ(){return Object(LX.a)((function(t){return OX.b.apply(void 0,Object(u.a)(t.map((function(t){return t.pipe(Object(FX.a)(1),Object(NX.a)(NZ))})))).pipe(Object(BX.a)((function(t,e){var n=!1;return e.reduce((function(t,i,r){if(t!==NZ)return t;if(i===NZ&&(n=!0),!n){if(!1===i)return i;if(r===e.length-1||_Z(i))return i}return t}),t)}),NZ),Object(vg.a)((function(t){return t!==NZ})),Object(ef.a)((function(t){return _Z(t)?t:!0===t})),Object(FX.a)(1))}))}function HZ(t,e){return null!==t&&e&&e(new iY(t)),Object(lm.a)(!0)}function zZ(t,e){return null!==t&&e&&e(new eY(t)),Object(lm.a)(!0)}function VZ(t,e,n){var i=e.routeConfig?e.routeConfig.canActivate:null;if(!i||0===i.length)return Object(lm.a)(!0);var r=i.map((function(i){return Object(MX.a)((function(){var r,o=IZ(i,e,n);if(function(t){return t&&yZ(t.canActivate)}(o))r=wY(o.canActivate(e,t));else{if(!yZ(o))throw new Error("Invalid CanActivate guard");r=wY(o(e,t))}return r.pipe(Object(jX.a)())}))}));return Object(lm.a)(r).pipe(BZ())}function UZ(t,e,n){var i=e[e.length-1],r=e.slice(0,e.length-1).reverse().map((function(t){return function(t){var e=t.routeConfig?t.routeConfig.canActivateChild:null;return e&&0!==e.length?{node:t,guards:e}:null}(t)})).filter((function(t){return null!==t})).map((function(e){return Object(MX.a)((function(){var r=e.guards.map((function(r){var o,a=IZ(r,e.node,n);if(function(t){return t&&yZ(t.canActivateChild)}(a))o=wY(a.canActivateChild(i,t));else{if(!yZ(a))throw new Error("Invalid CanActivateChild guard");o=wY(a(i,t))}return o.pipe(Object(jX.a)())}));return Object(lm.a)(r).pipe(BZ())}))}));return Object(lm.a)(r).pipe(BZ())}var qZ=function t(){Object(m.a)(this,t)},GZ=function(){function t(e,n,i,r,o,a){Object(m.a)(this,t),this.rootComponentType=e,this.config=n,this.urlTree=i,this.url=r,this.paramsInheritanceStrategy=o,this.relativeLinkResolution=a}return Object(g.a)(t,[{key:"recognize",value:function(){try{var t=XZ(this.urlTree.root,[],[],this.config,this.relativeLinkResolution).segmentGroup,e=this.processSegmentGroup(this.config,t,"primary"),n=new JY([],Object.freeze({}),Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,{},"primary",this.rootComponentType,null,this.urlTree.root,-1,{}),i=new WY(n,e),r=new tZ(this.url,i);return this.inheritParamsAndData(r._root),Object(lm.a)(r)}catch(o){return new k.a((function(t){return t.error(o)}))}}},{key:"inheritParamsAndData",value:function(t){var e=this,n=t.value,i=QY(n,this.paramsInheritanceStrategy);n.params=Object.freeze(i.params),n.data=Object.freeze(i.data),t.children.forEach((function(t){return e.inheritParamsAndData(t)}))}},{key:"processSegmentGroup",value:function(t,e,n){return 0===e.segments.length&&e.hasChildren()?this.processChildren(t,e):this.processSegment(t,e,e.segments,n)}},{key:"processChildren",value:function(t,e){var n,i=this,r=MY(e,(function(e,n){return i.processSegmentGroup(t,e,n)}));return n={},r.forEach((function(t){var e=n[t.value.outlet];if(e){var i=e.url.map((function(t){return t.toString()})).join("/"),r=t.value.url.map((function(t){return t.toString()})).join("/");throw new Error("Two segments cannot have the same outlet name: '".concat(i,"' and '").concat(r,"'."))}n[t.value.outlet]=t.value})),function(t){t.sort((function(t,e){return"primary"===t.value.outlet?-1:"primary"===e.value.outlet?1:t.value.outlet.localeCompare(e.value.outlet)}))}(r),r}},{key:"processSegment",value:function(t,e,n,i){var r,o=d(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;try{return this.processSegmentAgainstRoute(a,e,n,i)}catch(s){if(!(s instanceof qZ))throw s}}}catch(c){o.e(c)}finally{o.f()}if(this.noLeftoversInUrl(e,n,i))return[];throw new qZ}},{key:"noLeftoversInUrl",value:function(t,e,n){return 0===e.length&&!t.children[n]}},{key:"processSegmentAgainstRoute",value:function(t,e,n,i){if(t.redirectTo)throw new qZ;if((t.outlet||"primary")!==i)throw new qZ;var r,o=[],a=[];if("**"===t.path){var s=n.length>0?yY(n).parameters:{};r=new JY(n,s,Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,QZ(t),i,t.component,t,WZ(e),KZ(e)+n.length,$Z(t))}else{var c=function(t,e,n){if(""===e.path){if("full"===e.pathMatch&&(t.hasChildren()||n.length>0))throw new qZ;return{consumedSegments:[],lastChild:0,parameters:{}}}var i=(e.matcher||uY)(n,t,e);if(!i)throw new qZ;var r={};_Y(i.posParams,(function(t,e){r[e]=t.path}));var o=i.consumed.length>0?Object.assign(Object.assign({},r),i.consumed[i.consumed.length-1].parameters):r;return{consumedSegments:i.consumed,lastChild:i.consumed.length,parameters:o}}(e,t,n);o=c.consumedSegments,a=n.slice(c.lastChild),r=new JY(o,c.parameters,Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,QZ(t),i,t.component,t,WZ(e),KZ(e)+o.length,$Z(t))}var l=function(t){return t.children?t.children:t.loadChildren?t._loadedConfig.routes:[]}(t),u=XZ(e,o,a,l,this.relativeLinkResolution),h=u.segmentGroup,d=u.slicedSegments;if(0===d.length&&h.hasChildren()){var f=this.processChildren(l,h);return[new WY(r,f)]}if(0===l.length&&0===d.length)return[new WY(r,[])];var p=this.processSegment(l,h,d,"primary");return[new WY(r,p)]}}]),t}();function WZ(t){for(var e=t;e._sourceSegment;)e=e._sourceSegment;return e}function KZ(t){for(var e=t,n=e._segmentIndexShift?e._segmentIndexShift:0;e._sourceSegment;)n+=(e=e._sourceSegment)._segmentIndexShift?e._segmentIndexShift:0;return n-1}function XZ(t,e,n,i,r){if(n.length>0&&function(t,e,n){return n.some((function(n){return YZ(t,e,n)&&"primary"!==ZZ(n)}))}(t,n,i)){var o=new SY(e,function(t,e,n,i){var r={};r.primary=i,i._sourceSegment=t,i._segmentIndexShift=e.length;var o,a=d(n);try{for(a.s();!(o=a.n()).done;){var s=o.value;if(""===s.path&&"primary"!==ZZ(s)){var c=new SY([],{});c._sourceSegment=t,c._segmentIndexShift=e.length,r[ZZ(s)]=c}}}catch(l){a.e(l)}finally{a.f()}return r}(t,e,i,new SY(n,t.children)));return o._sourceSegment=t,o._segmentIndexShift=e.length,{segmentGroup:o,slicedSegments:[]}}if(0===n.length&&function(t,e,n){return n.some((function(n){return YZ(t,e,n)}))}(t,n,i)){var a=new SY(t.segments,function(t,e,n,i,r,o){var a,s={},c=d(i);try{for(c.s();!(a=c.n()).done;){var l=a.value;if(YZ(t,n,l)&&!r[ZZ(l)]){var u=new SY([],{});u._sourceSegment=t,u._segmentIndexShift="legacy"===o?t.segments.length:e.length,s[ZZ(l)]=u}}}catch(h){c.e(h)}finally{c.f()}return Object.assign(Object.assign({},r),s)}(t,e,n,i,t.children,r));return a._sourceSegment=t,a._segmentIndexShift=e.length,{segmentGroup:a,slicedSegments:n}}var s=new SY(t.segments,t.children);return s._sourceSegment=t,s._segmentIndexShift=e.length,{segmentGroup:s,slicedSegments:n}}function YZ(t,e,n){return(!(t.hasChildren()||e.length>0)||"full"!==n.pathMatch)&&""===n.path&&void 0===n.redirectTo}function ZZ(t){return t.outlet||"primary"}function QZ(t){return t.data||{}}function $Z(t){return t.resolve||{}}function JZ(t){return function(e){return e.pipe(Object(LX.a)((function(e){var n=t(e);return n?Object(tf.a)(n).pipe(Object(ef.a)((function(){return e}))):Object(tf.a)([e])})))}}var tQ=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"shouldDetach",value:function(t){return!1}},{key:"store",value:function(t,e){}},{key:"shouldAttach",value:function(t){return!1}},{key:"retrieve",value:function(t){return null}},{key:"shouldReuseRoute",value:function(t,e){return t.routeConfig===e.routeConfig}}]),t}(),eQ=new ht("ROUTES"),nQ=function(){function t(e,n,i,r){Object(m.a)(this,t),this.loader=e,this.compiler=n,this.onLoadStartListener=i,this.onLoadEndListener=r}return Object(g.a)(t,[{key:"load",value:function(t,e){var n=this;return this.onLoadStartListener&&this.onLoadStartListener(e),this.loadModuleFactory(e.loadChildren).pipe(Object(ef.a)((function(i){n.onLoadEndListener&&n.onLoadEndListener(e);var r=i.create(t);return new hY(bY(r.injector.get(eQ)).map(mY),r)})))}},{key:"loadModuleFactory",value:function(t){var e=this;return"string"==typeof t?Object(tf.a)(this.loader.load(t)):wY(t()).pipe(Object(IX.a)((function(t){return t instanceof Mt?Object(lm.a)(t):Object(tf.a)(e.compiler.compileModuleAsync(t))})))}}]),t}(),iQ=function t(){Object(m.a)(this,t),this.outlet=null,this.route=null,this.resolver=null,this.children=new rQ,this.attachRef=null},rQ=function(){function t(){Object(m.a)(this,t),this.contexts=new Map}return Object(g.a)(t,[{key:"onChildOutletCreated",value:function(t,e){var n=this.getOrCreateContext(t);n.outlet=e,this.contexts.set(t,n)}},{key:"onChildOutletDestroyed",value:function(t){var e=this.getContext(t);e&&(e.outlet=null)}},{key:"onOutletDeactivated",value:function(){var t=this.contexts;return this.contexts=new Map,t}},{key:"onOutletReAttached",value:function(t){this.contexts=t}},{key:"getOrCreateContext",value:function(t){var e=this.getContext(t);return e||(e=new iQ,this.contexts.set(t,e)),e}},{key:"getContext",value:function(t){return this.contexts.get(t)||null}}]),t}(),oQ=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"shouldProcessUrl",value:function(t){return!0}},{key:"extract",value:function(t){return t}},{key:"merge",value:function(t,e){return t}}]),t}();function aQ(t){throw t}function sQ(t,e,n){return e.parse("/")}function cQ(t,e){return Object(lm.a)(null)}var lQ=function(){var t=function(){function t(e,n,i,r,o,a,s,c){var l=this;Object(m.a)(this,t),this.rootComponentType=e,this.urlSerializer=n,this.rootContexts=i,this.location=r,this.config=c,this.lastSuccessfulNavigation=null,this.currentNavigation=null,this.navigationId=0,this.isNgZoneEnabled=!1,this.events=new w.b,this.errorHandler=aQ,this.malformedUriErrorHandler=sQ,this.navigated=!1,this.lastSuccessfulId=-1,this.hooks={beforePreactivation:cQ,afterPreactivation:cQ},this.urlHandlingStrategy=new oQ,this.routeReuseStrategy=new tQ,this.onSameUrlNavigation="ignore",this.paramsInheritanceStrategy="emptyOnly",this.urlUpdateStrategy="deferred",this.relativeLinkResolution="legacy",this.ngModule=o.get(Ot),this.console=o.get(yl);var u=o.get(jl);this.isNgZoneEnabled=u instanceof jl,this.resetConfig(c),this.currentUrlTree=new CY(new SY([],{}),{},null),this.rawUrlTree=this.currentUrlTree,this.browserUrlTree=this.currentUrlTree,this.configLoader=new nQ(a,s,(function(t){return l.triggerEvent(new JX(t))}),(function(t){return l.triggerEvent(new tY(t))})),this.routerState=YY(this.currentUrlTree,this.rootComponentType),this.transitions=new Pm.a({id:0,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,extractedUrl:this.urlHandlingStrategy.extract(this.currentUrlTree),urlAfterRedirects:this.urlHandlingStrategy.extract(this.currentUrlTree),rawUrl:this.currentUrlTree,extras:{},resolve:null,reject:null,promise:Promise.resolve(!0),source:"imperative",restoredState:null,currentSnapshot:this.routerState.snapshot,targetSnapshot:null,currentRouterState:this.routerState,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.navigations=this.setupNavigations(this.transitions),this.processNavigations()}return Object(g.a)(t,[{key:"setupNavigations",value:function(t){var e=this,n=this.events;return t.pipe(Object(vg.a)((function(t){return 0!==t.id})),Object(ef.a)((function(t){return Object.assign(Object.assign({},t),{extractedUrl:e.urlHandlingStrategy.extract(t.rawUrl)})})),Object(LX.a)((function(t){var i,r,o,a=!1,s=!1;return Object(lm.a)(t).pipe(Object(DX.a)((function(t){e.currentNavigation={id:t.id,initialUrl:t.currentRawUrl,extractedUrl:t.extractedUrl,trigger:t.source,extras:t.extras,previousNavigation:e.lastSuccessfulNavigation?Object.assign(Object.assign({},e.lastSuccessfulNavigation),{previousNavigation:null}):null}})),Object(LX.a)((function(t){var i,r,o,a,s=!e.navigated||t.extractedUrl.toString()!==e.browserUrlTree.toString();if(("reload"===e.onSameUrlNavigation||s)&&e.urlHandlingStrategy.shouldProcessUrl(t.rawUrl))return Object(lm.a)(t).pipe(Object(LX.a)((function(t){var i=e.transitions.getValue();return n.next(new qX(t.id,e.serializeUrl(t.extractedUrl),t.source,t.restoredState)),i!==e.transitions.getValue()?TX.a:[t]})),Object(LX.a)((function(t){return Promise.resolve(t)})),(i=e.ngModule.injector,r=e.configLoader,o=e.urlSerializer,a=e.config,function(t){return t.pipe(Object(LX.a)((function(t){return function(t,e,n,i,r){return new OZ(t,e,n,i,r).apply()}(i,r,o,t.extractedUrl,a).pipe(Object(ef.a)((function(e){return Object.assign(Object.assign({},t),{urlAfterRedirects:e})})))})))}),Object(DX.a)((function(t){e.currentNavigation=Object.assign(Object.assign({},e.currentNavigation),{finalUrl:t.urlAfterRedirects})})),function(t,n,i,r,o){return function(i){return i.pipe(Object(IX.a)((function(i){return function(t,e,n,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"emptyOnly",o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"legacy";return new GZ(t,e,n,i,r,o).recognize()}(t,n,i.urlAfterRedirects,(a=i.urlAfterRedirects,e.serializeUrl(a)),r,o).pipe(Object(ef.a)((function(t){return Object.assign(Object.assign({},i),{targetSnapshot:t})})));var a})))}}(e.rootComponentType,e.config,0,e.paramsInheritanceStrategy,e.relativeLinkResolution),Object(DX.a)((function(t){"eager"===e.urlUpdateStrategy&&(t.extras.skipLocationChange||e.setBrowserUrl(t.urlAfterRedirects,!!t.extras.replaceUrl,t.id,t.extras.state),e.browserUrlTree=t.urlAfterRedirects)})),Object(DX.a)((function(t){var i=new XX(t.id,e.serializeUrl(t.extractedUrl),e.serializeUrl(t.urlAfterRedirects),t.targetSnapshot);n.next(i)})));if(s&&e.rawUrlTree&&e.urlHandlingStrategy.shouldProcessUrl(e.rawUrlTree)){var c=t.extractedUrl,l=t.source,u=t.restoredState,h=t.extras,d=new qX(t.id,e.serializeUrl(c),l,u);n.next(d);var f=YY(c,e.rootComponentType).snapshot;return Object(lm.a)(Object.assign(Object.assign({},t),{targetSnapshot:f,urlAfterRedirects:c,extras:Object.assign(Object.assign({},h),{skipLocationChange:!1,replaceUrl:!1})}))}return e.rawUrlTree=t.rawUrl,e.browserUrlTree=t.urlAfterRedirects,t.resolve(null),TX.a})),JZ((function(t){var n=t.extras;return e.hooks.beforePreactivation(t.targetSnapshot,{navigationId:t.id,appliedUrlTree:t.extractedUrl,rawUrlTree:t.rawUrl,skipLocationChange:!!n.skipLocationChange,replaceUrl:!!n.replaceUrl})})),Object(DX.a)((function(t){var n=new YX(t.id,e.serializeUrl(t.extractedUrl),e.serializeUrl(t.urlAfterRedirects),t.targetSnapshot);e.triggerEvent(n)})),Object(ef.a)((function(t){return Object.assign(Object.assign({},t),{guards:(n=t.targetSnapshot,i=t.currentSnapshot,r=e.rootContexts,o=n._root,DZ(o,i?i._root:null,r,[o.value]))});var n,i,r,o})),function(t,e){return function(n){return n.pipe(Object(IX.a)((function(n){var i=n.targetSnapshot,r=n.currentSnapshot,o=n.guards,a=o.canActivateChecks,s=o.canDeactivateChecks;return 0===s.length&&0===a.length?Object(lm.a)(Object.assign(Object.assign({},n),{guardsResult:!0})):function(t,e,n,i){return Object(tf.a)(t).pipe(Object(IX.a)((function(t){return function(t,e,n,i,r){var o=e&&e.routeConfig?e.routeConfig.canDeactivate:null;if(!o||0===o.length)return Object(lm.a)(!0);var a=o.map((function(o){var a,s=IZ(o,e,r);if(function(t){return t&&yZ(t.canDeactivate)}(s))a=wY(s.canDeactivate(t,e,n,i));else{if(!yZ(s))throw new Error("Invalid CanDeactivate guard");a=wY(s(t,e,n,i))}return a.pipe(Object(jX.a)())}));return Object(lm.a)(a).pipe(BZ())}(t.component,t.route,n,e,i)})),Object(jX.a)((function(t){return!0!==t}),!0))}(s,i,r,t).pipe(Object(IX.a)((function(n){return n&&"boolean"==typeof n?function(t,e,n,i){return Object(tf.a)(e).pipe(Object(gg.a)((function(e){return Object(tf.a)([zZ(e.route.parent,i),HZ(e.route,i),UZ(t,e.path,n),VZ(t,e.route,n)]).pipe(Object(EX.a)(),Object(jX.a)((function(t){return!0!==t}),!0))})),Object(jX.a)((function(t){return!0!==t}),!0))}(i,a,t,e):Object(lm.a)(n)})),Object(ef.a)((function(t){return Object.assign(Object.assign({},n),{guardsResult:t})})))})))}}(e.ngModule.injector,(function(t){return e.triggerEvent(t)})),Object(DX.a)((function(t){if(_Z(t.guardsResult)){var n=lY('Redirecting to "'.concat(e.serializeUrl(t.guardsResult),'"'));throw n.url=t.guardsResult,n}})),Object(DX.a)((function(t){var n=new ZX(t.id,e.serializeUrl(t.extractedUrl),e.serializeUrl(t.urlAfterRedirects),t.targetSnapshot,!!t.guardsResult);e.triggerEvent(n)})),Object(vg.a)((function(t){if(!t.guardsResult){e.resetUrlToCurrentUrlTree();var i=new WX(t.id,e.serializeUrl(t.extractedUrl),"");return n.next(i),t.resolve(!1),!1}return!0})),JZ((function(t){if(t.guards.canActivateChecks.length)return Object(lm.a)(t).pipe(Object(DX.a)((function(t){var n=new QX(t.id,e.serializeUrl(t.extractedUrl),e.serializeUrl(t.urlAfterRedirects),t.targetSnapshot);e.triggerEvent(n)})),Object(LX.a)((function(t){var i,r,o=!1;return Object(lm.a)(t).pipe((i=e.paramsInheritanceStrategy,r=e.ngModule.injector,function(t){return t.pipe(Object(IX.a)((function(t){var e=t.targetSnapshot,n=t.guards.canActivateChecks;if(!n.length)return Object(lm.a)(t);var o=0;return Object(tf.a)(n).pipe(Object(gg.a)((function(t){return function(t,e,n,i){return function(t,e,n,i){var r=Object.keys(t);if(0===r.length)return Object(lm.a)({});var o={};return Object(tf.a)(r).pipe(Object(IX.a)((function(r){return function(t,e,n,i){var r=IZ(t,e,i);return wY(r.resolve?r.resolve(e,n):r(e,n))}(t[r],e,n,i).pipe(Object(DX.a)((function(t){o[r]=t})))})),Object(HX.a)(1),Object(IX.a)((function(){return Object.keys(o).length===r.length?Object(lm.a)(o):TX.a})))}(t._resolve,t,e,i).pipe(Object(ef.a)((function(e){return t._resolvedData=e,t.data=Object.assign(Object.assign({},t.data),QY(t,n).resolve),null})))}(t.route,e,i,r)})),Object(DX.a)((function(){return o++})),Object(HX.a)(1),Object(IX.a)((function(e){return o===n.length?Object(lm.a)(t):TX.a})))})))}),Object(DX.a)({next:function(){return o=!0},complete:function(){if(!o){var i=new WX(t.id,e.serializeUrl(t.extractedUrl),"At least one route resolver didn't emit any value.");n.next(i),t.resolve(!1)}}}))})),Object(DX.a)((function(t){var n=new $X(t.id,e.serializeUrl(t.extractedUrl),e.serializeUrl(t.urlAfterRedirects),t.targetSnapshot);e.triggerEvent(n)})))})),JZ((function(t){var n=t.extras;return e.hooks.afterPreactivation(t.targetSnapshot,{navigationId:t.id,appliedUrlTree:t.extractedUrl,rawUrlTree:t.rawUrl,skipLocationChange:!!n.skipLocationChange,replaceUrl:!!n.replaceUrl})})),Object(ef.a)((function(t){var n,i,r,o=(r=function t(e,n,i){if(i&&e.shouldReuseRoute(n.value,i.value.snapshot)){var r=i.value;r._futureSnapshot=n.value;var o=function(e,n,i){return n.children.map((function(n){var r,o=d(i.children);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.shouldReuseRoute(a.value.snapshot,n.value))return t(e,n,a)}}catch(s){o.e(s)}finally{o.f()}return t(e,n)}))}(e,n,i);return new WY(r,o)}var a=e.retrieve(n.value);if(a){var s=a.route;return function t(e,n){if(e.value.routeConfig!==n.value.routeConfig)throw new Error("Cannot reattach ActivatedRouteSnapshot created from a different route");if(e.children.length!==n.children.length)throw new Error("Cannot reattach ActivatedRouteSnapshot with a different number of children");n.value._futureSnapshot=e.value;for(var i=0;i<e.children.length;++i)t(e.children[i],n.children[i])}(n,s),s}var c,l=new ZY(new Pm.a((c=n.value).url),new Pm.a(c.params),new Pm.a(c.queryParams),new Pm.a(c.fragment),new Pm.a(c.data),c.outlet,c.component,c),u=n.children.map((function(n){return t(e,n)}));return new WY(l,u)}(e.routeReuseStrategy,(n=t.targetSnapshot)._root,(i=t.currentRouterState)?i._root:void 0),new XY(r,n));return Object.assign(Object.assign({},t),{targetRouterState:o})})),Object(DX.a)((function(t){e.currentUrlTree=t.urlAfterRedirects,e.rawUrlTree=e.urlHandlingStrategy.merge(e.currentUrlTree,t.rawUrl),e.routerState=t.targetRouterState,"deferred"===e.urlUpdateStrategy&&(t.extras.skipLocationChange||e.setBrowserUrl(e.rawUrlTree,!!t.extras.replaceUrl,t.id,t.extras.state),e.browserUrlTree=t.urlAfterRedirects)})),(i=e.rootContexts,r=e.routeReuseStrategy,o=function(t){return e.triggerEvent(t)},Object(ef.a)((function(t){return new vZ(r,t.targetRouterState,t.currentRouterState,o).activate(i),t}))),Object(DX.a)({next:function(){a=!0},complete:function(){a=!0}}),Object(zX.a)((function(){if(!a&&!s){e.resetUrlToCurrentUrlTree();var i=new WX(t.id,e.serializeUrl(t.extractedUrl),"Navigation ID ".concat(t.id," is not equal to the current navigation id ").concat(e.navigationId));n.next(i),t.resolve(!1)}e.currentNavigation=null})),Object(AX.a)((function(i){if(s=!0,(c=i)&&c.ngNavigationCancelingError){var r=_Z(i.url);r||(e.navigated=!0,e.resetStateAndUrl(t.currentRouterState,t.currentUrlTree,t.rawUrl));var o=new WX(t.id,e.serializeUrl(t.extractedUrl),i.message);n.next(o),r?setTimeout((function(){var n=e.urlHandlingStrategy.merge(i.url,e.rawUrlTree);return e.scheduleNavigation(n,"imperative",null,{skipLocationChange:t.extras.skipLocationChange,replaceUrl:"eager"===e.urlUpdateStrategy},{resolve:t.resolve,reject:t.reject,promise:t.promise})}),0):t.resolve(!1)}else{e.resetStateAndUrl(t.currentRouterState,t.currentUrlTree,t.rawUrl);var a=new KX(t.id,e.serializeUrl(t.extractedUrl),i);n.next(a);try{t.resolve(e.errorHandler(i))}catch(l){t.reject(l)}}var c;return TX.a})))})))}},{key:"resetRootComponentType",value:function(t){this.rootComponentType=t,this.routerState.root.component=this.rootComponentType}},{key:"getTransition",value:function(){var t=this.transitions.value;return t.urlAfterRedirects=this.browserUrlTree,t}},{key:"setTransition",value:function(t){this.transitions.next(Object.assign(Object.assign({},this.getTransition()),t))}},{key:"initialNavigation",value:function(){this.setUpLocationChangeListener(),0===this.navigationId&&this.navigateByUrl(this.location.path(!0),{replaceUrl:!0})}},{key:"setUpLocationChangeListener",value:function(){var t=this;this.locationSubscription||(this.locationSubscription=this.location.subscribe((function(e){var n=t.parseUrl(e.url),i="popstate"===e.type?"popstate":"hashchange",r=e.state&&e.state.navigationId?e.state:null;setTimeout((function(){t.scheduleNavigation(n,i,r,{replaceUrl:!0})}),0)})))}},{key:"getCurrentNavigation",value:function(){return this.currentNavigation}},{key:"triggerEvent",value:function(t){this.events.next(t)}},{key:"resetConfig",value:function(t){dY(t),this.config=t.map(mY),this.navigated=!1,this.lastSuccessfulId=-1}},{key:"ngOnDestroy",value:function(){this.dispose()}},{key:"dispose",value:function(){this.locationSubscription&&(this.locationSubscription.unsubscribe(),this.locationSubscription=null)}},{key:"createUrlTree",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.relativeTo,i=e.queryParams,r=e.fragment,o=e.preserveQueryParams,a=e.queryParamsHandling,s=e.preserveFragment;ii()&&o&&console&&console.warn&&console.warn("preserveQueryParams is deprecated, use queryParamsHandling instead.");var c=n||this.routerState.root,l=s?this.currentUrlTree.fragment:r,u=null;if(a)switch(a){case"merge":u=Object.assign(Object.assign({},this.currentUrlTree.queryParams),i);break;case"preserve":u=this.currentUrlTree.queryParams;break;default:u=i||null}else u=o?this.currentUrlTree.queryParams:i||null;return null!==u&&(u=this.removeEmptyProps(u)),oZ(c,this.currentUrlTree,t,u,l)}},{key:"navigateByUrl",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{skipLocationChange:!1};ii()&&this.isNgZoneEnabled&&!jl.isInAngularZone()&&this.console.warn("Navigation triggered outside Angular zone, did you forget to call 'ngZone.run()'?");var n=_Z(t)?t:this.parseUrl(t),i=this.urlHandlingStrategy.merge(n,this.rawUrlTree);return this.scheduleNavigation(i,"imperative",null,e)}},{key:"navigate",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{skipLocationChange:!1};return uQ(t),this.navigateByUrl(this.createUrlTree(t,e),e)}},{key:"serializeUrl",value:function(t){return this.urlSerializer.serialize(t)}},{key:"parseUrl",value:function(t){var e;try{e=this.urlSerializer.parse(t)}catch(n){e=this.malformedUriErrorHandler(n,this.urlSerializer,t)}return e}},{key:"isActive",value:function(t,e){if(_Z(t))return kY(this.currentUrlTree,t,e);var n=this.parseUrl(t);return kY(this.currentUrlTree,n,e)}},{key:"removeEmptyProps",value:function(t){return Object.keys(t).reduce((function(e,n){var i=t[n];return null!=i&&(e[n]=i),e}),{})}},{key:"processNavigations",value:function(){var t=this;this.navigations.subscribe((function(e){t.navigated=!0,t.lastSuccessfulId=e.id,t.events.next(new GX(e.id,t.serializeUrl(e.extractedUrl),t.serializeUrl(t.currentUrlTree))),t.lastSuccessfulNavigation=t.currentNavigation,t.currentNavigation=null,e.resolve(!0)}),(function(e){t.console.warn("Unhandled Navigation Error: ")}))}},{key:"scheduleNavigation",value:function(t,e,n,i,r){var o,a,s,c=this.getTransition();if(c&&"imperative"!==e&&"imperative"===c.source&&c.rawUrl.toString()===t.toString())return Promise.resolve(!0);if(c&&"hashchange"==e&&"popstate"===c.source&&c.rawUrl.toString()===t.toString())return Promise.resolve(!0);if(c&&"popstate"==e&&"hashchange"===c.source&&c.rawUrl.toString()===t.toString())return Promise.resolve(!0);r?(o=r.resolve,a=r.reject,s=r.promise):s=new Promise((function(t,e){o=t,a=e}));var l=++this.navigationId;return this.setTransition({id:l,source:e,restoredState:n,currentUrlTree:this.currentUrlTree,currentRawUrl:this.rawUrlTree,rawUrl:t,extras:i,resolve:o,reject:a,promise:s,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),s.catch((function(t){return Promise.reject(t)}))}},{key:"setBrowserUrl",value:function(t,e,n,i){var r=this.urlSerializer.serialize(t);i=i||{},this.location.isCurrentPathEqualTo(r)||e?this.location.replaceState(r,"",Object.assign(Object.assign({},i),{navigationId:n})):this.location.go(r,"",Object.assign(Object.assign({},i),{navigationId:n}))}},{key:"resetStateAndUrl",value:function(t,e,n){this.routerState=t,this.currentUrlTree=e,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,n),this.resetUrlToCurrentUrlTree()}},{key:"resetUrlToCurrentUrlTree",value:function(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",{navigationId:this.lastSuccessfulId})}},{key:"url",get:function(){return this.serializeUrl(this.currentUrlTree)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(jo),_t(TY),_t(rQ),_t(Mu),_t(Xo),_t(eu),_t(El),_t(void 0))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}();function uQ(t){for(var e=0;e<t.length;e++){var n=t[e];if(null==n)throw new Error("The requested path contains ".concat(n," segment at index ").concat(e))}}var hQ=function(){var t=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this.router=e,this.route=n,this.commands=[],null==i&&r.setAttribute(o.nativeElement,"tabindex","0")}return Object(g.a)(t,[{key:"onClick",value:function(){var t={skipLocationChange:fQ(this.skipLocationChange),replaceUrl:fQ(this.replaceUrl),state:this.state};return this.router.navigateByUrl(this.urlTree,t),!0}},{key:"routerLink",set:function(t){this.commands=null!=t?Array.isArray(t)?t:[t]:[]}},{key:"preserveQueryParams",set:function(t){ii()&&console&&console.warn&&console.warn("preserveQueryParams is deprecated!, use queryParamsHandling instead."),this.preserve=t}},{key:"urlTree",get:function(){return this.router.createUrlTree(this.commands,{relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,preserveQueryParams:fQ(this.preserve),queryParamsHandling:this.queryParamsHandling,preserveFragment:fQ(this.preserveFragment)})}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(lQ),da(ZY),fa("tabindex"),da(Ks),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","routerLink","",5,"a",5,"area"]],hostBindings:function(t,e){1&t&&xa("click",(function(){return e.onClick()}))},inputs:{routerLink:"routerLink",preserveQueryParams:"preserveQueryParams",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",preserveFragment:"preserveFragment",skipLocationChange:"skipLocationChange",replaceUrl:"replaceUrl",state:"state"}}),t}(),dQ=function(){var t=function(){function t(e,n,i){var r=this;Object(m.a)(this,t),this.router=e,this.route=n,this.locationStrategy=i,this.commands=[],this.subscription=e.events.subscribe((function(t){t instanceof GX&&r.updateTargetUrlAndHref()}))}return Object(g.a)(t,[{key:"ngOnChanges",value:function(t){this.updateTargetUrlAndHref()}},{key:"ngOnDestroy",value:function(){this.subscription.unsubscribe()}},{key:"onClick",value:function(t,e,n,i){if(0!==t||e||n||i)return!0;if("string"==typeof this.target&&"_self"!=this.target)return!0;var r={skipLocationChange:fQ(this.skipLocationChange),replaceUrl:fQ(this.replaceUrl),state:this.state};return this.router.navigateByUrl(this.urlTree,r),!1}},{key:"updateTargetUrlAndHref",value:function(){this.href=this.locationStrategy.prepareExternalUrl(this.router.serializeUrl(this.urlTree))}},{key:"routerLink",set:function(t){this.commands=null!=t?Array.isArray(t)?t:[t]:[]}},{key:"preserveQueryParams",set:function(t){ii()&&console&&console.warn&&console.warn("preserveQueryParams is deprecated, use queryParamsHandling instead."),this.preserve=t}},{key:"urlTree",get:function(){return this.router.createUrlTree(this.commands,{relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,preserveQueryParams:fQ(this.preserve),queryParamsHandling:this.queryParamsHandling,preserveFragment:fQ(this.preserveFragment)})}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(lQ),da(ZY),da(ku))},t.\u0275dir=Wt({type:t,selectors:[["a","routerLink",""],["area","routerLink",""]],hostVars:2,hostBindings:function(t,e){1&t&&xa("click",(function(t){return e.onClick(t.button,t.ctrlKey,t.metaKey,t.shiftKey)})),2&t&&(bs("href",e.href,Pi),oa("target",e.target))},inputs:{routerLink:"routerLink",preserveQueryParams:"preserveQueryParams",target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",preserveFragment:"preserveFragment",skipLocationChange:"skipLocationChange",replaceUrl:"replaceUrl",state:"state"},features:[Ms]}),t}();function fQ(t){return""===t||!!t}var pQ=function(){var t=function(){function t(e,n,i,r,o,a){var s=this;Object(m.a)(this,t),this.router=e,this.element=n,this.renderer=i,this.cdr=r,this.link=o,this.linkWithHref=a,this.classes=[],this.isActive=!1,this.routerLinkActiveOptions={exact:!1},this.subscription=e.events.subscribe((function(t){t instanceof GX&&s.update()}))}return Object(g.a)(t,[{key:"ngAfterContentInit",value:function(){var t=this;this.links.changes.subscribe((function(e){return t.update()})),this.linksWithHrefs.changes.subscribe((function(e){return t.update()})),this.update()}},{key:"ngOnChanges",value:function(t){this.update()}},{key:"ngOnDestroy",value:function(){this.subscription.unsubscribe()}},{key:"update",value:function(){var t=this;this.links&&this.linksWithHrefs&&this.router.navigated&&Promise.resolve().then((function(){var e=t.hasActiveLinks();t.isActive!==e&&(t.isActive=e,t.cdr.markForCheck(),t.classes.forEach((function(n){e?t.renderer.addClass(t.element.nativeElement,n):t.renderer.removeClass(t.element.nativeElement,n)})))}))}},{key:"isLinkActive",value:function(t){var e=this;return function(n){return t.isActive(n.urlTree,e.routerLinkActiveOptions.exact)}}},{key:"hasActiveLinks",value:function(){var t=this.isLinkActive(this.router);return this.link&&t(this.link)||this.linkWithHref&&t(this.linkWithHref)||this.links.some(t)||this.linksWithHrefs.some(t)}},{key:"routerLinkActive",set:function(t){var e=Array.isArray(t)?t:t.split(" ");this.classes=e.filter((function(t){return!!t}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(lQ),da(Us),da(Ks),da(Po),da(hQ,8),da(dQ,8))},t.\u0275dir=Wt({type:t,selectors:[["","routerLinkActive",""]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,hQ,!0),rl(n,dQ,!0)),2&t&&(tl(i=sl())&&(e.links=i),tl(i=sl())&&(e.linksWithHrefs=i))},inputs:{routerLinkActiveOptions:"routerLinkActiveOptions",routerLinkActive:"routerLinkActive"},exportAs:["routerLinkActive"],features:[Ms]}),t}(),mQ=function(){var t=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this.parentContexts=e,this.location=n,this.resolver=i,this.changeDetector=o,this.activated=null,this._activatedRoute=null,this.activateEvents=new Uc,this.deactivateEvents=new Uc,this.name=r||"primary",e.onChildOutletCreated(this.name,this)}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this.parentContexts.onChildOutletDestroyed(this.name)}},{key:"ngOnInit",value:function(){if(!this.activated){var t=this.parentContexts.getContext(this.name);t&&t.route&&(t.attachRef?this.attach(t.attachRef,t.route):this.activateWith(t.route,t.resolver||null))}}},{key:"detach",value:function(){if(!this.activated)throw new Error("Outlet is not activated");this.location.detach();var t=this.activated;return this.activated=null,this._activatedRoute=null,t}},{key:"attach",value:function(t,e){this.activated=t,this._activatedRoute=e,this.location.insert(t.hostView)}},{key:"deactivate",value:function(){if(this.activated){var t=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(t)}}},{key:"activateWith",value:function(t,e){if(this.isActivated)throw new Error("Cannot activate an already activated outlet");this._activatedRoute=t;var n=(e=e||this.resolver).resolveComponentFactory(t._futureSnapshot.routeConfig.component),i=this.parentContexts.getOrCreateContext(this.name).children,r=new gQ(t,i,this.location.injector);this.activated=this.location.createComponent(n,this.location.length,r),this.changeDetector.markForCheck(),this.activateEvents.emit(this.activated.instance)}},{key:"isActivated",get:function(){return!!this.activated}},{key:"component",get:function(){if(!this.activated)throw new Error("Outlet is not activated");return this.activated.instance}},{key:"activatedRoute",get:function(){if(!this.activated)throw new Error("Outlet is not activated");return this._activatedRoute}},{key:"activatedRouteData",get:function(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(rQ),da(mc),da(Vs),fa("name"),da(Po))},t.\u0275dir=Wt({type:t,selectors:[["router-outlet"]],outputs:{activateEvents:"activate",deactivateEvents:"deactivate"},exportAs:["outlet"]}),t}(),gQ=function(){function t(e,n,i){Object(m.a)(this,t),this.route=e,this.childContexts=n,this.parent=i}return Object(g.a)(t,[{key:"get",value:function(t,e){return t===ZY?this.route:t===rQ?this.childContexts:this.parent.get(t,e)}}]),t}(),vQ=function t(){Object(m.a)(this,t)},bQ=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"preload",value:function(t,e){return e().pipe(Object(AX.a)((function(){return Object(lm.a)(null)})))}}]),t}(),yQ=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"preload",value:function(t,e){return Object(lm.a)(null)}}]),t}(),_Q=function(){var t=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this.router=e,this.injector=r,this.preloadingStrategy=o,this.loader=new nQ(n,i,(function(t){return e.triggerEvent(new JX(t))}),(function(t){return e.triggerEvent(new tY(t))}))}return Object(g.a)(t,[{key:"setUpPreloading",value:function(){var t=this;this.subscription=this.router.events.pipe(Object(vg.a)((function(t){return t instanceof GX})),Object(gg.a)((function(){return t.preload()}))).subscribe((function(){}))}},{key:"preload",value:function(){var t=this.injector.get(Ot);return this.processRoutes(t,this.router.config)}},{key:"ngOnDestroy",value:function(){this.subscription.unsubscribe()}},{key:"processRoutes",value:function(t,e){var n,i=[],r=d(e);try{for(r.s();!(n=r.n()).done;){var o=n.value;if(o.loadChildren&&!o.canLoad&&o._loadedConfig){var a=o._loadedConfig;i.push(this.processRoutes(a.module,a.routes))}else o.loadChildren&&!o.canLoad?i.push(this.preloadConfig(t,o)):o.children&&i.push(this.processRoutes(t,o.children))}}catch(s){r.e(s)}finally{r.f()}return Object(tf.a)(i).pipe(Object(VX.a)(),Object(ef.a)((function(t){})))}},{key:"preloadConfig",value:function(t,e){var n=this;return this.preloadingStrategy.preload(e,(function(){return n.loader.load(t.injector,e).pipe(Object(IX.a)((function(t){return e._loadedConfig=t,n.processRoutes(t.module,t.routes)})))}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(lQ),_t(eu),_t(El),_t(Xo),_t(vQ))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),wQ=function(){var t=function(){function t(e,n){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Object(m.a)(this,t),this.router=e,this.viewportScroller=n,this.options=i,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},i.scrollPositionRestoration=i.scrollPositionRestoration||"disabled",i.anchorScrolling=i.anchorScrolling||"disabled"}return Object(g.a)(t,[{key:"init",value:function(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}},{key:"createScrollEvents",value:function(){var t=this;return this.router.events.subscribe((function(e){e instanceof qX?(t.store[t.lastId]=t.viewportScroller.getScrollPosition(),t.lastSource=e.navigationTrigger,t.restoredId=e.restoredState?e.restoredState.navigationId:0):e instanceof GX&&(t.lastId=e.id,t.scheduleScrollEvent(e,t.router.parseUrl(e.urlAfterRedirects).fragment))}))}},{key:"consumeScrollEvents",value:function(){var t=this;return this.router.events.subscribe((function(e){e instanceof oY&&(e.position?"top"===t.options.scrollPositionRestoration?t.viewportScroller.scrollToPosition([0,0]):"enabled"===t.options.scrollPositionRestoration&&t.viewportScroller.scrollToPosition(e.position):e.anchor&&"enabled"===t.options.anchorScrolling?t.viewportScroller.scrollToAnchor(e.anchor):"disabled"!==t.options.scrollPositionRestoration&&t.viewportScroller.scrollToPosition([0,0]))}))}},{key:"scheduleScrollEvent",value:function(t,e){this.router.triggerEvent(new oY(t,"popstate"===this.lastSource?this.store[this.restoredId]:null,e))}},{key:"ngOnDestroy",value:function(){this.routerEventsSubscription&&this.routerEventsSubscription.unsubscribe(),this.scrollEventsSubscription&&this.scrollEventsSubscription.unsubscribe()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(lQ),_t(pd),_t(void 0))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}(),kQ=new ht("ROUTER_CONFIGURATION"),CQ=new ht("ROUTER_FORROOT_GUARD"),SQ=[Mu,{provide:TY,useClass:EY},{provide:lQ,useFactory:function(t,e,n,i,r,o,a){var s=arguments.length>7&&void 0!==arguments[7]?arguments[7]:{},c=arguments.length>8?arguments[8]:void 0,l=arguments.length>9?arguments[9]:void 0,u=new lQ(null,t,e,n,i,r,o,bY(a));if(c&&(u.urlHandlingStrategy=c),l&&(u.routeReuseStrategy=l),s.errorHandler&&(u.errorHandler=s.errorHandler),s.malformedUriErrorHandler&&(u.malformedUriErrorHandler=s.malformedUriErrorHandler),s.enableTracing){var h=uu();u.events.subscribe((function(t){h.logGroup("Router Event: ".concat(t.constructor.name)),h.log(t.toString()),h.log(t),h.logGroupEnd()}))}return s.onSameUrlNavigation&&(u.onSameUrlNavigation=s.onSameUrlNavigation),s.paramsInheritanceStrategy&&(u.paramsInheritanceStrategy=s.paramsInheritanceStrategy),s.urlUpdateStrategy&&(u.urlUpdateStrategy=s.urlUpdateStrategy),s.relativeLinkResolution&&(u.relativeLinkResolution=s.relativeLinkResolution),u},deps:[TY,rQ,Mu,Xo,eu,El,eQ,kQ,[function t(){Object(m.a)(this,t)},new E],[function t(){Object(m.a)(this,t)},new E]]},rQ,{provide:ZY,useFactory:function(t){return t.routerState.root},deps:[lQ]},{provide:eu,useClass:ru},_Q,yQ,bQ,{provide:kQ,useValue:{enableTracing:!1}}];function xQ(){return new Wl("Router",lQ)}var OQ=function(){var t=function(){function t(e,n){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"forRoot",value:function(e,n){return{ngModule:t,providers:[SQ,PQ(e),{provide:CQ,useFactory:EQ,deps:[[lQ,new E,new A]]},{provide:kQ,useValue:n||{}},{provide:ku,useFactory:TQ,deps:[fu,[new T(Su),new E],kQ]},{provide:wQ,useFactory:MQ,deps:[lQ,pd,kQ]},{provide:vQ,useExisting:n&&n.preloadingStrategy?n.preloadingStrategy:yQ},{provide:Wl,multi:!0,useFactory:xQ},[AQ,{provide:hl,multi:!0,useFactory:jQ,deps:[AQ]},{provide:DQ,useFactory:IQ,deps:[AQ]},{provide:bl,multi:!0,useExisting:DQ}]]}}},{key:"forChild",value:function(e){return{ngModule:t,providers:[PQ(e)]}}}]),t}();return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)(_t(CQ,8),_t(lQ,8))}}),t}();function MQ(t,e,n){return n.scrollOffset&&e.setOffset(n.scrollOffset),new wQ(t,e,n)}function TQ(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return n.useHash?new Ou(t,e):new xu(t,e)}function EQ(t){if(t)throw new Error("RouterModule.forRoot() called twice. Lazy loaded modules should use RouterModule.forChild() instead.");return"guarded"}function PQ(t){return[{provide:Yo,multi:!0,useValue:t},{provide:eQ,multi:!0,useValue:t}]}var AQ=function(){var t=function(){function t(e){Object(m.a)(this,t),this.injector=e,this.initNavigation=!1,this.resultOfPreactivationDone=new w.b}return Object(g.a)(t,[{key:"appInitializer",value:function(){var t=this;return this.injector.get(mu,Promise.resolve(null)).then((function(){var e=null,n=new Promise((function(t){return e=t})),i=t.injector.get(lQ),r=t.injector.get(kQ);if(t.isLegacyDisabled(r)||t.isLegacyEnabled(r))e(!0);else if("disabled"===r.initialNavigation)i.setUpLocationChangeListener(),e(!0);else{if("enabled"!==r.initialNavigation)throw new Error("Invalid initialNavigation options: '".concat(r.initialNavigation,"'"));i.hooks.afterPreactivation=function(){return t.initNavigation?Object(lm.a)(null):(t.initNavigation=!0,e(!0),t.resultOfPreactivationDone)},i.initialNavigation()}return n}))}},{key:"bootstrapListener",value:function(t){var e=this.injector.get(kQ),n=this.injector.get(_Q),i=this.injector.get(wQ),r=this.injector.get(lQ),o=this.injector.get(Jl);t===o.components[0]&&(this.isLegacyEnabled(e)?r.initialNavigation():this.isLegacyDisabled(e)&&r.setUpLocationChangeListener(),n.setUpPreloading(),i.init(),r.resetRootComponentType(o.componentTypes[0]),this.resultOfPreactivationDone.next(null),this.resultOfPreactivationDone.complete())}},{key:"isLegacyEnabled",value:function(t){return"legacy_enabled"===t.initialNavigation||!0===t.initialNavigation||void 0===t.initialNavigation}},{key:"isLegacyDisabled",value:function(t){return"legacy_disabled"===t.initialNavigation||!1===t.initialNavigation}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Xo))},t.\u0275prov=R({token:t,factory:t.\u0275fac}),t}();function jQ(t){return t.appInitializer.bind(t)}function IQ(t){return t.bootstrapListener.bind(t)}var DQ=new ht("Router Initializer"),RQ=function(){function t(t,e){this.utils=new LQ,this.dbWrapper=new FQ(t,e)}return t.prototype.openDatabase=function(t,e){var n=this,i=this;return new Promise((function(r,o){n.dbWrapper.dbVersion=t;var a=n.utils.indexedDB.open(n.dbWrapper.dbName,t);a.onsuccess=function(t){i.dbWrapper.db=a.result,r()},a.onerror=function(t){o(t.target.errorCode+" ("+t.target.error+")")},"function"==typeof e&&(a.onupgradeneeded=function(t){e(t,i.dbWrapper.db)})}))},t.prototype.getByKey=function(t,e){var n=this;return new Promise((function(i,r){n.dbWrapper.validateBeforeTransaction(t,r),n.dbWrapper.createTransaction({storeName:t,dbMode:"readonly",error:function(t){r(t)},complete:function(t){}}).objectStore(t).get(e).onsuccess=function(t){i(t.target.result)}}))},t.prototype.getAll=function(t,e,n){var i=this;return new Promise((function(r,o){i.dbWrapper.validateBeforeTransaction(t,o);var a,s=i.dbWrapper.createTransaction({storeName:t,dbMode:"readonly",error:function(t){o(t)},complete:function(t){}}).objectStore(t),c=[];(a=n?s.index(n.indexName).openCursor(e,"desc"===n.order?"prev":"next"):s.openCursor(e)).onerror=function(t){o(t)},a.onsuccess=function(t){var e=t.target.result;e?(c.push(e.value),e.continue()):r(c)}}))},t.prototype.add=function(t,e,n){var i=this;return new Promise((function(r,o){i.dbWrapper.validateBeforeTransaction(t,o),i.dbWrapper.createTransaction({storeName:t,dbMode:"readwrite",error:function(t){o(t)},complete:function(t){r({key:n,value:e})}}).objectStore(t).add(e,n).onsuccess=function(t){n=t.target.result}}))},t.prototype.update=function(t,e,n){var i=this;return new Promise((function(r,o){i.dbWrapper.validateBeforeTransaction(t,o),i.dbWrapper.createTransaction({storeName:t,dbMode:"readwrite",error:function(t){o(t)},complete:function(t){r(e)},abort:function(t){o(t)}}).objectStore(t).put(e,n)}))},t.prototype.delete=function(t,e){var n=this;return new Promise((function(i,r){n.dbWrapper.validateBeforeTransaction(t,r),n.dbWrapper.createTransaction({storeName:t,dbMode:"readwrite",error:function(t){r(t)},complete:function(t){i()},abort:function(t){r(t)}}).objectStore(t).delete(e)}))},t.prototype.openCursor=function(t,e,n){var i=this;return new Promise((function(r,o){i.dbWrapper.validateBeforeTransaction(t,o),i.dbWrapper.createTransaction({storeName:t,dbMode:"readonly",error:function(t){o(t)},complete:function(t){r()},abort:function(t){o(t)}}).objectStore(t).openCursor(n).onsuccess=function(t){e(t),r()}}))},t.prototype.clear=function(t){var e=this;return new Promise((function(n,i){e.dbWrapper.validateBeforeTransaction(t,i),e.dbWrapper.createTransaction({storeName:t,dbMode:"readwrite",error:function(t){i(t)},complete:function(t){n()},abort:function(t){i(t)}}).objectStore(t).clear(),n()}))},t.prototype.getByIndex=function(t,e,n){var i=this;return new Promise((function(r,o){i.dbWrapper.validateBeforeTransaction(t,o),i.dbWrapper.createTransaction({storeName:t,dbMode:"readonly",error:function(t){o(t)},abort:function(t){o(t)},complete:function(t){}}).objectStore(t).index(e).get(n).onsuccess=function(t){r(t.target.result)}}))},t}(),LQ=function(){return function(){this.indexedDB=window.indexedDB||window.mozIndexedDB||window.webkitIndexedDB||window.msIndexedDB}}(),FQ=function(){function t(t,e){this.dbName=t,this.dbVersion=e||1,this.db=null}return t.prototype.validateStoreName=function(t){return this.db.objectStoreNames.contains(t)},t.prototype.validateBeforeTransaction=function(t,e){this.db||e("You need to use the openDatabase function to create a database before you query it!"),this.validateStoreName(t)||e("objectStore does not exists: "+t)},t.prototype.createTransaction=function(t){var e=this.db.transaction(t.storeName,t.dbMode);return e.onerror=t.error,e.oncomplete=t.complete,e.onabort=t.abort,e},t}(),NQ=function(){function t(){this.db=new RQ(t.DATABASE,t.VERSION)}return t.prototype.get=function(){return this.db},t.VERSION=1,t.DATABASE="gns3-web-ui",t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),BQ=function(){return function(){}}(),HQ=function(t,e){return(HQ=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)};function zQ(t,e){function n(){this.constructor=t}HQ(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var VQ=function(){return(VQ=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)};function UQ(t,e,n,i){return new(n||(n=Promise))((function(r,o){function a(t){try{c(i.next(t))}catch(e){o(e)}}function s(t){try{c(i.throw(t))}catch(e){o(e)}}function c(t){var e;t.done?r(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,s)}c((i=i.apply(t,e||[])).next())}))}function qQ(t,e){var n,i,r,o,a={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,i&&(r=2&o[0]?i.return:o[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,i=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((r=(r=a.trys).length>0&&r[r.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]<r[3])){a.label=o[1];break}if(6===o[0]&&a.label<r[1]){a.label=r[1],r=o;break}if(r&&a.label<r[2]){a.label=r[2],a.ops.push(o);break}r[2]&&a.ops.pop(),a.trys.pop();continue}o=e.call(t,a)}catch(s){o=[6,s],i=0}finally{n=r=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}function GQ(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,r++)i[r]=o[a];return i}var WQ=n("z6cu"),KQ=function(t){function e(e){return t.call(this,e)||this}return zQ(e,t),e.fromError=function(t,n){var i=new e(t);return i.originalError=n,i},e}(Error),XQ=function(){function t(){}return t.prototype.handleError=function(t){var e=t;return"HttpErrorResponse"===t.name&&0===t.status&&(e=KQ.fromError("Server is unreachable",t)),Object(WQ.a)(e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),YQ=function(){function t(t,e){this.http=t,this.errorHandler=e,this.requestsNotificationEmitter=new Uc}return t.prototype.get=function(t,e,n){n=this.getJsonOptions(n);var i=this.getOptionsForServer(t,e,n);return this.requestsNotificationEmitter.emit("GET "+i.url),this.http.get(i.url,i.options).pipe(Object(AX.a)(this.errorHandler.handleError))},t.prototype.getText=function(t,e,n){n=this.getTextOptions(n);var i=this.getOptionsForServer(t,e,n);return this.requestsNotificationEmitter.emit("GET "+i.url),this.http.get(i.url,i.options).pipe(Object(AX.a)(this.errorHandler.handleError))},t.prototype.post=function(t,e,n,i){i=this.getJsonOptions(i);var r=this.getOptionsForServer(t,e,i);return this.requestsNotificationEmitter.emit("POST "+r.url),this.http.post(r.url,n,r.options).pipe(Object(AX.a)(this.errorHandler.handleError))},t.prototype.put=function(t,e,n,i){i=this.getJsonOptions(i);var r=this.getOptionsForServer(t,e,i);return this.requestsNotificationEmitter.emit("PUT "+r.url),this.http.put(r.url,n,r.options).pipe(Object(AX.a)(this.errorHandler.handleError))},t.prototype.delete=function(t,e,n){n=this.getJsonOptions(n);var i=this.getOptionsForServer(t,e,n);return this.requestsNotificationEmitter.emit("DELETE "+i.url),this.http.delete(i.url,i.options).pipe(Object(AX.a)(this.errorHandler.handleError))},t.prototype.patch=function(t,e,n,i){i=this.getJsonOptions(i);var r=this.getOptionsForServer(t,e,i);return this.http.patch(r.url,n,r.options).pipe(Object(AX.a)(this.errorHandler.handleError))},t.prototype.head=function(t,e,n){n=this.getJsonOptions(n);var i=this.getOptionsForServer(t,e,n);return this.http.head(i.url,i.options).pipe(Object(AX.a)(this.errorHandler.handleError))},t.prototype.options=function(t,e,n){n=this.getJsonOptions(n);var i=this.getOptionsForServer(t,e,n);return this.http.options(i.url,i.options).pipe(Object(AX.a)(this.errorHandler.handleError))},t.prototype.getJsonOptions=function(t){return t||{responseType:"json"}},t.prototype.getTextOptions=function(t){return t||{responseType:"text"}},t.prototype.getOptionsForServer=function(t,e,n){if(e=t.host&&t.port?"http://"+t.host+":"+t.port+"/v2"+e:"/v2"+e,n.headers||(n.headers={}),"basic"===t.authorization){var i=btoa(t.login+":"+t.password);n.headers.Authorization="Basic "+i}return{url:e,options:n}},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Rg),_t(XQ))}}),t}(),ZQ=function(){function t(t,e){var n=this;this.indexedDbService=t,this.httpServer=e,this.tablename="servers",this.isIncognitoMode=!1,this.serverIdsInIncognitoMode=[],this.serviceInitialized=new w.b,this.ready=this.indexedDbService.get().openDatabase(1,(function(t){t.currentTarget.result.createObjectStore(n.tablename,{keyPath:"id",autoIncrement:!0})})).then((function(){n.indexedDbService.get().getAll(n.tablename).then((function(){})).catch((function(){n.isIncognitoMode=!0}))})).catch((function(){n.isIncognitoMode=!0})).finally((function(){n.isServiceInitialized=!0,n.serviceInitialized.next(!0)}))}return t.prototype.tryToCreateDb=function(){var t=this;return new Promise((function(e){t.indexedDbService.get().openDatabase(1,(function(e){e.currentTarget.result.createObjectStore(t.tablename,{keyPath:"id",autoIncrement:!0})})).then((function(){})).catch((function(){t.isIncognitoMode=!0}))}))},t.prototype.get=function(t){var e=this;if(this.isIncognitoMode){var n=JSON.parse(localStorage.getItem("server-"+t));return new Promise((function(t){t(n)}))}return this.onReady((function(){return e.indexedDbService.get().getByKey(e.tablename,t)}))},t.prototype.create=function(t){var e=this;return this.isIncognitoMode?(t.id=this.serverIdsInIncognitoMode.length+1,localStorage.setItem("server-"+t.id,JSON.stringify(t)),this.serverIdsInIncognitoMode.push("server-"+t.id),new Promise((function(e){e(t)}))):this.onReady((function(){return new Promise((function(n,i){e.indexedDbService.get().add(e.tablename,t).then((function(e){t.id=e.key,n(t)}),i)}))}))},t.prototype.update=function(t){var e=this;return this.isIncognitoMode?(localStorage.removeItem("server-"+t.id),localStorage.setItem("server-"+t.id,JSON.stringify(t)),new Promise((function(e){e(t)}))):this.onReady((function(){return new Promise((function(n,i){e.indexedDbService.get().update(e.tablename,t).then((function(e){n(t)}),i)}))}))},t.prototype.findAll=function(){var t=this;return this.isIncognitoMode?new Promise((function(e){var n=[];t.serverIdsInIncognitoMode.forEach((function(t){var e=JSON.parse(localStorage.getItem(t));n.push(e)})),e(n)})):this.onReady((function(){return t.indexedDbService.get().getAll(t.tablename)}))},t.prototype.delete=function(t){var e=this;return this.isIncognitoMode?(localStorage.removeItem("server-"+t.id),this.serverIdsInIncognitoMode=this.serverIdsInIncognitoMode.filter((function(e){return e!=="server-"+t.id})),new Promise((function(e){e(t.id)}))):this.onReady((function(){return e.indexedDbService.get().delete(e.tablename,t.id)}))},t.prototype.getServerUrl=function(t){return"http://"+t.host+":"+t.port+"/"},t.prototype.checkServerVersion=function(t){return this.httpServer.get(t,"/version")},t.prototype.getLocalServer=function(t,e){var n=this;return new Promise((function(i,r){n.findAll().then((function(o){var a=o.find((function(t){return"bundled"===t.location}));if(a)a.host=t,a.port=e,n.update(a).then((function(t){i(t)}),r);else{var s=new BQ;s.name="local",s.host=t,s.port=e,s.location="bundled",n.create(s).then((function(t){i(t)}),r)}}),r)}))},t.prototype.onReady=function(t){var e=this;return new Promise((function(n,i){e.ready.then((function(){t().then((function(t){n(t)}),(function(t){i(t)}))}),(function(t){i(t)}))}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(NQ),_t(YQ))}}),t}(),QQ=function(){function t(t){this.persistenceService=t,this.settingsSubject=new Pm.a(this.getAll())}return t.prototype.get=function(e){if(!(e in t.DEFAULTS))throw Error("Key '"+e+"' doesn't exist in settings");var n=this.persistenceService.get(e,nX.LOCAL);return void 0===n?t.DEFAULTS[e]:n},t.prototype.set=function(e,n){if(!(e in t.DEFAULTS))throw Error("Key '"+e+"' doesn't exist in settings");this.persistenceService.set(e,n,{type:nX.LOCAL}),this.settingsSubject.next(this.getAll())},t.prototype.getAll=function(){var e=this,n=VQ({},t.DEFAULTS);return Object.keys(t.DEFAULTS).forEach((function(t){n[t]=e.get(t)})),n},t.prototype.setAll=function(t){var e=this;Object.keys(t).forEach((function(n){e.set(n,t[n])}))},t.prototype.isExperimentalEnabled=function(){return this.get("experimental_features")},t.prototype.subscribe=function(t){return this.settingsSubject.subscribe(t)},t.DEFAULTS={crash_reports:!0,experimental_features:!1,angular_map:!1,console_command:void 0},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(fX))}}),t}(),$Q=function(){function t(t,e){this.httpServer=t,this.settingsService=e,this.projectListSubject=new w.b}return t.prototype.projectListUpdated=function(){this.projectListSubject.next(!0)},t.prototype.get=function(t,e){return this.httpServer.get(t,"/projects/"+e)},t.prototype.open=function(t,e){return this.httpServer.post(t,"/projects/"+e+"/open",{})},t.prototype.close=function(t,e){return this.httpServer.post(t,"/projects/"+e+"/close",{})},t.prototype.list=function(t){return this.httpServer.get(t,"/projects")},t.prototype.nodes=function(t,e){return this.httpServer.get(t,"/projects/"+e+"/nodes")},t.prototype.links=function(t,e){return this.httpServer.get(t,"/projects/"+e+"/links")},t.prototype.drawings=function(t,e){return this.httpServer.get(t,"/projects/"+e+"/drawings")},t.prototype.add=function(t,e,n){return this.httpServer.post(t,"/projects",{name:e,project_id:n})},t.prototype.update=function(t,e){return this.httpServer.put(t,"/projects/"+e.project_id,{auto_close:e.auto_close,auto_open:e.auto_open,auto_start:e.auto_start,drawing_grid_size:e.drawing_grid_size,grid_size:e.grid_size,name:e.name,scene_width:e.scene_width,scene_height:e.scene_height,show_interface_labels:e.show_interface_labels})},t.prototype.delete=function(t,e){return this.httpServer.delete(t,"/projects/"+e)},t.prototype.getUploadPath=function(t,e,n){return"http://"+t.host+":"+t.port+"/v2/projects/"+e+"/import?name="+n},t.prototype.getExportPath=function(t,e){return"http://"+t.host+":"+t.port+"/v2/projects/"+e.project_id+"/export"},t.prototype.export=function(t,e){return this.httpServer.get(t,"/projects/"+e+"/export")},t.prototype.getStatistics=function(t,e){return this.httpServer.get(t,"/projects/"+e+"/stats")},t.prototype.duplicate=function(t,e,n){return this.httpServer.post(t,"/projects/"+e+"/duplicate",{name:n})},t.prototype.notificationsPath=function(t,e){return"ws://"+t.host+":"+t.port+"/v2/projects/"+e+"/notifications/ws"},t.prototype.isReadOnly=function(t){return!!t.readonly&&t.readonly},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ),_t(QQ))}}),t}();function JQ(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];return n.length?n.some((function(e){return t[e]})):t.altKey||t.shiftKey||t.ctrlKey||t.metaKey}var t$=n("Kj3r"),e$=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"create",value:function(t){return"undefined"==typeof MutationObserver?null:new MutationObserver(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:function(){return new t},token:t,providedIn:"root"}),t}(),n$=function(){var t=function(){function t(e){Object(m.a)(this,t),this._mutationObserverFactory=e,this._observedElements=new Map}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){var t=this;this._observedElements.forEach((function(e,n){return t._cleanupObserver(n)}))}},{key:"observe",value:function(t){var e=this,n=sm(t);return new k.a((function(t){var i=e._observeElement(n).subscribe(t);return function(){i.unsubscribe(),e._unobserveElement(n)}}))}},{key:"_observeElement",value:function(t){if(this._observedElements.has(t))this._observedElements.get(t).count++;else{var e=new w.b,n=this._mutationObserverFactory.create((function(t){return e.next(t)}));n&&n.observe(t,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(t,{observer:n,stream:e,count:1})}return this._observedElements.get(t).stream}},{key:"_unobserveElement",value:function(t){this._observedElements.has(t)&&(this._observedElements.get(t).count--,this._observedElements.get(t).count||this._cleanupObserver(t))}},{key:"_cleanupObserver",value:function(t){if(this._observedElements.has(t)){var e=this._observedElements.get(t),n=e.observer,i=e.stream;n&&n.disconnect(),i.complete(),this._observedElements.delete(t)}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(e$))},t.\u0275prov=R({factory:function(){return new t(_t(e$))},token:t,providedIn:"root"}),t}(),i$=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._contentObserver=e,this._elementRef=n,this._ngZone=i,this.event=new Uc,this._disabled=!1,this._currentSubscription=null}return Object(g.a)(t,[{key:"ngAfterContentInit",value:function(){this._currentSubscription||this.disabled||this._subscribe()}},{key:"ngOnDestroy",value:function(){this._unsubscribe()}},{key:"_subscribe",value:function(){var t=this;this._unsubscribe();var e=this._contentObserver.observe(this._elementRef);this._ngZone.runOutsideAngular((function(){t._currentSubscription=(t.debounce?e.pipe(Object(t$.a)(t.debounce)):e).subscribe(t.event)}))}},{key:"_unsubscribe",value:function(){this._currentSubscription&&this._currentSubscription.unsubscribe()}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t),this._disabled?this._unsubscribe():this._subscribe()}},{key:"debounce",get:function(){return this._debounce},set:function(t){this._debounce=im(t),this._subscribe()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(n$),da(Us),da(jl))},t.\u0275dir=Wt({type:t,selectors:[["","cdkObserveContent",""]],inputs:{disabled:["cdkObserveContentDisabled","disabled"],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"]}),t}(),r$=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[e$]}),t}();function o$(t,e){return(t.getAttribute(e)||"").match(/\S+/g)||[]}var a$=0,s$=new Map,c$=null,l$=function(){var t=function(){function t(e){Object(m.a)(this,t),this._document=e}return Object(g.a)(t,[{key:"describe",value:function(t,e){this._canBeDescribed(t,e)&&("string"!=typeof e?(this._setMessageId(e),s$.set(e,{messageElement:e,referenceCount:0})):s$.has(e)||this._createMessageElement(e),this._isElementDescribedByMessage(t,e)||this._addMessageReference(t,e))}},{key:"removeDescription",value:function(t,e){if(this._isElementNode(t)){if(this._isElementDescribedByMessage(t,e)&&this._removeMessageReference(t,e),"string"==typeof e){var n=s$.get(e);n&&0===n.referenceCount&&this._deleteMessageElement(e)}c$&&0===c$.childNodes.length&&this._deleteMessagesContainer()}}},{key:"ngOnDestroy",value:function(){for(var t=this._document.querySelectorAll("[".concat("cdk-describedby-host","]")),e=0;e<t.length;e++)this._removeCdkDescribedByReferenceIds(t[e]),t[e].removeAttribute("cdk-describedby-host");c$&&this._deleteMessagesContainer(),s$.clear()}},{key:"_createMessageElement",value:function(t){var e=this._document.createElement("div");this._setMessageId(e),e.textContent=t,this._createMessagesContainer(),c$.appendChild(e),s$.set(t,{messageElement:e,referenceCount:0})}},{key:"_setMessageId",value:function(t){t.id||(t.id="".concat("cdk-describedby-message","-").concat(a$++))}},{key:"_deleteMessageElement",value:function(t){var e=s$.get(t),n=e&&e.messageElement;c$&&n&&c$.removeChild(n),s$.delete(t)}},{key:"_createMessagesContainer",value:function(){if(!c$){var t=this._document.getElementById("cdk-describedby-message-container");t&&t.parentNode.removeChild(t),(c$=this._document.createElement("div")).id="cdk-describedby-message-container",c$.setAttribute("aria-hidden","true"),c$.style.display="none",this._document.body.appendChild(c$)}}},{key:"_deleteMessagesContainer",value:function(){c$&&c$.parentNode&&(c$.parentNode.removeChild(c$),c$=null)}},{key:"_removeCdkDescribedByReferenceIds",value:function(t){var e=o$(t,"aria-describedby").filter((function(t){return 0!=t.indexOf("cdk-describedby-message")}));t.setAttribute("aria-describedby",e.join(" "))}},{key:"_addMessageReference",value:function(t,e){var n,i,r,o=s$.get(e);i=o.messageElement.id,(r=o$(n=t,"aria-describedby")).some((function(t){return t.trim()==i.trim()}))||(r.push(i.trim()),n.setAttribute("aria-describedby",r.join(" "))),t.setAttribute("cdk-describedby-host",""),o.referenceCount++}},{key:"_removeMessageReference",value:function(t,e){var n,i,r,o,a=s$.get(e);a.referenceCount--,r=a.messageElement.id,(o=o$(n=t,i="aria-describedby").filter((function(t){return t!=r.trim()}))).length?n.setAttribute(i,o.join(" ")):n.removeAttribute(i),t.removeAttribute("cdk-describedby-host")}},{key:"_isElementDescribedByMessage",value:function(t,e){var n=o$(t,"aria-describedby"),i=s$.get(e),r=i&&i.messageElement.id;return!!r&&-1!=n.indexOf(r)}},{key:"_canBeDescribed",value:function(t,e){if(!this._isElementNode(t))return!1;if(e&&"object"==typeof e)return!0;var n=null==e?"":"".concat(e).trim(),i=t.getAttribute("aria-label");return!(!n||i&&i.trim()===n)}},{key:"_isElementNode",value:function(t){return t.nodeType===this._document.ELEMENT_NODE}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(du))},t.\u0275prov=R({factory:function(){return new t(_t(du))},token:t,providedIn:"root"}),t}(),u$=function(){function t(e){var n=this;Object(m.a)(this,t),this._items=e,this._activeItemIndex=-1,this._activeItem=null,this._wrap=!1,this._letterKeyStream=new w.b,this._typeaheadSubscription=_.a.EMPTY,this._vertical=!0,this._allowedModifierKeys=[],this._skipPredicateFn=function(t){return t.disabled},this._pressedLetters=[],this.tabOut=new w.b,this.change=new w.b,e instanceof Gc&&e.changes.subscribe((function(t){if(n._activeItem){var e=t.toArray().indexOf(n._activeItem);e>-1&&e!==n._activeItemIndex&&(n._activeItemIndex=e)}}))}return Object(g.a)(t,[{key:"skipPredicate",value:function(t){return this._skipPredicateFn=t,this}},{key:"withWrap",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._wrap=t,this}},{key:"withVerticalOrientation",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._vertical=t,this}},{key:"withHorizontalOrientation",value:function(t){return this._horizontal=t,this}},{key:"withAllowedModifierKeys",value:function(t){return this._allowedModifierKeys=t,this}},{key:"withTypeAhead",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:200;if(this._items.length&&this._items.some((function(t){return"function"!=typeof t.getLabel})))throw Error("ListKeyManager items in typeahead mode must implement the `getLabel` method.");return this._typeaheadSubscription.unsubscribe(),this._typeaheadSubscription=this._letterKeyStream.pipe(Object(DX.a)((function(e){return t._pressedLetters.push(e)})),Object(t$.a)(e),Object(vg.a)((function(){return t._pressedLetters.length>0})),Object(ef.a)((function(){return t._pressedLetters.join("")}))).subscribe((function(e){for(var n=t._getItemsArray(),i=1;i<n.length+1;i++){var r=(t._activeItemIndex+i)%n.length,o=n[r];if(!t._skipPredicateFn(o)&&0===o.getLabel().toUpperCase().trim().indexOf(e)){t.setActiveItem(r);break}}t._pressedLetters=[]})),this}},{key:"setActiveItem",value:function(t){var e=this._activeItem;this.updateActiveItem(t),this._activeItem!==e&&this.change.next(this._activeItemIndex)}},{key:"onKeydown",value:function(t){var e=this,n=t.keyCode,i=["altKey","ctrlKey","metaKey","shiftKey"].every((function(n){return!t[n]||e._allowedModifierKeys.indexOf(n)>-1}));switch(n){case 9:return void this.tabOut.next();case 40:if(this._vertical&&i){this.setNextItemActive();break}return;case 38:if(this._vertical&&i){this.setPreviousItemActive();break}return;case 39:if(this._horizontal&&i){"rtl"===this._horizontal?this.setPreviousItemActive():this.setNextItemActive();break}return;case 37:if(this._horizontal&&i){"rtl"===this._horizontal?this.setNextItemActive():this.setPreviousItemActive();break}return;default:return void((i||JQ(t,"shiftKey"))&&(t.key&&1===t.key.length?this._letterKeyStream.next(t.key.toLocaleUpperCase()):(n>=65&&n<=90||n>=48&&n<=57)&&this._letterKeyStream.next(String.fromCharCode(n))))}this._pressedLetters=[],t.preventDefault()}},{key:"isTyping",value:function(){return this._pressedLetters.length>0}},{key:"setFirstItemActive",value:function(){this._setActiveItemByIndex(0,1)}},{key:"setLastItemActive",value:function(){this._setActiveItemByIndex(this._items.length-1,-1)}},{key:"setNextItemActive",value:function(){this._activeItemIndex<0?this.setFirstItemActive():this._setActiveItemByDelta(1)}},{key:"setPreviousItemActive",value:function(){this._activeItemIndex<0&&this._wrap?this.setLastItemActive():this._setActiveItemByDelta(-1)}},{key:"updateActiveItem",value:function(t){var e=this._getItemsArray(),n="number"==typeof t?t:e.indexOf(t),i=e[n];this._activeItem=null==i?null:i,this._activeItemIndex=n}},{key:"_setActiveItemByDelta",value:function(t){this._wrap?this._setActiveInWrapMode(t):this._setActiveInDefaultMode(t)}},{key:"_setActiveInWrapMode",value:function(t){for(var e=this._getItemsArray(),n=1;n<=e.length;n++){var i=(this._activeItemIndex+t*n+e.length)%e.length;if(!this._skipPredicateFn(e[i]))return void this.setActiveItem(i)}}},{key:"_setActiveInDefaultMode",value:function(t){this._setActiveItemByIndex(this._activeItemIndex+t,t)}},{key:"_setActiveItemByIndex",value:function(t,e){var n=this._getItemsArray();if(n[t]){for(;this._skipPredicateFn(n[t]);)if(!n[t+=e])return;this.setActiveItem(t)}}},{key:"_getItemsArray",value:function(){return this._items instanceof Gc?this._items.toArray():this._items}},{key:"activeItemIndex",get:function(){return this._activeItemIndex}},{key:"activeItem",get:function(){return this._activeItem}}]),t}(),h$=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"setActiveItem",value:function(t){this.activeItem&&this.activeItem.setInactiveStyles(),Object(o.a)(Object(a.a)(n.prototype),"setActiveItem",this).call(this,t),this.activeItem&&this.activeItem.setActiveStyles()}}]),n}(u$),d$=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments))._origin="program",t}return Object(g.a)(n,[{key:"setFocusOrigin",value:function(t){return this._origin=t,this}},{key:"setActiveItem",value:function(t){Object(o.a)(Object(a.a)(n.prototype),"setActiveItem",this).call(this,t),this.activeItem&&this.activeItem.focus(this._origin)}}]),n}(u$),f$=function(){var t=function(){function t(e){Object(m.a)(this,t),this._platform=e}return Object(g.a)(t,[{key:"isDisabled",value:function(t){return t.hasAttribute("disabled")}},{key:"isVisible",value:function(t){return function(t){return!!(t.offsetWidth||t.offsetHeight||"function"==typeof t.getClientRects&&t.getClientRects().length)}(t)&&"visible"===getComputedStyle(t).visibility}},{key:"isTabbable",value:function(t){if(!this._platform.isBrowser)return!1;var e,n=function(t){try{return t.frameElement}catch(MCt){return null}}((e=t).ownerDocument&&e.ownerDocument.defaultView||window);if(n){var i=n&&n.nodeName.toLowerCase();if(-1===m$(n))return!1;if((this._platform.BLINK||this._platform.WEBKIT)&&"object"===i)return!1;if((this._platform.BLINK||this._platform.WEBKIT)&&!this.isVisible(n))return!1}var r=t.nodeName.toLowerCase(),o=m$(t);if(t.hasAttribute("contenteditable"))return-1!==o;if("iframe"===r)return!1;if("audio"===r){if(!t.hasAttribute("controls"))return!1;if(this._platform.BLINK)return!0}if("video"===r){if(!t.hasAttribute("controls")&&this._platform.TRIDENT)return!1;if(this._platform.BLINK||this._platform.FIREFOX)return!0}return("object"!==r||!this._platform.BLINK&&!this._platform.WEBKIT)&&!(this._platform.WEBKIT&&this._platform.IOS&&!function(t){var e=t.nodeName.toLowerCase(),n="input"===e&&t.type;return"text"===n||"password"===n||"select"===e||"textarea"===e}(t))&&t.tabIndex>=0}},{key:"isFocusable",value:function(t){return function(t){return!function(t){return function(t){return"input"==t.nodeName.toLowerCase()}(t)&&"hidden"==t.type}(t)&&(function(t){var e=t.nodeName.toLowerCase();return"input"===e||"select"===e||"button"===e||"textarea"===e}(t)||function(t){return function(t){return"a"==t.nodeName.toLowerCase()}(t)&&t.hasAttribute("href")}(t)||t.hasAttribute("contenteditable")||p$(t))}(t)&&!this.isDisabled(t)&&this.isVisible(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Cm))},t.\u0275prov=R({factory:function(){return new t(_t(Cm))},token:t,providedIn:"root"}),t}();function p$(t){if(!t.hasAttribute("tabindex")||void 0===t.tabIndex)return!1;var e=t.getAttribute("tabindex");return"-32768"!=e&&!(!e||isNaN(parseInt(e,10)))}function m$(t){if(!p$(t))return null;var e=parseInt(t.getAttribute("tabindex")||"",10);return isNaN(e)?-1:e}var g$=function(){function t(e,n,i,r){var o=this,a=arguments.length>4&&void 0!==arguments[4]&&arguments[4];Object(m.a)(this,t),this._element=e,this._checker=n,this._ngZone=i,this._document=r,this._hasAttached=!1,this.startAnchorListener=function(){return o.focusLastTabbableElement()},this.endAnchorListener=function(){return o.focusFirstTabbableElement()},this._enabled=!0,a||this.attachAnchors()}return Object(g.a)(t,[{key:"destroy",value:function(){var t=this._startAnchor,e=this._endAnchor;t&&(t.removeEventListener("focus",this.startAnchorListener),t.parentNode&&t.parentNode.removeChild(t)),e&&(e.removeEventListener("focus",this.endAnchorListener),e.parentNode&&e.parentNode.removeChild(e)),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}},{key:"attachAnchors",value:function(){var t=this;return!!this._hasAttached||(this._ngZone.runOutsideAngular((function(){t._startAnchor||(t._startAnchor=t._createAnchor(),t._startAnchor.addEventListener("focus",t.startAnchorListener)),t._endAnchor||(t._endAnchor=t._createAnchor(),t._endAnchor.addEventListener("focus",t.endAnchorListener))})),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}},{key:"focusInitialElementWhenReady",value:function(){var t=this;return new Promise((function(e){t._executeOnStable((function(){return e(t.focusInitialElement())}))}))}},{key:"focusFirstTabbableElementWhenReady",value:function(){var t=this;return new Promise((function(e){t._executeOnStable((function(){return e(t.focusFirstTabbableElement())}))}))}},{key:"focusLastTabbableElementWhenReady",value:function(){var t=this;return new Promise((function(e){t._executeOnStable((function(){return e(t.focusLastTabbableElement())}))}))}},{key:"_getRegionBoundary",value:function(t){for(var e=this._element.querySelectorAll("[cdk-focus-region-".concat(t,"], ")+"[cdkFocusRegion".concat(t,"], ")+"[cdk-focus-".concat(t,"]")),n=0;n<e.length;n++)e[n].hasAttribute("cdk-focus-".concat(t))?console.warn("Found use of deprecated attribute 'cdk-focus-".concat(t,"', ")+"use 'cdkFocusRegion".concat(t,"' instead. The deprecated ")+"attribute will be removed in 8.0.0.",e[n]):e[n].hasAttribute("cdk-focus-region-".concat(t))&&console.warn("Found use of deprecated attribute 'cdk-focus-region-".concat(t,"', ")+"use 'cdkFocusRegion".concat(t,"' instead. The deprecated attribute ")+"will be removed in 8.0.0.",e[n]);return"start"==t?e.length?e[0]:this._getFirstTabbableElement(this._element):e.length?e[e.length-1]:this._getLastTabbableElement(this._element)}},{key:"focusInitialElement",value:function(){var t=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");return t?(t.hasAttribute("cdk-focus-initial")&&console.warn("Found use of deprecated attribute 'cdk-focus-initial', use 'cdkFocusInitial' instead. The deprecated attribute will be removed in 8.0.0",t),ii()&&!this._checker.isFocusable(t)&&console.warn("Element matching '[cdkFocusInitial]' is not focusable.",t),t.focus(),!0):this.focusFirstTabbableElement()}},{key:"focusFirstTabbableElement",value:function(){var t=this._getRegionBoundary("start");return t&&t.focus(),!!t}},{key:"focusLastTabbableElement",value:function(){var t=this._getRegionBoundary("end");return t&&t.focus(),!!t}},{key:"hasAttached",value:function(){return this._hasAttached}},{key:"_getFirstTabbableElement",value:function(t){if(this._checker.isFocusable(t)&&this._checker.isTabbable(t))return t;for(var e=t.children||t.childNodes,n=0;n<e.length;n++){var i=e[n].nodeType===this._document.ELEMENT_NODE?this._getFirstTabbableElement(e[n]):null;if(i)return i}return null}},{key:"_getLastTabbableElement",value:function(t){if(this._checker.isFocusable(t)&&this._checker.isTabbable(t))return t;for(var e=t.children||t.childNodes,n=e.length-1;n>=0;n--){var i=e[n].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(e[n]):null;if(i)return i}return null}},{key:"_createAnchor",value:function(){var t=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,t),t.classList.add("cdk-visually-hidden"),t.classList.add("cdk-focus-trap-anchor"),t.setAttribute("aria-hidden","true"),t}},{key:"_toggleAnchorTabIndex",value:function(t,e){t?e.setAttribute("tabindex","0"):e.removeAttribute("tabindex")}},{key:"toggleAnchors",value:function(t){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(t,this._startAnchor),this._toggleAnchorTabIndex(t,this._endAnchor))}},{key:"_executeOnStable",value:function(t){this._ngZone.isStable?t():this._ngZone.onStable.asObservable().pipe(Object(FX.a)(1)).subscribe(t)}},{key:"enabled",get:function(){return this._enabled},set:function(t){this._enabled=t,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(t,this._startAnchor),this._toggleAnchorTabIndex(t,this._endAnchor))}}]),t}(),v$=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._checker=e,this._ngZone=n,this._document=i}return Object(g.a)(t,[{key:"create",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return new g$(t,this._checker,this._ngZone,this._document,e)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(f$),_t(jl),_t(du))},t.\u0275prov=R({factory:function(){return new t(_t(f$),_t(jl),_t(du))},token:t,providedIn:"root"}),t}();"undefined"!=typeof Element&&Element;var b$=new ht("liveAnnouncerElement",{providedIn:"root",factory:function(){return null}}),y$=new ht("LIVE_ANNOUNCER_DEFAULT_OPTIONS"),_$=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._ngZone=n,this._defaultOptions=r,this._document=i,this._liveElement=e||this._createLiveElement()}return Object(g.a)(t,[{key:"announce",value:function(t){for(var e,n,i=this,r=this._defaultOptions,o=arguments.length,a=new Array(o>1?o-1:0),s=1;s<o;s++)a[s-1]=arguments[s];return 1===a.length&&"number"==typeof a[0]?n=a[0]:(e=a[0],n=a[1]),this.clear(),clearTimeout(this._previousTimeout),e||(e=r&&r.politeness?r.politeness:"polite"),null==n&&r&&(n=r.duration),this._liveElement.setAttribute("aria-live",e),this._ngZone.runOutsideAngular((function(){return new Promise((function(e){clearTimeout(i._previousTimeout),i._previousTimeout=setTimeout((function(){i._liveElement.textContent=t,e(),"number"==typeof n&&(i._previousTimeout=setTimeout((function(){return i.clear()}),n))}),100)}))}))}},{key:"clear",value:function(){this._liveElement&&(this._liveElement.textContent="")}},{key:"ngOnDestroy",value:function(){clearTimeout(this._previousTimeout),this._liveElement&&this._liveElement.parentNode&&(this._liveElement.parentNode.removeChild(this._liveElement),this._liveElement=null)}},{key:"_createLiveElement",value:function(){for(var t=this._document.getElementsByClassName("cdk-live-announcer-element"),e=this._document.createElement("div"),n=0;n<t.length;n++)t[n].parentNode.removeChild(t[n]);return e.classList.add("cdk-live-announcer-element"),e.classList.add("cdk-visually-hidden"),e.setAttribute("aria-atomic","true"),e.setAttribute("aria-live","polite"),this._document.body.appendChild(e),e}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(b$,8),_t(jl),_t(du),_t(y$,8))},t.\u0275prov=R({factory:function(){return new t(_t(b$,8),_t(jl),_t(du),_t(y$,8))},token:t,providedIn:"root"}),t}();function w$(t){return 0===t.buttons}var k$=new ht("cdk-focus-monitor-default-options"),C$=Mm({passive:!0,capture:!0}),S$=function(){var t=function(){function t(e,n,i,r){var o=this;Object(m.a)(this,t),this._ngZone=e,this._platform=n,this._origin=null,this._windowFocused=!1,this._elementInfo=new Map,this._monitoredElementCount=0,this._rootNodeFocusListenerCount=new Map,this._documentKeydownListener=function(){o._lastTouchTarget=null,o._setOriginForCurrentEventQueue("keyboard")},this._documentMousedownListener=function(t){if(!o._lastTouchTarget){var e=w$(t)?"keyboard":"mouse";o._setOriginForCurrentEventQueue(e)}},this._documentTouchstartListener=function(t){null!=o._touchTimeoutId&&clearTimeout(o._touchTimeoutId),o._lastTouchTarget=x$(t),o._touchTimeoutId=setTimeout((function(){return o._lastTouchTarget=null}),650)},this._windowFocusListener=function(){o._windowFocused=!0,o._windowFocusTimeoutId=setTimeout((function(){return o._windowFocused=!1}))},this._rootNodeFocusAndBlurListener=function(t){for(var e=x$(t),n="focus"===t.type?o._onFocus:o._onBlur,i=e;i;i=i.parentElement)n.call(o,t,i)},this._document=i,this._detectionMode=(null==r?void 0:r.detectionMode)||0}return Object(g.a)(t,[{key:"monitor",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!this._platform.isBrowser)return Object(lm.a)(null);var n=sm(t),i=Em(n)||this._getDocument(),r=this._elementInfo.get(n);if(r)return e&&(r.checkChildren=!0),r.subject.asObservable();var o={checkChildren:e,subject:new w.b,rootNode:i};return this._elementInfo.set(n,o),this._registerGlobalListeners(o),o.subject.asObservable()}},{key:"stopMonitoring",value:function(t){var e=sm(t),n=this._elementInfo.get(e);n&&(n.subject.complete(),this._setClasses(e),this._elementInfo.delete(e),this._removeGlobalListeners(n))}},{key:"focusVia",value:function(t,e,n){var i=sm(t);this._setOriginForCurrentEventQueue(e),"function"==typeof i.focus&&i.focus(n)}},{key:"ngOnDestroy",value:function(){var t=this;this._elementInfo.forEach((function(e,n){return t.stopMonitoring(n)}))}},{key:"_getDocument",value:function(){return this._document||document}},{key:"_getWindow",value:function(){return this._getDocument().defaultView||window}},{key:"_toggleClass",value:function(t,e,n){n?t.classList.add(e):t.classList.remove(e)}},{key:"_getFocusOrigin",value:function(t){return this._origin?this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:this._wasCausedByTouch(t)?"touch":"program"}},{key:"_setClasses",value:function(t,e){this._toggleClass(t,"cdk-focused",!!e),this._toggleClass(t,"cdk-touch-focused","touch"===e),this._toggleClass(t,"cdk-keyboard-focused","keyboard"===e),this._toggleClass(t,"cdk-mouse-focused","mouse"===e),this._toggleClass(t,"cdk-program-focused","program"===e)}},{key:"_setOriginForCurrentEventQueue",value:function(t){var e=this;this._ngZone.runOutsideAngular((function(){e._origin=t,0===e._detectionMode&&(e._originTimeoutId=setTimeout((function(){return e._origin=null}),1))}))}},{key:"_wasCausedByTouch",value:function(t){var e=x$(t);return this._lastTouchTarget instanceof Node&&e instanceof Node&&(e===this._lastTouchTarget||e.contains(this._lastTouchTarget))}},{key:"_onFocus",value:function(t,e){var n=this._elementInfo.get(e);if(n&&(n.checkChildren||e===x$(t))){var i=this._getFocusOrigin(t);this._setClasses(e,i),this._emitOrigin(n.subject,i),this._lastFocusOrigin=i}}},{key:"_onBlur",value:function(t,e){var n=this._elementInfo.get(e);!n||n.checkChildren&&t.relatedTarget instanceof Node&&e.contains(t.relatedTarget)||(this._setClasses(e),this._emitOrigin(n.subject,null))}},{key:"_emitOrigin",value:function(t,e){this._ngZone.run((function(){return t.next(e)}))}},{key:"_registerGlobalListeners",value:function(t){var e=this;if(this._platform.isBrowser){var n=t.rootNode,i=this._rootNodeFocusListenerCount.get(n)||0;i||this._ngZone.runOutsideAngular((function(){n.addEventListener("focus",e._rootNodeFocusAndBlurListener,C$),n.addEventListener("blur",e._rootNodeFocusAndBlurListener,C$)})),this._rootNodeFocusListenerCount.set(n,i+1),1==++this._monitoredElementCount&&this._ngZone.runOutsideAngular((function(){var t=e._getDocument(),n=e._getWindow();t.addEventListener("keydown",e._documentKeydownListener,C$),t.addEventListener("mousedown",e._documentMousedownListener,C$),t.addEventListener("touchstart",e._documentTouchstartListener,C$),n.addEventListener("focus",e._windowFocusListener)}))}}},{key:"_removeGlobalListeners",value:function(t){var e=t.rootNode;if(this._rootNodeFocusListenerCount.has(e)){var n=this._rootNodeFocusListenerCount.get(e);n>1?this._rootNodeFocusListenerCount.set(e,n-1):(e.removeEventListener("focus",this._rootNodeFocusAndBlurListener,C$),e.removeEventListener("blur",this._rootNodeFocusAndBlurListener,C$),this._rootNodeFocusListenerCount.delete(e))}if(!--this._monitoredElementCount){var i=this._getDocument(),r=this._getWindow();i.removeEventListener("keydown",this._documentKeydownListener,C$),i.removeEventListener("mousedown",this._documentMousedownListener,C$),i.removeEventListener("touchstart",this._documentTouchstartListener,C$),r.removeEventListener("focus",this._windowFocusListener),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._touchTimeoutId),clearTimeout(this._originTimeoutId)}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(jl),_t(Cm),_t(du,8),_t(k$,8))},t.\u0275prov=R({factory:function(){return new t(_t(jl),_t(Cm),_t(du,8),_t(k$,8))},token:t,providedIn:"root"}),t}();function x$(t){return t.composedPath?t.composedPath()[0]:t.target}var O$=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._elementRef=e,this._focusMonitor=n,this.cdkFocusChange=new Uc}return Object(g.a)(t,[{key:"ngAfterViewInit",value:function(){var t=this;this._monitorSubscription=this._focusMonitor.monitor(this._elementRef,this._elementRef.nativeElement.hasAttribute("cdkMonitorSubtreeFocus")).subscribe((function(e){return t.cdkFocusChange.emit(e)}))}},{key:"ngOnDestroy",value:function(){this._focusMonitor.stopMonitoring(this._elementRef),this._monitorSubscription&&this._monitorSubscription.unsubscribe()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(S$))},t.\u0275dir=Wt({type:t,selectors:[["","cdkMonitorElementFocus",""],["","cdkMonitorSubtreeFocus",""]],outputs:{cdkFocusChange:"cdkFocusChange"}}),t}(),M$=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._platform=e,this._document=n}return Object(g.a)(t,[{key:"getHighContrastMode",value:function(){if(!this._platform.isBrowser)return 0;var t=this._document.createElement("div");t.style.backgroundColor="rgb(1,2,3)",t.style.position="absolute",this._document.body.appendChild(t);var e=this._document.defaultView||window,n=e&&e.getComputedStyle?e.getComputedStyle(t):null,i=(n&&n.backgroundColor||"").replace(/ /g,"");switch(this._document.body.removeChild(t),i){case"rgb(0,0,0)":return 2;case"rgb(255,255,255)":return 1}return 0}},{key:"_applyBodyHighContrastModeCssClasses",value:function(){if(this._platform.isBrowser&&this._document.body){var t=this._document.body.classList;t.remove("cdk-high-contrast-active"),t.remove("cdk-high-contrast-black-on-white"),t.remove("cdk-high-contrast-white-on-black");var e=this.getHighContrastMode();1===e?(t.add("cdk-high-contrast-active"),t.add("cdk-high-contrast-black-on-white")):2===e&&(t.add("cdk-high-contrast-active"),t.add("cdk-high-contrast-white-on-black"))}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Cm),_t(du))},t.\u0275prov=R({factory:function(){return new t(_t(Cm),_t(du))},token:t,providedIn:"root"}),t}(),T$=function(){var t=function t(e){Object(m.a)(this,t),e._applyBodyHighContrastModeCssClasses()};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)(_t(M$))},imports:[[Sm,r$]]}),t}(),E$=n("7Hc7"),P$=n("3E0/");function A$(){throw Error("Host already has a portal attached")}var j$=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"attach",value:function(t){return null==t&&function(){throw Error("Attempting to attach a portal to a null PortalOutlet")}(),t.hasAttached()&&A$(),this._attachedHost=t,t.attach(this)}},{key:"detach",value:function(){var t=this._attachedHost;null==t?function(){throw Error("Attempting to detach a portal that is not attached to a host")}():(this._attachedHost=null,t.detach())}},{key:"setAttachedHost",value:function(t){this._attachedHost=t}},{key:"isAttached",get:function(){return null!=this._attachedHost}}]),t}(),I$=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this)).component=t,a.viewContainerRef=i,a.injector=r,a.componentFactoryResolver=o,a}return n}(j$),D$=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this)).templateRef=t,o.viewContainerRef=i,o.context=r,o}return Object(g.a)(n,[{key:"attach",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.context;return this.context=e,Object(o.a)(Object(a.a)(n.prototype),"attach",this).call(this,t)}},{key:"detach",value:function(){return this.context=void 0,Object(o.a)(Object(a.a)(n.prototype),"detach",this).call(this)}},{key:"origin",get:function(){return this.templateRef.elementRef}}]),n}(j$),R$=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this)).element=t instanceof Us?t.nativeElement:t,i}return n}(j$),L$=function(){function t(){Object(m.a)(this,t),this._isDisposed=!1,this.attachDomPortal=null}return Object(g.a)(t,[{key:"hasAttached",value:function(){return!!this._attachedPortal}},{key:"attach",value:function(t){return t||function(){throw Error("Must provide a portal to attach")}(),this.hasAttached()&&A$(),this._isDisposed&&function(){throw Error("This PortalOutlet has already been disposed")}(),t instanceof I$?(this._attachedPortal=t,this.attachComponentPortal(t)):t instanceof D$?(this._attachedPortal=t,this.attachTemplatePortal(t)):this.attachDomPortal&&t instanceof R$?(this._attachedPortal=t,this.attachDomPortal(t)):void function(){throw Error("Attempting to attach an unknown Portal type. BasePortalOutlet accepts either a ComponentPortal or a TemplatePortal.")}()}},{key:"detach",value:function(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}},{key:"dispose",value:function(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}},{key:"setDisposeFn",value:function(t){this._disposeFn=t}},{key:"_invokeDisposeFn",value:function(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}]),t}(),F$=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,c,l){var u,h;return Object(m.a)(this,n),(h=e.call(this)).outletElement=t,h._componentFactoryResolver=i,h._appRef=r,h._defaultInjector=c,h.attachDomPortal=function(t){if(!h._document)throw Error("Cannot attach DOM portal without _document constructor parameter");var e=t.element;if(!e.parentNode)throw Error("DOM portal content must be attached to a parent node.");var i=h._document.createComment("dom-portal");e.parentNode.insertBefore(i,e),h.outletElement.appendChild(e),Object(o.a)((u=Object(s.a)(h),Object(a.a)(n.prototype)),"setDisposeFn",u).call(u,(function(){i.parentNode&&i.parentNode.replaceChild(e,i)}))},h._document=l,h}return Object(g.a)(n,[{key:"attachComponentPortal",value:function(t){var e,n=this,i=(t.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(t.component);return t.viewContainerRef?(e=t.viewContainerRef.createComponent(i,t.viewContainerRef.length,t.injector||t.viewContainerRef.injector),this.setDisposeFn((function(){return e.destroy()}))):(e=i.create(t.injector||this._defaultInjector),this._appRef.attachView(e.hostView),this.setDisposeFn((function(){n._appRef.detachView(e.hostView),e.destroy()}))),this.outletElement.appendChild(this._getComponentRootNode(e)),e}},{key:"attachTemplatePortal",value:function(t){var e=this,n=t.viewContainerRef,i=n.createEmbeddedView(t.templateRef,t.context);return i.detectChanges(),i.rootNodes.forEach((function(t){return e.outletElement.appendChild(t)})),this.setDisposeFn((function(){var t=n.indexOf(i);-1!==t&&n.remove(t)})),i}},{key:"dispose",value:function(){Object(o.a)(Object(a.a)(n.prototype),"dispose",this).call(this),null!=this.outletElement.parentNode&&this.outletElement.parentNode.removeChild(this.outletElement)}},{key:"_getComponentRootNode",value:function(t){return t.hostView.rootNodes[0]}}]),n}(L$),N$=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){return Object(m.a)(this,n),e.call(this,t,i)}return n}(D$);return t.\u0275fac=function(e){return new(e||t)(da(fc),da(mc))},t.\u0275dir=Wt({type:t,selectors:[["","cdkPortal",""]],exportAs:["cdkPortal"],features:[ws]}),t}(),B$=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var c,l;return Object(m.a)(this,n),(l=e.call(this))._componentFactoryResolver=t,l._viewContainerRef=i,l._isInitialized=!1,l.attached=new Uc,l.attachDomPortal=function(t){if(!l._document)throw Error("Cannot attach DOM portal without _document constructor parameter");var e=t.element;if(!e.parentNode)throw Error("DOM portal content must be attached to a parent node.");var i=l._document.createComment("dom-portal");t.setAttachedHost(Object(s.a)(l)),e.parentNode.insertBefore(i,e),l._getRootNode().appendChild(e),Object(o.a)((c=Object(s.a)(l),Object(a.a)(n.prototype)),"setDisposeFn",c).call(c,(function(){i.parentNode&&i.parentNode.replaceChild(e,i)}))},l._document=r,l}return Object(g.a)(n,[{key:"ngOnInit",value:function(){this._isInitialized=!0}},{key:"ngOnDestroy",value:function(){Object(o.a)(Object(a.a)(n.prototype),"dispose",this).call(this),this._attachedPortal=null,this._attachedRef=null}},{key:"attachComponentPortal",value:function(t){t.setAttachedHost(this);var e=null!=t.viewContainerRef?t.viewContainerRef:this._viewContainerRef,i=(t.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(t.component),r=e.createComponent(i,e.length,t.injector||e.injector);return e!==this._viewContainerRef&&this._getRootNode().appendChild(r.hostView.rootNodes[0]),Object(o.a)(Object(a.a)(n.prototype),"setDisposeFn",this).call(this,(function(){return r.destroy()})),this._attachedPortal=t,this._attachedRef=r,this.attached.emit(r),r}},{key:"attachTemplatePortal",value:function(t){var e=this;t.setAttachedHost(this);var i=this._viewContainerRef.createEmbeddedView(t.templateRef,t.context);return Object(o.a)(Object(a.a)(n.prototype),"setDisposeFn",this).call(this,(function(){return e._viewContainerRef.clear()})),this._attachedPortal=t,this._attachedRef=i,this.attached.emit(i),i}},{key:"_getRootNode",value:function(){var t=this._viewContainerRef.element.nativeElement;return t.nodeType===t.ELEMENT_NODE?t:t.parentNode}},{key:"portal",get:function(){return this._attachedPortal},set:function(t){(!this.hasAttached()||t||this._isInitialized)&&(this.hasAttached()&&Object(o.a)(Object(a.a)(n.prototype),"detach",this).call(this),t&&Object(o.a)(Object(a.a)(n.prototype),"attach",this).call(this,t),this._attachedPortal=t)}},{key:"attachedRef",get:function(){return this._attachedRef}}]),n}(L$);return t.\u0275fac=function(e){return new(e||t)(da(Vs),da(mc),da(du))},t.\u0275dir=Wt({type:t,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:["cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[ws]}),t}(),H$=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(B$);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","cdkPortalHost",""],["","portalHost",""]],inputs:{portal:["cdkPortalHost","portal"]},exportAs:["cdkPortalHost"],features:[Ns([{provide:B$,useExisting:t}]),ws]});var e=zn(t);return t}(),z$=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}(),V$=function(){function t(e,n){Object(m.a)(this,t),this._parentInjector=e,this._customTokens=n}return Object(g.a)(t,[{key:"get",value:function(t,e){var n=this._customTokens.get(t);return void 0!==n?n:this._parentInjector.get(t,e)}}]),t}(),U$=new Zs("10.0.1"),q$=["*",[["mat-option"],["ng-container"]]],G$=["*","mat-option, ng-container"];function W$(t,e){if(1&t&&ba(0,"mat-pseudo-checkbox",3),2&t){var n=Aa();pa("state",n.selected?"checked":"unchecked")("disabled",n.disabled)}}var K$=["*"],X$=function(){var t=function t(){Object(m.a)(this,t)};return t.STANDARD_CURVE="cubic-bezier(0.4,0.0,0.2,1)",t.DECELERATION_CURVE="cubic-bezier(0.0,0.0,0.2,1)",t.ACCELERATION_CURVE="cubic-bezier(0.4,0.0,1,1)",t.SHARP_CURVE="cubic-bezier(0.4,0.0,0.6,1)",t}(),Y$=function(){var t=function t(){Object(m.a)(this,t)};return t.COMPLEX="375ms",t.ENTERING="225ms",t.EXITING="195ms",t}(),Z$=new Zs("10.0.1"),Q$=new ht("mat-sanity-checks",{providedIn:"root",factory:function(){return!0}}),$$=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._hasDoneGlobalChecks=!1,this._document=i,e._applyBodyHighContrastModeCssClasses(),this._sanityChecks=n,this._hasDoneGlobalChecks||(this._checkDoctypeIsDefined(),this._checkThemeIsPresent(),this._checkCdkVersionMatch(),this._hasDoneGlobalChecks=!0)}return Object(g.a)(t,[{key:"_getDocument",value:function(){var t=this._document||document;return"object"==typeof t&&t?t:null}},{key:"_getWindow",value:function(){var t=this._getDocument(),e=(null==t?void 0:t.defaultView)||window;return"object"==typeof e&&e?e:null}},{key:"_checksAreEnabled",value:function(){return ii()&&!this._isTestEnv()}},{key:"_isTestEnv",value:function(){var t=this._getWindow();return t&&(t.__karma__||t.jasmine)}},{key:"_checkDoctypeIsDefined",value:function(){var t=this._checksAreEnabled()&&(!0===this._sanityChecks||this._sanityChecks.doctype),e=this._getDocument();t&&e&&!e.doctype&&console.warn("Current document does not have a doctype. This may cause some Angular Material components not to behave as expected.")}},{key:"_checkThemeIsPresent",value:function(){var t=!this._checksAreEnabled()||!1===this._sanityChecks||!this._sanityChecks.theme,e=this._getDocument();if(!t&&e&&e.body&&"function"==typeof getComputedStyle){var n=e.createElement("div");n.classList.add("mat-theme-loaded-marker"),e.body.appendChild(n);var i=getComputedStyle(n);i&&"none"!==i.display&&console.warn("Could not find Angular Material core theme. Most Material components may not work as expected. For more info refer to the theming guide: https://material.angular.io/guide/theming"),e.body.removeChild(n)}}},{key:"_checkCdkVersionMatch",value:function(){this._checksAreEnabled()&&(!0===this._sanityChecks||this._sanityChecks.version)&&Z$.full!==U$.full&&console.warn("The Angular Material version ("+Z$.full+") does not match the Angular CDK version ("+U$.full+").\nPlease ensure the versions of these two packages exactly match.")}}]),t}();return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)(_t(M$),_t(Q$,8),_t(du,8))},imports:[[bm],bm]}),t}();function J$(t){return function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;Object(m.a)(this,n);for(var i=arguments.length,r=new Array(i),o=0;o<i;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r)))._disabled=!1,t}return Object(g.a)(n,[{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t)}}]),n}(t)}function tJ(t,e){return function(t){Object(f.a)(i,t);var n=Object(p.a)(i);function i(){var t;Object(m.a)(this,i);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return(t=n.call.apply(n,[this].concat(o))).color=e,t}return Object(g.a)(i,[{key:"color",get:function(){return this._color},set:function(t){var n=t||e;n!==this._color&&(this._color&&this._elementRef.nativeElement.classList.remove("mat-".concat(this._color)),n&&this._elementRef.nativeElement.classList.add("mat-".concat(n)),this._color=n)}}]),i}(t)}function eJ(t){return function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;Object(m.a)(this,n);for(var i=arguments.length,r=new Array(i),o=0;o<i;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r)))._disableRipple=!1,t}return Object(g.a)(n,[{key:"disableRipple",get:function(){return this._disableRipple},set:function(t){this._disableRipple=nm(t)}}]),n}(t)}function nJ(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return function(t){Object(f.a)(i,t);var n=Object(p.a)(i);function i(){var t;Object(m.a)(this,i);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return(t=n.call.apply(n,[this].concat(o)))._tabIndex=e,t}return Object(g.a)(i,[{key:"tabIndex",get:function(){return this.disabled?-1:this._tabIndex},set:function(t){this._tabIndex=null!=t?t:e}}]),i}(t)}function iJ(t){return function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;Object(m.a)(this,n);for(var i=arguments.length,r=new Array(i),o=0;o<i;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))).errorState=!1,t.stateChanges=new w.b,t}return Object(g.a)(n,[{key:"updateErrorState",value:function(){var t=this.errorState,e=(this.errorStateMatcher||this._defaultErrorStateMatcher).isErrorState(this.ngControl?this.ngControl.control:null,this._parentFormGroup||this._parentForm);e!==t&&(this.errorState=e,this.stateChanges.next())}}]),n}(t)}function rJ(t){return function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;Object(m.a)(this,n);for(var i=arguments.length,r=new Array(i),o=0;o<i;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r)))._isInitialized=!1,t._pendingSubscribers=[],t.initialized=new k.a((function(e){t._isInitialized?t._notifySubscriber(e):t._pendingSubscribers.push(e)})),t}return Object(g.a)(n,[{key:"_markInitialized",value:function(){if(this._isInitialized)throw Error("This directive has already been marked as initialized and should not be called twice.");this._isInitialized=!0,this._pendingSubscribers.forEach(this._notifySubscriber),this._pendingSubscribers=null}},{key:"_notifySubscriber",value:function(t){t.next(),t.complete()}}]),n}(t)}var oJ=function(){var t=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"isErrorState",value:function(t,e){return!!(t&&t.invalid&&(t.touched||e&&e.submitted))}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:function(){return new t},token:t,providedIn:"root"}),t}(),aJ=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-line",""],["","matLine",""]],hostAttrs:[1,"mat-line"]}),t}();function sJ(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"mat";t.changes.pipe(Object(NX.a)(t)).subscribe((function(t){var i=t.length;cJ(e,"".concat(n,"-2-line"),!1),cJ(e,"".concat(n,"-3-line"),!1),cJ(e,"".concat(n,"-multi-line"),!1),2===i||3===i?cJ(e,"".concat(n,"-").concat(i,"-line"),!0):i>3&&cJ(e,"".concat(n,"-multi-line"),!0)}))}function cJ(t,e,n){var i=t.nativeElement.classList;n?i.add(e):i.remove(e)}var lJ=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[$$],$$]}),t}(),uJ=function(){function t(e,n,i){Object(m.a)(this,t),this._renderer=e,this.element=n,this.config=i,this.state=3}return Object(g.a)(t,[{key:"fadeOut",value:function(){this._renderer.fadeOutRipple(this)}}]),t}(),hJ={enterDuration:450,exitDuration:400},dJ=Mm({passive:!0}),fJ=["mousedown","touchstart"],pJ=["mouseup","mouseleave","touchend","touchcancel"],mJ=function(){function t(e,n,i,r){Object(m.a)(this,t),this._target=e,this._ngZone=n,this._isPointerDown=!1,this._activeRipples=new Set,this._pointerUpEventsRegistered=!1,r.isBrowser&&(this._containerElement=sm(i))}return Object(g.a)(t,[{key:"fadeInRipple",value:function(t,e){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),o=Object.assign(Object.assign({},hJ),i.animation);i.centered&&(t=r.left+r.width/2,e=r.top+r.height/2);var a=i.radius||vJ(t,e,r),s=t-r.left,c=e-r.top,l=o.enterDuration,u=document.createElement("div");u.classList.add("mat-ripple-element"),u.style.left="".concat(s-a,"px"),u.style.top="".concat(c-a,"px"),u.style.height="".concat(2*a,"px"),u.style.width="".concat(2*a,"px"),null!=i.color&&(u.style.backgroundColor=i.color),u.style.transitionDuration="".concat(l,"ms"),this._containerElement.appendChild(u),gJ(u),u.style.transform="scale(1)";var h=new uJ(this,u,i);return h.state=0,this._activeRipples.add(h),i.persistent||(this._mostRecentTransientRipple=h),this._runTimeoutOutsideZone((function(){var t=h===n._mostRecentTransientRipple;h.state=1,i.persistent||t&&n._isPointerDown||h.fadeOut()}),l),h}},{key:"fadeOutRipple",value:function(t){var e=this._activeRipples.delete(t);if(t===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),this._activeRipples.size||(this._containerRect=null),e){var n=t.element,i=Object.assign(Object.assign({},hJ),t.config.animation);n.style.transitionDuration="".concat(i.exitDuration,"ms"),n.style.opacity="0",t.state=2,this._runTimeoutOutsideZone((function(){t.state=3,n.parentNode.removeChild(n)}),i.exitDuration)}}},{key:"fadeOutAll",value:function(){this._activeRipples.forEach((function(t){return t.fadeOut()}))}},{key:"setupTriggerEvents",value:function(t){var e=sm(t);e&&e!==this._triggerElement&&(this._removeTriggerEvents(),this._triggerElement=e,this._registerEvents(fJ))}},{key:"handleEvent",value:function(t){"mousedown"===t.type?this._onMousedown(t):"touchstart"===t.type?this._onTouchStart(t):this._onPointerUp(),this._pointerUpEventsRegistered||(this._registerEvents(pJ),this._pointerUpEventsRegistered=!0)}},{key:"_onMousedown",value:function(t){var e=w$(t),n=this._lastTouchStartEvent&&Date.now()<this._lastTouchStartEvent+800;this._target.rippleDisabled||e||n||(this._isPointerDown=!0,this.fadeInRipple(t.clientX,t.clientY,this._target.rippleConfig))}},{key:"_onTouchStart",value:function(t){if(!this._target.rippleDisabled){this._lastTouchStartEvent=Date.now(),this._isPointerDown=!0;for(var e=t.changedTouches,n=0;n<e.length;n++)this.fadeInRipple(e[n].clientX,e[n].clientY,this._target.rippleConfig)}}},{key:"_onPointerUp",value:function(){this._isPointerDown&&(this._isPointerDown=!1,this._activeRipples.forEach((function(t){!t.config.persistent&&(1===t.state||t.config.terminateOnPointerUp&&0===t.state)&&t.fadeOut()})))}},{key:"_runTimeoutOutsideZone",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;this._ngZone.runOutsideAngular((function(){return setTimeout(t,e)}))}},{key:"_registerEvents",value:function(t){var e=this;this._ngZone.runOutsideAngular((function(){t.forEach((function(t){e._triggerElement.addEventListener(t,e,dJ)}))}))}},{key:"_removeTriggerEvents",value:function(){var t=this;this._triggerElement&&(fJ.forEach((function(e){t._triggerElement.removeEventListener(e,t,dJ)})),this._pointerUpEventsRegistered&&pJ.forEach((function(e){t._triggerElement.removeEventListener(e,t,dJ)})))}}]),t}();function gJ(t){window.getComputedStyle(t).getPropertyValue("opacity")}function vJ(t,e,n){var i=Math.max(Math.abs(t-n.left),Math.abs(t-n.right)),r=Math.max(Math.abs(e-n.top),Math.abs(e-n.bottom));return Math.sqrt(i*i+r*r)}var bJ=new ht("mat-ripple-global-options"),yJ=function(){var t=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this._elementRef=e,this._animationMode=o,this.radius=0,this._disabled=!1,this._isInitialized=!1,this._globalOptions=r||{},this._rippleRenderer=new mJ(this,n,e,i)}return Object(g.a)(t,[{key:"ngOnInit",value:function(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}},{key:"ngOnDestroy",value:function(){this._rippleRenderer._removeTriggerEvents()}},{key:"fadeOutAll",value:function(){this._rippleRenderer.fadeOutAll()}},{key:"_setupTriggerEventsIfEnabled",value:function(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}},{key:"launch",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2?arguments[2]:void 0;return"number"==typeof t?this._rippleRenderer.fadeInRipple(t,e,Object.assign(Object.assign({},this.rippleConfig),n)):this._rippleRenderer.fadeInRipple(0,0,Object.assign(Object.assign({},this.rippleConfig),t))}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=t,this._setupTriggerEventsIfEnabled()}},{key:"trigger",get:function(){return this._trigger||this._elementRef.nativeElement},set:function(t){this._trigger=t,this._setupTriggerEventsIfEnabled()}},{key:"rippleConfig",get:function(){return{centered:this.centered,radius:this.radius,color:this.color,animation:Object.assign(Object.assign(Object.assign({},this._globalOptions.animation),"NoopAnimations"===this._animationMode?{enterDuration:0,exitDuration:0}:{}),this.animation),terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}},{key:"rippleDisabled",get:function(){return this.disabled||!!this._globalOptions.disabled}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(jl),da(Cm),da(bJ,8),da(Cy,8))},t.\u0275dir=Wt({type:t,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(t,e){2&t&&Qa("mat-ripple-unbounded",e.unbounded)},inputs:{radius:["matRippleRadius","radius"],disabled:["matRippleDisabled","disabled"],trigger:["matRippleTrigger","trigger"],color:["matRippleColor","color"],unbounded:["matRippleUnbounded","unbounded"],centered:["matRippleCentered","centered"],animation:["matRippleAnimation","animation"]},exportAs:["matRipple"]}),t}(),_J=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[$$,Sm],$$]}),t}(),wJ=function(){var t=function t(e){Object(m.a)(this,t),this._animationMode=e,this.state="unchecked",this.disabled=!1};return t.\u0275fac=function(e){return new(e||t)(da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:8,hostBindings:function(t,e){2&t&&Qa("mat-pseudo-checkbox-indeterminate","indeterminate"===e.state)("mat-pseudo-checkbox-checked","checked"===e.state)("mat-pseudo-checkbox-disabled",e.disabled)("_mat-animation-noopable","NoopAnimations"===e._animationMode)},inputs:{state:"state",disabled:"disabled"},decls:0,vars:0,template:function(t,e){},styles:['.mat-pseudo-checkbox{width:16px;height:16px;border:2px solid;border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:"";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox.mat-pseudo-checkbox-indeterminate{border-color:transparent}._mat-animation-noopable.mat-pseudo-checkbox{transition:none;animation:none}._mat-animation-noopable.mat-pseudo-checkbox::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{top:5px;left:1px;width:10px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{top:2.4px;left:1px;width:8px;height:3px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}\n'],encapsulation:2,changeDetection:0}),t}(),kJ=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}(),CJ=J$((function t(){Object(m.a)(this,t)})),SJ=0,xJ=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments))._labelId="mat-optgroup-label-".concat(SJ++),t}return n}(CJ);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-optgroup"]],hostAttrs:["role","group",1,"mat-optgroup"],hostVars:4,hostBindings:function(t,e){2&t&&(oa("aria-disabled",e.disabled.toString())("aria-labelledby",e._labelId),Qa("mat-optgroup-disabled",e.disabled))},inputs:{disabled:"disabled",label:"label"},exportAs:["matOptgroup"],features:[ws],ngContentSelectors:G$,decls:4,vars:2,consts:[[1,"mat-optgroup-label",3,"id"]],template:function(t,e){1&t&&(Ia(q$),ga(0,"label",0),ds(1),Da(2),va(),Da(3,1)),2&t&&(pa("id",e._labelId),Qi(1),ps("",e.label," "))},styles:[".mat-optgroup-label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.mat-optgroup-label[disabled]{cursor:default}[dir=rtl] .mat-optgroup-label{text-align:right}.mat-optgroup-label .mat-icon{margin-right:16px;vertical-align:middle}.mat-optgroup-label .mat-icon svg{vertical-align:top}[dir=rtl] .mat-optgroup-label .mat-icon{margin-left:16px;margin-right:0}\n"],encapsulation:2,changeDetection:0});var e=zn(t);return t}(),OJ=0,MJ=function t(e){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];Object(m.a)(this,t),this.source=e,this.isUserInput=n},TJ=new ht("MAT_OPTION_PARENT_COMPONENT"),EJ=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._element=e,this._changeDetectorRef=n,this._parent=i,this.group=r,this._selected=!1,this._active=!1,this._disabled=!1,this._mostRecentViewValue="",this.id="mat-option-".concat(OJ++),this.onSelectionChange=new Uc,this._stateChanges=new w.b}return Object(g.a)(t,[{key:"select",value:function(){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}},{key:"deselect",value:function(){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}},{key:"focus",value:function(t,e){var n=this._getHostElement();"function"==typeof n.focus&&n.focus(e)}},{key:"setActiveStyles",value:function(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}},{key:"setInactiveStyles",value:function(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}},{key:"getLabel",value:function(){return this.viewValue}},{key:"_handleKeydown",value:function(t){13!==t.keyCode&&32!==t.keyCode||JQ(t)||(this._selectViaInteraction(),t.preventDefault())}},{key:"_selectViaInteraction",value:function(){this.disabled||(this._selected=!this.multiple||!this._selected,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}},{key:"_getAriaSelected",value:function(){return this.selected||!this.multiple&&null}},{key:"_getTabIndex",value:function(){return this.disabled?"-1":"0"}},{key:"_getHostElement",value:function(){return this._element.nativeElement}},{key:"ngAfterViewChecked",value:function(){if(this._selected){var t=this.viewValue;t!==this._mostRecentViewValue&&(this._mostRecentViewValue=t,this._stateChanges.next())}}},{key:"ngOnDestroy",value:function(){this._stateChanges.complete()}},{key:"_emitSelectionChangeEvent",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.onSelectionChange.emit(new MJ(this,t))}},{key:"multiple",get:function(){return this._parent&&this._parent.multiple}},{key:"selected",get:function(){return this._selected}},{key:"disabled",get:function(){return this.group&&this.group.disabled||this._disabled},set:function(t){this._disabled=nm(t)}},{key:"disableRipple",get:function(){return this._parent&&this._parent.disableRipple}},{key:"active",get:function(){return this._active}},{key:"viewValue",get:function(){return(this._getHostElement().textContent||"").trim()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(TJ,8),da(xJ,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-option"]],hostAttrs:["role","option",1,"mat-option","mat-focus-indicator"],hostVars:12,hostBindings:function(t,e){1&t&&xa("click",(function(){return e._selectViaInteraction()}))("keydown",(function(t){return e._handleKeydown(t)})),2&t&&(bs("id",e.id),oa("tabindex",e._getTabIndex())("aria-selected",e._getAriaSelected())("aria-disabled",e.disabled.toString()),Qa("mat-selected",e.selected)("mat-option-multiple",e.multiple)("mat-active",e.active)("mat-option-disabled",e.disabled))},inputs:{id:"id",disabled:"disabled",value:"value"},outputs:{onSelectionChange:"onSelectionChange"},exportAs:["matOption"],ngContentSelectors:K$,decls:4,vars:3,consts:[["class","mat-option-pseudo-checkbox",3,"state","disabled",4,"ngIf"],[1,"mat-option-text"],["mat-ripple","",1,"mat-option-ripple",3,"matRippleTrigger","matRippleDisabled"],[1,"mat-option-pseudo-checkbox",3,"state","disabled"]],template:function(t,e){1&t&&(Ia(),ua(0,W$,1,2,"mat-pseudo-checkbox",0),ga(1,"span",1),Da(2),va(),ba(3,"div",2)),2&t&&(pa("ngIf",e.multiple),Qi(3),pa("matRippleTrigger",e._getHostElement())("matRippleDisabled",e.disabled||e.disableRipple))},directives:[Ah,yJ,wJ],styles:[".mat-option{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;position:relative;cursor:pointer;outline:none;display:flex;flex-direction:row;max-width:100%;box-sizing:border-box;align-items:center;-webkit-tap-highlight-color:transparent}.mat-option[disabled]{cursor:default}[dir=rtl] .mat-option{text-align:right}.mat-option .mat-icon{margin-right:16px;vertical-align:middle}.mat-option .mat-icon svg{vertical-align:top}[dir=rtl] .mat-option .mat-icon{margin-left:16px;margin-right:0}.mat-option[aria-disabled=true]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:32px}[dir=rtl] .mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:16px;padding-right:32px}.cdk-high-contrast-active .mat-option{margin:0 1px}.cdk-high-contrast-active .mat-option.mat-active{border:solid 1px currentColor;margin:0}.mat-option-text{display:inline-block;flex-grow:1;overflow:hidden;text-overflow:ellipsis}.mat-option .mat-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.cdk-high-contrast-active .mat-option .mat-option-ripple{opacity:.5}.mat-option-pseudo-checkbox{margin-right:8px}[dir=rtl] .mat-option-pseudo-checkbox{margin-left:8px;margin-right:0}\n"],encapsulation:2,changeDetection:0}),t}();function PJ(t,e,n){if(n.length){for(var i=e.toArray(),r=n.toArray(),o=0,a=0;a<t+1;a++)i[a].group&&i[a].group===r[o]&&o++;return o}return 0}var AJ=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[_J,hd,kJ]]}),t}(),jJ=new ht("mat-label-global-options"),IJ=n("xgIS"),DJ=n("eNwd"),RJ=n("/uUt"),LJ=n("3UWI"),FJ=n("Zy1z"),NJ=n("UXun"),BJ=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._ngZone=e,this._platform=n,this._scrolled=new w.b,this._globalSubscription=null,this._scrolledCount=0,this.scrollContainers=new Map,this._document=i}return Object(g.a)(t,[{key:"register",value:function(t){var e=this;this.scrollContainers.has(t)||this.scrollContainers.set(t,t.elementScrolled().subscribe((function(){return e._scrolled.next(t)})))}},{key:"deregister",value:function(t){var e=this.scrollContainers.get(t);e&&(e.unsubscribe(),this.scrollContainers.delete(t))}},{key:"scrolled",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:20;return this._platform.isBrowser?new k.a((function(n){t._globalSubscription||t._addGlobalListener();var i=e>0?t._scrolled.pipe(Object(LJ.a)(e)).subscribe(n):t._scrolled.subscribe(n);return t._scrolledCount++,function(){i.unsubscribe(),t._scrolledCount--,t._scrolledCount||t._removeGlobalListener()}})):Object(lm.a)()}},{key:"ngOnDestroy",value:function(){var t=this;this._removeGlobalListener(),this.scrollContainers.forEach((function(e,n){return t.deregister(n)})),this._scrolled.complete()}},{key:"ancestorScrolled",value:function(t,e){var n=this.getAncestorScrollContainers(t);return this.scrolled(e).pipe(Object(vg.a)((function(t){return!t||n.indexOf(t)>-1})))}},{key:"getAncestorScrollContainers",value:function(t){var e=this,n=[];return this.scrollContainers.forEach((function(i,r){e._scrollableContainsElement(r,t)&&n.push(r)})),n}},{key:"_getDocument",value:function(){return this._document||document}},{key:"_getWindow",value:function(){return this._getDocument().defaultView||window}},{key:"_scrollableContainsElement",value:function(t,e){var n=e.nativeElement,i=t.getElementRef().nativeElement;do{if(n==i)return!0}while(n=n.parentElement);return!1}},{key:"_addGlobalListener",value:function(){var t=this;this._globalSubscription=this._ngZone.runOutsideAngular((function(){var e=t._getWindow();return Object(IJ.a)(e.document,"scroll").subscribe((function(){return t._scrolled.next()}))}))}},{key:"_removeGlobalListener",value:function(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(jl),_t(Cm),_t(du,8))},t.\u0275prov=R({factory:function(){return new t(_t(jl),_t(Cm),_t(du,8))},token:t,providedIn:"root"}),t}(),HJ=function(){var t=function(){function t(e,n,i,r){var o=this;Object(m.a)(this,t),this.elementRef=e,this.scrollDispatcher=n,this.ngZone=i,this.dir=r,this._destroyed=new w.b,this._elementScrolled=new k.a((function(t){return o.ngZone.runOutsideAngular((function(){return Object(IJ.a)(o.elementRef.nativeElement,"scroll").pipe(Object(Am.a)(o._destroyed)).subscribe(t)}))}))}return Object(g.a)(t,[{key:"ngOnInit",value:function(){this.scrollDispatcher.register(this)}},{key:"ngOnDestroy",value:function(){this.scrollDispatcher.deregister(this),this._destroyed.next(),this._destroyed.complete()}},{key:"elementScrolled",value:function(){return this._elementScrolled}},{key:"getElementRef",value:function(){return this.elementRef}},{key:"scrollTo",value:function(t){var e=this.elementRef.nativeElement,n=this.dir&&"rtl"==this.dir.value;null==t.left&&(t.left=n?t.end:t.start),null==t.right&&(t.right=n?t.start:t.end),null!=t.bottom&&(t.top=e.scrollHeight-e.clientHeight-t.bottom),n&&0!=Tm()?(null!=t.left&&(t.right=e.scrollWidth-e.clientWidth-t.left),2==Tm()?t.left=t.right:1==Tm()&&(t.left=t.right?-t.right:t.right)):null!=t.right&&(t.left=e.scrollWidth-e.clientWidth-t.right),this._applyScrollToOptions(t)}},{key:"_applyScrollToOptions",value:function(t){var e=this.elementRef.nativeElement;"object"==typeof document&&"scrollBehavior"in document.documentElement.style?e.scrollTo(t):(null!=t.top&&(e.scrollTop=t.top),null!=t.left&&(e.scrollLeft=t.left))}},{key:"measureScrollOffset",value:function(t){var e=this.elementRef.nativeElement;if("top"==t)return e.scrollTop;if("bottom"==t)return e.scrollHeight-e.clientHeight-e.scrollTop;var n=this.dir&&"rtl"==this.dir.value;return"start"==t?t=n?"right":"left":"end"==t&&(t=n?"left":"right"),n&&2==Tm()?"left"==t?e.scrollWidth-e.clientWidth-e.scrollLeft:e.scrollLeft:n&&1==Tm()?"left"==t?e.scrollLeft+e.scrollWidth-e.clientWidth:-e.scrollLeft:"left"==t?e.scrollLeft:e.scrollWidth-e.clientWidth-e.scrollLeft}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(BJ),da(jl),da(gm,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]]}),t}(),zJ=function(){var t=function(){function t(e,n,i){var r=this;Object(m.a)(this,t),this._platform=e,this._document=i,n.runOutsideAngular((function(){var t=r._getWindow();r._change=e.isBrowser?Object(C.a)(Object(IJ.a)(t,"resize"),Object(IJ.a)(t,"orientationchange")):Object(lm.a)(),r._invalidateCache=r.change().subscribe((function(){return r._updateViewportSize()}))}))}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this._invalidateCache.unsubscribe()}},{key:"getViewportSize",value:function(){this._viewportSize||this._updateViewportSize();var t={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),t}},{key:"getViewportRect",value:function(){var t=this.getViewportScrollPosition(),e=this.getViewportSize(),n=e.width,i=e.height;return{top:t.top,left:t.left,bottom:t.top+i,right:t.left+n,height:i,width:n}}},{key:"getViewportScrollPosition",value:function(){if(!this._platform.isBrowser)return{top:0,left:0};var t=this._getDocument(),e=this._getWindow(),n=t.documentElement,i=n.getBoundingClientRect();return{top:-i.top||t.body.scrollTop||e.scrollY||n.scrollTop||0,left:-i.left||t.body.scrollLeft||e.scrollX||n.scrollLeft||0}}},{key:"change",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:20;return t>0?this._change.pipe(Object(LJ.a)(t)):this._change}},{key:"_getDocument",value:function(){return this._document||document}},{key:"_getWindow",value:function(){return this._getDocument().defaultView||window}},{key:"_updateViewportSize",value:function(){var t=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:t.innerWidth,height:t.innerHeight}:{width:0,height:0}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Cm),_t(jl),_t(du,8))},t.\u0275prov=R({factory:function(){return new t(_t(Cm),_t(jl),_t(du,8))},token:t,providedIn:"root"}),t}(),VJ=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}(),UJ=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[bm,Sm,VJ],bm,VJ]}),t}(),qJ=function(){function t(e,n){Object(m.a)(this,t),this._viewportRuler=e,this._previousHTMLStyles={top:"",left:""},this._isEnabled=!1,this._document=n}return Object(g.a)(t,[{key:"attach",value:function(){}},{key:"enable",value:function(){if(this._canBeEnabled()){var t=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=t.style.left||"",this._previousHTMLStyles.top=t.style.top||"",t.style.left=am(-this._previousScrollPosition.left),t.style.top=am(-this._previousScrollPosition.top),t.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}},{key:"disable",value:function(){if(this._isEnabled){var t=this._document.documentElement,e=t.style,n=this._document.body.style,i=e.scrollBehavior||"",r=n.scrollBehavior||"";this._isEnabled=!1,e.left=this._previousHTMLStyles.left,e.top=this._previousHTMLStyles.top,t.classList.remove("cdk-global-scrollblock"),e.scrollBehavior=n.scrollBehavior="auto",window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),e.scrollBehavior=i,n.scrollBehavior=r}}},{key:"_canBeEnabled",value:function(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;var t=this._document.body,e=this._viewportRuler.getViewportSize();return t.scrollHeight>e.height||t.scrollWidth>e.width}}]),t}();function GJ(){return Error("Scroll strategy has already been attached.")}var WJ=function(){function t(e,n,i,r){var o=this;Object(m.a)(this,t),this._scrollDispatcher=e,this._ngZone=n,this._viewportRuler=i,this._config=r,this._scrollSubscription=null,this._detach=function(){o.disable(),o._overlayRef.hasAttached()&&o._ngZone.run((function(){return o._overlayRef.detach()}))}}return Object(g.a)(t,[{key:"attach",value:function(t){if(this._overlayRef)throw GJ();this._overlayRef=t}},{key:"enable",value:function(){var t=this;if(!this._scrollSubscription){var e=this._scrollDispatcher.scrolled(0);this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=e.subscribe((function(){var e=t._viewportRuler.getViewportScrollPosition().top;Math.abs(e-t._initialScrollPosition)>t._config.threshold?t._detach():t._overlayRef.updatePosition()}))):this._scrollSubscription=e.subscribe(this._detach)}}},{key:"disable",value:function(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}},{key:"detach",value:function(){this.disable(),this._overlayRef=null}}]),t}(),KJ=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"enable",value:function(){}},{key:"disable",value:function(){}},{key:"attach",value:function(){}}]),t}();function XJ(t,e){return e.some((function(e){return t.bottom<e.top||t.top>e.bottom||t.right<e.left||t.left>e.right}))}function YJ(t,e){return e.some((function(e){return t.top<e.top||t.bottom>e.bottom||t.left<e.left||t.right>e.right}))}var ZJ=function(){function t(e,n,i,r){Object(m.a)(this,t),this._scrollDispatcher=e,this._viewportRuler=n,this._ngZone=i,this._config=r,this._scrollSubscription=null}return Object(g.a)(t,[{key:"attach",value:function(t){if(this._overlayRef)throw GJ();this._overlayRef=t}},{key:"enable",value:function(){var t=this;this._scrollSubscription||(this._scrollSubscription=this._scrollDispatcher.scrolled(this._config?this._config.scrollThrottle:0).subscribe((function(){if(t._overlayRef.updatePosition(),t._config&&t._config.autoClose){var e=t._overlayRef.overlayElement.getBoundingClientRect(),n=t._viewportRuler.getViewportSize(),i=n.width,r=n.height;XJ(e,[{width:i,height:r,bottom:r,right:i,top:0,left:0}])&&(t.disable(),t._ngZone.run((function(){return t._overlayRef.detach()})))}})))}},{key:"disable",value:function(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}},{key:"detach",value:function(){this.disable(),this._overlayRef=null}}]),t}(),QJ=function(){var t=function t(e,n,i,r){var o=this;Object(m.a)(this,t),this._scrollDispatcher=e,this._viewportRuler=n,this._ngZone=i,this.noop=function(){return new KJ},this.close=function(t){return new WJ(o._scrollDispatcher,o._ngZone,o._viewportRuler,t)},this.block=function(){return new qJ(o._viewportRuler,o._document)},this.reposition=function(t){return new ZJ(o._scrollDispatcher,o._viewportRuler,o._ngZone,t)},this._document=r};return t.\u0275fac=function(e){return new(e||t)(_t(BJ),_t(zJ),_t(jl),_t(du))},t.\u0275prov=R({factory:function(){return new t(_t(BJ),_t(zJ),_t(jl),_t(du))},token:t,providedIn:"root"}),t}(),$J=function t(e){if(Object(m.a)(this,t),this.scrollStrategy=new KJ,this.panelClass="",this.hasBackdrop=!1,this.backdropClass="cdk-overlay-dark-backdrop",this.disposeOnNavigation=!1,e)for(var n=0,i=Object.keys(e);n<i.length;n++){var r=i[n];void 0!==e[r]&&(this[r]=e[r])}},JJ=function t(e,n,i,r,o){Object(m.a)(this,t),this.offsetX=i,this.offsetY=r,this.panelClass=o,this.originX=e.originX,this.originY=e.originY,this.overlayX=n.overlayX,this.overlayY=n.overlayY},t0=function(){return function t(e,n){Object(m.a)(this,t),this.connectionPair=e,this.scrollableViewProperties=n}}();function e0(t,e){if("top"!==e&&"bottom"!==e&&"center"!==e)throw Error("ConnectedPosition: Invalid ".concat(t,' "').concat(e,'". ')+'Expected "top", "bottom" or "center".')}function n0(t,e){if("start"!==e&&"end"!==e&&"center"!==e)throw Error("ConnectedPosition: Invalid ".concat(t,' "').concat(e,'". ')+'Expected "start", "end" or "center".')}var i0=function(){var t=function(){function t(e){var n=this;Object(m.a)(this,t),this._attachedOverlays=[],this._keydownListener=function(t){for(var e=n._attachedOverlays,i=e.length-1;i>-1;i--)if(e[i]._keydownEvents.observers.length>0){e[i]._keydownEvents.next(t);break}},this._document=e}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this._detach()}},{key:"add",value:function(t){this.remove(t),this._isAttached||(this._document.body.addEventListener("keydown",this._keydownListener),this._isAttached=!0),this._attachedOverlays.push(t)}},{key:"remove",value:function(t){var e=this._attachedOverlays.indexOf(t);e>-1&&this._attachedOverlays.splice(e,1),0===this._attachedOverlays.length&&this._detach()}},{key:"_detach",value:function(){this._isAttached&&(this._document.body.removeEventListener("keydown",this._keydownListener),this._isAttached=!1)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(du))},t.\u0275prov=R({factory:function(){return new t(_t(du))},token:t,providedIn:"root"}),t}(),r0=!("undefined"==typeof window||!window||!window.__karma__&&!window.jasmine),o0=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._platform=n,this._document=e}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){var t=this._containerElement;t&&t.parentNode&&t.parentNode.removeChild(t)}},{key:"getContainerElement",value:function(){return this._containerElement||this._createContainer(),this._containerElement}},{key:"_createContainer",value:function(){var t=this._platform?this._platform.isBrowser:"undefined"!=typeof window;if(t||r0)for(var e=this._document.querySelectorAll(".".concat("cdk-overlay-container",'[platform="server"], ')+".".concat("cdk-overlay-container",'[platform="test"]')),n=0;n<e.length;n++)e[n].parentNode.removeChild(e[n]);var i=this._document.createElement("div");i.classList.add("cdk-overlay-container"),r0?i.setAttribute("platform","test"):t||i.setAttribute("platform","server"),this._document.body.appendChild(i),this._containerElement=i}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(du),_t(Cm))},t.\u0275prov=R({factory:function(){return new t(_t(du),_t(Cm))},token:t,providedIn:"root"}),t}(),a0=function(){function t(e,n,i,r,o,a,s,c){var l=this;Object(m.a)(this,t),this._portalOutlet=e,this._host=n,this._pane=i,this._config=r,this._ngZone=o,this._keyboardDispatcher=a,this._document=s,this._location=c,this._backdropElement=null,this._backdropClick=new w.b,this._attachments=new w.b,this._detachments=new w.b,this._locationChanges=_.a.EMPTY,this._backdropClickHandler=function(t){return l._backdropClick.next(t)},this._keydownEvents=new w.b,r.scrollStrategy&&(this._scrollStrategy=r.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=r.positionStrategy}return Object(g.a)(t,[{key:"attach",value:function(t){var e=this,n=this._portalOutlet.attach(t);return!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host),this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._ngZone.onStable.asObservable().pipe(Object(FX.a)(1)).subscribe((function(){e.hasAttached()&&e.updatePosition()})),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&this._location&&(this._locationChanges=this._location.subscribe((function(){return e.dispose()}))),n}},{key:"detach",value:function(){if(this.hasAttached()){this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();var t=this._portalOutlet.detach();return this._detachments.next(),this._keyboardDispatcher.remove(this),this._detachContentWhenStable(),this._locationChanges.unsubscribe(),t}}},{key:"dispose",value:function(){var t=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this.detachBackdrop(),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._host&&this._host.parentNode&&(this._host.parentNode.removeChild(this._host),this._host=null),this._previousHostParent=this._pane=null,t&&this._detachments.next(),this._detachments.complete()}},{key:"hasAttached",value:function(){return this._portalOutlet.hasAttached()}},{key:"backdropClick",value:function(){return this._backdropClick.asObservable()}},{key:"attachments",value:function(){return this._attachments.asObservable()}},{key:"detachments",value:function(){return this._detachments.asObservable()}},{key:"keydownEvents",value:function(){return this._keydownEvents.asObservable()}},{key:"getConfig",value:function(){return this._config}},{key:"updatePosition",value:function(){this._positionStrategy&&this._positionStrategy.apply()}},{key:"updatePositionStrategy",value:function(t){t!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=t,this.hasAttached()&&(t.attach(this),this.updatePosition()))}},{key:"updateSize",value:function(t){this._config=Object.assign(Object.assign({},this._config),t),this._updateElementSize()}},{key:"setDirection",value:function(t){this._config=Object.assign(Object.assign({},this._config),{direction:t}),this._updateElementDirection()}},{key:"addPanelClass",value:function(t){this._pane&&this._toggleClasses(this._pane,t,!0)}},{key:"removePanelClass",value:function(t){this._pane&&this._toggleClasses(this._pane,t,!1)}},{key:"getDirection",value:function(){var t=this._config.direction;return t?"string"==typeof t?t:t.value:"ltr"}},{key:"updateScrollStrategy",value:function(t){t!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=t,this.hasAttached()&&(t.attach(this),t.enable()))}},{key:"_updateElementDirection",value:function(){this._host.setAttribute("dir",this.getDirection())}},{key:"_updateElementSize",value:function(){if(this._pane){var t=this._pane.style;t.width=am(this._config.width),t.height=am(this._config.height),t.minWidth=am(this._config.minWidth),t.minHeight=am(this._config.minHeight),t.maxWidth=am(this._config.maxWidth),t.maxHeight=am(this._config.maxHeight)}}},{key:"_togglePointerEvents",value:function(t){this._pane.style.pointerEvents=t?"auto":"none"}},{key:"_attachBackdrop",value:function(){var t=this;this._backdropElement=this._document.createElement("div"),this._backdropElement.classList.add("cdk-overlay-backdrop"),this._config.backdropClass&&this._toggleClasses(this._backdropElement,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropElement,this._host),this._backdropElement.addEventListener("click",this._backdropClickHandler),"undefined"!=typeof requestAnimationFrame?this._ngZone.runOutsideAngular((function(){requestAnimationFrame((function(){t._backdropElement&&t._backdropElement.classList.add("cdk-overlay-backdrop-showing")}))})):this._backdropElement.classList.add("cdk-overlay-backdrop-showing")}},{key:"_updateStackingOrder",value:function(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}},{key:"detachBackdrop",value:function(){var t=this,e=this._backdropElement;if(e){var n,i=function i(){e&&(e.removeEventListener("click",t._backdropClickHandler),e.removeEventListener("transitionend",i),e.parentNode&&e.parentNode.removeChild(e)),t._backdropElement==e&&(t._backdropElement=null),t._config.backdropClass&&t._toggleClasses(e,t._config.backdropClass,!1),clearTimeout(n)};e.classList.remove("cdk-overlay-backdrop-showing"),this._ngZone.runOutsideAngular((function(){e.addEventListener("transitionend",i)})),e.style.pointerEvents="none",n=this._ngZone.runOutsideAngular((function(){return setTimeout(i,500)}))}}},{key:"_toggleClasses",value:function(t,e,n){var i=t.classList;om(e).forEach((function(t){t&&(n?i.add(t):i.remove(t))}))}},{key:"_detachContentWhenStable",value:function(){var t=this;this._ngZone.runOutsideAngular((function(){var e=t._ngZone.onStable.asObservable().pipe(Object(Am.a)(Object(C.a)(t._attachments,t._detachments))).subscribe((function(){t._pane&&t._host&&0!==t._pane.children.length||(t._pane&&t._config.panelClass&&t._toggleClasses(t._pane,t._config.panelClass,!1),t._host&&t._host.parentElement&&(t._previousHostParent=t._host.parentElement,t._previousHostParent.removeChild(t._host)),e.unsubscribe())}))}))}},{key:"_disposeScrollStrategy",value:function(){var t=this._scrollStrategy;t&&(t.disable(),t.detach&&t.detach())}},{key:"overlayElement",get:function(){return this._pane}},{key:"backdropElement",get:function(){return this._backdropElement}},{key:"hostElement",get:function(){return this._host}}]),t}(),s0=/([A-Za-z%]+)$/,c0=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this._viewportRuler=n,this._document=i,this._platform=r,this._overlayContainer=o,this._lastBoundingBoxSize={width:0,height:0},this._isPushed=!1,this._canPush=!0,this._growAfterOpen=!1,this._hasFlexibleDimensions=!0,this._positionLocked=!1,this._viewportMargin=0,this._scrollables=[],this._preferredPositions=[],this._positionChanges=new w.b,this._resizeSubscription=_.a.EMPTY,this._offsetX=0,this._offsetY=0,this._appliedPanelClasses=[],this.positionChanges=this._positionChanges.asObservable(),this.setOrigin(e)}return Object(g.a)(t,[{key:"attach",value:function(t){var e=this;if(this._overlayRef&&t!==this._overlayRef)throw Error("This position strategy is already attached to an overlay");this._validatePositions(),t.hostElement.classList.add("cdk-overlay-connected-position-bounding-box"),this._overlayRef=t,this._boundingBox=t.hostElement,this._pane=t.overlayElement,this._isDisposed=!1,this._isInitialRender=!0,this._lastPosition=null,this._resizeSubscription.unsubscribe(),this._resizeSubscription=this._viewportRuler.change().subscribe((function(){e._isInitialRender=!0,e.apply()}))}},{key:"apply",value:function(){if(!this._isDisposed&&this._platform.isBrowser)if(!this._isInitialRender&&this._positionLocked&&this._lastPosition)this.reapplyLastPosition();else{this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect();var t,e,n=this._originRect,i=this._overlayRect,r=this._viewportRect,o=[],a=d(this._preferredPositions);try{for(a.s();!(e=a.n()).done;){var s=e.value,c=this._getOriginPoint(n,s),l=this._getOverlayPoint(c,i,s),u=this._getOverlayFit(l,i,r,s);if(u.isCompletelyWithinViewport)return this._isPushed=!1,void this._applyPosition(s,c);this._canFitWithFlexibleDimensions(u,l,r)?o.push({position:s,origin:c,overlayRect:i,boundingBoxRect:this._calculateBoundingBoxRect(c,s)}):(!t||t.overlayFit.visibleArea<u.visibleArea)&&(t={overlayFit:u,overlayPoint:l,originPoint:c,position:s,overlayRect:i})}}catch(b){a.e(b)}finally{a.f()}if(o.length){var h,f=null,p=-1,m=d(o);try{for(m.s();!(h=m.n()).done;){var g=h.value,v=g.boundingBoxRect.width*g.boundingBoxRect.height*(g.position.weight||1);v>p&&(p=v,f=g)}}catch(b){m.e(b)}finally{m.f()}return this._isPushed=!1,void this._applyPosition(f.position,f.origin)}if(this._canPush)return this._isPushed=!0,void this._applyPosition(t.position,t.originPoint);this._applyPosition(t.position,t.originPoint)}}},{key:"detach",value:function(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}},{key:"dispose",value:function(){this._isDisposed||(this._boundingBox&&l0(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove("cdk-overlay-connected-position-bounding-box"),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}},{key:"reapplyLastPosition",value:function(){if(!this._isDisposed&&(!this._platform||this._platform.isBrowser)){this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect();var t=this._lastPosition||this._preferredPositions[0],e=this._getOriginPoint(this._originRect,t);this._applyPosition(t,e)}}},{key:"withScrollableContainers",value:function(t){return this._scrollables=t,this}},{key:"withPositions",value:function(t){return this._preferredPositions=t,-1===t.indexOf(this._lastPosition)&&(this._lastPosition=null),this._validatePositions(),this}},{key:"withViewportMargin",value:function(t){return this._viewportMargin=t,this}},{key:"withFlexibleDimensions",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._hasFlexibleDimensions=t,this}},{key:"withGrowAfterOpen",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._growAfterOpen=t,this}},{key:"withPush",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._canPush=t,this}},{key:"withLockedPosition",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._positionLocked=t,this}},{key:"setOrigin",value:function(t){return this._origin=t,this}},{key:"withDefaultOffsetX",value:function(t){return this._offsetX=t,this}},{key:"withDefaultOffsetY",value:function(t){return this._offsetY=t,this}},{key:"withTransformOriginOn",value:function(t){return this._transformOriginSelector=t,this}},{key:"_getOriginPoint",value:function(t,e){var n;if("center"==e.originX)n=t.left+t.width/2;else{var i=this._isRtl()?t.right:t.left,r=this._isRtl()?t.left:t.right;n="start"==e.originX?i:r}return{x:n,y:"center"==e.originY?t.top+t.height/2:"top"==e.originY?t.top:t.bottom}}},{key:"_getOverlayPoint",value:function(t,e,n){var i;return i="center"==n.overlayX?-e.width/2:"start"===n.overlayX?this._isRtl()?-e.width:0:this._isRtl()?0:-e.width,{x:t.x+i,y:t.y+("center"==n.overlayY?-e.height/2:"top"==n.overlayY?0:-e.height)}}},{key:"_getOverlayFit",value:function(t,e,n,i){var r=t.x,o=t.y,a=this._getOffset(i,"x"),s=this._getOffset(i,"y");a&&(r+=a),s&&(o+=s);var c=0-o,l=o+e.height-n.height,u=this._subtractOverflows(e.width,0-r,r+e.width-n.width),h=this._subtractOverflows(e.height,c,l),d=u*h;return{visibleArea:d,isCompletelyWithinViewport:e.width*e.height===d,fitsInViewportVertically:h===e.height,fitsInViewportHorizontally:u==e.width}}},{key:"_canFitWithFlexibleDimensions",value:function(t,e,n){if(this._hasFlexibleDimensions){var i=n.bottom-e.y,r=n.right-e.x,o=u0(this._overlayRef.getConfig().minHeight),a=u0(this._overlayRef.getConfig().minWidth);return(t.fitsInViewportVertically||null!=o&&o<=i)&&(t.fitsInViewportHorizontally||null!=a&&a<=r)}return!1}},{key:"_pushOverlayOnScreen",value:function(t,e,n){if(this._previousPushAmount&&this._positionLocked)return{x:t.x+this._previousPushAmount.x,y:t.y+this._previousPushAmount.y};var i,r,o=this._viewportRect,a=Math.max(t.x+e.width-o.right,0),s=Math.max(t.y+e.height-o.bottom,0),c=Math.max(o.top-n.top-t.y,0),l=Math.max(o.left-n.left-t.x,0);return this._previousPushAmount={x:i=e.width<=o.width?l||-a:t.x<this._viewportMargin?o.left-n.left-t.x:0,y:r=e.height<=o.height?c||-s:t.y<this._viewportMargin?o.top-n.top-t.y:0},{x:t.x+i,y:t.y+r}}},{key:"_applyPosition",value:function(t,e){if(this._setTransformOrigin(t),this._setOverlayElementStyles(e,t),this._setBoundingBoxStyles(e,t),t.panelClass&&this._addPanelClasses(t.panelClass),this._lastPosition=t,this._positionChanges.observers.length){var n=this._getScrollVisibility(),i=new t0(t,n);this._positionChanges.next(i)}this._isInitialRender=!1}},{key:"_setTransformOrigin",value:function(t){if(this._transformOriginSelector){var e,n=this._boundingBox.querySelectorAll(this._transformOriginSelector),i=t.overlayY;e="center"===t.overlayX?"center":this._isRtl()?"start"===t.overlayX?"right":"left":"start"===t.overlayX?"left":"right";for(var r=0;r<n.length;r++)n[r].style.transformOrigin="".concat(e," ").concat(i)}}},{key:"_calculateBoundingBoxRect",value:function(t,e){var n,i,r,o,a,s,c=this._viewportRect,l=this._isRtl();if("top"===e.overlayY)n=c.height-(i=t.y)+this._viewportMargin;else if("bottom"===e.overlayY)n=c.height-(r=c.height-t.y+2*this._viewportMargin)+this._viewportMargin;else{var u=Math.min(c.bottom-t.y+c.top,t.y),h=this._lastBoundingBoxSize.height;i=t.y-u,(n=2*u)>h&&!this._isInitialRender&&!this._growAfterOpen&&(i=t.y-h/2)}if("end"===e.overlayX&&!l||"start"===e.overlayX&&l)s=c.width-t.x+this._viewportMargin,o=t.x-this._viewportMargin;else if("start"===e.overlayX&&!l||"end"===e.overlayX&&l)a=t.x,o=c.right-t.x;else{var d=Math.min(c.right-t.x+c.left,t.x),f=this._lastBoundingBoxSize.width;a=t.x-d,(o=2*d)>f&&!this._isInitialRender&&!this._growAfterOpen&&(a=t.x-f/2)}return{top:i,left:a,bottom:r,right:s,width:o,height:n}}},{key:"_setBoundingBoxStyles",value:function(t,e){var n=this._calculateBoundingBoxRect(t,e);this._isInitialRender||this._growAfterOpen||(n.height=Math.min(n.height,this._lastBoundingBoxSize.height),n.width=Math.min(n.width,this._lastBoundingBoxSize.width));var i={};if(this._hasExactPosition())i.top=i.left="0",i.bottom=i.right=i.maxHeight=i.maxWidth="",i.width=i.height="100%";else{var r=this._overlayRef.getConfig().maxHeight,o=this._overlayRef.getConfig().maxWidth;i.height=am(n.height),i.top=am(n.top),i.bottom=am(n.bottom),i.width=am(n.width),i.left=am(n.left),i.right=am(n.right),i.alignItems="center"===e.overlayX?"center":"end"===e.overlayX?"flex-end":"flex-start",i.justifyContent="center"===e.overlayY?"center":"bottom"===e.overlayY?"flex-end":"flex-start",r&&(i.maxHeight=am(r)),o&&(i.maxWidth=am(o))}this._lastBoundingBoxSize=n,l0(this._boundingBox.style,i)}},{key:"_resetBoundingBoxStyles",value:function(){l0(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}},{key:"_resetOverlayElementStyles",value:function(){l0(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}},{key:"_setOverlayElementStyles",value:function(t,e){var n={},i=this._hasExactPosition(),r=this._hasFlexibleDimensions,o=this._overlayRef.getConfig();if(i){var a=this._viewportRuler.getViewportScrollPosition();l0(n,this._getExactOverlayY(e,t,a)),l0(n,this._getExactOverlayX(e,t,a))}else n.position="static";var s="",c=this._getOffset(e,"x"),l=this._getOffset(e,"y");c&&(s+="translateX(".concat(c,"px) ")),l&&(s+="translateY(".concat(l,"px)")),n.transform=s.trim(),o.maxHeight&&(i?n.maxHeight=am(o.maxHeight):r&&(n.maxHeight="")),o.maxWidth&&(i?n.maxWidth=am(o.maxWidth):r&&(n.maxWidth="")),l0(this._pane.style,n)}},{key:"_getExactOverlayY",value:function(t,e,n){var i={top:"",bottom:""},r=this._getOverlayPoint(e,this._overlayRect,t);this._isPushed&&(r=this._pushOverlayOnScreen(r,this._overlayRect,n));var o=this._overlayContainer.getContainerElement().getBoundingClientRect().top;return r.y-=o,"bottom"===t.overlayY?i.bottom="".concat(this._document.documentElement.clientHeight-(r.y+this._overlayRect.height),"px"):i.top=am(r.y),i}},{key:"_getExactOverlayX",value:function(t,e,n){var i={left:"",right:""},r=this._getOverlayPoint(e,this._overlayRect,t);return this._isPushed&&(r=this._pushOverlayOnScreen(r,this._overlayRect,n)),"right"==(this._isRtl()?"end"===t.overlayX?"left":"right":"end"===t.overlayX?"right":"left")?i.right="".concat(this._document.documentElement.clientWidth-(r.x+this._overlayRect.width),"px"):i.left=am(r.x),i}},{key:"_getScrollVisibility",value:function(){var t=this._getOriginRect(),e=this._pane.getBoundingClientRect(),n=this._scrollables.map((function(t){return t.getElementRef().nativeElement.getBoundingClientRect()}));return{isOriginClipped:YJ(t,n),isOriginOutsideView:XJ(t,n),isOverlayClipped:YJ(e,n),isOverlayOutsideView:XJ(e,n)}}},{key:"_subtractOverflows",value:function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];return n.reduce((function(t,e){return t-Math.max(e,0)}),t)}},{key:"_getNarrowedViewportRect",value:function(){var t=this._document.documentElement.clientWidth,e=this._document.documentElement.clientHeight,n=this._viewportRuler.getViewportScrollPosition();return{top:n.top+this._viewportMargin,left:n.left+this._viewportMargin,right:n.left+t-this._viewportMargin,bottom:n.top+e-this._viewportMargin,width:t-2*this._viewportMargin,height:e-2*this._viewportMargin}}},{key:"_isRtl",value:function(){return"rtl"===this._overlayRef.getDirection()}},{key:"_hasExactPosition",value:function(){return!this._hasFlexibleDimensions||this._isPushed}},{key:"_getOffset",value:function(t,e){return"x"===e?null==t.offsetX?this._offsetX:t.offsetX:null==t.offsetY?this._offsetY:t.offsetY}},{key:"_validatePositions",value:function(){if(!this._preferredPositions.length)throw Error("FlexibleConnectedPositionStrategy: At least one position is required.");this._preferredPositions.forEach((function(t){n0("originX",t.originX),e0("originY",t.originY),n0("overlayX",t.overlayX),e0("overlayY",t.overlayY)}))}},{key:"_addPanelClasses",value:function(t){var e=this;this._pane&&om(t).forEach((function(t){""!==t&&-1===e._appliedPanelClasses.indexOf(t)&&(e._appliedPanelClasses.push(t),e._pane.classList.add(t))}))}},{key:"_clearPanelClasses",value:function(){var t=this;this._pane&&(this._appliedPanelClasses.forEach((function(e){t._pane.classList.remove(e)})),this._appliedPanelClasses=[])}},{key:"_getOriginRect",value:function(){var t=this._origin;if(t instanceof Us)return t.nativeElement.getBoundingClientRect();if(t instanceof Element)return t.getBoundingClientRect();var e=t.width||0,n=t.height||0;return{top:t.y,bottom:t.y+n,left:t.x,right:t.x+e,height:n,width:e}}},{key:"positions",get:function(){return this._preferredPositions}}]),t}();function l0(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function u0(t){if("number"!=typeof t&&null!=t){var e=l(t.split(s0),2),n=e[1];return n&&"px"!==n?null:parseFloat(e[0])}return t||null}var h0=function(){function t(e,n,i,r,o,a,s){Object(m.a)(this,t),this._preferredPositions=[],this._positionStrategy=new c0(i,r,o,a,s).withFlexibleDimensions(!1).withPush(!1).withViewportMargin(0),this.withFallbackPosition(e,n)}return Object(g.a)(t,[{key:"attach",value:function(t){this._overlayRef=t,this._positionStrategy.attach(t),this._direction&&(t.setDirection(this._direction),this._direction=null)}},{key:"dispose",value:function(){this._positionStrategy.dispose()}},{key:"detach",value:function(){this._positionStrategy.detach()}},{key:"apply",value:function(){this._positionStrategy.apply()}},{key:"recalculateLastPosition",value:function(){this._positionStrategy.reapplyLastPosition()}},{key:"withScrollableContainers",value:function(t){this._positionStrategy.withScrollableContainers(t)}},{key:"withFallbackPosition",value:function(t,e,n,i){var r=new JJ(t,e,n,i);return this._preferredPositions.push(r),this._positionStrategy.withPositions(this._preferredPositions),this}},{key:"withDirection",value:function(t){return this._overlayRef?this._overlayRef.setDirection(t):this._direction=t,this}},{key:"withOffsetX",value:function(t){return this._positionStrategy.withDefaultOffsetX(t),this}},{key:"withOffsetY",value:function(t){return this._positionStrategy.withDefaultOffsetY(t),this}},{key:"withLockedPosition",value:function(t){return this._positionStrategy.withLockedPosition(t),this}},{key:"withPositions",value:function(t){return this._preferredPositions=t.slice(),this._positionStrategy.withPositions(this._preferredPositions),this}},{key:"setOrigin",value:function(t){return this._positionStrategy.setOrigin(t),this}},{key:"_isRtl",get:function(){return"rtl"===this._overlayRef.getDirection()}},{key:"onPositionChange",get:function(){return this._positionStrategy.positionChanges}},{key:"positions",get:function(){return this._preferredPositions}}]),t}(),d0=function(){function t(){Object(m.a)(this,t),this._cssPosition="static",this._topOffset="",this._bottomOffset="",this._leftOffset="",this._rightOffset="",this._alignItems="",this._justifyContent="",this._width="",this._height=""}return Object(g.a)(t,[{key:"attach",value:function(t){var e=t.getConfig();this._overlayRef=t,this._width&&!e.width&&t.updateSize({width:this._width}),this._height&&!e.height&&t.updateSize({height:this._height}),t.hostElement.classList.add("cdk-global-overlay-wrapper"),this._isDisposed=!1}},{key:"top",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return this._bottomOffset="",this._topOffset=t,this._alignItems="flex-start",this}},{key:"left",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return this._rightOffset="",this._leftOffset=t,this._justifyContent="flex-start",this}},{key:"bottom",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return this._topOffset="",this._bottomOffset=t,this._alignItems="flex-end",this}},{key:"right",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return this._leftOffset="",this._rightOffset=t,this._justifyContent="flex-end",this}},{key:"width",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return this._overlayRef?this._overlayRef.updateSize({width:t}):this._width=t,this}},{key:"height",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return this._overlayRef?this._overlayRef.updateSize({height:t}):this._height=t,this}},{key:"centerHorizontally",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return this.left(t),this._justifyContent="center",this}},{key:"centerVertically",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return this.top(t),this._alignItems="center",this}},{key:"apply",value:function(){if(this._overlayRef&&this._overlayRef.hasAttached()){var t=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement.style,n=this._overlayRef.getConfig(),i=n.width,r=n.height,o=n.maxWidth,a=n.maxHeight,s=!("100%"!==i&&"100vw"!==i||o&&"100%"!==o&&"100vw"!==o),c=!("100%"!==r&&"100vh"!==r||a&&"100%"!==a&&"100vh"!==a);t.position=this._cssPosition,t.marginLeft=s?"0":this._leftOffset,t.marginTop=c?"0":this._topOffset,t.marginBottom=this._bottomOffset,t.marginRight=this._rightOffset,s?e.justifyContent="flex-start":"center"===this._justifyContent?e.justifyContent="center":"rtl"===this._overlayRef.getConfig().direction?"flex-start"===this._justifyContent?e.justifyContent="flex-end":"flex-end"===this._justifyContent&&(e.justifyContent="flex-start"):e.justifyContent=this._justifyContent,e.alignItems=c?"flex-start":this._alignItems}}},{key:"dispose",value:function(){if(!this._isDisposed&&this._overlayRef){var t=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement,n=e.style;e.classList.remove("cdk-global-overlay-wrapper"),n.justifyContent=n.alignItems=t.marginTop=t.marginBottom=t.marginLeft=t.marginRight=t.position="",this._overlayRef=null,this._isDisposed=!0}}}]),t}(),f0=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._viewportRuler=e,this._document=n,this._platform=i,this._overlayContainer=r}return Object(g.a)(t,[{key:"global",value:function(){return new d0}},{key:"connectedTo",value:function(t,e,n){return new h0(e,n,t,this._viewportRuler,this._document,this._platform,this._overlayContainer)}},{key:"flexibleConnectedTo",value:function(t){return new c0(t,this._viewportRuler,this._document,this._platform,this._overlayContainer)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(zJ),_t(du),_t(Cm),_t(o0))},t.\u0275prov=R({factory:function(){return new t(_t(zJ),_t(du),_t(Cm),_t(o0))},token:t,providedIn:"root"}),t}(),p0=0,m0=function(){var t=function(){function t(e,n,i,r,o,a,s,c,l,u){Object(m.a)(this,t),this.scrollStrategies=e,this._overlayContainer=n,this._componentFactoryResolver=i,this._positionBuilder=r,this._keyboardDispatcher=o,this._injector=a,this._ngZone=s,this._document=c,this._directionality=l,this._location=u}return Object(g.a)(t,[{key:"create",value:function(t){var e=this._createHostElement(),n=this._createPaneElement(e),i=this._createPortalOutlet(n),r=new $J(t);return r.direction=r.direction||this._directionality.value,new a0(i,e,n,r,this._ngZone,this._keyboardDispatcher,this._document,this._location)}},{key:"position",value:function(){return this._positionBuilder}},{key:"_createPaneElement",value:function(t){var e=this._document.createElement("div");return e.id="cdk-overlay-".concat(p0++),e.classList.add("cdk-overlay-pane"),t.appendChild(e),e}},{key:"_createHostElement",value:function(){var t=this._document.createElement("div");return this._overlayContainer.getContainerElement().appendChild(t),t}},{key:"_createPortalOutlet",value:function(t){return this._appRef||(this._appRef=this._injector.get(Jl)),new F$(t,this._componentFactoryResolver,this._appRef,this._injector,this._document)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(QJ),_t(o0),_t(Vs),_t(f0),_t(i0),_t(Xo),_t(jl),_t(du),_t(gm),_t(Mu,8))},t.\u0275prov=R({token:t,factory:function(e){return t.\u0275fac(e)}}),t}(),g0=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],v0=new ht("cdk-connected-overlay-scroll-strategy"),b0=function(){var t=function t(e){Object(m.a)(this,t),this.elementRef=e};return t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"]}),t}(),y0=function(){var t=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this._overlay=e,this._dir=o,this._hasBackdrop=!1,this._lockPosition=!1,this._growAfterOpen=!1,this._flexibleDimensions=!1,this._push=!1,this._backdropSubscription=_.a.EMPTY,this.viewportMargin=0,this.open=!1,this.backdropClick=new Uc,this.positionChange=new Uc,this.attach=new Uc,this.detach=new Uc,this.overlayKeydown=new Uc,this._templatePortal=new D$(n,i),this._scrollStrategyFactory=r,this.scrollStrategy=this._scrollStrategyFactory()}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this._overlayRef&&this._overlayRef.dispose(),this._backdropSubscription.unsubscribe()}},{key:"ngOnChanges",value:function(t){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef.updateSize({width:this.width,minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),t.origin&&this.open&&this._position.apply()),t.open&&(this.open?this._attachOverlay():this._detachOverlay())}},{key:"_createOverlay",value:function(){var t=this;this.positions&&this.positions.length||(this.positions=g0),this._overlayRef=this._overlay.create(this._buildConfig()),this._overlayRef.keydownEvents().subscribe((function(e){t.overlayKeydown.next(e),27!==e.keyCode||JQ(e)||(e.preventDefault(),t._detachOverlay())}))}},{key:"_buildConfig",value:function(){var t=this._position=this.positionStrategy||this._createPositionStrategy(),e=new $J({direction:this._dir,positionStrategy:t,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop});return(this.width||0===this.width)&&(e.width=this.width),(this.height||0===this.height)&&(e.height=this.height),(this.minWidth||0===this.minWidth)&&(e.minWidth=this.minWidth),(this.minHeight||0===this.minHeight)&&(e.minHeight=this.minHeight),this.backdropClass&&(e.backdropClass=this.backdropClass),this.panelClass&&(e.panelClass=this.panelClass),e}},{key:"_updatePositionStrategy",value:function(t){var e=this,n=this.positions.map((function(t){return{originX:t.originX,originY:t.originY,overlayX:t.overlayX,overlayY:t.overlayY,offsetX:t.offsetX||e.offsetX,offsetY:t.offsetY||e.offsetY,panelClass:t.panelClass||void 0}}));return t.setOrigin(this.origin.elementRef).withPositions(n).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector)}},{key:"_createPositionStrategy",value:function(){var t=this,e=this._overlay.position().flexibleConnectedTo(this.origin.elementRef);return this._updatePositionStrategy(e),e.positionChanges.subscribe((function(e){return t.positionChange.emit(e)})),e}},{key:"_attachOverlay",value:function(){var t=this;this._overlayRef?this._overlayRef.getConfig().hasBackdrop=this.hasBackdrop:this._createOverlay(),this._overlayRef.hasAttached()||(this._overlayRef.attach(this._templatePortal),this.attach.emit()),this.hasBackdrop?this._backdropSubscription=this._overlayRef.backdropClick().subscribe((function(e){t.backdropClick.emit(e)})):this._backdropSubscription.unsubscribe()}},{key:"_detachOverlay",value:function(){this._overlayRef&&(this._overlayRef.detach(),this.detach.emit()),this._backdropSubscription.unsubscribe()}},{key:"offsetX",get:function(){return this._offsetX},set:function(t){this._offsetX=t,this._position&&this._updatePositionStrategy(this._position)}},{key:"offsetY",get:function(){return this._offsetY},set:function(t){this._offsetY=t,this._position&&this._updatePositionStrategy(this._position)}},{key:"hasBackdrop",get:function(){return this._hasBackdrop},set:function(t){this._hasBackdrop=nm(t)}},{key:"lockPosition",get:function(){return this._lockPosition},set:function(t){this._lockPosition=nm(t)}},{key:"flexibleDimensions",get:function(){return this._flexibleDimensions},set:function(t){this._flexibleDimensions=nm(t)}},{key:"growAfterOpen",get:function(){return this._growAfterOpen},set:function(t){this._growAfterOpen=nm(t)}},{key:"push",get:function(){return this._push},set:function(t){this._push=nm(t)}},{key:"overlayRef",get:function(){return this._overlayRef}},{key:"dir",get:function(){return this._dir?this._dir.value:"ltr"}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(m0),da(fc),da(mc),da(v0),da(gm,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{viewportMargin:["cdkConnectedOverlayViewportMargin","viewportMargin"],open:["cdkConnectedOverlayOpen","open"],scrollStrategy:["cdkConnectedOverlayScrollStrategy","scrollStrategy"],offsetX:["cdkConnectedOverlayOffsetX","offsetX"],offsetY:["cdkConnectedOverlayOffsetY","offsetY"],hasBackdrop:["cdkConnectedOverlayHasBackdrop","hasBackdrop"],lockPosition:["cdkConnectedOverlayLockPosition","lockPosition"],flexibleDimensions:["cdkConnectedOverlayFlexibleDimensions","flexibleDimensions"],growAfterOpen:["cdkConnectedOverlayGrowAfterOpen","growAfterOpen"],push:["cdkConnectedOverlayPush","push"],positions:["cdkConnectedOverlayPositions","positions"],origin:["cdkConnectedOverlayOrigin","origin"],positionStrategy:["cdkConnectedOverlayPositionStrategy","positionStrategy"],width:["cdkConnectedOverlayWidth","width"],height:["cdkConnectedOverlayHeight","height"],minWidth:["cdkConnectedOverlayMinWidth","minWidth"],minHeight:["cdkConnectedOverlayMinHeight","minHeight"],backdropClass:["cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:["cdkConnectedOverlayPanelClass","panelClass"],transformOriginSelector:["cdkConnectedOverlayTransformOriginOn","transformOriginSelector"]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown"},exportAs:["cdkConnectedOverlay"],features:[Ms]}),t}(),_0={provide:v0,deps:[m0],useFactory:function(t){return function(){return t.scrollStrategies.reposition()}}},w0=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[m0,_0],imports:[[bm,z$,UJ],UJ]}),t}(),k0=["mat-menu-item",""],C0=["*"];function S0(t,e){if(1&t){var n=ka();ga(0,"div",0),xa("keydown",(function(t){return Se(n),Aa()._handleKeydown(t)}))("click",(function(){return Se(n),Aa().closed.emit("click")}))("@transformMenu.start",(function(t){return Se(n),Aa()._onAnimationStart(t)}))("@transformMenu.done",(function(t){return Se(n),Aa()._onAnimationDone(t)})),ga(1,"div",1),Da(2),va(),va()}if(2&t){var i=Aa();pa("id",i.panelId)("ngClass",i._classList)("@transformMenu",i._panelAnimationState),oa("aria-label",i.ariaLabel||null)("aria-labelledby",i.ariaLabelledby||null)("aria-describedby",i.ariaDescribedby||null)}}var x0={transformMenu:Jg("transformMenu",[rv("void",iv({opacity:0,transform:"scale(0.8)"})),av("void => enter",ev([cv(".mat-menu-content, .mat-mdc-menu-content",tv("100ms linear",iv({opacity:1}))),tv("120ms cubic-bezier(0, 0, 0.2, 1)",iv({transform:"scale(1)"}))])),av("* => void",tv("100ms 25ms linear",iv({opacity:0})))]),fadeInItems:Jg("fadeInItems",[rv("showing",iv({opacity:1})),av("void => *",[iv({opacity:0}),tv("400ms 100ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])},O0=function(){var t=function(){function t(e,n,i,r,o,a,s){Object(m.a)(this,t),this._template=e,this._componentFactoryResolver=n,this._appRef=i,this._injector=r,this._viewContainerRef=o,this._document=a,this._changeDetectorRef=s,this._attached=new w.b}return Object(g.a)(t,[{key:"attach",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this._portal||(this._portal=new D$(this._template,this._viewContainerRef)),this.detach(),this._outlet||(this._outlet=new F$(this._document.createElement("div"),this._componentFactoryResolver,this._appRef,this._injector));var e=this._template.elementRef.nativeElement;e.parentNode.insertBefore(this._outlet.outletElement,e),this._changeDetectorRef&&this._changeDetectorRef.markForCheck(),this._portal.attach(this._outlet,t),this._attached.next()}},{key:"detach",value:function(){this._portal.isAttached&&this._portal.detach()}},{key:"ngOnDestroy",value:function(){this._outlet&&this._outlet.dispose()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(fc),da(Vs),da(Jl),da(Xo),da(mc),da(du),da(Po))},t.\u0275dir=Wt({type:t,selectors:[["ng-template","matMenuContent",""]]}),t}(),M0=new ht("MAT_MENU_PANEL"),T0=eJ(J$((function t(){Object(m.a)(this,t)}))),E0=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this))._elementRef=t,a._focusMonitor=r,a._parentMenu=o,a.role="menuitem",a._hovered=new w.b,a._focused=new w.b,a._highlighted=!1,a._triggersSubmenu=!1,o&&o.addItem&&o.addItem(Object(s.a)(a)),a._document=i,a}return Object(g.a)(n,[{key:"focus",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"program",e=arguments.length>1?arguments[1]:void 0;this._focusMonitor?this._focusMonitor.focusVia(this._getHostElement(),t,e):this._getHostElement().focus(e),this._focused.next(this)}},{key:"ngAfterViewInit",value:function(){this._focusMonitor&&this._focusMonitor.monitor(this._elementRef,!1)}},{key:"ngOnDestroy",value:function(){this._focusMonitor&&this._focusMonitor.stopMonitoring(this._elementRef),this._parentMenu&&this._parentMenu.removeItem&&this._parentMenu.removeItem(this),this._hovered.complete(),this._focused.complete()}},{key:"_getTabIndex",value:function(){return this.disabled?"-1":"0"}},{key:"_getHostElement",value:function(){return this._elementRef.nativeElement}},{key:"_checkDisabled",value:function(t){this.disabled&&(t.preventDefault(),t.stopPropagation())}},{key:"_handleMouseEnter",value:function(){this._hovered.next(this)}},{key:"getLabel",value:function(){var t=this._elementRef.nativeElement,e=this._document?this._document.TEXT_NODE:3,n="";if(t.childNodes)for(var i=t.childNodes.length,r=0;r<i;r++)t.childNodes[r].nodeType===e&&(n+=t.childNodes[r].textContent);return n.trim()}}]),n}(T0);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(du),da(S$),da(M0,8))},t.\u0275cmp=Ht({type:t,selectors:[["","mat-menu-item",""]],hostAttrs:[1,"mat-focus-indicator"],hostVars:10,hostBindings:function(t,e){1&t&&xa("click",(function(t){return e._checkDisabled(t)}))("mouseenter",(function(){return e._handleMouseEnter()})),2&t&&(oa("role",e.role)("tabindex",e._getTabIndex())("aria-disabled",e.disabled.toString())("disabled",e.disabled||null),Qa("mat-menu-item",!0)("mat-menu-item-highlighted",e._highlighted)("mat-menu-item-submenu-trigger",e._triggersSubmenu))},inputs:{disabled:"disabled",disableRipple:"disableRipple",role:"role"},exportAs:["matMenuItem"],features:[ws],attrs:k0,ngContentSelectors:C0,decls:2,vars:2,consts:[["matRipple","",1,"mat-menu-ripple",3,"matRippleDisabled","matRippleTrigger"]],template:function(t,e){1&t&&(Ia(),Da(0),ba(1,"div",0)),2&t&&(Qi(1),pa("matRippleDisabled",e.disableRipple||e.disabled)("matRippleTrigger",e._getHostElement()))},directives:[yJ],encapsulation:2,changeDetection:0}),t}(),P0=new ht("mat-menu-default-options",{providedIn:"root",factory:function(){return{overlapTrigger:!1,xPosition:"after",yPosition:"below",backdropClass:"cdk-overlay-transparent-backdrop"}}}),A0=0,j0=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._elementRef=e,this._ngZone=n,this._defaultOptions=i,this._xPosition=this._defaultOptions.xPosition,this._yPosition=this._defaultOptions.yPosition,this._directDescendantItems=new Gc,this._tabSubscription=_.a.EMPTY,this._classList={},this._panelAnimationState="void",this._animationDone=new w.b,this.backdropClass=this._defaultOptions.backdropClass,this._overlapTrigger=this._defaultOptions.overlapTrigger,this._hasBackdrop=this._defaultOptions.hasBackdrop,this.closed=new Uc,this.close=this.closed,this.panelId="mat-menu-panel-".concat(A0++)}return Object(g.a)(t,[{key:"ngOnInit",value:function(){this.setPositionClasses()}},{key:"ngAfterContentInit",value:function(){var t=this;this._updateDirectDescendants(),this._keyManager=new d$(this._directDescendantItems).withWrap().withTypeAhead(),this._tabSubscription=this._keyManager.tabOut.subscribe((function(){return t.closed.emit("tab")})),this._directDescendantItems.changes.pipe(Object(NX.a)(this._directDescendantItems),Object(LX.a)((function(t){return C.a.apply(void 0,Object(u.a)(t.map((function(t){return t._focused}))))}))).subscribe((function(e){return t._keyManager.updateActiveItem(e)}))}},{key:"ngOnDestroy",value:function(){this._directDescendantItems.destroy(),this._tabSubscription.unsubscribe(),this.closed.complete()}},{key:"_hovered",value:function(){return this._directDescendantItems.changes.pipe(Object(NX.a)(this._directDescendantItems),Object(LX.a)((function(t){return C.a.apply(void 0,Object(u.a)(t.map((function(t){return t._hovered}))))})))}},{key:"addItem",value:function(t){}},{key:"removeItem",value:function(t){}},{key:"_handleKeydown",value:function(t){var e=t.keyCode,n=this._keyManager;switch(e){case 27:JQ(t)||(t.preventDefault(),this.closed.emit("keydown"));break;case 37:this.parentMenu&&"ltr"===this.direction&&this.closed.emit("keydown");break;case 39:this.parentMenu&&"rtl"===this.direction&&this.closed.emit("keydown");break;case 36:case 35:JQ(t)||(36===e?n.setFirstItemActive():n.setLastItemActive(),t.preventDefault());break;default:38!==e&&40!==e||n.setFocusOrigin("keyboard"),n.onKeydown(t)}}},{key:"focusFirstItem",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"program";this.lazyContent?this._ngZone.onStable.asObservable().pipe(Object(FX.a)(1)).subscribe((function(){return t._focusFirstItem(e)})):this._focusFirstItem(e)}},{key:"_focusFirstItem",value:function(t){var e=this._keyManager;if(e.setFocusOrigin(t).setFirstItemActive(),!e.activeItem&&this._directDescendantItems.length)for(var n=this._directDescendantItems.first._getHostElement().parentElement;n;){if("menu"===n.getAttribute("role")){n.focus();break}n=n.parentElement}}},{key:"resetActiveItem",value:function(){this._keyManager.setActiveItem(-1)}},{key:"setElevation",value:function(t){var e=Math.min(4+t,24),n="mat-elevation-z".concat(e),i=Object.keys(this._classList).find((function(t){return t.startsWith("mat-elevation-z")}));i&&i!==this._previousElevation||(this._previousElevation&&(this._classList[this._previousElevation]=!1),this._classList[n]=!0,this._previousElevation=n)}},{key:"setPositionClasses",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.xPosition,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.yPosition,n=this._classList;n["mat-menu-before"]="before"===t,n["mat-menu-after"]="after"===t,n["mat-menu-above"]="above"===e,n["mat-menu-below"]="below"===e}},{key:"_startAnimation",value:function(){this._panelAnimationState="enter"}},{key:"_resetAnimation",value:function(){this._panelAnimationState="void"}},{key:"_onAnimationDone",value:function(t){this._animationDone.next(t),this._isAnimating=!1}},{key:"_onAnimationStart",value:function(t){this._isAnimating=!0,"enter"===t.toState&&0===this._keyManager.activeItemIndex&&(t.element.scrollTop=0)}},{key:"_updateDirectDescendants",value:function(){var t=this;this._allItems.changes.pipe(Object(NX.a)(this._allItems)).subscribe((function(e){t._directDescendantItems.reset(e.filter((function(e){return e._parentMenu===t}))),t._directDescendantItems.notifyOnChanges()}))}},{key:"xPosition",get:function(){return this._xPosition},set:function(t){"before"!==t&&"after"!==t&&function(){throw Error('xPosition value must be either \'before\' or after\'.\n Example: <mat-menu xPosition="before" #menu="matMenu"></mat-menu>')}(),this._xPosition=t,this.setPositionClasses()}},{key:"yPosition",get:function(){return this._yPosition},set:function(t){"above"!==t&&"below"!==t&&function(){throw Error('yPosition value must be either \'above\' or below\'.\n Example: <mat-menu yPosition="above" #menu="matMenu"></mat-menu>')}(),this._yPosition=t,this.setPositionClasses()}},{key:"overlapTrigger",get:function(){return this._overlapTrigger},set:function(t){this._overlapTrigger=nm(t)}},{key:"hasBackdrop",get:function(){return this._hasBackdrop},set:function(t){this._hasBackdrop=nm(t)}},{key:"panelClass",set:function(t){var e=this,n=this._previousPanelClass;n&&n.length&&n.split(" ").forEach((function(t){e._classList[t]=!1})),this._previousPanelClass=t,t&&t.length&&(t.split(" ").forEach((function(t){e._classList[t]=!0})),this._elementRef.nativeElement.className="")}},{key:"classList",get:function(){return this.panelClass},set:function(t){this.panelClass=t}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(jl),da(P0))},t.\u0275dir=Wt({type:t,contentQueries:function(t,e,n){var i;1&t&&(rl(n,O0,!0),rl(n,E0,!0),rl(n,E0,!1)),2&t&&(tl(i=sl())&&(e.lazyContent=i.first),tl(i=sl())&&(e._allItems=i),tl(i=sl())&&(e.items=i))},viewQuery:function(t,e){var n;1&t&&nl(fc,!0),2&t&&tl(n=sl())&&(e.templateRef=n.first)},inputs:{backdropClass:"backdropClass",xPosition:"xPosition",yPosition:"yPosition",overlapTrigger:"overlapTrigger",hasBackdrop:"hasBackdrop",panelClass:["class","panelClass"],classList:"classList",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],ariaDescribedby:["aria-describedby","ariaDescribedby"]},outputs:{closed:"closed",close:"close"}}),t}(),I0=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(j0);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,features:[ws]});var e=zn(t);return t}(),D0=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){return Object(m.a)(this,n),e.call(this,t,i,r)}return n}(I0);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(jl),da(P0))},t.\u0275cmp=Ht({type:t,selectors:[["mat-menu"]],exportAs:["matMenu"],features:[Ns([{provide:M0,useExisting:I0},{provide:I0,useExisting:t}]),ws],ngContentSelectors:C0,decls:1,vars:0,consts:[["tabindex","-1","role","menu",1,"mat-menu-panel",3,"id","ngClass","keydown","click"],[1,"mat-menu-content"]],template:function(t,e){1&t&&(Ia(),ua(0,S0,3,6,"ng-template"))},directives:[Oh],styles:['.mat-menu-panel{min-width:112px;max-width:280px;overflow:auto;-webkit-overflow-scrolling:touch;max-height:calc(100vh - 48px);border-radius:4px;outline:0;min-height:64px}.mat-menu-panel.ng-animating{pointer-events:none}.cdk-high-contrast-active .mat-menu-panel{outline:solid 1px}.mat-menu-content:not(:empty){padding-top:8px;padding-bottom:8px}.mat-menu-item{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;position:relative}.mat-menu-item::-moz-focus-inner{border:0}.mat-menu-item[disabled]{cursor:default}[dir=rtl] .mat-menu-item{text-align:right}.mat-menu-item .mat-icon{margin-right:16px;vertical-align:middle}.mat-menu-item .mat-icon svg{vertical-align:top}[dir=rtl] .mat-menu-item .mat-icon{margin-left:16px;margin-right:0}.mat-menu-item[disabled]{pointer-events:none}.cdk-high-contrast-active .mat-menu-item.cdk-program-focused,.cdk-high-contrast-active .mat-menu-item.cdk-keyboard-focused,.cdk-high-contrast-active .mat-menu-item-highlighted{outline:dotted 1px}.mat-menu-item-submenu-trigger{padding-right:32px}.mat-menu-item-submenu-trigger::after{width:0;height:0;border-style:solid;border-width:5px 0 5px 5px;border-color:transparent transparent transparent currentColor;content:"";display:inline-block;position:absolute;top:50%;right:16px;transform:translateY(-50%)}[dir=rtl] .mat-menu-item-submenu-trigger{padding-right:16px;padding-left:32px}[dir=rtl] .mat-menu-item-submenu-trigger::after{right:auto;left:16px;transform:rotateY(180deg) translateY(-50%)}button.mat-menu-item{width:100%}.mat-menu-item .mat-menu-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}\n'],encapsulation:2,data:{animation:[x0.transformMenu,x0.fadeInItems]},changeDetection:0}),t}(),R0=new ht("mat-menu-scroll-strategy"),L0={provide:R0,deps:[m0],useFactory:function(t){return function(){return t.scrollStrategies.reposition()}}},F0=Mm({passive:!0}),N0=function(){var t=function(){function t(e,n,i,r,o,a,s,c){var l=this;Object(m.a)(this,t),this._overlay=e,this._element=n,this._viewContainerRef=i,this._parentMenu=o,this._menuItemInstance=a,this._dir=s,this._focusMonitor=c,this._overlayRef=null,this._menuOpen=!1,this._closingActionsSubscription=_.a.EMPTY,this._hoverSubscription=_.a.EMPTY,this._menuCloseSubscription=_.a.EMPTY,this._handleTouchStart=function(){return l._openedBy="touch"},this._openedBy=null,this.restoreFocus=!0,this.menuOpened=new Uc,this.onMenuOpen=this.menuOpened,this.menuClosed=new Uc,this.onMenuClose=this.menuClosed,n.nativeElement.addEventListener("touchstart",this._handleTouchStart,F0),a&&(a._triggersSubmenu=this.triggersSubmenu()),this._scrollStrategy=r}return Object(g.a)(t,[{key:"ngAfterContentInit",value:function(){this._checkMenu(),this._handleHover()}},{key:"ngOnDestroy",value:function(){this._overlayRef&&(this._overlayRef.dispose(),this._overlayRef=null),this._element.nativeElement.removeEventListener("touchstart",this._handleTouchStart,F0),this._menuCloseSubscription.unsubscribe(),this._closingActionsSubscription.unsubscribe(),this._hoverSubscription.unsubscribe()}},{key:"triggersSubmenu",value:function(){return!(!this._menuItemInstance||!this._parentMenu)}},{key:"toggleMenu",value:function(){return this._menuOpen?this.closeMenu():this.openMenu()}},{key:"openMenu",value:function(){var t=this;if(!this._menuOpen){this._checkMenu();var e=this._createOverlay(),n=e.getConfig();this._setPosition(n.positionStrategy),n.hasBackdrop=null==this.menu.hasBackdrop?!this.triggersSubmenu():this.menu.hasBackdrop,e.attach(this._getPortal()),this.menu.lazyContent&&this.menu.lazyContent.attach(this.menuData),this._closingActionsSubscription=this._menuClosingActions().subscribe((function(){return t.closeMenu()})),this._initMenu(),this.menu instanceof I0&&this.menu._startAnimation()}}},{key:"closeMenu",value:function(){this.menu.close.emit()}},{key:"focus",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"program",e=arguments.length>1?arguments[1]:void 0;this._focusMonitor?this._focusMonitor.focusVia(this._element,t,e):this._element.nativeElement.focus(e)}},{key:"_destroyMenu",value:function(){var t=this;if(this._overlayRef&&this.menuOpen){var e=this.menu;this._closingActionsSubscription.unsubscribe(),this._overlayRef.detach(),this._restoreFocus(),e instanceof I0?(e._resetAnimation(),e.lazyContent?e._animationDone.pipe(Object(vg.a)((function(t){return"void"===t.toState})),Object(FX.a)(1),Object(Am.a)(e.lazyContent._attached)).subscribe({next:function(){return e.lazyContent.detach()},complete:function(){return t._setIsMenuOpen(!1)}}):this._setIsMenuOpen(!1)):(this._setIsMenuOpen(!1),e.lazyContent&&e.lazyContent.detach())}}},{key:"_initMenu",value:function(){this.menu.parentMenu=this.triggersSubmenu()?this._parentMenu:void 0,this.menu.direction=this.dir,this._setMenuElevation(),this._setIsMenuOpen(!0),this.menu.focusFirstItem(this._openedBy||"program")}},{key:"_setMenuElevation",value:function(){if(this.menu.setElevation){for(var t=0,e=this.menu.parentMenu;e;)t++,e=e.parentMenu;this.menu.setElevation(t)}}},{key:"_restoreFocus",value:function(){this.restoreFocus&&(this._openedBy?this.triggersSubmenu()||this.focus(this._openedBy):this.focus()),this._openedBy=null}},{key:"_setIsMenuOpen",value:function(t){this._menuOpen=t,this._menuOpen?this.menuOpened.emit():this.menuClosed.emit(),this.triggersSubmenu()&&(this._menuItemInstance._highlighted=t)}},{key:"_checkMenu",value:function(){this.menu||function(){throw Error('matMenuTriggerFor: must pass in an mat-menu instance.\n\n Example:\n <mat-menu #menu="matMenu"></mat-menu>\n <button [matMenuTriggerFor]="menu"></button>')}()}},{key:"_createOverlay",value:function(){if(!this._overlayRef){var t=this._getOverlayConfig();this._subscribeToPositions(t.positionStrategy),this._overlayRef=this._overlay.create(t),this._overlayRef.keydownEvents().subscribe()}return this._overlayRef}},{key:"_getOverlayConfig",value:function(){return new $J({positionStrategy:this._overlay.position().flexibleConnectedTo(this._element).withLockedPosition().withTransformOriginOn(".mat-menu-panel, .mat-mdc-menu-panel"),backdropClass:this.menu.backdropClass||"cdk-overlay-transparent-backdrop",scrollStrategy:this._scrollStrategy(),direction:this._dir})}},{key:"_subscribeToPositions",value:function(t){var e=this;this.menu.setPositionClasses&&t.positionChanges.subscribe((function(t){e.menu.setPositionClasses("start"===t.connectionPair.overlayX?"after":"before","top"===t.connectionPair.overlayY?"below":"above")}))}},{key:"_setPosition",value:function(t){var e=l("before"===this.menu.xPosition?["end","start"]:["start","end"],2),n=e[0],i=e[1],r=l("above"===this.menu.yPosition?["bottom","top"]:["top","bottom"],2),o=r[0],a=r[1],s=o,c=a,u=n,h=i,d=0;this.triggersSubmenu()?(h=n="before"===this.menu.xPosition?"start":"end",i=u="end"===n?"start":"end",d="bottom"===o?8:-8):this.menu.overlapTrigger||(s="top"===o?"bottom":"top",c="top"===a?"bottom":"top"),t.withPositions([{originX:n,originY:s,overlayX:u,overlayY:o,offsetY:d},{originX:i,originY:s,overlayX:h,overlayY:o,offsetY:d},{originX:n,originY:c,overlayX:u,overlayY:a,offsetY:-d},{originX:i,originY:c,overlayX:h,overlayY:a,offsetY:-d}])}},{key:"_menuClosingActions",value:function(){var t=this,e=this._overlayRef.backdropClick(),n=this._overlayRef.detachments(),i=this._parentMenu?this._parentMenu.closed:Object(lm.a)(),r=this._parentMenu?this._parentMenu._hovered().pipe(Object(vg.a)((function(e){return e!==t._menuItemInstance})),Object(vg.a)((function(){return t._menuOpen}))):Object(lm.a)();return Object(C.a)(e,i,r,n)}},{key:"_handleMousedown",value:function(t){w$(t)||(this._openedBy=0===t.button?"mouse":null,this.triggersSubmenu()&&t.preventDefault())}},{key:"_handleKeydown",value:function(t){var e=t.keyCode;this.triggersSubmenu()&&(39===e&&"ltr"===this.dir||37===e&&"rtl"===this.dir)&&this.openMenu()}},{key:"_handleClick",value:function(t){this.triggersSubmenu()?(t.stopPropagation(),this.openMenu()):this.toggleMenu()}},{key:"_handleHover",value:function(){var t=this;this.triggersSubmenu()&&(this._hoverSubscription=this._parentMenu._hovered().pipe(Object(vg.a)((function(e){return e===t._menuItemInstance&&!e.disabled})),Object(P$.a)(0,E$.a)).subscribe((function(){t._openedBy="mouse",t.menu instanceof I0&&t.menu._isAnimating?t.menu._animationDone.pipe(Object(FX.a)(1),Object(P$.a)(0,E$.a),Object(Am.a)(t._parentMenu._hovered())).subscribe((function(){return t.openMenu()})):t.openMenu()})))}},{key:"_getPortal",value:function(){return this._portal&&this._portal.templateRef===this.menu.templateRef||(this._portal=new D$(this.menu.templateRef,this._viewContainerRef)),this._portal}},{key:"_deprecatedMatMenuTriggerFor",get:function(){return this.menu},set:function(t){this.menu=t}},{key:"menu",get:function(){return this._menu},set:function(t){var e=this;t!==this._menu&&(this._menu=t,this._menuCloseSubscription.unsubscribe(),t&&(this._menuCloseSubscription=t.close.asObservable().subscribe((function(t){e._destroyMenu(),"click"!==t&&"tab"!==t||!e._parentMenu||e._parentMenu.closed.emit(t)}))))}},{key:"menuOpen",get:function(){return this._menuOpen}},{key:"dir",get:function(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(m0),da(Us),da(mc),da(R0),da(I0,8),da(E0,10),da(gm,8),da(S$))},t.\u0275dir=Wt({type:t,selectors:[["","mat-menu-trigger-for",""],["","matMenuTriggerFor",""]],hostAttrs:["aria-haspopup","true",1,"mat-menu-trigger"],hostVars:2,hostBindings:function(t,e){1&t&&xa("mousedown",(function(t){return e._handleMousedown(t)}))("keydown",(function(t){return e._handleKeydown(t)}))("click",(function(t){return e._handleClick(t)})),2&t&&oa("aria-expanded",e.menuOpen||null)("aria-controls",e.menuOpen?e.menu.panelId:null)},inputs:{restoreFocus:["matMenuTriggerRestoreFocus","restoreFocus"],_deprecatedMatMenuTriggerFor:["mat-menu-trigger-for","_deprecatedMatMenuTriggerFor"],menu:["matMenuTriggerFor","menu"],menuData:["matMenuTriggerData","menuData"]},outputs:{menuOpened:"menuOpened",onMenuOpen:"onMenuOpen",menuClosed:"menuClosed",onMenuClose:"onMenuClose"},exportAs:["matMenuTrigger"]}),t}(),B0=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[L0],imports:[$$]}),t}(),H0=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[L0],imports:[[hd,$$,_J,w0,B0],VJ,$$,B0]}),t}(),z0=function(){return function(){}}(),V0=function(){return function(){}}(),U0=function(){function t(){}return t.prototype.getInfoAboutNode=function(t,e){var n=[];return"cloud"===t.node_type?n.push("Cloud "+t.name+" is always on."):"nat"===t.node_type?n.push("NAT "+t.name+" is always on."):"ethernet-hub"===t.node_type?n.push("Ethernet hub "+t.name+" is always on."):"ethernet_switch"===t.node_type?n.push("Ethernet switch "+t.name+" is always on."):"frame_relay_switch"===t.node_type?n.push("Frame relay switch "+t.name+" is always on."):"atm_switch"===t.node_type?n.push("ATM switch "+t.name+" is always on."):"docker"===t.node_type?n.push("Docker "+t.name+" is "+t.status+"."):"dynamips"===t.node_type?n.push("Dynamips "+t.name+" is always on."):"traceng"===t.node_type?n.push("TraceNG "+t.name+" is always on."):"virtualbox"===t.node_type?n.push("VirtualBox VM "+t.name+" is "+t.status+"."):"vmware"===t.node_type?n.push("VMware VM "+t.name+" is "+t.status+"."):"qemu"===t.node_type?n.push("QEMU VM "+t.name+" is "+t.status+"."):"iou"===t.node_type?n.push("IOU "+t.name+" is always on."):"vpcs"===t.node_type&&n.push("Node "+t.name+" is "+t.status+"."),n.push("Running on server "+e.name+" with port "+e.port+"."),n.push("Server ID is "+e.id+"."),"none"!==t.console_type&&"null"!==t.console_type&&n.push("Console is on port "+t.console+" and type is "+t.console_type+"."),n.concat(this.getInfoAboutPorts(t.ports))},t.prototype.getInfoAboutPorts=function(t){var e="Ports: ";return t.forEach((function(t){e+="link_type: "+t.link_type+", \n name: "+t.name+"; "})),e=e.substring(0,e.length-2)},t.prototype.getCommandLine=function(t){return"cloud"===t.node_type||"nat"===t.node_type||"ethernet_hub"===t.node_type||"ethernet_switch"===t.node_type||"frame_relay_switch"===t.node_type||"atm_switch"===t.node_type||"dynamips"===t.node_type||"traceng"===t.node_type||"iou"===t.node_type?"Command line information is not supported for this type of node.":t.command_line?t.command_line:"Please start the node in order to get the command line information."},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function q0(t,e){}var G0=function t(){Object(m.a)(this,t),this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.maxWidth="80vw",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.autoFocus=!0,this.restoreFocus=!0,this.closeOnNavigation=!0},W0={dialogContainer:Jg("dialogContainer",[rv("void, exit",iv({opacity:0,transform:"scale(0.7)"})),rv("enter",iv({transform:"none"})),av("* => enter",tv("150ms cubic-bezier(0, 0, 0.2, 1)",iv({transform:"none",opacity:1}))),av("* => void, * => exit",tv("75ms cubic-bezier(0.4, 0.0, 0.2, 1)",iv({opacity:0})))])};function K0(){throw Error("Attempting to attach dialog content after content is already attached")}var X0=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){var s;return Object(m.a)(this,n),(s=e.call(this))._elementRef=t,s._focusTrapFactory=i,s._changeDetectorRef=r,s._config=a,s._elementFocusedBeforeDialogWasOpened=null,s._state="enter",s._animationStateChanged=new Uc,s.attachDomPortal=function(t){return s._portalOutlet.hasAttached()&&K0(),s._setupFocusTrap(),s._portalOutlet.attachDomPortal(t)},s._ariaLabelledBy=a.ariaLabelledBy||null,s._document=o,s}return Object(g.a)(n,[{key:"attachComponentPortal",value:function(t){return this._portalOutlet.hasAttached()&&K0(),this._setupFocusTrap(),this._portalOutlet.attachComponentPortal(t)}},{key:"attachTemplatePortal",value:function(t){return this._portalOutlet.hasAttached()&&K0(),this._setupFocusTrap(),this._portalOutlet.attachTemplatePortal(t)}},{key:"_recaptureFocus",value:function(){this._containsFocus()||(!this._config.autoFocus||!this._focusTrap.focusInitialElement())&&this._elementRef.nativeElement.focus()}},{key:"_trapFocus",value:function(){this._config.autoFocus?this._focusTrap.focusInitialElementWhenReady():this._containsFocus()||this._elementRef.nativeElement.focus()}},{key:"_restoreFocus",value:function(){var t=this._elementFocusedBeforeDialogWasOpened;if(this._config.restoreFocus&&t&&"function"==typeof t.focus){var e=this._document.activeElement,n=this._elementRef.nativeElement;e&&e!==this._document.body&&e!==n&&!n.contains(e)||t.focus()}this._focusTrap&&this._focusTrap.destroy()}},{key:"_setupFocusTrap",value:function(){var t=this;this._focusTrap||(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement)),this._document&&(this._elementFocusedBeforeDialogWasOpened=this._document.activeElement,this._elementRef.nativeElement.focus&&Promise.resolve().then((function(){return t._elementRef.nativeElement.focus()})))}},{key:"_containsFocus",value:function(){var t=this._elementRef.nativeElement,e=this._document.activeElement;return t===e||t.contains(e)}},{key:"_onAnimationDone",value:function(t){"enter"===t.toState?this._trapFocus():"exit"===t.toState&&this._restoreFocus(),this._animationStateChanged.emit(t)}},{key:"_onAnimationStart",value:function(t){this._animationStateChanged.emit(t)}},{key:"_startExitAnimation",value:function(){this._state="exit",this._changeDetectorRef.markForCheck()}}]),n}(L$);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(v$),da(Po),da(du,8),da(G0))},t.\u0275cmp=Ht({type:t,selectors:[["mat-dialog-container"]],viewQuery:function(t,e){var n;1&t&&el(B$,!0),2&t&&tl(n=sl())&&(e._portalOutlet=n.first)},hostAttrs:["tabindex","-1","aria-modal","true",1,"mat-dialog-container"],hostVars:6,hostBindings:function(t,e){1&t&&Oa("@dialogContainer.start",(function(t){return e._onAnimationStart(t)}))("@dialogContainer.done",(function(t){return e._onAnimationDone(t)})),2&t&&(oa("id",e._id)("role",e._config.role)("aria-labelledby",e._config.ariaLabel?null:e._ariaLabelledBy)("aria-label",e._config.ariaLabel)("aria-describedby",e._config.ariaDescribedBy||null),ys("@dialogContainer",e._state))},features:[ws],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,e){1&t&&ua(0,q0,0,0,"ng-template",0)},directives:[B$],styles:[".mat-dialog-container{display:block;padding:24px;border-radius:4px;box-sizing:border-box;overflow:auto;outline:0;width:100%;height:100%;min-height:inherit;max-height:inherit}.cdk-high-contrast-active .mat-dialog-container{outline:solid 1px}.mat-dialog-content{display:block;margin:0 -24px;padding:0 24px;max-height:65vh;overflow:auto;-webkit-overflow-scrolling:touch}.mat-dialog-title{margin:0 0 20px;display:block}.mat-dialog-actions{padding:8px 0;display:flex;flex-wrap:wrap;min-height:52px;align-items:center;margin-bottom:-24px}.mat-dialog-actions[align=end]{justify-content:flex-end}.mat-dialog-actions[align=center]{justify-content:center}.mat-dialog-actions .mat-button-base+.mat-button-base,.mat-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}\n"],encapsulation:2,data:{animation:[W0.dialogContainer]}}),t}(),Y0=0,Z0=function(){function t(e,n){var i=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"mat-dialog-".concat(Y0++);Object(m.a)(this,t),this._overlayRef=e,this._containerInstance=n,this.id=r,this.disableClose=this._containerInstance._config.disableClose,this._afterOpened=new w.b,this._afterClosed=new w.b,this._beforeClosed=new w.b,this._state=0,n._id=r,n._animationStateChanged.pipe(Object(vg.a)((function(t){return"done"===t.phaseName&&"enter"===t.toState})),Object(FX.a)(1)).subscribe((function(){i._afterOpened.next(),i._afterOpened.complete()})),n._animationStateChanged.pipe(Object(vg.a)((function(t){return"done"===t.phaseName&&"exit"===t.toState})),Object(FX.a)(1)).subscribe((function(){clearTimeout(i._closeFallbackTimeout),i._finishDialogClose()})),e.detachments().subscribe((function(){i._beforeClosed.next(i._result),i._beforeClosed.complete(),i._afterClosed.next(i._result),i._afterClosed.complete(),i.componentInstance=null,i._overlayRef.dispose()})),e.keydownEvents().pipe(Object(vg.a)((function(t){return 27===t.keyCode&&!i.disableClose&&!JQ(t)}))).subscribe((function(t){t.preventDefault(),i.close()})),e.backdropClick().subscribe((function(){i.disableClose?i._containerInstance._recaptureFocus():i.close()}))}return Object(g.a)(t,[{key:"close",value:function(t){var e=this;this._result=t,this._containerInstance._animationStateChanged.pipe(Object(vg.a)((function(t){return"start"===t.phaseName})),Object(FX.a)(1)).subscribe((function(n){e._beforeClosed.next(t),e._beforeClosed.complete(),e._overlayRef.detachBackdrop(),e._closeFallbackTimeout=setTimeout((function(){return e._finishDialogClose()}),n.totalTime+100)})),this._containerInstance._startExitAnimation(),this._state=1}},{key:"afterOpened",value:function(){return this._afterOpened.asObservable()}},{key:"afterClosed",value:function(){return this._afterClosed.asObservable()}},{key:"beforeClosed",value:function(){return this._beforeClosed.asObservable()}},{key:"backdropClick",value:function(){return this._overlayRef.backdropClick()}},{key:"keydownEvents",value:function(){return this._overlayRef.keydownEvents()}},{key:"updatePosition",value:function(t){var e=this._getPositionStrategy();return t&&(t.left||t.right)?t.left?e.left(t.left):e.right(t.right):e.centerHorizontally(),t&&(t.top||t.bottom)?t.top?e.top(t.top):e.bottom(t.bottom):e.centerVertically(),this._overlayRef.updatePosition(),this}},{key:"updateSize",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return this._getPositionStrategy().width(t).height(e),this._overlayRef.updatePosition(),this}},{key:"addPanelClass",value:function(t){return this._overlayRef.addPanelClass(t),this}},{key:"removePanelClass",value:function(t){return this._overlayRef.removePanelClass(t),this}},{key:"getState",value:function(){return this._state}},{key:"_finishDialogClose",value:function(){this._state=2,this._overlayRef.dispose()}},{key:"_getPositionStrategy",value:function(){return this._overlayRef.getConfig().positionStrategy}}]),t}(),Q0=new ht("MatDialogData"),$0=new ht("mat-dialog-default-options"),J0=new ht("mat-dialog-scroll-strategy"),t1={provide:J0,deps:[m0],useFactory:function(t){return function(){return t.scrollStrategies.block()}}},e1=function(){var t=function(){function t(e,n,i,r,o,a,s){var c=this;Object(m.a)(this,t),this._overlay=e,this._injector=n,this._defaultOptions=r,this._parentDialog=a,this._overlayContainer=s,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new w.b,this._afterOpenedAtThisLevel=new w.b,this._ariaHiddenElements=new Map,this.afterAllClosed=Object(MX.a)((function(){return c.openDialogs.length?c._afterAllClosed:c._afterAllClosed.pipe(Object(NX.a)(void 0))})),this._scrollStrategy=o}return Object(g.a)(t,[{key:"open",value:function(t,e){var n=this;if((e=function(t,e){return Object.assign(Object.assign({},e),t)}(e,this._defaultOptions||new G0)).id&&this.getDialogById(e.id))throw Error('Dialog with id "'.concat(e.id,'" exists already. The dialog id must be unique.'));var i=this._createOverlay(e),r=this._attachDialogContainer(i,e),o=this._attachDialogContent(t,r,i,e);return this.openDialogs.length||this._hideNonDialogContentFromAssistiveTechnology(),this.openDialogs.push(o),o.afterClosed().subscribe((function(){return n._removeOpenDialog(o)})),this.afterOpened.next(o),o}},{key:"closeAll",value:function(){this._closeDialogs(this.openDialogs)}},{key:"getDialogById",value:function(t){return this.openDialogs.find((function(e){return e.id===t}))}},{key:"ngOnDestroy",value:function(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}},{key:"_createOverlay",value:function(t){var e=this._getOverlayConfig(t);return this._overlay.create(e)}},{key:"_getOverlayConfig",value:function(t){var e=new $J({positionStrategy:this._overlay.position().global(),scrollStrategy:t.scrollStrategy||this._scrollStrategy(),panelClass:t.panelClass,hasBackdrop:t.hasBackdrop,direction:t.direction,minWidth:t.minWidth,minHeight:t.minHeight,maxWidth:t.maxWidth,maxHeight:t.maxHeight,disposeOnNavigation:t.closeOnNavigation});return t.backdropClass&&(e.backdropClass=t.backdropClass),e}},{key:"_attachDialogContainer",value:function(t,e){var n=Xo.create({parent:e&&e.viewContainerRef&&e.viewContainerRef.injector||this._injector,providers:[{provide:G0,useValue:e}]}),i=new I$(X0,e.viewContainerRef,n,e.componentFactoryResolver);return t.attach(i).instance}},{key:"_attachDialogContent",value:function(t,e,n,i){var r=new Z0(n,e,i.id);if(t instanceof fc)e.attachTemplatePortal(new D$(t,null,{$implicit:i.data,dialogRef:r}));else{var o=this._createInjector(i,r,e),a=e.attachComponentPortal(new I$(t,i.viewContainerRef,o));r.componentInstance=a.instance}return r.updateSize(i.width,i.height).updatePosition(i.position),r}},{key:"_createInjector",value:function(t,e,n){var i=t&&t.viewContainerRef&&t.viewContainerRef.injector,r=[{provide:X0,useValue:n},{provide:Q0,useValue:t.data},{provide:Z0,useValue:e}];return!t.direction||i&&i.get(gm,null)||r.push({provide:gm,useValue:{value:t.direction,change:Object(lm.a)()}}),Xo.create({parent:i||this._injector,providers:r})}},{key:"_removeOpenDialog",value:function(t){var e=this.openDialogs.indexOf(t);e>-1&&(this.openDialogs.splice(e,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((function(t,e){t?e.setAttribute("aria-hidden",t):e.removeAttribute("aria-hidden")})),this._ariaHiddenElements.clear(),this._afterAllClosed.next()))}},{key:"_hideNonDialogContentFromAssistiveTechnology",value:function(){var t=this._overlayContainer.getContainerElement();if(t.parentElement)for(var e=t.parentElement.children,n=e.length-1;n>-1;n--){var i=e[n];i===t||"SCRIPT"===i.nodeName||"STYLE"===i.nodeName||i.hasAttribute("aria-live")||(this._ariaHiddenElements.set(i,i.getAttribute("aria-hidden")),i.setAttribute("aria-hidden","true"))}}},{key:"_closeDialogs",value:function(t){for(var e=t.length;e--;)t[e].close()}},{key:"openDialogs",get:function(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}},{key:"afterOpened",get:function(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}},{key:"_afterAllClosed",get:function(){var t=this._parentDialog;return t?t._afterAllClosed:this._afterAllClosedAtThisLevel}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(m0),_t(Xo),_t(Mu,8),_t($0,8),_t(J0),_t(t,12),_t(o0))},t.\u0275prov=R({token:t,factory:function(e){return t.\u0275fac(e)}}),t}(),n1=0,i1=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this.dialogRef=e,this._elementRef=n,this._dialog=i,this.type="button"}return Object(g.a)(t,[{key:"ngOnInit",value:function(){this.dialogRef||(this.dialogRef=s1(this._elementRef,this._dialog.openDialogs))}},{key:"ngOnChanges",value:function(t){var e=t._matDialogClose||t._matDialogCloseResult;e&&(this.dialogResult=e.currentValue)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Z0,8),da(Us),da(e1))},t.\u0275dir=Wt({type:t,selectors:[["","mat-dialog-close",""],["","matDialogClose",""]],hostVars:2,hostBindings:function(t,e){1&t&&xa("click",(function(){return e.dialogRef.close(e.dialogResult)})),2&t&&oa("aria-label",e.ariaLabel||null)("type",e.type)},inputs:{type:"type",dialogResult:["mat-dialog-close","dialogResult"],ariaLabel:["aria-label","ariaLabel"],_matDialogClose:["matDialogClose","_matDialogClose"]},exportAs:["matDialogClose"],features:[Ms]}),t}(),r1=function(){var t=function(){function t(e,n,i){Object(m.a)(this,t),this._dialogRef=e,this._elementRef=n,this._dialog=i,this.id="mat-dialog-title-".concat(n1++)}return Object(g.a)(t,[{key:"ngOnInit",value:function(){var t=this;this._dialogRef||(this._dialogRef=s1(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then((function(){var e=t._dialogRef._containerInstance;e&&!e._ariaLabelledBy&&(e._ariaLabelledBy=t.id)}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Z0,8),da(Us),da(e1))},t.\u0275dir=Wt({type:t,selectors:[["","mat-dialog-title",""],["","matDialogTitle",""]],hostAttrs:[1,"mat-dialog-title"],hostVars:1,hostBindings:function(t,e){2&t&&bs("id",e.id)},inputs:{id:"id"},exportAs:["matDialogTitle"]}),t}(),o1=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-dialog-content"]}),t}(),a1=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-dialog-actions",""],["mat-dialog-actions"],["","matDialogActions",""]],hostAttrs:[1,"mat-dialog-actions"]}),t}();function s1(t,e){for(var n=t.nativeElement.parentElement;n&&!n.classList.contains("mat-dialog-container");)n=n.parentElement;return n?e.find((function(t){return t.id===n.id})):null}var c1=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[e1,t1],imports:[[w0,z$,$$],$$]}),t}(),l1=n("PqYM");function u1(t,e){1&t&&Da(0)}var h1=["*"];function d1(t,e){}var f1=function(t){return{animationDuration:t}},p1=function(t,e){return{value:t,params:e}},m1=["tabBodyWrapper"],g1=["tabHeader"];function v1(t,e){}function b1(t,e){1&t&&ua(0,v1,0,0,"ng-template",9),2&t&&pa("cdkPortalOutlet",Aa().$implicit.templateLabel)}function y1(t,e){1&t&&ds(0),2&t&&fs(Aa().$implicit.textLabel)}function _1(t,e){if(1&t){var n=ka();ga(0,"div",6),xa("click",(function(){Se(n);var t=e.$implicit,i=e.index,r=Aa(),o=ha(1);return r._handleClick(t,o,i)})),ga(1,"div",7),ua(2,b1,1,1,"ng-template",8),ua(3,y1,1,1,"ng-template",8),va(),va()}if(2&t){var i=e.$implicit,r=e.index,o=Aa();Qa("mat-tab-label-active",o.selectedIndex==r),pa("id",o._getTabLabelId(r))("disabled",i.disabled)("matRippleDisabled",i.disabled||o.disableRipple),oa("tabIndex",o._getTabIndex(i,r))("aria-posinset",r+1)("aria-setsize",o._tabs.length)("aria-controls",o._getTabContentId(r))("aria-selected",o.selectedIndex==r)("aria-label",i.ariaLabel||null)("aria-labelledby",!i.ariaLabel&&i.ariaLabelledby?i.ariaLabelledby:null),Qi(2),pa("ngIf",i.templateLabel),Qi(1),pa("ngIf",!i.templateLabel)}}function w1(t,e){if(1&t){var n=ka();ga(0,"mat-tab-body",10),xa("_onCentered",(function(){return Se(n),Aa()._removeTabBodyWrapperHeight()}))("_onCentering",(function(t){return Se(n),Aa()._setTabBodyWrapperHeight(t)})),va()}if(2&t){var i=e.$implicit,r=e.index,o=Aa();Qa("mat-tab-body-active",o.selectedIndex==r),pa("id",o._getTabContentId(r))("content",i.content)("position",i.position)("origin",i.origin)("animationDuration",o.animationDuration),oa("aria-labelledby",o._getTabLabelId(r))}}var k1=["tabListContainer"],C1=["tabList"],S1=["nextPaginator"],x1=["previousPaginator"],O1=["mat-tab-nav-bar",""],M1=new ht("MatInkBarPositioner",{providedIn:"root",factory:function(){return function(t){return{left:t?(t.offsetLeft||0)+"px":"0",width:t?(t.offsetWidth||0)+"px":"0"}}}}),T1=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._elementRef=e,this._ngZone=n,this._inkBarPositioner=i,this._animationMode=r}return Object(g.a)(t,[{key:"alignToElement",value:function(t){var e=this;this.show(),"undefined"!=typeof requestAnimationFrame?this._ngZone.runOutsideAngular((function(){requestAnimationFrame((function(){return e._setStyles(t)}))})):this._setStyles(t)}},{key:"show",value:function(){this._elementRef.nativeElement.style.visibility="visible"}},{key:"hide",value:function(){this._elementRef.nativeElement.style.visibility="hidden"}},{key:"_setStyles",value:function(t){var e=this._inkBarPositioner(t),n=this._elementRef.nativeElement;n.style.left=e.left,n.style.width=e.width}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(jl),da(M1),da(Cy,8))},t.\u0275dir=Wt({type:t,selectors:[["mat-ink-bar"]],hostAttrs:[1,"mat-ink-bar"],hostVars:2,hostBindings:function(t,e){2&t&&Qa("_mat-animation-noopable","NoopAnimations"===e._animationMode)}}),t}(),E1=function(){var t=function t(e){Object(m.a)(this,t),this.template=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["","matTabContent",""]]}),t}(),P1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(N$);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-tab-label",""],["","matTabLabel",""]],features:[ws]});var e=zn(t);return t}(),A1=J$((function t(){Object(m.a)(this,t)})),j1=new ht("MAT_TAB_GROUP"),I1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),(r=e.call(this))._viewContainerRef=t,r._closestTabGroup=i,r.textLabel="",r._contentPortal=null,r._stateChanges=new w.b,r.position=null,r.origin=null,r.isActive=!1,r}return Object(g.a)(n,[{key:"ngOnChanges",value:function(t){(t.hasOwnProperty("textLabel")||t.hasOwnProperty("disabled"))&&this._stateChanges.next()}},{key:"ngOnDestroy",value:function(){this._stateChanges.complete()}},{key:"ngOnInit",value:function(){this._contentPortal=new D$(this._explicitContent||this._implicitContent,this._viewContainerRef)}},{key:"templateLabel",get:function(){return this._templateLabel},set:function(t){t&&(this._templateLabel=t)}},{key:"content",get:function(){return this._contentPortal}}]),n}(A1);return t.\u0275fac=function(e){return new(e||t)(da(mc),da(j1,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-tab"]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,P1,!0),ol(n,E1,!0,fc)),2&t&&(tl(i=sl())&&(e.templateLabel=i.first),tl(i=sl())&&(e._explicitContent=i.first))},viewQuery:function(t,e){var n;1&t&&el(fc,!0),2&t&&tl(n=sl())&&(e._implicitContent=n.first)},inputs:{disabled:"disabled",textLabel:["label","textLabel"],ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"]},exportAs:["matTab"],features:[ws,Ms],ngContentSelectors:h1,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),ua(0,u1,1,0,"ng-template"))},encapsulation:2}),t}(),D1={translateTab:Jg("translateTab",[rv("center, void, left-origin-center, right-origin-center",iv({transform:"none"})),rv("left",iv({transform:"translate3d(-100%, 0, 0)",minHeight:"1px"})),rv("right",iv({transform:"translate3d(100%, 0, 0)",minHeight:"1px"})),av("* => left, * => right, left => center, right => center",tv("{{animationDuration}} cubic-bezier(0.35, 0, 0.25, 1)")),av("void => left-origin-center",[iv({transform:"translate3d(-100%, 0, 0)"}),tv("{{animationDuration}} cubic-bezier(0.35, 0, 0.25, 1)")]),av("void => right-origin-center",[iv({transform:"translate3d(100%, 0, 0)"}),tv("{{animationDuration}} cubic-bezier(0.35, 0, 0.25, 1)")])])},R1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,t,i,o))._host=r,a._centeringSub=_.a.EMPTY,a._leavingSub=_.a.EMPTY,a}return Object(g.a)(n,[{key:"ngOnInit",value:function(){var t=this;Object(o.a)(Object(a.a)(n.prototype),"ngOnInit",this).call(this),this._centeringSub=this._host._beforeCentering.pipe(Object(NX.a)(this._host._isCenterPosition(this._host._position))).subscribe((function(e){e&&!t.hasAttached()&&t.attach(t._host._content)})),this._leavingSub=this._host._afterLeavingCenter.subscribe((function(){t.detach()}))}},{key:"ngOnDestroy",value:function(){Object(o.a)(Object(a.a)(n.prototype),"ngOnDestroy",this).call(this),this._centeringSub.unsubscribe(),this._leavingSub.unsubscribe()}}]),n}(B$);return t.\u0275fac=function(e){return new(e||t)(da(Vs),da(mc),da(Y((function(){return F1}))),da(du))},t.\u0275dir=Wt({type:t,selectors:[["","matTabBodyHost",""]],features:[ws]}),t}(),L1=function(){var t=function(){function t(e,n,i){var r=this;Object(m.a)(this,t),this._elementRef=e,this._dir=n,this._dirChangeSubscription=_.a.EMPTY,this._translateTabComplete=new w.b,this._onCentering=new Uc,this._beforeCentering=new Uc,this._afterLeavingCenter=new Uc,this._onCentered=new Uc(!0),this.animationDuration="500ms",n&&(this._dirChangeSubscription=n.change.subscribe((function(t){r._computePositionAnimationState(t),i.markForCheck()}))),this._translateTabComplete.pipe(Object(RJ.a)((function(t,e){return t.fromState===e.fromState&&t.toState===e.toState}))).subscribe((function(t){r._isCenterPosition(t.toState)&&r._isCenterPosition(r._position)&&r._onCentered.emit(),r._isCenterPosition(t.fromState)&&!r._isCenterPosition(r._position)&&r._afterLeavingCenter.emit()}))}return Object(g.a)(t,[{key:"ngOnInit",value:function(){"center"==this._position&&null!=this.origin&&(this._position=this._computePositionFromOrigin(this.origin))}},{key:"ngOnDestroy",value:function(){this._dirChangeSubscription.unsubscribe(),this._translateTabComplete.complete()}},{key:"_onTranslateTabStarted",value:function(t){var e=this._isCenterPosition(t.toState);this._beforeCentering.emit(e),e&&this._onCentering.emit(this._elementRef.nativeElement.clientHeight)}},{key:"_getLayoutDirection",value:function(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}},{key:"_isCenterPosition",value:function(t){return"center"==t||"left-origin-center"==t||"right-origin-center"==t}},{key:"_computePositionAnimationState",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._getLayoutDirection();this._position=this._positionIndex<0?"ltr"==t?"left":"right":this._positionIndex>0?"ltr"==t?"right":"left":"center"}},{key:"_computePositionFromOrigin",value:function(t){var e=this._getLayoutDirection();return"ltr"==e&&t<=0||"rtl"==e&&t>0?"left-origin-center":"right-origin-center"}},{key:"position",set:function(t){this._positionIndex=t,this._computePositionAnimationState()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(gm,8),da(Po))},t.\u0275dir=Wt({type:t,inputs:{animationDuration:"animationDuration",position:"position",_content:["content","_content"],origin:"origin"},outputs:{_onCentering:"_onCentering",_beforeCentering:"_beforeCentering",_afterLeavingCenter:"_afterLeavingCenter",_onCentered:"_onCentered"}}),t}(),F1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){return Object(m.a)(this,n),e.call(this,t,i,r)}return n}(L1);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(gm,8),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["mat-tab-body"]],viewQuery:function(t,e){var n;1&t&&nl(H$,!0),2&t&&tl(n=sl())&&(e._portalHost=n.first)},hostAttrs:[1,"mat-tab-body"],features:[ws],decls:3,vars:6,consts:[[1,"mat-tab-body-content"],["content",""],["matTabBodyHost",""]],template:function(t,e){1&t&&(ga(0,"div",0,1),xa("@translateTab.start",(function(t){return e._onTranslateTabStarted(t)}))("@translateTab.done",(function(t){return e._translateTabComplete.next(t)})),ua(2,d1,0,0,"ng-template",2),va()),2&t&&pa("@translateTab",Dc(3,p1,e._position,Ic(1,f1,e.animationDuration)))},directives:[R1],styles:[".mat-tab-body-content{height:100%;overflow:auto}.mat-tab-group-dynamic-height .mat-tab-body-content{overflow:hidden}\n"],encapsulation:2,data:{animation:[D1.translateTab]}}),t}(),N1=new ht("MAT_TABS_CONFIG"),B1=0,H1=function t(){Object(m.a)(this,t)},z1=tJ(eJ((function t(e){Object(m.a)(this,t),this._elementRef=e})),"primary"),V1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,t))._changeDetectorRef=i,a._animationMode=o,a._tabs=new Gc,a._indexToSelect=0,a._tabBodyWrapperHeight=0,a._tabsSubscription=_.a.EMPTY,a._tabLabelSubscription=_.a.EMPTY,a._dynamicHeight=!1,a._selectedIndex=null,a.headerPosition="above",a.selectedIndexChange=new Uc,a.focusChange=new Uc,a.animationDone=new Uc,a.selectedTabChange=new Uc(!0),a._groupId=B1++,a.animationDuration=r&&r.animationDuration?r.animationDuration:"500ms",a.disablePagination=!(!r||null==r.disablePagination)&&r.disablePagination,a}return Object(g.a)(n,[{key:"ngAfterContentChecked",value:function(){var t=this,e=this._indexToSelect=this._clampTabIndex(this._indexToSelect);if(this._selectedIndex!=e){var n=null==this._selectedIndex;n||this.selectedTabChange.emit(this._createChangeEvent(e)),Promise.resolve().then((function(){t._tabs.forEach((function(t,n){return t.isActive=n===e})),n||t.selectedIndexChange.emit(e)}))}this._tabs.forEach((function(n,i){n.position=i-e,null==t._selectedIndex||0!=n.position||n.origin||(n.origin=e-t._selectedIndex)})),this._selectedIndex!==e&&(this._selectedIndex=e,this._changeDetectorRef.markForCheck())}},{key:"ngAfterContentInit",value:function(){var t=this;this._subscribeToAllTabChanges(),this._subscribeToTabLabels(),this._tabsSubscription=this._tabs.changes.subscribe((function(){if(t._clampTabIndex(t._indexToSelect)===t._selectedIndex)for(var e=t._tabs.toArray(),n=0;n<e.length;n++)if(e[n].isActive){t._indexToSelect=t._selectedIndex=n;break}t._changeDetectorRef.markForCheck()}))}},{key:"_subscribeToAllTabChanges",value:function(){var t=this;this._allTabs.changes.pipe(Object(NX.a)(this._allTabs)).subscribe((function(e){t._tabs.reset(e.filter((function(e){return!e._closestTabGroup||e._closestTabGroup===t}))),t._tabs.notifyOnChanges()}))}},{key:"ngOnDestroy",value:function(){this._tabs.destroy(),this._tabsSubscription.unsubscribe(),this._tabLabelSubscription.unsubscribe()}},{key:"realignInkBar",value:function(){this._tabHeader&&this._tabHeader._alignInkBarToSelectedTab()}},{key:"_focusChanged",value:function(t){this.focusChange.emit(this._createChangeEvent(t))}},{key:"_createChangeEvent",value:function(t){var e=new H1;return e.index=t,this._tabs&&this._tabs.length&&(e.tab=this._tabs.toArray()[t]),e}},{key:"_subscribeToTabLabels",value:function(){var t=this;this._tabLabelSubscription&&this._tabLabelSubscription.unsubscribe(),this._tabLabelSubscription=C.a.apply(void 0,Object(u.a)(this._tabs.map((function(t){return t._stateChanges})))).subscribe((function(){return t._changeDetectorRef.markForCheck()}))}},{key:"_clampTabIndex",value:function(t){return Math.min(this._tabs.length-1,Math.max(t||0,0))}},{key:"_getTabLabelId",value:function(t){return"mat-tab-label-".concat(this._groupId,"-").concat(t)}},{key:"_getTabContentId",value:function(t){return"mat-tab-content-".concat(this._groupId,"-").concat(t)}},{key:"_setTabBodyWrapperHeight",value:function(t){if(this._dynamicHeight&&this._tabBodyWrapperHeight){var e=this._tabBodyWrapper.nativeElement;e.style.height=this._tabBodyWrapperHeight+"px",this._tabBodyWrapper.nativeElement.offsetHeight&&(e.style.height=t+"px")}}},{key:"_removeTabBodyWrapperHeight",value:function(){var t=this._tabBodyWrapper.nativeElement;this._tabBodyWrapperHeight=t.clientHeight,t.style.height="",this.animationDone.emit()}},{key:"_handleClick",value:function(t,e,n){t.disabled||(this.selectedIndex=e.focusIndex=n)}},{key:"_getTabIndex",value:function(t,e){return t.disabled?null:this.selectedIndex===e?0:-1}},{key:"dynamicHeight",get:function(){return this._dynamicHeight},set:function(t){this._dynamicHeight=nm(t)}},{key:"selectedIndex",get:function(){return this._selectedIndex},set:function(t){this._indexToSelect=im(t,null)}},{key:"animationDuration",get:function(){return this._animationDuration},set:function(t){this._animationDuration=/^\d+$/.test(t)?t+"ms":t}},{key:"backgroundColor",get:function(){return this._backgroundColor},set:function(t){var e=this._elementRef.nativeElement;e.classList.remove("mat-background-".concat(this.backgroundColor)),t&&e.classList.add("mat-background-".concat(t)),this._backgroundColor=t}}]),n}(z1);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(N1,8),da(Cy,8))},t.\u0275dir=Wt({type:t,inputs:{headerPosition:"headerPosition",animationDuration:"animationDuration",disablePagination:"disablePagination",dynamicHeight:"dynamicHeight",selectedIndex:"selectedIndex",backgroundColor:"backgroundColor"},outputs:{selectedIndexChange:"selectedIndexChange",focusChange:"focusChange",animationDone:"animationDone",selectedTabChange:"selectedTabChange"},features:[ws]}),t}(),U1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){return Object(m.a)(this,n),e.call(this,t,i,r,o)}return n}(V1);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(N1,8),da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-tab-group"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,I1,!0),2&t&&tl(i=sl())&&(e._allTabs=i)},viewQuery:function(t,e){var n;1&t&&(nl(m1,!0),nl(g1,!0)),2&t&&(tl(n=sl())&&(e._tabBodyWrapper=n.first),tl(n=sl())&&(e._tabHeader=n.first))},hostAttrs:[1,"mat-tab-group"],hostVars:4,hostBindings:function(t,e){2&t&&Qa("mat-tab-group-dynamic-height",e.dynamicHeight)("mat-tab-group-inverted-header","below"===e.headerPosition)},inputs:{color:"color",disableRipple:"disableRipple"},exportAs:["matTabGroup"],features:[Ns([{provide:j1,useExisting:t}]),ws],decls:6,vars:7,consts:[[3,"selectedIndex","disableRipple","disablePagination","indexFocused","selectFocusedIndex"],["tabHeader",""],["class","mat-tab-label mat-focus-indicator","role","tab","matTabLabelWrapper","","mat-ripple","","cdkMonitorElementFocus","",3,"id","mat-tab-label-active","disabled","matRippleDisabled","click",4,"ngFor","ngForOf"],[1,"mat-tab-body-wrapper"],["tabBodyWrapper",""],["role","tabpanel",3,"id","mat-tab-body-active","content","position","origin","animationDuration","_onCentered","_onCentering",4,"ngFor","ngForOf"],["role","tab","matTabLabelWrapper","","mat-ripple","","cdkMonitorElementFocus","",1,"mat-tab-label","mat-focus-indicator",3,"id","disabled","matRippleDisabled","click"],[1,"mat-tab-label-content"],[3,"ngIf"],[3,"cdkPortalOutlet"],["role","tabpanel",3,"id","content","position","origin","animationDuration","_onCentered","_onCentering"]],template:function(t,e){1&t&&(ga(0,"mat-tab-header",0,1),xa("indexFocused",(function(t){return e._focusChanged(t)}))("selectFocusedIndex",(function(t){return e.selectedIndex=t})),ua(2,_1,4,14,"div",2),va(),ga(3,"div",3,4),ua(5,w1,1,8,"mat-tab-body",5),va()),2&t&&(pa("selectedIndex",e.selectedIndex||0)("disableRipple",e.disableRipple)("disablePagination",e.disablePagination),Qi(2),pa("ngForOf",e._tabs),Qi(1),Qa("_mat-animation-noopable","NoopAnimations"===e._animationMode),Qi(2),pa("ngForOf",e._tabs))},directives:function(){return[Y1,Eh,G1,yJ,O$,Ah,B$,F1]},styles:[".mat-tab-group{display:flex;flex-direction:column}.mat-tab-group.mat-tab-group-inverted-header{flex-direction:column-reverse}.mat-tab-label{height:48px;padding:0 24px;cursor:pointer;box-sizing:border-box;opacity:.6;min-width:160px;text-align:center;display:inline-flex;justify-content:center;align-items:center;white-space:nowrap;position:relative}.mat-tab-label:focus{outline:none}.mat-tab-label:focus:not(.mat-tab-disabled){opacity:1}.cdk-high-contrast-active .mat-tab-label:focus{outline:dotted 2px;outline-offset:-2px}.mat-tab-label.mat-tab-disabled{cursor:default}.cdk-high-contrast-active .mat-tab-label.mat-tab-disabled{opacity:.5}.mat-tab-label .mat-tab-label-content{display:inline-flex;justify-content:center;align-items:center;white-space:nowrap}.cdk-high-contrast-active .mat-tab-label{opacity:1}@media(max-width: 599px){.mat-tab-label{padding:0 12px}}@media(max-width: 959px){.mat-tab-label{padding:0 12px}}.mat-tab-group[mat-stretch-tabs]>.mat-tab-header .mat-tab-label{flex-basis:0;flex-grow:1}.mat-tab-body-wrapper{position:relative;overflow:hidden;display:flex;transition:height 500ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable.mat-tab-body-wrapper{transition:none;animation:none}.mat-tab-body{top:0;left:0;right:0;bottom:0;position:absolute;display:block;overflow:hidden;flex-basis:100%}.mat-tab-body.mat-tab-body-active{position:relative;overflow-x:hidden;overflow-y:auto;z-index:1;flex-grow:1}.mat-tab-group.mat-tab-group-dynamic-height .mat-tab-body.mat-tab-body-active{overflow-y:hidden}\n"],encapsulation:2}),t}(),q1=J$((function t(){Object(m.a)(this,t)})),G1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this)).elementRef=t,i}return Object(g.a)(n,[{key:"focus",value:function(){this.elementRef.nativeElement.focus()}},{key:"getOffsetLeft",value:function(){return this.elementRef.nativeElement.offsetLeft}},{key:"getOffsetWidth",value:function(){return this.elementRef.nativeElement.offsetWidth}}]),n}(q1);return t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","matTabLabelWrapper",""]],hostVars:3,hostBindings:function(t,e){2&t&&(oa("aria-disabled",!!e.disabled),Qa("mat-tab-disabled",e.disabled))},inputs:{disabled:"disabled"},features:[ws]}),t}(),W1=Mm({passive:!0}),K1=function(){var t=function(){function t(e,n,i,r,o,a,s){var c=this;Object(m.a)(this,t),this._elementRef=e,this._changeDetectorRef=n,this._viewportRuler=i,this._dir=r,this._ngZone=o,this._platform=a,this._animationMode=s,this._scrollDistance=0,this._selectedIndexChanged=!1,this._destroyed=new w.b,this._showPaginationControls=!1,this._disableScrollAfter=!0,this._disableScrollBefore=!0,this._stopScrolling=new w.b,this.disablePagination=!1,this._selectedIndex=0,this.selectFocusedIndex=new Uc,this.indexFocused=new Uc,o.runOutsideAngular((function(){Object(IJ.a)(e.nativeElement,"mouseleave").pipe(Object(Am.a)(c._destroyed)).subscribe((function(){c._stopInterval()}))}))}return Object(g.a)(t,[{key:"ngAfterViewInit",value:function(){var t=this;Object(IJ.a)(this._previousPaginator.nativeElement,"touchstart",W1).pipe(Object(Am.a)(this._destroyed)).subscribe((function(){t._handlePaginatorPress("before")})),Object(IJ.a)(this._nextPaginator.nativeElement,"touchstart",W1).pipe(Object(Am.a)(this._destroyed)).subscribe((function(){t._handlePaginatorPress("after")}))}},{key:"ngAfterContentInit",value:function(){var t=this,e=this._dir?this._dir.change:Object(lm.a)(null),n=this._viewportRuler.change(150),i=function(){t.updatePagination(),t._alignInkBarToSelectedTab()};this._keyManager=new d$(this._items).withHorizontalOrientation(this._getLayoutDirection()).withWrap(),this._keyManager.updateActiveItem(0),"undefined"!=typeof requestAnimationFrame?requestAnimationFrame(i):i(),Object(C.a)(e,n,this._items.changes).pipe(Object(Am.a)(this._destroyed)).subscribe((function(){Promise.resolve().then(i),t._keyManager.withHorizontalOrientation(t._getLayoutDirection())})),this._keyManager.change.pipe(Object(Am.a)(this._destroyed)).subscribe((function(e){t.indexFocused.emit(e),t._setTabFocus(e)}))}},{key:"ngAfterContentChecked",value:function(){this._tabLabelCount!=this._items.length&&(this.updatePagination(),this._tabLabelCount=this._items.length,this._changeDetectorRef.markForCheck()),this._selectedIndexChanged&&(this._scrollToLabel(this._selectedIndex),this._checkScrollingControls(),this._alignInkBarToSelectedTab(),this._selectedIndexChanged=!1,this._changeDetectorRef.markForCheck()),this._scrollDistanceChanged&&(this._updateTabScrollPosition(),this._scrollDistanceChanged=!1,this._changeDetectorRef.markForCheck())}},{key:"ngOnDestroy",value:function(){this._destroyed.next(),this._destroyed.complete(),this._stopScrolling.complete()}},{key:"_handleKeydown",value:function(t){if(!JQ(t))switch(t.keyCode){case 36:this._keyManager.setFirstItemActive(),t.preventDefault();break;case 35:this._keyManager.setLastItemActive(),t.preventDefault();break;case 13:case 32:this.focusIndex!==this.selectedIndex&&(this.selectFocusedIndex.emit(this.focusIndex),this._itemSelected(t));break;default:this._keyManager.onKeydown(t)}}},{key:"_onContentChanges",value:function(){var t=this,e=this._elementRef.nativeElement.textContent;e!==this._currentTextContent&&(this._currentTextContent=e||"",this._ngZone.run((function(){t.updatePagination(),t._alignInkBarToSelectedTab(),t._changeDetectorRef.markForCheck()})))}},{key:"updatePagination",value:function(){this._checkPaginationEnabled(),this._checkScrollingControls(),this._updateTabScrollPosition()}},{key:"_isValidIndex",value:function(t){if(!this._items)return!0;var e=this._items?this._items.toArray()[t]:null;return!!e&&!e.disabled}},{key:"_setTabFocus",value:function(t){if(this._showPaginationControls&&this._scrollToLabel(t),this._items&&this._items.length){this._items.toArray()[t].focus();var e=this._tabListContainer.nativeElement,n=this._getLayoutDirection();e.scrollLeft="ltr"==n?0:e.scrollWidth-e.offsetWidth}}},{key:"_getLayoutDirection",value:function(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}},{key:"_updateTabScrollPosition",value:function(){if(!this.disablePagination){var t=this.scrollDistance,e=this._platform,n="ltr"===this._getLayoutDirection()?-t:t;this._tabList.nativeElement.style.transform="translateX(".concat(Math.round(n),"px)"),e&&(e.TRIDENT||e.EDGE)&&(this._tabListContainer.nativeElement.scrollLeft=0)}}},{key:"_scrollHeader",value:function(t){return this._scrollTo(this._scrollDistance+("before"==t?-1:1)*this._tabListContainer.nativeElement.offsetWidth/3)}},{key:"_handlePaginatorClick",value:function(t){this._stopInterval(),this._scrollHeader(t)}},{key:"_scrollToLabel",value:function(t){if(!this.disablePagination){var e=this._items?this._items.toArray()[t]:null;if(e){var n,i,r=this._tabListContainer.nativeElement.offsetWidth,o=e.elementRef.nativeElement,a=o.offsetLeft,s=o.offsetWidth;"ltr"==this._getLayoutDirection()?i=(n=a)+s:n=(i=this._tabList.nativeElement.offsetWidth-a)-s;var c=this.scrollDistance,l=this.scrollDistance+r;n<c?this.scrollDistance-=c-n+60:i>l&&(this.scrollDistance+=i-l+60)}}}},{key:"_checkPaginationEnabled",value:function(){if(this.disablePagination)this._showPaginationControls=!1;else{var t=this._tabList.nativeElement.scrollWidth>this._elementRef.nativeElement.offsetWidth;t||(this.scrollDistance=0),t!==this._showPaginationControls&&this._changeDetectorRef.markForCheck(),this._showPaginationControls=t}}},{key:"_checkScrollingControls",value:function(){this.disablePagination?this._disableScrollAfter=this._disableScrollBefore=!0:(this._disableScrollBefore=0==this.scrollDistance,this._disableScrollAfter=this.scrollDistance==this._getMaxScrollDistance(),this._changeDetectorRef.markForCheck())}},{key:"_getMaxScrollDistance",value:function(){return this._tabList.nativeElement.scrollWidth-this._tabListContainer.nativeElement.offsetWidth||0}},{key:"_alignInkBarToSelectedTab",value:function(){var t=this._items&&this._items.length?this._items.toArray()[this.selectedIndex]:null,e=t?t.elementRef.nativeElement:null;e?this._inkBar.alignToElement(e):this._inkBar.hide()}},{key:"_stopInterval",value:function(){this._stopScrolling.next()}},{key:"_handlePaginatorPress",value:function(t,e){var n=this;e&&null!=e.button&&0!==e.button||(this._stopInterval(),Object(l1.a)(650,100).pipe(Object(Am.a)(Object(C.a)(this._stopScrolling,this._destroyed))).subscribe((function(){var e=n._scrollHeader(t),i=e.distance;(0===i||i>=e.maxScrollDistance)&&n._stopInterval()})))}},{key:"_scrollTo",value:function(t){if(this.disablePagination)return{maxScrollDistance:0,distance:0};var e=this._getMaxScrollDistance();return this._scrollDistance=Math.max(0,Math.min(e,t)),this._scrollDistanceChanged=!0,this._checkScrollingControls(),{maxScrollDistance:e,distance:this._scrollDistance}}},{key:"selectedIndex",get:function(){return this._selectedIndex},set:function(t){t=im(t),this._selectedIndex!=t&&(this._selectedIndexChanged=!0,this._selectedIndex=t,this._keyManager&&this._keyManager.updateActiveItem(t))}},{key:"focusIndex",get:function(){return this._keyManager?this._keyManager.activeItemIndex:0},set:function(t){this._isValidIndex(t)&&this.focusIndex!==t&&this._keyManager&&this._keyManager.setActiveItem(t)}},{key:"scrollDistance",get:function(){return this._scrollDistance},set:function(t){this._scrollTo(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(zJ),da(gm,8),da(jl),da(Cm),da(Cy,8))},t.\u0275dir=Wt({type:t,inputs:{disablePagination:"disablePagination"}}),t}(),X1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c){var l;return Object(m.a)(this,n),(l=e.call(this,t,i,r,o,a,s,c))._disableRipple=!1,l}return Object(g.a)(n,[{key:"_itemSelected",value:function(t){t.preventDefault()}},{key:"disableRipple",get:function(){return this._disableRipple},set:function(t){this._disableRipple=nm(t)}}]),n}(K1);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(zJ),da(gm,8),da(jl),da(Cm),da(Cy,8))},t.\u0275dir=Wt({type:t,inputs:{disableRipple:"disableRipple"},features:[ws]}),t}(),Y1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c){return Object(m.a)(this,n),e.call(this,t,i,r,o,a,s,c)}return n}(X1);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(zJ),da(gm,8),da(jl),da(Cm),da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-tab-header"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,G1,!1),2&t&&tl(i=sl())&&(e._items=i)},viewQuery:function(t,e){var n;1&t&&(el(T1,!0),el(k1,!0),el(C1,!0),nl(S1,!0),nl(x1,!0)),2&t&&(tl(n=sl())&&(e._inkBar=n.first),tl(n=sl())&&(e._tabListContainer=n.first),tl(n=sl())&&(e._tabList=n.first),tl(n=sl())&&(e._nextPaginator=n.first),tl(n=sl())&&(e._previousPaginator=n.first))},hostAttrs:[1,"mat-tab-header"],hostVars:4,hostBindings:function(t,e){2&t&&Qa("mat-tab-header-pagination-controls-enabled",e._showPaginationControls)("mat-tab-header-rtl","rtl"==e._getLayoutDirection())},inputs:{selectedIndex:"selectedIndex"},outputs:{selectFocusedIndex:"selectFocusedIndex",indexFocused:"indexFocused"},features:[ws],ngContentSelectors:h1,decls:13,vars:8,consts:[["aria-hidden","true","mat-ripple","",1,"mat-tab-header-pagination","mat-tab-header-pagination-before","mat-elevation-z4",3,"matRippleDisabled","click","mousedown","touchend"],["previousPaginator",""],[1,"mat-tab-header-pagination-chevron"],[1,"mat-tab-label-container",3,"keydown"],["tabListContainer",""],["role","tablist",1,"mat-tab-list",3,"cdkObserveContent"],["tabList",""],[1,"mat-tab-labels"],["aria-hidden","true","mat-ripple","",1,"mat-tab-header-pagination","mat-tab-header-pagination-after","mat-elevation-z4",3,"matRippleDisabled","mousedown","click","touchend"],["nextPaginator",""]],template:function(t,e){1&t&&(Ia(),ga(0,"div",0,1),xa("click",(function(){return e._handlePaginatorClick("before")}))("mousedown",(function(t){return e._handlePaginatorPress("before",t)}))("touchend",(function(){return e._stopInterval()})),ba(2,"div",2),va(),ga(3,"div",3,4),xa("keydown",(function(t){return e._handleKeydown(t)})),ga(5,"div",5,6),xa("cdkObserveContent",(function(){return e._onContentChanges()})),ga(7,"div",7),Da(8),va(),ba(9,"mat-ink-bar"),va(),va(),ga(10,"div",8,9),xa("mousedown",(function(t){return e._handlePaginatorPress("after",t)}))("click",(function(){return e._handlePaginatorClick("after")}))("touchend",(function(){return e._stopInterval()})),ba(12,"div",2),va()),2&t&&(Qa("mat-tab-header-pagination-disabled",e._disableScrollBefore),pa("matRippleDisabled",e._disableScrollBefore||e.disableRipple),Qi(5),Qa("_mat-animation-noopable","NoopAnimations"===e._animationMode),Qi(5),Qa("mat-tab-header-pagination-disabled",e._disableScrollAfter),pa("matRippleDisabled",e._disableScrollAfter||e.disableRipple))},directives:[yJ,i$,T1],styles:['.mat-tab-header{display:flex;overflow:hidden;position:relative;flex-shrink:0}.mat-tab-header-pagination{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative;display:none;justify-content:center;align-items:center;min-width:32px;cursor:pointer;z-index:2;-webkit-tap-highlight-color:transparent;touch-action:none}.mat-tab-header-pagination-controls-enabled .mat-tab-header-pagination{display:flex}.mat-tab-header-pagination-before,.mat-tab-header-rtl .mat-tab-header-pagination-after{padding-left:4px}.mat-tab-header-pagination-before .mat-tab-header-pagination-chevron,.mat-tab-header-rtl .mat-tab-header-pagination-after .mat-tab-header-pagination-chevron{transform:rotate(-135deg)}.mat-tab-header-rtl .mat-tab-header-pagination-before,.mat-tab-header-pagination-after{padding-right:4px}.mat-tab-header-rtl .mat-tab-header-pagination-before .mat-tab-header-pagination-chevron,.mat-tab-header-pagination-after .mat-tab-header-pagination-chevron{transform:rotate(45deg)}.mat-tab-header-pagination-chevron{border-style:solid;border-width:2px 2px 0 0;content:"";height:8px;width:8px}.mat-tab-header-pagination-disabled{box-shadow:none;cursor:default}.mat-tab-list{flex-grow:1;position:relative;transition:transform 500ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-ink-bar{position:absolute;bottom:0;height:2px;transition:500ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable.mat-ink-bar{transition:none;animation:none}.mat-tab-group-inverted-header .mat-ink-bar{bottom:auto;top:0}.cdk-high-contrast-active .mat-ink-bar{outline:solid 2px;height:0}.mat-tab-labels{display:flex}[mat-align-tabs=center]>.mat-tab-header .mat-tab-labels{justify-content:center}[mat-align-tabs=end]>.mat-tab-header .mat-tab-labels{justify-content:flex-end}.mat-tab-label-container{display:flex;flex-grow:1;overflow:hidden;z-index:1}._mat-animation-noopable.mat-tab-list{transition:none;animation:none}.mat-tab-label{height:48px;padding:0 24px;cursor:pointer;box-sizing:border-box;opacity:.6;min-width:160px;text-align:center;display:inline-flex;justify-content:center;align-items:center;white-space:nowrap;position:relative}.mat-tab-label:focus{outline:none}.mat-tab-label:focus:not(.mat-tab-disabled){opacity:1}.cdk-high-contrast-active .mat-tab-label:focus{outline:dotted 2px;outline-offset:-2px}.mat-tab-label.mat-tab-disabled{cursor:default}.cdk-high-contrast-active .mat-tab-label.mat-tab-disabled{opacity:.5}.mat-tab-label .mat-tab-label-content{display:inline-flex;justify-content:center;align-items:center;white-space:nowrap}.cdk-high-contrast-active .mat-tab-label{opacity:1}@media(max-width: 599px){.mat-tab-label{min-width:72px}}\n'],encapsulation:2}),t}(),Z1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c){var l;return Object(m.a)(this,n),(l=e.call(this,t,o,a,i,r,s,c))._disableRipple=!1,l.color="primary",l}return Object(g.a)(n,[{key:"_itemSelected",value:function(){}},{key:"ngAfterContentInit",value:function(){var t=this;this._items.changes.pipe(Object(NX.a)(null),Object(Am.a)(this._destroyed)).subscribe((function(){t.updateActiveLink()})),Object(o.a)(Object(a.a)(n.prototype),"ngAfterContentInit",this).call(this)}},{key:"updateActiveLink",value:function(t){if(this._items){for(var e=this._items.toArray(),n=0;n<e.length;n++)if(e[n].active)return this.selectedIndex=n,void this._changeDetectorRef.markForCheck();this.selectedIndex=-1,this._inkBar.hide()}}},{key:"backgroundColor",get:function(){return this._backgroundColor},set:function(t){var e=this._elementRef.nativeElement.classList;e.remove("mat-background-".concat(this.backgroundColor)),t&&e.add("mat-background-".concat(t)),this._backgroundColor=t}},{key:"disableRipple",get:function(){return this._disableRipple},set:function(t){this._disableRipple=nm(t)}}]),n}(K1);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(gm,8),da(jl),da(Po),da(zJ),da(Cm,8),da(Cy,8))},t.\u0275dir=Wt({type:t,inputs:{color:"color",backgroundColor:"backgroundColor",disableRipple:"disableRipple"},features:[ws]}),t}(),Q1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c){return Object(m.a)(this,n),e.call(this,t,i,r,o,a,s,c)}return n}(Z1);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(gm,8),da(jl),da(Po),da(zJ),da(Cm,8),da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["","mat-tab-nav-bar",""]],contentQueries:function(t,e,n){var i;1&t&&rl(n,t2,!0),2&t&&tl(i=sl())&&(e._items=i)},viewQuery:function(t,e){var n;1&t&&(el(T1,!0),el(k1,!0),el(C1,!0),nl(S1,!0),nl(x1,!0)),2&t&&(tl(n=sl())&&(e._inkBar=n.first),tl(n=sl())&&(e._tabListContainer=n.first),tl(n=sl())&&(e._tabList=n.first),tl(n=sl())&&(e._nextPaginator=n.first),tl(n=sl())&&(e._previousPaginator=n.first))},hostAttrs:[1,"mat-tab-nav-bar","mat-tab-header"],hostVars:10,hostBindings:function(t,e){2&t&&Qa("mat-tab-header-pagination-controls-enabled",e._showPaginationControls)("mat-tab-header-rtl","rtl"==e._getLayoutDirection())("mat-primary","warn"!==e.color&&"accent"!==e.color)("mat-accent","accent"===e.color)("mat-warn","warn"===e.color)},inputs:{color:"color"},exportAs:["matTabNavBar","matTabNav"],features:[ws],attrs:O1,ngContentSelectors:h1,decls:13,vars:8,consts:[["aria-hidden","true","mat-ripple","",1,"mat-tab-header-pagination","mat-tab-header-pagination-before","mat-elevation-z4",3,"matRippleDisabled","click","mousedown","touchend"],["previousPaginator",""],[1,"mat-tab-header-pagination-chevron"],[1,"mat-tab-link-container",3,"keydown"],["tabListContainer",""],[1,"mat-tab-list",3,"cdkObserveContent"],["tabList",""],[1,"mat-tab-links"],["aria-hidden","true","mat-ripple","",1,"mat-tab-header-pagination","mat-tab-header-pagination-after","mat-elevation-z4",3,"matRippleDisabled","mousedown","click","touchend"],["nextPaginator",""]],template:function(t,e){1&t&&(Ia(),ga(0,"div",0,1),xa("click",(function(){return e._handlePaginatorClick("before")}))("mousedown",(function(t){return e._handlePaginatorPress("before",t)}))("touchend",(function(){return e._stopInterval()})),ba(2,"div",2),va(),ga(3,"div",3,4),xa("keydown",(function(t){return e._handleKeydown(t)})),ga(5,"div",5,6),xa("cdkObserveContent",(function(){return e._onContentChanges()})),ga(7,"div",7),Da(8),va(),ba(9,"mat-ink-bar"),va(),va(),ga(10,"div",8,9),xa("mousedown",(function(t){return e._handlePaginatorPress("after",t)}))("click",(function(){return e._handlePaginatorClick("after")}))("touchend",(function(){return e._stopInterval()})),ba(12,"div",2),va()),2&t&&(Qa("mat-tab-header-pagination-disabled",e._disableScrollBefore),pa("matRippleDisabled",e._disableScrollBefore||e.disableRipple),Qi(5),Qa("_mat-animation-noopable","NoopAnimations"===e._animationMode),Qi(5),Qa("mat-tab-header-pagination-disabled",e._disableScrollAfter),pa("matRippleDisabled",e._disableScrollAfter||e.disableRipple))},directives:[yJ,i$,T1],styles:['.mat-tab-header{display:flex;overflow:hidden;position:relative;flex-shrink:0}.mat-tab-header-pagination{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative;display:none;justify-content:center;align-items:center;min-width:32px;cursor:pointer;z-index:2;-webkit-tap-highlight-color:transparent;touch-action:none}.mat-tab-header-pagination-controls-enabled .mat-tab-header-pagination{display:flex}.mat-tab-header-pagination-before,.mat-tab-header-rtl .mat-tab-header-pagination-after{padding-left:4px}.mat-tab-header-pagination-before .mat-tab-header-pagination-chevron,.mat-tab-header-rtl .mat-tab-header-pagination-after .mat-tab-header-pagination-chevron{transform:rotate(-135deg)}.mat-tab-header-rtl .mat-tab-header-pagination-before,.mat-tab-header-pagination-after{padding-right:4px}.mat-tab-header-rtl .mat-tab-header-pagination-before .mat-tab-header-pagination-chevron,.mat-tab-header-pagination-after .mat-tab-header-pagination-chevron{transform:rotate(45deg)}.mat-tab-header-pagination-chevron{border-style:solid;border-width:2px 2px 0 0;content:"";height:8px;width:8px}.mat-tab-header-pagination-disabled{box-shadow:none;cursor:default}.mat-tab-list{flex-grow:1;position:relative;transition:transform 500ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-tab-links{display:flex}[mat-align-tabs=center]>.mat-tab-link-container .mat-tab-links{justify-content:center}[mat-align-tabs=end]>.mat-tab-link-container .mat-tab-links{justify-content:flex-end}.mat-ink-bar{position:absolute;bottom:0;height:2px;transition:500ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable.mat-ink-bar{transition:none;animation:none}.mat-tab-group-inverted-header .mat-ink-bar{bottom:auto;top:0}.cdk-high-contrast-active .mat-ink-bar{outline:solid 2px;height:0}.mat-tab-link-container{display:flex;flex-grow:1;overflow:hidden;z-index:1}.mat-tab-link{height:48px;padding:0 24px;cursor:pointer;box-sizing:border-box;opacity:.6;min-width:160px;text-align:center;display:inline-flex;justify-content:center;align-items:center;white-space:nowrap;vertical-align:top;text-decoration:none;position:relative;overflow:hidden;-webkit-tap-highlight-color:transparent}.mat-tab-link:focus{outline:none}.mat-tab-link:focus:not(.mat-tab-disabled){opacity:1}.cdk-high-contrast-active .mat-tab-link:focus{outline:dotted 2px;outline-offset:-2px}.mat-tab-link.mat-tab-disabled{cursor:default}.cdk-high-contrast-active .mat-tab-link.mat-tab-disabled{opacity:.5}.mat-tab-link .mat-tab-label-content{display:inline-flex;justify-content:center;align-items:center;white-space:nowrap}.cdk-high-contrast-active .mat-tab-link{opacity:1}[mat-stretch-tabs] .mat-tab-link{flex-basis:0;flex-grow:1}.mat-tab-link.mat-tab-disabled{pointer-events:none}@media(max-width: 599px){.mat-tab-link{min-width:72px}}\n'],encapsulation:2}),t}(),$1=nJ(eJ(J$((function t(){Object(m.a)(this,t)})))),J1=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s){var c;return Object(m.a)(this,n),(c=e.call(this))._tabNavBar=t,c.elementRef=i,c._focusMonitor=a,c._isActive=!1,c.rippleConfig=r||{},c.tabIndex=parseInt(o)||0,"NoopAnimations"===s&&(c.rippleConfig.animation={enterDuration:0,exitDuration:0}),c}return Object(g.a)(n,[{key:"focus",value:function(){this.elementRef.nativeElement.focus()}},{key:"ngAfterViewInit",value:function(){this._focusMonitor.monitor(this.elementRef)}},{key:"ngOnDestroy",value:function(){this._focusMonitor.stopMonitoring(this.elementRef)}},{key:"active",get:function(){return this._isActive},set:function(t){t!==this._isActive&&(this._isActive=t,this._tabNavBar.updateActiveLink(this.elementRef))}},{key:"rippleDisabled",get:function(){return this.disabled||this.disableRipple||this._tabNavBar.disableRipple||!!this.rippleConfig.disabled}}]),n}($1);return t.\u0275fac=function(e){return new(e||t)(da(Z1),da(Us),da(bJ,8),fa("tabindex"),da(S$),da(Cy,8))},t.\u0275dir=Wt({type:t,inputs:{active:"active"},features:[ws]}),t}(),t2=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,c,l,u){var h;return Object(m.a)(this,n),(h=e.call(this,t,i,a,c,l,u))._tabLinkRipple=new mJ(Object(s.a)(h),r,i,o),h._tabLinkRipple.setupTriggerEvents(i.nativeElement),h}return Object(g.a)(n,[{key:"ngOnDestroy",value:function(){Object(o.a)(Object(a.a)(n.prototype),"ngOnDestroy",this).call(this),this._tabLinkRipple._removeTriggerEvents()}}]),n}(J1);return t.\u0275fac=function(e){return new(e||t)(da(Q1),da(Us),da(jl),da(Cm),da(bJ,8),fa("tabindex"),da(S$),da(Cy,8))},t.\u0275dir=Wt({type:t,selectors:[["","mat-tab-link",""],["","matTabLink",""]],hostAttrs:[1,"mat-tab-link","mat-focus-indicator"],hostVars:7,hostBindings:function(t,e){2&t&&(oa("aria-current",e.active?"page":null)("aria-disabled",e.disabled)("tabIndex",e.tabIndex),Qa("mat-tab-disabled",e.disabled)("mat-tab-label-active",e.active))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex"},exportAs:["matTabLink"],features:[ws]}),t}(),e2=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd,$$,z$,_J,r$,T$],$$]}),t}(),n2=["mat-button",""],i2=["*"],r2=["mat-button","mat-flat-button","mat-icon-button","mat-raised-button","mat-stroked-button","mat-mini-fab","mat-fab"],o2=tJ(J$(eJ((function t(e){Object(m.a)(this,t),this._elementRef=e})))),a2=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;Object(m.a)(this,n),(o=e.call(this,t))._focusMonitor=i,o._animationMode=r,o.isRoundButton=o._hasHostAttributes("mat-fab","mat-mini-fab"),o.isIconButton=o._hasHostAttributes("mat-icon-button");var a,s=d(r2);try{for(s.s();!(a=s.n()).done;){var c=a.value;o._hasHostAttributes(c)&&o._getHostElement().classList.add(c)}}catch(l){s.e(l)}finally{s.f()}return t.nativeElement.classList.add("mat-button-base"),o.isRoundButton&&(o.color="accent"),o}return Object(g.a)(n,[{key:"ngAfterViewInit",value:function(){this._focusMonitor.monitor(this._elementRef,!0)}},{key:"ngOnDestroy",value:function(){this._focusMonitor.stopMonitoring(this._elementRef)}},{key:"focus",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"program",e=arguments.length>1?arguments[1]:void 0;this._focusMonitor.focusVia(this._getHostElement(),t,e)}},{key:"_getHostElement",value:function(){return this._elementRef.nativeElement}},{key:"_isRippleDisabled",value:function(){return this.disableRipple||this.disabled}},{key:"_hasHostAttributes",value:function(){for(var t=this,e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return n.some((function(e){return t._getHostElement().hasAttribute(e)}))}}]),n}(o2);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(S$),da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["button","mat-button",""],["button","mat-raised-button",""],["button","mat-icon-button",""],["button","mat-fab",""],["button","mat-mini-fab",""],["button","mat-stroked-button",""],["button","mat-flat-button",""]],viewQuery:function(t,e){var n;1&t&&nl(yJ,!0),2&t&&tl(n=sl())&&(e.ripple=n.first)},hostAttrs:[1,"mat-focus-indicator"],hostVars:3,hostBindings:function(t,e){2&t&&(oa("disabled",e.disabled||null),Qa("_mat-animation-noopable","NoopAnimations"===e._animationMode))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color"},exportAs:["matButton"],features:[ws],attrs:n2,ngContentSelectors:i2,decls:4,vars:5,consts:[[1,"mat-button-wrapper"],["matRipple","",1,"mat-button-ripple",3,"matRippleDisabled","matRippleCentered","matRippleTrigger"],[1,"mat-button-focus-overlay"]],template:function(t,e){1&t&&(Ia(),ga(0,"span",0),Da(1),va(),ba(2,"div",1),ba(3,"div",2)),2&t&&(Qi(2),Qa("mat-button-ripple-round",e.isRoundButton||e.isIconButton),pa("matRippleDisabled",e._isRippleDisabled())("matRippleCentered",e.isIconButton)("matRippleTrigger",e._getHostElement()))},directives:[yJ],styles:[".mat-button .mat-button-focus-overlay,.mat-icon-button .mat-button-focus-overlay{opacity:0}.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:.04}@media(hover: none){.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:0}}.mat-button,.mat-icon-button,.mat-stroked-button,.mat-flat-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-button[disabled],.mat-icon-button[disabled],.mat-stroked-button[disabled],.mat-flat-button[disabled]{cursor:default}.mat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-button.cdk-program-focused .mat-button-focus-overlay,.mat-icon-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-icon-button.cdk-program-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-program-focused .mat-button-focus-overlay,.mat-flat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-flat-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-raised-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button[disabled]{cursor:default}.mat-raised-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-raised-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-raised-button::-moz-focus-inner{border:0}._mat-animation-noopable.mat-raised-button{transition:none;animation:none}.mat-stroked-button{border:1px solid currentColor;padding:0 15px;line-height:34px}.mat-stroked-button .mat-button-ripple.mat-ripple,.mat-stroked-button .mat-button-focus-overlay{top:-1px;left:-1px;right:-1px;bottom:-1px}.mat-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:56px;height:56px;padding:0;flex-shrink:0}.mat-fab::-moz-focus-inner{border:0}.mat-fab[disabled]{cursor:default}.mat-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-fab{transition:none;animation:none}.mat-fab .mat-button-wrapper{padding:16px 0;display:inline-block;line-height:24px}.mat-mini-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:40px;height:40px;padding:0;flex-shrink:0}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab[disabled]{cursor:default}.mat-mini-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-mini-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-mini-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-mini-fab{transition:none;animation:none}.mat-mini-fab .mat-button-wrapper{padding:8px 0;display:inline-block;line-height:24px}.mat-icon-button{padding:0;min-width:0;width:40px;height:40px;flex-shrink:0;line-height:40px;border-radius:50%}.mat-icon-button i,.mat-icon-button .mat-icon{line-height:24px}.mat-button-ripple.mat-ripple,.mat-button-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-button-ripple.mat-ripple:not(:empty){transform:translateZ(0)}.mat-button-focus-overlay{opacity:0;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1),background-color 200ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-button-focus-overlay{transition:none}.cdk-high-contrast-active .mat-button-focus-overlay{background-color:#fff}.cdk-high-contrast-black-on-white .mat-button-focus-overlay{background-color:#000}.mat-button-ripple-round{border-radius:50%;z-index:1}.mat-button .mat-button-wrapper>*,.mat-flat-button .mat-button-wrapper>*,.mat-stroked-button .mat-button-wrapper>*,.mat-raised-button .mat-button-wrapper>*,.mat-icon-button .mat-button-wrapper>*,.mat-fab .mat-button-wrapper>*,.mat-mini-fab .mat-button-wrapper>*{vertical-align:middle}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button{display:block;font-size:inherit;width:2.5em;height:2.5em}.cdk-high-contrast-active .mat-button,.cdk-high-contrast-active .mat-flat-button,.cdk-high-contrast-active .mat-raised-button,.cdk-high-contrast-active .mat-icon-button,.cdk-high-contrast-active .mat-fab,.cdk-high-contrast-active .mat-mini-fab{outline:solid 1px}\n"],encapsulation:2,changeDetection:0}),t}(),s2=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){return Object(m.a)(this,n),e.call(this,i,t,r)}return Object(g.a)(n,[{key:"_haltDisabledEvents",value:function(t){this.disabled&&(t.preventDefault(),t.stopImmediatePropagation())}}]),n}(a2);return t.\u0275fac=function(e){return new(e||t)(da(S$),da(Us),da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["a","mat-button",""],["a","mat-raised-button",""],["a","mat-icon-button",""],["a","mat-fab",""],["a","mat-mini-fab",""],["a","mat-stroked-button",""],["a","mat-flat-button",""]],hostAttrs:[1,"mat-focus-indicator"],hostVars:5,hostBindings:function(t,e){1&t&&xa("click",(function(t){return e._haltDisabledEvents(t)})),2&t&&(oa("tabindex",e.disabled?-1:e.tabIndex||0)("disabled",e.disabled||null)("aria-disabled",e.disabled.toString()),Qa("_mat-animation-noopable","NoopAnimations"===e._animationMode))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color",tabIndex:"tabIndex"},exportAs:["matButton","matAnchor"],features:[ws],attrs:n2,ngContentSelectors:i2,decls:4,vars:5,consts:[[1,"mat-button-wrapper"],["matRipple","",1,"mat-button-ripple",3,"matRippleDisabled","matRippleCentered","matRippleTrigger"],[1,"mat-button-focus-overlay"]],template:function(t,e){1&t&&(Ia(),ga(0,"span",0),Da(1),va(),ba(2,"div",1),ba(3,"div",2)),2&t&&(Qi(2),Qa("mat-button-ripple-round",e.isRoundButton||e.isIconButton),pa("matRippleDisabled",e._isRippleDisabled())("matRippleCentered",e.isIconButton)("matRippleTrigger",e._getHostElement()))},directives:[yJ],styles:[".mat-button .mat-button-focus-overlay,.mat-icon-button .mat-button-focus-overlay{opacity:0}.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:.04}@media(hover: none){.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:0}}.mat-button,.mat-icon-button,.mat-stroked-button,.mat-flat-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-button[disabled],.mat-icon-button[disabled],.mat-stroked-button[disabled],.mat-flat-button[disabled]{cursor:default}.mat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-button.cdk-program-focused .mat-button-focus-overlay,.mat-icon-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-icon-button.cdk-program-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-program-focused .mat-button-focus-overlay,.mat-flat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-flat-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-raised-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button[disabled]{cursor:default}.mat-raised-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-raised-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-raised-button::-moz-focus-inner{border:0}._mat-animation-noopable.mat-raised-button{transition:none;animation:none}.mat-stroked-button{border:1px solid currentColor;padding:0 15px;line-height:34px}.mat-stroked-button .mat-button-ripple.mat-ripple,.mat-stroked-button .mat-button-focus-overlay{top:-1px;left:-1px;right:-1px;bottom:-1px}.mat-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:56px;height:56px;padding:0;flex-shrink:0}.mat-fab::-moz-focus-inner{border:0}.mat-fab[disabled]{cursor:default}.mat-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-fab{transition:none;animation:none}.mat-fab .mat-button-wrapper{padding:16px 0;display:inline-block;line-height:24px}.mat-mini-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:40px;height:40px;padding:0;flex-shrink:0}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab[disabled]{cursor:default}.mat-mini-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-mini-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-mini-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-mini-fab{transition:none;animation:none}.mat-mini-fab .mat-button-wrapper{padding:8px 0;display:inline-block;line-height:24px}.mat-icon-button{padding:0;min-width:0;width:40px;height:40px;flex-shrink:0;line-height:40px;border-radius:50%}.mat-icon-button i,.mat-icon-button .mat-icon{line-height:24px}.mat-button-ripple.mat-ripple,.mat-button-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-button-ripple.mat-ripple:not(:empty){transform:translateZ(0)}.mat-button-focus-overlay{opacity:0;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1),background-color 200ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-button-focus-overlay{transition:none}.cdk-high-contrast-active .mat-button-focus-overlay{background-color:#fff}.cdk-high-contrast-black-on-white .mat-button-focus-overlay{background-color:#000}.mat-button-ripple-round{border-radius:50%;z-index:1}.mat-button .mat-button-wrapper>*,.mat-flat-button .mat-button-wrapper>*,.mat-stroked-button .mat-button-wrapper>*,.mat-raised-button .mat-button-wrapper>*,.mat-icon-button .mat-button-wrapper>*,.mat-fab .mat-button-wrapper>*,.mat-mini-fab .mat-button-wrapper>*{vertical-align:middle}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button{display:block;font-size:inherit;width:2.5em;height:2.5em}.cdk-high-contrast-active .mat-button,.cdk-high-contrast-active .mat-flat-button,.cdk-high-contrast-active .mat-raised-button,.cdk-high-contrast-active .mat-icon-button,.cdk-high-contrast-active .mat-fab,.cdk-high-contrast-active .mat-mini-fab{outline:solid 1px}\n"],encapsulation:2,changeDetection:0}),t}(),c2=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[_J,$$],$$]}),t}();function l2(t,e){if(1&t&&(ga(0,"div"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n," ")}}var u2=function(){function t(t,e){this.dialogRef=t,this.infoService=e,this.infoList=[],this.usage="",this.commandLine=""}return t.prototype.ngOnInit=function(){this.infoList=this.infoService.getInfoAboutNode(this.node,this.server),this.commandLine=this.infoService.getCommandLine(this.node),this.usage=this.node.usage?this.node.usage:"No usage information has been provided for this node."},t.prototype.onCloseClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(U0))},t.\u0275cmp=Ht({type:t,selectors:[["app-info-dialog"]],inputs:{server:"server",node:"node"},decls:16,vars:4,consts:[["mat-dialog-title",""],[1,"modal-form-container"],["animationDuration","0ms"],["label","General information"],[1,"textBox"],[4,"ngFor","ngForOf"],["label","Usage instructions"],["label","Command line"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"mat-tab-group",2),ga(4,"mat-tab",3),ga(5,"div",4),ua(6,l2,2,1,"div",5),va(),va(),ga(7,"mat-tab",6),ga(8,"div",4),ds(9),va(),va(),ga(10,"mat-tab",7),ga(11,"div",4),ds(12),va(),va(),va(),va(),ga(13,"div",8),ga(14,"button",9),xa("click",(function(){return e.onCloseClick()})),ds(15,"Close"),va(),va()),2&t&&(Qi(1),fs(e.node.name),Qi(5),pa("ngForOf",e.infoList),Qi(3),ps(" ",e.usage," "),Qi(3),ps(" ",e.commandLine," "))},directives:[r1,U1,I1,Eh,a1,a2],styles:[".textBox[_ngcontent-%COMP%]{margin-top:10px}"]}),t}(),h2=["*"];function d2(t){return Error('Unable to find icon with the name "'.concat(t,'"'))}function f2(t){return Error("The URL provided to MatIconRegistry was not trusted as a resource URL "+"via Angular's DomSanitizer. Attempted URL was \"".concat(t,'".'))}function p2(t){return Error("The literal provided to MatIconRegistry was not trusted as safe HTML by "+"Angular's DomSanitizer. Attempted literal was \"".concat(t,'".'))}var m2=function t(e,n){Object(m.a)(this,t),this.options=n,e.nodeName?this.svgElement=e:this.url=e},g2=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._httpClient=e,this._sanitizer=n,this._errorHandler=r,this._svgIconConfigs=new Map,this._iconSetConfigs=new Map,this._cachedIconsByUrl=new Map,this._inProgressUrlFetches=new Map,this._fontCssClassesByAlias=new Map,this._defaultFontSetClass="material-icons",this._document=i}return Object(g.a)(t,[{key:"addSvgIcon",value:function(t,e,n){return this.addSvgIconInNamespace("",t,e,n)}},{key:"addSvgIconLiteral",value:function(t,e,n){return this.addSvgIconLiteralInNamespace("",t,e,n)}},{key:"addSvgIconInNamespace",value:function(t,e,n,i){return this._addSvgIconConfig(t,e,new m2(n,i))}},{key:"addSvgIconLiteralInNamespace",value:function(t,e,n,i){var r=this._sanitizer.sanitize(Mi.HTML,n);if(!r)throw p2(n);var o=this._createSvgElementForSingleIcon(r,i);return this._addSvgIconConfig(t,e,new m2(o,i))}},{key:"addSvgIconSet",value:function(t,e){return this.addSvgIconSetInNamespace("",t,e)}},{key:"addSvgIconSetLiteral",value:function(t,e){return this.addSvgIconSetLiteralInNamespace("",t,e)}},{key:"addSvgIconSetInNamespace",value:function(t,e,n){return this._addSvgIconSetConfig(t,new m2(e,n))}},{key:"addSvgIconSetLiteralInNamespace",value:function(t,e,n){var i=this._sanitizer.sanitize(Mi.HTML,e);if(!i)throw p2(e);var r=this._svgElementFromString(i);return this._addSvgIconSetConfig(t,new m2(r,n))}},{key:"registerFontClassAlias",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t;return this._fontCssClassesByAlias.set(t,e),this}},{key:"classNameForFontAlias",value:function(t){return this._fontCssClassesByAlias.get(t)||t}},{key:"setDefaultFontSetClass",value:function(t){return this._defaultFontSetClass=t,this}},{key:"getDefaultFontSetClass",value:function(){return this._defaultFontSetClass}},{key:"getSvgIconFromUrl",value:function(t){var e=this,n=this._sanitizer.sanitize(Mi.RESOURCE_URL,t);if(!n)throw f2(t);var i=this._cachedIconsByUrl.get(n);return i?Object(lm.a)(v2(i)):this._loadSvgIconFromConfig(new m2(t)).pipe(Object(DX.a)((function(t){return e._cachedIconsByUrl.set(n,t)})),Object(ef.a)((function(t){return v2(t)})))}},{key:"getNamedSvgIcon",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=b2(e,t),i=this._svgIconConfigs.get(n);if(i)return this._getSvgFromConfig(i);var r=this._iconSetConfigs.get(e);return r?this._getSvgFromIconSetConfigs(t,r):Object(WQ.a)(d2(n))}},{key:"ngOnDestroy",value:function(){this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}},{key:"_getSvgFromConfig",value:function(t){return t.svgElement?Object(lm.a)(v2(t.svgElement)):this._loadSvgIconFromConfig(t).pipe(Object(DX.a)((function(e){return t.svgElement=e})),Object(ef.a)((function(t){return v2(t)})))}},{key:"_getSvgFromIconSetConfigs",value:function(t,e){var n=this,i=this._extractIconWithNameFromAnySet(t,e);if(i)return Object(lm.a)(i);var r=e.filter((function(t){return!t.svgElement})).map((function(t){return n._loadSvgIconSetFromConfig(t).pipe(Object(AX.a)((function(e){var i=n._sanitizer.sanitize(Mi.RESOURCE_URL,t.url),r="Loading icon set URL: ".concat(i," failed: ").concat(e.message);return n._errorHandler.handleError(new Error(r)),Object(lm.a)(null)})))}));return Object(Jd.a)(r).pipe(Object(ef.a)((function(){var i=n._extractIconWithNameFromAnySet(t,e);if(!i)throw d2(t);return i})))}},{key:"_extractIconWithNameFromAnySet",value:function(t,e){for(var n=e.length-1;n>=0;n--){var i=e[n];if(i.svgElement){var r=this._extractSvgIconFromSet(i.svgElement,t,i.options);if(r)return r}}return null}},{key:"_loadSvgIconFromConfig",value:function(t){var e=this;return this._fetchIcon(t).pipe(Object(ef.a)((function(n){return e._createSvgElementForSingleIcon(n,t.options)})))}},{key:"_loadSvgIconSetFromConfig",value:function(t){var e=this;return t.svgElement?Object(lm.a)(t.svgElement):this._fetchIcon(t).pipe(Object(ef.a)((function(n){return t.svgElement||(t.svgElement=e._svgElementFromString(n)),t.svgElement})))}},{key:"_createSvgElementForSingleIcon",value:function(t,e){var n=this._svgElementFromString(t);return this._setSvgAttributes(n,e),n}},{key:"_extractSvgIconFromSet",value:function(t,e,n){var i=t.querySelector('[id="'.concat(e,'"]'));if(!i)return null;var r=i.cloneNode(!0);if(r.removeAttribute("id"),"svg"===r.nodeName.toLowerCase())return this._setSvgAttributes(r,n);if("symbol"===r.nodeName.toLowerCase())return this._setSvgAttributes(this._toSvgElement(r),n);var o=this._svgElementFromString("<svg></svg>");return o.appendChild(r),this._setSvgAttributes(o,n)}},{key:"_svgElementFromString",value:function(t){var e=this._document.createElement("DIV");e.innerHTML=t;var n=e.querySelector("svg");if(!n)throw Error("<svg> tag not found");return n}},{key:"_toSvgElement",value:function(t){for(var e=this._svgElementFromString("<svg></svg>"),n=t.attributes,i=0;i<n.length;i++){var r=n[i],o=r.name;"id"!==o&&e.setAttribute(o,r.value)}for(var a=0;a<t.childNodes.length;a++)t.childNodes[a].nodeType===this._document.ELEMENT_NODE&&e.appendChild(t.childNodes[a].cloneNode(!0));return e}},{key:"_setSvgAttributes",value:function(t,e){return t.setAttribute("fit",""),t.setAttribute("height","100%"),t.setAttribute("width","100%"),t.setAttribute("preserveAspectRatio","xMidYMid meet"),t.setAttribute("focusable","false"),e&&e.viewBox&&t.setAttribute("viewBox",e.viewBox),t}},{key:"_fetchIcon",value:function(t){var e,n=this,i=t.url,r=t.options,o=null!==(e=null==r?void 0:r.withCredentials)&&void 0!==e&&e;if(!this._httpClient)throw Error("Could not find HttpClient provider for use with Angular Material icons. Please include the HttpClientModule from @angular/common/http in your app imports.");if(null==i)throw Error('Cannot fetch icon from URL "'.concat(i,'".'));var a=this._sanitizer.sanitize(Mi.RESOURCE_URL,i);if(!a)throw f2(i);var s=this._inProgressUrlFetches.get(a);if(s)return s;var c=this._httpClient.get(a,{responseType:"text",withCredentials:o}).pipe(Object(zX.a)((function(){return n._inProgressUrlFetches.delete(a)})),Object(S.a)());return this._inProgressUrlFetches.set(a,c),c}},{key:"_addSvgIconConfig",value:function(t,e,n){return this._svgIconConfigs.set(b2(t,e),n),this}},{key:"_addSvgIconSetConfig",value:function(t,e){var n=this._iconSetConfigs.get(t);return n?n.push(e):this._iconSetConfigs.set(t,[e]),this}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Rg,8),_t(Vd),_t(du,8),_t(Gn))},t.\u0275prov=R({factory:function(){return new t(_t(Rg,8),_t(Vd),_t(du,8),_t(Gn))},token:t,providedIn:"root"}),t}();function v2(t){return t.cloneNode(!0)}function b2(t,e){return t+":"+e}var y2,_2=tJ((function t(e){Object(m.a)(this,t),this._elementRef=e})),w2=new ht("mat-icon-location",{providedIn:"root",factory:function(){var t=wt(du),e=t?t.location:null;return{getPathname:function(){return e?e.pathname+e.search:""}}}}),k2=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],C2=k2.map((function(t){return"[".concat(t,"]")})).join(", "),S2=/^url\(['"]?#(.*?)['"]?\)$/,x2=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){var s;return Object(m.a)(this,n),(s=e.call(this,t))._iconRegistry=i,s._location=o,s._errorHandler=a,s._inline=!1,s._currentIconFetch=_.a.EMPTY,r||t.nativeElement.setAttribute("aria-hidden","true"),s}return Object(g.a)(n,[{key:"_splitIconName",value:function(t){if(!t)return["",""];var e=t.split(":");switch(e.length){case 1:return["",e[0]];case 2:return e;default:throw Error('Invalid icon name: "'.concat(t,'"'))}}},{key:"ngOnChanges",value:function(t){var e=this,n=t.svgIcon;if(n)if(this._currentIconFetch.unsubscribe(),this.svgIcon){var i=l(this._splitIconName(this.svgIcon),2),r=i[0],o=i[1];this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(o,r).pipe(Object(FX.a)(1)).subscribe((function(t){return e._setSvgElement(t)}),(function(t){var n="Error retrieving icon ".concat(r,":").concat(o,"! ").concat(t.message);e._errorHandler.handleError(new Error(n))}))}else n.previousValue&&this._clearSvgElement();this._usingFontIcon()&&this._updateFontIconClasses()}},{key:"ngOnInit",value:function(){this._usingFontIcon()&&this._updateFontIconClasses()}},{key:"ngAfterViewChecked",value:function(){var t=this._elementsWithExternalReferences;if(t&&t.size){var e=this._location.getPathname();e!==this._previousPath&&(this._previousPath=e,this._prependPathToReferences(e))}}},{key:"ngOnDestroy",value:function(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}},{key:"_usingFontIcon",value:function(){return!this.svgIcon}},{key:"_setSvgElement",value:function(t){this._clearSvgElement();for(var e=t.querySelectorAll("style"),n=0;n<e.length;n++)e[n].textContent+=" ";var i=this._location.getPathname();this._previousPath=i,this._cacheChildrenWithExternalReferences(t),this._prependPathToReferences(i),this._elementRef.nativeElement.appendChild(t)}},{key:"_clearSvgElement",value:function(){var t=this._elementRef.nativeElement,e=t.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();e--;){var n=t.childNodes[e];1===n.nodeType&&"svg"!==n.nodeName.toLowerCase()||t.removeChild(n)}}},{key:"_updateFontIconClasses",value:function(){if(this._usingFontIcon()){var t=this._elementRef.nativeElement,e=this.fontSet?this._iconRegistry.classNameForFontAlias(this.fontSet):this._iconRegistry.getDefaultFontSetClass();e!=this._previousFontSetClass&&(this._previousFontSetClass&&t.classList.remove(this._previousFontSetClass),e&&t.classList.add(e),this._previousFontSetClass=e),this.fontIcon!=this._previousFontIconClass&&(this._previousFontIconClass&&t.classList.remove(this._previousFontIconClass),this.fontIcon&&t.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}}},{key:"_cleanupFontValue",value:function(t){return"string"==typeof t?t.trim().split(" ")[0]:t}},{key:"_prependPathToReferences",value:function(t){var e=this._elementsWithExternalReferences;e&&e.forEach((function(e,n){e.forEach((function(e){n.setAttribute(e.name,"url('".concat(t,"#").concat(e.value,"')"))}))}))}},{key:"_cacheChildrenWithExternalReferences",value:function(t){for(var e=t.querySelectorAll(C2),n=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map,i=function(t){k2.forEach((function(i){var r=e[t],o=r.getAttribute(i),a=o?o.match(S2):null;if(a){var s=n.get(r);s||n.set(r,s=[]),s.push({name:i,value:a[1]})}}))},r=0;r<e.length;r++)i(r)}},{key:"inline",get:function(){return this._inline},set:function(t){this._inline=nm(t)}},{key:"fontSet",get:function(){return this._fontSet},set:function(t){this._fontSet=this._cleanupFontValue(t)}},{key:"fontIcon",get:function(){return this._fontIcon},set:function(t){this._fontIcon=this._cleanupFontValue(t)}}]),n}(_2);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(g2),fa("aria-hidden"),da(w2),da(Gn))},t.\u0275cmp=Ht({type:t,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:4,hostBindings:function(t,e){2&t&&Qa("mat-icon-inline",e.inline)("mat-icon-no-color","primary"!==e.color&&"accent"!==e.color&&"warn"!==e.color)},inputs:{color:"color",inline:"inline",fontSet:"fontSet",fontIcon:"fontIcon",svgIcon:"svgIcon"},exportAs:["matIcon"],features:[ws,Ms],ngContentSelectors:h2,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),Da(0))},styles:[".mat-icon{background-repeat:no-repeat;display:inline-block;fill:currentColor;height:24px;width:24px}.mat-icon.mat-icon-inline{font-size:inherit;height:inherit;line-height:inherit;width:inherit}[dir=rtl] .mat-icon-rtl-mirror{transform:scale(-1, 1)}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon{display:block}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon{margin:auto}\n"],encapsulation:2,changeDetection:0}),t}(),O2=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[$$],$$]}),t}(),M2=function(){function t(t){this.dialog=t}return t.prototype.showNode=function(){var t=this.dialog.open(u2,{width:"600px",maxHeight:"600px",autoFocus:!1,disableClose:!0}).componentInstance;t.node=this.node,t.server=this.server},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-show-node-action"]],inputs:{node:"node",server:"server"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.showNode()})),ga(1,"mat-icon"),ds(2,"info"),va(),ga(3,"span"),ds(4,"Show node information"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),T2=function(){function t(){}return t.prototype.getConsoleTypes=function(){return["telnet","none"]},t.prototype.getCategories=function(){return[["Default","guest"],["Routers","routers"],["Switches","switches"],["End devices","end_devices"],["Security devices","security_devices"]]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),E2=function(){function t(t){this.httpServer=t}return t.prototype.getNodeById=function(t,e,n){return this.httpServer.get(t,"/projects/"+e+"/nodes/"+n)},t.prototype.start=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/"+e.node_id+"/start",{})},t.prototype.startAll=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/start",{})},t.prototype.stop=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/"+e.node_id+"/stop",{})},t.prototype.stopAll=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/stop",{})},t.prototype.suspend=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/"+e.node_id+"/suspend",{})},t.prototype.suspendAll=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/suspend",{})},t.prototype.reload=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/"+e.node_id+"/reload",{})},t.prototype.reloadAll=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/reload",{})},t.prototype.createFromTemplate=function(t,e,n,i,r,o){return this.httpServer.post(t,"/projects/"+e.project_id+"/templates/"+n.template_id,o?{x:Math.round(i),y:Math.round(r),compute_id:o}:{x:Math.round(i),y:Math.round(r),compute_id:"local"})},t.prototype.updatePosition=function(t,e,n,i,r){var o=Math.round(i),a=Math.round(r);return e.snap_to_grid&&(o=Math.round((o+n.width/2)/e.grid_size)*e.grid_size,a=Math.round((a+n.height/2)/e.grid_size)*e.grid_size,o=Math.round(o-n.width/2),a=Math.round(a-n.height/2)),this.httpServer.put(t,"/projects/"+n.project_id+"/nodes/"+n.node_id,{x:o,y:a})},t.prototype.updateLabel=function(t,e,n){return this.httpServer.put(t,"/projects/"+e.project_id+"/nodes/"+e.node_id,{label:{rotation:n.rotation,style:n.style,text:n.text,x:Math.round(n.x),y:Math.round(n.y)}})},t.prototype.updateSymbol=function(t,e,n){return this.httpServer.put(t,"/projects/"+e.project_id+"/nodes/"+e.node_id,{symbol:n})},t.prototype.update=function(t,e){return this.httpServer.put(t,"/projects/"+e.project_id+"/nodes/"+e.node_id,{x:Math.round(e.x),y:Math.round(e.y),z:e.z})},t.prototype.updateNode=function(t,e){return this.httpServer.put(t,"/projects/"+e.project_id+"/nodes/"+e.node_id,{console_type:e.console_type,console_auto_start:e.console_auto_start,locked:e.locked,name:e.name,properties:e.properties})},t.prototype.updateNodeWithCustomAdapters=function(t,e){return this.httpServer.put(t,"/projects/"+e.project_id+"/nodes/"+e.node_id,{console_type:e.console_type,console_auto_start:e.console_auto_start,custom_adapters:e.custom_adapters,name:e.name,properties:e.properties})},t.prototype.delete=function(t,e){return this.httpServer.delete(t,"/projects/"+e.project_id+"/nodes/"+e.node_id)},t.prototype.duplicate=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/"+e.node_id+"/duplicate",{x:e.x+10,y:e.y+10,z:e.z})},t.prototype.getNode=function(t,e){return this.httpServer.get(t,"/projects/"+e.project_id+"/nodes/"+e.node_id)},t.prototype.getDefaultCommand=function(){return'putty.exe -telnet %h %p -wt "%d" -gns3 5 -skin 4'},t.prototype.getNetworkConfiguration=function(t,e){return this.httpServer.get(t,"/projects/"+e.project_id+"/nodes/"+e.node_id+"/files/etc/network/interfaces",{responseType:"text"})},t.prototype.saveNetworkConfiguration=function(t,e,n){return this.httpServer.post(t,"/projects/"+e.project_id+"/nodes/"+e.node_id+"/files/etc/network/interfaces",n)},t.prototype.getStartupConfiguration=function(t,e){var n="/projects/"+e.project_id+"/nodes/"+e.node_id;return"vpcs"===e.node_type?n+="/files/startup.vpc":"iou"===e.node_type?n+="/files/startup-config.cfg":"dynamips"===e.node_type&&(n+="/files/configs/i"+e.node_id+"_startup-config.cfg"),this.httpServer.get(t,n,{responseType:"text"})},t.prototype.getPrivateConfiguration=function(t,e){var n="/projects/"+e.project_id+"/nodes/"+e.node_id;return"iou"===e.node_type?n+="/files/private-config.cfg":"dynamips"===e.node_type&&(n+="/files/configs/i"+e.node_id+"_private-config.cfg"),this.httpServer.get(t,n,{responseType:"text"})},t.prototype.saveConfiguration=function(t,e,n){var i="/projects/"+e.project_id+"/nodes/"+e.node_id;return"vpcs"===e.node_type?i+="/files/startup.vpc":"iou"===e.node_type?i+="/files/startup-config.cfg":"dynamips"===e.node_type&&(i+="/files/configs/i"+e.node_id+"_startup-config.cfg"),this.httpServer.post(t,i,n)},t.prototype.savePrivateConfiguration=function(t,e,n){var i="/projects/"+e.project_id+"/nodes/"+e.node_id;return"iou"===e.node_type?i+="/files/private-config.cfg":"dynamips"===e.node_type&&(i+="/files/configs/i"+e.node_id+"_private-config.cfg"),this.httpServer.post(t,i,n)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),P2=n("GyhO"),A2=n("zP0r"),j2=new Set,I2=function(){var t=function(){function t(e){Object(m.a)(this,t),this._platform=e,this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):D2}return Object(g.a)(t,[{key:"matchMedia",value:function(t){return this._platform.WEBKIT&&function(t){if(!j2.has(t))try{y2||((y2=document.createElement("style")).setAttribute("type","text/css"),document.head.appendChild(y2)),y2.sheet&&(y2.sheet.insertRule("@media ".concat(t," {.fx-query-test{ }}"),0),j2.add(t))}catch(e){console.error(e)}}(t),this._matchMedia(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Cm))},t.\u0275prov=R({factory:function(){return new t(_t(Cm))},token:t,providedIn:"root"}),t}();function D2(t){return{matches:"all"===t||""===t,media:t,addListener:function(){},removeListener:function(){}}}var R2=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._mediaMatcher=e,this._zone=n,this._queries=new Map,this._destroySubject=new w.b}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this._destroySubject.next(),this._destroySubject.complete()}},{key:"isMatched",value:function(t){var e=this;return L2(om(t)).some((function(t){return e._registerQuery(t).mql.matches}))}},{key:"observe",value:function(t){var e=this,n=L2(om(t)).map((function(t){return e._registerQuery(t).observable})),i=Object(OX.b)(n);return(i=Object(P2.a)(i.pipe(Object(FX.a)(1)),i.pipe(Object(A2.a)(1),Object(t$.a)(0)))).pipe(Object(ef.a)((function(t){var e={matches:!1,breakpoints:{}};return t.forEach((function(t){e.matches=e.matches||t.matches,e.breakpoints[t.query]=t.matches})),e})))}},{key:"_registerQuery",value:function(t){var e=this;if(this._queries.has(t))return this._queries.get(t);var n=this._mediaMatcher.matchMedia(t),i={observable:new k.a((function(t){var i=function(n){return e._zone.run((function(){return t.next(n)}))};return n.addListener(i),function(){n.removeListener(i)}})).pipe(Object(NX.a)(n),Object(ef.a)((function(e){return{query:t,matches:e.matches}})),Object(Am.a)(this._destroySubject)),mql:n};return this._queries.set(t,i),i}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(I2),_t(jl))},t.\u0275prov=R({factory:function(){return new t(_t(I2),_t(jl))},token:t,providedIn:"root"}),t}();function L2(t){return t.map((function(t){return t.split(",")})).reduce((function(t,e){return t.concat(e)})).map((function(t){return t.trim()}))}function F2(t,e){if(1&t){var n=ka();ga(0,"div",1),ga(1,"button",2),xa("click",(function(){return Se(n),Aa().action()})),ds(2),va(),va()}if(2&t){var i=Aa();Qi(2),fs(i.data.action)}}function N2(t,e){}var B2=Math.pow(2,31)-1,H2=function(){function t(e,n){var i=this;Object(m.a)(this,t),this._overlayRef=n,this._afterDismissed=new w.b,this._afterOpened=new w.b,this._onAction=new w.b,this._dismissedByAction=!1,this.containerInstance=e,this.onAction().subscribe((function(){return i.dismiss()})),e._onExit.subscribe((function(){return i._finishDismiss()}))}return Object(g.a)(t,[{key:"dismiss",value:function(){this._afterDismissed.closed||this.containerInstance.exit(),clearTimeout(this._durationTimeoutId)}},{key:"dismissWithAction",value:function(){this._onAction.closed||(this._dismissedByAction=!0,this._onAction.next(),this._onAction.complete())}},{key:"closeWithAction",value:function(){this.dismissWithAction()}},{key:"_dismissAfter",value:function(t){var e=this;this._durationTimeoutId=setTimeout((function(){return e.dismiss()}),Math.min(t,B2))}},{key:"_open",value:function(){this._afterOpened.closed||(this._afterOpened.next(),this._afterOpened.complete())}},{key:"_finishDismiss",value:function(){this._overlayRef.dispose(),this._onAction.closed||this._onAction.complete(),this._afterDismissed.next({dismissedByAction:this._dismissedByAction}),this._afterDismissed.complete(),this._dismissedByAction=!1}},{key:"afterDismissed",value:function(){return this._afterDismissed.asObservable()}},{key:"afterOpened",value:function(){return this.containerInstance._onEnter}},{key:"onAction",value:function(){return this._onAction.asObservable()}}]),t}(),z2=new ht("MatSnackBarData"),V2=function t(){Object(m.a)(this,t),this.politeness="assertive",this.announcementMessage="",this.duration=0,this.data=null,this.horizontalPosition="center",this.verticalPosition="bottom"},U2=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this.snackBarRef=e,this.data=n}return Object(g.a)(t,[{key:"action",value:function(){this.snackBarRef.dismissWithAction()}},{key:"hasAction",get:function(){return!!this.data.action}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(H2),da(z2))},t.\u0275cmp=Ht({type:t,selectors:[["simple-snack-bar"]],hostAttrs:[1,"mat-simple-snackbar"],decls:3,vars:2,consts:[["class","mat-simple-snackbar-action",4,"ngIf"],[1,"mat-simple-snackbar-action"],["mat-button","",3,"click"]],template:function(t,e){1&t&&(ga(0,"span"),ds(1),va(),ua(2,F2,3,1,"div",0)),2&t&&(Qi(1),fs(e.data.message),Qi(1),pa("ngIf",e.hasAction))},directives:[Ah,a2],styles:[".mat-simple-snackbar{display:flex;justify-content:space-between;align-items:center;line-height:20px;opacity:1}.mat-simple-snackbar-action{flex-shrink:0;margin:-8px -8px -8px 8px}.mat-simple-snackbar-action button{max-height:36px;min-width:0}[dir=rtl] .mat-simple-snackbar-action{margin-left:-8px;margin-right:8px}\n"],encapsulation:2,changeDetection:0}),t}(),q2={snackBarState:Jg("state",[rv("void, hidden",iv({transform:"scale(0.8)",opacity:0})),rv("visible",iv({transform:"scale(1)",opacity:1})),av("* => visible",tv("150ms cubic-bezier(0, 0, 0.2, 1)")),av("* => void, * => hidden",tv("75ms cubic-bezier(0.4, 0.0, 1, 1)",iv({opacity:0})))])},G2=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this))._ngZone=t,a._elementRef=i,a._changeDetectorRef=r,a.snackBarConfig=o,a._destroyed=!1,a._onExit=new w.b,a._onEnter=new w.b,a._animationState="void",a.attachDomPortal=function(t){return a._assertNotAttached(),a._applySnackBarClasses(),a._portalOutlet.attachDomPortal(t)},a._role="assertive"!==o.politeness||o.announcementMessage?"off"===o.politeness?null:"status":"alert",a}return Object(g.a)(n,[{key:"attachComponentPortal",value:function(t){return this._assertNotAttached(),this._applySnackBarClasses(),this._portalOutlet.attachComponentPortal(t)}},{key:"attachTemplatePortal",value:function(t){return this._assertNotAttached(),this._applySnackBarClasses(),this._portalOutlet.attachTemplatePortal(t)}},{key:"onAnimationEnd",value:function(t){var e=t.toState;if(("void"===e&&"void"!==t.fromState||"hidden"===e)&&this._completeExit(),"visible"===e){var n=this._onEnter;this._ngZone.run((function(){n.next(),n.complete()}))}}},{key:"enter",value:function(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.detectChanges())}},{key:"exit",value:function(){return this._animationState="hidden",this._elementRef.nativeElement.setAttribute("mat-exit",""),this._onExit}},{key:"ngOnDestroy",value:function(){this._destroyed=!0,this._completeExit()}},{key:"_completeExit",value:function(){var t=this;this._ngZone.onMicrotaskEmpty.asObservable().pipe(Object(FX.a)(1)).subscribe((function(){t._onExit.next(),t._onExit.complete()}))}},{key:"_applySnackBarClasses",value:function(){var t=this._elementRef.nativeElement,e=this.snackBarConfig.panelClass;e&&(Array.isArray(e)?e.forEach((function(e){return t.classList.add(e)})):t.classList.add(e)),"center"===this.snackBarConfig.horizontalPosition&&t.classList.add("mat-snack-bar-center"),"top"===this.snackBarConfig.verticalPosition&&t.classList.add("mat-snack-bar-top")}},{key:"_assertNotAttached",value:function(){if(this._portalOutlet.hasAttached())throw Error("Attempting to attach snack bar content after content is already attached")}}]),n}(L$);return t.\u0275fac=function(e){return new(e||t)(da(jl),da(Us),da(Po),da(V2))},t.\u0275cmp=Ht({type:t,selectors:[["snack-bar-container"]],viewQuery:function(t,e){var n;1&t&&el(B$,!0),2&t&&tl(n=sl())&&(e._portalOutlet=n.first)},hostAttrs:[1,"mat-snack-bar-container"],hostVars:2,hostBindings:function(t,e){1&t&&Oa("@state.done",(function(t){return e.onAnimationEnd(t)})),2&t&&(oa("role",e._role),ys("@state",e._animationState))},features:[ws],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,e){1&t&&ua(0,N2,0,0,"ng-template",0)},directives:[B$],styles:[".mat-snack-bar-container{border-radius:4px;box-sizing:border-box;display:block;margin:24px;max-width:33vw;min-width:344px;padding:14px 16px;min-height:48px;transform-origin:center}.cdk-high-contrast-active .mat-snack-bar-container{border:solid 1px}.mat-snack-bar-handset{width:100%}.mat-snack-bar-handset .mat-snack-bar-container{margin:8px;max-width:100%;min-width:0;width:100%}\n"],encapsulation:2,data:{animation:[q2.snackBarState]}}),t}(),W2=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[w0,z$,hd,c2,$$],$$]}),t}(),K2=new ht("mat-snack-bar-default-options",{providedIn:"root",factory:function(){return new V2}}),X2=function(){var t=function(){function t(e,n,i,r,o,a){Object(m.a)(this,t),this._overlay=e,this._live=n,this._injector=i,this._breakpointObserver=r,this._parentSnackBar=o,this._defaultConfig=a,this._snackBarRefAtThisLevel=null}return Object(g.a)(t,[{key:"openFromComponent",value:function(t,e){return this._attach(t,e)}},{key:"openFromTemplate",value:function(t,e){return this._attach(t,e)}},{key:"open",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2?arguments[2]:void 0,i=Object.assign(Object.assign({},this._defaultConfig),n);return i.data={message:t,action:e},i.announcementMessage||(i.announcementMessage=t),this.openFromComponent(U2,i)}},{key:"dismiss",value:function(){this._openedSnackBarRef&&this._openedSnackBarRef.dismiss()}},{key:"ngOnDestroy",value:function(){this._snackBarRefAtThisLevel&&this._snackBarRefAtThisLevel.dismiss()}},{key:"_attachSnackBarContainer",value:function(t,e){var n=new V$(e&&e.viewContainerRef&&e.viewContainerRef.injector||this._injector,new WeakMap([[V2,e]])),i=new I$(G2,e.viewContainerRef,n),r=t.attach(i);return r.instance.snackBarConfig=e,r.instance}},{key:"_attach",value:function(t,e){var n=Object.assign(Object.assign(Object.assign({},new V2),this._defaultConfig),e),i=this._createOverlay(n),r=this._attachSnackBarContainer(i,n),o=new H2(r,i);if(t instanceof fc){var a=new D$(t,null,{$implicit:n.data,snackBarRef:o});o.instance=r.attachTemplatePortal(a)}else{var s=this._createInjector(n,o),c=new I$(t,void 0,s),l=r.attachComponentPortal(c);o.instance=l.instance}return this._breakpointObserver.observe("(max-width: 599.99px) and (orientation: portrait)").pipe(Object(Am.a)(i.detachments())).subscribe((function(t){var e=i.overlayElement.classList;t.matches?e.add("mat-snack-bar-handset"):e.remove("mat-snack-bar-handset")})),this._animateSnackBar(o,n),this._openedSnackBarRef=o,this._openedSnackBarRef}},{key:"_animateSnackBar",value:function(t,e){var n=this;t.afterDismissed().subscribe((function(){n._openedSnackBarRef==t&&(n._openedSnackBarRef=null),e.announcementMessage&&n._live.clear()})),this._openedSnackBarRef?(this._openedSnackBarRef.afterDismissed().subscribe((function(){t.containerInstance.enter()})),this._openedSnackBarRef.dismiss()):t.containerInstance.enter(),e.duration&&e.duration>0&&t.afterOpened().subscribe((function(){return t._dismissAfter(e.duration)})),e.announcementMessage&&this._live.announce(e.announcementMessage,e.politeness)}},{key:"_createOverlay",value:function(t){var e=new $J;e.direction=t.direction;var n=this._overlay.position().global(),i="rtl"===t.direction,r="left"===t.horizontalPosition||"start"===t.horizontalPosition&&!i||"end"===t.horizontalPosition&&i,o=!r&&"center"!==t.horizontalPosition;return r?n.left("0"):o?n.right("0"):n.centerHorizontally(),"top"===t.verticalPosition?n.top("0"):n.bottom("0"),e.positionStrategy=n,this._overlay.create(e)}},{key:"_createInjector",value:function(t,e){return new V$(t&&t.viewContainerRef&&t.viewContainerRef.injector||this._injector,new WeakMap([[H2,e],[z2,t.data]]))}},{key:"_openedSnackBarRef",get:function(){var t=this._parentSnackBar;return t?t._openedSnackBarRef:this._snackBarRefAtThisLevel},set:function(t){this._parentSnackBar?this._parentSnackBar._openedSnackBarRef=t:this._snackBarRefAtThisLevel=t}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(m0),_t(_$),_t(Xo),_t(R2),_t(t,12),_t(K2))},t.\u0275prov=R({factory:function(){return new t(_t(m0),_t(_$),_t(dt),_t(R2),_t(t,12),_t(K2))},token:t,providedIn:W2}),t}(),Y2=function(){function t(t,e){this.snackbar=t,this.zone=e,this.snackBarConfigForSuccess={duration:4e3,panelClass:["snackabar-success"],MatSnackBarHorizontalPosition:"center",MatSnackBarVerticalPosition:"bottom"},this.snackBarConfigForWarning={duration:4e3,panelClass:["snackabar-warning"],MatSnackBarHorizontalPosition:"center",MatSnackBarVerticalPosition:"bottom"},this.snackBarConfigForError={duration:1e4,panelClass:["snackabar-error"],MatSnackBarHorizontalPosition:"center",MatSnackBarVerticalPosition:"bottom"}}return t.prototype.error=function(t){var e=this;this.zone.run((function(){e.snackbar.open(t,"Close",e.snackBarConfigForError)}))},t.prototype.warning=function(t){var e=this;this.zone.run((function(){e.snackbar.open(t,"Close",e.snackBarConfigForWarning)}))},t.prototype.success=function(t){var e=this;this.zone.run((function(){e.snackbar.open(t,"Close",e.snackBarConfigForSuccess)}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(X2),_t(jl))}}),t}(),Z2=["*",[["mat-card-footer"]]],Q2=["*","mat-card-footer"],$2=[[["","mat-card-avatar",""],["","matCardAvatar",""]],[["mat-card-title"],["mat-card-subtitle"],["","mat-card-title",""],["","mat-card-subtitle",""],["","matCardTitle",""],["","matCardSubtitle",""]],"*"],J2=["[mat-card-avatar], [matCardAvatar]","mat-card-title, mat-card-subtitle,\n [mat-card-title], [mat-card-subtitle],\n [matCardTitle], [matCardSubtitle]","*"],t3=[[["mat-card-title"],["mat-card-subtitle"],["","mat-card-title",""],["","mat-card-subtitle",""],["","matCardTitle",""],["","matCardSubtitle",""]],[["img"]],"*"],e3=["mat-card-title, mat-card-subtitle,\n [mat-card-title], [mat-card-subtitle],\n [matCardTitle], [matCardSubtitle]","img","*"],n3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-card-content"],["","mat-card-content",""],["","matCardContent",""]],hostAttrs:[1,"mat-card-content"]}),t}(),i3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-card-title"],["","mat-card-title",""],["","matCardTitle",""]],hostAttrs:[1,"mat-card-title"]}),t}(),r3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-card-subtitle"],["","mat-card-subtitle",""],["","matCardSubtitle",""]],hostAttrs:[1,"mat-card-subtitle"]}),t}(),o3=function(){var t=function t(){Object(m.a)(this,t),this.align="start"};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-card-actions"]],hostAttrs:[1,"mat-card-actions"],hostVars:2,hostBindings:function(t,e){2&t&&Qa("mat-card-actions-align-end","end"===e.align)},inputs:{align:"align"},exportAs:["matCardActions"]}),t}(),a3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-card-footer"]],hostAttrs:[1,"mat-card-footer"]}),t}(),s3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-card-image",""],["","matCardImage",""]],hostAttrs:[1,"mat-card-image"]}),t}(),c3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-card-sm-image",""],["","matCardImageSmall",""]],hostAttrs:[1,"mat-card-sm-image"]}),t}(),l3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-card-md-image",""],["","matCardImageMedium",""]],hostAttrs:[1,"mat-card-md-image"]}),t}(),u3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-card-lg-image",""],["","matCardImageLarge",""]],hostAttrs:[1,"mat-card-lg-image"]}),t}(),h3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-card-xl-image",""],["","matCardImageXLarge",""]],hostAttrs:[1,"mat-card-xl-image"]}),t}(),d3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-card-avatar",""],["","matCardAvatar",""]],hostAttrs:[1,"mat-card-avatar"]}),t}(),f3=function(){var t=function t(e){Object(m.a)(this,t),this._animationMode=e};return t.\u0275fac=function(e){return new(e||t)(da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-card"]],hostAttrs:[1,"mat-card","mat-focus-indicator"],hostVars:2,hostBindings:function(t,e){2&t&&Qa("_mat-animation-noopable","NoopAnimations"===e._animationMode)},exportAs:["matCard"],ngContentSelectors:Q2,decls:2,vars:0,template:function(t,e){1&t&&(Ia(Z2),Da(0),Da(1,1))},styles:[".mat-card{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);display:block;position:relative;padding:16px;border-radius:4px}._mat-animation-noopable.mat-card{transition:none;animation:none}.mat-card .mat-divider-horizontal{position:absolute;left:0;width:100%}[dir=rtl] .mat-card .mat-divider-horizontal{left:auto;right:0}.mat-card .mat-divider-horizontal.mat-divider-inset{position:static;margin:0}[dir=rtl] .mat-card .mat-divider-horizontal.mat-divider-inset{margin-right:0}.cdk-high-contrast-active .mat-card{outline:solid 1px}.mat-card-actions,.mat-card-subtitle,.mat-card-content{display:block;margin-bottom:16px}.mat-card-title{display:block;margin-bottom:8px}.mat-card-actions{margin-left:-8px;margin-right:-8px;padding:8px 0}.mat-card-actions-align-end{display:flex;justify-content:flex-end}.mat-card-image{width:calc(100% + 32px);margin:0 -16px 16px -16px}.mat-card-footer{display:block;margin:0 -16px -16px -16px}.mat-card-actions .mat-button,.mat-card-actions .mat-raised-button,.mat-card-actions .mat-stroked-button{margin:0 8px}.mat-card-header{display:flex;flex-direction:row}.mat-card-header .mat-card-title{margin-bottom:12px}.mat-card-header-text{margin:0 16px}.mat-card-avatar{height:40px;width:40px;border-radius:50%;flex-shrink:0;object-fit:cover}.mat-card-title-group{display:flex;justify-content:space-between}.mat-card-sm-image{width:80px;height:80px}.mat-card-md-image{width:112px;height:112px}.mat-card-lg-image{width:152px;height:152px}.mat-card-xl-image{width:240px;height:240px;margin:-8px}.mat-card-title-group>.mat-card-xl-image{margin:-8px 0 8px}@media(max-width: 599px){.mat-card-title-group{margin:0}.mat-card-xl-image{margin-left:0;margin-right:0}}.mat-card>:first-child,.mat-card-content>:first-child{margin-top:0}.mat-card>:last-child:not(.mat-card-footer),.mat-card-content>:last-child:not(.mat-card-footer){margin-bottom:0}.mat-card-image:first-child{margin-top:-16px;border-top-left-radius:inherit;border-top-right-radius:inherit}.mat-card>.mat-card-actions:last-child{margin-bottom:-8px;padding-bottom:0}.mat-card-actions .mat-button:first-child,.mat-card-actions .mat-raised-button:first-child,.mat-card-actions .mat-stroked-button:first-child{margin-left:0;margin-right:0}.mat-card-title:not(:first-child),.mat-card-subtitle:not(:first-child){margin-top:-4px}.mat-card-header .mat-card-subtitle:not(:first-child){margin-top:-8px}.mat-card>.mat-card-xl-image:first-child{margin-top:-8px}.mat-card>.mat-card-xl-image:last-child{margin-bottom:-8px}\n"],encapsulation:2,changeDetection:0}),t}(),p3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-card-header"]],hostAttrs:[1,"mat-card-header"],ngContentSelectors:J2,decls:4,vars:0,consts:[[1,"mat-card-header-text"]],template:function(t,e){1&t&&(Ia($2),Da(0),ga(1,"div",0),Da(2,1),va(),Da(3,2))},encapsulation:2,changeDetection:0}),t}(),m3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-card-title-group"]],hostAttrs:[1,"mat-card-title-group"],ngContentSelectors:e3,decls:4,vars:0,template:function(t,e){1&t&&(Ia(t3),ga(0,"div"),Da(1),va(),Da(2,1),Da(3,2))},encapsulation:2,changeDetection:0}),t}(),g3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[$$],$$]}),t}(),v3=["underline"],b3=["connectionContainer"],y3=["inputContainer"],_3=["label"];function w3(t,e){1&t&&(ya(0),ga(1,"div",14),ba(2,"div",15),ba(3,"div",16),ba(4,"div",17),va(),ga(5,"div",18),ba(6,"div",15),ba(7,"div",16),ba(8,"div",17),va(),_a())}function k3(t,e){1&t&&(ga(0,"div",19),Da(1,1),va())}function C3(t,e){if(1&t&&(ya(0),Da(1,2),ga(2,"span"),ds(3),va(),_a()),2&t){var n=Aa(2);Qi(3),fs(n._control.placeholder)}}function S3(t,e){1&t&&Da(0,3,["*ngSwitchCase","true"])}function x3(t,e){1&t&&(ga(0,"span",23),ds(1," *"),va())}function O3(t,e){if(1&t){var n=ka();ga(0,"label",20,21),xa("cdkObserveContent",(function(){return Se(n),Aa().updateOutlineGap()})),ua(2,C3,4,1,"ng-container",12),ua(3,S3,1,0,void 0,12),ua(4,x3,2,0,"span",22),va()}if(2&t){var i=Aa();Qa("mat-empty",i._control.empty&&!i._shouldAlwaysFloat)("mat-form-field-empty",i._control.empty&&!i._shouldAlwaysFloat)("mat-accent","accent"==i.color)("mat-warn","warn"==i.color),pa("cdkObserveContentDisabled","outline"!=i.appearance)("id",i._labelId)("ngSwitch",i._hasLabel()),oa("for",i._control.id)("aria-owns",i._control.id),Qi(2),pa("ngSwitchCase",!1),Qi(1),pa("ngSwitchCase",!0),Qi(1),pa("ngIf",!i.hideRequiredMarker&&i._control.required&&!i._control.disabled)}}function M3(t,e){1&t&&(ga(0,"div",24),Da(1,4),va())}function T3(t,e){if(1&t&&(ga(0,"div",25,26),ba(2,"span",27),va()),2&t){var n=Aa();Qi(2),Qa("mat-accent","accent"==n.color)("mat-warn","warn"==n.color)}}function E3(t,e){1&t&&(ga(0,"div"),Da(1,5),va()),2&t&&pa("@transitionMessages",Aa()._subscriptAnimationState)}function P3(t,e){if(1&t&&(ga(0,"div",31),ds(1),va()),2&t){var n=Aa(2);pa("id",n._hintLabelId),Qi(1),fs(n.hintLabel)}}function A3(t,e){if(1&t&&(ga(0,"div",28),ua(1,P3,2,2,"div",29),Da(2,6),ba(3,"div",30),Da(4,7),va()),2&t){var n=Aa();pa("@transitionMessages",n._subscriptAnimationState),Qi(1),pa("ngIf",n.hintLabel)}}var j3=["*",[["","matPrefix",""]],[["mat-placeholder"]],[["mat-label"]],[["","matSuffix",""]],[["mat-error"]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],I3=["*","[matPrefix]","mat-placeholder","mat-label","[matSuffix]","mat-error","mat-hint:not([align='end'])","mat-hint[align='end']"],D3=0,R3=function(){var t=function t(){Object(m.a)(this,t),this.id="mat-error-".concat(D3++)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-error"]],hostAttrs:["role","alert",1,"mat-error"],hostVars:1,hostBindings:function(t,e){2&t&&oa("id",e.id)},inputs:{id:"id"}}),t}(),L3={transitionMessages:Jg("transitionMessages",[rv("enter",iv({opacity:1,transform:"translateY(0%)"})),av("void => enter",[iv({opacity:0,transform:"translateY(-100%)"}),tv("300ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])},F3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t}),t}();function N3(t){return Error("A hint was already declared for 'align=\"".concat(t,"\"'."))}var B3=0,H3=function(){var t=function t(){Object(m.a)(this,t),this.align="start",this.id="mat-hint-".concat(B3++)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-hint"]],hostAttrs:[1,"mat-hint"],hostVars:4,hostBindings:function(t,e){2&t&&(oa("id",e.id)("align",null),Qa("mat-right","end"==e.align))},inputs:{align:"align",id:"id"}}),t}(),z3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-label"]]}),t}(),V3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-placeholder"]]}),t}(),U3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","matPrefix",""]]}),t}(),q3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","matSuffix",""]]}),t}(),G3=0,W3=tJ((function t(e){Object(m.a)(this,t),this._elementRef=e}),"primary"),K3=new ht("MAT_FORM_FIELD_DEFAULT_OPTIONS"),X3=new ht("MatFormField"),Y3=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c,l){var u;return Object(m.a)(this,n),(u=e.call(this,t))._elementRef=t,u._changeDetectorRef=i,u._dir=o,u._defaults=a,u._platform=s,u._ngZone=c,u._outlineGapCalculationNeededImmediately=!1,u._outlineGapCalculationNeededOnStable=!1,u._destroyed=new w.b,u._showAlwaysAnimate=!1,u._subscriptAnimationState="",u._hintLabel="",u._hintLabelId="mat-hint-".concat(G3++),u._labelId="mat-form-field-label-".concat(G3++),u._labelOptions=r||{},u.floatLabel=u._getDefaultFloatLabelState(),u._animationsEnabled="NoopAnimations"!==l,u.appearance=a&&a.appearance?a.appearance:"legacy",u._hideRequiredMarker=!(!a||null==a.hideRequiredMarker)&&a.hideRequiredMarker,u}return Object(g.a)(n,[{key:"getConnectedOverlayOrigin",value:function(){return this._connectionContainerRef||this._elementRef}},{key:"ngAfterContentInit",value:function(){var t=this;this._validateControlChild();var e=this._control;e.controlType&&this._elementRef.nativeElement.classList.add("mat-form-field-type-".concat(e.controlType)),e.stateChanges.pipe(Object(NX.a)(null)).subscribe((function(){t._validatePlaceholders(),t._syncDescribedByIds(),t._changeDetectorRef.markForCheck()})),e.ngControl&&e.ngControl.valueChanges&&e.ngControl.valueChanges.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){return t._changeDetectorRef.markForCheck()})),this._ngZone.runOutsideAngular((function(){t._ngZone.onStable.asObservable().pipe(Object(Am.a)(t._destroyed)).subscribe((function(){t._outlineGapCalculationNeededOnStable&&t.updateOutlineGap()}))})),Object(C.a)(this._prefixChildren.changes,this._suffixChildren.changes).subscribe((function(){t._outlineGapCalculationNeededOnStable=!0,t._changeDetectorRef.markForCheck()})),this._hintChildren.changes.pipe(Object(NX.a)(null)).subscribe((function(){t._processHints(),t._changeDetectorRef.markForCheck()})),this._errorChildren.changes.pipe(Object(NX.a)(null)).subscribe((function(){t._syncDescribedByIds(),t._changeDetectorRef.markForCheck()})),this._dir&&this._dir.change.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){"function"==typeof requestAnimationFrame?t._ngZone.runOutsideAngular((function(){requestAnimationFrame((function(){return t.updateOutlineGap()}))})):t.updateOutlineGap()}))}},{key:"ngAfterContentChecked",value:function(){this._validateControlChild(),this._outlineGapCalculationNeededImmediately&&this.updateOutlineGap()}},{key:"ngAfterViewInit",value:function(){this._subscriptAnimationState="enter",this._changeDetectorRef.detectChanges()}},{key:"ngOnDestroy",value:function(){this._destroyed.next(),this._destroyed.complete()}},{key:"_shouldForward",value:function(t){var e=this._control?this._control.ngControl:null;return e&&e[t]}},{key:"_hasPlaceholder",value:function(){return!!(this._control&&this._control.placeholder||this._placeholderChild)}},{key:"_hasLabel",value:function(){return!!this._labelChild}},{key:"_shouldLabelFloat",value:function(){return this._canLabelFloat&&(this._control.shouldLabelFloat||this._shouldAlwaysFloat)}},{key:"_hideControlPlaceholder",value:function(){return"legacy"===this.appearance&&!this._hasLabel()||this._hasLabel()&&!this._shouldLabelFloat()}},{key:"_hasFloatingLabel",value:function(){return this._hasLabel()||"legacy"===this.appearance&&this._hasPlaceholder()}},{key:"_getDisplayedMessages",value:function(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}},{key:"_animateAndLockLabel",value:function(){var t=this;this._hasFloatingLabel()&&this._canLabelFloat&&(this._animationsEnabled&&this._label&&(this._showAlwaysAnimate=!0,Object(IJ.a)(this._label.nativeElement,"transitionend").pipe(Object(FX.a)(1)).subscribe((function(){t._showAlwaysAnimate=!1}))),this.floatLabel="always",this._changeDetectorRef.markForCheck())}},{key:"_validatePlaceholders",value:function(){if(this._control.placeholder&&this._placeholderChild)throw Error("Placeholder attribute and child element were both specified.")}},{key:"_processHints",value:function(){this._validateHints(),this._syncDescribedByIds()}},{key:"_validateHints",value:function(){var t,e,n=this;this._hintChildren&&this._hintChildren.forEach((function(i){if("start"===i.align){if(t||n.hintLabel)throw N3("start");t=i}else if("end"===i.align){if(e)throw N3("end");e=i}}))}},{key:"_getDefaultFloatLabelState",value:function(){return this._defaults&&this._defaults.floatLabel||this._labelOptions.float||"auto"}},{key:"_syncDescribedByIds",value:function(){if(this._control){var t=[];if("hint"===this._getDisplayedMessages()){var e=this._hintChildren?this._hintChildren.find((function(t){return"start"===t.align})):null,n=this._hintChildren?this._hintChildren.find((function(t){return"end"===t.align})):null;e?t.push(e.id):this._hintLabel&&t.push(this._hintLabelId),n&&t.push(n.id)}else this._errorChildren&&(t=this._errorChildren.map((function(t){return t.id})));this._control.setDescribedByIds(t)}}},{key:"_validateControlChild",value:function(){if(!this._control)throw Error("mat-form-field must contain a MatFormFieldControl.")}},{key:"updateOutlineGap",value:function(){var t=this._label?this._label.nativeElement:null;if("outline"===this.appearance&&t&&t.children.length&&t.textContent.trim()&&this._platform.isBrowser)if(this._isAttachedToDOM()){var e=0,n=0,i=this._connectionContainerRef.nativeElement,r=i.querySelectorAll(".mat-form-field-outline-start"),o=i.querySelectorAll(".mat-form-field-outline-gap");if(this._label&&this._label.nativeElement.children.length){var a=i.getBoundingClientRect();if(0===a.width&&0===a.height)return this._outlineGapCalculationNeededOnStable=!0,void(this._outlineGapCalculationNeededImmediately=!1);for(var s=this._getStartEnd(a),c=t.children,l=this._getStartEnd(c[0].getBoundingClientRect()),u=0,h=0;h<c.length;h++)u+=c[h].offsetWidth;e=Math.abs(l-s)-5,n=u>0?.75*u+10:0}for(var d=0;d<r.length;d++)r[d].style.width="".concat(e,"px");for(var f=0;f<o.length;f++)o[f].style.width="".concat(n,"px");this._outlineGapCalculationNeededOnStable=this._outlineGapCalculationNeededImmediately=!1}else this._outlineGapCalculationNeededImmediately=!0}},{key:"_getStartEnd",value:function(t){return this._dir&&"rtl"===this._dir.value?t.right:t.left}},{key:"_isAttachedToDOM",value:function(){var t=this._elementRef.nativeElement;if(t.getRootNode){var e=t.getRootNode();return e&&e!==t}return document.documentElement.contains(t)}},{key:"appearance",get:function(){return this._appearance},set:function(t){var e=this._appearance;this._appearance=t||this._defaults&&this._defaults.appearance||"legacy","outline"===this._appearance&&e!==t&&(this._outlineGapCalculationNeededOnStable=!0)}},{key:"hideRequiredMarker",get:function(){return this._hideRequiredMarker},set:function(t){this._hideRequiredMarker=nm(t)}},{key:"_shouldAlwaysFloat",get:function(){return"always"===this.floatLabel&&!this._showAlwaysAnimate}},{key:"_canLabelFloat",get:function(){return"never"!==this.floatLabel}},{key:"hintLabel",get:function(){return this._hintLabel},set:function(t){this._hintLabel=t,this._processHints()}},{key:"floatLabel",get:function(){return"legacy"!==this.appearance&&"never"===this._floatLabel?"auto":this._floatLabel},set:function(t){t!==this._floatLabel&&(this._floatLabel=t||this._getDefaultFloatLabelState(),this._changeDetectorRef.markForCheck())}},{key:"_control",get:function(){return this._explicitFormFieldControl||this._controlNonStatic||this._controlStatic},set:function(t){this._explicitFormFieldControl=t}},{key:"_labelChild",get:function(){return this._labelChildNonStatic||this._labelChildStatic}}]),n}(W3);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(jJ,8),da(gm,8),da(K3,8),da(Cm),da(jl),da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-form-field"]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,F3,!0),ol(n,F3,!0),rl(n,z3,!0),ol(n,z3,!0),rl(n,V3,!0),rl(n,R3,!0),rl(n,H3,!0),rl(n,U3,!0),rl(n,q3,!0)),2&t&&(tl(i=sl())&&(e._controlNonStatic=i.first),tl(i=sl())&&(e._controlStatic=i.first),tl(i=sl())&&(e._labelChildNonStatic=i.first),tl(i=sl())&&(e._labelChildStatic=i.first),tl(i=sl())&&(e._placeholderChild=i.first),tl(i=sl())&&(e._errorChildren=i),tl(i=sl())&&(e._hintChildren=i),tl(i=sl())&&(e._prefixChildren=i),tl(i=sl())&&(e._suffixChildren=i))},viewQuery:function(t,e){var n;1&t&&(nl(v3,!0),el(b3,!0),nl(y3,!0),nl(_3,!0)),2&t&&(tl(n=sl())&&(e.underlineRef=n.first),tl(n=sl())&&(e._connectionContainerRef=n.first),tl(n=sl())&&(e._inputContainerRef=n.first),tl(n=sl())&&(e._label=n.first))},hostAttrs:[1,"mat-form-field"],hostVars:44,hostBindings:function(t,e){2&t&&Qa("mat-form-field-appearance-standard","standard"==e.appearance)("mat-form-field-appearance-fill","fill"==e.appearance)("mat-form-field-appearance-outline","outline"==e.appearance)("mat-form-field-appearance-legacy","legacy"==e.appearance)("mat-form-field-invalid",e._control.errorState)("mat-form-field-can-float",e._canLabelFloat)("mat-form-field-should-float",e._shouldLabelFloat())("mat-form-field-has-label",e._hasFloatingLabel())("mat-form-field-hide-placeholder",e._hideControlPlaceholder())("mat-form-field-disabled",e._control.disabled)("mat-form-field-autofilled",e._control.autofilled)("mat-focused",e._control.focused)("mat-accent","accent"==e.color)("mat-warn","warn"==e.color)("ng-untouched",e._shouldForward("untouched"))("ng-touched",e._shouldForward("touched"))("ng-pristine",e._shouldForward("pristine"))("ng-dirty",e._shouldForward("dirty"))("ng-valid",e._shouldForward("valid"))("ng-invalid",e._shouldForward("invalid"))("ng-pending",e._shouldForward("pending"))("_mat-animation-noopable",!e._animationsEnabled)},inputs:{color:"color",floatLabel:"floatLabel",appearance:"appearance",hideRequiredMarker:"hideRequiredMarker",hintLabel:"hintLabel"},exportAs:["matFormField"],features:[Ns([{provide:X3,useExisting:t}]),ws],ngContentSelectors:I3,decls:15,vars:8,consts:[[1,"mat-form-field-wrapper"],[1,"mat-form-field-flex",3,"click"],["connectionContainer",""],[4,"ngIf"],["class","mat-form-field-prefix",4,"ngIf"],[1,"mat-form-field-infix"],["inputContainer",""],[1,"mat-form-field-label-wrapper"],["class","mat-form-field-label",3,"cdkObserveContentDisabled","id","mat-empty","mat-form-field-empty","mat-accent","mat-warn","ngSwitch","cdkObserveContent",4,"ngIf"],["class","mat-form-field-suffix",4,"ngIf"],["class","mat-form-field-underline",4,"ngIf"],[1,"mat-form-field-subscript-wrapper",3,"ngSwitch"],[4,"ngSwitchCase"],["class","mat-form-field-hint-wrapper",4,"ngSwitchCase"],[1,"mat-form-field-outline"],[1,"mat-form-field-outline-start"],[1,"mat-form-field-outline-gap"],[1,"mat-form-field-outline-end"],[1,"mat-form-field-outline","mat-form-field-outline-thick"],[1,"mat-form-field-prefix"],[1,"mat-form-field-label",3,"cdkObserveContentDisabled","id","ngSwitch","cdkObserveContent"],["label",""],["class","mat-placeholder-required mat-form-field-required-marker","aria-hidden","true",4,"ngIf"],["aria-hidden","true",1,"mat-placeholder-required","mat-form-field-required-marker"],[1,"mat-form-field-suffix"],[1,"mat-form-field-underline"],["underline",""],[1,"mat-form-field-ripple"],[1,"mat-form-field-hint-wrapper"],["class","mat-hint",3,"id",4,"ngIf"],[1,"mat-form-field-hint-spacer"],[1,"mat-hint",3,"id"]],template:function(t,e){1&t&&(Ia(j3),ga(0,"div",0),ga(1,"div",1,2),xa("click",(function(t){return e._control.onContainerClick&&e._control.onContainerClick(t)})),ua(3,w3,9,0,"ng-container",3),ua(4,k3,2,0,"div",4),ga(5,"div",5,6),Da(7),ga(8,"span",7),ua(9,O3,5,16,"label",8),va(),va(),ua(10,M3,2,0,"div",9),va(),ua(11,T3,3,4,"div",10),ga(12,"div",11),ua(13,E3,2,1,"div",12),ua(14,A3,5,2,"div",13),va(),va()),2&t&&(Qi(3),pa("ngIf","outline"==e.appearance),Qi(1),pa("ngIf",e._prefixChildren.length),Qi(5),pa("ngIf",e._hasFloatingLabel()),Qi(1),pa("ngIf",e._suffixChildren.length),Qi(1),pa("ngIf","outline"!=e.appearance),Qi(1),pa("ngSwitch",e._getDisplayedMessages()),Qi(1),pa("ngSwitchCase","error"),Qi(1),pa("ngSwitchCase","hint"))},directives:[Ah,Rh,Lh,i$],styles:[".mat-form-field{display:inline-block;position:relative;text-align:left}[dir=rtl] .mat-form-field{text-align:right}.mat-form-field-wrapper{position:relative}.mat-form-field-flex{display:inline-flex;align-items:baseline;box-sizing:border-box;width:100%}.mat-form-field-prefix,.mat-form-field-suffix{white-space:nowrap;flex:none;position:relative}.mat-form-field-infix{display:block;position:relative;flex:auto;min-width:0;width:180px}.cdk-high-contrast-active .mat-form-field-infix{border-image:linear-gradient(transparent, transparent)}.mat-form-field-label-wrapper{position:absolute;left:0;box-sizing:content-box;width:100%;height:100%;overflow:hidden;pointer-events:none}[dir=rtl] .mat-form-field-label-wrapper{left:auto;right:0}.mat-form-field-label{position:absolute;left:0;font:inherit;pointer-events:none;width:100%;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;transform-origin:0 0;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),color 400ms cubic-bezier(0.25, 0.8, 0.25, 1),width 400ms cubic-bezier(0.25, 0.8, 0.25, 1);display:none}[dir=rtl] .mat-form-field-label{transform-origin:100% 0;left:auto;right:0}.mat-form-field-empty.mat-form-field-label,.mat-form-field-can-float.mat-form-field-should-float .mat-form-field-label{display:block}.mat-form-field-autofill-control:-webkit-autofill+.mat-form-field-label-wrapper .mat-form-field-label{display:none}.mat-form-field-can-float .mat-form-field-autofill-control:-webkit-autofill+.mat-form-field-label-wrapper .mat-form-field-label{display:block;transition:none}.mat-input-server:focus+.mat-form-field-label-wrapper .mat-form-field-label,.mat-input-server[placeholder]:not(:placeholder-shown)+.mat-form-field-label-wrapper .mat-form-field-label{display:none}.mat-form-field-can-float .mat-input-server:focus+.mat-form-field-label-wrapper .mat-form-field-label,.mat-form-field-can-float .mat-input-server[placeholder]:not(:placeholder-shown)+.mat-form-field-label-wrapper .mat-form-field-label{display:block}.mat-form-field-label:not(.mat-form-field-empty){transition:none}.mat-form-field-underline{position:absolute;width:100%;pointer-events:none;transform:scale3d(1, 1.0001, 1)}.mat-form-field-ripple{position:absolute;left:0;width:100%;transform-origin:50%;transform:scaleX(0.5);opacity:0;transition:background-color 300ms cubic-bezier(0.55, 0, 0.55, 0.2)}.mat-form-field.mat-focused .mat-form-field-ripple,.mat-form-field.mat-form-field-invalid .mat-form-field-ripple{opacity:1;transform:scaleX(1);transition:transform 300ms cubic-bezier(0.25, 0.8, 0.25, 1),opacity 100ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 300ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-form-field-subscript-wrapper{position:absolute;box-sizing:border-box;width:100%;overflow:hidden}.mat-form-field-subscript-wrapper .mat-icon,.mat-form-field-label-wrapper .mat-icon{width:1em;height:1em;font-size:inherit;vertical-align:baseline}.mat-form-field-hint-wrapper{display:flex}.mat-form-field-hint-spacer{flex:1 0 1em}.mat-error{display:block}.mat-form-field-control-wrapper{position:relative}.mat-form-field._mat-animation-noopable .mat-form-field-label,.mat-form-field._mat-animation-noopable .mat-form-field-ripple{transition:none}\n",'.mat-form-field-appearance-fill .mat-form-field-flex{border-radius:4px 4px 0 0;padding:.75em .75em 0 .75em}.cdk-high-contrast-active .mat-form-field-appearance-fill .mat-form-field-flex{outline:solid 1px}.mat-form-field-appearance-fill .mat-form-field-underline::before{content:"";display:block;position:absolute;bottom:0;height:1px;width:100%}.mat-form-field-appearance-fill .mat-form-field-ripple{bottom:0;height:2px}.cdk-high-contrast-active .mat-form-field-appearance-fill .mat-form-field-ripple{height:0;border-top:solid 2px}.mat-form-field-appearance-fill:not(.mat-form-field-disabled) .mat-form-field-flex:hover~.mat-form-field-underline .mat-form-field-ripple{opacity:1;transform:none;transition:opacity 600ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-form-field-appearance-fill._mat-animation-noopable:not(.mat-form-field-disabled) .mat-form-field-flex:hover~.mat-form-field-underline .mat-form-field-ripple{transition:none}.mat-form-field-appearance-fill .mat-form-field-subscript-wrapper{padding:0 1em}\n','.mat-input-element{font:inherit;background:transparent;color:currentColor;border:none;outline:none;padding:0;margin:0;width:100%;max-width:100%;vertical-align:bottom;text-align:inherit}.mat-input-element:-moz-ui-invalid{box-shadow:none}.mat-input-element::-ms-clear,.mat-input-element::-ms-reveal{display:none}.mat-input-element,.mat-input-element::-webkit-search-cancel-button,.mat-input-element::-webkit-search-decoration,.mat-input-element::-webkit-search-results-button,.mat-input-element::-webkit-search-results-decoration{-webkit-appearance:none}.mat-input-element::-webkit-contacts-auto-fill-button,.mat-input-element::-webkit-caps-lock-indicator,.mat-input-element::-webkit-credentials-auto-fill-button{visibility:hidden}.mat-input-element[type=date],.mat-input-element[type=datetime],.mat-input-element[type=datetime-local],.mat-input-element[type=month],.mat-input-element[type=week],.mat-input-element[type=time]{line-height:1}.mat-input-element[type=date]::after,.mat-input-element[type=datetime]::after,.mat-input-element[type=datetime-local]::after,.mat-input-element[type=month]::after,.mat-input-element[type=week]::after,.mat-input-element[type=time]::after{content:" ";white-space:pre;width:1px}.mat-input-element::-webkit-inner-spin-button,.mat-input-element::-webkit-calendar-picker-indicator,.mat-input-element::-webkit-clear-button{font-size:.75em}.mat-input-element::placeholder{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-input-element::placeholder:-ms-input-placeholder{-ms-user-select:text}.mat-input-element::-moz-placeholder{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-input-element::-moz-placeholder:-ms-input-placeholder{-ms-user-select:text}.mat-input-element::-webkit-input-placeholder{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-input-element::-webkit-input-placeholder:-ms-input-placeholder{-ms-user-select:text}.mat-input-element:-ms-input-placeholder{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-input-element:-ms-input-placeholder:-ms-input-placeholder{-ms-user-select:text}.mat-form-field-hide-placeholder .mat-input-element::placeholder{color:transparent !important;-webkit-text-fill-color:transparent;transition:none}.mat-form-field-hide-placeholder .mat-input-element::-moz-placeholder{color:transparent !important;-webkit-text-fill-color:transparent;transition:none}.mat-form-field-hide-placeholder .mat-input-element::-webkit-input-placeholder{color:transparent !important;-webkit-text-fill-color:transparent;transition:none}.mat-form-field-hide-placeholder .mat-input-element:-ms-input-placeholder{color:transparent !important;-webkit-text-fill-color:transparent;transition:none}textarea.mat-input-element{resize:vertical;overflow:auto}textarea.mat-input-element.cdk-textarea-autosize{resize:none}textarea.mat-input-element{padding:2px 0;margin:-2px 0}select.mat-input-element{-moz-appearance:none;-webkit-appearance:none;position:relative;background-color:transparent;display:inline-flex;box-sizing:border-box;padding-top:1em;top:-1em;margin-bottom:-1em}select.mat-input-element::-ms-expand{display:none}select.mat-input-element::-moz-focus-inner{border:0}select.mat-input-element:not(:disabled){cursor:pointer}select.mat-input-element::-ms-value{color:inherit;background:none}.mat-focused .cdk-high-contrast-active select.mat-input-element::-ms-value{color:inherit}.mat-form-field-type-mat-native-select .mat-form-field-infix::after{content:"";width:0;height:0;border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid;position:absolute;top:50%;right:0;margin-top:-2.5px;pointer-events:none}[dir=rtl] .mat-form-field-type-mat-native-select .mat-form-field-infix::after{right:auto;left:0}.mat-form-field-type-mat-native-select .mat-input-element{padding-right:15px}[dir=rtl] .mat-form-field-type-mat-native-select .mat-input-element{padding-right:0;padding-left:15px}.mat-form-field-type-mat-native-select .mat-form-field-label-wrapper{max-width:calc(100% - 10px)}.mat-form-field-type-mat-native-select.mat-form-field-appearance-outline .mat-form-field-infix::after{margin-top:-5px}.mat-form-field-type-mat-native-select.mat-form-field-appearance-fill .mat-form-field-infix::after{margin-top:-10px}\n',".mat-form-field-appearance-legacy .mat-form-field-label{transform:perspective(100px);-ms-transform:none}.mat-form-field-appearance-legacy .mat-form-field-prefix .mat-icon,.mat-form-field-appearance-legacy .mat-form-field-suffix .mat-icon{width:1em}.mat-form-field-appearance-legacy .mat-form-field-prefix .mat-icon-button,.mat-form-field-appearance-legacy .mat-form-field-suffix .mat-icon-button{font:inherit;vertical-align:baseline}.mat-form-field-appearance-legacy .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field-appearance-legacy .mat-form-field-suffix .mat-icon-button .mat-icon{font-size:inherit}.mat-form-field-appearance-legacy .mat-form-field-underline{height:1px}.cdk-high-contrast-active .mat-form-field-appearance-legacy .mat-form-field-underline{height:0;border-top:solid 1px}.mat-form-field-appearance-legacy .mat-form-field-ripple{top:0;height:2px;overflow:hidden}.cdk-high-contrast-active .mat-form-field-appearance-legacy .mat-form-field-ripple{height:0;border-top:solid 2px}.mat-form-field-appearance-legacy.mat-form-field-disabled .mat-form-field-underline{background-position:0;background-color:transparent}.cdk-high-contrast-active .mat-form-field-appearance-legacy.mat-form-field-disabled .mat-form-field-underline{border-top-style:dotted;border-top-width:2px}.mat-form-field-appearance-legacy.mat-form-field-invalid:not(.mat-focused) .mat-form-field-ripple{height:1px}\n",".mat-form-field-appearance-outline .mat-form-field-wrapper{margin:.25em 0}.mat-form-field-appearance-outline .mat-form-field-flex{padding:0 .75em 0 .75em;margin-top:-0.25em;position:relative}.mat-form-field-appearance-outline .mat-form-field-prefix,.mat-form-field-appearance-outline .mat-form-field-suffix{top:.25em}.mat-form-field-appearance-outline .mat-form-field-outline{display:flex;position:absolute;top:.25em;left:0;right:0;bottom:0;pointer-events:none}.mat-form-field-appearance-outline .mat-form-field-outline-start,.mat-form-field-appearance-outline .mat-form-field-outline-end{border:1px solid currentColor;min-width:5px}.mat-form-field-appearance-outline .mat-form-field-outline-start{border-radius:5px 0 0 5px;border-right-style:none}[dir=rtl] .mat-form-field-appearance-outline .mat-form-field-outline-start{border-right-style:solid;border-left-style:none;border-radius:0 5px 5px 0}.mat-form-field-appearance-outline .mat-form-field-outline-end{border-radius:0 5px 5px 0;border-left-style:none;flex-grow:1}[dir=rtl] .mat-form-field-appearance-outline .mat-form-field-outline-end{border-left-style:solid;border-right-style:none;border-radius:5px 0 0 5px}.mat-form-field-appearance-outline .mat-form-field-outline-gap{border-radius:.000001px;border:1px solid currentColor;border-left-style:none;border-right-style:none}.mat-form-field-appearance-outline.mat-form-field-can-float.mat-form-field-should-float .mat-form-field-outline-gap{border-top-color:transparent}.mat-form-field-appearance-outline .mat-form-field-outline-thick{opacity:0}.mat-form-field-appearance-outline .mat-form-field-outline-thick .mat-form-field-outline-start,.mat-form-field-appearance-outline .mat-form-field-outline-thick .mat-form-field-outline-end,.mat-form-field-appearance-outline .mat-form-field-outline-thick .mat-form-field-outline-gap{border-width:2px}.mat-form-field-appearance-outline.mat-focused .mat-form-field-outline,.mat-form-field-appearance-outline.mat-form-field-invalid .mat-form-field-outline{opacity:0;transition:opacity 100ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-form-field-appearance-outline.mat-focused .mat-form-field-outline-thick,.mat-form-field-appearance-outline.mat-form-field-invalid .mat-form-field-outline-thick{opacity:1}.mat-form-field-appearance-outline:not(.mat-form-field-disabled) .mat-form-field-flex:hover .mat-form-field-outline{opacity:0;transition:opacity 600ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-form-field-appearance-outline:not(.mat-form-field-disabled) .mat-form-field-flex:hover .mat-form-field-outline-thick{opacity:1}.mat-form-field-appearance-outline .mat-form-field-subscript-wrapper{padding:0 1em}.mat-form-field-appearance-outline._mat-animation-noopable:not(.mat-form-field-disabled) .mat-form-field-flex:hover~.mat-form-field-outline,.mat-form-field-appearance-outline._mat-animation-noopable .mat-form-field-outline,.mat-form-field-appearance-outline._mat-animation-noopable .mat-form-field-outline-start,.mat-form-field-appearance-outline._mat-animation-noopable .mat-form-field-outline-end,.mat-form-field-appearance-outline._mat-animation-noopable .mat-form-field-outline-gap{transition:none}\n",".mat-form-field-appearance-standard .mat-form-field-flex{padding-top:.75em}.mat-form-field-appearance-standard .mat-form-field-underline{height:1px}.cdk-high-contrast-active .mat-form-field-appearance-standard .mat-form-field-underline{height:0;border-top:solid 1px}.mat-form-field-appearance-standard .mat-form-field-ripple{bottom:0;height:2px}.cdk-high-contrast-active .mat-form-field-appearance-standard .mat-form-field-ripple{height:0;border-top:2px}.mat-form-field-appearance-standard.mat-form-field-disabled .mat-form-field-underline{background-position:0;background-color:transparent}.cdk-high-contrast-active .mat-form-field-appearance-standard.mat-form-field-disabled .mat-form-field-underline{border-top-style:dotted;border-top-width:2px}.mat-form-field-appearance-standard:not(.mat-form-field-disabled) .mat-form-field-flex:hover~.mat-form-field-underline .mat-form-field-ripple{opacity:1;transform:none;transition:opacity 600ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-form-field-appearance-standard._mat-animation-noopable:not(.mat-form-field-disabled) .mat-form-field-flex:hover~.mat-form-field-underline .mat-form-field-ripple{transition:none}\n"],encapsulation:2,data:{animation:[L3.transitionMessages]},changeDetection:0}),t}(),Z3=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd,$$,r$],$$]}),t}(),Q3=Mm({passive:!0}),$3=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._platform=e,this._ngZone=n,this._monitoredElements=new Map}return Object(g.a)(t,[{key:"monitor",value:function(t){var e=this;if(!this._platform.isBrowser)return TX.a;var n=sm(t),i=this._monitoredElements.get(n);if(i)return i.subject.asObservable();var r=new w.b,o="cdk-text-field-autofilled",a=function(t){"cdk-text-field-autofill-start"!==t.animationName||n.classList.contains(o)?"cdk-text-field-autofill-end"===t.animationName&&n.classList.contains(o)&&(n.classList.remove(o),e._ngZone.run((function(){return r.next({target:t.target,isAutofilled:!1})}))):(n.classList.add(o),e._ngZone.run((function(){return r.next({target:t.target,isAutofilled:!0})})))};return this._ngZone.runOutsideAngular((function(){n.addEventListener("animationstart",a,Q3),n.classList.add("cdk-text-field-autofill-monitored")})),this._monitoredElements.set(n,{subject:r,unlisten:function(){n.removeEventListener("animationstart",a,Q3)}}),r.asObservable()}},{key:"stopMonitoring",value:function(t){var e=sm(t),n=this._monitoredElements.get(e);n&&(n.unlisten(),n.subject.complete(),e.classList.remove("cdk-text-field-autofill-monitored"),e.classList.remove("cdk-text-field-autofilled"),this._monitoredElements.delete(e))}},{key:"ngOnDestroy",value:function(){var t=this;this._monitoredElements.forEach((function(e,n){return t.stopMonitoring(n)}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(Cm),_t(jl))},t.\u0275prov=R({factory:function(){return new t(_t(Cm),_t(jl))},token:t,providedIn:"root"}),t}(),J3=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._elementRef=e,this._autofillMonitor=n,this.cdkAutofill=new Uc}return Object(g.a)(t,[{key:"ngOnInit",value:function(){var t=this;this._autofillMonitor.monitor(this._elementRef).subscribe((function(e){return t.cdkAutofill.emit(e)}))}},{key:"ngOnDestroy",value:function(){this._autofillMonitor.stopMonitoring(this._elementRef)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da($3))},t.\u0275dir=Wt({type:t,selectors:[["","cdkAutofill",""]],outputs:{cdkAutofill:"cdkAutofill"}}),t}(),t5=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._elementRef=e,this._platform=n,this._ngZone=i,this._destroyed=new w.b,this._enabled=!0,this._previousMinRows=-1,this._document=r,this._textareaElement=this._elementRef.nativeElement,this._measuringClass=n.FIREFOX?"cdk-textarea-autosize-measuring-firefox":"cdk-textarea-autosize-measuring"}return Object(g.a)(t,[{key:"_setMinHeight",value:function(){var t=this.minRows&&this._cachedLineHeight?"".concat(this.minRows*this._cachedLineHeight,"px"):null;t&&(this._textareaElement.style.minHeight=t)}},{key:"_setMaxHeight",value:function(){var t=this.maxRows&&this._cachedLineHeight?"".concat(this.maxRows*this._cachedLineHeight,"px"):null;t&&(this._textareaElement.style.maxHeight=t)}},{key:"ngAfterViewInit",value:function(){var t=this;this._platform.isBrowser&&(this._initialHeight=this._textareaElement.style.height,this.resizeToFitContent(),this._ngZone.runOutsideAngular((function(){var e=t._getWindow();Object(IJ.a)(e,"resize").pipe(Object(LJ.a)(16),Object(Am.a)(t._destroyed)).subscribe((function(){return t.resizeToFitContent(!0)}))})))}},{key:"ngOnDestroy",value:function(){this._destroyed.next(),this._destroyed.complete()}},{key:"_cacheTextareaLineHeight",value:function(){if(!this._cachedLineHeight){var t=this._textareaElement.cloneNode(!1);t.rows=1,t.style.position="absolute",t.style.visibility="hidden",t.style.border="none",t.style.padding="0",t.style.height="",t.style.minHeight="",t.style.maxHeight="",t.style.overflow="hidden",this._textareaElement.parentNode.appendChild(t),this._cachedLineHeight=t.clientHeight,this._textareaElement.parentNode.removeChild(t),this._setMinHeight(),this._setMaxHeight()}}},{key:"ngDoCheck",value:function(){this._platform.isBrowser&&this.resizeToFitContent()}},{key:"resizeToFitContent",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this._enabled&&(this._cacheTextareaLineHeight(),this._cachedLineHeight)){var n=this._elementRef.nativeElement,i=n.value;if(e||this._minRows!==this._previousMinRows||i!==this._previousValue){var r=n.placeholder;n.classList.add(this._measuringClass),n.placeholder="";var o=n.scrollHeight-4;n.style.height="".concat(o,"px"),n.classList.remove(this._measuringClass),n.placeholder=r,this._ngZone.runOutsideAngular((function(){"undefined"!=typeof requestAnimationFrame?requestAnimationFrame((function(){return t._scrollToCaretPosition(n)})):setTimeout((function(){return t._scrollToCaretPosition(n)}))})),this._previousValue=i,this._previousMinRows=this._minRows}}}},{key:"reset",value:function(){void 0!==this._initialHeight&&(this._textareaElement.style.height=this._initialHeight)}},{key:"_noopInputHandler",value:function(){}},{key:"_getDocument",value:function(){return this._document||document}},{key:"_getWindow",value:function(){return this._getDocument().defaultView||window}},{key:"_scrollToCaretPosition",value:function(t){var e=t.selectionStart,n=t.selectionEnd,i=this._getDocument();this._destroyed.isStopped||i.activeElement!==t||t.setSelectionRange(e,n)}},{key:"minRows",get:function(){return this._minRows},set:function(t){this._minRows=im(t),this._setMinHeight()}},{key:"maxRows",get:function(){return this._maxRows},set:function(t){this._maxRows=im(t),this._setMaxHeight()}},{key:"enabled",get:function(){return this._enabled},set:function(t){t=nm(t),this._enabled!==t&&((this._enabled=t)?this.resizeToFitContent(!0):this.reset())}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Cm),da(jl),da(du,8))},t.\u0275dir=Wt({type:t,selectors:[["textarea","cdkTextareaAutosize",""]],hostAttrs:["rows","1",1,"cdk-textarea-autosize"],hostBindings:function(t,e){1&t&&xa("input",(function(){return e._noopInputHandler()}))},inputs:{minRows:["cdkAutosizeMinRows","minRows"],maxRows:["cdkAutosizeMaxRows","maxRows"],enabled:["cdkTextareaAutosize","enabled"]},exportAs:["cdkTextareaAutosize"]}),t}(),e5=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[Sm]]}),t}(),n5=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"matAutosizeMinRows",get:function(){return this.minRows},set:function(t){this.minRows=t}},{key:"matAutosizeMaxRows",get:function(){return this.maxRows},set:function(t){this.maxRows=t}},{key:"matAutosize",get:function(){return this.enabled},set:function(t){this.enabled=t}},{key:"matTextareaAutosize",get:function(){return this.enabled},set:function(t){this.enabled=t}}]),n}(t5);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["textarea","mat-autosize",""],["textarea","matTextareaAutosize",""]],hostAttrs:["rows","1",1,"cdk-textarea-autosize","mat-autosize"],inputs:{cdkAutosizeMinRows:"cdkAutosizeMinRows",cdkAutosizeMaxRows:"cdkAutosizeMaxRows",matAutosizeMinRows:"matAutosizeMinRows",matAutosizeMaxRows:"matAutosizeMaxRows",matAutosize:["mat-autosize","matAutosize"],matTextareaAutosize:"matTextareaAutosize"},exportAs:["matTextareaAutosize"],features:[ws]});var e=zn(t);return t}(),i5=new ht("MAT_INPUT_VALUE_ACCESSOR"),r5=["button","checkbox","file","hidden","image","radio","range","reset","submit"],o5=0,a5=iJ((function t(e,n,i,r){Object(m.a)(this,t),this._defaultErrorStateMatcher=e,this._parentForm=n,this._parentFormGroup=i,this.ngControl=r})),s5=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c,l,u){var h;Object(m.a)(this,n),(h=e.call(this,s,o,a,r))._elementRef=t,h._platform=i,h.ngControl=r,h._autofillMonitor=l,h._uid="mat-input-".concat(o5++),h.focused=!1,h.stateChanges=new w.b,h.controlType="mat-input",h.autofilled=!1,h._disabled=!1,h._required=!1,h._type="text",h._readonly=!1,h._neverEmptyInputTypes=["date","datetime","datetime-local","month","time","week"].filter((function(t){return Om().has(t)}));var d=h._elementRef.nativeElement,f=d.nodeName.toLowerCase();return h._inputValueAccessor=c||d,h._previousNativeValue=h.value,h.id=h.id,i.IOS&&u.runOutsideAngular((function(){t.nativeElement.addEventListener("keyup",(function(t){var e=t.target;e.value||e.selectionStart||e.selectionEnd||(e.setSelectionRange(1,1),e.setSelectionRange(0,0))}))})),h._isServer=!h._platform.isBrowser,h._isNativeSelect="select"===f,h._isTextarea="textarea"===f,h._isNativeSelect&&(h.controlType=d.multiple?"mat-native-select-multiple":"mat-native-select"),h}return Object(g.a)(n,[{key:"ngAfterViewInit",value:function(){var t=this;this._platform.isBrowser&&this._autofillMonitor.monitor(this._elementRef.nativeElement).subscribe((function(e){t.autofilled=e.isAutofilled,t.stateChanges.next()}))}},{key:"ngOnChanges",value:function(){this.stateChanges.next()}},{key:"ngOnDestroy",value:function(){this.stateChanges.complete(),this._platform.isBrowser&&this._autofillMonitor.stopMonitoring(this._elementRef.nativeElement)}},{key:"ngDoCheck",value:function(){this.ngControl&&this.updateErrorState(),this._dirtyCheckNativeValue()}},{key:"focus",value:function(t){this._elementRef.nativeElement.focus(t)}},{key:"_focusChanged",value:function(t){t===this.focused||this.readonly&&t||(this.focused=t,this.stateChanges.next())}},{key:"_onInput",value:function(){}},{key:"_dirtyCheckNativeValue",value:function(){var t=this._elementRef.nativeElement.value;this._previousNativeValue!==t&&(this._previousNativeValue=t,this.stateChanges.next())}},{key:"_validateType",value:function(){if(r5.indexOf(this._type)>-1)throw Error('Input type "'.concat(this._type,"\" isn't supported by matInput."))}},{key:"_isNeverEmpty",value:function(){return this._neverEmptyInputTypes.indexOf(this._type)>-1}},{key:"_isBadInput",value:function(){var t=this._elementRef.nativeElement.validity;return t&&t.badInput}},{key:"setDescribedByIds",value:function(t){this._ariaDescribedby=t.join(" ")}},{key:"onContainerClick",value:function(){this.focused||this.focus()}},{key:"disabled",get:function(){return this.ngControl&&null!==this.ngControl.disabled?this.ngControl.disabled:this._disabled},set:function(t){this._disabled=nm(t),this.focused&&(this.focused=!1,this.stateChanges.next())}},{key:"id",get:function(){return this._id},set:function(t){this._id=t||this._uid}},{key:"required",get:function(){return this._required},set:function(t){this._required=nm(t)}},{key:"type",get:function(){return this._type},set:function(t){this._type=t||"text",this._validateType(),!this._isTextarea&&Om().has(this._type)&&(this._elementRef.nativeElement.type=this._type)}},{key:"value",get:function(){return this._inputValueAccessor.value},set:function(t){t!==this.value&&(this._inputValueAccessor.value=t,this.stateChanges.next())}},{key:"readonly",get:function(){return this._readonly},set:function(t){this._readonly=nm(t)}},{key:"empty",get:function(){return!(this._isNeverEmpty()||this._elementRef.nativeElement.value||this._isBadInput()||this.autofilled)}},{key:"shouldLabelFloat",get:function(){if(this._isNativeSelect){var t=this._elementRef.nativeElement,e=t.options[0];return this.focused||t.multiple||!this.empty||!!(t.selectedIndex>-1&&e&&e.label)}return this.focused||!this.empty}}]),n}(a5);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Cm),da(ff,10),da(gp,8),da(Pp,8),da(oJ),da(i5,10),da($3),da(jl))},t.\u0275dir=Wt({type:t,selectors:[["input","matInput",""],["textarea","matInput",""],["select","matNativeControl",""],["input","matNativeControl",""],["textarea","matNativeControl",""]],hostAttrs:[1,"mat-input-element","mat-form-field-autofill-control"],hostVars:10,hostBindings:function(t,e){1&t&&xa("focus",(function(){return e._focusChanged(!0)}))("blur",(function(){return e._focusChanged(!1)}))("input",(function(){return e._onInput()})),2&t&&(bs("disabled",e.disabled)("required",e.required),oa("id",e.id)("placeholder",e.placeholder)("readonly",e.readonly&&!e._isNativeSelect||null)("aria-describedby",e._ariaDescribedby||null)("aria-invalid",e.errorState)("aria-required",e.required.toString()),Qa("mat-input-server",e._isServer))},inputs:{id:"id",disabled:"disabled",required:"required",type:"type",value:"value",readonly:"readonly",placeholder:"placeholder",errorStateMatcher:"errorStateMatcher"},exportAs:["matInput"],features:[Ns([{provide:F3,useExisting:t}]),ws,Ms]}),t}(),c5=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[oJ],imports:[[e5,Z3],e5,Z3]}),t}(),l5=["trigger"],u5=["panel"];function h5(t,e){if(1&t&&(ga(0,"span",8),ds(1),va()),2&t){var n=Aa();Qi(1),fs(n.placeholder||"\xa0")}}function d5(t,e){if(1&t&&(ga(0,"span"),ds(1),va()),2&t){var n=Aa(2);Qi(1),fs(n.triggerValue||"\xa0")}}function f5(t,e){1&t&&Da(0,0,["*ngSwitchCase","true"])}function p5(t,e){1&t&&(ga(0,"span",9),ua(1,d5,2,1,"span",10),ua(2,f5,1,0,void 0,11),va()),2&t&&(pa("ngSwitch",!!Aa().customTrigger),Qi(2),pa("ngSwitchCase",!0))}function m5(t,e){if(1&t){var n=ka();ga(0,"div",12),ga(1,"div",13,14),xa("@transformPanel.done",(function(t){return Se(n),Aa()._panelDoneAnimatingStream.next(t.toState)}))("keydown",(function(t){return Se(n),Aa()._handleKeydown(t)})),Da(3,1),va(),va()}if(2&t){var i=Aa();pa("@transformPanelWrap",void 0),Qi(1),vs("mat-select-panel ",i._getPanelTheme(),""),Za("transform-origin",i._transformOrigin)("font-size",i._triggerFontSize,"px"),pa("ngClass",i.panelClass)("@transformPanel",i.multiple?"showing-multiple":"showing"),oa("id",i.id+"-panel")}}var g5=[[["mat-select-trigger"]],"*"],v5=["mat-select-trigger","*"],b5={transformPanelWrap:Jg("transformPanelWrap",[av("* => void",cv("@transformPanel",[sv()],{optional:!0}))]),transformPanel:Jg("transformPanel",[rv("void",iv({transform:"scaleY(0.8)",minWidth:"100%",opacity:0})),rv("showing",iv({opacity:1,minWidth:"calc(100% + 32px)",transform:"scaleY(1)"})),rv("showing-multiple",iv({opacity:1,minWidth:"calc(100% + 64px)",transform:"scaleY(1)"})),av("void => *",tv("120ms cubic-bezier(0, 0, 0.2, 1)")),av("* => void",tv("100ms 25ms linear",iv({opacity:0})))])},y5=0,_5=new ht("mat-select-scroll-strategy"),w5=new ht("MAT_SELECT_CONFIG"),k5={provide:_5,deps:[m0],useFactory:function(t){return function(){return t.scrollStrategies.reposition()}}},C5=function t(e,n){Object(m.a)(this,t),this.source=e,this.value=n},S5=eJ(nJ(J$(iJ((function t(e,n,i,r,o){Object(m.a)(this,t),this._elementRef=e,this._defaultErrorStateMatcher=n,this._parentForm=i,this._parentFormGroup=r,this.ngControl=o}))))),x5=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-select-trigger"]]}),t}(),O5=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,c,l,h,d,f,p,g,v,b){var y;return Object(m.a)(this,n),(y=e.call(this,a,o,l,h,f))._viewportRuler=t,y._changeDetectorRef=i,y._ngZone=r,y._dir=c,y._parentFormField=d,y.ngControl=f,y._liveAnnouncer=v,y._panelOpen=!1,y._required=!1,y._scrollTop=0,y._multiple=!1,y._compareWith=function(t,e){return t===e},y._uid="mat-select-".concat(y5++),y._destroy=new w.b,y._triggerFontSize=0,y._onChange=function(){},y._onTouched=function(){},y._optionIds="",y._transformOrigin="top",y._panelDoneAnimatingStream=new w.b,y._offsetY=0,y._positions=[{originX:"start",originY:"top",overlayX:"start",overlayY:"top"},{originX:"start",originY:"bottom",overlayX:"start",overlayY:"bottom"}],y._disableOptionCentering=!1,y._focused=!1,y.controlType="mat-select",y.ariaLabel="",y.optionSelectionChanges=Object(MX.a)((function(){var t=y.options;return t?t.changes.pipe(Object(NX.a)(t),Object(LX.a)((function(){return C.a.apply(void 0,Object(u.a)(t.map((function(t){return t.onSelectionChange}))))}))):y._ngZone.onStable.asObservable().pipe(Object(FX.a)(1),Object(LX.a)((function(){return y.optionSelectionChanges})))})),y.openedChange=new Uc,y._openedStream=y.openedChange.pipe(Object(vg.a)((function(t){return t})),Object(ef.a)((function(){}))),y._closedStream=y.openedChange.pipe(Object(vg.a)((function(t){return!t})),Object(ef.a)((function(){}))),y.selectionChange=new Uc,y.valueChange=new Uc,y.ngControl&&(y.ngControl.valueAccessor=Object(s.a)(y)),y._scrollStrategyFactory=g,y._scrollStrategy=y._scrollStrategyFactory(),y.tabIndex=parseInt(p)||0,y.id=y.id,b&&(null!=b.disableOptionCentering&&(y.disableOptionCentering=b.disableOptionCentering),null!=b.typeaheadDebounceInterval&&(y.typeaheadDebounceInterval=b.typeaheadDebounceInterval)),y}return Object(g.a)(n,[{key:"ngOnInit",value:function(){var t=this;this._selectionModel=new fm(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe(Object(RJ.a)(),Object(Am.a)(this._destroy)).subscribe((function(){t.panelOpen?(t._scrollTop=0,t.openedChange.emit(!0)):(t.openedChange.emit(!1),t.overlayDir.offsetX=0,t._changeDetectorRef.markForCheck())})),this._viewportRuler.change().pipe(Object(Am.a)(this._destroy)).subscribe((function(){t._panelOpen&&(t._triggerRect=t.trigger.nativeElement.getBoundingClientRect(),t._changeDetectorRef.markForCheck())}))}},{key:"ngAfterContentInit",value:function(){var t=this;this._initKeyManager(),this._selectionModel.changed.pipe(Object(Am.a)(this._destroy)).subscribe((function(t){t.added.forEach((function(t){return t.select()})),t.removed.forEach((function(t){return t.deselect()}))})),this.options.changes.pipe(Object(NX.a)(null),Object(Am.a)(this._destroy)).subscribe((function(){t._resetOptions(),t._initializeSelection()}))}},{key:"ngDoCheck",value:function(){this.ngControl&&this.updateErrorState()}},{key:"ngOnChanges",value:function(t){t.disabled&&this.stateChanges.next(),t.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this._typeaheadDebounceInterval)}},{key:"ngOnDestroy",value:function(){this._destroy.next(),this._destroy.complete(),this.stateChanges.complete()}},{key:"toggle",value:function(){this.panelOpen?this.close():this.open()}},{key:"open",value:function(){var t=this;!this.disabled&&this.options&&this.options.length&&!this._panelOpen&&(this._triggerRect=this.trigger.nativeElement.getBoundingClientRect(),this._triggerFontSize=parseInt(getComputedStyle(this.trigger.nativeElement).fontSize||"0"),this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._calculateOverlayPosition(),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this._ngZone.onStable.asObservable().pipe(Object(FX.a)(1)).subscribe((function(){t._triggerFontSize&&t.overlayDir.overlayRef&&t.overlayDir.overlayRef.overlayElement&&(t.overlayDir.overlayRef.overlayElement.style.fontSize="".concat(t._triggerFontSize,"px"))})))}},{key:"close",value:function(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched())}},{key:"writeValue",value:function(t){this.options&&this._setSelectionByValue(t)}},{key:"registerOnChange",value:function(t){this._onChange=t}},{key:"registerOnTouched",value:function(t){this._onTouched=t}},{key:"setDisabledState",value:function(t){this.disabled=t,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}},{key:"_isRtl",value:function(){return!!this._dir&&"rtl"===this._dir.value}},{key:"_handleKeydown",value:function(t){this.disabled||(this.panelOpen?this._handleOpenKeydown(t):this._handleClosedKeydown(t))}},{key:"_handleClosedKeydown",value:function(t){var e=t.keyCode,n=40===e||38===e||37===e||39===e,i=13===e||32===e,r=this._keyManager;if(!r.isTyping()&&i&&!JQ(t)||(this.multiple||t.altKey)&&n)t.preventDefault(),this.open();else if(!this.multiple){var o=this.selected;36===e||35===e?(36===e?r.setFirstItemActive():r.setLastItemActive(),t.preventDefault()):r.onKeydown(t);var a=this.selected;a&&o!==a&&this._liveAnnouncer.announce(a.viewValue,1e4)}}},{key:"_handleOpenKeydown",value:function(t){var e=this._keyManager,n=t.keyCode,i=40===n||38===n,r=e.isTyping();if(36===n||35===n)t.preventDefault(),36===n?e.setFirstItemActive():e.setLastItemActive();else if(i&&t.altKey)t.preventDefault(),this.close();else if(r||13!==n&&32!==n||!e.activeItem||JQ(t))if(!r&&this._multiple&&65===n&&t.ctrlKey){t.preventDefault();var o=this.options.some((function(t){return!t.disabled&&!t.selected}));this.options.forEach((function(t){t.disabled||(o?t.select():t.deselect())}))}else{var a=e.activeItemIndex;e.onKeydown(t),this._multiple&&i&&t.shiftKey&&e.activeItem&&e.activeItemIndex!==a&&e.activeItem._selectViaInteraction()}else t.preventDefault(),e.activeItem._selectViaInteraction()}},{key:"_onFocus",value:function(){this.disabled||(this._focused=!0,this.stateChanges.next())}},{key:"_onBlur",value:function(){this._focused=!1,this.disabled||this.panelOpen||(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}},{key:"_onAttached",value:function(){var t=this;this.overlayDir.positionChange.pipe(Object(FX.a)(1)).subscribe((function(){t._changeDetectorRef.detectChanges(),t._calculateOverlayOffsetX(),t.panel.nativeElement.scrollTop=t._scrollTop}))}},{key:"_getPanelTheme",value:function(){return this._parentFormField?"mat-".concat(this._parentFormField.color):""}},{key:"_initializeSelection",value:function(){var t=this;Promise.resolve().then((function(){t._setSelectionByValue(t.ngControl?t.ngControl.value:t._value),t.stateChanges.next()}))}},{key:"_setSelectionByValue",value:function(t){var e=this;if(this.multiple&&t){if(!Array.isArray(t))throw Error("Value must be an array in multiple-selection mode.");this._selectionModel.clear(),t.forEach((function(t){return e._selectValue(t)})),this._sortValues()}else{this._selectionModel.clear();var n=this._selectValue(t);n?this._keyManager.setActiveItem(n):this.panelOpen||this._keyManager.setActiveItem(-1)}this._changeDetectorRef.markForCheck()}},{key:"_selectValue",value:function(t){var e=this,n=this.options.find((function(n){try{return null!=n.value&&e._compareWith(n.value,t)}catch(i){return ii()&&console.warn(i),!1}}));return n&&this._selectionModel.select(n),n}},{key:"_initKeyManager",value:function(){var t=this;this._keyManager=new h$(this.options).withTypeAhead(this._typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withAllowedModifierKeys(["shiftKey"]),this._keyManager.tabOut.pipe(Object(Am.a)(this._destroy)).subscribe((function(){t.panelOpen&&(!t.multiple&&t._keyManager.activeItem&&t._keyManager.activeItem._selectViaInteraction(),t.focus(),t.close())})),this._keyManager.change.pipe(Object(Am.a)(this._destroy)).subscribe((function(){t._panelOpen&&t.panel?t._scrollActiveOptionIntoView():t._panelOpen||t.multiple||!t._keyManager.activeItem||t._keyManager.activeItem._selectViaInteraction()}))}},{key:"_resetOptions",value:function(){var t=this,e=Object(C.a)(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(Object(Am.a)(e)).subscribe((function(e){t._onSelect(e.source,e.isUserInput),e.isUserInput&&!t.multiple&&t._panelOpen&&(t.close(),t.focus())})),C.a.apply(void 0,Object(u.a)(this.options.map((function(t){return t._stateChanges})))).pipe(Object(Am.a)(e)).subscribe((function(){t._changeDetectorRef.markForCheck(),t.stateChanges.next()})),this._setOptionIds()}},{key:"_onSelect",value:function(t,e){var n=this._selectionModel.isSelected(t);null!=t.value||this._multiple?(n!==t.selected&&(t.selected?this._selectionModel.select(t):this._selectionModel.deselect(t)),e&&this._keyManager.setActiveItem(t),this.multiple&&(this._sortValues(),e&&this.focus())):(t.deselect(),this._selectionModel.clear(),this._propagateChanges(t.value)),n!==this._selectionModel.isSelected(t)&&this._propagateChanges(),this.stateChanges.next()}},{key:"_sortValues",value:function(){var t=this;if(this.multiple){var e=this.options.toArray();this._selectionModel.sort((function(n,i){return t.sortComparator?t.sortComparator(n,i,e):e.indexOf(n)-e.indexOf(i)})),this.stateChanges.next()}}},{key:"_propagateChanges",value:function(t){var e;e=this.multiple?this.selected.map((function(t){return t.value})):this.selected?this.selected.value:t,this._value=e,this.valueChange.emit(e),this._onChange(e),this.selectionChange.emit(new C5(this,e)),this._changeDetectorRef.markForCheck()}},{key:"_setOptionIds",value:function(){this._optionIds=this.options.map((function(t){return t.id})).join(" ")}},{key:"_highlightCorrectOption",value:function(){this._keyManager&&(this.empty?this._keyManager.setFirstItemActive():this._keyManager.setActiveItem(this._selectionModel.selected[0]))}},{key:"_scrollActiveOptionIntoView",value:function(){var t,e,n,i=this._keyManager.activeItemIndex||0,r=PJ(i,this.options,this.optionGroups);this.panel.nativeElement.scrollTop=(n=(i+r)*(t=this._getItemHeight()))<(e=this.panel.nativeElement.scrollTop)?n:n+t>e+256?Math.max(0,n-256+t):e}},{key:"focus",value:function(t){this._elementRef.nativeElement.focus(t)}},{key:"_getOptionIndex",value:function(t){return this.options.reduce((function(e,n,i){return void 0!==e?e:t===n?i:void 0}),void 0)}},{key:"_calculateOverlayPosition",value:function(){var t=this._getItemHeight(),e=this._getItemCount(),n=Math.min(e*t,256),i=e*t-n,r=this.empty?0:this._getOptionIndex(this._selectionModel.selected[0]);r+=PJ(r,this.options,this.optionGroups);var o=n/2;this._scrollTop=this._calculateOverlayScroll(r,o,i),this._offsetY=this._calculateOverlayOffsetY(r,o,i),this._checkOverlayWithinViewport(i)}},{key:"_calculateOverlayScroll",value:function(t,e,n){var i=this._getItemHeight();return Math.min(Math.max(0,i*t-e+i/2),n)}},{key:"_getAriaLabel",value:function(){return this.ariaLabelledby?null:this.ariaLabel||this.placeholder}},{key:"_getAriaLabelledby",value:function(){return this.ariaLabelledby?this.ariaLabelledby:this._parentFormField&&this._parentFormField._hasFloatingLabel()&&!this._getAriaLabel()&&this._parentFormField._labelId||null}},{key:"_getAriaActiveDescendant",value:function(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}},{key:"_calculateOverlayOffsetX",value:function(){var t,e=this.overlayDir.overlayRef.overlayElement.getBoundingClientRect(),n=this._viewportRuler.getViewportSize(),i=this._isRtl(),r=this.multiple?56:32;if(this.multiple)t=40;else{var o=this._selectionModel.selected[0]||this.options.first;t=o&&o.group?32:16}i||(t*=-1);var a=0-(e.left+t-(i?r:0)),s=e.right+t-n.width+(i?0:r);a>0?t+=a+8:s>0&&(t-=s+8),this.overlayDir.offsetX=Math.round(t),this.overlayDir.overlayRef.updatePosition()}},{key:"_calculateOverlayOffsetY",value:function(t,e,n){var i,r=this._getItemHeight(),o=(r-this._triggerRect.height)/2,a=Math.floor(256/r);return this._disableOptionCentering?0:(i=0===this._scrollTop?t*r:this._scrollTop===n?(t-(this._getItemCount()-a))*r+(r-(this._getItemCount()*r-256)%r):e-r/2,Math.round(-1*i-o))}},{key:"_checkOverlayWithinViewport",value:function(t){var e=this._getItemHeight(),n=this._viewportRuler.getViewportSize(),i=this._triggerRect.top-8,r=n.height-this._triggerRect.bottom-8,o=Math.abs(this._offsetY),a=Math.min(this._getItemCount()*e,256)-o-this._triggerRect.height;a>r?this._adjustPanelUp(a,r):o>i?this._adjustPanelDown(o,i,t):this._transformOrigin=this._getOriginBasedOnOption()}},{key:"_adjustPanelUp",value:function(t,e){var n=Math.round(t-e);this._scrollTop-=n,this._offsetY-=n,this._transformOrigin=this._getOriginBasedOnOption(),this._scrollTop<=0&&(this._scrollTop=0,this._offsetY=0,this._transformOrigin="50% bottom 0px")}},{key:"_adjustPanelDown",value:function(t,e,n){var i=Math.round(t-e);if(this._scrollTop+=i,this._offsetY+=i,this._transformOrigin=this._getOriginBasedOnOption(),this._scrollTop>=n)return this._scrollTop=n,this._offsetY=0,void(this._transformOrigin="50% top 0px")}},{key:"_getOriginBasedOnOption",value:function(){var t=this._getItemHeight(),e=(t-this._triggerRect.height)/2,n=Math.abs(this._offsetY)-e+t/2;return"50% ".concat(n,"px 0px")}},{key:"_getItemCount",value:function(){return this.options.length+this.optionGroups.length}},{key:"_getItemHeight",value:function(){return 3*this._triggerFontSize}},{key:"setDescribedByIds",value:function(t){this._ariaDescribedby=t.join(" ")}},{key:"onContainerClick",value:function(){this.focus(),this.open()}},{key:"focused",get:function(){return this._focused||this._panelOpen}},{key:"placeholder",get:function(){return this._placeholder},set:function(t){this._placeholder=t,this.stateChanges.next()}},{key:"required",get:function(){return this._required},set:function(t){this._required=nm(t),this.stateChanges.next()}},{key:"multiple",get:function(){return this._multiple},set:function(t){if(this._selectionModel)throw Error("Cannot change `multiple` mode of select after initialization.");this._multiple=nm(t)}},{key:"disableOptionCentering",get:function(){return this._disableOptionCentering},set:function(t){this._disableOptionCentering=nm(t)}},{key:"compareWith",get:function(){return this._compareWith},set:function(t){if("function"!=typeof t)throw Error("`compareWith` must be a function.");this._compareWith=t,this._selectionModel&&this._initializeSelection()}},{key:"value",get:function(){return this._value},set:function(t){t!==this._value&&(this.writeValue(t),this._value=t)}},{key:"typeaheadDebounceInterval",get:function(){return this._typeaheadDebounceInterval},set:function(t){this._typeaheadDebounceInterval=im(t)}},{key:"id",get:function(){return this._id},set:function(t){this._id=t||this._uid,this.stateChanges.next()}},{key:"panelOpen",get:function(){return this._panelOpen}},{key:"selected",get:function(){return this.multiple?this._selectionModel.selected:this._selectionModel.selected[0]}},{key:"triggerValue",get:function(){if(this.empty)return"";if(this._multiple){var t=this._selectionModel.selected.map((function(t){return t.viewValue}));return this._isRtl()&&t.reverse(),t.join(", ")}return this._selectionModel.selected[0].viewValue}},{key:"empty",get:function(){return!this._selectionModel||this._selectionModel.isEmpty()}},{key:"shouldLabelFloat",get:function(){return this._panelOpen||!this.empty}}]),n}(S5);return t.\u0275fac=function(e){return new(e||t)(da(zJ),da(Po),da(jl),da(oJ),da(Us),da(gm,8),da(gp,8),da(Pp,8),da(X3,8),da(ff,10),fa("tabindex"),da(_5),da(_$),da(w5,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-select"]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,x5,!0),rl(n,EJ,!0),rl(n,xJ,!0)),2&t&&(tl(i=sl())&&(e.customTrigger=i.first),tl(i=sl())&&(e.options=i),tl(i=sl())&&(e.optionGroups=i))},viewQuery:function(t,e){var n;1&t&&(nl(l5,!0),nl(u5,!0),nl(y0,!0)),2&t&&(tl(n=sl())&&(e.trigger=n.first),tl(n=sl())&&(e.panel=n.first),tl(n=sl())&&(e.overlayDir=n.first))},hostAttrs:["role","listbox",1,"mat-select"],hostVars:19,hostBindings:function(t,e){1&t&&xa("keydown",(function(t){return e._handleKeydown(t)}))("focus",(function(){return e._onFocus()}))("blur",(function(){return e._onBlur()})),2&t&&(oa("id",e.id)("tabindex",e.tabIndex)("aria-label",e._getAriaLabel())("aria-labelledby",e._getAriaLabelledby())("aria-required",e.required.toString())("aria-disabled",e.disabled.toString())("aria-invalid",e.errorState)("aria-owns",e.panelOpen?e._optionIds:null)("aria-multiselectable",e.multiple)("aria-describedby",e._ariaDescribedby||null)("aria-activedescendant",e._getAriaActiveDescendant()),Qa("mat-select-disabled",e.disabled)("mat-select-invalid",e.errorState)("mat-select-required",e.required)("mat-select-empty",e.empty))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex",ariaLabel:["aria-label","ariaLabel"],id:"id",disableOptionCentering:"disableOptionCentering",typeaheadDebounceInterval:"typeaheadDebounceInterval",placeholder:"placeholder",required:"required",multiple:"multiple",compareWith:"compareWith",value:"value",panelClass:"panelClass",ariaLabelledby:["aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",sortComparator:"sortComparator"},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[Ns([{provide:F3,useExisting:t},{provide:TJ,useExisting:t}]),ws,Ms],ngContentSelectors:v5,decls:9,vars:9,consts:[["cdk-overlay-origin","","aria-hidden","true",1,"mat-select-trigger",3,"click"],["origin","cdkOverlayOrigin","trigger",""],[1,"mat-select-value",3,"ngSwitch"],["class","mat-select-placeholder",4,"ngSwitchCase"],["class","mat-select-value-text",3,"ngSwitch",4,"ngSwitchCase"],[1,"mat-select-arrow-wrapper"],[1,"mat-select-arrow"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayMinWidth","cdkConnectedOverlayOffsetY","backdropClick","attach","detach"],[1,"mat-select-placeholder"],[1,"mat-select-value-text",3,"ngSwitch"],[4,"ngSwitchDefault"],[4,"ngSwitchCase"],[1,"mat-select-panel-wrap"],[3,"ngClass","keydown"],["panel",""]],template:function(t,e){if(1&t&&(Ia(g5),ga(0,"div",0,1),xa("click",(function(){return e.toggle()})),ga(3,"div",2),ua(4,h5,2,1,"span",3),ua(5,p5,3,2,"span",4),va(),ga(6,"div",5),ba(7,"div",6),va(),va(),ua(8,m5,4,11,"ng-template",7),xa("backdropClick",(function(){return e.close()}))("attach",(function(){return e._onAttached()}))("detach",(function(){return e.close()}))),2&t){var n=ha(1);Qi(3),pa("ngSwitch",e.empty),Qi(1),pa("ngSwitchCase",!0),Qi(1),pa("ngSwitchCase",!1),Qi(3),pa("cdkConnectedOverlayScrollStrategy",e._scrollStrategy)("cdkConnectedOverlayOrigin",n)("cdkConnectedOverlayOpen",e.panelOpen)("cdkConnectedOverlayPositions",e._positions)("cdkConnectedOverlayMinWidth",null==e._triggerRect?null:e._triggerRect.width)("cdkConnectedOverlayOffsetY",e._offsetY)}},directives:[b0,Rh,Lh,y0,Fh,Oh],styles:[".mat-select{display:inline-block;width:100%;outline:none}.mat-select-trigger{display:inline-table;cursor:pointer;position:relative;box-sizing:border-box}.mat-select-disabled .mat-select-trigger{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.mat-select-value{display:table-cell;max-width:0;width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-select-arrow-wrapper{display:table-cell;vertical-align:middle}.mat-form-field-appearance-fill .mat-select-arrow-wrapper{transform:translateY(-50%)}.mat-form-field-appearance-outline .mat-select-arrow-wrapper{transform:translateY(-25%)}.mat-form-field-appearance-standard.mat-form-field-has-label .mat-select:not(.mat-select-empty) .mat-select-arrow-wrapper{transform:translateY(-50%)}.mat-form-field-appearance-standard .mat-select.mat-select-empty .mat-select-arrow-wrapper{transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable.mat-form-field-appearance-standard .mat-select.mat-select-empty .mat-select-arrow-wrapper{transition:none}.mat-select-arrow{width:0;height:0;border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid;margin:0 4px}.mat-select-panel-wrap{flex-basis:100%}.mat-select-panel{min-width:112px;max-width:280px;overflow:auto;-webkit-overflow-scrolling:touch;padding-top:0;padding-bottom:0;max-height:256px;min-width:100%;border-radius:4px}.cdk-high-contrast-active .mat-select-panel{outline:solid 1px}.mat-select-panel .mat-optgroup-label,.mat-select-panel .mat-option{font-size:inherit;line-height:3em;height:3em}.mat-form-field-type-mat-select:not(.mat-form-field-disabled) .mat-form-field-flex{cursor:pointer}.mat-form-field-type-mat-select .mat-form-field-label{width:calc(100% - 18px)}.mat-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable .mat-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-select-placeholder{color:transparent;-webkit-text-fill-color:transparent;transition:none;display:block}\n"],encapsulation:2,data:{animation:[b5.transformPanelWrap,b5.transformPanel]},changeDetection:0}),t}(),M5=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[k5],imports:[[hd,w0,AJ,$$],VJ,Z3,AJ,$$]}),t}(),T5=["input"],E5=function(){return{enterDuration:150}},P5=["*"],A5=new ht("mat-checkbox-default-options",{providedIn:"root",factory:function(){return{color:"accent",clickAction:"check-indeterminate"}}}),j5=new ht("mat-checkbox-click-action"),I5=0,D5={provide:nf,useExisting:Y((function(){return F5})),multi:!0},R5=function t(){Object(m.a)(this,t)},L5=nJ(tJ(eJ(J$((function t(e){Object(m.a)(this,t),this._elementRef=e}))))),F5=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c,l){var u;return Object(m.a)(this,n),(u=e.call(this,t))._changeDetectorRef=i,u._focusMonitor=r,u._ngZone=o,u._clickAction=s,u._animationMode=c,u._options=l,u.ariaLabel="",u.ariaLabelledby=null,u._uniqueId="mat-checkbox-".concat(++I5),u.id=u._uniqueId,u.labelPosition="after",u.name=null,u.change=new Uc,u.indeterminateChange=new Uc,u._onTouched=function(){},u._currentAnimationClass="",u._currentCheckState=0,u._controlValueAccessorChangeFn=function(){},u._checked=!1,u._disabled=!1,u._indeterminate=!1,u._options=u._options||{},u._options.color&&(u.color=u._options.color),u.tabIndex=parseInt(a)||0,u._clickAction=u._clickAction||u._options.clickAction,u}return Object(g.a)(n,[{key:"ngAfterViewInit",value:function(){var t=this;this._focusMonitor.monitor(this._elementRef,!0).subscribe((function(e){e||Promise.resolve().then((function(){t._onTouched(),t._changeDetectorRef.markForCheck()}))})),this._syncIndeterminate(this._indeterminate)}},{key:"ngAfterViewChecked",value:function(){}},{key:"ngOnDestroy",value:function(){this._focusMonitor.stopMonitoring(this._elementRef)}},{key:"_isRippleDisabled",value:function(){return this.disableRipple||this.disabled}},{key:"_onLabelTextChange",value:function(){this._changeDetectorRef.detectChanges()}},{key:"writeValue",value:function(t){this.checked=!!t}},{key:"registerOnChange",value:function(t){this._controlValueAccessorChangeFn=t}},{key:"registerOnTouched",value:function(t){this._onTouched=t}},{key:"setDisabledState",value:function(t){this.disabled=t}},{key:"_getAriaChecked",value:function(){return this.checked?"true":this.indeterminate?"mixed":"false"}},{key:"_transitionCheckState",value:function(t){var e=this._currentCheckState,n=this._elementRef.nativeElement;if(e!==t&&(this._currentAnimationClass.length>0&&n.classList.remove(this._currentAnimationClass),this._currentAnimationClass=this._getAnimationClassForCheckStateTransition(e,t),this._currentCheckState=t,this._currentAnimationClass.length>0)){n.classList.add(this._currentAnimationClass);var i=this._currentAnimationClass;this._ngZone.runOutsideAngular((function(){setTimeout((function(){n.classList.remove(i)}),1e3)}))}}},{key:"_emitChangeEvent",value:function(){var t=new R5;t.source=this,t.checked=this.checked,this._controlValueAccessorChangeFn(this.checked),this.change.emit(t)}},{key:"toggle",value:function(){this.checked=!this.checked}},{key:"_onInputClick",value:function(t){var e=this;t.stopPropagation(),this.disabled||"noop"===this._clickAction?this.disabled||"noop"!==this._clickAction||(this._inputElement.nativeElement.checked=this.checked,this._inputElement.nativeElement.indeterminate=this.indeterminate):(this.indeterminate&&"check"!==this._clickAction&&Promise.resolve().then((function(){e._indeterminate=!1,e.indeterminateChange.emit(e._indeterminate)})),this.toggle(),this._transitionCheckState(this._checked?1:2),this._emitChangeEvent())}},{key:"focus",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"keyboard",e=arguments.length>1?arguments[1]:void 0;this._focusMonitor.focusVia(this._inputElement,t,e)}},{key:"_onInteractionEvent",value:function(t){t.stopPropagation()}},{key:"_getAnimationClassForCheckStateTransition",value:function(t,e){if("NoopAnimations"===this._animationMode)return"";var n="";switch(t){case 0:if(1===e)n="unchecked-checked";else{if(3!=e)return"";n="unchecked-indeterminate"}break;case 2:n=1===e?"unchecked-checked":"unchecked-indeterminate";break;case 1:n=2===e?"checked-unchecked":"checked-indeterminate";break;case 3:n=1===e?"indeterminate-checked":"indeterminate-unchecked"}return"mat-checkbox-anim-".concat(n)}},{key:"_syncIndeterminate",value:function(t){var e=this._inputElement;e&&(e.nativeElement.indeterminate=t)}},{key:"inputId",get:function(){return"".concat(this.id||this._uniqueId,"-input")}},{key:"required",get:function(){return this._required},set:function(t){this._required=nm(t)}},{key:"checked",get:function(){return this._checked},set:function(t){t!=this.checked&&(this._checked=t,this._changeDetectorRef.markForCheck())}},{key:"disabled",get:function(){return this._disabled},set:function(t){var e=nm(t);e!==this.disabled&&(this._disabled=e,this._changeDetectorRef.markForCheck())}},{key:"indeterminate",get:function(){return this._indeterminate},set:function(t){var e=t!=this._indeterminate;this._indeterminate=nm(t),e&&(this._transitionCheckState(this._indeterminate?3:this.checked?1:2),this.indeterminateChange.emit(this._indeterminate)),this._syncIndeterminate(this._indeterminate)}}]),n}(L5);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(S$),da(jl),fa("tabindex"),da(j5,8),da(Cy,8),da(A5,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-checkbox"]],viewQuery:function(t,e){var n;1&t&&(nl(T5,!0),nl(yJ,!0)),2&t&&(tl(n=sl())&&(e._inputElement=n.first),tl(n=sl())&&(e.ripple=n.first))},hostAttrs:[1,"mat-checkbox"],hostVars:12,hostBindings:function(t,e){2&t&&(bs("id",e.id),oa("tabindex",null),Qa("mat-checkbox-indeterminate",e.indeterminate)("mat-checkbox-checked",e.checked)("mat-checkbox-disabled",e.disabled)("mat-checkbox-label-before","before"==e.labelPosition)("_mat-animation-noopable","NoopAnimations"===e._animationMode))},inputs:{disableRipple:"disableRipple",color:"color",tabIndex:"tabIndex",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],id:"id",labelPosition:"labelPosition",name:"name",required:"required",checked:"checked",disabled:"disabled",indeterminate:"indeterminate",ariaDescribedby:["aria-describedby","ariaDescribedby"],value:"value"},outputs:{change:"change",indeterminateChange:"indeterminateChange"},exportAs:["matCheckbox"],features:[Ns([D5]),ws],ngContentSelectors:P5,decls:17,vars:20,consts:[[1,"mat-checkbox-layout"],["label",""],[1,"mat-checkbox-inner-container"],["type","checkbox",1,"mat-checkbox-input","cdk-visually-hidden",3,"id","required","checked","disabled","tabIndex","change","click"],["input",""],["matRipple","",1,"mat-checkbox-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleRadius","matRippleCentered","matRippleAnimation"],[1,"mat-ripple-element","mat-checkbox-persistent-ripple"],[1,"mat-checkbox-frame"],[1,"mat-checkbox-background"],["version","1.1","focusable","false","viewBox","0 0 24 24",0,"xml","space","preserve",1,"mat-checkbox-checkmark"],["fill","none","stroke","white","d","M4.1,12.7 9,17.6 20.3,6.3",1,"mat-checkbox-checkmark-path"],[1,"mat-checkbox-mixedmark"],[1,"mat-checkbox-label",3,"cdkObserveContent"],["checkboxLabel",""],[2,"display","none"]],template:function(t,e){if(1&t&&(Ia(),ga(0,"label",0,1),ga(2,"div",2),ga(3,"input",3,4),xa("change",(function(t){return e._onInteractionEvent(t)}))("click",(function(t){return e._onInputClick(t)})),va(),ga(5,"div",5),ba(6,"div",6),va(),ba(7,"div",7),ga(8,"div",8),Qe(),ga(9,"svg",9),ba(10,"path",10),va(),$e(),ba(11,"div",11),va(),va(),ga(12,"span",12,13),xa("cdkObserveContent",(function(){return e._onLabelTextChange()})),ga(14,"span",14),ds(15,"\xa0"),va(),Da(16),va(),va()),2&t){var n=ha(1),i=ha(13);oa("for",e.inputId),Qi(2),Qa("mat-checkbox-inner-container-no-side-margin",!i.textContent||!i.textContent.trim()),Qi(1),pa("id",e.inputId)("required",e.required)("checked",e.checked)("disabled",e.disabled)("tabIndex",e.tabIndex),oa("value",e.value)("name",e.name)("aria-label",e.ariaLabel||null)("aria-labelledby",e.ariaLabelledby)("aria-checked",e._getAriaChecked())("aria-describedby",e.ariaDescribedby),Qi(2),pa("matRippleTrigger",n)("matRippleDisabled",e._isRippleDisabled())("matRippleRadius",20)("matRippleCentered",!0)("matRippleAnimation",jc(19,E5))}},directives:[yJ,i$],styles:["@keyframes mat-checkbox-fade-in-background{0%{opacity:0}50%{opacity:1}}@keyframes mat-checkbox-fade-out-background{0%,50%{opacity:1}100%{opacity:0}}@keyframes mat-checkbox-unchecked-checked-checkmark-path{0%,50%{stroke-dashoffset:22.910259}50%{animation-timing-function:cubic-bezier(0, 0, 0.2, 0.1)}100%{stroke-dashoffset:0}}@keyframes mat-checkbox-unchecked-indeterminate-mixedmark{0%,68.2%{transform:scaleX(0)}68.2%{animation-timing-function:cubic-bezier(0, 0, 0, 1)}100%{transform:scaleX(1)}}@keyframes mat-checkbox-checked-unchecked-checkmark-path{from{animation-timing-function:cubic-bezier(0.4, 0, 1, 1);stroke-dashoffset:0}to{stroke-dashoffset:-22.910259}}@keyframes mat-checkbox-checked-indeterminate-checkmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 0.1);opacity:1;transform:rotate(0deg)}to{opacity:0;transform:rotate(45deg)}}@keyframes mat-checkbox-indeterminate-checked-checkmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);opacity:0;transform:rotate(45deg)}to{opacity:1;transform:rotate(360deg)}}@keyframes mat-checkbox-checked-indeterminate-mixedmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 0.1);opacity:0;transform:rotate(-45deg)}to{opacity:1;transform:rotate(0deg)}}@keyframes mat-checkbox-indeterminate-checked-mixedmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);opacity:1;transform:rotate(0deg)}to{opacity:0;transform:rotate(315deg)}}@keyframes mat-checkbox-indeterminate-unchecked-mixedmark{0%{animation-timing-function:linear;opacity:1;transform:scaleX(1)}32.8%,100%{opacity:0;transform:scaleX(0)}}.mat-checkbox-background,.mat-checkbox-frame{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:2px;box-sizing:border-box;pointer-events:none}.mat-checkbox{transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);cursor:pointer;-webkit-tap-highlight-color:transparent}._mat-animation-noopable.mat-checkbox{transition:none;animation:none}.mat-checkbox .mat-ripple-element:not(.mat-checkbox-persistent-ripple){opacity:.16}.mat-checkbox-layout{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:inherit;align-items:baseline;vertical-align:middle;display:inline-flex;white-space:nowrap}.mat-checkbox-label{-webkit-user-select:auto;-moz-user-select:auto;-ms-user-select:auto;user-select:auto}.mat-checkbox-inner-container{display:inline-block;height:16px;line-height:0;margin:auto;margin-right:8px;order:0;position:relative;vertical-align:middle;white-space:nowrap;width:16px;flex-shrink:0}[dir=rtl] .mat-checkbox-inner-container{margin-left:8px;margin-right:auto}.mat-checkbox-inner-container-no-side-margin{margin-left:0;margin-right:0}.mat-checkbox-frame{background-color:transparent;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1);border-width:2px;border-style:solid}._mat-animation-noopable .mat-checkbox-frame{transition:none}.cdk-high-contrast-active .mat-checkbox.cdk-keyboard-focused .mat-checkbox-frame{border-style:dotted}.mat-checkbox-background{align-items:center;display:inline-flex;justify-content:center;transition:background-color 90ms cubic-bezier(0, 0, 0.2, 0.1),opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}._mat-animation-noopable .mat-checkbox-background{transition:none}.cdk-high-contrast-active .mat-checkbox .mat-checkbox-background{background:none}.mat-checkbox-persistent-ripple{width:100%;height:100%;transform:none}.mat-checkbox-inner-container:hover .mat-checkbox-persistent-ripple{opacity:.04}.mat-checkbox.cdk-keyboard-focused .mat-checkbox-persistent-ripple{opacity:.12}.mat-checkbox-persistent-ripple,.mat-checkbox.mat-checkbox-disabled .mat-checkbox-inner-container:hover .mat-checkbox-persistent-ripple{opacity:0}@media(hover: none){.mat-checkbox-inner-container:hover .mat-checkbox-persistent-ripple{display:none}}.mat-checkbox-checkmark{top:0;left:0;right:0;bottom:0;position:absolute;width:100%}.mat-checkbox-checkmark-path{stroke-dashoffset:22.910259;stroke-dasharray:22.910259;stroke-width:2.1333333333px}.cdk-high-contrast-black-on-white .mat-checkbox-checkmark-path{stroke:#000 !important}.mat-checkbox-mixedmark{width:calc(100% - 6px);height:2px;opacity:0;transform:scaleX(0) rotate(0deg);border-radius:2px}.cdk-high-contrast-active .mat-checkbox-mixedmark{height:0;border-top:solid 2px;margin-top:2px}.mat-checkbox-label-before .mat-checkbox-inner-container{order:1;margin-left:8px;margin-right:auto}[dir=rtl] .mat-checkbox-label-before .mat-checkbox-inner-container{margin-left:auto;margin-right:8px}.mat-checkbox-checked .mat-checkbox-checkmark{opacity:1}.mat-checkbox-checked .mat-checkbox-checkmark-path{stroke-dashoffset:0}.mat-checkbox-checked .mat-checkbox-mixedmark{transform:scaleX(1) rotate(-45deg)}.mat-checkbox-indeterminate .mat-checkbox-checkmark{opacity:0;transform:rotate(45deg)}.mat-checkbox-indeterminate .mat-checkbox-checkmark-path{stroke-dashoffset:0}.mat-checkbox-indeterminate .mat-checkbox-mixedmark{opacity:1;transform:scaleX(1) rotate(0deg)}.mat-checkbox-unchecked .mat-checkbox-background{background-color:transparent}.mat-checkbox-disabled{cursor:default}.cdk-high-contrast-active .mat-checkbox-disabled{opacity:.5}.mat-checkbox-anim-unchecked-checked .mat-checkbox-background{animation:180ms linear 0ms mat-checkbox-fade-in-background}.mat-checkbox-anim-unchecked-checked .mat-checkbox-checkmark-path{animation:180ms linear 0ms mat-checkbox-unchecked-checked-checkmark-path}.mat-checkbox-anim-unchecked-indeterminate .mat-checkbox-background{animation:180ms linear 0ms mat-checkbox-fade-in-background}.mat-checkbox-anim-unchecked-indeterminate .mat-checkbox-mixedmark{animation:90ms linear 0ms mat-checkbox-unchecked-indeterminate-mixedmark}.mat-checkbox-anim-checked-unchecked .mat-checkbox-background{animation:180ms linear 0ms mat-checkbox-fade-out-background}.mat-checkbox-anim-checked-unchecked .mat-checkbox-checkmark-path{animation:90ms linear 0ms mat-checkbox-checked-unchecked-checkmark-path}.mat-checkbox-anim-checked-indeterminate .mat-checkbox-checkmark{animation:90ms linear 0ms mat-checkbox-checked-indeterminate-checkmark}.mat-checkbox-anim-checked-indeterminate .mat-checkbox-mixedmark{animation:90ms linear 0ms mat-checkbox-checked-indeterminate-mixedmark}.mat-checkbox-anim-indeterminate-checked .mat-checkbox-checkmark{animation:500ms linear 0ms mat-checkbox-indeterminate-checked-checkmark}.mat-checkbox-anim-indeterminate-checked .mat-checkbox-mixedmark{animation:500ms linear 0ms mat-checkbox-indeterminate-checked-mixedmark}.mat-checkbox-anim-indeterminate-unchecked .mat-checkbox-background{animation:180ms linear 0ms mat-checkbox-fade-out-background}.mat-checkbox-anim-indeterminate-unchecked .mat-checkbox-mixedmark{animation:300ms linear 0ms mat-checkbox-indeterminate-unchecked-mixedmark}.mat-checkbox-input{bottom:0;left:50%}.mat-checkbox .mat-checkbox-ripple{position:absolute;left:calc(50% - 20px);top:calc(50% - 20px);height:40px;width:40px;z-index:1;pointer-events:none}\n"],encapsulation:2,changeDetection:0}),t}(),N5={provide:yf,useExisting:Y((function(){return B5})),multi:!0},B5=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(zp);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-checkbox","required","","formControlName",""],["mat-checkbox","required","","formControl",""],["mat-checkbox","required","","ngModel",""]],features:[Ns([N5]),ws]});var e=zn(t);return t}(),H5=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}(),z5=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[_J,$$,r$,H5],$$,H5]}),t}();function V5(t,e){if(1&t&&(ga(0,"mat-option",15),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var U5=function(){return{standalone:!0}},q5=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.vpcsConfigurationService=r,this.consoleTypes=[],this.inputForm=this.formBuilder.group({name:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name,t.getConfiguration()}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.vpcsConfigurationService.getConsoleTypes()},t.prototype.onSaveClick=function(){var t=this;this.inputForm.valid?this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()})):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(T2))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-vpcs"]],decls:19,vars:10,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ngModelOptions","ngModel","ngModelChange"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ga(6,"form",5),ga(7,"mat-form-field",6),ga(8,"input",7),xa("ngModelChange",(function(t){return e.node.name=t})),va(),va(),ga(9,"mat-form-field",8),ga(10,"mat-select",9),xa("ngModelChange",(function(t){return e.node.console_type=t})),ua(11,V5,2,2,"mat-option",10),va(),va(),ga(12,"mat-checkbox",11),xa("ngModelChange",(function(t){return e.node.console_auto_start=t})),ds(13," Auto start console "),va(),va(),va(),va(),va(),va(),ga(14,"div",12),ga(15,"button",13),xa("click",(function(){return e.onCancelClick()})),ds(16,"Cancel"),va(),ga(17,"button",14),xa("click",(function(){return e.onSaveClick()})),ds(18,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("formGroup",e.inputForm),Qi(2),pa("ngModel",e.node.name),Qi(2),pa("ngModelOptions",jc(8,U5))("ngModel",e.node.console_type),Qi(1),pa("ngForOf",e.consoleTypes),Qi(1),pa("ngModelOptions",jc(9,U5))("ngModel",e.node.console_auto_start))},directives:[r1,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,F5,a1,a2,EJ],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),G5=function(){return{standalone:!0}},W5=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.vpcsConfigurationService=r,this.consoleTypes=[],this.categories=[],this.inputForm=this.formBuilder.group({name:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=t.node.name,t.numberOfPorts=t.node.ports.length,t.getConfiguration()}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.vpcsConfigurationService.getConsoleTypes(),this.categories=this.vpcsConfigurationService.getCategories()},t.prototype.onSaveClick=function(){var t=this;if(this.inputForm.valid){this.node.properties.ports_mapping=[];for(var e=0;e<this.numberOfPorts;e++)this.node.properties.ports_mapping.push({name:"Ethernet"+e,port_number:e});this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()}))}else this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(T2))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-ethernet-hub"]],decls:16,vars:6,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","Number of ports",3,"ngModel","ngModelOptions","ngModelChange"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ga(6,"form",5),ga(7,"mat-form-field",6),ga(8,"input",7),xa("ngModelChange",(function(t){return e.node.name=t})),va(),va(),ga(9,"mat-form-field",6),ga(10,"input",8),xa("ngModelChange",(function(t){return e.numberOfPorts=t})),va(),va(),va(),va(),va(),va(),va(),ga(11,"div",9),ga(12,"button",10),xa("click",(function(){return e.onCancelClick()})),ds(13,"Cancel"),va(),ga(14,"button",11),xa("click",(function(){return e.onSaveClick()})),ds(15,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("formGroup",e.inputForm),Qi(2),pa("ngModel",e.node.name),Qi(2),pa("ngModel",e.numberOfPorts)("ngModelOptions",jc(5,G5)))},directives:[r1,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,Ef,Sp,a1,a2],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),K5=function(){function t(){}return t.prototype.getCategoriesForCloudNodes=function(){return[["Default","guest"],["Routers","router"],["Switches","switch"],["End devices","end_device"],["Security devices","security_device"]]},t.prototype.getConsoleTypesForCloudNodes=function(){return["telnet","none"]},t.prototype.getCategoriesForEthernetHubs=function(){return[["Default","guest"],["Routers","router"],["Switches","switch"],["End devices","end_device"],["Security devices","security_device"]]},t.prototype.getCategoriesForEthernetSwitches=function(){return[["Default","guest"],["Routers","router"],["Switches","switch"],["End devices","end_device"],["Security devices","security_device"]]},t.prototype.getConsoleTypesForEthernetSwitches=function(){return["telnet","none"]},t.prototype.getPortTypesForEthernetSwitches=function(){return["access","dot1q","qinq"]},t.prototype.getEtherTypesForEthernetSwitches=function(){return["0x8100","0x88A8","0x9100","0x9200"]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),X5=[[["caption"]],[["colgroup"],["col"]]],Y5=["caption","colgroup, col"];function Z5(t,e){if(1&t&&(ga(0,"th",3),ds(1),va()),2&t){var n=Aa();Za("text-align",n.justify),Qi(1),ps(" ",n.headerText," ")}}function Q5(t,e){if(1&t&&(ga(0,"td",4),ds(1),va()),2&t){var n=e.$implicit,i=Aa();Za("text-align",i.justify),Qi(1),ps(" ",i.dataAccessor(n,i.name)," ")}}var $5=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments)).stickyCssClass="mat-table-sticky",t}return n}(dg);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-table"],["table","mat-table",""]],hostAttrs:[1,"mat-table"],exportAs:["matTable"],features:[Ns([{provide:dg,useExisting:t},{provide:Fm,useExisting:t}]),ws],ngContentSelectors:Y5,decls:6,vars:0,consts:[["headerRowOutlet",""],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(t,e){1&t&&(Ia(X5),Da(0),Da(1,1),wa(2,0),wa(3,1),wa(4,2),wa(5,3))},directives:[lg,cg,hg,ug],styles:['mat-table{display:block}mat-header-row{min-height:56px}mat-row,mat-footer-row{min-height:48px}mat-row,mat-header-row,mat-footer-row{display:flex;border-width:0;border-bottom-width:1px;border-style:solid;align-items:center;box-sizing:border-box}mat-row::after,mat-header-row::after,mat-footer-row::after{display:inline-block;min-height:inherit;content:""}mat-cell:first-of-type,mat-header-cell:first-of-type,mat-footer-cell:first-of-type{padding-left:24px}[dir=rtl] mat-cell:first-of-type,[dir=rtl] mat-header-cell:first-of-type,[dir=rtl] mat-footer-cell:first-of-type{padding-left:0;padding-right:24px}mat-cell:last-of-type,mat-header-cell:last-of-type,mat-footer-cell:last-of-type{padding-right:24px}[dir=rtl] mat-cell:last-of-type,[dir=rtl] mat-header-cell:last-of-type,[dir=rtl] mat-footer-cell:last-of-type{padding-right:0;padding-left:24px}mat-cell,mat-header-cell,mat-footer-cell{flex:1;display:flex;align-items:center;overflow:hidden;word-wrap:break-word;min-height:inherit}table.mat-table{border-spacing:0}tr.mat-header-row{height:56px}tr.mat-row,tr.mat-footer-row{height:48px}th.mat-header-cell{text-align:left}[dir=rtl] th.mat-header-cell{text-align:right}th.mat-header-cell,td.mat-cell,td.mat-footer-cell{padding:0;border-bottom-width:1px;border-bottom-style:solid}th.mat-header-cell:first-of-type,td.mat-cell:first-of-type,td.mat-footer-cell:first-of-type{padding-left:24px}[dir=rtl] th.mat-header-cell:first-of-type,[dir=rtl] td.mat-cell:first-of-type,[dir=rtl] td.mat-footer-cell:first-of-type{padding-left:0;padding-right:24px}th.mat-header-cell:last-of-type,td.mat-cell:last-of-type,td.mat-footer-cell:last-of-type{padding-right:24px}[dir=rtl] th.mat-header-cell:last-of-type,[dir=rtl] td.mat-cell:last-of-type,[dir=rtl] td.mat-footer-cell:last-of-type{padding-right:0;padding-left:24px}\n'],encapsulation:2});var e=zn(t);return t}(),J5=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Bm);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matCellDef",""]],features:[Ns([{provide:Bm,useExisting:t}]),ws]});var e=zn(t);return t}(),t4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Hm);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matHeaderCellDef",""]],features:[Ns([{provide:Hm,useExisting:t}]),ws]});var e=zn(t);return t}(),e4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(zm);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matFooterCellDef",""]],features:[Ns([{provide:zm,useExisting:t}]),ws]});var e=zn(t);return t}(),n4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Um);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matColumnDef",""]],inputs:{sticky:"sticky",name:["matColumnDef","name"]},features:[Ns([{provide:Um,useExisting:t},{provide:"MAT_SORT_HEADER_COLUMN_DEF",useExisting:t}]),ws]});var e=zn(t);return t}(),i4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),r=e.call(this,t,i),i.nativeElement.classList.add("mat-column-".concat(t.cssClassFriendlyName)),r}return n}(Gm);return t.\u0275fac=function(e){return new(e||t)(da(Um),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["mat-header-cell"],["th","mat-header-cell",""]],hostAttrs:["role","columnheader",1,"mat-header-cell"],features:[ws]}),t}(),r4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),r=e.call(this,t,i),i.nativeElement.classList.add("mat-column-".concat(t.cssClassFriendlyName)),r}return n}(Wm);return t.\u0275fac=function(e){return new(e||t)(da(Um),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["mat-footer-cell"],["td","mat-footer-cell",""]],hostAttrs:["role","gridcell",1,"mat-footer-cell"],features:[ws]}),t}(),o4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i){var r;return Object(m.a)(this,n),r=e.call(this,t,i),i.nativeElement.classList.add("mat-column-".concat(t.cssClassFriendlyName)),r}return n}(Km);return t.\u0275fac=function(e){return new(e||t)(da(Um),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["mat-cell"],["td","mat-cell",""]],hostAttrs:["role","gridcell",1,"mat-cell"],features:[ws]}),t}(),a4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Zm);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matHeaderRowDef",""]],inputs:{columns:["matHeaderRowDef","columns"],sticky:["matHeaderRowDefSticky","sticky"]},features:[Ns([{provide:Zm,useExisting:t}]),ws]});var e=zn(t);return t}(),s4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}($m);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matFooterRowDef",""]],inputs:{columns:["matFooterRowDef","columns"],sticky:["matFooterRowDefSticky","sticky"]},features:[Ns([{provide:$m,useExisting:t}]),ws]});var e=zn(t);return t}(),c4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Jm);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matRowDef",""]],inputs:{columns:["matRowDefColumns","columns"],when:["matRowDefWhen","when"]},features:[Ns([{provide:Jm,useExisting:t}]),ws]});var e=zn(t);return t}(),l4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(eg);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-header-row"],["tr","mat-header-row",""]],hostAttrs:["role","row",1,"mat-header-row"],exportAs:["matHeaderRow"],features:[Ns([{provide:eg,useExisting:t}]),ws],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,e){1&t&&wa(0,0)},directives:[tg],encapsulation:2});var e=zn(t);return t}(),u4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(ng);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-footer-row"],["tr","mat-footer-row",""]],hostAttrs:["role","row",1,"mat-footer-row"],exportAs:["matFooterRow"],features:[Ns([{provide:ng,useExisting:t}]),ws],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,e){1&t&&wa(0,0)},directives:[tg],encapsulation:2});var e=zn(t);return t}(),h4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(ig);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-row"],["tr","mat-row",""]],hostAttrs:["role","row",1,"mat-row"],exportAs:["matRow"],features:[Ns([{provide:ig,useExisting:t}]),ws],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,e){1&t&&wa(0,0)},directives:[tg],encapsulation:2});var e=zn(t);return t}(),d4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(rg);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["ng-template","matNoDataRow",""]],features:[Ns([{provide:rg,useExisting:t}]),ws]});var e=zn(t);return t}(),f4=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(pg);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-text-column"]],features:[ws],decls:3,vars:0,consts:[["matColumnDef",""],["mat-header-cell","",3,"text-align",4,"matHeaderCellDef"],["mat-cell","",3,"text-align",4,"matCellDef"],["mat-header-cell",""],["mat-cell",""]],template:function(t,e){1&t&&(ya(0,0),ua(1,Z5,2,3,"th",1),ua(2,Q5,2,3,"td",2),_a())},directives:[n4,t4,J5,i4,o4],encapsulation:2});var e=zn(t);return t}(),p4=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[mg,$$],$$]}),t}(),m4=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return Object(m.a)(this,n),(t=e.call(this))._renderData=new Pm.a([]),t._filter=new Pm.a(""),t._internalPageChanges=new w.b,t._renderChangesSubscription=_.a.EMPTY,t.sortingDataAccessor=function(t,e){var n=t[e];if(rm(n)){var i=Number(n);return i<9007199254740991?i:n}return n},t.sortData=function(e,n){var i=n.active,r=n.direction;return i&&""!=r?e.sort((function(e,n){var o=t.sortingDataAccessor(e,i),a=t.sortingDataAccessor(n,i),s=0;return null!=o&&null!=a?o>a?s=1:o<a&&(s=-1):null!=o?s=1:null!=a&&(s=-1),s*("asc"==r?1:-1)})):e},t.filterPredicate=function(t,e){var n=Object.keys(t).reduce((function(e,n){return e+t[n]+"\u25ec"}),"").toLowerCase(),i=e.trim().toLowerCase();return-1!=n.indexOf(i)},t._data=new Pm.a(i),t._updateChangeSubscription(),t}return Object(g.a)(n,[{key:"_updateChangeSubscription",value:function(){var t=this,e=this._sort?Object(C.a)(this._sort.sortChange,this._sort.initialized):Object(lm.a)(null),n=this._paginator?Object(C.a)(this._paginator.page,this._internalPageChanges,this._paginator.initialized):Object(lm.a)(null),i=this._data,r=Object(OX.b)([i,this._filter]).pipe(Object(ef.a)((function(e){var n=l(e,1);return t._filterData(n[0])}))),o=Object(OX.b)([r,e]).pipe(Object(ef.a)((function(e){var n=l(e,1);return t._orderData(n[0])}))),a=Object(OX.b)([o,n]).pipe(Object(ef.a)((function(e){var n=l(e,1);return t._pageData(n[0])})));this._renderChangesSubscription.unsubscribe(),this._renderChangesSubscription=a.subscribe((function(e){return t._renderData.next(e)}))}},{key:"_filterData",value:function(t){var e=this;return this.filteredData=this.filter?t.filter((function(t){return e.filterPredicate(t,e.filter)})):t,this.paginator&&this._updatePaginator(this.filteredData.length),this.filteredData}},{key:"_orderData",value:function(t){return this.sort?this.sortData(t.slice(),this.sort):t}},{key:"_pageData",value:function(t){if(!this.paginator)return t;var e=this.paginator.pageIndex*this.paginator.pageSize;return t.slice(e,e+this.paginator.pageSize)}},{key:"_updatePaginator",value:function(t){var e=this;Promise.resolve().then((function(){var n=e.paginator;if(n&&(n.length=t,n.pageIndex>0)){var i=Math.ceil(n.length/n.pageSize)-1||0,r=Math.min(n.pageIndex,i);r!==n.pageIndex&&(n.pageIndex=r,e._internalPageChanges.next())}}))}},{key:"connect",value:function(){return this._renderData}},{key:"disconnect",value:function(){}},{key:"data",get:function(){return this._data.value},set:function(t){this._data.next(t)}},{key:"filter",get:function(){return this._filter.value},set:function(t){this._filter.next(t)}},{key:"sort",get:function(){return this._sort},set:function(t){this._sort=t,this._updateChangeSubscription()}},{key:"paginator",get:function(){return this._paginator},set:function(t){this._paginator=t,this._updateChangeSubscription()}}]),n}(um),g4={tooltipState:Jg("state",[rv("initial, void, hidden",iv({opacity:0,transform:"scale(0)"})),rv("visible",iv({transform:"scale(1)"})),av("* => visible",tv("200ms cubic-bezier(0, 0, 0.2, 1)",ov([iv({opacity:0,transform:"scale(0)",offset:0}),iv({opacity:.5,transform:"scale(0.99)",offset:.5}),iv({opacity:1,transform:"scale(1)",offset:1})]))),av("* => hidden",tv("100ms cubic-bezier(0, 0, 0.2, 1)",iv({opacity:0})))])},v4=Mm({passive:!0});function b4(t){return Error('Tooltip position "'.concat(t,'" is invalid.'))}var y4=new ht("mat-tooltip-scroll-strategy"),_4={provide:y4,deps:[m0],useFactory:function(t){return function(){return t.scrollStrategies.reposition({scrollThrottle:20})}}},w4=new ht("mat-tooltip-default-options",{providedIn:"root",factory:function(){return{showDelay:0,hideDelay:0,touchendHideDelay:1500}}}),k4=function(){var t=function(){function t(e,n,i,r,o,a,s,c,l,u,h){var d=this;Object(m.a)(this,t),this._overlay=e,this._elementRef=n,this._scrollDispatcher=i,this._viewContainerRef=r,this._ngZone=o,this._platform=a,this._ariaDescriber=s,this._focusMonitor=c,this._dir=u,this._defaultOptions=h,this._position="below",this._disabled=!1,this.showDelay=this._defaultOptions.showDelay,this.hideDelay=this._defaultOptions.hideDelay,this.touchGestures="auto",this._message="",this._passiveListeners=new Map,this._destroyed=new w.b,this._handleKeydown=function(t){d._isTooltipVisible()&&27===t.keyCode&&!JQ(t)&&(t.preventDefault(),t.stopPropagation(),d._ngZone.run((function(){return d.hide(0)})))},this._scrollStrategy=l,h&&(h.position&&(this.position=h.position),h.touchGestures&&(this.touchGestures=h.touchGestures)),o.runOutsideAngular((function(){n.nativeElement.addEventListener("keydown",d._handleKeydown)}))}return Object(g.a)(t,[{key:"ngAfterViewInit",value:function(){var t=this;this._setupPointerEvents(),this._focusMonitor.monitor(this._elementRef).pipe(Object(Am.a)(this._destroyed)).subscribe((function(e){e?"keyboard"===e&&t._ngZone.run((function(){return t.show()})):t._ngZone.run((function(){return t.hide(0)}))}))}},{key:"ngOnDestroy",value:function(){var t=this._elementRef.nativeElement;clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),t.removeEventListener("keydown",this._handleKeydown),this._passiveListeners.forEach((function(e,n){t.removeEventListener(n,e,v4)})),this._passiveListeners.clear(),this._destroyed.next(),this._destroyed.complete(),this._ariaDescriber.removeDescription(t,this.message),this._focusMonitor.stopMonitoring(t)}},{key:"show",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.showDelay;if(!this.disabled&&this.message&&(!this._isTooltipVisible()||this._tooltipInstance._showTimeoutId||this._tooltipInstance._hideTimeoutId)){var n=this._createOverlay();this._detach(),this._portal=this._portal||new I$(C4,this._viewContainerRef),this._tooltipInstance=n.attach(this._portal).instance,this._tooltipInstance.afterHidden().pipe(Object(Am.a)(this._destroyed)).subscribe((function(){return t._detach()})),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),this._tooltipInstance.show(e)}}},{key:"hide",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.hideDelay;this._tooltipInstance&&this._tooltipInstance.hide(t)}},{key:"toggle",value:function(){this._isTooltipVisible()?this.hide():this.show()}},{key:"_isTooltipVisible",value:function(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}},{key:"_createOverlay",value:function(){var t=this;if(this._overlayRef)return this._overlayRef;var e=this._scrollDispatcher.getAncestorScrollContainers(this._elementRef),n=this._overlay.position().flexibleConnectedTo(this._elementRef).withTransformOriginOn(".mat-tooltip").withFlexibleDimensions(!1).withViewportMargin(8).withScrollableContainers(e);return n.positionChanges.pipe(Object(Am.a)(this._destroyed)).subscribe((function(e){t._tooltipInstance&&e.scrollableViewProperties.isOverlayClipped&&t._tooltipInstance.isVisible()&&t._ngZone.run((function(){return t.hide(0)}))})),this._overlayRef=this._overlay.create({direction:this._dir,positionStrategy:n,panelClass:"mat-tooltip-panel",scrollStrategy:this._scrollStrategy()}),this._updatePosition(),this._overlayRef.detachments().pipe(Object(Am.a)(this._destroyed)).subscribe((function(){return t._detach()})),this._overlayRef}},{key:"_detach",value:function(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}},{key:"_updatePosition",value:function(){var t=this._overlayRef.getConfig().positionStrategy,e=this._getOrigin(),n=this._getOverlayPosition();t.withPositions([Object.assign(Object.assign({},e.main),n.main),Object.assign(Object.assign({},e.fallback),n.fallback)])}},{key:"_getOrigin",value:function(){var t,e=!this._dir||"ltr"==this._dir.value,n=this.position;if("above"==n||"below"==n)t={originX:"center",originY:"above"==n?"top":"bottom"};else if("before"==n||"left"==n&&e||"right"==n&&!e)t={originX:"start",originY:"center"};else{if(!("after"==n||"right"==n&&e||"left"==n&&!e))throw b4(n);t={originX:"end",originY:"center"}}var i=this._invertPosition(t.originX,t.originY);return{main:t,fallback:{originX:i.x,originY:i.y}}}},{key:"_getOverlayPosition",value:function(){var t,e=!this._dir||"ltr"==this._dir.value,n=this.position;if("above"==n)t={overlayX:"center",overlayY:"bottom"};else if("below"==n)t={overlayX:"center",overlayY:"top"};else if("before"==n||"left"==n&&e||"right"==n&&!e)t={overlayX:"end",overlayY:"center"};else{if(!("after"==n||"right"==n&&e||"left"==n&&!e))throw b4(n);t={overlayX:"start",overlayY:"center"}}var i=this._invertPosition(t.overlayX,t.overlayY);return{main:t,fallback:{overlayX:i.x,overlayY:i.y}}}},{key:"_updateTooltipMessage",value:function(){var t=this;this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),this._ngZone.onMicrotaskEmpty.asObservable().pipe(Object(FX.a)(1),Object(Am.a)(this._destroyed)).subscribe((function(){t._tooltipInstance&&t._overlayRef.updatePosition()})))}},{key:"_setTooltipClass",value:function(t){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=t,this._tooltipInstance._markForCheck())}},{key:"_invertPosition",value:function(t,e){return"above"===this.position||"below"===this.position?"top"===e?e="bottom":"bottom"===e&&(e="top"):"end"===t?t="start":"start"===t&&(t="end"),{x:t,y:e}}},{key:"_setupPointerEvents",value:function(){var t=this;if(this._platform.IOS||this._platform.ANDROID){if("off"!==this.touchGestures){this._disableNativeGesturesIfNecessary();var e=function(){clearTimeout(t._touchstartTimeout),t.hide(t._defaultOptions.touchendHideDelay)};this._passiveListeners.set("touchend",e).set("touchcancel",e).set("touchstart",(function(){clearTimeout(t._touchstartTimeout),t._touchstartTimeout=setTimeout((function(){return t.show()}),500)}))}}else this._passiveListeners.set("mouseenter",(function(){return t.show()})).set("mouseleave",(function(){return t.hide()}));this._passiveListeners.forEach((function(e,n){t._elementRef.nativeElement.addEventListener(n,e,v4)}))}},{key:"_disableNativeGesturesIfNecessary",value:function(){var t=this._elementRef.nativeElement,e=t.style,n=this.touchGestures;"off"!==n&&(("on"===n||"INPUT"!==t.nodeName&&"TEXTAREA"!==t.nodeName)&&(e.userSelect=e.msUserSelect=e.webkitUserSelect=e.MozUserSelect="none"),"on"!==n&&t.draggable||(e.webkitUserDrag="none"),e.touchAction="none",e.webkitTapHighlightColor="transparent")}},{key:"position",get:function(){return this._position},set:function(t){t!==this._position&&(this._position=t,this._overlayRef&&(this._updatePosition(),this._tooltipInstance&&this._tooltipInstance.show(0),this._overlayRef.updatePosition()))}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t),this._disabled&&this.hide(0)}},{key:"message",get:function(){return this._message},set:function(t){var e=this;this._ariaDescriber.removeDescription(this._elementRef.nativeElement,this._message),this._message=null!=t?"".concat(t).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._updateTooltipMessage(),this._ngZone.runOutsideAngular((function(){Promise.resolve().then((function(){e._ariaDescriber.describe(e._elementRef.nativeElement,e.message)}))})))}},{key:"tooltipClass",get:function(){return this._tooltipClass},set:function(t){this._tooltipClass=t,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(m0),da(Us),da(BJ),da(mc),da(jl),da(Cm),da(l$),da(S$),da(y4),da(gm,8),da(w4,8))},t.\u0275dir=Wt({type:t,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-tooltip-trigger"],inputs:{showDelay:["matTooltipShowDelay","showDelay"],hideDelay:["matTooltipHideDelay","hideDelay"],touchGestures:["matTooltipTouchGestures","touchGestures"],position:["matTooltipPosition","position"],disabled:["matTooltipDisabled","disabled"],message:["matTooltip","message"],tooltipClass:["matTooltipClass","tooltipClass"]},exportAs:["matTooltip"]}),t}(),C4=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._changeDetectorRef=e,this._breakpointObserver=n,this._visibility="initial",this._closeOnInteraction=!1,this._onHide=new w.b,this._isHandset=this._breakpointObserver.observe("(max-width: 599.99px) and (orientation: portrait), (max-width: 959.99px) and (orientation: landscape)")}return Object(g.a)(t,[{key:"show",value:function(t){var e=this;this._hideTimeoutId&&(clearTimeout(this._hideTimeoutId),this._hideTimeoutId=null),this._closeOnInteraction=!0,this._showTimeoutId=setTimeout((function(){e._visibility="visible",e._showTimeoutId=null,e._markForCheck()}),t)}},{key:"hide",value:function(t){var e=this;this._showTimeoutId&&(clearTimeout(this._showTimeoutId),this._showTimeoutId=null),this._hideTimeoutId=setTimeout((function(){e._visibility="hidden",e._hideTimeoutId=null,e._markForCheck()}),t)}},{key:"afterHidden",value:function(){return this._onHide.asObservable()}},{key:"isVisible",value:function(){return"visible"===this._visibility}},{key:"ngOnDestroy",value:function(){this._onHide.complete()}},{key:"_animationStart",value:function(){this._closeOnInteraction=!1}},{key:"_animationDone",value:function(t){var e=t.toState;"hidden"!==e||this.isVisible()||this._onHide.next(),"visible"!==e&&"hidden"!==e||(this._closeOnInteraction=!0)}},{key:"_handleBodyInteraction",value:function(){this._closeOnInteraction&&this.hide(0)}},{key:"_markForCheck",value:function(){this._changeDetectorRef.markForCheck()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Po),da(R2))},t.\u0275cmp=Ht({type:t,selectors:[["mat-tooltip-component"]],hostAttrs:["aria-hidden","true"],hostVars:2,hostBindings:function(t,e){1&t&&xa("click",(function(){return e._handleBodyInteraction()}),!1,wn),2&t&&Za("zoom","visible"===e._visibility?1:null)},decls:3,vars:7,consts:[[1,"mat-tooltip",3,"ngClass"]],template:function(t,e){var n;1&t&&(ga(0,"div",0),xa("@state.start",(function(){return e._animationStart()}))("@state.done",(function(t){return e._animationDone(t)})),Nc(1,"async"),ds(2),va()),2&t&&(Qa("mat-tooltip-handset",null==(n=Bc(1,5,e._isHandset))?null:n.matches),pa("ngClass",e.tooltipClass)("@state",e._visibility),Qi(2),fs(e.message))},directives:[Oh],pipes:[Wh],styles:[".mat-tooltip-panel{pointer-events:none !important}.mat-tooltip{color:#fff;border-radius:4px;margin:14px;max-width:250px;padding-left:8px;padding-right:8px;overflow:hidden;text-overflow:ellipsis}.cdk-high-contrast-active .mat-tooltip{outline:solid 1px}.mat-tooltip-handset{margin:24px;padding-left:16px;padding-right:16px}\n"],encapsulation:2,data:{animation:[g4.tooltipState]},changeDetection:0}),t}(),S4=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[_4],imports:[[T$,hd,w0,$$],$$,VJ]}),t}();function x4(t,e){1&t&&(ga(0,"th",18),ds(1," Port number "),va())}function O4(t,e){if(1&t&&(ga(0,"td",19),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.port_number," ")}}function M4(t,e){1&t&&(ga(0,"th",18),ds(1," VLAN "),va())}function T4(t,e){if(1&t&&(ga(0,"td",19),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.vlan," ")}}function E4(t,e){1&t&&(ga(0,"th",18),ds(1," Type "),va())}function P4(t,e){if(1&t&&(ga(0,"td",19),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.type," ")}}function A4(t,e){1&t&&(ga(0,"th",18),ds(1," EtherType "),va())}function j4(t,e){if(1&t&&(ga(0,"td",19),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.ethertype," ")}}function I4(t,e){1&t&&(ga(0,"th",18),ds(1," Actions "),va())}function D4(t,e){if(1&t){var n=ka();ga(0,"td",19),ga(1,"button",20),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().delete(t)})),ga(2,"mat-icon",21),ds(3,"delete"),va(),va(),va()}}function R4(t,e){1&t&&ba(0,"tr",22)}function L4(t,e){1&t&&ba(0,"tr",23)}function F4(t,e){if(1&t&&(ga(0,"mat-option",24),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function N4(t,e){if(1&t&&(ga(0,"mat-option",24),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var B4=function(){return{standalone:!0}},H4=function(){function t(t){this.builtInTemplatesConfigurationService=t,this.ethernetPorts=[],this.newPort={name:"",port_number:0},this.portTypes=[],this.etherTypes=[],this.displayedColumns=["port_number","vlan","type","ethertype","action"]}return t.prototype.ngOnInit=function(){this.getConfiguration()},t.prototype.getConfiguration=function(){this.etherTypes=this.builtInTemplatesConfigurationService.getEtherTypesForEthernetSwitches(),this.portTypes=this.builtInTemplatesConfigurationService.getPortTypesForEthernetSwitches()},t.prototype.onAdd=function(){this.ethernetPorts.push(this.newPort),this.newPort={name:"",port_number:0}},t.prototype.delete=function(t){this.ethernetPorts=this.ethernetPorts.filter((function(e){return e!==t}))},t.\u0275fac=function(e){return new(e||t)(da(K5))},t.\u0275cmp=Ht({type:t,selectors:[["app-ports"]],inputs:{ethernetPorts:"ethernetPorts"},decls:31,vars:13,consts:[["mat-table","",1,"table",3,"dataSource"],["matColumnDef","port_number"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","vlan"],["matColumnDef","type"],["matColumnDef","ethertype"],["matColumnDef","action"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],[1,"form-field"],["matInput","","type","number","placeholder","Port",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","VLAN",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["placeholder","EtherType",3,"ngModelOptions","ngModel","ngModelChange"],["mat-button","",1,"form-field",3,"click"],["mat-header-cell",""],["mat-cell",""],["mat-icon-button","","matTooltip","Delete port","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Delete port"],["mat-header-row",""],["mat-row",""],[3,"value"]],template:function(t,e){1&t&&(ga(0,"table",0),ya(1,1),ua(2,x4,2,0,"th",2),ua(3,O4,2,1,"td",3),_a(),ya(4,4),ua(5,M4,2,0,"th",2),ua(6,T4,2,1,"td",3),_a(),ya(7,5),ua(8,E4,2,0,"th",2),ua(9,P4,2,1,"td",3),_a(),ya(10,6),ua(11,A4,2,0,"th",2),ua(12,j4,2,1,"td",3),_a(),ya(13,7),ua(14,I4,2,0,"th",2),ua(15,D4,4,0,"td",3),_a(),ua(16,R4,1,0,"tr",8),ua(17,L4,1,0,"tr",9),va(),ba(18,"br"),ga(19,"mat-form-field",10),ga(20,"input",11),xa("ngModelChange",(function(t){return e.newPort.port_number=t})),va(),va(),ga(21,"mat-form-field",10),ga(22,"input",12),xa("ngModelChange",(function(t){return e.newPort.vlan=t})),va(),va(),ga(23,"mat-form-field",13),ga(24,"mat-select",14),xa("ngModelChange",(function(t){return e.newPort.type=t})),ua(25,F4,2,2,"mat-option",15),va(),va(),ga(26,"mat-form-field",13),ga(27,"mat-select",16),xa("ngModelChange",(function(t){return e.newPort.ethertype=t})),ua(28,N4,2,2,"mat-option",15),va(),va(),ga(29,"button",17),xa("click",(function(){return e.onAdd()})),ds(30,"Add"),va()),2&t&&(pa("dataSource",e.ethernetPorts),Qi(16),pa("matHeaderRowDef",e.displayedColumns),Qi(1),pa("matRowDefColumns",e.displayedColumns),Qi(3),pa("ngModel",e.newPort.port_number),Qi(2),pa("ngModel",e.newPort.vlan),Qi(2),pa("ngModelOptions",jc(11,B4))("ngModel",e.newPort.type),Qi(1),pa("ngForOf",e.portTypes),Qi(2),pa("ngModelOptions",jc(12,B4))("ngModel",e.newPort.ethertype),Qi(1),pa("ngForOf",e.etherTypes))},directives:[$5,n4,t4,J5,a4,c4,Y3,s5,Ef,cf,mf,Sp,O5,Eh,a2,i4,o4,k4,x2,l4,h4,EJ],styles:[".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function z4(t,e){if(1&t&&(ga(0,"mat-option",16),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function V4(t,e){1&t&&ba(0,"app-ports",17,18),2&t&&pa("ethernetPorts",Aa(2).node.properties.ports_mapping)}var U4=function(){return{standalone:!0}};function q4(t,e){if(1&t){var n=ka();ga(0,"div",7),ga(1,"mat-card",8),ga(2,"form",9),ga(3,"mat-form-field",10),ga(4,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().node.name=t})),va(),va(),ga(5,"mat-form-field",12),ga(6,"mat-select",13),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_type=t})),ua(7,z4,2,2,"mat-option",14),va(),va(),va(),ua(8,V4,2,1,"app-ports",15),va(),va()}if(2&t){var i=Aa();Qi(2),pa("formGroup",i.inputForm),Qi(2),pa("ngModel",i.node.name),Qi(2),pa("ngModelOptions",jc(6,U4))("ngModel",i.node.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngIf",i.node.properties)}}var G4=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.ethernetSwitchesConfigurationService=r,this.consoleTypes=[],this.inputForm=this.formBuilder.group({name:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=t.node.name,t.getConfiguration()}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.ethernetSwitchesConfigurationService.getConsoleTypesForEthernetSwitches()},t.prototype.onSaveClick=function(){var t=this;this.inputForm.valid?(this.node.properties.ports_mapping=this.portsComponent.ethernetPorts,this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()}))):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(K5))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-ethernet-switch"]],viewQuery:function(t,e){var n;1&t&&nl(H4,!0),2&t&&tl(n=sl())&&(e.portsComponent=n.first)},decls:10,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],["class","default-content",4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ethernetPorts",4,"ngIf"],[3,"value"],[3,"ethernetPorts"],["ports",""]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ua(4,q4,9,7,"div",3),va(),va(),ga(5,"div",4),ga(6,"button",5),xa("click",(function(){return e.onCancelClick()})),ds(7,"Cancel"),va(),ga(8,"button",6),xa("click",(function(){return e.onSaveClick()})),ds(9,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(3),pa("ngIf",e.node))},directives:[r1,Ah,a1,a2,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,EJ,H4],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}();function W4(t,e){1&t&&(ga(0,"th",24),ds(1," Port : DLCI"),va())}function K4(t,e){if(1&t&&(ga(0,"td",25),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.portIn," ")}}function X4(t,e){1&t&&(ga(0,"th",24),ds(1," Port : DLCI "),va())}function Y4(t,e){if(1&t&&(ga(0,"td",25),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.portOut," ")}}function Z4(t,e){1&t&&(ga(0,"th",24),ds(1," Actions "),va())}function Q4(t,e){if(1&t){var n=ka();ga(0,"td",25),ga(1,"button",26),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(2).delete(t)})),ga(2,"mat-icon",27),ds(3,"delete"),va(),va(),va()}}function $4(t,e){1&t&&ba(0,"tr",28)}function J4(t,e){1&t&&ba(0,"tr",29)}function t6(t,e){if(1&t&&(ga(0,"table",16),ya(1,17),ua(2,W4,2,0,"th",18),ua(3,K4,2,1,"td",19),_a(),ya(4,20),ua(5,X4,2,0,"th",18),ua(6,Y4,2,1,"td",19),_a(),ya(7,21),ua(8,Z4,2,0,"th",18),ua(9,Q4,4,0,"td",19),_a(),ua(10,$4,1,0,"tr",22),ua(11,J4,1,0,"tr",23),va()),2&t){var n=Aa();pa("dataSource",n.nodeMappingsDataSource),Qi(10),pa("matHeaderRowDef",n.displayedColumns),Qi(1),pa("matRowDefColumns",n.displayedColumns)}}var e6=function(){function t(t,e,n,i){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.consoleTypes=[],this.nodeMappings=new Map,this.nodeMappingsDataSource=[],this.dataSource=[],this.displayedColumns=["portIn","portOut","actions"],this.sourcePort="",this.sourceDlci="",this.destinationPort="",this.destinationDlci="",this.nameForm=this.formBuilder.group({name:new hp("",kf.required)}),this.inputForm=this.formBuilder.group({sourcePort:new hp("",kf.required),sourceDlci:new hp("",kf.required),destinationPort:new hp("",kf.required),destinationDlci:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name;var n=e.properties.mappings;Object.keys(n).forEach((function(e){t.nodeMappings.set(e,n[e])})),t.nodeMappings.forEach((function(e,n){t.nodeMappingsDataSource.push({portIn:n,portOut:e})}))}))},t.prototype.delete=function(t){this.nodeMappingsDataSource=this.nodeMappingsDataSource.filter((function(e){return e!==t}))},t.prototype.add=function(){if(this.inputForm.valid){var t={portIn:this.sourcePort+":"+this.sourceDlci,portOut:this.destinationPort+":"+this.destinationDlci};this.nodeMappingsDataSource.filter((function(e){return e.portIn===t.portIn})).length>0?this.toasterService.error("Mapping already defined."):(this.nodeMappingsDataSource=this.nodeMappingsDataSource.concat([t]),this.clearUserInput())}else this.toasterService.error("Fill all required fields.")},t.prototype.clearUserInput=function(){this.sourcePort="0",this.sourceDlci="0",this.destinationPort="0",this.destinationDlci="0"},t.prototype.strMapToObj=function(t){for(var e=Object.create(null),n=0,i=t;n<i.length;n++){var r=i[n];e[r[0]]=r[1]}return e},t.prototype.onSaveClick=function(){var t=this;this.nameForm.valid?(this.nodeMappings.clear(),this.nodeMappingsDataSource.forEach((function(e){t.nodeMappings.set(e.portIn,e.portOut)})),this.node.properties.mappings=Array.from(this.nodeMappings).reduce((function(t,e){var n;return Object.assign(t,((n={})[e[0]]=e[1],n))}),{}),this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()}))):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-switch"]],decls:29,vars:9,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],["class","table","mat-table","",3,"dataSource",4,"ngIf"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","sourcePort","placeholder","Port",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","sourceDlci","placeholder","DLCI",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","destinationPort","placeholder","Port",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","destinationDlci","placeholder","DLCI",3,"ngModel","ngModelChange"],["mat-button","",1,"form-field",3,"click"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["mat-table","",1,"table",3,"dataSource"],["matColumnDef","portIn"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","portOut"],["matColumnDef","actions"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-header-cell",""],["mat-cell",""],["mat-icon-button","","matTooltip","Delete port","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Delete port"],["mat-header-row",""],["mat-row",""]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card"),ua(6,t6,12,3,"table",4),ba(7,"br"),ga(8,"form",5),ga(9,"mat-form-field",6),ga(10,"input",7),xa("ngModelChange",(function(t){return e.node.name=t})),va(),va(),va(),ga(11,"form",5),ds(12," Source "),ga(13,"mat-form-field",6),ga(14,"input",8),xa("ngModelChange",(function(t){return e.sourcePort=t})),va(),va(),ga(15,"mat-form-field",6),ga(16,"input",9),xa("ngModelChange",(function(t){return e.sourceDlci=t})),va(),va(),ds(17," Destination "),ga(18,"mat-form-field",6),ga(19,"input",10),xa("ngModelChange",(function(t){return e.destinationPort=t})),va(),va(),ga(20,"mat-form-field",6),ga(21,"input",11),xa("ngModelChange",(function(t){return e.destinationDlci=t})),va(),va(),va(),ga(22,"button",12),xa("click",(function(){return e.add()})),ds(23,"Add"),va(),va(),va(),va(),va(),ga(24,"div",13),ga(25,"button",14),xa("click",(function(){return e.onCancelClick()})),ds(26,"Cancel"),va(),ga(27,"button",15),xa("click",(function(){return e.onSaveClick()})),ds(28,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.nodeMappingsDataSource.length),Qi(2),pa("formGroup",e.nameForm),Qi(2),pa("ngModel",e.node.name),Qi(1),pa("formGroup",e.inputForm),Qi(3),pa("ngModel",e.sourcePort),Qi(2),pa("ngModel",e.sourceDlci),Qi(3),pa("ngModel",e.destinationPort),Qi(2),pa("ngModel",e.destinationDlci))},directives:[r1,f3,Ah,xp,gf,Pp,Y3,s5,cf,mf,Fp,Ef,a2,a1,$5,n4,t4,J5,a4,c4,i4,o4,k4,x2,l4,h4],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),n6=function(){function t(){}return t.prototype.getConsoleTypes=function(){return["telnet","none"]},t.prototype.getOnCloseoptions=function(){return[["Power off the VM","power_off"],["Send the shutdown signal (ACPI)","shutdown_signal"],["Save the VM state","save_vm_state"]]},t.prototype.getCategories=function(){return[["Default","guest"],["Routers","routers"],["Switches","switches"],["End devices","end_devices"],["Security devices","security_devices"]]},t.prototype.getNetworkTypes=function(){return["PCnet-PCI II (Am79C970A)","PCNet-FAST III (Am79C973)","Intel PRO/1000 MT Desktop (82540EM)","Intel PRO/1000 T Server (82543GC)","Intel PRO/1000 MT Server (82545EM)","Paravirtualized Network (virtio-net)"]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function i6(t,e){1&t&&(ga(0,"th",10),ds(1," Adapter number "),va())}function r6(t,e){if(1&t&&(ga(0,"td",11),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" Adapter ",n.adapter_number," ")}}function o6(t,e){1&t&&(ga(0,"th",10),ds(1," Port name "),va())}function a6(t,e){if(1&t&&(ga(0,"td",11),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" Ethernet ",n.adapter_number," ")}}function s6(t,e){1&t&&(ga(0,"th",10),ds(1," Adapter type "),va())}function c6(t,e){if(1&t&&(ga(0,"mat-option",14),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function l6(t,e){if(1&t){var n=ka();ga(0,"td",11),ga(1,"mat-select",12),xa("ngModelChange",(function(t){return Se(n),e.$implicit.adapter_type=t})),ua(2,c6,2,2,"mat-option",13),va(),va()}if(2&t){var i=e.$implicit,r=Aa();Qi(1),pa("ngModel",i.adapter_type),Qi(1),pa("ngForOf",r.networkTypes)}}function u6(t,e){1&t&&(ga(0,"th",10),ds(1," Actions "),va())}function h6(t,e){if(1&t){var n=ka();ga(0,"td",11),ga(1,"button",15),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().delete(t)})),ga(2,"mat-icon",16),ds(3,"delete"),va(),va(),va()}}function d6(t,e){1&t&&ba(0,"tr",17)}function f6(t,e){1&t&&ba(0,"tr",18)}var p6=function(){function t(){this.networkTypes=[],this.displayedColumns=[],this.adapters=[]}return t.prototype.onAdd=function(){this.adapters=this.adapters.concat([{adapter_number:this.adapters.length,adapter_type:this.networkTypes[0]}])},t.prototype.delete=function(t){this.adapters=this.adapters.filter((function(e){return e!==t}))},t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["app-custom-adapters-table"]],inputs:{networkTypes:"networkTypes",displayedColumns:"displayedColumns",adapters:"adapters"},decls:17,vars:3,consts:[["mat-table","",1,"table",3,"dataSource"],["matColumnDef","adapter_number"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","port_name"],["matColumnDef","adapter_type"],["matColumnDef","actions"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-button","",1,"form-field",3,"click"],["mat-header-cell",""],["mat-cell",""],["placeholder","Type",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"value"],["mat-icon-button","","matTooltip","Delete adapter","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Delete adapter"],["mat-header-row",""],["mat-row",""]],template:function(t,e){1&t&&(ga(0,"table",0),ya(1,1),ua(2,i6,2,0,"th",2),ua(3,r6,2,1,"td",3),_a(),ya(4,4),ua(5,o6,2,0,"th",2),ua(6,a6,2,1,"td",3),_a(),ya(7,5),ua(8,s6,2,0,"th",2),ua(9,l6,3,2,"td",3),_a(),ya(10,6),ua(11,u6,2,0,"th",2),ua(12,h6,4,0,"td",3),_a(),ua(13,d6,1,0,"tr",7),ua(14,f6,1,0,"tr",8),va(),ga(15,"button",9),xa("click",(function(){return e.onAdd()})),ds(16,"Add"),va()),2&t&&(pa("dataSource",e.adapters),Qi(13),pa("matHeaderRowDef",e.displayedColumns),Qi(1),pa("matRowDefColumns",e.displayedColumns))},directives:[$5,n4,t4,J5,a4,c4,a2,i4,o4,O5,mf,Sp,Eh,EJ,k4,x2,l4,h4],styles:[".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),m6=["customAdapters"];function g6(t,e){if(1&t&&(ga(0,"mat-option",26),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function v6(t,e){if(1&t&&(ga(0,"mat-option",26),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}var b6=function(){return{standalone:!0}};function y6(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ba(2,"br"),ga(3,"form",10),ga(4,"mat-form-field",11),ga(5,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().node.name=t})),va(),va(),ga(6,"mat-form-field",13),ga(7,"mat-select",14),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_type=t})),ua(8,g6,2,2,"mat-option",15),va(),va(),ga(9,"mat-checkbox",16),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_auto_start=t})),ds(10," Auto start console "),va(),ga(11,"mat-form-field",11),ga(12,"input",17),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.ram=t})),va(),ga(13,"span",18),ds(14,"MB"),va(),va(),ga(15,"mat-form-field",11),ga(16,"mat-select",19),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.on_close=t})),ua(17,v6,2,2,"mat-option",15),va(),va(),va(),ga(18,"mat-checkbox",20),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.headless=t})),ds(19," Start VM in headless mode "),va(),va(),ga(20,"mat-tab",21),ba(21,"br"),ga(22,"mat-checkbox",20),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.use_any_adapter=t})),ds(23," Allow GNS3 to use any configured VirtualBox adapter "),va(),ba(24,"app-custom-adapters-table",22,23),va(),ga(26,"mat-tab",24),ga(27,"mat-form-field",11),ga(28,"textarea",25),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.usage=t})),va(),va(),va(),va()}if(2&t){var i=Aa();Qi(3),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.node.name),Qi(2),pa("ngModelOptions",jc(17,b6))("ngModel",i.node.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModelOptions",jc(18,b6))("ngModel",i.node.console_auto_start),Qi(3),pa("ngModel",i.node.properties.ram),Qi(4),pa("ngModelOptions",jc(19,b6))("ngModel",i.node.properties.on_close),Qi(1),pa("ngForOf",i.onCloseOptions),Qi(1),pa("ngModel",i.node.properties.headless),Qi(4),pa("ngModel",i.node.properties.use_any_adapter),Qi(2),pa("networkTypes",i.networkTypes)("displayedColumns",i.displayedColumns)("adapters",i.node.ports),Qi(4),pa("ngModel",i.node.properties.usage)}}var _6=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.virtualBoxConfigurationService=r,this.consoleTypes=[],this.onCloseOptions=[],this.displayedColumns=["adapter_number","port_name","adapter_type","actions"],this.networkTypes=[],this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required),ram:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name,t.getConfiguration()}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.virtualBoxConfigurationService.getConsoleTypes(),this.onCloseOptions=this.virtualBoxConfigurationService.getOnCloseoptions(),this.networkTypes=this.virtualBoxConfigurationService.getNetworkTypes()},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid?(this.node.custom_adapters=[],this.customAdapters.adapters.forEach((function(e){t.node.custom_adapters.push({adapter_number:e.adapter_number,adapter_type:e.adapter_type})})),this.node.properties.adapters=this.node.custom_adapters.length,this.nodeService.updateNodeWithCustomAdapters(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()}))):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(n6))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-virtualbox"]],viewQuery:function(t,e){var n;1&t&&nl(m6,!0),2&t&&tl(n=sl())&&(e.customAdapters=n.first)},decls:12,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["label","General settings"],[3,"formGroup"],[1,"form-field"],["matInput","","formControlName","name","type","text","placeholder","Name",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","formControlName","ram","type","number","placeholder","RAM",3,"ngModel","ngModelChange"],["matSuffix",""],["placeholder","On close",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ngModel","ngModelChange"],["label","Network"],[3,"networkTypes","displayedColumns","adapters"],["customAdapters",""],["label","Usage"],["matInput","","type","text",3,"ngModel","ngModelChange"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ua(6,y6,29,20,"mat-tab-group",5),va(),va(),va(),va(),ga(7,"div",6),ga(8,"button",7),xa("click",(function(){return e.onCancelClick()})),ds(9,"Cancel"),va(),ga(10,"button",8),xa("click",(function(){return e.onSaveClick()})),ds(11,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.name))},directives:[r1,f3,Ah,a1,a2,U1,I1,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,F5,Ef,q3,p6,EJ],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),w6=function(){function t(t){this.httpServer=t}return t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.getImagePath=function(t,e){return"http://"+t.host+":"+t.port+"/v2/compute/qemu/images/"+e},t.prototype.getBinaries=function(t){return this.httpServer.get(t,"/computes/local/qemu/binaries")},t.prototype.getImages=function(t){return this.httpServer.get(t,"/compute/qemu/images")},t.prototype.addImage=function(t,e){return this.httpServer.post(t,"/compute/qemu/img",e)},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),k6=function(){function t(){}return t.prototype.getConsoleTypes=function(){return["telnet","vnc","spice","spice+agent","none"]},t.prototype.getDiskInterfaces=function(){return["ide","sata","scsi","sd","mtd","floppy","pflash","virtio","nvme","none"]},t.prototype.getNetworkTypes=function(){return["e1000","e1000-82544gc","e1000-82545em","e1000e","rocker","Intel Gigabit Ethernet","i82550","i82551","i82557a","i82557b","i82557c","i82558a","i82558b","i82559a","i82559b","i82559c","i82559er","i82562","i82801","ne2k_pci","pcnet","rtl8139","virtio","virtio-net-pci","vmxnet3"]},t.prototype.getBootPriorities=function(){return[["HDD","c"],["CD/DVD-ROM","d"],["Network","n"],["HDD or Network","cn"],["HDD or CD/DVD-ROM","cd"]]},t.prototype.getOnCloseOptions=function(){return[["Power off the VM","power_off"],["Send the shutdown signal (ACPI)","shutdown_signal"],["Save the VM state","save_vm_state"]]},t.prototype.getCategories=function(){return[["Default","guest"],["Routers","routers"],["Switches","switches"],["End devices","end_devices"],["Security devices","security_devices"]]},t.prototype.getPriorities=function(){return["realtime","very high","high","normal","low","very low"]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),C6=["input"],S6=function(){return{enterDuration:150}},x6=["*"],O6=new ht("mat-radio-default-options",{providedIn:"root",factory:function(){return{color:"accent"}}}),M6=0,T6={provide:nf,useExisting:Y((function(){return A6})),multi:!0},E6=function t(e,n){Object(m.a)(this,t),this.source=e,this.value=n},P6=function(){var t=function(){function t(e){Object(m.a)(this,t),this._changeDetector=e,this._value=null,this._name="mat-radio-group-".concat(M6++),this._selected=null,this._isInitialized=!1,this._labelPosition="after",this._disabled=!1,this._required=!1,this._controlValueAccessorChangeFn=function(){},this.onTouched=function(){},this.change=new Uc}return Object(g.a)(t,[{key:"_checkSelectedRadioButton",value:function(){this._selected&&!this._selected.checked&&(this._selected.checked=!0)}},{key:"ngAfterContentInit",value:function(){this._isInitialized=!0}},{key:"_touch",value:function(){this.onTouched&&this.onTouched()}},{key:"_updateRadioButtonNames",value:function(){var t=this;this._radios&&this._radios.forEach((function(e){e.name=t.name,e._markForCheck()}))}},{key:"_updateSelectedRadioFromValue",value:function(){var t=this;this._radios&&(null===this._selected||this._selected.value!==this._value)&&(this._selected=null,this._radios.forEach((function(e){e.checked=t.value===e.value,e.checked&&(t._selected=e)})))}},{key:"_emitChangeEvent",value:function(){this._isInitialized&&this.change.emit(new E6(this._selected,this._value))}},{key:"_markRadiosForCheck",value:function(){this._radios&&this._radios.forEach((function(t){return t._markForCheck()}))}},{key:"writeValue",value:function(t){this.value=t,this._changeDetector.markForCheck()}},{key:"registerOnChange",value:function(t){this._controlValueAccessorChangeFn=t}},{key:"registerOnTouched",value:function(t){this.onTouched=t}},{key:"setDisabledState",value:function(t){this.disabled=t,this._changeDetector.markForCheck()}},{key:"name",get:function(){return this._name},set:function(t){this._name=t,this._updateRadioButtonNames()}},{key:"labelPosition",get:function(){return this._labelPosition},set:function(t){this._labelPosition="before"===t?"before":"after",this._markRadiosForCheck()}},{key:"value",get:function(){return this._value},set:function(t){this._value!==t&&(this._value=t,this._updateSelectedRadioFromValue(),this._checkSelectedRadioButton())}},{key:"selected",get:function(){return this._selected},set:function(t){this._selected=t,this.value=t?t.value:null,this._checkSelectedRadioButton()}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t),this._markRadiosForCheck()}},{key:"required",get:function(){return this._required},set:function(t){this._required=nm(t),this._markRadiosForCheck()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Po))},t.\u0275dir=Wt({type:t,inputs:{name:"name",labelPosition:"labelPosition",value:"value",selected:"selected",disabled:"disabled",required:"required",color:"color"},outputs:{change:"change"}}),t}(),A6=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(P6);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-radio-group"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,D6,!0),2&t&&tl(i=sl())&&(e._radios=i)},hostAttrs:["role","radiogroup",1,"mat-radio-group"],exportAs:["matRadioGroup"],features:[Ns([T6]),ws]});var e=zn(t);return t}(),j6=eJ(nJ((function t(e){Object(m.a)(this,t),this._elementRef=e}))),I6=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c){var l;return Object(m.a)(this,n),(l=e.call(this,i))._changeDetector=r,l._focusMonitor=o,l._radioDispatcher=a,l._animationMode=s,l._providerOverride=c,l._uniqueId="mat-radio-".concat(++M6),l.id=l._uniqueId,l.change=new Uc,l._checked=!1,l._value=null,l._removeUniqueSelectionListener=function(){},l.radioGroup=t,l._removeUniqueSelectionListener=a.listen((function(t,e){t!==l.id&&e===l.name&&(l.checked=!1)})),l}return Object(g.a)(n,[{key:"focus",value:function(t){this._focusMonitor.focusVia(this._inputElement,"keyboard",t)}},{key:"_markForCheck",value:function(){this._changeDetector.markForCheck()}},{key:"ngOnInit",value:function(){this.radioGroup&&(this.checked=this.radioGroup.value===this._value,this.name=this.radioGroup.name)}},{key:"ngAfterViewInit",value:function(){var t=this;this._focusMonitor.monitor(this._elementRef,!0).subscribe((function(e){!e&&t.radioGroup&&t.radioGroup._touch()}))}},{key:"ngOnDestroy",value:function(){this._focusMonitor.stopMonitoring(this._elementRef),this._removeUniqueSelectionListener()}},{key:"_emitChangeEvent",value:function(){this.change.emit(new E6(this,this._value))}},{key:"_isRippleDisabled",value:function(){return this.disableRipple||this.disabled}},{key:"_onInputClick",value:function(t){t.stopPropagation()}},{key:"_onInputChange",value:function(t){t.stopPropagation();var e=this.radioGroup&&this.value!==this.radioGroup.value;this.checked=!0,this._emitChangeEvent(),this.radioGroup&&(this.radioGroup._controlValueAccessorChangeFn(this.value),e&&this.radioGroup._emitChangeEvent())}},{key:"_setDisabled",value:function(t){this._disabled!==t&&(this._disabled=t,this._changeDetector.markForCheck())}},{key:"checked",get:function(){return this._checked},set:function(t){var e=nm(t);this._checked!==e&&(this._checked=e,e&&this.radioGroup&&this.radioGroup.value!==this.value?this.radioGroup.selected=this:!e&&this.radioGroup&&this.radioGroup.value===this.value&&(this.radioGroup.selected=null),e&&this._radioDispatcher.notify(this.id,this.name),this._changeDetector.markForCheck())}},{key:"value",get:function(){return this._value},set:function(t){this._value!==t&&(this._value=t,null!==this.radioGroup&&(this.checked||(this.checked=this.radioGroup.value===t),this.checked&&(this.radioGroup.selected=this)))}},{key:"labelPosition",get:function(){return this._labelPosition||this.radioGroup&&this.radioGroup.labelPosition||"after"},set:function(t){this._labelPosition=t}},{key:"disabled",get:function(){return this._disabled||null!==this.radioGroup&&this.radioGroup.disabled},set:function(t){this._setDisabled(nm(t))}},{key:"required",get:function(){return this._required||this.radioGroup&&this.radioGroup.required},set:function(t){this._required=nm(t)}},{key:"color",get:function(){return this._color||this.radioGroup&&this.radioGroup.color||this._providerOverride&&this._providerOverride.color||"accent"},set:function(t){this._color=t}},{key:"inputId",get:function(){return"".concat(this.id||this._uniqueId,"-input")}}]),n}(j6);return t.\u0275fac=function(e){return new(e||t)(da(P6,8),da(Us),da(Po),da(S$),da(pm),da(Cy,8),da(O6,8))},t.\u0275dir=Wt({type:t,viewQuery:function(t,e){var n;1&t&&nl(C6,!0),2&t&&tl(n=sl())&&(e._inputElement=n.first)},inputs:{id:"id",checked:"checked",value:"value",labelPosition:"labelPosition",disabled:"disabled",required:"required",color:"color",name:"name",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],ariaDescribedby:["aria-describedby","ariaDescribedby"]},outputs:{change:"change"},features:[ws]}),t}(),D6=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c){return Object(m.a)(this,n),e.call(this,t,i,r,o,a,s,c)}return n}(I6);return t.\u0275fac=function(e){return new(e||t)(da(A6,8),da(Us),da(Po),da(S$),da(pm),da(Cy,8),da(O6,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-radio-button"]],hostAttrs:[1,"mat-radio-button"],hostVars:17,hostBindings:function(t,e){1&t&&xa("focus",(function(){return e._inputElement.nativeElement.focus()})),2&t&&(oa("tabindex",-1)("id",e.id)("aria-label",null)("aria-labelledby",null)("aria-describedby",null),Qa("mat-radio-checked",e.checked)("mat-radio-disabled",e.disabled)("_mat-animation-noopable","NoopAnimations"===e._animationMode)("mat-primary","primary"===e.color)("mat-accent","accent"===e.color)("mat-warn","warn"===e.color))},inputs:{disableRipple:"disableRipple",tabIndex:"tabIndex"},exportAs:["matRadioButton"],features:[ws],ngContentSelectors:x6,decls:13,vars:19,consts:[[1,"mat-radio-label"],["label",""],[1,"mat-radio-container"],[1,"mat-radio-outer-circle"],[1,"mat-radio-inner-circle"],["type","radio",1,"mat-radio-input","cdk-visually-hidden",3,"id","checked","disabled","tabIndex","required","change","click"],["input",""],["mat-ripple","",1,"mat-radio-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered","matRippleRadius","matRippleAnimation"],[1,"mat-ripple-element","mat-radio-persistent-ripple"],[1,"mat-radio-label-content"],[2,"display","none"]],template:function(t,e){if(1&t&&(Ia(),ga(0,"label",0,1),ga(2,"div",2),ba(3,"div",3),ba(4,"div",4),ga(5,"input",5,6),xa("change",(function(t){return e._onInputChange(t)}))("click",(function(t){return e._onInputClick(t)})),va(),ga(7,"div",7),ba(8,"div",8),va(),va(),ga(9,"div",9),ga(10,"span",10),ds(11,"\xa0"),va(),Da(12),va(),va()),2&t){var n=ha(1);oa("for",e.inputId),Qi(5),pa("id",e.inputId)("checked",e.checked)("disabled",e.disabled)("tabIndex",e.tabIndex)("required",e.required),oa("name",e.name)("value",e.value)("aria-label",e.ariaLabel)("aria-labelledby",e.ariaLabelledby)("aria-describedby",e.ariaDescribedby),Qi(2),pa("matRippleTrigger",n)("matRippleDisabled",e._isRippleDisabled())("matRippleCentered",!0)("matRippleRadius",20)("matRippleAnimation",jc(18,S6)),Qi(2),Qa("mat-radio-label-before","before"==e.labelPosition)}},directives:[yJ],styles:[".mat-radio-button{display:inline-block;-webkit-tap-highlight-color:transparent;outline:0}.mat-radio-label{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;display:inline-flex;align-items:center;white-space:nowrap;vertical-align:middle;width:100%}.mat-radio-container{box-sizing:border-box;display:inline-block;position:relative;width:20px;height:20px;flex-shrink:0}.mat-radio-outer-circle{box-sizing:border-box;height:20px;left:0;position:absolute;top:0;transition:border-color ease 280ms;width:20px;border-width:2px;border-style:solid;border-radius:50%}._mat-animation-noopable .mat-radio-outer-circle{transition:none}.mat-radio-inner-circle{border-radius:50%;box-sizing:border-box;height:20px;left:0;position:absolute;top:0;transition:transform ease 280ms,background-color ease 280ms;width:20px;transform:scale(0.001)}._mat-animation-noopable .mat-radio-inner-circle{transition:none}.mat-radio-checked .mat-radio-inner-circle{transform:scale(0.5)}.cdk-high-contrast-active .mat-radio-checked .mat-radio-inner-circle{border:solid 10px}.mat-radio-label-content{-webkit-user-select:auto;-moz-user-select:auto;-ms-user-select:auto;user-select:auto;display:inline-block;order:0;line-height:inherit;padding-left:8px;padding-right:0}[dir=rtl] .mat-radio-label-content{padding-right:8px;padding-left:0}.mat-radio-label-content.mat-radio-label-before{order:-1;padding-left:0;padding-right:8px}[dir=rtl] .mat-radio-label-content.mat-radio-label-before{padding-right:0;padding-left:8px}.mat-radio-disabled,.mat-radio-disabled .mat-radio-label{cursor:default}.mat-radio-button .mat-radio-ripple{position:absolute;left:calc(50% - 20px);top:calc(50% - 20px);height:40px;width:40px;z-index:1;pointer-events:none}.mat-radio-button .mat-radio-ripple .mat-ripple-element:not(.mat-radio-persistent-ripple){opacity:.16}.mat-radio-persistent-ripple{width:100%;height:100%;transform:none}.mat-radio-container:hover .mat-radio-persistent-ripple{opacity:.04}.mat-radio-button:not(.mat-radio-disabled).cdk-keyboard-focused .mat-radio-persistent-ripple,.mat-radio-button:not(.mat-radio-disabled).cdk-program-focused .mat-radio-persistent-ripple{opacity:.12}.mat-radio-persistent-ripple,.mat-radio-disabled .mat-radio-container:hover .mat-radio-persistent-ripple{opacity:0}@media(hover: none){.mat-radio-container:hover .mat-radio-persistent-ripple{display:none}}.mat-radio-input{bottom:0;left:50%}.cdk-high-contrast-active .mat-radio-disabled{opacity:.5}\n"],encapsulation:2,changeDetection:0}),t}(),R6=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[_J,$$],$$]}),t}();function L6(t,e){if(1&t&&(ga(0,"mat-option",16),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function F6(t,e){if(1&t&&(ga(0,"mat-option",16),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function N6(t,e){if(1&t&&(ga(0,"mat-option",16),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.value),Qi(1),ps(" ",n.name," ")}}function B6(t,e){if(1&t&&(ga(0,"mat-option",16),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function H6(t,e){if(1&t&&(ga(0,"mat-option",16),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.value),Qi(1),ps(" ",n.name," ")}}function z6(t,e){if(1&t){var n=ka();ga(0,"div"),ds(1," Size options "),ga(2,"mat-form-field",6),ga(3,"mat-select",8),xa("ngModelChange",(function(t){return Se(n),Aa().qemuImg.preallocation=t})),ua(4,F6,2,2,"mat-option",9),va(),va(),ga(5,"mat-form-field",6),ga(6,"mat-select",17),xa("ngModelChange",(function(t){return Se(n),Aa().qemuImg.cluster_size=t})),ua(7,N6,2,2,"mat-option",9),va(),va(),ds(8," Refcounts "),ga(9,"mat-form-field",6),ga(10,"mat-select",18),xa("ngModelChange",(function(t){return Se(n),Aa().qemuImg.lazy_refcounts=t})),ua(11,B6,2,2,"mat-option",9),va(),va(),ga(12,"mat-form-field",6),ga(13,"mat-select",19),xa("ngModelChange",(function(t){return Se(n),Aa().qemuImg.refcount_bits=t})),ua(14,H6,2,2,"mat-option",9),va(),va(),va()}if(2&t){var i=Aa();Qi(3),pa("ngModel",i.qemuImg.preallocation),Qi(1),pa("ngForOf",i.preallocationsOptions),Qi(2),pa("ngModel",i.qemuImg.cluster_size),Qi(1),pa("ngForOf",i.clusterSizeOptions),Qi(3),pa("ngModel",i.qemuImg.lazy_refcounts),Qi(1),pa("ngForOf",i.lazyRefcountsOptions),Qi(2),pa("ngModel",i.qemuImg.refcount_bits),Qi(1),pa("ngForOf",i.clusterSizeOptions)}}function V6(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"mat-radio-group",20),ga(2,"mat-radio-button",21),xa("click",(function(){return Se(n),Aa().setSubformat("dynamic")})),ds(3,"Dynamic"),va(),ga(4,"mat-radio-button",22),xa("click",(function(){return Se(n),Aa().setSubformat("fixed")})),ds(5,"Fixed"),va(),va(),va()}}function U6(t,e){if(1&t&&(ga(0,"mat-option",16),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function q6(t,e){if(1&t){var n=ka();ga(0,"div"),ds(1," Adapter type"),ba(2,"br"),ga(3,"mat-radio-group",23),ga(4,"mat-radio-button",21),xa("click",(function(){return Se(n),Aa().setAdapterType("ide")})),ds(5,"IDE"),va(),ga(6,"mat-radio-button",22),xa("click",(function(){return Se(n),Aa().setAdapterType("lsilogic")})),ds(7,"LSI Logic"),va(),ga(8,"mat-radio-button",24),xa("click",(function(){return Se(n),Aa().setAdapterType("buslogic")})),ds(9,"BusLogic"),va(),ga(10,"mat-radio-button",25),xa("click",(function(){return Se(n),Aa().setAdapterType("legacyESX")})),ds(11,"Legacy (ESX)"),va(),va(),ba(12,"br"),ba(13,"br"),ds(14," Image file sizing mode"),ba(15,"br"),ga(16,"mat-radio-group",20),ga(17,"mat-radio-button",21),xa("click",(function(){return Se(n),Aa().setSubformat("streamOptimized")})),ds(18,"Stream optimized"),va(),ga(19,"mat-radio-button",22),xa("click",(function(){return Se(n),Aa().setSubformat("twoGbMaxExtentSparse")})),ds(20,"Split every 2GB (sparse)"),va(),ga(21,"mat-radio-button",24),xa("click",(function(){return Se(n),Aa().setSubformat("twoGbMaxExtentFlat")})),ds(22,"Split every 2GB (flat)"),va(),ga(23,"mat-radio-button",25),xa("click",(function(){return Se(n),Aa().setSubformat("monolithicSparse")})),ds(24,"Monolithic sparse"),va(),ga(25,"mat-radio-button",26),xa("click",(function(){return Se(n),Aa().setSubformat("monolithicFlat")})),ds(26,"Monolithic flat"),va(),va(),ba(27,"br"),ba(28,"br"),ga(29,"mat-select",27),xa("ngModelChange",(function(t){return Se(n),Aa().qemuImg.zeroed_grain=t})),ua(30,U6,2,2,"mat-option",9),va(),va()}if(2&t){var i=Aa();Qi(29),pa("ngModel",i.qemuImg.zeroed_grain),Qi(1),pa("ngForOf",i.zeroedGrainOptions)}}var G6=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.qemuService=r,this.formatOptions=["qcow2","qcow","vhd","vdi","vmdk","raw"],this.preallocationsOptions=["off","metadata","falloc","full"],this.clusterSizeOptions=[{name:"512",value:512},{name:"1k",value:1024},{name:"2k",value:2048},{name:"4k",value:4096},{name:"8k",value:8192},{name:"16k",value:16384},{name:"32k",value:32768},{name:"64k",value:65536},{name:"128k",value:131072},{name:"256k",value:262144},{name:"512k",value:524288},{name:"1024k",value:1048576},{name:"2048k",value:2097152}],this.lazyRefcountsOptions=["off","on"],this.refcountBitsOptions=[1,2,4,8,16,32,64],this.zeroedGrainOptions=["on","off"],this.inputForm=this.formBuilder.group({qemu_img:new hp("",kf.required),path:new hp("",kf.required),size:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){this.qemuImg={}},t.prototype.setSubformat=function(t){this.qemuImg.subformat=t},t.prototype.onSaveClick=function(){var t=this;this.inputForm.valid&&this.qemuImg.format?this.qemuService.addImage(this.server,this.qemuImg).subscribe((function(){t.dialogRef.close()})):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(w6))},t.\u0275cmp=Ht({type:t,selectors:[["app-qemu-image-creator"]],decls:25,vars:10,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","qemu_img","placeholder","Qemu image path",3,"ngModel","ngModelChange"],["placeholder","Image format",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[4,"ngIf"],["matInput","","type","text","formControlName","path","placeholder","File location",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","size","placeholder","Disk size",3,"ngModel","ngModelChange"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[3,"value"],["placeholder","Cluster size",3,"ngModel","ngModelChange"],["placeholder","Lazy refcounts",3,"ngModel","ngModelChange"],["placeholder","Refcount entry size",3,"ngModel","ngModelChange"],["aria-label","Image file sizing mode",1,"radio-selection"],["value","1","checked","",3,"click"],["value","2",3,"click"],["aria-label","Adapter type",1,"radio-selection"],["value","3",3,"click"],["value","4",3,"click"],["value","5",3,"click"],["placeholder","Zeroed grain",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Qemu image configurator"),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ga(6,"form",5),ga(7,"mat-form-field",6),ga(8,"input",7),xa("ngModelChange",(function(t){return e.qemuImg.qemu_img=t})),va(),va(),va(),ga(9,"mat-form-field",6),ga(10,"mat-select",8),xa("ngModelChange",(function(t){return e.qemuImg.format=t})),ua(11,L6,2,2,"mat-option",9),va(),va(),ua(12,z6,15,8,"div",10),ua(13,V6,6,0,"div",10),ua(14,q6,31,2,"div",10),ga(15,"form",5),ga(16,"mat-form-field",6),ga(17,"input",11),xa("ngModelChange",(function(t){return e.qemuImg.path=t})),va(),va(),ga(18,"mat-form-field",6),ga(19,"input",12),xa("ngModelChange",(function(t){return e.qemuImg.size=t})),va(),va(),va(),va(),va(),va(),va(),ga(20,"div",13),ga(21,"button",14),xa("click",(function(){return e.onCancelClick()})),ds(22,"Cancel"),va(),ga(23,"button",15),xa("click",(function(){return e.onSaveClick()})),ds(24,"Apply"),va(),va()),2&t&&(Qi(6),pa("formGroup",e.inputForm),Qi(2),pa("ngModel",e.qemuImg.qemu_img),Qi(2),pa("ngModel",e.qemuImg.format),Qi(1),pa("ngForOf",e.formatOptions),Qi(1),pa("ngIf","qcow2"===e.qemuImg.format),Qi(1),pa("ngIf","vhd"===e.qemuImg.format||"vdi"===e.qemuImg.format),Qi(1),pa("ngIf","vmdk"===e.qemuImg.format),Qi(1),pa("formGroup",e.inputForm),Qi(2),pa("ngModel",e.qemuImg.path),Qi(2),pa("ngModel",e.qemuImg.size))},directives:[r1,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,Ah,Ef,a1,a2,EJ,A6,D6],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),W6=["customAdapters"];function K6(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.path),Qi(1),ps(" ",n.path," ")}}function X6(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Y6(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Z6(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Q6(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.filename),Qi(1),ps(" ",n.filename," ")}}function $6(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function J6(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.filename),Qi(1),ps(" ",n.filename," ")}}function t7(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function e7(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.filename),Qi(1),ps(" ",n.filename," ")}}function n7(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function i7(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.filename),Qi(1),ps(" ",n.filename," ")}}function r7(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function o7(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",11),ga(1,"input",50),xa("ngModelChange",(function(t){return Se(n),Aa(2).node.properties.cpu_throttling=t})),va(),va()}if(2&t){var i=Aa(2);Qi(1),pa("ngModel",i.node.properties.cpu_throttling)}}function a7(t,e){if(1&t&&(ga(0,"mat-option",49),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function s7(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ba(2,"br"),ga(3,"form",10),ga(4,"mat-form-field",11),ga(5,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().node.name=t})),va(),va(),ga(6,"mat-form-field",11),ga(7,"input",13),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.ram=t})),va(),ga(8,"span",14),ds(9,"MB"),va(),va(),va(),ga(10,"mat-form-field",11),ga(11,"input",15),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.cpus=t})),va(),va(),ga(12,"mat-form-field",11),ga(13,"mat-select",16),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.qemu_path=t})),ua(14,K6,2,2,"mat-option",17),va(),va(),ga(15,"mat-form-field",11),ga(16,"mat-select",18),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.boot_priority=t})),ua(17,X6,2,2,"mat-option",17),va(),va(),ga(18,"mat-form-field",11),ga(19,"mat-select",19),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.on_close=t})),ua(20,Y6,2,2,"mat-option",17),va(),va(),ga(21,"mat-form-field",20),ga(22,"mat-select",21),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_type=t})),ua(23,Z6,2,2,"mat-option",17),va(),va(),ga(24,"mat-checkbox",22),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.console_auto_start=t})),ds(25," Auto start console "),va(),va(),ga(26,"mat-tab",23),ga(27,"mat-card"),ga(28,"button",24),xa("click",(function(){return Se(n),Aa().openQemuImageCreator()})),ds(29,"Create Qemu image"),va(),ba(30,"mat-card-title"),ga(31,"mat-card-subtitle"),ds(32," HDA (Primary Master) "),va(),ga(33,"mat-card-content"),ga(34,"mat-select",25),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.hda_disk_image=t})),ua(35,Q6,2,2,"mat-option",17),va(),ga(36,"mat-form-field",11),ga(37,"mat-select",26),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.hda_disk_interface=t})),ua(38,$6,2,2,"mat-option",17),va(),va(),va(),va(),ga(39,"mat-card"),ba(40,"mat-card-title"),ga(41,"mat-card-subtitle"),ds(42," HDB (Primary Slave) "),va(),ga(43,"mat-card-content"),ga(44,"mat-select",25),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.hdb_disk_image=t})),ua(45,J6,2,2,"mat-option",17),va(),ga(46,"mat-form-field",11),ga(47,"mat-select",26),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.hdb_disk_interface=t})),ua(48,t7,2,2,"mat-option",17),va(),va(),va(),va(),ga(49,"mat-card"),ba(50,"mat-card-title"),ga(51,"mat-card-subtitle"),ds(52," HDC (Secondary Master) "),va(),ga(53,"mat-card-content"),ga(54,"mat-select",25),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.hdc_disk_image=t})),ua(55,e7,2,2,"mat-option",17),va(),ga(56,"mat-form-field",11),ga(57,"mat-select",26),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.hdc_disk_interface=t})),ua(58,n7,2,2,"mat-option",17),va(),va(),va(),va(),ga(59,"mat-card"),ba(60,"mat-card-title"),ga(61,"mat-card-subtitle"),ds(62," HDD (Secondary Slave) "),va(),ga(63,"mat-card-content"),ga(64,"mat-select",25),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.hdd_disk_image=t})),ua(65,i7,2,2,"mat-option",17),va(),ga(66,"mat-form-field",11),ga(67,"mat-select",26),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.hdd_disk_interface=t})),ua(68,r7,2,2,"mat-option",17),va(),va(),va(),va(),va(),ga(69,"mat-tab",27),ga(70,"div"),ga(71,"button",28),xa("click",(function(){return Se(n),ha(74).click()})),ds(72,"Browse"),va(),ga(73,"input",29,30),xa("change",(function(t){return Se(n),Aa().uploadCdromImageFile(t)})),va(),ga(75,"mat-form-field",31),ga(76,"input",32),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.cdrom_image=t})),va(),va(),va(),va(),ga(77,"mat-tab",33),ba(78,"br"),ga(79,"mat-checkbox",22),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.legacy_networking=t})),ds(80," Use the legacy networking mode "),va(),ba(81,"br"),ga(82,"mat-checkbox",22),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.replicate_network_connection_state=t})),ds(83," Replicate network connection state "),va(),ba(84,"app-custom-adapters-table",34,35),va(),ga(86,"mat-tab",36),ga(87,"mat-card"),ba(88,"mat-card-title"),ga(89,"mat-card-subtitle"),ds(90," Linux boot specific settings "),va(),ga(91,"mat-card-content"),ga(92,"div"),ga(93,"button",28),xa("click",(function(){return Se(n),ha(96).click()})),ds(94,"Browse"),va(),ga(95,"input",29,37),xa("change",(function(t){return Se(n),Aa().uploadInitrdFile(t)})),va(),ga(97,"mat-form-field",31),ga(98,"input",38),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.initrd=t})),va(),va(),va(),ga(99,"div"),ga(100,"button",28),xa("click",(function(){return Se(n),Aa().filekerenelimage.click()})),ds(101,"Browse"),va(),ga(102,"input",29,39),xa("change",(function(t){return Se(n),Aa().uploadKernelImageFile(t)})),va(),ga(104,"mat-form-field",31),ga(105,"input",40),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.kernel_image=t})),va(),va(),va(),ga(106,"mat-form-field",11),ga(107,"input",41),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.kernel_command_line=t})),va(),va(),va(),va(),ga(108,"mat-card"),ba(109,"mat-card-title"),ga(110,"mat-card-subtitle"),ds(111," Bios "),va(),ga(112,"mat-card-content"),ga(113,"div"),ga(114,"button",28),xa("click",(function(){return Se(n),ha(117).click()})),ds(115,"Browse"),va(),ga(116,"input",29,42),xa("change",(function(t){return Se(n),Aa().uploadBiosFile(t)})),va(),ga(118,"mat-form-field",31),ga(119,"input",43),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.bios_image=t})),va(),va(),va(),va(),va(),ga(120,"mat-card"),ba(121,"mat-card-title"),ga(122,"mat-card-subtitle"),ds(123," Optimization "),va(),ga(124,"mat-card-content"),ga(125,"mat-checkbox",22),xa("ngModelChange",(function(t){return Se(n),Aa().activateCpuThrottling=t})),ds(126," Activate CPU throttling "),va(),ua(127,o7,2,1,"mat-form-field",44),ga(128,"mat-form-field",11),ga(129,"mat-select",45),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.process_priority=t})),ua(130,a7,2,2,"mat-option",17),va(),va(),va(),va(),ga(131,"mat-card"),ba(132,"mat-card-title"),ga(133,"mat-card-subtitle"),ds(134," Additional settings "),va(),ga(135,"mat-card-content"),ga(136,"mat-form-field",11),ga(137,"input",46),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.options=t})),va(),va(),va(),va(),va(),ga(138,"mat-tab",47),ga(139,"mat-form-field",11),ga(140,"textarea",48),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.usage=t})),va(),va(),va(),va()}if(2&t){var i=Aa();Qi(3),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.node.name),Qi(2),pa("ngModel",i.node.properties.ram),Qi(4),pa("ngModel",i.node.properties.cpus),Qi(2),pa("ngModel",i.node.properties.qemu_path),Qi(1),pa("ngForOf",i.binaries),Qi(2),pa("ngModel",i.node.properties.boot_priority),Qi(1),pa("ngForOf",i.bootPriorities),Qi(2),pa("ngModel",i.node.properties.on_close),Qi(1),pa("ngForOf",i.onCloseOptions),Qi(2),pa("ngModel",i.node.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModel",i.node.properties.console_auto_start),Qi(10),pa("ngModel",i.node.properties.hda_disk_image),Qi(1),pa("ngForOf",i.qemuImages),Qi(2),pa("ngModel",i.node.properties.hda_disk_interface),Qi(1),pa("ngForOf",i.diskInterfaces),Qi(6),pa("ngModel",i.node.properties.hdb_disk_image),Qi(1),pa("ngForOf",i.qemuImages),Qi(2),pa("ngModel",i.node.properties.hdb_disk_interface),Qi(1),pa("ngForOf",i.diskInterfaces),Qi(6),pa("ngModel",i.node.properties.hdc_disk_image),Qi(1),pa("ngForOf",i.qemuImages),Qi(2),pa("ngModel",i.node.properties.hdc_disk_interface),Qi(1),pa("ngForOf",i.diskInterfaces),Qi(6),pa("ngModel",i.node.properties.hdd_disk_image),Qi(1),pa("ngForOf",i.qemuImages),Qi(2),pa("ngModel",i.node.properties.hdd_disk_interface),Qi(1),pa("ngForOf",i.diskInterfaces),Qi(8),pa("ngModel",i.node.properties.cdrom_image),Qi(3),pa("ngModel",i.node.properties.legacy_networking),Qi(3),pa("ngModel",i.node.properties.replicate_network_connection_state),Qi(2),pa("networkTypes",i.networkTypes)("displayedColumns",i.displayedColumns)("adapters",i.node.ports),Qi(14),pa("ngModel",i.node.properties.initrd),Qi(7),pa("ngModel",i.node.properties.kernel_image),Qi(2),pa("ngModel",i.node.properties.kernel_command_line),Qi(12),pa("ngModel",i.node.properties.bios_image),Qi(6),pa("ngModel",i.activateCpuThrottling),Qi(2),pa("ngIf",i.activateCpuThrottling),Qi(2),pa("ngModel",i.node.properties.process_priority),Qi(1),pa("ngForOf",i.priorities),Qi(7),pa("ngModel",i.node.properties.options),Qi(3),pa("ngModel",i.node.properties.usage)}}var c7=function(){function t(t,e,n,i,r,o,a){this.dialog=t,this.dialogRef=e,this.nodeService=n,this.toasterService=i,this.formBuilder=r,this.qemuService=o,this.qemuConfigurationService=a,this.consoleTypes=[],this.binaries=[],this.onCloseOptions=[],this.bootPriorities=[],this.diskInterfaces=[],this.displayedColumns=["adapter_number","port_name","adapter_type","actions"],this.networkTypes=[],this.qemuImages=[],this.conf={autoFocus:!1,width:"800px",disableClose:!0},this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required),ram:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name,t.getConfiguration()})),this.qemuService.getBinaries(this.server).subscribe((function(e){t.binaries=e})),this.qemuService.getImages(this.server).subscribe((function(e){t.qemuImages=e}))},t.prototype.openQemuImageCreator=function(){this.dialogRefQemuImageCreator=this.dialog.open(G6,this.conf),this.dialogRefQemuImageCreator.componentInstance.server=this.server},t.prototype.uploadCdromImageFile=function(t){this.node.properties.cdrom_image=t.target.files[0].name},t.prototype.uploadInitrdFile=function(t){this.node.properties.initrd=t.target.files[0].name},t.prototype.uploadKernelImageFile=function(t){this.node.properties.kernel_image=t.target.files[0].name},t.prototype.uploadBiosFile=function(t){this.node.properties.bios_image=t.target.files[0].name},t.prototype.getConfiguration=function(){var t=this;this.consoleTypes=this.qemuConfigurationService.getConsoleTypes(),this.onCloseOptions=this.qemuConfigurationService.getOnCloseOptions(),this.qemuConfigurationService.getNetworkTypes().forEach((function(e){t.networkTypes.push(e)})),this.bootPriorities=this.qemuConfigurationService.getBootPriorities(),this.diskInterfaces=this.qemuConfigurationService.getDiskInterfaces()},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid?(this.node.custom_adapters=[],this.customAdapters.adapters.forEach((function(e){t.node.custom_adapters.push({adapter_number:e.adapter_number,adapter_type:e.adapter_type})})),this.node.properties.adapters=this.node.custom_adapters.length,this.nodeService.updateNodeWithCustomAdapters(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()}))):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(e1),da(Z0),da(E2),da(Y2),da(Jp),da(w6),da(k6))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-qemu"]],viewQuery:function(t,e){var n;1&t&&nl(W6,!0),2&t&&tl(n=sl())&&(e.customAdapters=n.first)},decls:12,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["label","General settings"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","ram","placeholder","RAM",3,"ngModel","ngModelChange"],["matSuffix",""],["matInput","","type","number","placeholder","vCPUs",3,"ngModel","ngModelChange"],["placeholder","Qemu binary",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["placeholder","Boot priority",3,"ngModel","ngModelChange"],["placeholder","On close",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModel","ngModelChange"],[3,"ngModel","ngModelChange"],["label","HDD"],["mat-raised-button","","color","primary",1,"create-button",3,"click"],["placeholder","Disk image",3,"ngModel","ngModelChange"],["placeholder","Disk interface",3,"ngModel","ngModelChange"],["label","CD/DVD"],["mat-raised-button","","color","primary",1,"file-button",3,"click"],["type","file",1,"nonvisible",3,"change"],["filecdrom",""],[1,"file-name-form-field"],["matInput","","type","text","placeholder","Image",3,"ngModel","ngModelChange"],["label","Network"],[3,"networkTypes","displayedColumns","adapters"],["customAdapters",""],["label","Advanced"],["fileinitrd",""],["matInput","","type","text","placeholder","Initial RAM disk (initrd)",3,"ngModel","ngModelChange"],["filekernelimage",""],["matInput","","type","text","placeholder","Kernel image",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Kernel command line",3,"ngModel","ngModelChange"],["filebios",""],["matInput","","type","text","placeholder","Bios image",3,"ngModel","ngModelChange"],["class","form-field",4,"ngIf"],["placeholder","Process priority",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Options",3,"ngModel","ngModelChange"],["label","Usage"],["matInput","","type","text",3,"ngModel","ngModelChange"],[3,"value"],["matInput","","type","number","placeholder","Perecentage of CPU allowed",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ua(6,s7,141,45,"mat-tab-group",5),va(),va(),va(),va(),ga(7,"div",6),ga(8,"button",7),xa("click",(function(){return e.onCancelClick()})),ds(9,"Cancel"),va(),ga(10,"button",8),xa("click",(function(){return e.onSaveClick()})),ds(11,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.name))},directives:[r1,f3,Ah,a1,a2,U1,I1,xp,gf,Pp,Y3,s5,cf,mf,Fp,Ef,q3,Sp,O5,Eh,F5,i3,r3,n3,p6,EJ],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}();function l7(t,e){1&t&&(ga(0,"th",18),ds(1," Name "),va())}function u7(t,e){if(1&t&&(ga(0,"td",19),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.name," ")}}function h7(t,e){1&t&&(ga(0,"th",18),ds(1," Local port "),va())}function d7(t,e){if(1&t&&(ga(0,"td",19),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.rport," ")}}function f7(t,e){1&t&&(ga(0,"th",18),ds(1," Type "),va())}function p7(t,e){if(1&t&&(ga(0,"td",19),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.rhost," ")}}function m7(t,e){1&t&&(ga(0,"th",18),ds(1," Remote port "),va())}function g7(t,e){if(1&t&&(ga(0,"td",19),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.lport," ")}}function v7(t,e){1&t&&(ga(0,"th",18),ds(1," Actions "),va())}function b7(t,e){if(1&t){var n=ka();ga(0,"td",19),ga(1,"button",20),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(2).delete(t)})),ga(2,"mat-icon",21),ds(3,"delete"),va(),va(),va()}}function y7(t,e){1&t&&ba(0,"tr",22)}function _7(t,e){1&t&&ba(0,"tr",23)}function w7(t,e){if(1&t&&(ga(0,"table",8),ya(1,9),ua(2,l7,2,0,"th",10),ua(3,u7,2,1,"td",11),_a(),ya(4,12),ua(5,h7,2,0,"th",10),ua(6,d7,2,1,"td",11),_a(),ya(7,13),ua(8,f7,2,0,"th",10),ua(9,p7,2,1,"td",11),_a(),ya(10,14),ua(11,m7,2,0,"th",10),ua(12,g7,2,1,"td",11),_a(),ya(13,15),ua(14,v7,2,0,"th",10),ua(15,b7,4,0,"td",11),_a(),ua(16,y7,1,0,"tr",16),ua(17,_7,1,0,"tr",17),va()),2&t){var n=Aa();pa("dataSource",n.dataSourceUdp),Qi(16),pa("matHeaderRowDef",n.displayedColumns),Qi(1),pa("matRowDefColumns",n.displayedColumns)}}function k7(t,e){1&t&&ba(0,"br")}var C7=function(){function t(t){this.builtInTemplatesConfigurationService=t,this.dataSourceUdp=[],this.displayedColumns=["name","lport","rhost","rport","action"],this.newPort={name:"",port_number:0},this.portTypes=[],this.etherTypes=[]}return t.prototype.ngOnInit=function(){this.getConfiguration()},t.prototype.getConfiguration=function(){this.etherTypes=this.builtInTemplatesConfigurationService.getEtherTypesForEthernetSwitches(),this.portTypes=this.builtInTemplatesConfigurationService.getPortTypesForEthernetSwitches()},t.prototype.onAddUdpInterface=function(){this.dataSourceUdp=this.dataSourceUdp.concat([this.newPort]),this.newPort={name:"",port_number:0}},t.prototype.delete=function(t){this.dataSourceUdp=this.dataSourceUdp.filter((function(e){return e!==t}))},t.\u0275fac=function(e){return new(e||t)(da(K5))},t.\u0275cmp=Ht({type:t,selectors:[["app-udp-tunnels"]],inputs:{dataSourceUdp:"dataSourceUdp"},decls:12,vars:6,consts:[["class","table","mat-table","",3,"dataSource",4,"ngIf"],[4,"ngIf"],[1,"form-field"],["matInput","","type","text","placeholder","Name",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","Local port",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Remote host",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","Remote port",3,"ngModel","ngModelChange"],["mat-button","",1,"form-field",3,"click"],["mat-table","",1,"table",3,"dataSource"],["matColumnDef","name"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","rport"],["matColumnDef","rhost"],["matColumnDef","lport"],["matColumnDef","action"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-header-cell",""],["mat-cell",""],["mat-icon-button","","matTooltip","Delete port","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Delete port"],["mat-header-row",""],["mat-row",""]],template:function(t,e){1&t&&(ua(0,w7,18,3,"table",0),ua(1,k7,1,0,"br",1),ga(2,"mat-form-field",2),ga(3,"input",3),xa("ngModelChange",(function(t){return e.newPort.name=t})),va(),va(),ga(4,"mat-form-field",2),ga(5,"input",4),xa("ngModelChange",(function(t){return e.newPort.lport=t})),va(),va(),ga(6,"mat-form-field",2),ga(7,"input",5),xa("ngModelChange",(function(t){return e.newPort.rhost=t})),va(),va(),ga(8,"mat-form-field",2),ga(9,"input",6),xa("ngModelChange",(function(t){return e.newPort.rport=t})),va(),va(),ga(10,"button",7),xa("click",(function(){return e.onAddUdpInterface()})),ds(11,"Add"),va()),2&t&&(pa("ngIf",e.dataSourceUdp.length),Qi(1),pa("ngIf",e.dataSourceUdp.length),Qi(2),pa("ngModel",e.newPort.name),Qi(2),pa("ngModel",e.newPort.lport),Qi(2),pa("ngModel",e.newPort.rhost),Qi(2),pa("ngModel",e.newPort.rport))},directives:[Ah,Y3,s5,cf,mf,Sp,Ef,a2,$5,n4,t4,J5,a4,c4,i4,o4,k4,x2,l4,h4],styles:[".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),S7=["udpTunnels"];function x7(t,e){if(1&t&&(ga(0,"div",16),ga(1,"div",16),ds(2),va(),ba(3,"br"),ba(4,"br"),va()),2&t){var n=e.$implicit;Qi(2),fs(n.name)}}function O7(t,e){if(1&t&&(ga(0,"mat-option",28),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function M7(t,e){if(1&t&&(ga(0,"div",16),ga(1,"div",16),ds(2),va(),ba(3,"br"),ba(4,"br"),va()),2&t){var n=e.$implicit;Qi(2),fs(n.name)}}function T7(t,e){if(1&t&&(ga(0,"mat-option",28),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var E7=function(){return{standalone:!0}};function P7(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ua(2,x7,5,1,"div",10),ga(3,"mat-form-field",11),ga(4,"mat-select",12),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetInterface=t})),ua(5,O7,2,2,"mat-option",13),va(),va(),ga(6,"button",14),xa("click",(function(){return Se(n),Aa().onAddEthernetInterface()})),ds(7,"Add"),va(),va(),ga(8,"mat-tab",15),ua(9,M7,5,1,"div",10),ga(10,"mat-form-field",16),ga(11,"input",17),xa("ngModelChange",(function(t){return Se(n),Aa().tapInterface=t})),va(),va(),ga(12,"button",14),xa("click",(function(){return Se(n),Aa().onAddTapInterface()})),ds(13,"Add"),va(),va(),ga(14,"mat-tab",18),ba(15,"app-udp-tunnels",19,20),va(),ga(17,"mat-tab",21),ga(18,"form",22),ga(19,"mat-form-field",16),ga(20,"input",23),xa("ngModelChange",(function(t){return Se(n),Aa().node.name=t})),va(),va(),va(),ga(21,"mat-form-field",11),ga(22,"mat-select",24),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_type=t})),ua(23,T7,2,2,"mat-option",13),va(),va(),ga(24,"mat-form-field",16),ga(25,"input",25),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.remote_console_host=t})),va(),va(),ga(26,"mat-form-field",16),ga(27,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.remote_console_port=t})),va(),va(),ga(28,"mat-form-field",16),ga(29,"input",27),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.remote_console_http_path=t})),va(),va(),va(),va()}if(2&t){var i=Aa();Qi(2),pa("ngForOf",i.portsMappingEthernet),Qi(2),pa("ngModelOptions",jc(14,E7))("ngModel",i.ethernetInterface),Qi(1),pa("ngForOf",i.ethernetInterfaces),Qi(4),pa("ngForOf",i.portsMappingTap),Qi(2),pa("ngModel",i.tapInterface),Qi(4),pa("dataSourceUdp",i.portsMappingUdp),Qi(3),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.node.name),Qi(2),pa("ngModel",i.node.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(2),pa("ngModel",i.node.properties.remote_console_host),Qi(2),pa("ngModel",i.node.properties.remote_console_port),Qi(2),pa("ngModel",i.node.properties.remote_console_http_path)}}var A7=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.builtInTemplatesConfigurationService=r,this.consoleTypes=[],this.binaries=[],this.onCloseOptions=[],this.bootPriorities=[],this.diskInterfaces=[],this.portsMappingEthernet=[],this.portsMappingTap=[],this.portsMappingUdp=[],this.displayedColumns=["adapter_number","port_name","adapter_type","actions"],this.networkTypes=[],this.tapInterface="",this.ethernetInterface="",this.ethernetInterfaces=["Ethernet 2","Ethernet 3"],this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name,t.getConfiguration(),t.portsMappingEthernet=t.node.properties.ports_mapping.filter((function(t){return"ethernet"===t.type})),t.portsMappingTap=t.node.properties.ports_mapping.filter((function(t){return"tap"===t.type})),t.portsMappingUdp=t.node.properties.ports_mapping.filter((function(t){return"udp"===t.type}))}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.builtInTemplatesConfigurationService.getConsoleTypesForCloudNodes()},t.prototype.onAddEthernetInterface=function(){this.ethernetInterface&&this.portsMappingEthernet.push({interface:this.ethernetInterface,name:this.ethernetInterface,port_number:0,type:"ethernet"})},t.prototype.onAddTapInterface=function(){this.tapInterface&&this.portsMappingTap.push({interface:this.tapInterface,name:this.tapInterface,port_number:0,type:"tap"})},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid?(this.portsMappingUdp=this.udpTunnels.dataSourceUdp,this.node.properties.ports_mapping=this.portsMappingUdp.concat(this.portsMappingEthernet).concat(this.portsMappingTap),this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()}))):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(K5))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-cloud"]],viewQuery:function(t,e){var n;1&t&&nl(S7,!0),2&t&&tl(n=sl())&&(e.udpTunnels=n.first)},decls:12,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["label","Ethernet interfaces"],["class","form-field",4,"ngFor","ngForOf"],[1,"select"],["placeholder","Ethernet interface",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["mat-button","",1,"form-field",3,"click"],["label","TAP interfaces"],[1,"form-field"],["matInput","","type","text","placeholder","TAP interface",3,"ngModel","ngModelChange"],["label","UDP tunnels"],[3,"dataSourceUdp"],["udpTunnels",""],["label","Miscellaneous"],[3,"formGroup"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],["placeholder","Console type",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Console host",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Console port",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Console HTTP path",3,"ngModel","ngModelChange"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ua(6,P7,30,15,"mat-tab-group",5),va(),va(),va(),va(),ga(7,"div",6),ga(8,"button",7),xa("click",(function(){return e.onCancelClick()})),ds(9,"Cancel"),va(),ga(10,"button",8),xa("click",(function(){return e.onSaveClick()})),ds(11,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.name))},directives:[r1,f3,Ah,a1,a2,U1,I1,Eh,Y3,O5,mf,Sp,s5,cf,C7,xp,gf,Pp,Fp,EJ],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}();function j7(t,e){1&t&&(ga(0,"th",27),ds(1," Port : VPI : VCI "),va())}function I7(t,e){if(1&t&&(ga(0,"td",28),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.portIn," ")}}function D7(t,e){1&t&&(ga(0,"th",27),ds(1," Port : VPI : VCI "),va())}function R7(t,e){if(1&t&&(ga(0,"td",28),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.portOut," ")}}function L7(t,e){1&t&&(ga(0,"th",27),ds(1," Actions "),va())}function F7(t,e){if(1&t){var n=ka();ga(0,"td",28),ga(1,"button",29),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(2).delete(t)})),ga(2,"mat-icon",30),ds(3,"delete"),va(),va(),va()}}function N7(t,e){1&t&&ba(0,"tr",31)}function B7(t,e){1&t&&ba(0,"tr",32)}function H7(t,e){if(1&t&&(ga(0,"table",19),ya(1,20),ua(2,j7,2,0,"th",21),ua(3,I7,2,1,"td",22),_a(),ya(4,23),ua(5,D7,2,0,"th",21),ua(6,R7,2,1,"td",22),_a(),ya(7,24),ua(8,L7,2,0,"th",21),ua(9,F7,4,0,"td",22),_a(),ua(10,N7,1,0,"tr",25),ua(11,B7,1,0,"tr",26),va()),2&t){var n=Aa();pa("dataSource",n.nodeMappingsDataSource),Qi(10),pa("matHeaderRowDef",n.displayedColumns),Qi(1),pa("matRowDefColumns",n.displayedColumns)}}var z7=function(){function t(t,e,n,i){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.consoleTypes=[],this.nodeMappings=new Map,this.nodeMappingsDataSource=[],this.dataSource=[],this.displayedColumns=["portIn","portOut","actions"],this.sourcePort="",this.sourceVpi="",this.sourceVci="",this.destinationPort="",this.destinationVpi="",this.destinationVci="",this.useVpiOnly=!1,this.nameForm=this.formBuilder.group({name:new hp("",kf.required)}),this.inputForm=this.formBuilder.group({sourcePort:new hp("",kf.required),sourceVci:new hp("",kf.required),destinationPort:new hp("",kf.required),destinationVci:new hp("",kf.required)}),this.abstractForm=this.formBuilder.group({sourceVpi:new hp("",kf.required),destinationVpi:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name;var n=e.properties.mappings;Object.keys(n).forEach((function(e){t.nodeMappings.set(e,n[e])})),t.nodeMappings.forEach((function(e,n){t.nodeMappingsDataSource.push({portIn:n,portOut:e})}))}))},t.prototype.delete=function(t){this.nodeMappingsDataSource=this.nodeMappingsDataSource.filter((function(e){return e!==t}))},t.prototype.add=function(){var t;this.inputForm.valid?this.useVpiOnly?(t={portIn:this.sourcePort+":"+this.sourceVci,portOut:this.destinationPort+":"+this.destinationVci},this.nodeMappingsDataSource.filter((function(e){return e.portIn===t.portIn})).length>0?this.toasterService.error("Mapping already defined."):(this.nodeMappingsDataSource=this.nodeMappingsDataSource.concat([t]),this.clearUserInput())):this.abstractForm.valid?(t={portIn:this.sourcePort+":"+this.sourceVpi+":"+this.sourceVci,portOut:this.destinationPort+":"+this.destinationVpi+":"+this.destinationVci},this.nodeMappingsDataSource.filter((function(e){return e.portIn===t.portIn})).length>0?this.toasterService.error("Mapping already defined."):(this.nodeMappingsDataSource=this.nodeMappingsDataSource.concat([t]),this.clearUserInput())):this.toasterService.error("Fill all required fields."):this.toasterService.error("Fill all required fields.")},t.prototype.clearUserInput=function(){this.sourcePort="0",this.sourceVpi="0",this.sourceVci="0",this.destinationPort="0",this.destinationVpi="0",this.sourceVci="0"},t.prototype.strMapToObj=function(t){for(var e=Object.create(null),n=0,i=t;n<i.length;n++){var r=i[n];e[r[0]]=r[1]}return e},t.prototype.onSaveClick=function(){var t=this;this.nameForm.valid?(this.nodeMappings.clear(),this.nodeMappingsDataSource.forEach((function(e){t.nodeMappings.set(e.portIn,e.portOut)})),this.node.properties.mappings=Array.from(this.nodeMappings).reduce((function(t,e){var n;return Object.assign(t,((n={})[e[0]]=e[1],n))}),{}),this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()}))):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-atm-switch"]],decls:39,vars:16,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],["class","table","mat-table","",3,"dataSource",4,"ngIf"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],[3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","sourcePort","placeholder","Port",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","sourceVpi","placeholder","VPI",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","sourceVci","placeholder","VCI",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","destinationPort","placeholder","Port",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","destinationVpi","placeholder","VPI",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","destinationVci","placeholder","VCI",3,"ngModel","ngModelChange"],["mat-button","",1,"form-field",3,"click"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["mat-table","",1,"table",3,"dataSource"],["matColumnDef","portIn"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","portOut"],["matColumnDef","actions"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-header-cell",""],["mat-cell",""],["mat-icon-button","","matTooltip","Delete port","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Delete port"],["mat-header-row",""],["mat-row",""]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card"),ua(6,H7,12,3,"table",4),ba(7,"br"),ga(8,"form",5),ga(9,"mat-form-field",6),ga(10,"input",7),xa("ngModelChange",(function(t){return e.node.name=t})),va(),va(),va(),ga(11,"mat-checkbox",8),xa("ngModelChange",(function(t){return e.useVpiOnly=t})),ds(12," Use VPI only (VP tunnel) "),va(),ga(13,"form",5),ds(14," Source "),ga(15,"mat-form-field",6),ga(16,"input",9),xa("ngModelChange",(function(t){return e.sourcePort=t})),va(),va(),va(),ga(17,"form",5),ga(18,"mat-form-field",6),ga(19,"input",10),xa("ngModelChange",(function(t){return e.sourceVpi=t})),va(),va(),va(),ga(20,"form",5),ga(21,"mat-form-field",6),ga(22,"input",11),xa("ngModelChange",(function(t){return e.sourceVci=t})),va(),va(),ds(23," Destination "),ga(24,"mat-form-field",6),ga(25,"input",12),xa("ngModelChange",(function(t){return e.destinationPort=t})),va(),va(),va(),ga(26,"form",5),ga(27,"mat-form-field",6),ga(28,"input",13),xa("ngModelChange",(function(t){return e.destinationVpi=t})),va(),va(),va(),ga(29,"form",5),ga(30,"mat-form-field",6),ga(31,"input",14),xa("ngModelChange",(function(t){return e.destinationVci=t})),va(),va(),va(),ga(32,"button",15),xa("click",(function(){return e.add()})),ds(33,"Add"),va(),va(),va(),va(),va(),ga(34,"div",16),ga(35,"button",17),xa("click",(function(){return e.onCancelClick()})),ds(36,"Cancel"),va(),ga(37,"button",18),xa("click",(function(){return e.onSaveClick()})),ds(38,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.nodeMappingsDataSource.length),Qi(2),pa("formGroup",e.nameForm),Qi(2),pa("ngModel",e.node.name),Qi(1),pa("ngModel",e.useVpiOnly),Qi(2),pa("formGroup",e.inputForm),Qi(3),pa("ngModel",e.sourcePort),Qi(1),pa("formGroup",e.abstractForm),Qi(2),pa("ngModel",e.sourceVpi),Qi(1),pa("formGroup",e.inputForm),Qi(2),pa("ngModel",e.sourceVci),Qi(3),pa("ngModel",e.destinationPort),Qi(1),pa("formGroup",e.abstractForm),Qi(2),pa("ngModel",e.destinationVpi),Qi(1),pa("formGroup",e.inputForm),Qi(2),pa("ngModel",e.destinationVci))},directives:[r1,f3,Ah,xp,gf,Pp,Y3,s5,cf,mf,Fp,F5,Sp,Ef,a2,a1,$5,n4,t4,J5,a4,c4,i4,o4,k4,x2,l4,h4],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),V7=function(){function t(){}return t.prototype.getConsoleTypes=function(){return["telnet","none"]},t.prototype.getOnCloseoptions=function(){return[["Power off the VM","power_off"],["Send the shutdown signal (ACPI)","shutdown_signal"],["Save the VM state","save_vm_state"]]},t.prototype.getCategories=function(){return[["Default","guest"],["Routers","routers"],["Switches","switches"],["End devices","end_devices"],["Security devices","security_devices"]]},t.prototype.getNetworkTypes=function(){return["default","e1000","e1000e","flexible","vlance","vmxnet","vmxnet2","vmxnet3"]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),U7=["customAdapters"];function q7(t,e){if(1&t&&(ga(0,"mat-option",24),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function G7(t,e){if(1&t&&(ga(0,"mat-option",24),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}var W7=function(){return{standalone:!0}};function K7(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ba(2,"br"),ga(3,"form",10),ga(4,"mat-form-field",11),ga(5,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().node.name=t})),va(),va(),ga(6,"mat-form-field",13),ga(7,"mat-select",14),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_type=t})),ua(8,q7,2,2,"mat-option",15),va(),va(),ga(9,"mat-checkbox",16),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_auto_start=t})),ds(10," Auto start console "),va(),ga(11,"mat-form-field",11),ga(12,"mat-select",17),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.on_close=t})),ua(13,G7,2,2,"mat-option",15),va(),va(),va(),ga(14,"mat-checkbox",18),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.headless=t})),ds(15," Start VM in headless mode "),va(),ba(16,"br"),ga(17,"mat-checkbox",18),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.linked_clone=t})),ds(18," Use a linked base VM (experimental) "),va(),va(),ga(19,"mat-tab",19),ba(20,"br"),ga(21,"mat-checkbox",18),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.use_any_adapter=t})),ds(22," Allow GNS3 to override non custom VMware adapter "),va(),ba(23,"app-custom-adapters-table",20,21),va(),ga(25,"mat-tab",22),ga(26,"mat-form-field",11),ga(27,"textarea",23),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.usage=t})),va(),va(),va(),va()}if(2&t){var i=Aa();Qi(3),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.node.name),Qi(2),pa("ngModelOptions",jc(17,W7))("ngModel",i.node.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModelOptions",jc(18,W7))("ngModel",i.node.console_auto_start),Qi(3),pa("ngModelOptions",jc(19,W7))("ngModel",i.node.properties.on_close),Qi(1),pa("ngForOf",i.onCloseOptions),Qi(1),pa("ngModel",i.node.properties.headless),Qi(3),pa("ngModel",i.node.properties.linked_clone),Qi(4),pa("ngModel",i.node.properties.use_any_adapter),Qi(2),pa("networkTypes",i.networkTypes)("displayedColumns",i.displayedColumns)("adapters",i.node.ports),Qi(4),pa("ngModel",i.node.properties.usage)}}var X7=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.vmwareConfigurationService=r,this.consoleTypes=[],this.onCloseOptions=[],this.displayedColumns=["adapter_number","port_name","adapter_type","actions"],this.networkTypes=[],this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name,t.getConfiguration()}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.vmwareConfigurationService.getConsoleTypes(),this.onCloseOptions=this.vmwareConfigurationService.getOnCloseoptions(),this.networkTypes=this.vmwareConfigurationService.getNetworkTypes()},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid?(this.node.custom_adapters=[],this.customAdapters.adapters.forEach((function(e){t.node.custom_adapters.push({adapter_number:e.adapter_number,adapter_type:e.adapter_type})})),this.node.properties.adapters=this.node.custom_adapters.length,this.nodeService.updateNodeWithCustomAdapters(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()}))):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(V7))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-vmware"]],viewQuery:function(t,e){var n;1&t&&nl(U7,!0),2&t&&tl(n=sl())&&(e.customAdapters=n.first)},decls:12,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["label","General settings"],[3,"formGroup"],[1,"form-field"],["matInput","","formControlName","name","type","text","placeholder","Name",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ngModelOptions","ngModel","ngModelChange"],["placeholder","On close",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ngModel","ngModelChange"],["label","Network"],[3,"networkTypes","displayedColumns","adapters"],["customAdapters",""],["label","Usage"],["matInput","","type","text",3,"ngModel","ngModelChange"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ua(6,K7,28,20,"mat-tab-group",5),va(),va(),va(),va(),ga(7,"div",6),ga(8,"button",7),xa("click",(function(){return e.onCancelClick()})),ds(9,"Cancel"),va(),ga(10,"button",8),xa("click",(function(){return e.onSaveClick()})),ds(11,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.name))},directives:[r1,f3,Ah,a1,a2,U1,I1,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,F5,p6,EJ],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),Y7=function(){function t(){}return t.prototype.getConsoleTypes=function(){return["telnet","none"]},t.prototype.getCategories=function(){return[["Default","guest"],["Routers","router"],["Switches","switch"],["End devices","end_device"],["Security devices","security_device"]]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function Z7(t,e){if(1&t&&(ga(0,"mat-option",25),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Q7(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ba(2,"br"),ga(3,"form",10),ga(4,"mat-form-field",11),ga(5,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().node.name=t})),va(),va(),va(),ga(6,"mat-form-field",13),ga(7,"mat-select",14),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_type=t})),ua(8,Z7,2,2,"mat-option",15),va(),va(),ga(9,"mat-checkbox",16),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_auto_start=t})),ds(10," Auto start console "),va(),ba(11,"br"),ga(12,"mat-form-field",11),ga(13,"input",17),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.ram=t})),va(),ga(14,"span",18),ds(15,"MB"),va(),va(),ga(16,"mat-form-field",11),ga(17,"input",19),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.nvram=t})),va(),ga(18,"span",18),ds(19,"MB"),va(),va(),va(),ga(20,"mat-tab",20),ba(21,"br"),ga(22,"form",10),ga(23,"mat-form-field",11),ga(24,"input",21),xa("ngModelChange",(function(t){return Se(n),Aa().node.ethernet_adapters=t})),va(),va(),ga(25,"mat-form-field",11),ga(26,"input",22),xa("ngModelChange",(function(t){return Se(n),Aa().node.serial_adapters=t})),va(),va(),va(),va(),ga(27,"mat-tab",23),ga(28,"mat-form-field",11),ga(29,"textarea",24),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.usage=t})),va(),va(),va(),va()}if(2&t){var i=Aa();Qi(3),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.node.name),Qi(2),pa("ngModel",i.node.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModel",i.node.console_auto_start),Qi(4),pa("ngModel",i.node.properties.ram),Qi(4),pa("ngModel",i.node.properties.nvram),Qi(5),pa("formGroup",i.networkForm),Qi(2),pa("ngModel",i.node.ethernet_adapters),Qi(2),pa("ngModel",i.node.serial_adapters),Qi(3),pa("ngModel",i.node.properties.usage)}}var $7=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.configurationService=r,this.consoleTypes=[],this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required)}),this.networkForm=this.formBuilder.group({ethernetAdapters:new hp("",kf.required),serialAdapters:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name,t.getConfiguration()}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.configurationService.getConsoleTypes()},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid&&this.networkForm.valid?this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()})):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(Y7))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-iou"]],decls:12,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["label","General settings"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","RAM size",3,"ngModel","ngModelChange"],["matSuffix",""],["matInput","","type","number","placeholder","NVRAM size",3,"ngModel","ngModelChange"],["label","Network"],["matInput","","formControlName","ethernetAdapters","type","number","placeholder","Ethernet adapters",3,"ngModel","ngModelChange"],["matInput","","formControlName","serialAdapters","type","number","placeholder","Serial adapters",3,"ngModel","ngModelChange"],["label","Usage"],["matInput","","type","text",3,"ngModel","ngModelChange"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ua(6,Q7,30,11,"mat-tab-group",5),va(),va(),va(),va(),ga(7,"div",6),ga(8,"button",7),xa("click",(function(){return e.onCancelClick()})),ds(9,"Cancel"),va(),ga(10,"button",8),xa("click",(function(){return e.onSaveClick()})),ds(11,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.name))},directives:[r1,f3,Ah,a1,a2,U1,I1,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,F5,Ef,q3,EJ],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),J7=function(){function t(){this.c1700_wics=["WIC-1T","WIC-2T","WIC-1ENET"],this.c2600_wics=["WIC-1T","WIC-2T"],this.c3700_wics=["WIC-1T","WIC-2T"],this.c2600_nms=["NM-1FE-TX","NM-1E","NM-4E","NM-16ESW"],this.c3600_nms=["NM-1FE-TX","NM-1E","NM-4E","NM-16ESW","NM-4T"],this.c3700_nms=["NM-1FE-TX","NM-4T","NM-16ESW"],this.c7200_pas=["PA-A1","PA-FE-TX","PA-2FE-TX","PA-GE","PA-4T+","PA-8T","PA-4E","PA-8E","PA-POS-OC3"],this.c7200_io=["C7200-IO-FE","C7200-IO-2FE","C7200-IO-GE-E"]}return t.prototype.getConsoleTypes=function(){return["telnet","none"]},t.prototype.getDefaultRamSettings=function(){return{c1700:160,c2600:160,c2691:192,c3600:192,c3725:128,c3745:256,c7200:512}},t.prototype.getDefaultNvRamSettings=function(){return{c1700:128,c2600:128,c2691:256,c3600:192,c3620:192,c3640:192,c3660:192,c3725:256,c3745:256,c7200:512}},t.prototype.getAvailablePlatforms=function(){return["c1700","c2600","c2691","c3725","c3745","c3600","c7200"]},t.prototype.getPlatformsWithEtherSwitchRouterOption=function(){return{c1700:!1,c2600:!0,c2691:!0,c3725:!0,c3745:!0,c3600:!0,c7200:!1}},t.prototype.getPlatformsWithChassis=function(){return{c1700:!0,c2600:!0,c2691:!1,c3725:!1,c3745:!1,c3600:!0,c7200:!1}},t.prototype.getChassis=function(){return{c1700:["1720","1721","1750","1751","1760"],c2600:["2610","2611","2620","2621","2610XM","2611XM","2620XM","2621XM","2650XM","2651XM"],c3600:["3620","3640","3660"]}},t.prototype.getNetworkModules=function(){return{c1700:{0:this.c1700_wics,1:this.c1700_wics},c2600:{0:this.c2600_wics,1:this.c2600_wics,2:this.c2600_wics},c2691:{0:this.c3700_wics,1:this.c3700_wics,2:this.c3700_wics},c3725:{0:this.c3700_wics,1:this.c3700_wics,2:this.c3700_wics},c3745:{0:this.c3700_wics,1:this.c3700_wics,2:this.c3700_wics}}},t.prototype.getNetworkAdapters=function(){return{1720:{0:["C1700-MB-1FE"]},1721:{0:["C1700-MB-1FE"]},1750:{0:["C1700-MB-1FE"]},1751:{0:["C1700-MB-1FE"],1:["C1700-MB-WIC1"]},1760:{0:["C1700-MB-1FE"],1:["C1700-MB-WIC1"]},2610:{0:["C2600-MB-1E"],1:this.c2600_nms},2611:{0:["C2600-MB-2E"],1:this.c2600_nms},2620:{0:["C2600-MB-1FE"],1:this.c2600_nms},2621:{0:["C2600-MB-2FE"],1:this.c2600_nms},"2610XM":{0:["C2600-MB-1FE"],1:this.c2600_nms},"2611XM":{0:["C2600-MB-2FE"],1:this.c2600_nms},"2620XM":{0:["C2600-MB-1FE"],1:this.c2600_nms},"2621XM":{0:["C2600-MB-2FE"],1:this.c2600_nms},"2650XM":{0:["C2600-MB-1FE"],1:this.c2600_nms},"2651XM":{0:["C2600-MB-2FE"],1:this.c2600_nms},3620:{0:this.c3600_nms,1:this.c3600_nms},3640:{0:this.c3600_nms,1:this.c3600_nms,2:this.c3600_nms,3:this.c3600_nms},3660:{0:["Leopard-2FE"],1:this.c3600_nms,2:this.c3600_nms,3:this.c3600_nms,4:this.c3600_nms,5:this.c3600_nms,6:this.c3600_nms}}},t.prototype.getNetworkAdaptersForPlatform=function(){var t={};return t.c2691={0:["GT96100-FE"],1:this.c3700_nms},t.c3725={0:["GT96100-FE"],1:this.c3700_nms,2:this.c3700_nms},t.c3745={0:["GT96100-FE"],1:this.c3700_nms,2:this.c3700_nms,3:this.c3700_nms,4:this.c3700_nms},t.c7200={0:this.c7200_io,1:this.c7200_pas,2:this.c7200_pas,3:this.c7200_pas,4:this.c7200_pas,5:this.c7200_pas,6:this.c7200_pas},{c2691:{0:["GT96100-FE"],1:this.c3700_nms},c3725:{0:["GT96100-FE"],1:this.c3700_nms,2:this.c3700_nms},c3745:{0:["GT96100-FE"],1:this.c3700_nms,2:this.c3700_nms,3:this.c3700_nms,4:this.c3700_nms},c7200:{0:this.c7200_io,1:this.c7200_pas,2:this.c7200_pas,3:this.c7200_pas,4:this.c7200_pas,5:this.c7200_pas,6:this.c7200_pas}}},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function t8(t,e){if(1&t&&(ga(0,"mat-option",23),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function e8(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ba(2,"br"),ga(3,"form",10),ga(4,"mat-form-field",11),ga(5,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().node.name=t})),va(),va(),va(),ga(6,"mat-form-field",13),ga(7,"mat-select",14),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_type=t})),ua(8,t8,2,2,"mat-option",15),va(),va(),ga(9,"mat-checkbox",16),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_auto_start=t})),ds(10," Auto start console "),va(),ba(11,"br"),va(),ga(12,"mat-tab",17),ba(13,"br"),ga(14,"form",10),ga(15,"mat-form-field",11),ga(16,"input",18),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.ram=t})),va(),ga(17,"span",19),ds(18,"MB"),va(),va(),ga(19,"mat-form-field",11),ga(20,"input",20),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.nvram=t})),va(),ga(21,"span",19),ds(22,"MB"),va(),va(),va(),va(),ga(23,"mat-tab",21),ga(24,"mat-form-field",11),ga(25,"textarea",22),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.usage=t})),va(),va(),va(),va()}if(2&t){var i=Aa();Qi(3),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.node.name),Qi(2),pa("ngModel",i.node.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModel",i.node.console_auto_start),Qi(5),pa("formGroup",i.memoryForm),Qi(2),pa("ngModel",i.node.properties.ram),Qi(4),pa("ngModel",i.node.properties.nvram),Qi(5),pa("ngModel",i.node.properties.usage)}}var n8=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.configurationService=r,this.consoleTypes=[],this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required)}),this.memoryForm=this.formBuilder.group({ram:new hp("",kf.required),nvram:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name,t.getConfiguration()}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.configurationService.getConsoleTypes()},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid&&this.memoryForm.valid?this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()})):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(J7))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-ios"]],decls:12,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["label","General settings"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ngModel","ngModelChange"],["label","Memories and disks"],["matInput","","type","number","formControlName","ram","placeholder","RAM size",3,"ngModel","ngModelChange"],["matSuffix",""],["matInput","","type","number","formControlName","nvram","placeholder","NVRAM size",3,"ngModel","ngModelChange"],["label","Usage"],["matInput","","type","text",3,"ngModel","ngModelChange"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ua(6,e8,26,9,"mat-tab-group",5),va(),va(),va(),va(),ga(7,"div",6),ga(8,"button",7),xa("click",(function(){return e.onCancelClick()})),ds(9,"Cancel"),va(),ga(10,"button",8),xa("click",(function(){return e.onSaveClick()})),ds(11,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.name))},directives:[r1,f3,Ah,a1,a2,U1,I1,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,F5,Ef,q3,EJ],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),i8=function(){function t(){}return t.prototype.getConsoleTypes=function(){return["telnet","vnc","http","https","none"]},t.prototype.getCategories=function(){return[["Default","guest"],["Routers","routers"],["Switches","switches"],["End devices","end_devices"],["Security devices","security_devices"]]},t.prototype.getConsoleResolutions=function(){return["1920x1080","1366x768","1280x1024","1280x800","1024x768","800x600","640x480"]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function r8(t,e){if(1&t){var n=ka();ga(0,"div",5),ga(1,"textarea",6),xa("ngModelChange",(function(t){return Se(n),Aa().configuration=t})),va(),va()}if(2&t){var i=Aa();Qi(1),pa("ngModel",i.configuration)}}var o8=function(){function t(t,e,n){this.dialogRef=t,this.nodeService=e,this.toasterService=n}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNetworkConfiguration(this.server,this.node).subscribe((function(e){t.configuration=e}))},t.prototype.onSaveClick=function(){var t=this;this.nodeService.saveNetworkConfiguration(this.server,this.node,this.configuration).subscribe((function(e){t.onCancelClick(),t.toasterService.success("Configuration for node "+t.node.name+" saved.")}))},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-edit-network-configuration"]],decls:8,vars:2,consts:[["mat-dialog-title",""],["class","modal-form-container",4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[1,"modal-form-container"],["matInput","","type","text",1,"textArea",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ua(2,r8,2,1,"div",1),ga(3,"div",2),ga(4,"button",3),xa("click",(function(){return e.onCancelClick()})),ds(5,"Cancel"),va(),ga(6,"button",4),xa("click",(function(){return e.onSaveClick()})),ds(7,"Apply"),va(),va()),2&t&&(Qi(1),ps("Edit network configuration for node ",e.node.name,""),Qi(1),pa("ngIf",e.node))},directives:[r1,Ah,a1,a2,s5,cf,mf,Sp],styles:[".textArea[_ngcontent-%COMP%]{width:100%;height:350px}"]}),t}(),a8=function(){var t=function(){function t(){Object(m.a)(this,t),this._vertical=!1,this._inset=!1}return Object(g.a)(t,[{key:"vertical",get:function(){return this._vertical},set:function(t){this._vertical=nm(t)}},{key:"inset",get:function(){return this._inset},set:function(t){this._inset=nm(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-divider"]],hostAttrs:["role","separator",1,"mat-divider"],hostVars:7,hostBindings:function(t,e){2&t&&(oa("aria-orientation",e.vertical?"vertical":"horizontal"),Qa("mat-divider-vertical",e.vertical)("mat-divider-horizontal",!e.vertical)("mat-divider-inset",e.inset))},inputs:{vertical:"vertical",inset:"inset"},decls:0,vars:0,template:function(t,e){},styles:[".mat-divider{display:block;margin:0;border-top-width:1px;border-top-style:solid}.mat-divider.mat-divider-vertical{border-top:0;border-right-width:1px;border-right-style:solid}.mat-divider.mat-divider-inset{margin-left:80px}[dir=rtl] .mat-divider.mat-divider-inset{margin-left:auto;margin-right:80px}\n"],encapsulation:2,changeDetection:0}),t}(),s8=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[$$],$$]}),t}(),c8=["*"],l8=[[["","mat-list-avatar",""],["","mat-list-icon",""],["","matListAvatar",""],["","matListIcon",""]],[["","mat-line",""],["","matLine",""]],"*"],u8=["[mat-list-avatar], [mat-list-icon], [matListAvatar], [matListIcon]","[mat-line], [matLine]","*"],h8=["text"];function d8(t,e){if(1&t&&ba(0,"mat-pseudo-checkbox",5),2&t){var n=Aa();pa("state",n.selected?"checked":"unchecked")("disabled",n.disabled)}}var f8=["*",[["","mat-list-avatar",""],["","mat-list-icon",""],["","matListAvatar",""],["","matListIcon",""]]],p8=["*","[mat-list-avatar], [mat-list-icon], [matListAvatar], [matListIcon]"],m8=J$(eJ((function t(){Object(m.a)(this,t)}))),g8=eJ((function t(){Object(m.a)(this,t)})),v8=new ht("MatList"),b8=new ht("MatNavList"),y8=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments))._stateChanges=new w.b,t}return Object(g.a)(n,[{key:"ngOnChanges",value:function(){this._stateChanges.next()}},{key:"ngOnDestroy",value:function(){this._stateChanges.complete()}}]),n}(m8);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-nav-list"]],hostAttrs:["role","navigation",1,"mat-nav-list","mat-list-base"],inputs:{disableRipple:"disableRipple",disabled:"disabled"},exportAs:["matNavList"],features:[Ns([{provide:b8,useExisting:t}]),ws,Ms],ngContentSelectors:c8,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),Da(0))},styles:['.mat-subheader{display:flex;box-sizing:border-box;padding:16px;align-items:center}.mat-list-base .mat-subheader{margin:0}.mat-list-base{padding-top:8px;display:block;-webkit-tap-highlight-color:transparent}.mat-list-base .mat-subheader{height:48px;line-height:16px}.mat-list-base .mat-subheader:first-child{margin-top:-8px}.mat-list-base .mat-list-item,.mat-list-base .mat-list-option{display:block;height:48px;-webkit-tap-highlight-color:transparent;width:100%;padding:0}.mat-list-base .mat-list-item .mat-list-item-content,.mat-list-base .mat-list-option .mat-list-item-content{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;padding:0 16px;position:relative;height:inherit}.mat-list-base .mat-list-item .mat-list-item-content-reverse,.mat-list-base .mat-list-option .mat-list-item-content-reverse{display:flex;align-items:center;padding:0 16px;flex-direction:row-reverse;justify-content:space-around}.mat-list-base .mat-list-item .mat-list-item-ripple,.mat-list-base .mat-list-option .mat-list-item-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-list-base .mat-list-item.mat-list-item-with-avatar,.mat-list-base .mat-list-option.mat-list-item-with-avatar{height:56px}.mat-list-base .mat-list-item.mat-2-line,.mat-list-base .mat-list-option.mat-2-line{height:72px}.mat-list-base .mat-list-item.mat-3-line,.mat-list-base .mat-list-option.mat-3-line{height:88px}.mat-list-base .mat-list-item.mat-multi-line,.mat-list-base .mat-list-option.mat-multi-line{height:auto}.mat-list-base .mat-list-item.mat-multi-line .mat-list-item-content,.mat-list-base .mat-list-option.mat-multi-line .mat-list-item-content{padding-top:16px;padding-bottom:16px}.mat-list-base .mat-list-item .mat-list-text,.mat-list-base .mat-list-option .mat-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden;padding:0}.mat-list-base .mat-list-item .mat-list-text>*,.mat-list-base .mat-list-option .mat-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-list-base .mat-list-item .mat-list-text:empty,.mat-list-base .mat-list-option .mat-list-text:empty{display:none}.mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:0;padding-left:16px}[dir=rtl] .mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:0}.mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-left:0;padding-right:16px}[dir=rtl] .mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-right:0;padding-left:16px}.mat-list-base .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:16px}.mat-list-base .mat-list-item .mat-list-avatar,.mat-list-base .mat-list-option .mat-list-avatar{flex-shrink:0;width:40px;height:40px;border-radius:50%;object-fit:cover}.mat-list-base .mat-list-item .mat-list-avatar~.mat-divider-inset,.mat-list-base .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:72px;width:calc(100% - 72px)}[dir=rtl] .mat-list-base .mat-list-item .mat-list-avatar~.mat-divider-inset,[dir=rtl] .mat-list-base .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:auto;margin-right:72px}.mat-list-base .mat-list-item .mat-list-icon,.mat-list-base .mat-list-option .mat-list-icon{flex-shrink:0;width:24px;height:24px;font-size:24px;box-sizing:content-box;border-radius:50%;padding:4px}.mat-list-base .mat-list-item .mat-list-icon~.mat-divider-inset,.mat-list-base .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:64px;width:calc(100% - 64px)}[dir=rtl] .mat-list-base .mat-list-item .mat-list-icon~.mat-divider-inset,[dir=rtl] .mat-list-base .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:auto;margin-right:64px}.mat-list-base .mat-list-item .mat-divider,.mat-list-base .mat-list-option .mat-divider{position:absolute;bottom:0;left:0;width:100%;margin:0}[dir=rtl] .mat-list-base .mat-list-item .mat-divider,[dir=rtl] .mat-list-base .mat-list-option .mat-divider{margin-left:auto;margin-right:0}.mat-list-base .mat-list-item .mat-divider.mat-divider-inset,.mat-list-base .mat-list-option .mat-divider.mat-divider-inset{position:absolute}.mat-list-base[dense]{padding-top:4px;display:block}.mat-list-base[dense] .mat-subheader{height:40px;line-height:8px}.mat-list-base[dense] .mat-subheader:first-child{margin-top:-4px}.mat-list-base[dense] .mat-list-item,.mat-list-base[dense] .mat-list-option{display:block;height:40px;-webkit-tap-highlight-color:transparent;width:100%;padding:0}.mat-list-base[dense] .mat-list-item .mat-list-item-content,.mat-list-base[dense] .mat-list-option .mat-list-item-content{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;padding:0 16px;position:relative;height:inherit}.mat-list-base[dense] .mat-list-item .mat-list-item-content-reverse,.mat-list-base[dense] .mat-list-option .mat-list-item-content-reverse{display:flex;align-items:center;padding:0 16px;flex-direction:row-reverse;justify-content:space-around}.mat-list-base[dense] .mat-list-item .mat-list-item-ripple,.mat-list-base[dense] .mat-list-option .mat-list-item-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar{height:48px}.mat-list-base[dense] .mat-list-item.mat-2-line,.mat-list-base[dense] .mat-list-option.mat-2-line{height:60px}.mat-list-base[dense] .mat-list-item.mat-3-line,.mat-list-base[dense] .mat-list-option.mat-3-line{height:76px}.mat-list-base[dense] .mat-list-item.mat-multi-line,.mat-list-base[dense] .mat-list-option.mat-multi-line{height:auto}.mat-list-base[dense] .mat-list-item.mat-multi-line .mat-list-item-content,.mat-list-base[dense] .mat-list-option.mat-multi-line .mat-list-item-content{padding-top:16px;padding-bottom:16px}.mat-list-base[dense] .mat-list-item .mat-list-text,.mat-list-base[dense] .mat-list-option .mat-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden;padding:0}.mat-list-base[dense] .mat-list-item .mat-list-text>*,.mat-list-base[dense] .mat-list-option .mat-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-list-base[dense] .mat-list-item .mat-list-text:empty,.mat-list-base[dense] .mat-list-option .mat-list-text:empty{display:none}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:0;padding-left:16px}[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:0}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-left:0;padding-right:16px}[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-right:0;padding-left:16px}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:16px}.mat-list-base[dense] .mat-list-item .mat-list-avatar,.mat-list-base[dense] .mat-list-option .mat-list-avatar{flex-shrink:0;width:36px;height:36px;border-radius:50%;object-fit:cover}.mat-list-base[dense] .mat-list-item .mat-list-avatar~.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:68px;width:calc(100% - 68px)}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-list-avatar~.mat-divider-inset,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:auto;margin-right:68px}.mat-list-base[dense] .mat-list-item .mat-list-icon,.mat-list-base[dense] .mat-list-option .mat-list-icon{flex-shrink:0;width:20px;height:20px;font-size:20px;box-sizing:content-box;border-radius:50%;padding:4px}.mat-list-base[dense] .mat-list-item .mat-list-icon~.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:60px;width:calc(100% - 60px)}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-list-icon~.mat-divider-inset,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:auto;margin-right:60px}.mat-list-base[dense] .mat-list-item .mat-divider,.mat-list-base[dense] .mat-list-option .mat-divider{position:absolute;bottom:0;left:0;width:100%;margin:0}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-divider,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-divider{margin-left:auto;margin-right:0}.mat-list-base[dense] .mat-list-item .mat-divider.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-divider.mat-divider-inset{position:absolute}.mat-nav-list a{text-decoration:none;color:inherit}.mat-nav-list .mat-list-item{cursor:pointer;outline:none}mat-action-list button{background:none;color:inherit;border:none;font:inherit;outline:inherit;-webkit-tap-highlight-color:transparent;text-align:left}[dir=rtl] mat-action-list button{text-align:right}mat-action-list button::-moz-focus-inner{border:0}mat-action-list .mat-list-item{cursor:pointer;outline:inherit}.mat-list-option:not(.mat-list-item-disabled){cursor:pointer;outline:none}.mat-list-item-disabled{pointer-events:none}.cdk-high-contrast-active .mat-list-item-disabled{opacity:.5}.cdk-high-contrast-active :host .mat-list-item-disabled{opacity:.5}.cdk-high-contrast-active .mat-selection-list:focus{outline-style:dotted}.cdk-high-contrast-active .mat-list-option:hover,.cdk-high-contrast-active .mat-list-option:focus,.cdk-high-contrast-active .mat-nav-list .mat-list-item:hover,.cdk-high-contrast-active .mat-nav-list .mat-list-item:focus,.cdk-high-contrast-active mat-action-list .mat-list-item:hover,.cdk-high-contrast-active mat-action-list .mat-list-item:focus{outline:dotted 1px}.cdk-high-contrast-active .mat-list-single-selected-option::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}.cdk-high-contrast-active [dir=rtl] .mat-list-single-selected-option::after{right:auto;left:16px}@media(hover: none){.mat-list-option:not(.mat-list-item-disabled):hover,.mat-nav-list .mat-list-item:not(.mat-list-item-disabled):hover,.mat-action-list .mat-list-item:not(.mat-list-item-disabled):hover{background:none}}\n'],encapsulation:2,changeDetection:0});var e=zn(t);return t}(),_8=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this))._elementRef=t,i._stateChanges=new w.b,"action-list"===i._getListType()&&t.nativeElement.classList.add("mat-action-list"),i}return Object(g.a)(n,[{key:"_getListType",value:function(){var t=this._elementRef.nativeElement.nodeName.toLowerCase();return"mat-list"===t?"list":"mat-action-list"===t?"action-list":null}},{key:"ngOnChanges",value:function(){this._stateChanges.next()}},{key:"ngOnDestroy",value:function(){this._stateChanges.complete()}}]),n}(m8);return t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275cmp=Ht({type:t,selectors:[["mat-list"],["mat-action-list"]],hostAttrs:[1,"mat-list","mat-list-base"],inputs:{disableRipple:"disableRipple",disabled:"disabled"},exportAs:["matList"],features:[Ns([{provide:v8,useExisting:t}]),ws,Ms],ngContentSelectors:c8,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),Da(0))},styles:['.mat-subheader{display:flex;box-sizing:border-box;padding:16px;align-items:center}.mat-list-base .mat-subheader{margin:0}.mat-list-base{padding-top:8px;display:block;-webkit-tap-highlight-color:transparent}.mat-list-base .mat-subheader{height:48px;line-height:16px}.mat-list-base .mat-subheader:first-child{margin-top:-8px}.mat-list-base .mat-list-item,.mat-list-base .mat-list-option{display:block;height:48px;-webkit-tap-highlight-color:transparent;width:100%;padding:0}.mat-list-base .mat-list-item .mat-list-item-content,.mat-list-base .mat-list-option .mat-list-item-content{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;padding:0 16px;position:relative;height:inherit}.mat-list-base .mat-list-item .mat-list-item-content-reverse,.mat-list-base .mat-list-option .mat-list-item-content-reverse{display:flex;align-items:center;padding:0 16px;flex-direction:row-reverse;justify-content:space-around}.mat-list-base .mat-list-item .mat-list-item-ripple,.mat-list-base .mat-list-option .mat-list-item-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-list-base .mat-list-item.mat-list-item-with-avatar,.mat-list-base .mat-list-option.mat-list-item-with-avatar{height:56px}.mat-list-base .mat-list-item.mat-2-line,.mat-list-base .mat-list-option.mat-2-line{height:72px}.mat-list-base .mat-list-item.mat-3-line,.mat-list-base .mat-list-option.mat-3-line{height:88px}.mat-list-base .mat-list-item.mat-multi-line,.mat-list-base .mat-list-option.mat-multi-line{height:auto}.mat-list-base .mat-list-item.mat-multi-line .mat-list-item-content,.mat-list-base .mat-list-option.mat-multi-line .mat-list-item-content{padding-top:16px;padding-bottom:16px}.mat-list-base .mat-list-item .mat-list-text,.mat-list-base .mat-list-option .mat-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden;padding:0}.mat-list-base .mat-list-item .mat-list-text>*,.mat-list-base .mat-list-option .mat-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-list-base .mat-list-item .mat-list-text:empty,.mat-list-base .mat-list-option .mat-list-text:empty{display:none}.mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:0;padding-left:16px}[dir=rtl] .mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:0}.mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-left:0;padding-right:16px}[dir=rtl] .mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-right:0;padding-left:16px}.mat-list-base .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:16px}.mat-list-base .mat-list-item .mat-list-avatar,.mat-list-base .mat-list-option .mat-list-avatar{flex-shrink:0;width:40px;height:40px;border-radius:50%;object-fit:cover}.mat-list-base .mat-list-item .mat-list-avatar~.mat-divider-inset,.mat-list-base .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:72px;width:calc(100% - 72px)}[dir=rtl] .mat-list-base .mat-list-item .mat-list-avatar~.mat-divider-inset,[dir=rtl] .mat-list-base .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:auto;margin-right:72px}.mat-list-base .mat-list-item .mat-list-icon,.mat-list-base .mat-list-option .mat-list-icon{flex-shrink:0;width:24px;height:24px;font-size:24px;box-sizing:content-box;border-radius:50%;padding:4px}.mat-list-base .mat-list-item .mat-list-icon~.mat-divider-inset,.mat-list-base .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:64px;width:calc(100% - 64px)}[dir=rtl] .mat-list-base .mat-list-item .mat-list-icon~.mat-divider-inset,[dir=rtl] .mat-list-base .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:auto;margin-right:64px}.mat-list-base .mat-list-item .mat-divider,.mat-list-base .mat-list-option .mat-divider{position:absolute;bottom:0;left:0;width:100%;margin:0}[dir=rtl] .mat-list-base .mat-list-item .mat-divider,[dir=rtl] .mat-list-base .mat-list-option .mat-divider{margin-left:auto;margin-right:0}.mat-list-base .mat-list-item .mat-divider.mat-divider-inset,.mat-list-base .mat-list-option .mat-divider.mat-divider-inset{position:absolute}.mat-list-base[dense]{padding-top:4px;display:block}.mat-list-base[dense] .mat-subheader{height:40px;line-height:8px}.mat-list-base[dense] .mat-subheader:first-child{margin-top:-4px}.mat-list-base[dense] .mat-list-item,.mat-list-base[dense] .mat-list-option{display:block;height:40px;-webkit-tap-highlight-color:transparent;width:100%;padding:0}.mat-list-base[dense] .mat-list-item .mat-list-item-content,.mat-list-base[dense] .mat-list-option .mat-list-item-content{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;padding:0 16px;position:relative;height:inherit}.mat-list-base[dense] .mat-list-item .mat-list-item-content-reverse,.mat-list-base[dense] .mat-list-option .mat-list-item-content-reverse{display:flex;align-items:center;padding:0 16px;flex-direction:row-reverse;justify-content:space-around}.mat-list-base[dense] .mat-list-item .mat-list-item-ripple,.mat-list-base[dense] .mat-list-option .mat-list-item-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar{height:48px}.mat-list-base[dense] .mat-list-item.mat-2-line,.mat-list-base[dense] .mat-list-option.mat-2-line{height:60px}.mat-list-base[dense] .mat-list-item.mat-3-line,.mat-list-base[dense] .mat-list-option.mat-3-line{height:76px}.mat-list-base[dense] .mat-list-item.mat-multi-line,.mat-list-base[dense] .mat-list-option.mat-multi-line{height:auto}.mat-list-base[dense] .mat-list-item.mat-multi-line .mat-list-item-content,.mat-list-base[dense] .mat-list-option.mat-multi-line .mat-list-item-content{padding-top:16px;padding-bottom:16px}.mat-list-base[dense] .mat-list-item .mat-list-text,.mat-list-base[dense] .mat-list-option .mat-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden;padding:0}.mat-list-base[dense] .mat-list-item .mat-list-text>*,.mat-list-base[dense] .mat-list-option .mat-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-list-base[dense] .mat-list-item .mat-list-text:empty,.mat-list-base[dense] .mat-list-option .mat-list-text:empty{display:none}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:0;padding-left:16px}[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:0}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-left:0;padding-right:16px}[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-right:0;padding-left:16px}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:16px}.mat-list-base[dense] .mat-list-item .mat-list-avatar,.mat-list-base[dense] .mat-list-option .mat-list-avatar{flex-shrink:0;width:36px;height:36px;border-radius:50%;object-fit:cover}.mat-list-base[dense] .mat-list-item .mat-list-avatar~.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:68px;width:calc(100% - 68px)}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-list-avatar~.mat-divider-inset,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:auto;margin-right:68px}.mat-list-base[dense] .mat-list-item .mat-list-icon,.mat-list-base[dense] .mat-list-option .mat-list-icon{flex-shrink:0;width:20px;height:20px;font-size:20px;box-sizing:content-box;border-radius:50%;padding:4px}.mat-list-base[dense] .mat-list-item .mat-list-icon~.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:60px;width:calc(100% - 60px)}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-list-icon~.mat-divider-inset,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:auto;margin-right:60px}.mat-list-base[dense] .mat-list-item .mat-divider,.mat-list-base[dense] .mat-list-option .mat-divider{position:absolute;bottom:0;left:0;width:100%;margin:0}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-divider,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-divider{margin-left:auto;margin-right:0}.mat-list-base[dense] .mat-list-item .mat-divider.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-divider.mat-divider-inset{position:absolute}.mat-nav-list a{text-decoration:none;color:inherit}.mat-nav-list .mat-list-item{cursor:pointer;outline:none}mat-action-list button{background:none;color:inherit;border:none;font:inherit;outline:inherit;-webkit-tap-highlight-color:transparent;text-align:left}[dir=rtl] mat-action-list button{text-align:right}mat-action-list button::-moz-focus-inner{border:0}mat-action-list .mat-list-item{cursor:pointer;outline:inherit}.mat-list-option:not(.mat-list-item-disabled){cursor:pointer;outline:none}.mat-list-item-disabled{pointer-events:none}.cdk-high-contrast-active .mat-list-item-disabled{opacity:.5}.cdk-high-contrast-active :host .mat-list-item-disabled{opacity:.5}.cdk-high-contrast-active .mat-selection-list:focus{outline-style:dotted}.cdk-high-contrast-active .mat-list-option:hover,.cdk-high-contrast-active .mat-list-option:focus,.cdk-high-contrast-active .mat-nav-list .mat-list-item:hover,.cdk-high-contrast-active .mat-nav-list .mat-list-item:focus,.cdk-high-contrast-active mat-action-list .mat-list-item:hover,.cdk-high-contrast-active mat-action-list .mat-list-item:focus{outline:dotted 1px}.cdk-high-contrast-active .mat-list-single-selected-option::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}.cdk-high-contrast-active [dir=rtl] .mat-list-single-selected-option::after{right:auto;left:16px}@media(hover: none){.mat-list-option:not(.mat-list-item-disabled):hover,.mat-nav-list .mat-list-item:not(.mat-list-item-disabled):hover,.mat-action-list .mat-list-item:not(.mat-list-item-disabled):hover{background:none}}\n'],encapsulation:2,changeDetection:0}),t}(),w8=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-list-avatar",""],["","matListAvatar",""]],hostAttrs:[1,"mat-list-avatar"]}),t}(),k8=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-list-icon",""],["","matListIcon",""]],hostAttrs:[1,"mat-list-icon"]}),t}(),C8=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-subheader",""],["","matSubheader",""]],hostAttrs:[1,"mat-subheader"]}),t}(),S8=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;Object(m.a)(this,n),(a=e.call(this))._element=t,a._isInteractiveList=!1,a._destroyed=new w.b,a._disabled=!1,a._isInteractiveList=!!(r||o&&"action-list"===o._getListType()),a._list=r||o;var s=a._getHostElement();return"button"!==s.nodeName.toLowerCase()||s.hasAttribute("type")||s.setAttribute("type","button"),a._list&&a._list._stateChanges.pipe(Object(Am.a)(a._destroyed)).subscribe((function(){i.markForCheck()})),a}return Object(g.a)(n,[{key:"ngAfterContentInit",value:function(){sJ(this._lines,this._element)}},{key:"ngOnDestroy",value:function(){this._destroyed.next(),this._destroyed.complete()}},{key:"_isRippleDisabled",value:function(){return!this._isInteractiveList||this.disableRipple||!(!this._list||!this._list.disableRipple)}},{key:"_getHostElement",value:function(){return this._element.nativeElement}},{key:"disabled",get:function(){return this._disabled||!(!this._list||!this._list.disabled)},set:function(t){this._disabled=nm(t)}}]),n}(g8);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(b8,8),da(v8,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-list-item"],["a","mat-list-item",""],["button","mat-list-item",""]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,w8,!0),rl(n,k8,!0),rl(n,aJ,!0)),2&t&&(tl(i=sl())&&(e._avatar=i.first),tl(i=sl())&&(e._icon=i.first),tl(i=sl())&&(e._lines=i))},hostAttrs:[1,"mat-list-item","mat-focus-indicator"],hostVars:6,hostBindings:function(t,e){2&t&&Qa("mat-list-item-disabled",e.disabled)("mat-list-item-avatar",e._avatar||e._icon)("mat-list-item-with-avatar",e._avatar||e._icon)},inputs:{disableRipple:"disableRipple",disabled:"disabled"},exportAs:["matListItem"],features:[ws],ngContentSelectors:u8,decls:6,vars:2,consts:[[1,"mat-list-item-content"],["mat-ripple","",1,"mat-list-item-ripple",3,"matRippleTrigger","matRippleDisabled"],[1,"mat-list-text"]],template:function(t,e){1&t&&(Ia(l8),ga(0,"div",0),ba(1,"div",1),Da(2),ga(3,"div",2),Da(4,1),va(),Da(5,2),va()),2&t&&(Qi(1),pa("matRippleTrigger",e._getHostElement())("matRippleDisabled",e._isRippleDisabled()))},directives:[yJ],encapsulation:2,changeDetection:0}),t}(),x8=eJ((function t(){Object(m.a)(this,t)})),O8=eJ((function t(){Object(m.a)(this,t)})),M8={provide:nf,useExisting:Y((function(){return P8})),multi:!0},T8=function t(e,n){Object(m.a)(this,t),this.source=e,this.option=n},E8=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this))._element=t,o._changeDetector=i,o.selectionList=r,o._selected=!1,o._disabled=!1,o._hasFocus=!1,o.checkboxPosition="after",o._inputsInitialized=!1,o}return Object(g.a)(n,[{key:"ngOnInit",value:function(){var t=this,e=this.selectionList;e._value&&e._value.some((function(n){return e.compareWith(n,t._value)}))&&this._setSelected(!0);var n=this._selected;Promise.resolve().then((function(){(t._selected||n)&&(t.selected=!0,t._changeDetector.markForCheck())})),this._inputsInitialized=!0}},{key:"ngAfterContentInit",value:function(){sJ(this._lines,this._element)}},{key:"ngOnDestroy",value:function(){var t=this;this.selected&&Promise.resolve().then((function(){t.selected=!1}));var e=this._hasFocus,n=this.selectionList._removeOptionFromList(this);e&&n&&n.focus()}},{key:"toggle",value:function(){this.selected=!this.selected}},{key:"focus",value:function(){this._element.nativeElement.focus()}},{key:"getLabel",value:function(){return this._text&&this._text.nativeElement.textContent||""}},{key:"_isRippleDisabled",value:function(){return this.disabled||this.disableRipple||this.selectionList.disableRipple}},{key:"_handleClick",value:function(){this.disabled||!this.selectionList.multiple&&this.selected||(this.toggle(),this.selectionList._emitChangeEvent(this))}},{key:"_handleFocus",value:function(){this.selectionList._setFocusedOption(this),this._hasFocus=!0}},{key:"_handleBlur",value:function(){this.selectionList._onTouched(),this._hasFocus=!1}},{key:"_getHostElement",value:function(){return this._element.nativeElement}},{key:"_setSelected",value:function(t){return t!==this._selected&&(this._selected=t,t?this.selectionList.selectedOptions.select(this):this.selectionList.selectedOptions.deselect(this),this._changeDetector.markForCheck(),!0)}},{key:"_markForCheck",value:function(){this._changeDetector.markForCheck()}},{key:"color",get:function(){return this._color||this.selectionList.color},set:function(t){this._color=t}},{key:"value",get:function(){return this._value},set:function(t){this.selected&&t!==this.value&&this._inputsInitialized&&(this.selected=!1),this._value=t}},{key:"disabled",get:function(){return this._disabled||this.selectionList&&this.selectionList.disabled},set:function(t){var e=nm(t);e!==this._disabled&&(this._disabled=e,this._changeDetector.markForCheck())}},{key:"selected",get:function(){return this.selectionList.selectedOptions.isSelected(this)},set:function(t){var e=nm(t);e!==this._selected&&(this._setSelected(e),this.selectionList._reportValueChange())}}]),n}(O8);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(Y((function(){return P8}))))},t.\u0275cmp=Ht({type:t,selectors:[["mat-list-option"]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,w8,!0),rl(n,k8,!0),rl(n,aJ,!0)),2&t&&(tl(i=sl())&&(e._avatar=i.first),tl(i=sl())&&(e._icon=i.first),tl(i=sl())&&(e._lines=i))},viewQuery:function(t,e){var n;1&t&&nl(h8,!0),2&t&&tl(n=sl())&&(e._text=n.first)},hostAttrs:["role","option",1,"mat-list-item","mat-list-option","mat-focus-indicator"],hostVars:15,hostBindings:function(t,e){1&t&&xa("focus",(function(){return e._handleFocus()}))("blur",(function(){return e._handleBlur()}))("click",(function(){return e._handleClick()})),2&t&&(oa("aria-selected",e.selected)("aria-disabled",e.disabled)("tabindex",-1),Qa("mat-list-item-disabled",e.disabled)("mat-list-item-with-avatar",e._avatar||e._icon)("mat-primary","primary"===e.color)("mat-accent","primary"!==e.color&&"warn"!==e.color)("mat-warn","warn"===e.color)("mat-list-single-selected-option",e.selected&&!e.selectionList.multiple))},inputs:{disableRipple:"disableRipple",checkboxPosition:"checkboxPosition",color:"color",value:"value",selected:"selected",disabled:"disabled"},exportAs:["matListOption"],features:[ws],ngContentSelectors:p8,decls:7,vars:5,consts:[[1,"mat-list-item-content"],["mat-ripple","",1,"mat-list-item-ripple",3,"matRippleTrigger","matRippleDisabled"],[3,"state","disabled",4,"ngIf"],[1,"mat-list-text"],["text",""],[3,"state","disabled"]],template:function(t,e){1&t&&(Ia(f8),ga(0,"div",0),ba(1,"div",1),ua(2,d8,1,2,"mat-pseudo-checkbox",2),ga(3,"div",3,4),Da(5),va(),Da(6,1),va()),2&t&&(Qa("mat-list-item-content-reverse","after"==e.checkboxPosition),Qi(1),pa("matRippleTrigger",e._getHostElement())("matRippleDisabled",e._isRippleDisabled()),Qi(1),pa("ngIf",e.selectionList.multiple))},directives:[yJ,Ah,wJ],encapsulation:2,changeDetection:0}),t}(),P8=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this))._element=t,o._changeDetector=r,o._multiple=!0,o._contentInitialized=!1,o.selectionChange=new Uc,o.tabIndex=0,o.color="accent",o.compareWith=function(t,e){return t===e},o._disabled=!1,o.selectedOptions=new fm(o._multiple),o._tabIndex=-1,o._onChange=function(t){},o._destroyed=new w.b,o._onTouched=function(){},o}return Object(g.a)(n,[{key:"ngAfterContentInit",value:function(){var t=this;this._contentInitialized=!0,this._keyManager=new d$(this.options).withWrap().withTypeAhead().skipPredicate((function(){return!1})).withAllowedModifierKeys(["shiftKey"]),this._value&&this._setOptionsFromValues(this._value),this._keyManager.tabOut.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){t._allowFocusEscape()})),this.options.changes.pipe(Object(NX.a)(null),Object(Am.a)(this._destroyed)).subscribe((function(){t._updateTabIndex()})),this.selectedOptions.changed.pipe(Object(Am.a)(this._destroyed)).subscribe((function(t){if(t.added){var e,n=d(t.added);try{for(n.s();!(e=n.n()).done;)e.value.selected=!0}catch(o){n.e(o)}finally{n.f()}}if(t.removed){var i,r=d(t.removed);try{for(r.s();!(i=r.n()).done;)i.value.selected=!1}catch(o){r.e(o)}finally{r.f()}}}))}},{key:"ngOnChanges",value:function(t){var e=t.disableRipple,n=t.color;(e&&!e.firstChange||n&&!n.firstChange)&&this._markOptionsForCheck()}},{key:"ngOnDestroy",value:function(){this._destroyed.next(),this._destroyed.complete(),this._isDestroyed=!0}},{key:"focus",value:function(t){this._element.nativeElement.focus(t)}},{key:"selectAll",value:function(){this._setAllOptionsSelected(!0)}},{key:"deselectAll",value:function(){this._setAllOptionsSelected(!1)}},{key:"_setFocusedOption",value:function(t){this._keyManager.updateActiveItem(t)}},{key:"_removeOptionFromList",value:function(t){var e=this._getOptionIndex(t);return e>-1&&this._keyManager.activeItemIndex===e&&(e>0?this._keyManager.updateActiveItem(e-1):0===e&&this.options.length>1&&this._keyManager.updateActiveItem(Math.min(e+1,this.options.length-1))),this._keyManager.activeItem}},{key:"_keydown",value:function(t){var e=t.keyCode,n=this._keyManager,i=n.activeItemIndex,r=JQ(t);switch(e){case 32:case 13:r||n.isTyping()||(this._toggleFocusedOption(),t.preventDefault());break;case 36:case 35:r||(36===e?n.setFirstItemActive():n.setLastItemActive(),t.preventDefault());break;default:if(65===e&&this.multiple&&JQ(t,"ctrlKey")&&!n.isTyping()){var o=this.options.some((function(t){return!t.disabled&&!t.selected}));this._setAllOptionsSelected(o,!0),t.preventDefault()}else n.onKeydown(t)}this.multiple&&(38===e||40===e)&&t.shiftKey&&n.activeItemIndex!==i&&this._toggleFocusedOption()}},{key:"_reportValueChange",value:function(){if(this.options&&!this._isDestroyed){var t=this._getSelectedOptionValues();this._onChange(t),this._value=t}}},{key:"_emitChangeEvent",value:function(t){this.selectionChange.emit(new T8(this,t))}},{key:"_onFocus",value:function(){var t=this._keyManager.activeItemIndex;t&&-1!==t?this._keyManager.setActiveItem(t):this._keyManager.setFirstItemActive()}},{key:"writeValue",value:function(t){this._value=t,this.options&&this._setOptionsFromValues(t||[])}},{key:"setDisabledState",value:function(t){this.disabled=t}},{key:"registerOnChange",value:function(t){this._onChange=t}},{key:"registerOnTouched",value:function(t){this._onTouched=t}},{key:"_setOptionsFromValues",value:function(t){var e=this;this.options.forEach((function(t){return t._setSelected(!1)})),t.forEach((function(t){var n=e.options.find((function(n){return!n.selected&&e.compareWith(n.value,t)}));n&&n._setSelected(!0)}))}},{key:"_getSelectedOptionValues",value:function(){return this.options.filter((function(t){return t.selected})).map((function(t){return t.value}))}},{key:"_toggleFocusedOption",value:function(){var t=this._keyManager.activeItemIndex;if(null!=t&&this._isValidIndex(t)){var e=this.options.toArray()[t];!e||e.disabled||!this._multiple&&e.selected||(e.toggle(),this._emitChangeEvent(e))}}},{key:"_setAllOptionsSelected",value:function(t,e){var n=!1;this.options.forEach((function(i){e&&i.disabled||!i._setSelected(t)||(n=!0)})),n&&this._reportValueChange()}},{key:"_isValidIndex",value:function(t){return t>=0&&t<this.options.length}},{key:"_getOptionIndex",value:function(t){return this.options.toArray().indexOf(t)}},{key:"_markOptionsForCheck",value:function(){this.options&&this.options.forEach((function(t){return t._markForCheck()}))}},{key:"_allowFocusEscape",value:function(){var t=this;this._tabIndex=-1,setTimeout((function(){t._tabIndex=0,t._changeDetector.markForCheck()}))}},{key:"_updateTabIndex",value:function(){this._tabIndex=0===this.options.length?-1:0}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t),this._markOptionsForCheck()}},{key:"multiple",get:function(){return this._multiple},set:function(t){var e=nm(t);if(e!==this._multiple){if(ii()&&this._contentInitialized)throw new Error("Cannot change `multiple` mode of mat-selection-list after initialization.");this._multiple=e,this.selectedOptions=new fm(this._multiple,this.selectedOptions.selected)}}}]),n}(x8);return t.\u0275fac=function(e){return new(e||t)(da(Us),fa("tabindex"),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["mat-selection-list"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,E8,!0),2&t&&tl(i=sl())&&(e.options=i)},hostAttrs:["role","listbox",1,"mat-selection-list","mat-list-base"],hostVars:3,hostBindings:function(t,e){1&t&&xa("focus",(function(){return e._onFocus()}))("keydown",(function(t){return e._keydown(t)})),2&t&&oa("aria-multiselectable",e.multiple)("aria-disabled",e.disabled.toString())("tabindex",e._tabIndex)},inputs:{disableRipple:"disableRipple",tabIndex:"tabIndex",color:"color",compareWith:"compareWith",disabled:"disabled",multiple:"multiple"},outputs:{selectionChange:"selectionChange"},exportAs:["matSelectionList"],features:[Ns([M8]),ws,Ms],ngContentSelectors:c8,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),Da(0))},styles:['.mat-subheader{display:flex;box-sizing:border-box;padding:16px;align-items:center}.mat-list-base .mat-subheader{margin:0}.mat-list-base{padding-top:8px;display:block;-webkit-tap-highlight-color:transparent}.mat-list-base .mat-subheader{height:48px;line-height:16px}.mat-list-base .mat-subheader:first-child{margin-top:-8px}.mat-list-base .mat-list-item,.mat-list-base .mat-list-option{display:block;height:48px;-webkit-tap-highlight-color:transparent;width:100%;padding:0}.mat-list-base .mat-list-item .mat-list-item-content,.mat-list-base .mat-list-option .mat-list-item-content{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;padding:0 16px;position:relative;height:inherit}.mat-list-base .mat-list-item .mat-list-item-content-reverse,.mat-list-base .mat-list-option .mat-list-item-content-reverse{display:flex;align-items:center;padding:0 16px;flex-direction:row-reverse;justify-content:space-around}.mat-list-base .mat-list-item .mat-list-item-ripple,.mat-list-base .mat-list-option .mat-list-item-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-list-base .mat-list-item.mat-list-item-with-avatar,.mat-list-base .mat-list-option.mat-list-item-with-avatar{height:56px}.mat-list-base .mat-list-item.mat-2-line,.mat-list-base .mat-list-option.mat-2-line{height:72px}.mat-list-base .mat-list-item.mat-3-line,.mat-list-base .mat-list-option.mat-3-line{height:88px}.mat-list-base .mat-list-item.mat-multi-line,.mat-list-base .mat-list-option.mat-multi-line{height:auto}.mat-list-base .mat-list-item.mat-multi-line .mat-list-item-content,.mat-list-base .mat-list-option.mat-multi-line .mat-list-item-content{padding-top:16px;padding-bottom:16px}.mat-list-base .mat-list-item .mat-list-text,.mat-list-base .mat-list-option .mat-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden;padding:0}.mat-list-base .mat-list-item .mat-list-text>*,.mat-list-base .mat-list-option .mat-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-list-base .mat-list-item .mat-list-text:empty,.mat-list-base .mat-list-option .mat-list-text:empty{display:none}.mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:0;padding-left:16px}[dir=rtl] .mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:0}.mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-left:0;padding-right:16px}[dir=rtl] .mat-list-base .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-right:0;padding-left:16px}.mat-list-base .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:16px}.mat-list-base .mat-list-item .mat-list-avatar,.mat-list-base .mat-list-option .mat-list-avatar{flex-shrink:0;width:40px;height:40px;border-radius:50%;object-fit:cover}.mat-list-base .mat-list-item .mat-list-avatar~.mat-divider-inset,.mat-list-base .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:72px;width:calc(100% - 72px)}[dir=rtl] .mat-list-base .mat-list-item .mat-list-avatar~.mat-divider-inset,[dir=rtl] .mat-list-base .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:auto;margin-right:72px}.mat-list-base .mat-list-item .mat-list-icon,.mat-list-base .mat-list-option .mat-list-icon{flex-shrink:0;width:24px;height:24px;font-size:24px;box-sizing:content-box;border-radius:50%;padding:4px}.mat-list-base .mat-list-item .mat-list-icon~.mat-divider-inset,.mat-list-base .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:64px;width:calc(100% - 64px)}[dir=rtl] .mat-list-base .mat-list-item .mat-list-icon~.mat-divider-inset,[dir=rtl] .mat-list-base .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:auto;margin-right:64px}.mat-list-base .mat-list-item .mat-divider,.mat-list-base .mat-list-option .mat-divider{position:absolute;bottom:0;left:0;width:100%;margin:0}[dir=rtl] .mat-list-base .mat-list-item .mat-divider,[dir=rtl] .mat-list-base .mat-list-option .mat-divider{margin-left:auto;margin-right:0}.mat-list-base .mat-list-item .mat-divider.mat-divider-inset,.mat-list-base .mat-list-option .mat-divider.mat-divider-inset{position:absolute}.mat-list-base[dense]{padding-top:4px;display:block}.mat-list-base[dense] .mat-subheader{height:40px;line-height:8px}.mat-list-base[dense] .mat-subheader:first-child{margin-top:-4px}.mat-list-base[dense] .mat-list-item,.mat-list-base[dense] .mat-list-option{display:block;height:40px;-webkit-tap-highlight-color:transparent;width:100%;padding:0}.mat-list-base[dense] .mat-list-item .mat-list-item-content,.mat-list-base[dense] .mat-list-option .mat-list-item-content{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;padding:0 16px;position:relative;height:inherit}.mat-list-base[dense] .mat-list-item .mat-list-item-content-reverse,.mat-list-base[dense] .mat-list-option .mat-list-item-content-reverse{display:flex;align-items:center;padding:0 16px;flex-direction:row-reverse;justify-content:space-around}.mat-list-base[dense] .mat-list-item .mat-list-item-ripple,.mat-list-base[dense] .mat-list-option .mat-list-item-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar{height:48px}.mat-list-base[dense] .mat-list-item.mat-2-line,.mat-list-base[dense] .mat-list-option.mat-2-line{height:60px}.mat-list-base[dense] .mat-list-item.mat-3-line,.mat-list-base[dense] .mat-list-option.mat-3-line{height:76px}.mat-list-base[dense] .mat-list-item.mat-multi-line,.mat-list-base[dense] .mat-list-option.mat-multi-line{height:auto}.mat-list-base[dense] .mat-list-item.mat-multi-line .mat-list-item-content,.mat-list-base[dense] .mat-list-option.mat-multi-line .mat-list-item-content{padding-top:16px;padding-bottom:16px}.mat-list-base[dense] .mat-list-item .mat-list-text,.mat-list-base[dense] .mat-list-option .mat-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden;padding:0}.mat-list-base[dense] .mat-list-item .mat-list-text>*,.mat-list-base[dense] .mat-list-option .mat-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-list-base[dense] .mat-list-item .mat-list-text:empty,.mat-list-base[dense] .mat-list-option .mat-list-text:empty{display:none}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:0;padding-left:16px}[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:0}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-left:0;padding-right:16px}[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-item.mat-list-option .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar .mat-list-item-content-reverse .mat-list-text,[dir=rtl] .mat-list-base[dense] .mat-list-option.mat-list-option .mat-list-item-content-reverse .mat-list-text{padding-right:0;padding-left:16px}.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-item.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content-reverse .mat-list-text,.mat-list-base[dense] .mat-list-option.mat-list-item-with-avatar.mat-list-option .mat-list-item-content .mat-list-text{padding-right:16px;padding-left:16px}.mat-list-base[dense] .mat-list-item .mat-list-avatar,.mat-list-base[dense] .mat-list-option .mat-list-avatar{flex-shrink:0;width:36px;height:36px;border-radius:50%;object-fit:cover}.mat-list-base[dense] .mat-list-item .mat-list-avatar~.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:68px;width:calc(100% - 68px)}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-list-avatar~.mat-divider-inset,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-list-avatar~.mat-divider-inset{margin-left:auto;margin-right:68px}.mat-list-base[dense] .mat-list-item .mat-list-icon,.mat-list-base[dense] .mat-list-option .mat-list-icon{flex-shrink:0;width:20px;height:20px;font-size:20px;box-sizing:content-box;border-radius:50%;padding:4px}.mat-list-base[dense] .mat-list-item .mat-list-icon~.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:60px;width:calc(100% - 60px)}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-list-icon~.mat-divider-inset,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-list-icon~.mat-divider-inset{margin-left:auto;margin-right:60px}.mat-list-base[dense] .mat-list-item .mat-divider,.mat-list-base[dense] .mat-list-option .mat-divider{position:absolute;bottom:0;left:0;width:100%;margin:0}[dir=rtl] .mat-list-base[dense] .mat-list-item .mat-divider,[dir=rtl] .mat-list-base[dense] .mat-list-option .mat-divider{margin-left:auto;margin-right:0}.mat-list-base[dense] .mat-list-item .mat-divider.mat-divider-inset,.mat-list-base[dense] .mat-list-option .mat-divider.mat-divider-inset{position:absolute}.mat-nav-list a{text-decoration:none;color:inherit}.mat-nav-list .mat-list-item{cursor:pointer;outline:none}mat-action-list button{background:none;color:inherit;border:none;font:inherit;outline:inherit;-webkit-tap-highlight-color:transparent;text-align:left}[dir=rtl] mat-action-list button{text-align:right}mat-action-list button::-moz-focus-inner{border:0}mat-action-list .mat-list-item{cursor:pointer;outline:inherit}.mat-list-option:not(.mat-list-item-disabled){cursor:pointer;outline:none}.mat-list-item-disabled{pointer-events:none}.cdk-high-contrast-active .mat-list-item-disabled{opacity:.5}.cdk-high-contrast-active :host .mat-list-item-disabled{opacity:.5}.cdk-high-contrast-active .mat-selection-list:focus{outline-style:dotted}.cdk-high-contrast-active .mat-list-option:hover,.cdk-high-contrast-active .mat-list-option:focus,.cdk-high-contrast-active .mat-nav-list .mat-list-item:hover,.cdk-high-contrast-active .mat-nav-list .mat-list-item:focus,.cdk-high-contrast-active mat-action-list .mat-list-item:hover,.cdk-high-contrast-active mat-action-list .mat-list-item:focus{outline:dotted 1px}.cdk-high-contrast-active .mat-list-single-selected-option::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}.cdk-high-contrast-active [dir=rtl] .mat-list-single-selected-option::after{right:auto;left:16px}@media(hover: none){.mat-list-option:not(.mat-list-item-disabled):hover,.mat-nav-list .mat-list-item:not(.mat-list-item-disabled):hover,.mat-action-list .mat-list-item:not(.mat-list-item-disabled):hover{background:none}}\n'],encapsulation:2,changeDetection:0}),t}(),A8=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[lJ,_J,$$,kJ,hd],lJ,$$,kJ,s8]}),t}();function j8(t,e){if(1&t){var n=ka();ga(0,"mat-list-item"),ga(1,"div",6),ga(2,"span",7),ds(3),va(),ga(4,"span",7),ga(5,"input",9),xa("ngModelChange",(function(t){return Se(n),e.$implicit.port_name=t})),va(),va(),va(),va()}if(2&t){var i=e.$implicit;Qi(3),ps(" Adapter ",i.adapter_number," "),Qi(2),pa("ngModel",i.port_name)}}function I8(t,e){if(1&t&&(ga(0,"div",5),ga(1,"div",6),ga(2,"span",7),ds(3," Adapter number "),va(),ga(4,"span",7),ds(5," Port name "),va(),va(),ga(6,"div"),ga(7,"mat-list"),ua(8,j8,6,2,"mat-list-item",8),va(),va(),va()),2&t){var n=Aa();Qi(8),pa("ngForOf",n.adapters)}}var D8=function(){function t(t,e,n,i,r){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.dockerConfigurationService=r,this.displayedColumns=["adapter_number","port_name"],this.adapters=[]}return t.prototype.ngOnInit=function(){var t=this;this.node.custom_adapters?this.adapters=this.node.custom_adapters:this.node.ports.forEach((function(e){t.adapters.push({adapter_number:0,port_name:""})}))},t.prototype.onSaveClick=function(){var t=this;this.node.custom_adapters=this.adapters,this.nodeService.updateNodeWithCustomAdapters(this.server,this.node).subscribe((function(){t.onCancelClick(),t.toasterService.success("Configuration saved for node "+t.node.name)}))},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(i8))},t.\u0275cmp=Ht({type:t,selectors:[["app-configure-custom-adapters"]],decls:8,vars:2,consts:[["mat-dialog-title",""],["class","modal-form-container",4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[1,"modal-form-container"],[1,"header"],[1,"column"],[4,"ngFor","ngForOf"],["matInput","","type","text","placeholder","Edit port name",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ua(2,I8,9,1,"div",1),ga(3,"div",2),ga(4,"button",3),xa("click",(function(){return e.onCancelClick()})),ds(5,"Cancel"),va(),ga(6,"button",4),xa("click",(function(){return e.onSaveClick()})),ds(7,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configure custom adapters for node ",e.node.name,""),Qi(1),pa("ngIf",e.node))},directives:[r1,Ah,a1,a2,_8,Eh,S8,s5,cf,mf,Sp],styles:["th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;width:100%}.column[_ngcontent-%COMP%]{width:50%}"]}),t}();function R8(t,e){if(1&t&&(ga(0,"mat-option",26),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function L8(t,e){if(1&t&&(ga(0,"mat-option",26),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var F8=function(){return{standalone:!0}};function N8(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ba(2,"br"),ga(3,"form",10),ga(4,"mat-form-field",11),ga(5,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().node.name=t})),va(),va(),ga(6,"mat-form-field",11),ga(7,"input",13),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.start_command=t})),va(),va(),ga(8,"mat-form-field",11),ga(9,"input",14),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.adapters=t})),va(),va(),ga(10,"button",15),xa("click",(function(){return Se(n),Aa().configureCustomAdapters()})),ds(11," Configure custom adapters "),va(),ga(12,"mat-form-field",16),ga(13,"mat-select",17),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_type=t})),ua(14,R8,2,2,"mat-option",18),va(),va(),ga(15,"mat-checkbox",19),xa("ngModelChange",(function(t){return Se(n),Aa().node.console_auto_start=t})),ds(16," Auto start console "),va(),ga(17,"mat-form-field",11),ga(18,"mat-select",20),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.console_resolution=t})),ua(19,L8,2,2,"mat-option",18),va(),va(),ga(20,"mat-form-field",11),ga(21,"input",21),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.console_http_port=t})),va(),va(),ga(22,"mat-form-field",11),ga(23,"input",22),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.console_http_path=t})),va(),va(),ga(24,"button",15),xa("click",(function(){return Se(n),Aa().editNetworkConfiguration()})),ds(25," Edit network configuration "),va(),va(),ga(26,"h6"),ds(27,"Environment"),va(),ga(28,"mat-form-field",11),ga(29,"textarea",23),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.environment=t})),va(),va(),va(),ga(30,"mat-tab",24),ga(31,"h6"),ds(32,"Extra hosts"),va(),ga(33,"mat-form-field",11),ga(34,"textarea",23),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.extra_hosts=t})),va(),va(),ba(35,"br"),ga(36,"h6"),ds(37,"Additional directories"),va(),ga(38,"mat-form-field",11),ga(39,"textarea",23),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.extra_volumes=t})),va(),va(),va(),ga(40,"mat-tab",25),ga(41,"mat-form-field",11),ga(42,"textarea",23),xa("ngModelChange",(function(t){return Se(n),Aa().node.properties.usage=t})),va(),va(),va(),va()}if(2&t){var i=Aa();Qi(3),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.node.name),Qi(2),pa("ngModel",i.node.properties.start_command),Qi(2),pa("ngModel",i.node.properties.adapters),Qi(4),pa("ngModelOptions",jc(18,F8))("ngModel",i.node.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModelOptions",jc(19,F8))("ngModel",i.node.console_auto_start),Qi(3),pa("ngModelOptions",jc(20,F8))("ngModel",i.node.properties.console_resolution),Qi(1),pa("ngForOf",i.consoleResolutions),Qi(2),pa("ngModel",i.node.properties.console_http_port),Qi(2),pa("ngModel",i.node.properties.console_http_path),Qi(6),pa("ngModel",i.node.properties.environment),Qi(5),pa("ngModel",i.node.properties.extra_hosts),Qi(5),pa("ngModel",i.node.properties.extra_volumes),Qi(3),pa("ngModel",i.node.properties.usage)}}var B8=function(){function t(t,e,n,i,r,o){this.dialogReference=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.dockerConfigurationService=r,this.dialog=o,this.consoleTypes=[],this.consoleResolutions=["640x480","800x600","1024x768","1280x800","1280x1024","1366x768","1920x1080"],this.conf={autoFocus:!1,width:"800px",disableClose:!0},this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required),adapter:new hp("",kf.required),startCommand:new hp("",kf.required),consoleHttpPort:new hp("",kf.required),consoleHttpPath:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name,t.getConfiguration()}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.dockerConfigurationService.getConsoleTypes()},t.prototype.configureCustomAdapters=function(){this.dialogRef=this.dialog.open(D8,this.conf);var t=this.dialogRef.componentInstance;t.server=this.server,t.node=this.node},t.prototype.editNetworkConfiguration=function(){this.dialogRef=this.dialog.open(o8,this.conf);var t=this.dialogRef.componentInstance;t.server=this.server,t.node=this.node},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid?this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()})):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogReference.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp),da(i8),da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-docker"]],decls:12,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["label","General settings"],[3,"formGroup"],[1,"form-field"],["matInput","","formControlName","name","type","text","placeholder","Name",3,"ngModel","ngModelChange"],["matInput","","formControlName","startCommand","type","text","placeholder","Start command",3,"ngModel","ngModelChange"],["formControlName","adapter","matInput","","type","number","placeholder","Adapters",3,"ngModel","ngModelChange"],["mat-button","",1,"form-field",3,"click"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ngModelOptions","ngModel","ngModelChange"],["placeholder","VNC console resolution",3,"ngModelOptions","ngModel","ngModelChange"],["formControlName","consoleHttpPort","matInput","","type","number","placeholder","HTTP port in the container",3,"ngModel","ngModelChange"],["matInput","","formControlName","consoleHttpPath","type","text","placeholder","HTTP path",3,"ngModel","ngModelChange"],["matInput","","type","text",3,"ngModel","ngModelChange"],["label","Advanced"],["label","Usage"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ua(6,N8,43,21,"mat-tab-group",5),va(),va(),va(),va(),ga(7,"div",6),ga(8,"button",7),xa("click",(function(){return e.onCancelClick()})),ds(9,"Cancel"),va(),ga(10,"button",8),xa("click",(function(){return e.onSaveClick()})),ds(11,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("ngIf",e.name))},directives:[r1,f3,Ah,a1,a2,U1,I1,xp,gf,Pp,Y3,s5,cf,mf,Fp,Ef,O5,Sp,Eh,F5,EJ],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),H8=function(){function t(t,e,n,i){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name}))},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid?this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()})):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-nat"]],decls:14,vars:3,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ga(6,"form",5),ga(7,"mat-form-field",6),ga(8,"input",7),xa("ngModelChange",(function(t){return e.node.name=t})),va(),va(),va(),va(),va(),va(),va(),ga(9,"div",8),ga(10,"button",9),xa("click",(function(){return e.onCancelClick()})),ds(11,"Cancel"),va(),ga(12,"button",10),xa("click",(function(){return e.onSaveClick()})),ds(13,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("formGroup",e.generalSettingsForm),Qi(2),pa("ngModel",e.node.name))},directives:[r1,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a1,a2],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),z8=function(){function t(t,e,n,i){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.generalSettingsForm=this.formBuilder.group({name:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=e.name}))},t.prototype.onSaveClick=function(){var t=this;this.generalSettingsForm.valid?this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()})):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-configurator-traceng"]],decls:14,vars:3,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ga(6,"form",5),ga(7,"mat-form-field",6),ga(8,"input",7),xa("ngModelChange",(function(t){return e.node.name=t})),va(),va(),va(),va(),va(),va(),va(),ga(9,"div",8),ga(10,"button",9),xa("click",(function(){return e.onCancelClick()})),ds(11,"Cancel"),va(),ga(12,"button",10),xa("click",(function(){return e.onSaveClick()})),ds(13,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configurator for node ",e.name,""),Qi(5),pa("formGroup",e.generalSettingsForm),Qi(2),pa("ngModel",e.node.name))},directives:[r1,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a1,a2],styles:[".configButton[_ngcontent-%COMP%], .form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.default-content[_ngcontent-%COMP%]{max-height:400px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.file-button[_ngcontent-%COMP%]{width:18%}.create-button[_ngcontent-%COMP%]{width:100%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}.nonvisible[_ngcontent-%COMP%]{display:none}mat-radio-button[_ngcontent-%COMP%]{margin-right:10px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),V8=function(){function t(t){this.dialog=t,this.conf={autoFocus:!1,width:"800px",disableClose:!0}}return t.prototype.configureNode=function(){"vpcs"===this.node.node_type?this.dialogRef=this.dialog.open(q5,this.conf):"ethernet_hub"===this.node.node_type?this.dialogRef=this.dialog.open(W5,this.conf):"ethernet_switch"===this.node.node_type?this.dialogRef=this.dialog.open(G4,this.conf):"cloud"===this.node.node_type?this.dialogRef=this.dialog.open(A7,this.conf):"dynamips"===this.node.node_type?this.dialogRef=this.dialog.open(n8,this.conf):"iou"===this.node.node_type?this.dialogRef=this.dialog.open($7,this.conf):"qemu"===this.node.node_type?this.dialogRef=this.dialog.open(c7,this.conf):"virtualbox"===this.node.node_type?this.dialogRef=this.dialog.open(_6,this.conf):"vmware"===this.node.node_type?this.dialogRef=this.dialog.open(X7,this.conf):"docker"===this.node.node_type?this.dialogRef=this.dialog.open(B8,this.conf):"nat"===this.node.node_type?this.dialogRef=this.dialog.open(H8,this.conf):"frame_relay_switch"===this.node.node_type?this.dialogRef=this.dialog.open(e6,this.conf):"atm_switch"===this.node.node_type?this.dialogRef=this.dialog.open(z7,this.conf):"traceng"===this.node.node_type&&(this.dialogRef=this.dialog.open(z8,this.conf));var t=this.dialogRef.componentInstance;t.server=this.server,t.node=this.node},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-config-node-action"]],inputs:{server:"server",node:"node"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.configureNode()})),ga(1,"mat-icon"),ds(2,"settings_applications"),va(),ga(3,"span"),ds(4,"Configure"),va(),va())},directives:[E0,x2],encapsulation:2}),t}();function U8(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().startNodes()})),ga(1,"mat-icon"),ds(2,"play_arrow"),va(),ga(3,"span"),ds(4,"Start"),va(),va()}}var q8=function(){function t(t,e){this.nodeService=t,this.toasterService=e}return t.prototype.ngOnInit=function(){},t.prototype.ngOnChanges=function(t){var e=this;t.nodes&&(this.isNodeWithStoppedStatus=!1,this.nodes.forEach((function(t){"stopped"!==t.status&&"suspended"!==t.status||(e.isNodeWithStoppedStatus=!0)})))},t.prototype.startNodes=function(){var t=this;this.nodes.forEach((function(e){t.nodeService.start(t.server,e).subscribe((function(t){}),(function(e){t.toasterService.error(e.error.message)}))}))},t.\u0275fac=function(e){return new(e||t)(da(E2),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-start-node-action"]],inputs:{server:"server",nodes:"nodes"},features:[Ms],decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,U8,5,0,"button",0),2&t&&pa("ngIf",e.isNodeWithStoppedStatus)},directives:[Ah,E0,x2],encapsulation:2}),t}();function G8(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().suspendNodes()})),ga(1,"mat-icon"),ds(2,"pause"),va(),ga(3,"span"),ds(4,"Suspend"),va(),va()}}var W8=function(){function t(t){this.nodeService=t}return t.prototype.ngOnInit=function(){},t.prototype.ngOnChanges=function(t){var e=this;t.nodes&&(this.isNodeWithStartedStatus=!1,this.nodes.forEach((function(t){"started"===t.status&&(e.isNodeWithStartedStatus=!0)})))},t.prototype.suspendNodes=function(){var t=this;this.nodes.forEach((function(e){t.nodeService.suspend(t.server,e).subscribe((function(t){}))}))},t.\u0275fac=function(e){return new(e||t)(da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-suspend-node-action"]],inputs:{server:"server",nodes:"nodes"},features:[Ms],decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,G8,5,0,"button",0),2&t&&pa("ngIf",e.isNodeWithStartedStatus)},directives:[Ah,E0,x2],encapsulation:2}),t}();function K8(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().stopNodes()})),ga(1,"mat-icon"),ds(2,"stop"),va(),ga(3,"span"),ds(4,"Stop"),va(),va()}}var X8=function(){function t(t){this.nodeService=t}return t.prototype.ngOnInit=function(){},t.prototype.ngOnChanges=function(t){var e=this;t.nodes&&(this.isNodeWithStartedStatus=!1,this.nodes.forEach((function(t){"started"===t.status&&(e.isNodeWithStartedStatus=!0)})))},t.prototype.stopNodes=function(){var t=this;this.nodes.forEach((function(e){t.nodeService.stop(t.server,e).subscribe((function(t){}))}))},t.\u0275fac=function(e){return new(e||t)(da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-stop-node-action"]],inputs:{server:"server",nodes:"nodes"},features:[Ms],decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,K8,5,0,"button",0),2&t&&pa("ngIf",e.isNodeWithStartedStatus)},directives:[Ah,E0,x2],encapsulation:2}),t}();function Y8(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().reloadNodes()})),ga(1,"mat-icon"),ds(2,"refresh"),va(),ga(3,"span"),ds(4,"Reload"),va(),va()}}var Z8=function(){function t(t){this.nodeService=t,this.filteredNodes=[]}return t.prototype.ngOnInit=function(){var t=this;this.nodes.forEach((function(e){"vpcs"!==e.node_type&&"qemu"!==e.node_type&&"virtualbox"!==e.node_type&&"vmware"!==e.node_type||t.filteredNodes.push(e)}))},t.prototype.reloadNodes=function(){var t=this;this.filteredNodes.forEach((function(e){t.nodeService.reload(t.server,e).subscribe((function(t){}))}))},t.\u0275fac=function(e){return new(e||t)(da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-reload-node-action"]],inputs:{server:"server",nodes:"nodes"},decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,Y8,5,0,"button",0),2&t&&pa("ngIf",e.filteredNodes.length>0)},directives:[Ah,E0,x2],encapsulation:2}),t}(),Q8=function(){function t(){this.nodeConsoleTrigger=new Uc,this.closeNodeConsoleTrigger=new w.b,this.consoleResized=new w.b,this.openConsoles=0,this.defaultConsoleWidth=720,this.defaultConsoleHeight=408,this.defaultNumberOfColumns=80,this.defaultNumberOfRows=24}return t.prototype.getNumberOfColumns=function(){return this.lastNumberOfColumns},t.prototype.getNumberOfRows=function(){return this.lastNumberOfRows},t.prototype.setNumberOfColumns=function(t){this.lastNumberOfColumns=t},t.prototype.setNumberOfRows=function(t){this.lastNumberOfRows=t},t.prototype.openConsoleForNode=function(t){this.nodeConsoleTrigger.emit(t)},t.prototype.closeConsoleForNode=function(t){this.closeNodeConsoleTrigger.next(t)},t.prototype.resizeTerminal=function(t){this.consoleResized.next(t)},t.prototype.getLineWidth=function(){return this.defaultConsoleWidth/this.defaultNumberOfColumns},t.prototype.getLineHeight=function(){return this.defaultConsoleHeight/this.defaultNumberOfRows},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),$8=function(){function t(){this.isMapLocked=new w.b,this.isTopologySummaryVisible=!0,this.isLogConsoleVisible=!1,this.isLayerNumberVisible=!1,this.logConsoleSubject=new w.b,this.mapRenderedEmitter=new Uc,this.showInterfaceLabels=!0,this.integrateLinkLabelsToLinks=!0,this.isLayerNumberVisible="true"===localStorage.getItem("layersVisibility"),localStorage.getItem("integrateLinkLabelsToLinks")&&(this.integrateLinkLabelsToLinks="true"===localStorage.getItem("integrateLinkLabelsToLinks"))}return t.prototype.changeMapLockValue=function(t){this.isMapLocked.next(t)},t.prototype.toggleTopologySummary=function(t){this.isTopologySummaryVisible=t},t.prototype.toggleLogConsole=function(t){this.isLogConsoleVisible=t},t.prototype.toggleLayers=function(t){this.isLayerNumberVisible=t},t.prototype.toggleShowInterfaceLabels=function(t){this.showInterfaceLabels=t},t.prototype.toggleIntegrateInterfaceLabels=function(t){this.integrateLinkLabelsToLinks=t,localStorage.removeItem("integrateLinkLabelsToLinks"),t?localStorage.setItem("integrateLinkLabelsToLinks","true"):localStorage.setItem("integrateLinkLabelsToLinks","false")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),J8=function(){function t(t,e,n){this.consoleService=t,this.toasterService=e,this.mapSettingsService=n}return t.prototype.ngOnInit=function(){},t.prototype.openConsole=function(){var t=this;this.nodes.forEach((function(e){"started"===e.status?(t.mapSettingsService.logConsoleSubject.next(!0),t.consoleService.openConsoleForNode(e)):t.toasterService.error("To open console please start the node")}))},t.\u0275fac=function(e){return new(e||t)(da(Q8),da(Y2),da($8))},t.\u0275cmp=Ht({type:t,selectors:[["app-http-console-action"]],inputs:{server:"server",nodes:"nodes"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.openConsole()})),ga(1,"mat-icon"),ds(2,"http"),va(),ga(3,"span"),ds(4,"Web console"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),t9=function(){function t(t,e){this.toasterService=t,this.router=e}return t.prototype.ngOnInit=function(){},t.prototype.openConsole=function(){var t=this;this.nodes.forEach((function(e){if("started"===e.status){var n=t.router.url.split("/");window.open("/static/web-ui/"+n[1]+"/"+n[2]+"/"+n[3]+"/"+n[4]+"/nodes/"+e.node_id)}else t.toasterService.error("To open console please start the node")}))},t.\u0275fac=function(e){return new(e||t)(da(Y2),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-http-console-new-tab-action"]],inputs:{server:"server",nodes:"nodes"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.openConsole()})),ga(1,"mat-icon"),ds(2,"http"),va(),ga(3,"span"),ds(4,"Web console in new tab"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),e9=function(){function t(t,e,n,i,r){this.electronService=t,this.serverService=e,this.settingsService=n,this.toasterService=i,this.nodeService=r}return t.prototype.ngOnInit=function(){},t.prototype.console=function(){return UQ(this,void 0,void 0,(function(){var t,e,n,i,r;return qQ(this,(function(o){switch(o.label){case 0:if(t=this.settingsService.get("console_command")?this.settingsService.get("console_command"):this.nodeService.getDefaultCommand(),0===this.nodes.filter((function(t){return"started"===t.status})).length)return this.toasterService.error("Device needs to be started in order to console to it."),[2];e=0,n=this.nodes,o.label=1;case 1:return e<n.length?"started"!==(i=n[e]).status?[3,3]:(r={command:t,type:i.console_type,host:i.console_host,port:i.console,name:i.name,project_id:i.project_id,node_id:i.node_id,server_url:this.serverService.getServerUrl(this.server)},[4,this.openConsole(r)]):[3,4];case 2:o.sent(),o.label=3;case 3:return e++,[3,1];case 4:return[2]}}))}))},t.prototype.openConsole=function(t){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(e){switch(e.label){case 0:return[4,this.electronService.remote.require("./console-executor.js").openConsole(t)];case 1:return[2,e.sent()]}}))}))},t.\u0275fac=function(e){return new(e||t)(da(mX),da(ZQ),da(QQ),da(Y2),da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-console-device-action"]],inputs:{server:"server",nodes:"nodes"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.console()})),ga(1,"mat-icon"),ds(2,"web_asset"),va(),ga(3,"span"),ds(4,"Console"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),n9=function(){function t(t,e){this.toasterService=t,this.nodeService=e}return t.prototype.openConsole=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.startConsole()}))},t.prototype.startConsole=function(){"started"!==this.node.status?this.toasterService.error("This node must be started before a console can be opened"):("0.0.0.0"!==this.node.console_host&&"0:0:0:0:0:0:0:0"!==this.node.console_host&&"::"!==this.node.console_host||(this.node.console_host=this.server.host),"telnet"===this.node.console_type?location.assign("gns3+telnet://"+this.node.console_host+":"+this.node.console+"?name="+this.node.name+"&project_id="+this.node.project_id+"&node_id="+this.node.node_id):"vnc"===this.node.console_type?location.assign("gns3+vnc://"+this.node.console_host+":"+this.node.console+"?name="+this.node.name+"&project_id="+this.node.project_id+"&node_id="+this.node.node_id):"spice"===this.node.console_type?location.assign("gns3+spice://"+this.node.console_host+":"+this.node.console+"?name="+this.node.name+"&project_id="+this.node.project_id+"&node_id="+this.node.node_id):this.toasterService.error("Supported console types: telnet, vnc, spice."))},t.\u0275fac=function(e){return new(e||t)(da(Y2),da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-console-device-action-browser"]],inputs:{server:"server",node:"node"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.openConsole()})),ga(1,"mat-icon"),ds(2,"web_asset"),va(),ga(3,"span"),ds(4,"Console"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),i9=function(){function t(t){this.electronService=t}return t.prototype.ngOnInit=function(){},t.prototype.open=function(){this.electronService.shell.openPath(this.node.node_directory)},t.\u0275fac=function(e){return new(e||t)(da(mX))},t.\u0275cmp=Ht({type:t,selectors:[["app-open-file-explorer-action"]],inputs:{server:"server",node:"node"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.open()})),ga(1,"mat-icon"),ds(2,"tab"),va(),ga(3,"span"),ds(4,"Open file explorer"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),r9=function(){function t(t,e,n,i){this.dialogRef=t,this.nodeService=e,this.toasterService=n,this.formBuilder=i,this.inputForm=this.formBuilder.group({name:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getNode(this.server,this.node).subscribe((function(e){t.node=e,t.name=t.node.name}))},t.prototype.onSaveClick=function(){var t=this;this.inputForm.valid?this.nodeService.updateNode(this.server,this.node).subscribe((function(){t.toasterService.success("Node "+t.node.name+" updated."),t.onCancelClick()})):this.toasterService.error("Fill all required fields.")},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-change-hostname-dialog-component"]],decls:14,vars:3,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"content"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","name","placeholder","Name",3,"ngModel","ngModelChange"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div",3),ga(5,"mat-card",4),ga(6,"form",5),ga(7,"mat-form-field",6),ga(8,"input",7),xa("ngModelChange",(function(t){return e.node.name=t})),va(),va(),va(),va(),va(),va(),va(),ga(9,"div",8),ga(10,"button",9),xa("click",(function(){return e.onCancelClick()})),ds(11,"Cancel"),va(),ga(12,"button",10),xa("click",(function(){return e.onSaveClick()})),ds(13,"Apply"),va(),va()),2&t&&(Qi(1),ps("Change hostname for node ",e.name,""),Qi(5),pa("formGroup",e.inputForm),Qi(2),pa("ngModel",e.node.name))},directives:[r1,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a1,a2],styles:[".form-field[_ngcontent-%COMP%]{width:100%}"]}),t}(),o9=function(){function t(t){this.dialog=t}return t.prototype.ngOnInit=function(){},t.prototype.changeHostname=function(){var t=this.dialog.open(r9,{autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.node=this.node},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-change-hostname-action"]],inputs:{server:"server",node:"node"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.changeHostname()})),ga(1,"mat-icon"),ds(2,"edit"),va(),ga(3,"span"),ds(4,"Change hostname"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),a9=function(){function t(t){this.httpServer=t,this.symbols=new Pm.a([])}return t.prototype.get=function(t){return this.symbols.getValue().find((function(e){return e.symbol_id===t}))},t.prototype.getByFilename=function(t){return this.symbols.getValue().find((function(e){return e.filename===t}))},t.prototype.add=function(t,e,n){return this.cache=null,this.httpServer.post(t,"/symbols/"+e+"/raw",n)},t.prototype.load=function(t){return this.httpServer.get(t,"/symbols")},t.prototype.list=function(t){return this.cache||(this.cache=this.load(t).pipe(Object(NJ.a)(1))),this.cache},t.prototype.raw=function(t,e){var n=encodeURI(e);return this.httpServer.getText(t,"/symbols/"+n+"/raw")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),s9=function(){function t(){}return t.prototype.transform=function(t,e){return t?e?(e=e.toLowerCase(),t.filter((function(t){return t.filename.toLowerCase().includes(e)}))):t:[]},t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"filenamefilter",type:t,pure:!0}),t}(),c9=function(t){return{buttonSelected:t}},l9=function(t){return{imageSelected:t}};function u9(t,e){if(1&t){var n=ka();ga(0,"div",12),ga(1,"button",13),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().setSelected(t.symbol_id)})),ba(2,"img",14),va(),va()}if(2&t){var i=e.$implicit,r=Aa();Qi(1),pa("ngClass",Ic(3,c9,r.isSelected===i.symbol_id)),Qi(1),pa("ngClass",Ic(5,l9,r.isSelected===i.symbol_id))("src",r.getImageSourceForTemplate(i.symbol_id),Pi)}}var h9=function(){return{standalone:!0}},d9=function(){function t(t){this.symbolService=t,this.symbolChanged=new Uc,this.symbols=[],this.filteredSymbols=[],this.isSelected="",this.searchText=""}return t.prototype.ngOnInit=function(){this.isSelected=this.symbol,this.loadSymbols()},t.prototype.setFilter=function(t){this.filteredSymbols="all"===t?this.symbols:this.symbols.filter("builtin"===t?function(t){return t.builtin}:function(t){return!t.builtin})},t.prototype.setSelected=function(t){this.isSelected=t,this.symbolChanged.emit(this.isSelected)},t.prototype.loadSymbols=function(){var t=this;this.symbolService.list(this.server).subscribe((function(e){t.symbols=e,t.filteredSymbols=e}))},t.prototype.uploadSymbolFile=function(t){this.readSymbolFile(t.target)},t.prototype.readSymbolFile=function(t){var e=this,n=t.files[0],i=t.files[0].name,r=new FileReader,o=new Image;r.onloadend=function(){var t=e.createSvgFileForImage(r.result,o);e.symbolService.add(e.server,i,t).subscribe((function(){e.loadSymbols()}))},o.onload=function(){r.readAsDataURL(n)},o.src=window.URL.createObjectURL(n)},t.prototype.createSvgFileForImage=function(t,e){return'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="'+e.height+'" \n width="'+e.width+'">\n<image height="'+e.height+'" width="'+e.width+'" xlink:href="'+t+'"/>\n</svg>'},t.prototype.getImageSourceForTemplate=function(t){return"http://"+this.server.host+":"+this.server.port+"/v2/symbols/"+t+"/raw"},t.\u0275fac=function(e){return new(e||t)(da(a9))},t.\u0275cmp=Ht({type:t,selectors:[["app-symbols"]],inputs:{server:"server",symbol:"symbol"},outputs:{symbolChanged:"symbolChanged"},decls:20,vars:7,consts:[[1,"menu"],["aria-label","Select an option",1,"radio-selection"],["value","1","checked","",3,"click"],["value","2",3,"click"],["value","3",3,"click"],["type","file","accept",".svg, .bmp, .jpeg, .jpg, .gif, .png",1,"non-visible",3,"change"],["file",""],["mat-button","",3,"click"],[1,"example-full-width"],["matInput","","placeholder","Search by filename",3,"ngModel","ngModelOptions","ngModelChange"],[1,"wrapper"],["class","buttonWrapper",4,"ngFor","ngForOf"],[1,"buttonWrapper"],[1,"button",3,"ngClass","click"],[1,"image",3,"ngClass","src"]],template:function(t,e){if(1&t){var n=ka();ga(0,"div",0),ga(1,"mat-radio-group",1),ga(2,"mat-radio-button",2),xa("click",(function(){return e.setFilter("all")})),ds(3,"All symbols"),va(),ga(4,"mat-radio-button",3),xa("click",(function(){return e.setFilter("builtin")})),ds(5,"Built-in symbols"),va(),ga(6,"mat-radio-button",4),xa("click",(function(){return e.setFilter("custom")})),ds(7,"Custom symbols"),va(),va(),ga(8,"input",5,6),xa("change",(function(t){return e.uploadSymbolFile(t)})),va(),ga(10,"button",7),xa("click",(function(){return Se(n),ha(9).click()})),ga(11,"mat-icon"),ds(12,"add"),va(),ds(13," Add symbol "),va(),va(),ga(14,"form"),ga(15,"mat-form-field",8),ga(16,"input",9),xa("ngModelChange",(function(t){return e.searchText=t})),va(),va(),va(),ga(17,"div",10),ua(18,u9,3,7,"div",11),Nc(19,"filenamefilter"),va()}2&t&&(Qi(16),pa("ngModel",e.searchText)("ngModelOptions",jc(6,h9)),Qi(2),pa("ngForOf",Hc(19,3,e.filteredSymbols,e.searchText)))},directives:[A6,D6,a2,x2,xp,gf,gp,Y3,s5,cf,mf,Sp,Eh,Oh],pipes:[s9],styles:[".buttonWrapper[_ngcontent-%COMP%]{width:85px;height:85px;display:flex;align-items:center;margin-left:auto;margin-right:auto;outline:none}.menu[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.button[_ngcontent-%COMP%]{background:border-box;border-width:0;outline:none}.buttonSelected[_ngcontent-%COMP%]{border-width:3px;border-color:#0097a7;width:77px}.image[_ngcontent-%COMP%]{width:65px;height:65px;-webkit-filter:invert(0);filter:invert(0);--webkit-filter:invert(0)!important}.imageSelected[_ngcontent-%COMP%]{margin-left:-3px}.wrapper[_ngcontent-%COMP%]{display:grid;grid-template-rows:auto;grid-template-columns:repeat(7,1fr);grid-row-gap:3em;grid-column-gap:1em}.radio-selection[_ngcontent-%COMP%]{width:90%}.mat-radio-button[_ngcontent-%COMP%] ~ .mat-radio-button[_ngcontent-%COMP%]{margin-left:16px}.non-visible[_ngcontent-%COMP%]{display:none}.example-full-width[_ngcontent-%COMP%]{width:100%}"]}),t}(),f9=function(){function t(t,e){this.dialogRef=t,this.nodeService=e}return t.prototype.ngOnInit=function(){this.symbol=this.node.symbol},t.prototype.symbolChanged=function(t){this.symbol=t},t.prototype.onCloseClick=function(){this.dialogRef.close()},t.prototype.onSelectClick=function(){var t=this;this.nodeService.updateSymbol(this.server,this.node,this.symbol).subscribe((function(){t.onCloseClick()}))},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-change-symbol-dialog"]],inputs:{server:"server",node:"node"},decls:10,vars:3,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"symbolsWrapper"],[3,"server","symbol","symbolChanged"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"app-symbols",3),xa("symbolChanged",(function(t){return e.symbolChanged(t)})),va(),va(),va(),ga(5,"div",4),ga(6,"button",5),xa("click",(function(){return e.onCloseClick()})),ds(7,"Cancel"),va(),ga(8,"button",6),xa("click",(function(){return e.onSelectClick()})),ds(9,"Apply"),va(),va()),2&t&&(Qi(1),ps("Change symbol for node: ",e.node.name,""),Qi(3),pa("server",e.server)("symbol",e.symbol))},directives:[r1,d9,a1,a2],styles:[".symbolsWrapper[_ngcontent-%COMP%]{height:350px;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}"]}),t}(),p9=function(){function t(t){this.dialog=t}return t.prototype.ngOnInit=function(){},t.prototype.changeSymbol=function(){var t=this.dialog.open(f9,{width:"1000px",height:"500px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.node=this.node},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-change-symbol-action"]],inputs:{server:"server",node:"node"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.changeSymbol()})),ga(1,"mat-icon"),ds(2,"find_replace"),va(),ga(3,"span"),ds(4,"Change symbol"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),m9=function(){function t(){}return t.prototype.convert=function(t){var e=new z0;e.text=t.textContent;var n=t.attributes.getNamedItem("fill");n&&(e.fill=n.value);var i=t.attributes.getNamedItem("fill-opacity");i&&(e.fill_opacity=parseFloat(i.value));var r=t.attributes.getNamedItem("font-family");r&&(e.font_family=r.value);var o=t.attributes.getNamedItem("font-size");o&&(e.font_size=+o.value);var a=t.attributes.getNamedItem("font-weight");a&&(e.font_weight=a.value);var s=t.attributes.getNamedItem("text-decoration");return s&&(e.text_decoration=s.value),e},t}(),g9=function(){return function(){}}(),v9=function(){function t(){}return t.prototype.convert=function(t){var e=new g9,n=t.attributes.getNamedItem("xlink:href");n&&(e.data=n.value);var i=t.attributes.getNamedItem("width");i&&(e.width=parseInt(i.value,10));var r=t.attributes.getNamedItem("height");return r&&(e.height=parseInt(r.value,10)),e},t}(),b9=function(){return function(){}}(),y9=function(){function t(){}return t.prototype.convert=function(t){var e=new b9,n=t.attributes.getNamedItem("fill");n&&(e.fill=n.value);var i=t.attributes.getNamedItem("fill-opacity");n&&(e.fill_opacity=parseFloat(i.value));var r=t.attributes.getNamedItem("stroke");r&&(e.stroke=r.value);var o=t.attributes.getNamedItem("stroke-width");r&&(e.stroke_width=parseInt(o.value,10));var a=t.attributes.getNamedItem("stroke-dasharray");a&&(e.stroke_dasharray=a.value);var s=t.attributes.getNamedItem("width");s&&(e.width=parseInt(s.value,10));var c=t.attributes.getNamedItem("height");return c&&(e.height=parseInt(c.value,10)),e},t}(),_9=function(){return function(){}}(),w9=function(){function t(){}return t.prototype.convert=function(t){var e=new _9,n=t.attributes.getNamedItem("stroke");n&&(e.stroke=n.value);var i=t.attributes.getNamedItem("stroke-width");n&&(e.stroke_width=parseInt(i.value,10));var r=t.attributes.getNamedItem("stroke-dasharray");r&&(e.stroke_dasharray=r.value);var o=t.attributes.getNamedItem("x1");o&&(e.x1=parseInt(o.value,10));var a=t.attributes.getNamedItem("x2");a&&(e.x2=parseInt(a.value,10));var s=t.attributes.getNamedItem("y1");s&&(e.y1=parseInt(s.value,10));var c=t.attributes.getNamedItem("y2");return c&&(e.y2=parseInt(c.value,10)),e},t}(),k9=function(){return function(){}}(),C9=function(){function t(){}return t.prototype.convert=function(t){var e=new k9,n=t.attributes.getNamedItem("fill");n&&(e.fill=n.value);var i=t.attributes.getNamedItem("fill-opacity");n&&(e.fill_opacity=parseFloat(i.value));var r=t.attributes.getNamedItem("stroke");r&&(e.stroke=r.value);var o=t.attributes.getNamedItem("stroke-width");r&&(e.stroke_width=parseInt(o.value,10));var a=t.attributes.getNamedItem("stroke-dasharray");a&&(e.stroke_dasharray=a.value);var s=t.attributes.getNamedItem("cx");s&&(e.cx=parseInt(s.value,10));var c=t.attributes.getNamedItem("cy");c&&(e.cy=parseInt(c.value,10));var l=t.attributes.getNamedItem("rx");l&&(e.rx=parseInt(l.value,10));var u=t.attributes.getNamedItem("ry");return u&&(e.ry=parseInt(u.value,10)),e},t}(),S9=function(){function t(){this.parser=new DOMParser,this.elementParsers={text:new m9,image:new v9,rect:new y9,line:new w9,ellipse:new C9}}return t.prototype.supportedTags=function(){return Object.keys(this.elementParsers)},t.prototype.convert=function(t){var e=this.parser.parseFromString(t,"text/xml").getElementsByTagName("svg");if(1!==e.length)throw new Error("Cannot locate svg element root in '"+t+"'");var n=e[0],i=null,r=null;for(var o in n.children){var a=(r=n.children[o]).nodeName;if(a in this.elementParsers){i=this.elementParsers[a];break}}if(null===i)throw new Error("Cannot find parser for '"+t+"'");var s=i.convert(r);return s.width=+n.getAttribute("width"),s.height=+n.getAttribute("height"),s},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),x9=function(){function t(t,e){this.httpServer=t,this.svgToDrawingConverter=e}return t.prototype.add=function(t,e,n,i,r){return this.httpServer.post(t,"/projects/"+e+"/drawings",{svg:r,x:Math.round(n),y:Math.round(i),z:1})},t.prototype.duplicate=function(t,e,n){return this.httpServer.post(t,"/projects/"+e+"/drawings",{svg:n.svg,rotation:n.rotation,x:n.x+10,y:n.y+10,z:n.z})},t.prototype.updatePosition=function(t,e,n,i,r){var o=Math.round(i),a=Math.round(r);return e.snap_to_grid&&(n.element=this.svgToDrawingConverter.convert(n.svg),o=Math.round((o+n.element.width/2)/e.drawing_grid_size)*e.drawing_grid_size,a=Math.round((a+n.element.width/2)/e.drawing_grid_size)*e.drawing_grid_size,o=Math.round(o-n.element.width/2),a=Math.round(a-n.element.height/2)),this.httpServer.put(t,"/projects/"+n.project_id+"/drawings/"+n.drawing_id,{x:o,y:a})},t.prototype.updateSizeAndPosition=function(t,e,n,i,r){return this.httpServer.put(t,"/projects/"+e.project_id+"/drawings/"+e.drawing_id,{svg:r,x:Math.round(n),y:Math.round(i)})},t.prototype.updateText=function(t,e,n){return this.httpServer.put(t,"/projects/"+e.project_id+"/drawings/"+e.drawing_id,{svg:n,x:Math.round(e.x),y:Math.round(e.y),z:e.z})},t.prototype.update=function(t,e){return this.httpServer.put(t,"/projects/"+e.project_id+"/drawings/"+e.drawing_id,{locked:e.locked,svg:e.svg,rotation:e.rotation,x:Math.round(e.x),y:Math.round(e.y),z:e.z})},t.prototype.delete=function(t,e){return this.httpServer.delete(t,"/projects/"+e.project_id+"/drawings/"+e.drawing_id)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ),_t(S9))}}),t}(),O9=function(){function t(){this.data=[],this.dataChange=new Pm.a([]),this.itemUpdated=new w.b}return t.prototype.getItems=function(){return this.data},t.prototype.add=function(t){this.findIndex(t)>=0?this.update(t):(this.data.push(t),this.dataChange.next(this.data))},t.prototype.set=function(t){var e=this;t.forEach((function(t){var n=e.findIndex(t);if(n>=0){var i=Object.assign(e.data[n],t);e.data[n]=i}else e.data.push(t)})),this.data.filter((function(n){return 0===t.filter((function(t){return e.getItemKey(t)===e.getItemKey(n)})).length})).forEach((function(t){return e.remove(t)})),this.dataChange.next(this.data)},t.prototype.get=function(t){var e=this,n=this.data.findIndex((function(n){return e.getItemKey(n)===t}));if(n>=0)return this.data[n]},t.prototype.update=function(t){var e=this.findIndex(t);if(e>=0){var n=Object.assign(this.data[e],t);this.data[e]=n,this.dataChange.next(this.data),this.itemUpdated.next(n)}},t.prototype.remove=function(t){var e=this.findIndex(t);e>=0&&(this.data.splice(e,1),this.dataChange.next(this.data))},Object.defineProperty(t.prototype,"changes",{get:function(){return this.dataChange},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemChanged",{get:function(){return this.itemUpdated},enumerable:!1,configurable:!0}),t.prototype.clear=function(){this.data=[],this.dataChange.next(this.data)},t.prototype.findIndex=function(t){var e=this;return this.data.findIndex((function(n){return e.getItemKey(n)===e.getItemKey(t)}))},t}(),M9=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.prototype.getItemKey=function(t){return t.node_id},e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return T9(t||e)}}),e}(O9),T9=zn(M9),E9=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.prototype.getItemKey=function(t){return t.drawing_id},e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return P9(t||e)}}),e}(O9),P9=zn(E9),A9=function(){function t(t,e,n,i,r){this.nodeService=t,this.nodesDataSource=e,this.drawingService=n,this.drawingsDataSource=i,this.toasterService=r}return t.prototype.duplicate=function(){for(var t=this,e="",n=0,i=this.nodes;n<i.length;n++){var r=i[n];"stopped"===r.status?this.nodeService.duplicate(this.server,r).subscribe((function(e){t.nodesDataSource.add(e)})):e+=r.name+", "}for(var o=0,a=this.drawings;o<a.length;o++){var s=a[o];this.drawingService.duplicate(this.server,s.project_id,s).subscribe((function(e){t.drawingsDataSource.add(e)}))}e.length>0&&(e=e.substring(0,e.length-2),this.toasterService.error("Cannot duplicate node data for nodes: "+e))},t.\u0275fac=function(e){return new(e||t)(da(E2),da(M9),da(x9),da(E9),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-duplicate-action"]],inputs:{server:"server",project:"project",drawings:"drawings",nodes:"nodes"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.duplicate()})),ga(1,"mat-icon"),ds(2,"filter_none"),va(),ga(3,"span"),ds(4,"Duplicate"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),j9=function(){return function(){}}(),I9=function(){return function(){}}(),D9=function(){function t(){}return t.prototype.convert=function(t){var e=new I9;return e.id=t.drawing_id,e.projectId=t.project_id,e.rotation=t.rotation,e.svg=t.svg,e.locked=t.locked,e.x=t.x,e.y=t.y,e.z=t.z,e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),R9=function(){function t(){}return t.prototype.convert=function(t){var e="";if(t.element instanceof b9)e='<rect fill="'+t.element.fill+'" fill-opacity="'+t.element.fill_opacity+'" height="'+t.element.height+'" width="'+t.element.width+'" stroke="'+t.element.stroke+'" stroke-width="'+t.element.stroke_width+'" />';else if(t.element instanceof k9)e='<ellipse fill="'+t.element.fill+'" fill-opacity="'+t.element.fill_opacity+'" cx="'+t.element.cx+'" cy="'+t.element.cy+'" rx="'+t.element.rx+'" ry="'+t.element.ry+'" stroke="'+t.element.stroke+'" stroke-width="'+t.element.stroke_width+'" />';else if(t.element instanceof _9)e='<line stroke="'+t.element.stroke+'" stroke-width="'+t.element.stroke_width+'" x1="'+t.element.x1+'" x2="'+t.element.x2+'" y1="'+t.element.y1+'" y2="'+t.element.y2+'" />';else{if(!(t.element instanceof z0))return"";e='<text fill="'+t.element.fill+'" fill-opacity="1.0" font-family="'+t.element.font_family+'" font-size="'+t.element.font_size+'" font-weight="'+t.element.font_weight+'">'+t.element.text+"</text>"}return'<svg height="'+t.element.height+'" width="'+t.element.width+'">'+e+"</svg>"},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),L9=function(){function t(){}return t.prototype.get=function(t){return+t.value>=0?null:{negativeValue:!0}},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),F9=function(){function t(){}return t.prototype.get=function(t){return+t.value>-360&&+t.value<=360?null:{negativeValue:!0}},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),N9=function(){return{standalone:!0}};function B9(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",3),ga(1,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().element.stroke_dasharray=t})),va(),va()}if(2&t){var i=Aa();Qi(1),pa("ngModelOptions",jc(2,N9))("ngModel",i.element.stroke_dasharray)}}var H9=function(){function t(t,e,n,i,r,o,a,s,c){this.dialogRef=t,this.drawingToMapDrawingConverter=e,this.mapDrawingToSvgConverter=n,this.drawingService=i,this.drawingsDataSource=r,this.formBuilder=o,this.toasterService=a,this.nonNegativeValidator=s,this.rotationValidator=c,this.formGroup=this.formBuilder.group({borderWidth:new hp("",[kf.required,s.get]),rotation:new hp("",[kf.required,c.get])})}return t.prototype.ngOnInit=function(){this.element=new z9,this.drawing.element instanceof b9||this.drawing.element instanceof k9?(this.element.fill=this.drawing.element.fill,this.element.stroke=this.drawing.element.stroke,this.element.stroke_dasharray=this.drawing.element.stroke_dasharray,this.element.stroke_width=this.drawing.element.stroke_width):this.drawing.element instanceof _9&&(this.element.stroke=this.drawing.element.stroke,this.element.stroke_dasharray=this.drawing.element.stroke_dasharray,this.element.stroke_width=this.drawing.element.stroke_width),void 0===this.element.stroke_width&&(this.element.stroke_width=0),this.formGroup.controls.borderWidth.setValue(this.element.stroke_width),this.formGroup.controls.rotation.setValue(this.drawing.rotation)},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.onYesClick=function(){var t=this;if(this.formGroup.valid){this.element.stroke_width=this.formGroup.get("borderWidth").value,this.drawing.rotation=this.formGroup.get("rotation").value,this.drawing.element instanceof b9||this.drawing.element instanceof k9?(this.drawing.element.fill=this.element.fill,this.drawing.element.stroke=this.element.stroke,this.drawing.element.stroke_dasharray=this.element.stroke_dasharray,this.drawing.element.stroke_width=this.element.stroke_width):this.drawing.element instanceof _9&&(this.drawing.element.stroke=this.element.stroke,this.drawing.element.stroke_dasharray=this.element.stroke_dasharray,this.drawing.element.stroke_width=this.element.stroke_width);var e=this.drawingToMapDrawingConverter.convert(this.drawing);e.element=this.drawing.element,this.drawing.svg=this.mapDrawingToSvgConverter.convert(e),this.drawingService.update(this.server,this.drawing).subscribe((function(e){t.drawingsDataSource.update(e),t.dialogRef.close()}))}else this.toasterService.error("Entered data is incorrect")},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(D9),da(R9),da(x9),da(E9),da(Jp),da(Y2),da(L9),da(F9))},t.\u0275cmp=Ht({type:t,selectors:[["app-style-editor"]],decls:18,vars:8,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[3,"formGroup"],[1,"form-field"],["matInput","","placeholder","Fill color","type","color",3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","placeholder","Border color","type","color",3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","formControlName","borderWidth","placeholder","Border width","type","number"],["class","form-field",4,"ngIf"],["matInput","","formControlName","rotation","placeholder","Rotation","type","number"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["matInput","","placeholder","Border style","type","text",3,"ngModelOptions","ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Style editor"),va(),ga(2,"div",1),ga(3,"form",2),ga(4,"mat-form-field",3),ga(5,"input",4),xa("ngModelChange",(function(t){return e.element.fill=t})),va(),va(),ga(6,"mat-form-field",3),ga(7,"input",5),xa("ngModelChange",(function(t){return e.element.stroke=t})),va(),va(),ga(8,"mat-form-field",3),ba(9,"input",6),va(),ua(10,B9,2,3,"mat-form-field",7),ga(11,"mat-form-field",3),ba(12,"input",8),va(),va(),va(),ga(13,"div",9),ga(14,"button",10),xa("click",(function(){return e.onNoClick()})),ds(15,"Cancel"),va(),ga(16,"button",11),xa("click",(function(){return e.onYesClick()})),ds(17,"Apply"),va(),va()),2&t&&(Qi(3),pa("formGroup",e.formGroup),Qi(2),pa("ngModelOptions",jc(6,N9))("ngModel",e.element.fill),Qi(2),pa("ngModelOptions",jc(7,N9))("ngModel",e.element.stroke),Qi(3),pa("ngIf",e.element.stroke_dasharray))},directives:[r1,xp,gf,Pp,Y3,s5,cf,mf,Sp,Ef,Fp,Ah,a1,a2],styles:[".item[_ngcontent-%COMP%]{height:25px;font-size:10pt}.item[_ngcontent-%COMP%], .item-name[_ngcontent-%COMP%], .item-value[_ngcontent-%COMP%]{margin-bottom:10px}.item-value[_ngcontent-%COMP%]{width:100%}.input-color[_ngcontent-%COMP%]{padding:0;border-width:0;width:100%;background-color:transparent;outline:none}input[_ngcontent-%COMP%]:focus{outline:none}input[type=color][_ngcontent-%COMP%]{-webkit-appearance:none;border:none;height:25px}input[type=color][_ngcontent-%COMP%]::-webkit-color-swatch-wrapper{padding:0}input[type=color][_ngcontent-%COMP%]::-webkit-color-swatch{border:none}.modal-form-container[_ngcontent-%COMP%]{display:flex;flex-direction:column}.form-field[_ngcontent-%COMP%], .modal-form-container[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{width:100%}"]}),t}(),z9=function(){return function(){}}();function V9(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().editStyle()})),ga(1,"mat-icon"),ds(2,"style"),va(),ga(3,"span"),ds(4,"Edit style"),va(),va()}}var U9=function(){function t(t){this.dialog=t,this.isImageDrawing=!1}return t.prototype.ngOnChanges=function(){this.isImageDrawing=this.drawing.element instanceof g9},t.prototype.editStyle=function(){var t=this.dialog.open(H9,{width:"800px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.project=this.project,t.drawing=this.drawing},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-edit-style-action"]],inputs:{server:"server",project:"project",drawing:"drawing"},features:[Ms],decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,V9,5,0,"button",0),2&t&&pa("ngIf",!e.isImageDrawing)},directives:[Ah,E0,x2],encapsulation:2}),t}(),q9=function(){function t(t){this.httpServer=t}return t.prototype.createLink=function(t,e,n,i,r,o,a,s,c){return this.httpServer.post(t,"/projects/"+e.project_id+"/links",{nodes:[{node_id:e.node_id,port_number:n.port_number,adapter_number:n.adapter_number,label:{rotation:0,style:"font-size: 10; font-style: Verdana",text:n.short_name,x:o,y:a}},{node_id:i.node_id,port_number:r.port_number,adapter_number:r.adapter_number,label:{rotation:0,style:"font-size: 10; font-style: Verdana",text:r.short_name,x:s,y:c}}]})},t.prototype.getLink=function(t,e,n){return this.httpServer.get(t,"/projects/"+e+"/links/"+n)},t.prototype.deleteLink=function(t,e){return this.httpServer.delete(t,"/projects/"+e.project_id+"/links/"+e.link_id)},t.prototype.updateLink=function(t,e){return e.x=Math.round(e.x),e.y=Math.round(e.y),this.httpServer.put(t,"/projects/"+e.project_id+"/links/"+e.link_id,e)},t.prototype.getAvailableFilters=function(t,e){return this.httpServer.get(t,"/projects/"+e.project_id+"/links/"+e.link_id+"/available_filters")},t.prototype.updateNodes=function(t,e,n){var i=n.map((function(t){return{node_id:t.node_id,port_number:t.port_number,adapter_number:t.adapter_number,label:{rotation:t.label.rotation,style:t.label.style,text:t.label.text,x:t.label.x,y:t.label.y}}}));return this.httpServer.put(t,"/projects/"+e.project_id+"/links/"+e.link_id,{nodes:i})},t.prototype.startCaptureOnLink=function(t,e,n){return this.httpServer.post(t,"/projects/"+e.project_id+"/links/"+e.link_id+"/start_capture",n)},t.prototype.stopCaptureOnLink=function(t,e){return this.httpServer.post(t,"/projects/"+e.project_id+"/links/"+e.link_id+"/stop_capture",{})},t.prototype.streamPcap=function(t,e){return this.httpServer.get(t,"/projects/"+e.project_id+"/links/"+e.link_id+"/pcap")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),G9=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.prototype.getItemKey=function(t){return t.link_id},e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return W9(t||e)}}),e}(O9),W9=zn(G9),K9=n("zahk"),X9=function(){function t(){}return t.prototype.fix=function(e){return e.font_family===t.DEFAULT_FONT&&e.font_size===t.DEFAULT_SIZE&&(e.font_family=t.REPLACE_BY_FONT,e.font_size=t.REPLACE_BY_SIZE),e},t.prototype.fixStyles=function(t){var e=K9.parse(t,{context:"declarationList"}),n=null,i=null,r=!0;if(e.children.forEach((function(t){"font-family"===t.property&&t.value&&t.value.children&&t.value.children.forEach((function(t){"Identifier"===t.type&&(n=t),"String"===t.type&&(n=t,r=!1)})),"font-size"===t.property&&t.value&&t.value.children&&t.value.children.forEach((function(t){"Dimension"===t.type&&(i=t)}))})),i&&n){var o=i.value,a=this.fix({font_family:(r?n.name:n.value).split('"').join(""),font_size:parseInt(o,10)});r?n.name=a.font_family:n.value=a.font_family,i.value=a.font_size}return K9.generate(e)},t.DEFAULT_FONT="TypeWriter",t.DEFAULT_SIZE=10,t.REPLACE_BY_FONT="Noto Sans",t.REPLACE_BY_SIZE=11,t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Y9=["textArea"],Z9=function(){function t(t,e,n,i,r,o,a,s,c,l,u,h,d,f){this.dialogRef=t,this.drawingToMapDrawingConverter=e,this.mapDrawingToSvgConverter=n,this.drawingService=i,this.drawingsDataSource=r,this.renderer=o,this.nodeService=a,this.nodesDataSource=s,this.linkService=c,this.linksDataSource=l,this.formBuilder=u,this.toasterService=h,this.rotationValidator=d,this.fontFixer=f}return t.prototype.ngOnInit=function(){var t=this;this.formGroup=this.formBuilder.group({rotation:new hp("",[kf.required,this.rotationValidator.get])}),this.label&&this.node?(this.isTextEditable=!1,this.rotation=this.label.rotation.toString(),this.element=this.getTextElementFromLabel()):this.linkNode&&this.link?(this.isTextEditable=!0,this.label=this.link.nodes.find((function(e){return e.node_id===t.linkNode.node_id})).label,this.rotation=this.label.rotation.toString(),this.element=this.getTextElementFromLabel()):this.drawing&&(this.isTextEditable=!0,this.rotation=this.drawing.rotation.toString(),this.element=this.drawing.element);var e={font_family:this.element.font_family,font_size:this.element.font_size,font_weight:this.element.font_weight};e=this.fontFixer.fix(e),this.formGroup.controls.rotation.setValue(this.rotation),this.renderer.setStyle(this.textArea.nativeElement,"color",this.element.fill),this.renderer.setStyle(this.textArea.nativeElement,"font-family",e.font_family),this.renderer.setStyle(this.textArea.nativeElement,"font-size",e.font_size+"pt"),this.renderer.setStyle(this.textArea.nativeElement,"font-weight",e.font_weight)},t.prototype.getTextElementFromLabel=function(){for(var t=[],e=new z0,n=0,i=this.label.style.split(";");n<i.length;n++){var r=i[n];t.push({property:r.split(": ")[0],value:r.split(": ")[1]})}return e.text=this.label.text?this.label.text:"",e.font_family=t.find((function(t){return"font-family"===t.property}))?t.find((function(t){return"font-family"===t.property})).value:"TypeWriter",e.font_size=t.find((function(t){return"font-size"===t.property}))?+t.find((function(t){return"font-size"===t.property})).value:10,e.font_weight=t.find((function(t){return"font-weight"===t.property}))?t.find((function(t){return"font-weight"===t.property})).value:"normal",e.fill=t.find((function(t){return"fill"===t.property}))?t.find((function(t){return"fill"===t.property})).value:"#000000",e.fill_opacity=t.find((function(t){return"fill-opacity"===t.property}))?+t.find((function(t){return"fill-opacity"===t.property})).value:1,e},t.prototype.getStyleFromTextElement=function(){return"font-family: "+this.element.font_family+";font-size: "+this.element.font_size+";font-weight: "+this.element.font_weight+";fill: "+this.element.fill+";fill-opacity: "+this.element.fill_opacity+";"},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.onYesClick=function(){var t=this;if(this.formGroup.valid){if(this.rotation=this.formGroup.get("rotation").value,this.label&&this.node)this.node.label.style=this.getStyleFromTextElement(),this.node.label.rotation=+this.rotation,this.nodeService.updateLabel(this.server,this.node,this.node.label).subscribe((function(e){t.nodesDataSource.update(e),t.dialogRef.close()}));else if(this.linkNode&&this.link)this.label.style=this.getStyleFromTextElement(),this.label.rotation=+this.rotation,this.label.text=this.element.text,this.linkService.updateLink(this.server,this.link).subscribe((function(e){t.linksDataSource.update(e),t.dialogRef.close()}));else if(this.drawing){this.drawing.rotation=+this.rotation,this.drawing.element=this.element;var e=this.drawingToMapDrawingConverter.convert(this.drawing);e.element=this.drawing.element,this.drawing.svg=this.mapDrawingToSvgConverter.convert(e),this.drawingService.update(this.server,this.drawing).subscribe((function(e){t.drawingsDataSource.update(e),t.dialogRef.close()}))}}else this.toasterService.error("Entered data is incorrect")},t.prototype.changeTextColor=function(t){this.renderer.setStyle(this.textArea.nativeElement,"color",t)},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(D9),da(R9),da(x9),da(E9),da(Ks),da(E2),da(M9),da(q9),da(G9),da(Jp),da(Y2),da(F9),da(X9))},t.\u0275cmp=Ht({type:t,selectors:[["app-text-editor"]],viewQuery:function(t,e){var n;1&t&&el(Y9,!0),2&t&&tl(n=sl())&&(e.textArea=n.first)},decls:15,vars:4,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"form-field"],["matInput","","placeholder","Fill color","type","color",3,"ngModel","ngModelChange"],[3,"formGroup"],["formControlName","rotation","matInput","","placeholder","Rotation","type","text"],["id","textArea",1,"text",3,"ngModel","readonly","ngModelChange"],["textArea",""],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Text editor"),va(),ga(2,"div",1),ga(3,"mat-form-field",2),ga(4,"input",3),xa("ngModelChange",(function(t){return e.changeTextColor(t)}))("ngModelChange",(function(t){return e.element.fill=t})),va(),va(),ga(5,"form",4),ga(6,"mat-form-field",2),ba(7,"input",5),va(),va(),ga(8,"textarea",6,7),xa("ngModelChange",(function(t){return e.element.text=t})),va(),va(),ga(10,"div",8),ga(11,"button",9),xa("click",(function(){return e.onNoClick()})),ds(12,"Cancel"),va(),ga(13,"button",10),xa("click",(function(){return e.onYesClick()})),ds(14,"Apply"),va(),va()),2&t&&(Qi(4),pa("ngModel",e.element.fill),Qi(1),pa("formGroup",e.formGroup),Qi(3),pa("ngModel",e.element.text)("readonly",!e.isTextEditable))},directives:[r1,Y3,s5,cf,mf,Sp,xp,gf,Pp,Fp,a1,a2],styles:[".item[_ngcontent-%COMP%]{height:25px;font-size:10pt}.item[_ngcontent-%COMP%], .item-name[_ngcontent-%COMP%], .item-value[_ngcontent-%COMP%]{margin-bottom:10px}.item-value[_ngcontent-%COMP%]{width:100%}.input-color[_ngcontent-%COMP%]{padding:0;border-width:0;width:100%;background-color:transparent;outline:none}input[_ngcontent-%COMP%]:focus{outline:none}input[type=color][_ngcontent-%COMP%]{-webkit-appearance:none;border:none;height:25px}input[type=color][_ngcontent-%COMP%]::-webkit-color-swatch-wrapper{padding:0}input[type=color][_ngcontent-%COMP%]::-webkit-color-swatch{border:none}.text[_ngcontent-%COMP%]{width:100%;height:150px}.modal-form-container[_ngcontent-%COMP%]{display:flex;flex-direction:column}.form-field[_ngcontent-%COMP%], .modal-form-container[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{width:100%}"]}),t}(),Q9=function(){return function(){}}(),$9=function(){return function(){}}(),J9=function(){return function(){}}(),ttt=function(){function t(t){this.dialog=t}return t.prototype.ngOnInit=function(){},t.prototype.editText=function(){var t=this.dialog.open(Z9,{width:"300px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.project=this.project,t.drawing=this.drawing,t.node=this.node,t.label=this.label,t.link=this.link,t.linkNode=this.linkNode},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-edit-text-action"]],inputs:{server:"server",project:"project",drawing:"drawing",node:"node",label:"label",link:"link",linkNode:"linkNode"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.editText()})),ga(1,"mat-icon"),ds(2,"text_format"),va(),ga(3,"span"),ds(4,"Edit text"),va(),va())},directives:[E0,x2],encapsulation:2}),t}();function ett(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"textarea",7,8),xa("ngModelChange",(function(t){return Se(n),Aa().config=t})),va(),va()}if(2&t){var i=Aa();Qi(1),pa("ngModel",i.config)}}function ntt(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ga(2,"textarea",10,8),xa("ngModelChange",(function(t){return Se(n),Aa().config=t})),va(),va(),ga(4,"mat-tab",11),ga(5,"textarea",10,8),xa("ngModelChange",(function(t){return Se(n),Aa().privateConfig=t})),va(),va(),va()}if(2&t){var i=Aa();Qi(2),pa("ngModel",i.config),Qi(3),pa("ngModel",i.privateConfig)}}var itt=function(){function t(t,e,n){this.dialogRef=t,this.nodeService=e,this.toasterService=n}return t.prototype.ngOnInit=function(){var t=this;this.nodeService.getStartupConfiguration(this.server,this.node).subscribe((function(e){t.config=e})),"iou"!==this.node.node_type&&"dynamips"!==this.node.node_type||this.nodeService.getPrivateConfiguration(this.server,this.node).subscribe((function(e){t.privateConfig=e}))},t.prototype.onSaveClick=function(){var t=this;this.nodeService.saveConfiguration(this.server,this.node,this.config).subscribe((function(e){"iou"===t.node.node_type||"dynamips"===t.node.node_type?t.nodeService.savePrivateConfiguration(t.server,t.node,t.privateConfig).subscribe((function(e){t.dialogRef.close(),t.toasterService.success("Configuration for node "+t.node.name+" saved.")})):(t.dialogRef.close(),t.toasterService.success("Configuration for node "+t.node.name+" saved."))}))},t.prototype.onCancelClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(E2),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-config-editor"]],decls:9,vars:3,consts:[["mat-dialog-title",""],["class","modal-form-container",4,"ngIf"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[1,"modal-form-container"],["id","textArea",1,"textArea",3,"ngModel","ngModelChange"],["textArea",""],["label","Startup config"],["id","textArea",1,"textAreaTab",3,"ngModel","ngModelChange"],["label","Private config"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ua(2,ett,3,1,"div",1),ua(3,ntt,7,2,"mat-tab-group",2),ga(4,"div",3),ga(5,"button",4),xa("click",(function(){return e.onCancelClick()})),ds(6,"Cancel"),va(),ga(7,"button",5),xa("click",(function(){return e.onSaveClick()})),ds(8,"Apply"),va(),va()),2&t&&(Qi(1),ps("Configuration for node ",e.node.name,""),Qi(1),pa("ngIf","vpcs"===e.node.node_type),Qi(1),pa("ngIf","iou"===e.node.node_type||"dynamips"===e.node.node_type))},directives:[r1,Ah,a1,a2,cf,mf,Sp,U1,I1],styles:[".textArea[_ngcontent-%COMP%]{width:100%;height:350px}.textAreaTab[_ngcontent-%COMP%]{width:100%;height:300px}"]}),t}();function rtt(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().editConfig()})),ga(1,"mat-icon"),ds(2,"settings"),va(),ga(3,"span"),ds(4,"Edit config"),va(),va()}}var ott=function(){function t(t){this.dialog=t}return t.prototype.editConfig=function(){var t=this.dialog.open(itt,{width:"600px",height:"500px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.project=this.project,t.node=this.node},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-edit-config-action"]],inputs:{server:"server",project:"project",node:"node"},decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,rtt,5,0,"button",0),2&t&&pa("ngIf","vpcs"===e.node.node_type||"iou"===e.node.node_type||"dynamips"===e.node.node_type)},directives:[Ah,E0,x2],encapsulation:2}),t}(),att=function(){function t(t){this.dialogRef=t}return t.prototype.close=function(t){this.dialogRef.close(t)},t.\u0275fac=function(e){return new(e||t)(da(Z0))},t.\u0275cmp=Ht({type:t,selectors:[["app-config-dialog"]],decls:10,vars:0,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"container"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Choose configuration file"),va(),ga(2,"div",1),ga(3,"div",2),ga(4,"div"),ga(5,"button",3),xa("click",(function(){return e.close("startup-config")})),ds(6," startup configuration "),va(),va(),ga(7,"div"),ga(8,"button",3),xa("click",(function(){return e.close("private-config")})),ds(9," private configuration "),va(),va(),va(),va())},directives:[r1,a2],styles:[".container[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:space-between}"]}),t}();function stt(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().exportConfig()})),ga(1,"mat-icon"),ds(2,"call_made"),va(),ga(3,"span"),ds(4,"Export config"),va(),va()}}var ctt=function(){function t(t,e){this.nodeService=t,this.dialog=e}return t.prototype.exportConfig=function(){var t=this;"vpcs"===this.node.node_type?this.nodeService.getStartupConfiguration(this.server,this.node).subscribe((function(e){t.downloadByHtmlTag(e)})):this.dialog.open(att,{width:"500px",autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(e){"startup-config"===e?t.nodeService.getStartupConfiguration(t.server,t.node).subscribe((function(e){t.downloadByHtmlTag(e)})):"private-config"===e&&t.nodeService.getPrivateConfiguration(t.server,t.node).subscribe((function(e){t.downloadByHtmlTag(e)}))}))},t.prototype.downloadByHtmlTag=function(t){var e=document.createElement("a");e.setAttribute("href","data:text/plain;charset=utf-8,"+encodeURIComponent(t)),"vpcs"===this.node.node_type?e.setAttribute("download",this.node.name+"_startup.vpc"):"iou"!==this.node.node_type&&"dynamips"!==this.node.node_type||e.setAttribute("download",this.node.name+"_startup.cfg");var n=new MouseEvent("click");e.dispatchEvent(n)},t.\u0275fac=function(e){return new(e||t)(da(E2),da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-export-config-action"]],inputs:{server:"server",node:"node"},decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,stt,5,0,"button",0),2&t&&pa("ngIf","vpcs"===e.node.node_type||"dynamips"===e.node.node_type||"iou"===e.node.node_type)},directives:[Ah,E0,x2],encapsulation:2}),t}(),ltt=["fileInput"],utt=function(){function t(t,e,n){this.nodeService=t,this.toasterService=e,this.dialog=n}return t.prototype.triggerClick=function(){var t=this;"vpcs"!==this.node.node_type?this.dialog.open(att,{width:"500px",autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(e){t.configType=e,t.fileInput.nativeElement.click()})):(this.configType="startup-config",this.fileInput.nativeElement.click())},t.prototype.importConfig=function(t){var e=this,n=t.target.files[0],i=new FileReader;i.onload=function(t){var n=i.result;"string"!=typeof n&&(n=n.toString()),"startup-config"===e.configType?e.nodeService.saveConfiguration(e.server,e.node,n).subscribe((function(){e.toasterService.success("Configuration for node "+e.node.name+" imported.")})):"private-config"===e.configType&&e.nodeService.savePrivateConfiguration(e.server,e.node,n).subscribe((function(){e.toasterService.success("Configuration for node "+e.node.name+" imported.")}))},i.readAsText(n)},t.\u0275fac=function(e){return new(e||t)(da(E2),da(Y2),da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-import-config-action"]],viewQuery:function(t,e){var n;1&t&&nl(ltt,!0),2&t&&tl(n=sl())&&(e.fileInput=n.first)},inputs:{server:"server",node:"node"},decls:7,vars:0,consts:[["type","file","accept",".txt, .vpc",1,"non-visible",3,"change"],["fileInput",""],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"input",0,1),xa("change",(function(t){return e.importConfig(t)})),va(),ga(2,"button",2),xa("click",(function(){return e.triggerClick()})),ga(3,"mat-icon"),ds(4,"call_received"),va(),ga(5,"span"),ds(6,"Import config"),va(),va())},directives:[E0,x2],styles:[".non-visible[_ngcontent-%COMP%]{display:none}"]}),t}(),htt=function(){function t(t,e,n,i){this.nodesDataSource=t,this.drawingsDataSource=e,this.nodeService=n,this.drawingService=i}return t.prototype.ngOnInit=function(){},t.prototype.moveLayerUp=function(){var t=this;this.nodes.forEach((function(e){e.z++,t.nodesDataSource.update(e),t.nodeService.update(t.server,e).subscribe((function(t){}))})),this.drawings.forEach((function(e){e.z++,t.drawingsDataSource.update(e),t.drawingService.update(t.server,e).subscribe((function(t){}))}))},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E9),da(E2),da(x9))},t.\u0275cmp=Ht({type:t,selectors:[["app-move-layer-up-action"]],inputs:{server:"server",nodes:"nodes",drawings:"drawings"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.moveLayerUp()})),ga(1,"mat-icon"),ds(2,"keyboard_arrow_up"),va(),ga(3,"span"),ds(4,"Move layer up"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),dtt=function(){function t(t,e,n,i){this.nodesDataSource=t,this.drawingsDataSource=e,this.nodeService=n,this.drawingService=i}return t.prototype.ngOnInit=function(){},t.prototype.moveLayerDown=function(){var t=this;this.nodes.forEach((function(e){e.z--,t.nodesDataSource.update(e),t.nodeService.update(t.server,e).subscribe((function(t){}))})),this.drawings.forEach((function(e){e.z--,t.drawingsDataSource.update(e),t.drawingService.update(t.server,e).subscribe((function(t){}))}))},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E9),da(E2),da(x9))},t.\u0275cmp=Ht({type:t,selectors:[["app-move-layer-down-action"]],inputs:{server:"server",nodes:"nodes",drawings:"drawings"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.moveLayerDown()})),ga(1,"mat-icon"),ds(2,"keyboard_arrow_down"),va(),ga(3,"span"),ds(4,"Move layer down"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),ftt=function(){function t(t,e,n,i){this.nodesDataSource=t,this.drawingsDataSource=e,this.nodeService=n,this.drawingService=i}return t.prototype.ngOnInit=function(){},t.prototype.bringToFront=function(){var t=this,e=Math.max.apply(Math,this.nodes.map((function(t){return t.z}))),n=Math.max.apply(Math,this.drawings.map((function(t){return t.z}))),i=Math.max(e,n);i<100&&i++,this.nodes.forEach((function(e){e.z=i,t.nodesDataSource.update(e),t.nodeService.update(t.server,e).subscribe((function(t){}))})),this.drawings.forEach((function(e){e.z=i,t.drawingsDataSource.update(e),t.drawingService.update(t.server,e).subscribe((function(t){}))}))},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E9),da(E2),da(x9))},t.\u0275cmp=Ht({type:t,selectors:[["app-bring-to-front-action"]],inputs:{server:"server",nodes:"nodes",drawings:"drawings"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.bringToFront()})),ga(1,"mat-icon"),ds(2,"vertical_align_top"),va(),ga(3,"span"),ds(4,"Bring to front"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),ptt=function(){function t(){}return t.prototype.startCapture=function(t,e,n,i){location.assign("gns3+pcap://"+t.host+":"+t.port+"?project_id="+e.project_id+"&link_id="+n.link_id+"&name="+i)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function mtt(t,e){if(1&t&&(ga(0,"mat-option",11),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}var gtt=function(){return{standalone:!0}},vtt=function(){function t(t,e,n,i,r,o){this.dialogRef=t,this.linkService=e,this.formBuilder=n,this.toasterService=i,this.nodesDataSource=r,this.packetCaptureService=o,this.linkTypes=[],this.inputForm=this.formBuilder.group({linkType:new hp("",kf.required),fileName:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){this.linkTypes="ethernet"===this.link.link_type?[["Ethernet","DLT_EN10MB"]]:[["Cisco HDLC","DLT_C_HDLC"],["Cisco PPP","DLT_PPP_SERIAL"],["Frame Relay","DLT_FRELAY"],["ATM","DLT_ATM_RFC1483"]];var t=this.nodesDataSource.get(this.link.nodes[0].node_id),e=this.nodesDataSource.get(this.link.nodes[1].node_id);this.inputForm.controls.fileName.setValue(t.name+"_"+t.ports[this.link.nodes[0].port_number].name+"_to_"+e.name+"_"+e.ports[this.link.nodes[1].port_number].name)},t.prototype.onYesClick=function(){var t=this,e=!1;if(this.link.nodes.forEach((function(n){"started"===t.nodesDataSource.get(n.node_id).status&&(e=!0)})),e)if(this.inputForm.invalid)this.toasterService.error("Fill all required fields");else{var n={capture_file_name:this.inputForm.get("fileName").value,data_link_type:this.inputForm.get("linkType").value};this.startProgram&&this.packetCaptureService.startCapture(this.server,this.project,this.link,n.capture_file_name),this.linkService.startCaptureOnLink(this.server,this.link,n).subscribe((function(){t.dialogRef.close()}))}else this.toasterService.error("Cannot capture because there is no running device on this link")},t.prototype.onNoClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(q9),da(Jp),da(Y2),da(M9),da(ptt))},t.\u0275cmp=Ht({type:t,selectors:[["app-start-capture"]],decls:16,vars:5,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[3,"formGroup"],[1,"input-field"],["placeholder","Link type","formControlName","linkType","ngDefaultControl",""],[3,"value",4,"ngFor","ngForOf"],["placeholder","File name","formControlName","fileName","matInput","","type","text"],[3,"ngModelOptions","ngModel","ngModelChange"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Packet capture"),va(),ga(2,"div",1),ga(3,"form",2),ga(4,"mat-form-field",3),ga(5,"mat-select",4),ua(6,mtt,2,2,"mat-option",5),va(),va(),ga(7,"mat-form-field",3),ba(8,"input",6),va(),ga(9,"mat-checkbox",7),xa("ngModelChange",(function(t){return e.startProgram=t})),ds(10," Start the capture visualization program "),va(),va(),va(),ga(11,"div",8),ga(12,"button",9),xa("click",(function(){return e.onNoClick()})),ds(13,"Cancel"),va(),ga(14,"button",10),xa("click",(function(){return e.onYesClick()})),ds(15,"Ok"),va(),va()),2&t&&(Qi(3),pa("formGroup",e.inputForm),Qi(3),pa("ngForOf",e.linkTypes),Qi(3),pa("ngModelOptions",jc(4,gtt))("ngModel",e.startProgram))},directives:[r1,xp,gf,Pp,Y3,O5,mf,Fp,cf,Eh,s5,F5,Sp,a1,a2,EJ],styles:[".input-field[_ngcontent-%COMP%]{width:100%}"]}),t}();function btt(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().startCapture()})),ga(1,"mat-icon"),ds(2,"loupe"),va(),ga(3,"span"),ds(4,"Start capture"),va(),va()}}var ytt=function(){function t(t){this.dialog=t}return t.prototype.startCapture=function(){var t=this.dialog.open(vtt,{width:"400px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.project=this.project,t.link=this.link},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-start-capture-action"]],inputs:{server:"server",project:"project",link:"link"},decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,btt,5,0,"button",0),2&t&&pa("ngIf",!e.link.capturing)},directives:[Ah,E0,x2],encapsulation:2}),t}();function _tt(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().stopCapture()})),ga(1,"mat-icon"),ds(2,"pause_circle_filled"),va(),ga(3,"span"),ds(4,"Stop capture"),va(),va()}}var wtt=function(){function t(t){this.linkService=t}return t.prototype.stopCapture=function(){this.linkService.stopCaptureOnLink(this.server,this.link).subscribe((function(){}))},t.\u0275fac=function(e){return new(e||t)(da(q9))},t.\u0275cmp=Ht({type:t,selectors:[["app-stop-capture-action"]],inputs:{server:"server",link:"link"},decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,_tt,5,0,"button",0),2&t&&pa("ngIf",e.link.capturing)},directives:[Ah,E0,x2],encapsulation:2}),t}();function ktt(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().startCapture()})),ga(1,"mat-icon"),ds(2,"search"),va(),ga(3,"span"),ds(4,"Start Wireshark"),va(),va()}}var Ctt=function(){function t(t){this.packetCaptureService=t}return t.prototype.startCapture=function(){var t=this.link.capture_file_name.split(".");this.packetCaptureService.startCapture(this.server,this.project,this.link,t[0])},t.\u0275fac=function(e){return new(e||t)(da(ptt))},t.\u0275cmp=Ht({type:t,selectors:[["app-start-capture-on-started-link-action"]],inputs:{server:"server",project:"project",link:"link"},decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,ktt,5,0,"button",0),2&t&&pa("ngIf",e.link.capturing)},directives:[Ah,E0,x2],encapsulation:2}),t}();function Stt(t,e){if(1&t&&(ga(0,"div",5),ga(1,"h6"),ds(2),va(),ga(3,"span",6),ds(4),va(),va()),2&t){var n=e.$implicit;Qi(2),ps(" ",n.name," "),Qi(2),ps(" ",n.description," ")}}var xtt=function(){function t(t){this.dialogRef=t}return t.prototype.onCloseClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0))},t.\u0275cmp=Ht({type:t,selectors:[["app-help-dialog"]],inputs:{title:"title",messages:"messages"},decls:7,vars:2,consts:[["mat-dialog-title",""],[1,"modal-form-container"],["class","message",4,"ngFor","ngForOf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],[1,"message"],[1,"description"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1),va(),ga(2,"div",1),ua(3,Stt,5,2,"div",2),va(),ga(4,"div",3),ga(5,"button",4),xa("click",(function(){return e.onCloseClick()})),ds(6,"Close"),va(),va()),2&t&&(Qi(1),fs(e.title),Qi(2),pa("ngForOf",e.messages))},directives:[r1,Eh,a1,a2],styles:[".message[_ngcontent-%COMP%]{margin-bottom:10px}.description[_ngcontent-%COMP%]{color:#b0bec5}"]}),t}();function Ott(t,e){if(1&t){var n=ka();ga(0,"mat-tab-group"),ga(1,"mat-tab",9),ga(2,"mat-form-field",10),ga(3,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().filters.frequency_drop[0]=t})),va(),va(),va(),ga(4,"mat-tab",12),ga(5,"mat-form-field",10),ga(6,"input",13),xa("ngModelChange",(function(t){return Se(n),Aa().filters.packet_loss[0]=t})),va(),va(),va(),ga(7,"mat-tab",14),ga(8,"mat-form-field",10),ga(9,"input",15),xa("ngModelChange",(function(t){return Se(n),Aa().filters.delay[0]=t})),va(),va(),ga(10,"mat-form-field",10),ga(11,"input",16),xa("ngModelChange",(function(t){return Se(n),Aa().filters.delay[1]=t})),va(),va(),va(),ga(12,"mat-tab",17),ga(13,"mat-form-field",10),ga(14,"input",15),xa("ngModelChange",(function(t){return Se(n),Aa().filters.corrupt[0]=t})),va(),va(),va(),ga(15,"mat-tab",18),ga(16,"mat-form-field",10),ga(17,"textarea",19),xa("ngModelChange",(function(t){return Se(n),Aa().filters.bpf[0]=t})),va(),va(),va(),va()}if(2&t){var i=Aa();Qi(3),pa("ngModel",i.filters.frequency_drop[0]),Qi(3),pa("ngModel",i.filters.packet_loss[0]),Qi(3),pa("ngModel",i.filters.delay[0]),Qi(2),pa("ngModel",i.filters.delay[1]),Qi(3),pa("ngModel",i.filters.corrupt[0]),Qi(3),pa("ngModel",i.filters.bpf[0])}}var Mtt=function(){function t(t,e,n){this.dialogRef=t,this.linkService=e,this.dialog=n}return t.prototype.ngOnInit=function(){var t=this;this.linkService.getLink(this.server,this.link.project_id,this.link.link_id).subscribe((function(e){t.link=e,t.filters={bpf:[],corrupt:[0],delay:[0,0],frequency_drop:[0],packet_loss:[0]},t.link.filters&&(t.filters.bpf=t.link.filters.bpf?t.link.filters.bpf:[],t.filters.corrupt=t.link.filters.corrupt?t.link.filters.corrupt:[0],t.filters.delay=t.link.filters.delay?t.link.filters.delay:[0,0],t.filters.frequency_drop=t.link.filters.frequency_drop?t.link.filters.frequency_drop:[0],t.filters.packet_loss=t.link.filters.packet_loss?t.link.filters.packet_loss:[0])})),this.linkService.getAvailableFilters(this.server,this.link).subscribe((function(e){t.availableFilters=e}))},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.onResetClick=function(){var t=this;this.link.filters={bpf:[],corrupt:[0],delay:[0,0],frequency_drop:[0],packet_loss:[0]},this.linkService.updateLink(this.server,this.link).subscribe((function(e){t.dialogRef.close()}))},t.prototype.onYesClick=function(){var t=this;this.link.filters=this.filters,this.linkService.updateLink(this.server,this.link).subscribe((function(e){t.dialogRef.close()}))},t.prototype.onHelpClick=function(){var t=this.dialog.open(xtt,{width:"500px",autoFocus:!1,disableClose:!0}).componentInstance;t.title="Help for filters";var e=[];this.availableFilters.forEach((function(t){e.push({name:t.name,description:t.description})})),t.messages=e},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(q9),da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-packet-filters"]],decls:16,vars:1,consts:[["mat-dialog-title",""],[1,"content"],[4,"ngIf"],[1,"bottom-bar"],[1,"spacer"],["mat-dialog-actions","","layout","row",1,"dialog-actions"],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[1,"divider"],["label","Frequency drop"],[1,"input-field"],["matInput","","placeholder","Frequency","type","number",3,"ngModel","ngModelChange"],["label","Packet loss"],["matInput","","placeholder","Chance","type","number",3,"ngModel","ngModelChange"],["label","Delay"],["matInput","","placeholder","Latency","type","number",3,"ngModel","ngModelChange"],["matInput","","placeholder","Jitter","type","number",3,"ngModel","ngModelChange"],["label","Corrupt"],["label","Berkeley Packet Filter (BPF)"],["matInput","","type","text",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Packet filters"),va(),ga(2,"div",1),ua(3,Ott,18,6,"mat-tab-group",2),va(),ga(4,"div",3),ba(5,"div",4),ga(6,"div",5),ga(7,"button",6),xa("click",(function(){return e.onNoClick()})),ds(8,"Cancel"),va(),ga(9,"button",6),xa("click",(function(){return e.onResetClick()})),ds(10,"Reset"),va(),ga(11,"button",7),xa("click",(function(){return e.onYesClick()})),ds(12,"Apply"),va(),ba(13,"div",8),ga(14,"button",6),xa("click",(function(){return e.onHelpClick()})),ds(15,"Help"),va(),va(),va()),2&t&&(Qi(3),pa("ngIf",e.filters))},directives:[r1,Ah,a1,a2,U1,I1,Y3,s5,Ef,cf,mf,Sp],styles:[".spacer[_ngcontent-%COMP%]{flex-grow:1}.content[_ngcontent-%COMP%]{height:260px}.item[_ngcontent-%COMP%]{height:25px;font-size:10pt}.item[_ngcontent-%COMP%], .item-name[_ngcontent-%COMP%], .item-value[_ngcontent-%COMP%]{margin-bottom:10px}.item-value[_ngcontent-%COMP%]{width:100%}.input-field[_ngcontent-%COMP%]{width:100%;margin-top:10px}.divider[_ngcontent-%COMP%]{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;flex:1 1 auto}.input-color[_ngcontent-%COMP%]{padding:0;border-width:0;width:100%;background-color:transparent;outline:none}input[_ngcontent-%COMP%]:focus{outline:none}input[type=color][_ngcontent-%COMP%]{-webkit-appearance:none;border:none;height:25px}input[type=color][_ngcontent-%COMP%]::-webkit-color-swatch-wrapper{padding:0}input[type=color][_ngcontent-%COMP%]::-webkit-color-swatch{border:none}.modal-form-container[_ngcontent-%COMP%]{display:flex;flex-direction:column}.modal-form-container[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{width:100%}"]}),t}(),Ttt=function(){function t(t){this.dialog=t}return t.prototype.openPacketFilters=function(){var t=this.dialog.open(Mtt,{width:"900px",height:"400px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.project=this.project,t.link=this.link},t.\u0275fac=function(e){return new(e||t)(da(e1))},t.\u0275cmp=Ht({type:t,selectors:[["app-packet-filters-action"]],inputs:{server:"server",project:"project",link:"link"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.openPacketFilters()})),ga(1,"mat-icon"),ds(2,"filter_list"),va(),ga(3,"span"),ds(4,"Packet filters"),va(),va())},directives:[E0,x2],encapsulation:2}),t}();function Ett(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().resumeLink()})),ga(1,"mat-icon"),ds(2,"play_arrow"),va(),ga(3,"span"),ds(4,"Resume"),va(),va()}}var Ptt=function(){function t(t){this.linkService=t}return t.prototype.resumeLink=function(){this.link.suspend=!1,this.linkService.updateLink(this.server,this.link).subscribe((function(){}))},t.\u0275fac=function(e){return new(e||t)(da(q9))},t.\u0275cmp=Ht({type:t,selectors:[["app-resume-link-action"]],inputs:{server:"server",link:"link"},decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,Ett,5,0,"button",0),2&t&&pa("ngIf",e.link.suspend)},directives:[Ah,E0,x2],encapsulation:2}),t}();function Att(t,e){if(1&t){var n=ka();ga(0,"button",1),xa("click",(function(){return Se(n),Aa().suspendLink()})),ga(1,"mat-icon"),ds(2,"pause"),va(),ga(3,"span"),ds(4,"Suspend"),va(),va()}}var jtt=function(){function t(t){this.linkService=t}return t.prototype.suspendLink=function(){this.link.suspend=!0,this.linkService.updateLink(this.server,this.link).subscribe((function(){}))},t.\u0275fac=function(e){return new(e||t)(da(q9))},t.\u0275cmp=Ht({type:t,selectors:[["app-suspend-link-action"]],inputs:{server:"server",link:"link"},decls:1,vars:1,consts:[["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&ua(0,Att,5,0,"button",0),2&t&&pa("ngIf",!e.link.suspend)},directives:[Ah,E0,x2],encapsulation:2}),t}(),Itt=function(){function t(t,e,n,i){this.nodesDataSource=t,this.drawingsDataSource=e,this.nodeService=n,this.drawingService=i}return t.prototype.ngOnChanges=function(){this.command=1===this.nodes.length&&0===this.drawings.length?this.nodes[0].locked?"Unlock item":"Lock item":0===this.nodes.length&&1===this.drawings.length?this.drawings[0].locked?"Unlock item":"Lock item":"Lock/unlock items"},t.prototype.lock=function(){var t=this;this.nodes.forEach((function(e){e.locked=!e.locked,t.nodeService.updateNode(t.server,e).subscribe((function(e){t.nodesDataSource.update(e)}))})),this.drawings.forEach((function(e){e.locked=!e.locked,t.drawingService.update(t.server,e).subscribe((function(e){t.drawingsDataSource.update(e)}))}))},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E9),da(E2),da(x9))},t.\u0275cmp=Ht({type:t,selectors:[["app-lock-action"]],inputs:{server:"server",nodes:"nodes",drawings:"drawings"},features:[Ms],decls:5,vars:1,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.lock()})),ga(1,"mat-icon"),ds(2,"lock"),va(),ga(3,"span"),ds(4),va(),va()),2&t&&(Qi(4),fs(e.command))},directives:[E0,x2],encapsulation:2}),t}(),Dtt=function(){function t(t,e,n,i,r,o){this.nodesDataSource=t,this.drawingsDataSource=e,this.linksDataSource=n,this.nodeService=i,this.drawingService=r,this.linkService=o}return t.prototype.ngOnInit=function(){},t.prototype.delete=function(){var t=this;this.nodes.forEach((function(e){t.nodesDataSource.remove(e),t.nodeService.delete(t.server,e).subscribe((function(t){}))})),this.drawings.forEach((function(e){t.drawingsDataSource.remove(e),t.drawingService.delete(t.server,e).subscribe((function(t){}))})),this.links.forEach((function(e){t.linksDataSource.remove(e),t.linkService.deleteLink(t.server,e).subscribe((function(){}))}))},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E9),da(G9),da(E2),da(x9),da(q9))},t.\u0275cmp=Ht({type:t,selectors:[["app-delete-action"]],inputs:{server:"server",nodes:"nodes",drawings:"drawings",links:"links"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.delete()})),ga(1,"mat-icon"),ds(2,"delete"),va(),ga(3,"span"),ds(4,"Delete"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),Rtt=function(){function t(t,e){this.nodesDataSource=t,this.nodeService=e}return t.prototype.ngOnInit=function(){},t.prototype.alignHorizontally=function(){var t=this,e=0;this.nodes.forEach((function(t){e+=t.y})),e/=this.nodes.length,this.nodes.forEach((function(n){n.y=e,t.nodesDataSource.update(n),t.nodeService.update(t.server,n).subscribe((function(t){}))}))},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-align-horizontally-action"]],inputs:{server:"server",nodes:"nodes"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.alignHorizontally()})),ga(1,"mat-icon"),ds(2,"more_horiz"),va(),ga(3,"span"),ds(4,"Align horizontally"),va(),va())},directives:[E0,x2],encapsulation:2}),t}(),Ltt=function(){function t(t,e){this.nodesDataSource=t,this.nodeService=e}return t.prototype.ngOnInit=function(){},t.prototype.alignVertically=function(){var t=this,e=0;this.nodes.forEach((function(t){e+=t.x})),e/=this.nodes.length,this.nodes.forEach((function(n){n.x=e,t.nodesDataSource.update(n),t.nodeService.update(t.server,n).subscribe((function(t){}))}))},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-align-vertically-action"]],inputs:{server:"server",nodes:"nodes"},decls:5,vars:0,consts:[["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.alignVertically()})),ga(1,"mat-icon"),ds(2,"more_vert"),va(),ga(3,"span"),ds(4,"Align vertically"),va(),va())},directives:[E0,x2],encapsulation:2}),t}();function Ftt(t,e){if(1&t&&ba(0,"app-show-node-action",14),2&t){var n=Aa();pa("server",n.server)("node",n.nodes[0])}}function Ntt(t,e){if(1&t&&ba(0,"app-config-node-action",14),2&t){var n=Aa();pa("server",n.server)("node",n.nodes[0])}}function Btt(t,e){if(1&t&&ba(0,"app-start-node-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}function Htt(t,e){if(1&t&&ba(0,"app-suspend-node-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}function ztt(t,e){if(1&t&&ba(0,"app-stop-node-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}function Vtt(t,e){if(1&t&&ba(0,"app-reload-node-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}function Utt(t,e){if(1&t&&ba(0,"app-http-console-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}function qtt(t,e){if(1&t&&ba(0,"app-http-console-new-tab-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}function Gtt(t,e){if(1&t&&ba(0,"app-console-device-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}function Wtt(t,e){if(1&t&&ba(0,"app-console-device-action-browser",14),2&t){var n=Aa();pa("server",n.server)("node",n.nodes[0])}}function Ktt(t,e){if(1&t&&ba(0,"app-open-file-explorer-action",14),2&t){var n=Aa();pa("server",n.server)("node",n.nodes[0])}}function Xtt(t,e){if(1&t&&ba(0,"app-change-hostname-action",14),2&t){var n=Aa();pa("server",n.server)("node",n.nodes[0])}}function Ytt(t,e){if(1&t&&ba(0,"app-change-symbol-action",14),2&t){var n=Aa();pa("server",n.server)("node",n.nodes[0])}}function Ztt(t,e){if(1&t&&ba(0,"app-duplicate-action",16),2&t){var n=Aa();pa("server",n.server)("project",n.project)("nodes",n.nodes)("drawings",n.drawings)}}function Qtt(t,e){if(1&t&&ba(0,"app-edit-style-action",17),2&t){var n=Aa();pa("server",n.server)("project",n.project)("drawing",n.drawings[0])}}function $tt(t,e){if(1&t&&ba(0,"app-edit-text-action",18),2&t){var n=Aa();pa("server",n.server)("project",n.project)("drawing",n.drawings[0])("node",n.nodes[0])("label",n.labels[0])("link",n.links[0])("linkNode",n.linkNodes[0])}}function Jtt(t,e){if(1&t&&ba(0,"app-edit-config-action",19),2&t){var n=Aa();pa("server",n.server)("project",n.project)("node",n.nodes[0])}}function tet(t,e){if(1&t&&ba(0,"app-export-config-action",14),2&t){var n=Aa();pa("server",n.server)("node",n.nodes[0])}}function eet(t,e){if(1&t&&ba(0,"app-import-config-action",14),2&t){var n=Aa();pa("server",n.server)("node",n.nodes[0])}}function net(t,e){if(1&t&&ba(0,"app-move-layer-up-action",20),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)("drawings",n.drawings)}}function iet(t,e){if(1&t&&ba(0,"app-move-layer-down-action",20),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)("drawings",n.drawings)}}function ret(t,e){if(1&t&&ba(0,"app-bring-to-front-action",20),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)("drawings",n.drawings)}}function oet(t,e){if(1&t&&ba(0,"app-start-capture-action",21),2&t){var n=Aa();pa("server",n.server)("project",n.project)("link",n.links[0])}}function aet(t,e){if(1&t&&ba(0,"app-stop-capture-action",22),2&t){var n=Aa();pa("server",n.server)("link",n.links[0])}}function set(t,e){if(1&t&&ba(0,"app-start-capture-on-started-link-action",21),2&t){var n=Aa();pa("server",n.server)("project",n.project)("link",n.links[0])}}function cet(t,e){if(1&t&&ba(0,"app-packet-filters-action",21),2&t){var n=Aa();pa("server",n.server)("project",n.project)("link",n.links[0])}}function uet(t,e){if(1&t&&ba(0,"app-resume-link-action",22),2&t){var n=Aa();pa("server",n.server)("link",n.links[0])}}function het(t,e){if(1&t&&ba(0,"app-suspend-link-action",22),2&t){var n=Aa();pa("server",n.server)("link",n.links[0])}}function det(t,e){if(1&t&&ba(0,"app-lock-action",20),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)("drawings",n.drawings)}}function fet(t,e){if(1&t&&ba(0,"app-delete-action",23),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)("drawings",n.drawings)("links",n.links)}}function pet(t,e){if(1&t&&ba(0,"app-align-horizontally-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}function met(t,e){if(1&t&&ba(0,"app-align-vertically-action",15),2&t){var n=Aa();pa("server",n.server)("nodes",n.nodes)}}var get=function(){function t(t,e,n,i){this.sanitizer=t,this.changeDetector=e,this.electronService=n,this.projectService=i,this.drawings=[],this.nodes=[],this.labels=[],this.links=[],this.linkNodes=[],this.hasTextCapabilities=!1,this.isElectronApp=!1,this.isBundledServer=!1}return t.prototype.ngOnInit=function(){this.setPosition(0,0),this.isElectronApp=this.electronService.isElectronApp,this.isBundledServer="bundled"===this.server.location},t.prototype.setPosition=function(t,e){this.topPosition=this.sanitizer.bypassSecurityTrustStyle(t+"px"),this.leftPosition=this.sanitizer.bypassSecurityTrustStyle(e+"px"),this.changeDetector.detectChanges()},t.prototype.openMenuForDrawing=function(t,e,n){this.resetCapabilities(),this.hasTextCapabilities=t.element instanceof z0,this.drawings=[t],this.setPosition(e,n),this.contextMenu.openMenu()},t.prototype.openMenuForNode=function(t,e,n){this.resetCapabilities(),this.nodes=[t],this.setPosition(e,n),this.contextMenu.openMenu()},t.prototype.openMenuForLabel=function(t,e,n,i){this.resetCapabilities(),this.labels=[t],this.nodes=[e],this.setPosition(n,i),this.contextMenu.openMenu()},t.prototype.openMenuForInterfaceLabel=function(t,e,n,i){this.resetCapabilities(),this.linkNodes=[t],this.links=[e],this.setPosition(n,i),this.contextMenu.openMenu()},t.prototype.openMenuForListOfElements=function(t,e,n,i,r,o){this.resetCapabilities(),this.drawings=t,this.nodes=e,this.labels=n,this.links=i,this.setPosition(r,o),this.contextMenu.openMenu()},t.prototype.resetCapabilities=function(){this.drawings=[],this.nodes=[],this.labels=[],this.linkNodes=[],this.links=[],this.hasTextCapabilities=!1},t.\u0275fac=function(e){return new(e||t)(da(Vd),da(Po),da(mX),da($Q))},t.\u0275cmp=Ht({type:t,selectors:[["app-context-menu"]],viewQuery:function(t,e){var n;1&t&&nl(N0,!0),2&t&&tl(n=sl())&&(e.contextMenu=n.first)},inputs:{project:"project",server:"server"},decls:36,vars:37,consts:[[1,"context-menu"],[3,"matMenuTriggerFor"],[1,"context-menu-items"],["contextMenu","matMenu"],[3,"server","node",4,"ngIf"],[3,"server","nodes",4,"ngIf"],[3,"server","project","nodes","drawings",4,"ngIf"],[3,"server","project","drawing",4,"ngIf"],[3,"server","project","drawing","node","label","link","linkNode",4,"ngIf"],[3,"server","project","node",4,"ngIf"],[3,"server","nodes","drawings",4,"ngIf"],[3,"server","project","link",4,"ngIf"],[3,"server","link",4,"ngIf"],[3,"server","nodes","drawings","links",4,"ngIf"],[3,"server","node"],[3,"server","nodes"],[3,"server","project","nodes","drawings"],[3,"server","project","drawing"],[3,"server","project","drawing","node","label","link","linkNode"],[3,"server","project","node"],[3,"server","nodes","drawings"],[3,"server","project","link"],[3,"server","link"],[3,"server","nodes","drawings","links"]],template:function(t,e){if(1&t&&(ga(0,"div",0),ba(1,"span",1),ga(2,"mat-menu",2,3),ua(4,Ftt,1,2,"app-show-node-action",4),ua(5,Ntt,1,2,"app-config-node-action",4),ua(6,Btt,1,2,"app-start-node-action",5),ua(7,Htt,1,2,"app-suspend-node-action",5),ua(8,ztt,1,2,"app-stop-node-action",5),ua(9,Vtt,1,2,"app-reload-node-action",5),ua(10,Utt,1,2,"app-http-console-action",5),ua(11,qtt,1,2,"app-http-console-new-tab-action",5),ua(12,Gtt,1,2,"app-console-device-action",5),ua(13,Wtt,1,2,"app-console-device-action-browser",4),ua(14,Ktt,1,2,"app-open-file-explorer-action",4),ua(15,Xtt,1,2,"app-change-hostname-action",4),ua(16,Ytt,1,2,"app-change-symbol-action",4),ua(17,Ztt,1,4,"app-duplicate-action",6),ua(18,Qtt,1,3,"app-edit-style-action",7),ua(19,$tt,1,7,"app-edit-text-action",8),ua(20,Jtt,1,3,"app-edit-config-action",9),ua(21,tet,1,2,"app-export-config-action",4),ua(22,eet,1,2,"app-import-config-action",4),ua(23,net,1,3,"app-move-layer-up-action",10),ua(24,iet,1,3,"app-move-layer-down-action",10),ua(25,ret,1,3,"app-bring-to-front-action",10),ua(26,oet,1,3,"app-start-capture-action",11),ua(27,aet,1,2,"app-stop-capture-action",12),ua(28,set,1,3,"app-start-capture-on-started-link-action",11),ua(29,cet,1,3,"app-packet-filters-action",11),ua(30,uet,1,2,"app-resume-link-action",12),ua(31,het,1,2,"app-suspend-link-action",12),ua(32,det,1,3,"app-lock-action",10),ua(33,fet,1,4,"app-delete-action",13),ua(34,pet,1,2,"app-align-horizontally-action",5),ua(35,met,1,2,"app-align-vertically-action",5),va(),va()),2&t){var n=ha(3);Za("left",e.leftPosition)("top",e.topPosition),Qi(1),pa("matMenuTriggerFor",n),Qi(3),pa("ngIf",1===e.nodes.length),Qi(1),pa("ngIf",1===e.nodes.length),Qi(1),pa("ngIf",e.nodes.length),Qi(1),pa("ngIf",e.nodes.length),Qi(1),pa("ngIf",e.nodes.length),Qi(1),pa("ngIf",e.nodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&1===e.nodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&1===e.nodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&e.nodes.length&&e.isElectronApp),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&1===e.nodes.length&&!e.isElectronApp),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&1===e.nodes.length&&e.isElectronApp),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&1===e.nodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&1===e.nodes.length),Qi(1),pa("ngIf",e.drawings.length>0||e.nodes.length>0),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&1===e.drawings.length&&!e.hasTextCapabilities),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&(1===e.drawings.length&&e.hasTextCapabilities&&0===e.labels.length&&0===e.linkNodes.length||1===e.labels.length&&0===e.linkNodes.length&&0===e.drawings.length||1===e.linkNodes.length&&0===e.labels.length&&0===e.drawings.length)),Qi(1),pa("ngIf",1===e.nodes.length&&"vpcs"===e.nodes[0].node_type),Qi(1),pa("ngIf",1===e.nodes.length&&("vpcs"===e.nodes[0].node_type||"iou"===e.nodes[0].node_type||"dynamips"===e.nodes[0].node_type)),Qi(1),pa("ngIf",1===e.nodes.length&&("vpcs"===e.nodes[0].node_type||"iou"===e.nodes[0].node_type||"dynamips"===e.nodes[0].node_type)),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&(e.drawings.length||e.nodes.length)),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&(e.drawings.length||e.nodes.length)),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&(e.drawings.length||e.nodes.length)),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&0===e.drawings.length&&0===e.nodes.length&&1===e.links.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&0===e.drawings.length&&0===e.nodes.length&&1===e.links.length&&0===e.linkNodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&0===e.drawings.length&&0===e.nodes.length&&1===e.links.length&&0===e.linkNodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&0===e.drawings.length&&0===e.nodes.length&&1===e.links.length&&0===e.linkNodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&0===e.drawings.length&&0===e.nodes.length&&1===e.links.length&&0===e.linkNodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&0===e.drawings.length&&0===e.nodes.length&&1===e.links.length&&0===e.linkNodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&(e.drawings.length>0||e.nodes.length>0)),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&(e.drawings.length>0||e.nodes.length>0||e.links.length>0)&&0===e.linkNodes.length),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&e.nodes.length>1),Qi(1),pa("ngIf",!e.projectService.isReadOnly(e.project)&&e.nodes.length>1)}},directives:[N0,D0,Ah,M2,V8,q8,W8,X8,Z8,J8,t9,e9,n9,i9,o9,p9,A9,U9,ttt,ott,ctt,utt,htt,dtt,ftt,ytt,wtt,Ctt,Ttt,Ptt,jtt,Itt,Dtt,Rtt,Ltt],styles:[".context-menu[_ngcontent-%COMP%]{position:absolute;min-height:0}.mat-menu-panel[_ngcontent-%COMP%] ng-trigger[_ngcontent-%COMP%] ng-trigger-transformMenu[_ngcontent-%COMP%] ng-tns-c7-5[_ngcontent-%COMP%] context-menu-items[_ngcontent-%COMP%] mat-menu-after[_ngcontent-%COMP%] mat-menu-below[_ngcontent-%COMP%] ng-star-inserted[_ngcontent-%COMP%] mat-elevation-z4[_ngcontent-%COMP%]{min-height:0!important}"]}),t}(),vet=function(){function t(t,e,n){this.nodesDataSource=t,this.linksDataSource=e,this.drawingsDataSource=n,this.nodeNotificationEmitter=new Uc,this.linkNotificationEmitter=new Uc,this.drawingNotificationEmitter=new Uc,this.infoNotificationEmitter=new Uc,this.warningNotificationEmitter=new Uc,this.errorNotificationEmitter=new Uc}return t.prototype.handleMessage=function(t){"node.updated"===t.action&&(this.nodesDataSource.update(t.event),this.nodeNotificationEmitter.emit(t)),"node.created"===t.action&&(this.nodesDataSource.add(t.event),this.nodeNotificationEmitter.emit(t)),"node.deleted"===t.action&&(this.nodesDataSource.remove(t.event),this.nodeNotificationEmitter.emit(t)),"link.created"===t.action&&(this.linksDataSource.add(t.event),this.linkNotificationEmitter.emit(t)),"link.updated"===t.action&&(this.linksDataSource.update(t.event),this.linkNotificationEmitter.emit(t)),"link.deleted"===t.action&&(this.linksDataSource.remove(t.event),this.linkNotificationEmitter.emit(t)),"drawing.created"===t.action&&(this.drawingsDataSource.add(t.event),this.drawingNotificationEmitter.emit(t)),"drawing.updated"===t.action&&(this.drawingsDataSource.update(t.event),this.drawingNotificationEmitter.emit(t)),"drawing.deleted"===t.action&&(this.drawingsDataSource.remove(t.event),this.drawingNotificationEmitter.emit(t)),"log.error"===t.action&&this.errorNotificationEmitter.emit(t.event.message),"log.warning"===t.action&&this.warningNotificationEmitter.emit(t.event.message),"log.info"===t.action&&this.infoNotificationEmitter.emit(t.event.message)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(M9),_t(G9),_t(E9))}}),t}(),bet=function(){return function(t,e,n){void 0===n&&(n=!1),this.visible=t,this.error=e,this.clear=n}}(),yet=function(){function t(){this.state=new Pm.a(new bet(!1))}return t.prototype.setError=function(t){this.state.next(new bet(!1,t.error))},t.prototype.clear=function(){this.state.next(new bet(!1,null,!0))},t.prototype.activate=function(){this.state.next(new bet(!0))},t.prototype.deactivate=function(){this.state.next(new bet(!1))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),_et=function(){function t(){this.changesDetected=new Uc,this.hasBeenDrawn=!1}return t.prototype.detectChanges=function(){this.changesDetected.emit(!0)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),wet=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e}(function(){return function(t,e){this.event=t,this.node=e}}()),ket=function(){return function(){}}(),Cet=function(){return function(){}}(),xet=function(){function t(){}return t.prototype.calculate=function(t,e){var n=document.createElement("text");n.innerText=t,n.setAttribute("fill","#00000"),n.setAttribute("fill-opacity","0"),n.setAttribute("style",e),document.documentElement.appendChild(n);var i=n.getBoundingClientRect();return document.documentElement.removeChild(n),{width:i.width,height:i.height}},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Oet=function(){function t(){}return t.prototype.fix=function(t){var e=K9.parse(t,{context:"declarationList"});return e.children.forEach((function(t){"font-size"===t.property&&t.value&&t.value.children&&t.value.children.forEach((function(t){if("Number"===t.type){var e=t.value.toString();e.indexOf("pt")>=0||e.indexOf("px")>=0||(t.value=e+"pt")}}))})),K9.generate(e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Met=function(){function t(t,e,n){this.fontBBoxCalculator=t,this.cssFixer=e,this.fontFixer=n}return t.prototype.convert=function(t,e){var n=new Cet;n.rotation=t.rotation,n.style=t.style,n.text=t.text,n.x=t.x,n.y=t.y,n.originalX=t.x,n.originalY=t.y,void 0!==e&&(n.id=e.node_id,n.nodeId=e.node_id);var i=this.cssFixer.fix(n.style),r=this.fontFixer.fixStyles(i),o=this.fontBBoxCalculator.calculate(n.text,r);return null!==n.x&&(n.x+=3),null!==n.y&&(n.y+=o.height),n},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(xet),_t(Oet),_t(X9))}}),t}(),Tet=function(){return function(){}}(),Eet=function(){function t(){}return t.prototype.convert=function(t){var e=new Tet;return e.adapterNumber=t.adapter_number,e.linkType=t.link_type,e.name=t.name,e.portNumber=t.port_number,e.shortName=t.short_name,e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Pet=function(){function t(t,e,n,i,r){this.labelToMapLabel=t,this.portToMapPort=e,this.fontBBoxCalculator=n,this.cssFixer=i,this.fontFixer=r}return t.prototype.convert=function(t){var e=this,n=new ket;if(n.id=t.node_id,n.commandLine=t.command_line,n.computeId=t.compute_id,n.console=t.console,n.consoleHost=t.console_host,n.consoleType=t.console_type,n.firstPortName=t.first_port_name,n.height=t.height,n.label=this.labelToMapLabel?this.labelToMapLabel.convert(t.label,{node_id:t.node_id}):void 0,n.locked=t.locked,n.name=t.name,n.nodeDirectory=t.node_directory,n.nodeType=t.node_type,n.portNameFormat=t.port_name_format,n.portSegmentSize=t.port_segment_size,n.ports=t.ports?t.ports.map((function(t){return e.portToMapPort.convert(t)})):[],n.projectId=t.project_id,n.status=t.status,n.symbol=t.symbol,n.symbolUrl=t.symbol_url,n.usage=t.usage,n.width=t.width,n.x=t.x,n.y=t.y,n.z=t.z,void 0!==n.label){var i=this.cssFixer.fix(n.label.style),r=this.fontFixer.fixStyles(i),o=this.fontBBoxCalculator.calculate(n.label.text,r);null!==t.label.x&&null!==t.label.y||(n.label.x=t.width/2-o.width/2+3,n.label.y=-8)}return n},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Met),_t(Eet),_t(xet),_t(Oet),_t(X9))}}),t}(),Aet=function(){return function(){}}(),jet=function(){function t(t){this.labelToMapLabel=t}return t.prototype.convert=function(t,e){var n=new Aet;return n.nodeId=t.node_id,n.adapterNumber=t.adapter_number,n.portNumber=t.port_number,n.label=this.labelToMapLabel.convert(t.label),void 0!==e&&(n.linkId=e.link_id,n.id=n.nodeId+"-"+n.linkId),n},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Met))}}),t}(),Iet=function(){return function(){this.isSelected=!1,this.isMultiplied=!1}}(),Det=function(){function t(t){this.linkNodeToMapLinkNode=t}return t.prototype.convert=function(t){var e=this,n=new Iet;return n.id=t.link_id,n.captureFileName=t.capture_file_name,n.captureFilePath=t.capture_file_path,n.capturing=t.capturing,n.filters=t.filters,n.linkType=t.link_type,n.nodes=t.nodes.map((function(n){return e.linkNodeToMapLinkNode.convert(n,{link_id:t.link_id})})),n.projectId=t.project_id,n.suspend=t.suspend,n},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(jet))}}),t}(),Ret=function(){return function(){}}(),Let=function(){function t(){}return t.prototype.convert=function(t){var e=new Ret;return e.id=t.symbol_id,e.builtin=t.builtin,e.filename=t.filename,e.raw=t.raw,e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Fet=function(){return function(t,e,n,i){void 0===e&&(e=[]),void 0===n&&(n=[]),void 0===i&&(i=[]),this.index=t,this.nodes=e,this.drawings=n,this.links=i}}(),Net=function(){function t(){this.layers={}}return t.prototype.getLayersList=function(){var t=this;return Object.keys(this.layers).sort((function(t,e){return Number(t)-Number(e)})).map((function(e){return t.layers[e]}))},t.prototype.setNodes=function(t){var e=this;t.forEach((function(t){e.getLayerForKey(t.z.toString()).nodes.push(t)}))},t.prototype.setDrawings=function(t){var e=this;t.forEach((function(t){e.getLayerForKey(t.z.toString()).drawings.push(t)}))},t.prototype.setLinks=function(t){var e=this;t.filter((function(t){return t.source&&t.target})).forEach((function(t){var n=Math.min(t.source.z,t.target.z).toString();e.getLayerForKey(n).links.push(t)}))},t.prototype.clear=function(){this.layers={}},t.prototype.getLayerForKey=function(t){return t in this.layers||(this.layers[t]=new Fet,this.layers[t].index=Number(t)),this.layers[t]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Bet=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.prototype.getItemKey=function(t){return t.id},e}(O9),Het=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return zet(t||e)}}),e}(Bet),zet=zn(Het),Vet=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return Uet(t||e)}}),e}(Bet),Uet=zn(Vet),qet=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return Get(t||e)}}),e}(Bet),Get=zn(qet),Wet=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return Ket(t||e)}}),e}(Bet),Ket=zn(Wet),Xet=function(){function t(){this.LINK_WIDTH=2}return t.prototype.linkTranslation=function(t,e,n){var i,r,o=n.y-e.y;if(0===o)i=0,r=t;else{var a=Math.atan((n.x-e.x)/o);i=-t*Math.cos(a),r=t*Math.sin(a)}return{dx:i,dy:r}},t.prototype.assignDataToLinks=function(t){var e=this,n={};t.forEach((function(t,i){var r=t.source.id,o=t.target.id,a=r<o?r+","+o:o+","+r,s=1;a in n?s=n[a].push(i):n[a]=[i],t.distance=s%2==0?s*e.LINK_WIDTH:(1-s)*e.LINK_WIDTH}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Yet=function(){function t(t,e,n,i,r,o,a,s,c,l){this.mapNodesDataSource=t,this.mapLinksDataSource=e,this.mapDrawingsDataSource=n,this.mapSymbolsDataSource=i,this.nodeToMapNode=r,this.linkToMapLink=o,this.drawingToMapDrawing=a,this.symbolToMapSymbol=s,this.layersManager=c,this.multiLinkCalculator=l}return t.prototype.setNodes=function(t){var e=this;if(t){var n=t.map((function(t){return e.nodeToMapNode.convert(t)}));this.mapNodesDataSource.set(n),this.assignDataToLinks(),this.onDataUpdate()}},t.prototype.setLinks=function(t){var e=this;if(t){var n=t.map((function(t){return e.linkToMapLink.convert(t)}));this.mapLinksDataSource.set(n),this.assignDataToLinks(),this.onDataUpdate()}},t.prototype.setDrawings=function(t){var e=this;if(t){var n=t.map((function(t){return e.drawingToMapDrawing.convert(t)}));this.mapDrawingsDataSource.set(n),this.onDataUpdate()}},t.prototype.setSymbols=function(t){var e=this;if(t){var n=t.map((function(t){return e.symbolToMapSymbol.convert(t)}));this.mapSymbolsDataSource.set(n)}},t.prototype.getNodes=function(){return this.mapNodesDataSource.getItems()},t.prototype.getLinks=function(){return this.mapLinksDataSource.getItems()},t.prototype.getDrawings=function(){return this.mapDrawingsDataSource.getItems()},t.prototype.getSymbols=function(){return this.mapSymbolsDataSource.getItems()},t.prototype.onDataUpdate=function(){this.layersManager.clear(),this.layersManager.setNodes(this.getNodes()),this.layersManager.setLinks(this.getLinks()),this.layersManager.setDrawings(this.getDrawings())},t.prototype.assignDataToLinks=function(){var t={};this.getNodes().forEach((function(e){t[e.id]=e})),this.getLinks().forEach((function(e){var n=e.nodes[0].nodeId,i=e.nodes[1].nodeId;n in t&&(e.source=t[n]),i in t&&(e.target=t[i]),e.source&&e.target&&(e.x=e.source.x+.5*(e.target.x-e.source.x),e.y=e.source.y+.5*(e.target.y-e.source.y))})),this.multiLinkCalculator.assignDataToLinks(this.getLinks())},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Het),_t(Vet),_t(qet),_t(Wet),_t(Pet),_t(Det),_t(D9),_t(Let),_t(Net),_t(Xet))}}),t}(),Zet=function(){function t(){this.selection={},this.selected=new Uc,this.unselected=new Uc}return t.prototype.setSelected=function(t){var e=this,n=this.convertToKeyDict(t),i=Object.keys(n).filter((function(t){return!e.isSelectedByKey(t)})).map((function(t){return n[t]})),r=Object.keys(this.selection).filter((function(t){return!(t in n)})).map((function(t){return e.selection[t]}));this.selection=n,i.length>0&&this.selected.emit(i),r.length>0&&this.unselected.emit(r)},t.prototype.getSelected=function(){var t=this;return Object.keys(this.selection).map((function(e){return t.selection[e]}))},t.prototype.isSelected=function(t){var e=this.getKey(t);return this.isSelectedByKey(e)},t.prototype.isSelectedByKey=function(t){return t in this.selection},t.prototype.getKey=function(t){return t.constructor.name+"-"+t.id},t.prototype.convertToKeyDict=function(t){var e=this,n={};return t.forEach((function(t){n[e.getKey(t)]=t})),n},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Qet=function(){return function(){}}(),$et=function(t){function e(e){var n=t.call(this)||this;return n.datum=e,n}return zQ(e,t),e}(Qet),Jet=function(t){function e(e){var n=t.call(this)||this;return n.datum=e,n}return zQ(e,t),e}(Qet),tnt=function(t){function e(e){var n=t.call(this)||this;return n.datum=e,n}return zQ(e,t),e}(Qet),ent=function(){function t(){this.start=new Uc,this.drag=new Uc,this.end=new Uc}return t.prototype.call=function(t){t.call(this.behaviour())},t.prototype.behaviour=function(){var t,e,n,i=this;return AO().on("start",(function(r){e=jw.sourceEvent.clientX,n=jw.sourceEvent.clientY,(t=new $et(r)).dx=jw.dx,t.dy=jw.dy,t.x=jw.x,t.y=jw.y,i.start.emit(t)})).on("drag",(function(t){var r=new Jet(t);r.dx=jw.sourceEvent.clientX-e,r.dy=jw.sourceEvent.clientY-n,e=jw.sourceEvent.clientX,n=jw.sourceEvent.clientY,i.drag.emit(r)})).on("end",(function(e){var n=new tnt(e);n.dx=jw.x-t.x,n.dy=jw.y-t.y,i.end.emit(n)}))},t}(),nnt=function(){function t(){this.isReadOnly=!1}return t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),int=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e}(function(){return function(t,e,n){this.datum=t,this.dx=e,this.dy=n}}()),rnt=function(){return function(t,e,n,i,r){this.datum=t,this.x=e,this.y=n,this.width=i,this.height=r}}(),ont=function(){return function(t,e){this.x=t,this.y=e}}(),ant=function(){return function(t,e,n){this.datum=t,this.x=e,this.y=n}}(),snt=function(){return function(t,e,n){this.savedText=t,this.x=e,this.y=n}}(),cnt=function(){return function(t,e,n){this.textDrawingId=t,this.editedText=e,this.textElement=n}}(),lnt=function(){return function(t,e){this.event=t,this.drawing=e}}(),unt=function(){return function(t,e){this.event=t,this.link=e}}(),hnt=function(){return function(t,e){this.event=t,this.interfaceLabel=e}}(),dnt=function(){return function(t,e){this.event=t,this.label=e}}(),fnt=function(){function t(t,e,n,i){this.cssFixer=t,this.fontFixer=e,this.selectionManager=n,this.mapSettings=i,this.onContextMenu=new Uc,this.draggable=new ent}return t.prototype.redrawLabel=function(t,e){this.drawLabel(this.selectLabel(t,e))},t.prototype.draw=function(t){var e=this,n=t.selectAll("g.label_container").data((function(t){return[t.label]})),i=n.enter().append("g").attr("class","label_container").attr("label_id",(function(t){return t.id})),r=n.merge(i).on("contextmenu",(function(t,n){event.preventDefault(),e.onContextMenu.emit(new dnt(event,t))}));this.drawLabel(r),n.exit().remove(),this.mapSettings.isReadOnly||this.draggable.call(n)},t.prototype.drawLabel=function(t){var e=this,n=t.selectAll("g.label_body").data((function(t){return[t]})),i=n.enter().append("g").attr("class","label_body");i.append("text").attr("class","label"),i.append("rect").attr("class","label_selection");var r=n.merge(i);r.select("text.label").attr("label_id",(function(t){return t.id})).attr("style",(function(t){var n=e.cssFixer.fix(t.style);return e.fontFixer.fixStyles(n)})).text((function(t){return t.text})).attr("x",(function(t){return t.x})).attr("y",(function(t){return t.y})).attr("transform",(function(t){return"rotate("+t.rotation+", "+t.x+", "+t.y+")"})),r.select("rect.label_selection").attr("visibility",(function(t){return e.selectionManager.isSelected(t)?"visible":"hidden"})).attr("stroke","black").attr("stroke-dasharray","3,3").attr("stroke-width","0.5").attr("fill","none").each((function(t){var e=Ww(this),n=r.select('text[label_id="'+t.id+'"]').node().getBBox();e.attr("width",n.width+4),e.attr("height",n.height+4),e.attr("x",n.x-2),e.attr("y",n.y-2),e.attr("transform","rotate("+t.rotation+", "+t.x+", "+t.y+")")}))},t.prototype.selectLabel=function(t,e){return t.selectAll('g.label_container[label_id="'+e.id+'"]')},t.NODE_LABEL_MARGIN=3,t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Oet),_t(X9),_t(Zet),_t(nnt))}}),t}(),pnt=function(){function t(){this.dragged=new Uc,this.labelDragged=new Uc,this.clicked=new Uc}return t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),mnt=function(){function t(t,e,n,i,r){this.graphDataManager=t,this.selectionManager=e,this.labelWidget=n,this.nodesEventSource=i,this.mapSettingsService=r,this.onContextMenu=new Uc,this.onNodeClicked=new Uc}return t.prototype.draw=function(t){var e=this,n=this,i=t.selectAll("g.node_body").data((function(t){return[t]})),r=i.enter().append("g").attr("class","node_body");r.append("image");var o=i.merge(r).classed("selected",(function(t){return e.selectionManager.isSelected(t)})).on("click",(function(t){e.nodesEventSource.clicked.emit(new ant(t,jw.pageX,jw.pageY))}));o.select(".layer_label_wrapper").remove(),this.mapSettingsService.isLayerNumberVisible&&o.append("rect").attr("class","layer_label_wrapper").attr("width","26").attr("height","26").attr("x",(function(t){return t.width/2-13})).attr("y",(function(t){return t.height/2-13})).attr("fill","red"),o.select(".layer_label").remove(),this.mapSettingsService.isLayerNumberVisible&&o.append("text").attr("class","layer_label").text((function(t){return t.z})).attr("x",(function(t){return t.z>=100?t.width/2-13:t.z>=10?t.width/2-9:t.width/2-5})).attr("y",(function(t){return t.height/2+5})).attr("style",(function(){var t=[];return t.push('font-family: "Noto Sans"'),t.push("font-size: 11pt"),t.push("font-weight: bold"),t.join("; ")})).attr("fill","#ffffff"),o.select("image").on("contextmenu",(function(t,e){jw.preventDefault(),n.onContextMenu.emit(new wet(jw,t))})).attr("xnode:href",(function(t){return t.symbolUrl})).attr("width",(function(t){return"cloud"===t.nodeType||"nat"===t.nodeType?120:t.width?t.width>64?64:t.width:60})).attr("height",(function(t){return"cloud"===t.nodeType||"nat"===t.nodeType?60:t.height?t.height>64?64:t.height:60})).attr("x",(function(t){return 0})).attr("y",(function(t){return 0})).on("mouseover",(function(t){Ww(this).attr("class","over")})).on("mouseout",(function(t){Ww(this).attr("class","")})),o.attr("transform",(function(t){return"translate("+t.x+","+t.y+")"})),this.labelWidget.draw(o)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Yet),_t(Zet),_t(fnt),_t(pnt),_t($8))}}),t}(),gnt=function(){function t(t){this.fontFixer=t}return t.prototype.draw=function(e){var n=this,i=e.selectAll("text.text_element").data((function(t){return t.element&&t.element instanceof z0?[t.element]:[]})),r=i.enter().append("text").attr("class","text_element noselect"),o=i.merge(r);o.attr("style",(function(t){var e=n.fontFixer.fix(t),i=[];return e.font_family&&i.push('font-family: "'+t.font_family+'"'),e.font_size&&i.push("font-size: "+t.font_size+"pt"),e.font_weight&&i.push("font-weight: "+t.font_weight),i.join("; ")})).attr("fill",(function(t){return t.fill})).attr("text-decoration",(function(t){return t.text_decoration}));var a=o.selectAll("tspan").data((function(t){return t.text.split(/\r?\n/)})),s=a.enter().append("tspan");a.merge(s).text((function(t){return t})).attr("xml:space","preserve").attr("x",0).attr("dy",(function(t,e){return 0===e?"0em":"1.4em"})),a.exit().remove(),o.attr("transform",(function(){var e=Ww(this).selectAll("tspan"),n=this.getBBox().height/e.size();return"translate("+t.MARGIN+", "+(n-t.MARGIN)+")"})),i.exit().remove()},t.MARGIN=4,t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(X9))}}),t}(),vnt=function(){function t(){}return t.prototype.draw=function(t){var e=t.selectAll("image.image_element").data((function(t){return t.element&&t.element instanceof g9?[t.element]:[]})),n=e.enter().append("image").attr("class","image_element noselect");e.merge(n).attr("xlink:href",(function(t){return t.data})).attr("width",(function(t){return t.width})).attr("height",(function(t){return t.height})),e.exit().remove()},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),bnt=function(){function t(){}return t.prototype.fix=function(e){return e in t.MAPPING?t.MAPPING[e]:e},t.MAPPING={"25, 25":"10, 2","5, 25":"4, 2","5, 25, 25":"5, 5, 1, 5","25, 25, 5, 25, 5":"5, 2, 5, 2, 5"},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),ynt=function(){function t(t){this.qtDasharrayFixer=t}return t.prototype.draw=function(t){var e=this,n=t.selectAll("rect.rect_element").data((function(t){return t.element&&t.element instanceof b9?[t.element]:[]}));n.enter().append("line").attr("class","top"),n.enter().append("line").attr("class","bottom"),n.enter().append("line").attr("class","right"),n.enter().append("line").attr("class","left");var i=n.enter().append("rect").attr("class","rect_element noselect");n.merge(i).attr("fill",(function(t){return t.fill})).attr("fill-opacity",(function(t){return t.fill_opacity})).attr("stroke",(function(t){return t.stroke})).attr("stroke-width",(function(t){return t.stroke_width})).attr("stroke-dasharray",(function(t){return e.qtDasharrayFixer.fix(t.stroke_dasharray)})).attr("width",(function(t){return t.width})).attr("height",(function(t){return t.height})),n.exit().remove()},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(bnt))}}),t}(),_nt=function(){function t(t){this.qtDasharrayFixer=t}return t.prototype.draw=function(t){var e=this,n=t.selectAll("line.line_element").data((function(t){return t.element&&t.element instanceof _9?[t.element]:[]}));n.enter().append("circle").attr("class","right"),n.enter().append("circle").attr("class","left");var i=n.enter().append("line").attr("class","line_element noselect");n.merge(i).attr("stroke",(function(t){return t.stroke})).attr("stroke-width",(function(t){return t.stroke_width})).attr("stroke-dasharray",(function(t){return e.qtDasharrayFixer.fix(t.stroke_dasharray)})).attr("x1",(function(t){return t.x1})).attr("x2",(function(t){return t.x2})).attr("y1",(function(t){return t.y1})).attr("y2",(function(t){return t.y2})),n.exit().remove()},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(bnt))}}),t}(),wnt=function(){function t(t){this.qtDasharrayFixer=t}return t.prototype.draw=function(t){var e=this,n=t.selectAll("ellipse.ellipse_element").data((function(t){return t.element&&t.element instanceof k9?[t.element]:[]}));n.enter().append("line").attr("class","top"),n.enter().append("line").attr("class","bottom"),n.enter().append("line").attr("class","right"),n.enter().append("line").attr("class","left");var i=n.enter().append("ellipse").attr("class","ellipse_element noselect");n.merge(i).attr("fill",(function(t){return t.fill})).attr("fill-opacity",(function(t){return t.fill_opacity})).attr("stroke",(function(t){return t.stroke})).attr("stroke-width",(function(t){return t.stroke_width})).attr("stroke-dasharray",(function(t){return e.qtDasharrayFixer.fix(t.stroke_dasharray)})).attr("cx",(function(t){return t.cx})).attr("cy",(function(t){return t.cy})).attr("rx",(function(t){return t.rx})).attr("ry",(function(t){return t.ry})),n.exit().remove()},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(bnt))}}),t}(),knt=function(){function t(t,e,n,i,r,o,a){this.textDrawingWidget=t,this.imageDrawingWidget=e,this.rectDrawingWidget=n,this.lineDrawingWidget=i,this.ellipseDrawingWidget=r,this.selectionManager=o,this.mapSettingsService=a,this.drawingWidgets=[],this.drawingWidgets=[this.textDrawingWidget,this.imageDrawingWidget,this.rectDrawingWidget,this.lineDrawingWidget,this.ellipseDrawingWidget]}return t.prototype.draw=function(t){var e=this,n=t.selectAll("g.drawing_body").data((function(t){return[t]})),i=n.enter().append("g").attr("class","drawing_body"),r=n.merge(i).attr("transform",(function(t){return"translate("+t.x+","+t.y+") rotate("+t.rotation+")"}));this.drawingWidgets.forEach((function(t){t.draw(r)})),r.select(".layer_label_wrapper").remove(),this.mapSettingsService.isLayerNumberVisible&&r.filter((function(t){return t.element instanceof b9||t.element instanceof k9})).append("rect").attr("class","layer_label_wrapper").attr("width","26").attr("height","26").attr("x",(function(t){return t.element?t.element.width/2-13:0})).attr("y",(function(t){return t.element?t.element.height/2-13:0})).attr("fill","red"),r.select(".layer_label").remove(),this.mapSettingsService.isLayerNumberVisible&&r.filter((function(t){return t.element instanceof b9||t.element instanceof k9})).append("text").attr("class","layer_label").text((function(t){return t.z})).attr("x",(function(t){return t.z>=100?t.element?t.element.width/2-13:0:t.z>=10?t.element?t.element.width/2-9:0:t.element.width/2-5})).attr("y",(function(t){return t.element?t.element.height/2+5:0})).attr("style",(function(){var t=[];return t.push('font-family: "Noto Sans"'),t.push("font-size: 11pt"),t.push("font-weight: bold"),t.join("; ")})).attr("fill","#ffffff"),r.select("line.top").attr("stroke","transparent").attr("stroke-width","8px").attr("x1",(function(t){return t.element instanceof k9?t.element.cx-t.element.width/10:"0"})).attr("x2",(function(t){return t.element instanceof k9?t.element.cx+t.element.width/10:t.element.width})).attr("y1","0").attr("y2","0").attr("draggable","true").attr("cursor","ns-resize"),r.select("line.bottom").attr("stroke","transparent").attr("stroke-width","8px").attr("x1",(function(t){return t.element instanceof k9?t.element.cx-t.element.width/10:"0"})).attr("x2",(function(t){return t.element instanceof k9?t.element.cx+t.element.width/10:t.element.width})).attr("y1",(function(t){return t.element.height})).attr("y2",(function(t){return t.element.height})).attr("draggable","true").attr("cursor","ns-resize"),r.select("line.right").attr("stroke","transparent").attr("stroke-width","8px").attr("x1","0").attr("x2","0").attr("y1",(function(t){return t.element instanceof k9?t.element.cy-t.element.height/10:"0"})).attr("y2",(function(t){return t.element instanceof k9?t.element.cy+t.element.height/10:t.element.height})).attr("draggable","true").attr("cursor","ew-resize"),r.select("line.left").attr("stroke","transparent").attr("stroke-width","8px").attr("x1",(function(t){return t.element.width})).attr("x2",(function(t){return t.element.width})).attr("y1",(function(t){return t.element instanceof k9?t.element.cy-t.element.height/10:"0"})).attr("y2",(function(t){return t.element instanceof k9?t.element.cy+t.element.height/10:t.element.height})).attr("draggable","true").attr("cursor","ew-resize"),r.select("circle.left").attr("draggable","true").attr("fill","transparent").attr("stroke","transparent").attr("cx",(function(t){return t.element.x1})).attr("cy",(function(t){return t.element.y1})).attr("r",10).attr("cursor","move"),r.select("circle.right").attr("draggable","true").attr("fill","transparent").attr("stroke","transparent").attr("cx",(function(t){return t.element.x2})).attr("cy",(function(t){return t.element.y2})).attr("r",10).attr("cursor","move"),r.classed("drawing_selected",(function(t){return e.selectionManager.isSelected(t)}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(gnt),_t(vnt),_t(ynt),_t(_nt),_t(wnt),_t(Zet),_t($8))}}),t}(),Cnt=function(){return function(t,e){this.width=t,this.height=e}}(),Snt=function(){return function(t,e){this.x=t,this.y=e}}(),xnt=function(){return function(t,e,n){this.x=t,this.y=e,this.k=n}}(),Ont=function(){function t(){this.centerZeroZeroPoint=!0,this.size=new Cnt(0,0),this.transformation=new xnt(0,0,1)}return t.prototype.getZeroZeroTransformationPoint=function(){return this.centerZeroZeroPoint?new Snt(this.size.width/2,this.size.height/2):new Snt(0,0)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Mnt=function(){return function(){}}(),Tnt=function(){function t(t,e,n,i){this.drawingWidget=t,this.svgToDrawingConverter=e,this.context=n,this.mapSettings=i,this.draggable=new ent,this.draggingEnabled=!1,this.resizingFinished=new Uc,this.onContextMenu=new Uc,this.svgToDrawingConverter=new S9}return t.prototype.redrawDrawing=function(t,e){this.drawingWidget.draw(this.selectDrawing(t,e))},t.prototype.draw=function(t){var e,n,i,r,o=this,a=t.selectAll("g.drawing").data((function(t){return t.drawings.forEach((function(t){try{t.element=o.svgToDrawingConverter.convert(t.svg)}catch(e){console.log("Cannot convert due to Error: '"+e+"'")}})),t.drawings}),(function(t){return t.id})),s=a.enter().append("g").attr("class","drawing").attr("drawing_id",(function(t){return t.id})).on("contextmenu",(function(t){jw.preventDefault(),o.onContextMenu.emit(new lnt(jw,t))})),c=a.merge(s);this.drawingWidget.draw(c),a.exit().remove(),this.mapSettings.isReadOnly||this.draggable.call(c);var l,u,h,d,f=!1,p=AO().on("start",(function(t){document.body.style.cursor="ns-resize",i=t.y})).on("drag",(function(r){var a=jw;f?(n=e-(a.sourceEvent.pageY-(o.context.getZeroZeroTransformationPoint().y+o.context.transformation.y)),e=a.sourceEvent.pageY-(o.context.getZeroZeroTransformationPoint().y+o.context.transformation.y),r.element.height+n<0?(f=!1,e=i,r.element.height=Math.abs(r.element.height+a.dy)):(r.y=a.sourceEvent.pageY-(o.context.getZeroZeroTransformationPoint().y+o.context.transformation.y),r.element.height+=n,r.element instanceof k9&&(r.element.cy=r.element.cy+n/2<0?1:r.element.cy+=n/2,r.element.ry=r.element.ry+n/2<0?1:r.element.ry+=n/2))):r.element.height+a.dy<0?(f=!0,e=i,r.element.height=Math.abs(r.element.height+a.dy)):(r.element.height+=a.dy,r.element instanceof k9&&(r.element.cy=r.element.cy+a.dy/2<0?1:r.element.cy+=a.dy/2,r.element.ry=r.element.ry+a.dy/2<0?1:r.element.ry+=a.dy/2)),o.redrawDrawing(t,r)})).on("end",(function(t){document.body.style.cursor="initial",o.resizingFinished.emit(o.createResizingEvent(t))})),m=AO().on("start",(function(t){e=jw.sourceEvent.pageY-(o.context.getZeroZeroTransformationPoint().y+o.context.transformation.y),r=e+t.element.height,document.body.style.cursor="ns-resize"})).on("drag",(function(i){var a=jw;f?i.element.height+a.dy<0?(f=!1,e=r,i.element.height=Math.abs(i.element.height+a.dy)):(i.element.height+=a.dy,i.element instanceof k9&&(i.element.cy=i.element.cy+a.dy/2<0?1:i.element.cy+=a.dy/2,i.element.ry=i.element.ry+a.dy/2<0?1:i.element.ry+=a.dy/2)):(n=e-(a.sourceEvent.pageY-(o.context.getZeroZeroTransformationPoint().y+o.context.transformation.y)),e=a.sourceEvent.pageY-(o.context.getZeroZeroTransformationPoint().y+o.context.transformation.y),i.element.height+n<0?(e=r,f=!0,i.element.height=Math.abs(i.element.height+a.dy)):(i.y=a.sourceEvent.pageY-(o.context.getZeroZeroTransformationPoint().y+o.context.transformation.y),i.element.height+=n,i.element instanceof k9&&(i.element.cy=i.element.cy+n/2<0?1:i.element.cy+=n/2,i.element.ry=i.element.ry+n/2<0?1:i.element.ry+=n/2))),o.redrawDrawing(t,i)})).on("end",(function(t){document.body.style.cursor="initial",o.resizingFinished.emit(o.createResizingEvent(t))})),g=!1,v=AO().on("start",(function(t){l=jw.sourceEvent.pageX-(o.context.getZeroZeroTransformationPoint().x+o.context.transformation.x),d=l+t.element.width,document.body.style.cursor="ew-resize"})).on("drag",(function(e){var n=jw;g?e.element.width+n.dx<0?(l=d,g=!1,e.element.width=Math.abs(e.element.width+n.dx)):(e.element instanceof k9&&(e.element.cx=e.element.cx+n.dx/2<0?1:e.element.cx+=n.dx/2,e.element.rx=e.element.rx+n.dx/2<0?1:e.element.rx+=n.dx/2),e.element.width=e.element.width+n.dx<0?1:e.element.width+=n.dx):(u=l-(n.sourceEvent.pageX-(o.context.getZeroZeroTransformationPoint().x+o.context.transformation.x)),l=n.sourceEvent.pageX-(o.context.getZeroZeroTransformationPoint().x+o.context.transformation.x),e.element.width+u<0?(l=d,g=!0,e.element.width=Math.abs(e.element.width+n.dx)):(e.x=n.sourceEvent.pageX-(o.context.getZeroZeroTransformationPoint().x+o.context.transformation.x),e.element.width+=u,e.element instanceof k9&&(e.element.cx=e.element.cx+u/2<0?1:e.element.cx+=u/2,e.element.rx=e.element.rx+u/2<0?1:e.element.rx+=u/2))),o.redrawDrawing(t,e)})).on("end",(function(t){document.body.style.cursor="initial",o.resizingFinished.emit(o.createResizingEvent(t))})),b=AO().on("start",(function(t){document.body.style.cursor="ew-resize",h=t.x})).on("drag",(function(e){var n=jw;g?(u=l-(n.sourceEvent.pageX-(o.context.getZeroZeroTransformationPoint().x+o.context.transformation.x)),l=n.sourceEvent.pageX-(o.context.getZeroZeroTransformationPoint().x+o.context.transformation.x),e.element.width+u<0?(l=h,g=!1,e.element.width=Math.abs(e.element.width+n.dx)):(e.x=n.sourceEvent.pageX-(o.context.getZeroZeroTransformationPoint().x+o.context.transformation.x),e.element.width+=u,e.element instanceof k9&&(e.element.cx=e.element.cx+u/2<0?1:e.element.cx+=u/2,e.element.rx=e.element.rx+u/2<0?1:e.element.rx+=u/2))):e.element.width+n.dx<0?(l=h,g=!0,e.element.width=Math.abs(e.element.width+n.dx)):(e.element instanceof k9&&(e.element.cx=e.element.cx+n.dx/2<0?1:e.element.cx+=n.dx/2,e.element.rx=e.element.rx+n.dx/2<0?1:e.element.rx+=n.dx/2),e.element.width=e.element.width+n.dx<0?1:e.element.width+=n.dx),o.redrawDrawing(t,e)})).on("end",(function(t){document.body.style.cursor="initial",o.resizingFinished.emit(o.createResizingEvent(t))})),y=AO().on("start",(function(){document.body.style.cursor="move"})).on("drag",(function(e){var n=jw;e.element.width+=n.dx,e.element.height+=n.dy,e.element.x2+=n.dx,e.element.y2+=n.dy,o.redrawDrawing(t,e)})).on("end",(function(t){document.body.style.cursor="initial",o.resizingFinished.emit(o.createResizingEvent(t))})),_=AO().on("start",(function(){document.body.style.cursor="move"})).on("drag",(function(e){var n=jw;e.element.width+=n.dx,e.element.height+=n.dy,e.element.x1+=n.dx,e.element.y1+=n.dy,o.redrawDrawing(t,e)})).on("end",(function(t){document.body.style.cursor="initial",o.resizingFinished.emit(o.createResizingEvent(t))}));c.select("line.bottom").call(p),c.select("line.top").call(m),c.select("line.right").call(v),c.select("line.left").call(b),c.select("circle.right").call(y),c.select("circle.left").call(_)},t.prototype.createResizingEvent=function(t){var e=new Mnt;return e.x=t.x,e.y=t.y,e.width=t.element.width,e.height=t.element.height,e.datum=t,e},t.prototype.selectDrawing=function(t,e){return t.selectAll('g.drawing[drawing_id="'+e.id+'"]')},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(knt),_t(S9),_t(Ont),_t(nnt))}}),t}(),Ent=function(){function t(t,e,n){this.fontBBoxCalculator=t,this.cssFixer=e,this.fontFixer=n}return t.prototype.convert=function(t){var e=this.cssFixer.fix(t.style),n=this.fontFixer.fixStyles(e),i=this.fontBBoxCalculator.calculate(t.text,n),r=new Q9;return r.rotation=t.rotation,r.style=t.style,r.text=t.text,r.x=t.x,r.y=t.y,null!==r.x&&(r.x-=3),null!==r.y&&(r.y-=i.height),r},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(xet),_t(Oet),_t(X9))}}),t}(),Pnt=function(){return function(){}}(),Ant=function(){function t(){}return t.prototype.convert=function(t){var e=new Pnt;return e.adapter_number=t.adapterNumber,e.link_type=t.linkType,e.name=t.name,e.port_number=t.portNumber,e.short_name=t.shortName,e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),jnt=function(){function t(t,e){this.mapLabelToLabel=t,this.mapPortToPort=e}return t.prototype.convert=function(t){var e=this,n=new V0;return n.node_id=t.id,n.command_line=t.commandLine,n.compute_id=t.computeId,n.console=t.console,n.console_host=t.consoleHost,n.console_type=t.consoleType,n.first_port_name=t.firstPortName,n.height=t.height,n.label=t.label?this.mapLabelToLabel.convert(t.label):void 0,n.locked=t.locked,n.name=t.name,n.node_directory=t.nodeDirectory,n.node_type=t.nodeType,n.port_name_format=t.portNameFormat,n.port_segment_size=t.portSegmentSize,n.ports=t.ports?t.ports.map((function(t){return e.mapPortToPort.convert(t)})):[],n.project_id=t.projectId,n.status=t.status,n.symbol=t.symbol,n.symbol_url=t.symbolUrl,n.usage=t.usage,n.width=t.width,n.x=t.x,n.y=t.y,n.z=t.z,n},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Ent),_t(Ant))}}),t}(),Int=function(){function t(t,e){this.nodeWidget=t,this.mapSettings=e,this.draggable=new ent}return t.prototype.redrawNode=function(t,e){this.nodeWidget.draw(this.selectNode(t,e))},t.prototype.draw=function(t){var e=t.selectAll("g.node").data((function(t){return t.nodes?t.nodes:[]}),(function(t){return t.id})),n=e.enter().append("g").attr("class","node").attr("node_id",(function(t){return t.id})),i=e.merge(n);this.nodeWidget.draw(i),e.exit().remove(),this.mapSettings.isReadOnly||this.draggable.call(i)},t.prototype.selectNode=function(t,e){return t.selectAll('g.node[node_id="'+e.id+'"]')},t.NODE_LABEL_MARGIN=3,t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(mnt),_t(nnt))}}),t}(),Dnt=function(){return function(){}}(),Rnt=function(){function t(){this.drawingLine=new Dnt,this.drawing=!1,this.data={}}return t.prototype.start=function(t,e,n){var i=this;this.drawing=!0,this.data=n,this.drawingLine.start=new Snt(t,e),this.drawingLine.end=new Snt(t,e),this.selection.on("mousemove",(function(t,e){var n=i.selection.select("g.canvas").node(),r=Kk(n);i.drawingLine.end.x=r[0],i.drawingLine.end.y=r[1],i.draw(null,null)})),this.draw(null,null)},t.prototype.isDrawing=function(){return this.drawing},t.prototype.stop=function(){return this.drawing=!1,this.selection.on("mousemove",null),this.draw(null,null),this.data},t.prototype.connect=function(t,e){this.selection=t},t.prototype.draw=function(t,e){var n=this.selection.select("g.canvas");n.select("g.drawing-line-tool").node()||n.append("g").attr("class","drawing-line-tool");var i=[];this.drawing&&(i=[[[this.drawingLine.start.x,this.drawingLine.start.y],[this.drawingLine.end.x,this.drawingLine.end.y]]]);var r=Lz(),o=this.selection.select("g.drawing-line-tool").selectAll("path").data(i),a=o.enter().append("path");o.merge(a).attr("d",r).attr("stroke","#000").attr("stroke-width","2"),o.exit().remove()},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Lnt=function(){return function(t,e,n,i){this.x=t,this.y=e,this.width=n,this.height=i}}(),Fnt=function(){function t(){this.selected=new w.b}return t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Nnt=function(){function t(t,e){this.context=t,this.selectionEventSource=e,this.rectangleSelected=new w.b,this.contextMenuOpened=new Uc,this.enabled=!1}return t.prototype.disableContextMenu=function(){},t.prototype.setEnabled=function(t){this.enabled=t,this.contextMenuOpened.emit(!0)},t.prototype.activate=function(e){var n=this;e.on("mousedown",(function(){if(2==jw.button)return e.on("contextmenu",(function(){jw.preventDefault()})),void n.contextMenuOpened.emit(jw);var i=Ww(window),r=this.parentElement,o=n.transformation(Kk(r));n.startSelection(o),e.selectAll(t.SELECTABLE_CLASS).classed("selected",!1),i.on("mousemove.selection",(function(){var t=n.transformation(Kk(r));n.moveSelection(o,t)})).on("mouseup.selection",(function(){var t=n.transformation(Kk(r));n.endSelection(o,t),i.on("mousemove.selection",null).on("mouseup.selection",null)}))}))},t.prototype.deactivate=function(t){t.on("mousedown",null)},t.prototype.draw=function(t,e){var n=t.select("g.canvas");if(!n.select("g.selection-line-tool").node()){var i=n.append("g");i.attr("class","selection-line-tool"),this.path=i.append("path"),this.path.attr("class","selection").attr("visibility","hidden")}var r=n.select("g.selection-line-tool"),o=r.attr("status");"activated"!==o&&this.enabled&&(this.activate(t),r.attr("activated")),"deactivated"===o||this.enabled||(this.deactivate(t),r.attr("deactivated"))},t.prototype.startSelection=function(t){this.path.attr("d",this.rect(t[0],t[1],0,0)).attr("visibility","visible")},t.prototype.moveSelection=function(t,e){var n=t[0]/this.context.transformation.k,i=t[1]/this.context.transformation.k;this.path.attr("d",this.rect(n,i,e[0]/this.context.transformation.k-n,e[1]/this.context.transformation.k-i)),this.selectedEvent(t,e)},t.prototype.endSelection=function(t,e){this.path.attr("visibility","hidden"),this.selectedEvent(t,e)},t.prototype.selectedEvent=function(t,e){var n=Math.min(t[0],e[0]),i=Math.min(t[1],e[1]),r=Math.abs(t[0]-e[0]),o=Math.abs(t[1]-e[1]);this.selectionEventSource.selected.next(new Lnt(n,i,r,o))},t.prototype.rect=function(t,e,n,i){return"M"+[t,e]+" l"+[n,0]+" l"+[0,i]+" l"+[-n,0]+"z"},t.prototype.transformation=function(t){var e=this.context.getZeroZeroTransformationPoint();return[t[0]-e.x-this.context.transformation.x,t[1]-e.y-this.context.transformation.y]},t.SELECTABLE_CLASS=".selectable",t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Ont),_t(Fnt))}}),t}(),Bnt=function(){function t(t){this.context=t,this.enabled=!1,this.needsDeactivate=!1,this.needsActivate=!1,this.zoom=qK().scaleExtent([.5,8])}return t.prototype.setEnabled=function(t){this.enabled!=t&&(t?this.needsActivate=!0:this.needsDeactivate=!0),this.enabled=t},t.prototype.draw=function(t,e){this.needsActivate&&(this.activate(t),this.needsActivate=!1),this.needsDeactivate&&(this.deactivate(t),this.needsDeactivate=!1)},t.prototype.activate=function(t){var e=this;this.zoom.filter((function(){return"mousedown"===jw.type})),this.zoom.on("zoom",(function(){var n=t.select("g.canvas"),i=jw;n.attr("transform",(function(){return e.context.transformation.x=i.transform.x,e.context.transformation.y=i.transform.y,e.context.transformation.k=i.transform.k,"translate("+(e.context.getZeroZeroTransformationPoint().x+e.context.transformation.x)+", "+(e.context.getZeroZeroTransformationPoint().y+e.context.transformation.y)+") scale("+e.context.transformation.k+")"}))})),t.call(this.zoom)},t.prototype.deactivate=function(t){t.on("mousedown.zoom",null),this.zoom.on("zoom",null)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Ont))}}),t}(),Hnt=function(){return function(t,e,n,i){this.source=t,this.source_angle=e,this.target_angle=n,this.target=i}}(),znt=function(){function t(){this.onContextMenu=new Uc}return t.prototype.linkToSerialLink=function(t){var e={x:t.source.x+t.source.width/2,y:t.source.y+t.source.height/2},n={x:t.target.x+t.target.width/2,y:t.target.y+t.target.height/2},i=n.x-e.x,r=n.y-e.y,o=Math.atan2(r,i),a=-Math.PI/4,s=[Math.cos(o+a),Math.sin(o+a)];return new Hnt([e.x,e.y],[e.x+i/2+15*s[0],e.y+r/2+15*s[1]],[n.x-i/2-15*s[0],n.y-r/2-15*s[1]],[n.x,n.y])},t.prototype.draw=function(t){var e=this,n=t.selectAll("path.serial_link").data((function(t){return"serial"===t.linkType?[e.linkToSerialLink(t)]:[]})),i=n.enter().append("path").attr("class","serial_link").on("contextmenu",(function(t){var n=event;e.onContextMenu.emit(new unt(n,t))}));i.attr("stroke","#B22222").attr("fill","none").attr("stroke-width","2"),n.merge(i).attr("d",(function(t){var e=QS();return e.moveTo(t.source[0],t.source[1]),e.lineTo(t.source_angle[0],t.source_angle[1]),e.lineTo(t.target_angle[0],t.target_angle[1]),e.lineTo(t.target[0],t.target[1]),e.toString()}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Vnt=function(){return function(t,e){this.source=t,this.target=e}}(),Unt=function(){function t(){this.onContextMenu=new Uc}return t.prototype.linktoEthernetLink=function(t){return new Vnt([t.source.x+t.source.width/2,t.source.y+t.source.height/2],[t.target.x+t.target.width/2,t.target.y+t.target.height/2])},t.prototype.draw=function(t){var e=this,n=t.selectAll("path.ethernet_link").data((function(t){return"ethernet"===t.linkType?[e.linktoEthernetLink(t)]:[]})),i=n.enter().append("path").attr("class","ethernet_link").on("contextmenu",(function(t){var n=event;e.onContextMenu.emit(new unt(n,t))}));i.attr("stroke","#000").attr("stroke-width","2").on("contextmenu",(function(t){var n=event;e.onContextMenu.emit(new unt(n,t))})),n.merge(i).attr("d",(function(t){var e=QS();return e.moveTo(t.source[0],t.source[1]),e.lineTo(t.target[0],t.target[1]),e.toString()}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),qnt=function(){function t(t,e,n,i){this.cssFixer=t,this.fontFixer=e,this.selectionManager=n,this.mapSettings=i,this.onContextMenu=new Uc,this.draggable=new ent,this.enabled=!0}return t.prototype.setEnabled=function(t){this.enabled=t},t.prototype.draw=function(t){var e=this,n=this,i=t.selectAll("g.link_node_position").data((function(t){return[[t.source,t.nodes[0]],[t.target,t.nodes[1]]]})),r=i.enter().append("g").classed("link_node_position",!0),o=i.merge(r);o.attr("transform",(function(t){return"translate("+t[0].x+", "+t[0].y+")"}));var a=o.selectAll("g.interface_label_container").data((function(t){return e.enabled?[t[1]]:[]})),s=a.enter().append("g").classed("interface_label_container",!0);s.append("rect").attr("class","interface_label_selection"),s.append("text").attr("class","interface_label noselect").attr("interface_label_id",(function(t){return""+t.id}));var c=a.merge(s).on("contextmenu",(function(t,e){event.preventDefault(),n.onContextMenu.emit(new hnt(event,t))}));c.select("text.interface_label").text((function(t){return t.label.text})).attr("style",(function(t){var n=e.cssFixer.fix(t.label.style);return e.fontFixer.fixStyles(n)})).attr("x",(function(t){return t.label.x})).attr("y",(function(t){return t.label.y})).attr("transform",(function(t){return"rotate("+t.label.rotation+", "+t.label.x+", "+t.label.y+")"})),c.select("rect.interface_label_selection").attr("visibility",(function(t){return e.selectionManager.isSelected(t)?"visible":"hidden"})).attr("stroke","black").attr("stroke-dasharray","3,3").attr("stroke-width","0.5").attr("fill","none").each((function(t){var e=Ww(this),n=c.select('text[interface_label_id="'+t.id+'"]').node().getBBox();e.attr("width",n.width+4),e.attr("height",n.height+4),e.attr("x",n.x-2),e.attr("y",n.y-2),e.attr("transform","rotate("+t.label.rotation+", "+(n.x-2)+", "+(n.y-2)+")")})),a.exit().remove(),this.mapSettings.isReadOnly||this.draggable.call(c)},t.SURROUNDING_TEXT_BORDER=5,t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Oet),_t(X9),_t(Zet),_t(nnt))}}),t}(),Gnt=function(){return function(t,e,n,i){this.x=t,this.y=e,this.status=n,this.port=i}}(),Wnt=function(){function t(t){this._mapSettingsService=t,this.mapSettingsService=t}return t.prototype.draw=function(t){var e=this,n=[];t.each((function(t){n.push(t)})),n.forEach((function(t){n.forEach((function(e){e.nodes[0].linkId!==t.nodes[0].linkId&&(t.nodes[0].nodeId===e.nodes[0].nodeId&&t.nodes[1].nodeId===e.nodes[1].nodeId||t.nodes[0].nodeId===e.nodes[1].nodeId&&t.nodes[1].nodeId===e.nodes[0].nodeId||t.nodes[1].nodeId===e.nodes[0].nodeId&&t.nodes[0].nodeId===e.nodes[1].nodeId)&&(t.isMultiplied=!0)}))})),t.each((function(t){var n=Ww(this),i=n.select("path"),r=[];if(i.node()){var o=i.node().getPointAtLength(80),a=i.node().getPointAtLength(i.node().getTotalLength()-80);if(i.node().getTotalLength()>220&&t.source&&t.target){var s=t.nodes.find((function(e){return e.nodeId===t.source.id})).label.text,c=t.nodes.find((function(e){return e.nodeId===t.target.id})).label.text;r=[new Gnt(o.x,o.y,t.capturing&&t.suspend?"suspended":t.source.status,s),new Gnt(a.x,a.y,t.capturing&&t.suspend?"suspended":t.target.status,c)]}}if(n.selectAll("circle.status_started").remove(),n.selectAll("circle.status_stopped").remove(),n.selectAll("circle.status_suspended").remove(),n.selectAll("rect.status_started").remove(),n.selectAll("text.status_started_label").remove(),n.selectAll("rect.status_stopped").remove(),n.selectAll("text.status_stopped_label").remove(),n.selectAll("rect.status_suspended").remove(),n.selectAll("text.status_suspended_label").remove(),e.mapSettingsService.showInterfaceLabels&&e.mapSettingsService.integrateLinkLabelsToLinks&&!t.isMultiplied){var l=(b=n.selectAll("rect.status_started").data(r.filter((function(t){return"started"===t.status})))).enter().append("rect");b.merge(l).attr("class","status_started").attr("width",(function(t){return 8*t.port.length+10})).attr("height",20).attr("x",(function(t){return t.x-30})).attr("y",(function(t){return t.y-10})).attr("rx",8).attr("ry",8).style("fill","white").attr("stroke","#2ecc71").attr("stroke-width",3),b.exit().remove();var u=n.selectAll("text.status_started_label").data(r.filter((function(t){return"started"===t.status}))),h=u.enter().append("text");u.merge(h).attr("class","status_started_label").text((function(t){return t.port})).attr("x",(function(t){return t.x-25})).attr("y",(function(t){return t.y+5})).attr("fill","black"),u.exit().remove();var d=(y=n.selectAll("rect.status_stopped").data(r.filter((function(t){return"stopped"===t.status})))).enter().append("rect");y.merge(d).attr("class","status_stopped").attr("width",(function(t){return 8*t.port.length+10})).attr("height",20).attr("x",(function(t){return t.x-30})).attr("y",(function(t){return t.y-10})).attr("rx",8).attr("ry",8).style("fill","white").attr("stroke","red").attr("stroke-width",3),y.exit().remove();var f=n.selectAll("text.status_stopped_label").data(r.filter((function(t){return"stopped"===t.status}))),p=f.enter().append("text");f.merge(p).attr("class","status_stopped_label").text((function(t){return t.port})).attr("x",(function(t){return t.x-25})).attr("y",(function(t){return t.y+5})).attr("fill","black"),f.exit().remove();var m=(_=n.selectAll("rect.status_suspended").data(r.filter((function(t){return"suspended"===t.status})))).enter().append("rect");_.merge(m).attr("class","status_suspended").attr("width",(function(t){return 8*t.port.length+10})).attr("height",20).attr("x",(function(t){return t.x-30})).attr("y",(function(t){return t.y-10})).attr("rx",8).attr("ry",8).style("fill","white").attr("stroke","#FFFF00").attr("stroke-width",3),_.exit().remove();var g=n.selectAll("text.status_suspended_label").data(r.filter((function(t){return"suspended"===t.status}))),v=g.enter().append("text");g.merge(v).attr("class","status_suspended_label").text((function(t){return t.port})).attr("x",(function(t){return t.x-25})).attr("y",(function(t){return t.y+5})).attr("fill","black"),g.exit().remove()}else{var b,y,_;l=(b=n.selectAll("circle.status_started").data(r.filter((function(t){return"started"===t.status})))).enter().append("circle"),b.merge(l).attr("class","status_started").attr("cx",(function(t){return t.x})).attr("cy",(function(t){return t.y})).attr("r",6).attr("text",(function(t){return t.port})).attr("fill","#2ecc71"),b.exit().remove(),d=(y=n.selectAll("rect.status_stopped").data(r.filter((function(t){return"stopped"===t.status})))).enter().append("rect"),y.merge(d).attr("class","status_stopped").attr("x",(function(t){return t.x-5})).attr("y",(function(t){return t.y-5})).attr("width",10).attr("height",10).attr("fill","red"),y.exit().remove(),m=(_=n.selectAll("circle.status_suspended").data(r.filter((function(t){return"suspended"===t.status})))).enter().append("circle"),_.merge(m).attr("class","status_suspended").attr("cx",(function(t){return t.x})).attr("cy",(function(t){return t.y})).attr("r",6).attr("fill","#FFFF00"),_.exit().remove()}}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t($8))}}),t}(),Knt=function(){function t(t,e,n,i,r,o){this.multiLinkCalculatorHelper=t,this.interfaceLabelWidget=e,this.interfaceStatusWidget=n,this.selectionManager=i,this.ethernetLinkWidget=r,this.serialLinkWidget=o,this.onContextMenu=new Uc}return t.prototype.draw=function(t){var e=this,n=t.selectAll("g.link_body").data((function(t){return[t]})),i=n.enter().append("g").attr("class","link_body"),r=n.merge(i).attr("transform",(function(t){var n=e.multiLinkCalculatorHelper.linkTranslation(t.distance,t.source,t.target);return"translate ("+n.dx+", "+n.dy+")"}));n.select(".capture-icon").remove(),n.filter((function(t){return t.capturing&&!t.suspend&&!(t.filters.bpf||t.filters.corrupt||t.filters.delay||t.filters.frequency_drop||t.filters.packet_loss)})).append("g").on("contextmenu",(function(t){e.onContextMenu.emit(new unt(jw,t))})).attr("class","capture-icon").attr("transform",(function(t){return"translate ("+((t.source.x+t.target.x)/2+24)+", "+((t.source.y+t.target.y)/2+24)+") scale(0.5)"})).attr("viewBox","0 0 20 20").append("image").attr("xlink:href","assets/resources/images/inspect.svg"),n.select(".filter-capture-icon").remove(),n.filter((function(t){return t.capturing&&!t.suspend&&(t.filters.bpf||t.filters.corrupt||t.filters.delay||t.filters.frequency_drop||t.filters.packet_loss)})).append("g").on("contextmenu",(function(t){e.onContextMenu.emit(new unt(jw,t))})).attr("class","filter-capture-icon").attr("transform",(function(t){return"translate ("+((t.source.x+t.target.x)/2+24)+", "+((t.source.y+t.target.y)/2+24)+") scale(0.5)"})).attr("viewBox","0 0 20 20").append("image").attr("xlink:href","assets/resources/images/filter-capture.svg"),n.select(".filter-icon").remove(),n.filter((function(t){return!t.capturing&&(t.filters.bpf||t.filters.corrupt||t.filters.delay||t.filters.frequency_drop||t.filters.packet_loss)})).append("g").on("contextmenu",(function(t){e.onContextMenu.emit(new unt(jw,t))})).attr("class","filter-icon").attr("width","48px").attr("height","48px").attr("transform",(function(t){return"translate ("+((t.source.x+t.target.x)/2+24)+", "+((t.source.y+t.target.y)/2+24)+") scale(0.5)"})).attr("viewBox","0 0 20 20").append("image").attr("width","48px").attr("height","48px").attr("xlink:href","assets/resources/images/filter.svg"),n.select(".pause-icon").remove(),n.filter((function(t){return t.capturing&&t.suspend&&!(t.filters.bpf||t.filters.corrupt||t.filters.delay||t.filters.frequency_drop||t.filters.packet_loss)})).append("g").on("contextmenu",(function(t){e.onContextMenu.emit(new unt(jw,t))})).attr("class","pause-icon").attr("transform",(function(t){return"translate ("+((t.source.x+t.target.x)/2+24)+", "+((t.source.y+t.target.y)/2+24)+") scale(0.5)"})).attr("viewBox","0 0 20 20").append("image").attr("xlink:href","assets/resources/images/pause.svg"),this.serialLinkWidget.draw(r),this.ethernetLinkWidget.draw(r),r.select("path").classed("selected",(function(t){return e.selectionManager.isSelected(t)})),this.interfaceLabelWidget.draw(r),this.interfaceStatusWidget.draw(r)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Xet),_t(qnt),_t(Wnt),_t(Zet),_t(Unt),_t(znt))}}),t}(),Xnt=function(){function t(t,e){this.multiLinkCalculatorHelper=t,this.linkWidget=e}return t.prototype.redrawLink=function(t,e){this.linkWidget.draw(this.selectLink(t,e))},t.prototype.draw=function(t){var e=this,n=t.selectAll("g.link").data((function(t){if(t.links){var n=t.links.filter((function(t){return t.target&&t.source}));return e.multiLinkCalculatorHelper.assignDataToLinks(n),n}return[]}),(function(t){return t.id})),i=n.enter().append("g").attr("class","link").attr("link_id",(function(t){return t.id})).attr("map-source",(function(t){return t.source.id})).attr("map-target",(function(t){return t.target.id})),r=n.merge(i);this.linkWidget.draw(r),n.exit().remove()},t.prototype.selectLink=function(t,e){return t.selectAll('g.link[link_id="'+e.id+'"]')},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Xet),_t(Knt))}}),t}(),Ynt=function(){function t(t,e,n){this.linksWidget=t,this.nodesWidget=e,this.drawingsWidget=n}return t.prototype.draw=function(t,e){var n=t.selectAll("g.layer").data(e,(function(t){return t.index.toString()})),i=n.enter().append("g").attr("class","layer");i.append("g").attr("class","links"),i.append("g").attr("class","nodes"),i.append("g").attr("class","drawings");var r=n.merge(i);r.attr("data-index",(function(t){return t.index}));var o=r.select("g.links"),a=r.select("g.nodes"),s=r.select("g.drawings");n.exit().remove(),this.linksWidget.draw(o),this.nodesWidget.draw(a),this.drawingsWidget.draw(s)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Xnt),_t(Int),_t(Tnt))}}),t}(),Znt=function(){function t(t,e,n,i,r,o){this.nodesWidget=t,this.drawingLineTool=e,this.selectionTool=n,this.movingTool=i,this.layersWidget=r,this.layersManager=o}return t.prototype.getNodesWidget=function(){return this.nodesWidget},t.prototype.getDrawingLineTool=function(){return this.drawingLineTool},t.prototype.getSelectionTool=function(){return this.selectionTool},t.prototype.connect=function(t,e){this.drawingLineTool.connect(t,e)},t.prototype.draw=function(t,e){t.attr("width",e.size.width).attr("height",e.size.height);var n=t.selectAll("g.canvas").data([e]),i=n.enter().append("g").attr("class","canvas");n.merge(i).attr("transform",(function(t){return"translate("+(t.getZeroZeroTransformationPoint().x+t.transformation.x)+", "+(t.getZeroZeroTransformationPoint().y+t.transformation.y)+") scale("+t.transformation.k+")"})),this.layersWidget.draw(n,this.layersManager.getLayersList()),this.drawingLineTool.draw(t,e),this.selectionTool.draw(t,e),this.movingTool.draw(t,e)},t.prototype.disconnect=function(t){t.empty&&!t.empty()&&t.selectAll("*").remove()},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Int),_t(Rnt),_t(Nnt),_t(Bnt),_t(Ynt),_t(Net))}}),t}(),Qnt=function(){function t(){}return t.prototype.getOptimalSize=function(t,e){var n=document.documentElement.clientWidth,i=document.documentElement.clientHeight;return t>n&&(n=t),e>i&&(i=e),new Cnt(n,i)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),$nt=function(){function t(){this.isSelectionToolActivated=new w.b,this.isMovingToolActivated=new w.b,this.isTextEditingToolActivated=new w.b,this.isTextAddingToolActivated=new w.b,this.isDrawLinkToolActivated=new w.b}return t.prototype.selectionToolActivation=function(t){this.isSelectionToolActivated.next(t)},t.prototype.movingToolActivation=function(t){this.isMovingToolActivated.next(t)},t.prototype.textEditingToolActivation=function(t){this.isTextEditingToolActivated.next(t)},t.prototype.textAddingToolActivation=function(t){this.isTextAddingToolActivated.next(t)},t.prototype.drawLinkToolActivation=function(t){this.isDrawLinkToolActivated.next(t)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Jnt=function(){function t(){this.dragged=new Uc,this.resized=new Uc,this.selected=new Uc,this.pointToAddSelected=new Uc,this.saved=new Uc,this.textAdded=new Uc,this.textEdited=new Uc,this.textSaved=new Uc}return t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),tit=function(){function t(t){this.context=t,this.scaleChangeEmitter=new Uc,this.currentScale=1}return t.prototype.getScale=function(){return this.currentScale},t.prototype.setScale=function(t){this.currentScale=t,this.context.transformation.k=this.currentScale,this.scaleChangeEmitter.emit(this.currentScale)},t.prototype.resetToDefault=function(){this.currentScale=1,this.context.transformation.k=this.currentScale,this.scaleChangeEmitter.emit(this.currentScale)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Ont))}}),t}(),eit=["temporaryTextElement"],nit=function(){function t(t,e,n,i,r,o,a,s,c,l,u){this.drawingsEventSource=t,this.toolsService=e,this.context=n,this.renderer=i,this.mapScaleService=r,this.linkService=o,this.linksDataSource=a,this.nodesDataSource=s,this.selectionManager=c,this.fontFixer=l,this.ngZone=u,this.leftPosition="0px",this.topPosition="0px",this.innerText="",this.addingFinished=new Uc}return t.prototype.ngOnInit=function(){var t=this;this.textAddingSubscription=this.toolsService.isTextAddingToolActivated.subscribe((function(e){e?t.activateTextAdding():t.deactivateTextAdding()})),this.ngZone.runOutsideAngular(this.activateTextEditingForDrawings.bind(this)),this.ngZone.runOutsideAngular(this.activateTextEditingForNodeLabels.bind(this))},t.prototype.activateTextAdding=function(){var t=this;this.deactivateTextAdding(),this.mapListener=function(e){t.leftPosition=e.pageX.toString()+"px",t.topPosition=e.pageY.toString()+"px",t.renderer.setStyle(t.temporaryTextElement.nativeElement,"display","initial"),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"transform","scale("+t.mapScaleService.getScale()+")"),t.temporaryTextElement.nativeElement.focus(),t.textListener=function(){t.drawingsEventSource.textAdded.emit(new snt(t.temporaryTextElement.nativeElement.innerText.replace(/\n$/,""),e.pageX,e.pageY)),t.deactivateTextAdding(),t.innerText="",t.temporaryTextElement.nativeElement.innerText="",t.temporaryTextElement.nativeElement.removeEventListener("focusout",t.textListener),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"display","none")},t.temporaryTextElement.nativeElement.addEventListener("focusout",t.textListener)},this.svg.addEventListener("click",this.mapListener)},t.prototype.deactivateTextAdding=function(){this.svg.removeEventListener("click",this.mapListener)},t.prototype.activateTextEditingForNodeLabels=function(){var t=this,e=Ww(this.svg);e.selectAll("g.interface_label_container").select("text.interface_label").on("dblclick",(function(n,i,r){t.selectionManager.setSelected([]),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"display","initial"),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"transform","scale("+t.mapScaleService.getScale()+")"),t.editedLink=n,Ww(r[i]).attr("visibility","hidden"),Ww(r[i]).classed("editingMode",!0),t.editedNode=t.nodesDataSource.get(n.nodeId),t.editedLink=n;var o=(n.label.originalX+t.editedNode.x-1)*t.context.transformation.k+t.context.getZeroZeroTransformationPoint().x+t.context.transformation.x,a=(n.label.originalY+t.editedNode.y+4)*t.context.transformation.k+t.context.getZeroZeroTransformationPoint().y+t.context.transformation.y;t.leftPosition=o.toString()+"px",t.topPosition=a.toString()+"px",t.temporaryTextElement.nativeElement.innerText=n.label.text;for(var s=[],c=0,l=n.label.style.split(";");c<l.length;c++){var u=l[c];s.push({property:u.split(": ")[0],value:u.split(": ")[1]})}var h={font_family:s.find((function(t){return"font-family"===t.property}))?s.find((function(t){return"font-family"===t.property})).value:"TypeWriter",font_size:s.find((function(t){return"font-size"===t.property}))?Number(s.find((function(t){return"font-size"===t.property})).value):10,font_weight:s.find((function(t){return"font-weight"===t.property}))?s.find((function(t){return"font-weight"===t.property})).value:"normal"};h=t.fontFixer.fix(h),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"color",s.find((function(t){return"fill"===t.property}))?s.find((function(t){return"fill"===t.property})).value:"#000000"),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"font-family",h.font_family),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"font-size",h.font_size+"pt"),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"font-weight",h.font_weight),t.textListener=function(){var n=t.temporaryTextElement.nativeElement.innerText,i=t.linksDataSource.get(t.editedLink.linkId);i.nodes.find((function(e){return e.node_id===t.editedNode.node_id})).label.text=n,t.linkService.updateLink(t.server,i).subscribe((function(n){e.selectAll("text.editingMode").attr("visibility","visible").classed("editingMode",!1),t.innerText="",t.temporaryTextElement.nativeElement.innerText="",t.temporaryTextElement.nativeElement.removeEventListener("focusout",t.textListener),t.clearStyle(),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"display","none")}))},t.temporaryTextElement.nativeElement.addEventListener("focusout",t.textListener),t.temporaryTextElement.nativeElement.focus()}))},t.prototype.activateTextEditingForDrawings=function(){var t=this,e=Ww(this.svg);e.selectAll("text.text_element").on("dblclick",(function(n,i,r){t.renderer.setStyle(t.temporaryTextElement.nativeElement,"display","initial"),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"transform","scale("+t.mapScaleService.getScale()+")"),t.editedElement=n,Ww(r[i]).attr("visibility","hidden"),Ww(r[i]).classed("editingMode",!0),t.editingDrawingId=r[i].parentElement.parentElement.getAttribute("drawing_id");var o=r[i].parentElement.getAttribute("transform").split(/\(|\)/),a=Number(o[1].split(/,/)[0])*t.context.transformation.k+t.context.getZeroZeroTransformationPoint().x+t.context.transformation.x,s=Number(o[1].split(/,/)[1])*t.context.transformation.k+t.context.getZeroZeroTransformationPoint().y+t.context.transformation.y;t.leftPosition=a.toString()+"px",t.topPosition=s.toString()+"px",t.temporaryTextElement.nativeElement.innerText=n.text,t.renderer.setStyle(t.temporaryTextElement.nativeElement,"color",n.fill),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"font-family",n.font_family),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"font-size",n.font_size+"pt"),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"font-weight",n.font_weight),t.textListener=function(){t.drawingsEventSource.textEdited.emit(new cnt(t.editingDrawingId,t.temporaryTextElement.nativeElement.innerText.replace(/\n$/,""),t.editedElement)),e.selectAll("text.editingMode").attr("visibility","visible").classed("editingMode",!1),t.innerText="",t.temporaryTextElement.nativeElement.innerText="",t.temporaryTextElement.nativeElement.removeEventListener("focusout",t.textListener),t.clearStyle(),t.renderer.setStyle(t.temporaryTextElement.nativeElement,"display","none")},t.temporaryTextElement.nativeElement.addEventListener("focusout",t.textListener),t.temporaryTextElement.nativeElement.focus()}))},t.prototype.ngOnDestroy=function(){this.textAddingSubscription.unsubscribe()},t.prototype.clearStyle=function(){this.renderer.setStyle(this.temporaryTextElement.nativeElement,"color","#000000"),this.renderer.setStyle(this.temporaryTextElement.nativeElement,"font-family","Noto Sans"),this.renderer.setStyle(this.temporaryTextElement.nativeElement,"font-size","11pt"),this.renderer.setStyle(this.temporaryTextElement.nativeElement,"font-weight","bold")},t.\u0275fac=function(e){return new(e||t)(da(Jnt),da($nt),da(Ont),da(Ks),da(tit),da(q9),da(G9),da(M9),da(Zet),da(X9),da(jl))},t.\u0275cmp=Ht({type:t,selectors:[["app-text-editor"]],viewQuery:function(t,e){var n;1&t&&nl(eit,!0),2&t&&tl(n=sl())&&(e.temporaryTextElement=n.first)},inputs:{svg:"svg",server:"server"},decls:3,vars:5,consts:[["id","temporaryElement","contenteditable","true",1,"temporaryElement"],["temporaryTextElement",""]],template:function(t,e){1&t&&(ga(0,"div",0,1),ds(2),va()),2&t&&(Za("top",e.topPosition)("left",e.leftPosition),Qi(2),ps(" ",e.innerText,"\n"))},styles:[".temporaryElement[_ngcontent-%COMP%]{padding-left:4px;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;position:absolute;z-index:99;font-family:Noto Sans;font-size:11pt;font-weight:700;color:#000}"]}),t}(),iit=function(){function t(){this.movingModeState=new Uc}return t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),rit=function(){function t(t,e,n){this.element=t,this.movingEventSource=e,this.context=n,this.activated=!1}return t.prototype.ngOnInit=function(){var t=this;this.movingModeState=this.movingEventSource.movingModeState.subscribe((function(e){t.activated=e,e||t.removelisteners()}))},t.prototype.ngOnDestroy=function(){this.movingModeState.unsubscribe()},t.prototype.onMouseDown=function(t){var e=this;this.activated&&(this.mousemoveListener=function(t){Ww(e.element.nativeElement).selectAll("g.canvas").data([e.context]).attr("transform",(function(){return e.context.transformation.x=e.context.transformation.x+t.movementX,e.context.transformation.y=e.context.transformation.y+t.movementY,"translate("+(e.context.getZeroZeroTransformationPoint().x+e.context.transformation.x)+", "+(e.context.getZeroZeroTransformationPoint().y+e.context.transformation.y)+") scale("+e.context.transformation.k+")"}))},this.mouseupListener=function(t){e.removelisteners()},this.element.nativeElement.addEventListener("mouseup",this.mouseupListener),this.element.nativeElement.addEventListener("mousemove",this.mousemoveListener))},t.prototype.removelisteners=function(){this.element.nativeElement.removeEventListener("mouseup",this.mouseupListener),this.element.nativeElement.removeEventListener("mousemove",this.mousemoveListener)},t.\u0275fac=function(e){return new(e||t)(da(Us),da(iit),da(Ont))},t.\u0275dir=Wt({type:t,selectors:[["","movingCanvas",""]],hostBindings:function(t,e){1&t&&xa("mousedown",(function(t){return e.onMouseDown(t)}))}}),t}(),oit=function(){function t(t,e,n,i){this.element=t,this.movingEventSource=e,this.context=n,this.mapsScaleService=i}return t.prototype.ngOnInit=function(){var t=this;this.movingModeState=this.movingEventSource.movingModeState.subscribe((function(e){e?t.addListener():t.removeListener()}))},t.prototype.ngOnDestroy=function(){this.movingModeState.unsubscribe()},t.prototype.addListener=function(){var t=this;this.wheelListener=function(e){e.stopPropagation(),e.preventDefault();var n=e.deltaY;n=0===e.deltaMode?n/100:n/3,Ww(t.element.nativeElement).selectAll("g.canvas").data([t.context]).attr("transform",(function(){t.context.transformation.k=t.context.transformation.k-n/10;var e=t.context.getZeroZeroTransformationPoint().x+t.context.transformation.x,i=t.context.getZeroZeroTransformationPoint().y+t.context.transformation.y,r=t.context.transformation.k;return t.mapsScaleService.setScale(r),"translate("+e+", "+i+") scale("+r+")"}))},this.element.nativeElement.addEventListener("wheel",this.wheelListener,{passive:!1})},t.prototype.removeListener=function(){this.element.nativeElement.removeEventListener("wheel",this.wheelListener)},t.\u0275fac=function(e){return new(e||t)(da(Us),da(iit),da(Ont),da(tit))},t.\u0275dir=Wt({type:t,selectors:[["","zoomingCanvas",""]]}),t}(),ait=function(){function t(t,e){this.drawingsEventSource=t,this.context=e}return t.prototype.ngOnInit=function(){var t=this;this.drawingSelected=this.drawingsEventSource.selected.subscribe((function(e){""===e?t.deactivate():t.activate()}))},t.prototype.activate=function(){var t=this;this.deactivate(),this.mapListener=function(e){var n=(e.pageX-(t.context.getZeroZeroTransformationPoint().x+t.context.transformation.x))/t.context.transformation.k,i=(e.pageY-(t.context.getZeroZeroTransformationPoint().y+t.context.transformation.y))/t.context.transformation.k;t.drawingsEventSource.pointToAddSelected.emit(new ont(n,i)),t.deactivate()},this.svg.addEventListener("click",this.mapListener)},t.prototype.deactivate=function(){this.svg.removeEventListener("click",this.mapListener)},t.prototype.ngOnDestroy=function(){this.drawingSelected.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(Jnt),da(Ont))},t.\u0275cmp=Ht({type:t,selectors:[["app-drawing-adding"]],inputs:{svg:"svg"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),sit=["*"],cit=function(){function t(t,e){this.drawingsWidget=t,this.drawingsEventSource=e}return t.prototype.ngOnInit=function(){var t=this;this.resizingFinished=this.drawingsWidget.resizingFinished.subscribe((function(e){t.drawingsEventSource.resized.emit(new rnt(e.datum,e.x,e.y,e.width,e.height))}))},t.prototype.ngOnDestroy=function(){this.resizingFinished.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(Tnt),da(Jnt))},t.\u0275cmp=Ht({type:t,selectors:[["app-drawing-resizing"]],ngContentSelectors:sit,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),Da(0))},styles:[""]}),t}(),lit=function(){function t(){}return t.prototype.inRectangle=function(t,e,n){return t.x<=e&&e<t.x+t.width&&t.y<=n&&n<t.y+t.height},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),uit=function(){function t(t,e,n,i){this.selectionEventSource=t,this.graphDataManager=e,this.inRectangleHelper=n,this.selectionManager=i}return t.prototype.ngOnInit=function(){var t=this;this.onSelection=this.selectionEventSource.selected.subscribe((function(e){var n=t.graphDataManager.getNodes().filter((function(n){return t.inRectangleHelper.inRectangle(e,n.x,n.y)})),i=t.graphDataManager.getLinks().filter((function(n){return t.inRectangleHelper.inRectangle(e,n.x,n.y)})),r=t.graphDataManager.getDrawings().filter((function(n){return t.inRectangleHelper.inRectangle(e,n.x,n.y)})),o=t.graphDataManager.getNodes().filter((function(n){return void 0!==n.label&&t.inRectangleHelper.inRectangle(e,n.x+n.label.x,n.y+n.label.y)})).map((function(t){return t.label})),a=GQ(t.graphDataManager.getLinks().filter((function(n){return void 0!==n.source&&2==n.nodes.length&&void 0!==n.nodes[0].label&&t.inRectangleHelper.inRectangle(e,n.source.x+n.nodes[0].label.x,n.source.y+n.nodes[0].label.y)})).map((function(t){return t.nodes[0]})),t.graphDataManager.getLinks().filter((function(n){return void 0!==n.target&&2==n.nodes.length&&void 0!==n.nodes[1].label&&t.inRectangleHelper.inRectangle(e,n.target.x+n.nodes[1].label.x,n.target.y+n.nodes[1].label.y)})).map((function(t){return t.nodes[1]}))),s=GQ(n,i,r,o,a);t.selectionManager.setSelected(s)}))},t.prototype.ngOnDestroy=function(){this.onSelection.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(Fnt),da(Yet),da(lit),da(Zet))},t.\u0275cmp=Ht({type:t,selectors:[["app-selection-control"]],decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),hit=function(){function t(t,e){this.selectionManager=t,this.mapChangeDetectorRef=e}return t.prototype.ngOnInit=function(){var t=this;this.onSelected=this.selectionManager.selected.subscribe((function(){t.mapChangeDetectorRef.detectChanges()})),this.onUnselected=this.selectionManager.unselected.subscribe((function(){t.mapChangeDetectorRef.detectChanges()}))},t.prototype.ngOnDestroy=function(){this.onSelected.unsubscribe(),this.onUnselected.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(Zet),da(_et))},t.\u0275cmp=Ht({type:t,selectors:[["app-selection-select"]],decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),dit=function(){function t(){this.created=new Uc,this.interfaceDragged=new Uc}return t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),fit=function(){function t(t,e,n,i,r,o,a,s,c,l,u){this.nodesWidget=t,this.drawingsWidget=e,this.linksWidget=n,this.labelWidget=i,this.interfaceWidget=r,this.selectionManager=o,this.nodesEventSource=a,this.drawingsEventSource=s,this.graphDataManager=c,this.linksEventSource=l,this.mapSettingsService=u,this.isMapLocked=!1}return t.prototype.ngOnInit=function(){var t=this,e=Ww(this.svg);this.mapSettingsSubscription=this.mapSettingsService.isMapLocked.subscribe((function(e){t.isMapLocked=e})),this.start=Object(C.a)(this.nodesWidget.draggable.start,this.drawingsWidget.draggable.start,this.labelWidget.draggable.start,this.interfaceWidget.draggable.start).subscribe((function(e){var n=t.selectionManager.getSelected();e.datum instanceof ket&&0===n.filter((function(t){return t instanceof ket&&t.id===e.datum.id})).length&&t.selectionManager.setSelected([e.datum]),e.datum instanceof I9&&0===n.filter((function(t){return t instanceof I9&&t.id===e.datum.id})).length&&t.selectionManager.setSelected([e.datum]),e.datum instanceof Cet&&0===n.filter((function(t){return t instanceof Cet&&t.id===e.datum.id})).length&&t.selectionManager.setSelected([e.datum]),e.datum instanceof Aet&&0===n.filter((function(t){return t instanceof Aet&&t.id===e.datum.id})).length&&t.selectionManager.setSelected([e.datum])})),this.drag=Object(C.a)(this.nodesWidget.draggable.drag,this.drawingsWidget.draggable.drag,this.labelWidget.draggable.drag,this.interfaceWidget.draggable.drag).subscribe((function(n){if(!t.isMapLocked){var i=t.selectionManager.getSelected(),r=i.filter((function(t){return t instanceof ket})),o=r.filter((function(t){return t.locked})),a=r.filter((function(t){return!t.locked}));a.forEach((function(i){i.x+=n.dx,i.y+=n.dy,t.nodesWidget.redrawNode(e,i),t.graphDataManager.getLinks().filter((function(t){return void 0!==t.target&&t.target.id===i.id||void 0!==t.source&&t.source.id===i.id})).forEach((function(n){t.linksWidget.redrawLink(e,n)}))})),i.filter((function(t){return t instanceof I9})).filter((function(t){return!t.locked})).forEach((function(i){i.x+=n.dx,i.y+=n.dy,t.drawingsWidget.redrawDrawing(e,i)})),i.filter((function(t){return t instanceof Cet})).filter((function(t){return 0===o.filter((function(e){return e.id===t.nodeId})).length})).forEach((function(i){if(!(a.filter((function(t){return t.id===i.nodeId})).length>0)){var r=t.graphDataManager.getNodes().filter((function(t){return t.id===i.nodeId}))[0];r.label.x+=n.dx,r.label.y+=n.dy,t.labelWidget.redrawLabel(e,i)}})),i.filter((function(t){return t instanceof Aet})).filter((function(t){return 0===o.filter((function(e){return e.id===t.nodeId})).length})).forEach((function(i){if(!(a.filter((function(t){return t.id===i.nodeId})).length>0)){var r=t.graphDataManager.getLinks().filter((function(t){return t.nodes[0].id===i.id||t.nodes[1].id===i.id}))[0];r.nodes[0].id===i.id&&(r.nodes[0].label.x+=n.dx,r.nodes[0].label.y+=n.dy),r.nodes[1].id===i.id&&(r.nodes[1].label.x+=n.dx,r.nodes[1].label.y+=n.dy),t.linksWidget.redrawLink(e,r)}}))}})),this.end=Object(C.a)(this.nodesWidget.draggable.end,this.drawingsWidget.draggable.end,this.labelWidget.draggable.end,this.interfaceWidget.draggable.end).subscribe((function(e){if(!t.isMapLocked){var n=t.selectionManager.getSelected(),i=n.filter((function(t){return t instanceof ket})),r=i.filter((function(t){return t.locked})),o=i.filter((function(t){return!t.locked}));o.forEach((function(n){t.nodesEventSource.dragged.emit(new int(n,e.dx,e.dy))})),n.filter((function(t){return t instanceof I9})).filter((function(t){return!t.locked})).forEach((function(n){t.drawingsEventSource.dragged.emit(new int(n,e.dx,e.dy))})),n.filter((function(t){return t instanceof Cet})).filter((function(t){return 0===r.filter((function(e){return e.id===t.nodeId})).length})).forEach((function(n){o.filter((function(t){return t.id===n.nodeId})).length>0||t.nodesEventSource.labelDragged.emit(new int(n,e.dx,e.dy))})),n.filter((function(t){return t instanceof Aet})).filter((function(t){return 0===r.filter((function(e){return e.id===t.nodeId})).length})).forEach((function(n){o.filter((function(t){return t.id===n.nodeId})).length>0||t.linksEventSource.interfaceDragged.emit(new int(n,e.dx,e.dy))}))}}))},t.prototype.ngOnDestroy=function(){this.start.unsubscribe(),this.drag.unsubscribe(),this.end.unsubscribe(),this.mapSettingsSubscription.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(Int),da(Tnt),da(Xnt),da(fnt),da(qnt),da(Zet),da(pnt),da(Jnt),da(Yet),da(dit),da($8))},t.\u0275cmp=Ht({type:t,selectors:[["app-draggable-selection"]],inputs:{svg:"svg"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),pit=["svg"],mit=["textEditor"],git=function(){function t(t,e,n,i,r,o,a,s,c,l,u,h,d){this.graphDataManager=t,this.context=e,this.mapChangeDetectorRef=n,this.canvasSizeDetector=i,this.mapSettings=r,this.element=o,this.interfaceLabelWidget=a,this.selectionToolWidget=s,this.movingToolWidget=c,this.graphLayout=l,this.toolsService=u,this.mapScaleService=h,this.mapSettingsService=d,this.nodes=[],this.links=[],this.drawings=[],this.symbols=[],this.width=1500,this.height=600,this.subscriptions=[],this.settings={show_interface_labels:!0},this.gridVisibility=0,this.nodeGridX=0,this.nodeGridY=0,this.drawingGridX=0,this.drawingGridY=0,this.parentNativeElement=o.nativeElement}return Object.defineProperty(t.prototype,"showInterfaceLabels",{set:function(t){t&&!this.mapSettingsService.integrateLinkLabelsToLinks?(this.settings.show_interface_labels=!0,this.interfaceLabelWidget.setEnabled(!0)):(this.settings.show_interface_labels=!1,this.interfaceLabelWidget.setEnabled(!1)),this.mapChangeDetectorRef.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"readonly",{set:function(t){this.mapSettings.isReadOnly=t},enumerable:!1,configurable:!0}),t.prototype.ngOnChanges=function(t){(t.width&&!t.width.isFirstChange()||t.height&&!t.height.isFirstChange()||t.drawings&&!t.drawings.isFirstChange()||t.nodes&&!t.nodes.isFirstChange()||t.links&&!t.links.isFirstChange()||t.symbols&&!t.symbols.isFirstChange())&&this.svg.empty&&!this.svg.empty()&&(t.symbols&&this.onSymbolsChange(t.symbols),this.changeLayout())},t.prototype.ngOnInit=function(){var t=this;null!==this.parentNativeElement&&this.createGraph(this.parentNativeElement),this.context.size=this.getSize(),this.onChangesDetected=this.mapChangeDetectorRef.changesDetected.subscribe((function(){t.mapChangeDetectorRef.hasBeenDrawn&&t.redraw()})),this.subscriptions.push(this.mapScaleService.scaleChangeEmitter.subscribe((function(e){return t.redraw()}))),this.subscriptions.push(this.toolsService.isMovingToolActivated.subscribe((function(e){t.mapChangeDetectorRef.detectChanges()}))),this.subscriptions.push(this.toolsService.isSelectionToolActivated.subscribe((function(e){t.selectionToolWidget.setEnabled(e),t.mapChangeDetectorRef.detectChanges()}))),this.subscriptions.push(this.toolsService.isDrawLinkToolActivated.subscribe((function(e){t.drawLinkTool=e}))),this.gridVisibility="true"===localStorage.getItem("gridVisibility")?1:0},t.prototype.ngOnDestroy=function(){this.graphLayout.disconnect(this.svg),this.onChangesDetected.unsubscribe(),this.subscriptions.forEach((function(t){t.unsubscribe()}))},t.prototype.applyMapSettingsChanges=function(){this.redraw()},t.prototype.createGraph=function(t){var e=Ww(t);this.svg=e.select("svg"),this.graphLayout.connect(this.svg,this.context),this.graphLayout.draw(this.svg,this.context),this.mapChangeDetectorRef.hasBeenDrawn=!0},t.prototype.getSize=function(){return this.canvasSizeDetector.getOptimalSize(this.width,this.height)},t.prototype.changeLayout=function(){null!=this.parentNativeElement&&(this.context.size=this.getSize()),this.redraw()},t.prototype.onSymbolsChange=function(t){this.graphDataManager.setSymbols(this.symbols)},t.prototype.redraw=function(){this.updateGrid(),this.graphDataManager.setNodes(this.nodes),this.graphDataManager.setLinks(this.links),this.graphDataManager.setDrawings(this.drawings),this.graphLayout.draw(this.svg,this.context),this.textEditor.activateTextEditingForDrawings(),this.textEditor.activateTextEditingForNodeLabels(),this.mapSettingsService.mapRenderedEmitter.emit(!0)},t.prototype.updateGrid=function(){this.project.grid_size&&this.project.grid_size>0&&(this.nodeGridX=this.project.scene_width/2-Math.floor(this.project.scene_width/2/this.project.grid_size)*this.project.grid_size),this.project.grid_size&&this.project.grid_size>0&&(this.nodeGridY=this.project.scene_height/2-Math.floor(this.project.scene_height/2/this.project.grid_size)*this.project.grid_size),this.project.drawing_grid_size&&this.project.drawing_grid_size>0&&(this.drawingGridX=this.project.scene_width/2-Math.floor(this.project.scene_width/2/this.project.drawing_grid_size)*this.project.drawing_grid_size),this.project.drawing_grid_size&&this.project.drawing_grid_size>0&&(this.drawingGridY=this.project.scene_height/2-Math.floor(this.project.scene_height/2/this.project.drawing_grid_size)*this.project.drawing_grid_size)},t.prototype.onResize=function(t){this.changeLayout()},t.\u0275fac=function(e){return new(e||t)(da(Yet),da(Ont),da(_et),da(Qnt),da(nnt),da(Us),da(qnt),da(Nnt),da(Bnt),da(Znt),da($nt),da(tit),da($8))},t.\u0275cmp=Ht({type:t,selectors:[["app-d3-map"]],viewQuery:function(t,e){var n;1&t&&(nl(pit,!0),nl(mit,!0)),2&t&&(tl(n=sl())&&(e.svgRef=n.first),tl(n=sl())&&(e.textEditor=n.first))},hostBindings:function(t,e){1&t&&xa("resize",(function(t){return e.onResize(t)}),!1,yn)},inputs:{nodes:"nodes",links:"links",drawings:"drawings",symbols:"symbols",project:"project",server:"server",width:"width",height:"height",showInterfaceLabels:["show-interface-labels","showInterfaceLabels"],readonly:"readonly"},features:[Ms],decls:19,vars:18,consts:[["id","map","preserveAspectRatio","none","movingCanvas","","zoomingCanvas","",1,"map"],["svg",""],["id","grayscale"],["id","feGrayscale","type","saturate","values","0"],["id","gridDrawing","patternUnits","userSpaceOnUse"],["fill","none","stroke","silver"],["id","gridNode","patternUnits","userSpaceOnUse"],["fill","none","stroke","DarkSlateGray"],["width","100%","height","100%","fill","url(#gridDrawing)"],["width","100%","height","100%","fill","url(#gridNode)"],[3,"svg"],[3,"server","svg"],["textEditor",""]],template:function(t,e){if(1&t&&(Qe(),ga(0,"svg",0,1),ga(2,"filter",2),ba(3,"feColorMatrix",3),va(),ga(4,"defs"),ga(5,"pattern",4),ba(6,"path",5),va(),va(),ga(7,"defs"),ga(8,"pattern",6),ba(9,"path",7),va(),va(),ba(10,"rect",8),ba(11,"rect",9),va(),$e(),ba(12,"app-drawing-adding",10),ba(13,"app-drawing-resizing"),ba(14,"app-selection-control"),ba(15,"app-selection-select"),ba(16,"app-text-editor",11,12),ba(18,"app-draggable-selection",10)),2&t){var n=ha(1);Qi(5),oa("x",e.drawingGridX)("y",e.drawingGridY)("width",e.project.drawing_grid_size)("height",e.project.drawing_grid_size),Qi(1),la("d","M ",e.project.drawing_grid_size," 0 L 0 0 0 ",e.project.drawing_grid_size,""),oa("stroke-width",e.gridVisibility),Qi(2),oa("x",e.nodeGridX)("y",e.nodeGridY)("width",e.project.grid_size)("height",e.project.grid_size),Qi(1),la("d","M ",e.project.grid_size," 0 L 0 0 0 ",e.project.grid_size,""),oa("stroke-width",e.gridVisibility),Qi(3),pa("svg",n),Qi(4),pa("server",e.server)("svg",n),Qi(2),pa("svg",n)}},directives:[rit,oit,ait,cit,uit,hit,nit,fit],styles:["svg[_ngcontent-%COMP%]{display:block}"]}),t}(),vit=function(){function t(){}return t.prototype.convert=function(t){var e=new j9;return e.drawing_id=t.id,e.project_id=t.projectId,e.rotation=t.rotation,e.svg=t.svg,e.locked=t.locked,e.x=t.x,e.y=t.y,e.z=t.z,e.element=t.element,e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),bit=function(){function t(){}return t.prototype.setServerId=function(t){this.serverId=t},t.prototype.setProjectId=function(t){this.projectId=t},t.prototype.getServerId=function(){return this.serverId},t.prototype.getProjectId=function(){return this.projectId},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),yit=function(){function t(t){this.mapLabelToLabel=t}return t.prototype.convert=function(t){var e=new J9;return e.node_id=t.nodeId,e.adapter_number=t.adapterNumber,e.port_number=t.portNumber,e.label=this.mapLabelToLabel.convert(t.label),e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Ent))}}),t}(),_it=function(){function t(t){this.mapLinkNodeToMapLinkNode=t}return t.prototype.convert=function(t){var e=this,n=new $9;return n.link_id=t.id,n.capture_file_name=t.captureFileName,n.capture_file_path=t.captureFilePath,n.capturing=t.capturing,n.filters=t.filters,n.link_type=t.linkType,n.nodes=t.nodes.map((function(t){return e.mapLinkNodeToMapLinkNode.convert(t)})),n.project_id=t.projectId,n.suspend=t.suspend,n},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(yit))}}),t}(),wit=function(){function t(t){this.fontBBCalculator=t,this.MARGIN_BETWEEN_NODE_AND_LABEL=8}return t.prototype.fix=function(t){t.label.style="font-family: TypeWriter;font-size: 10.0;font-weight: bold;fill: #000000;fill-opacity: 1.0;";var e=this.fontBBCalculator.calculate(t.label.text,t.label.style);return t.label.x=t.width/2-e.width/2,t.label.y=-e.height-this.MARGIN_BETWEEN_NODE_AND_LABEL,t},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(xet))}}),t}(),kit=n("vAVA"),Cit='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">',Sit="http://www.w3.org/2000/xmlns/";function xit(){var t=document.createElementNS("http://www.w3.org/2000/svg","svg");document.body.appendChild(t),t.style.all="initial";var e=getComputedStyle(t);return document.body.removeChild(t),t=null,e}function Oit(t,e){function n(t){for(var n,i,r=getComputedStyle(t),o="",a=0,s=r.length;a<s;a++)(i=r.getPropertyValue(n=r[a]))!==e.getPropertyValue(n)&&(o+="".concat(n,":").concat(i,";"));t.setAttribute("style",o)}for(var i,r,o=((r=[]).push(i=t),function t(e){if(e&&e.hasChildNodes())for(var n=e.firstChild;n;)1===n.nodeType&&"SCRIPT"!==n.nodeName&&(r.push(n),t(n)),n=n.nextSibling}(i),r),a=o.length;a--;)n(o[a])}function Mit(t){var e=document.createElement("style");e.innerHTML=Array.from(document.styleSheets).map((function(t){return Array.from(t.cssRules).map((function(t){return t.cssText})).join(" ")})).join(" "),t.prepend(e)}function Tit(t,e,n){var i=document.createElement("a");document.body.appendChild(i),i.setAttribute("class","svg-crowbar"),i.setAttribute("download",t),i.setAttribute("href",e),i.style.display="none",i.click(),setTimeout((function(){n&&n(),document.body.removeChild(i)}),10)}var Eit,Pit={CHROME:"Chrome",FIREFOX:"Firefox",SAFARI:"Safari",OPERA:"Opera",IE:"IE",MS_EDGE:"MS-Edge",MS_EDGE_CHROMIUM:"MS-Edge-Chromium",FB_MESSANGER:"FB-Messanger",SAMSUNG:"Samsung",UCBROWSER:"UC-Browser",UNKNOWN:"Unknown"},Ait={HTC:/HTC|HTC.*(Sensation|Evo|Vision|Explorer|6800|8100|8900|A7272|S510e|C110e|Legend|Desire|T8282)|APX515CKT|Qtek9090|APA9292KT|HD_mini|Sensation.*Z710e|PG86100|Z715e|Desire.*(A8181|HD)|ADR6200|ADR6400L|ADR6425|001HT|Inspire 4G|Android.*\bEVO\b|T-Mobile G1|Z520m|Android [0-9.]+; Pixel/,NEXUS_PHONE:/Nexus One|Nexus S|Galaxy.*Nexus|Android.*Nexus.*Mobile|Nexus 4|Nexus 5|Nexus 6/,DELL:/Dell[;]? (Streak|Aero|Venue|Venue Pro|Flash|Smoke|Mini 3iX)|XCD28|XCD35|\b001DL\b|\b101DL\b|\bGS01\b/,MOTOROLA:new RegExp("Motorola|DROIDX|DROID BIONIC|\\bDroid\\b.*Build|Android.*Xoom|HRI39|MOT-|A1260|A1680|A555|A853|\n A855|A953|A955|A956|Motorola.*ELECTRIFY|Motorola.*i1|i867|i940|MB200|MB300|MB501|MB502|MB508|MB511|\n MB520|MB525|MB526|MB611|MB612|MB632|MB810|MB855|MB860|MB861|MB865|MB870|ME501|ME502|ME511|ME525|ME600|\n ME632|ME722|ME811|ME860|ME863|ME865|MT620|MT710|MT716|MT720|MT810|MT870|MT917|Motorola.*TITANIUM|WX435|\n WX445|XT300|XT301|XT311|XT316|XT317|XT319|XT320|XT390|XT502|XT530|XT531|XT532|XT535|XT603|XT610|XT611|\n XT615|XT681|XT701|XT702|XT711|XT720|XT800|XT806|XT860|XT862|XT875|XT882|XT883|XT894|XT901|XT907|XT909|\n XT910|XT912|XT928|XT926|XT915|XT919|XT925|XT1021|\\bMoto E\\b|XT1068|XT1092|XT1052"),SAMSUNG:new RegExp("\\bSamsung\\b|SM-G950F|SM-G955F|SM-G9250|GT-19300|SGH-I337|BGT-S5230|GT-B2100|GT-B2700|GT-B2710|\n GT-B3210|GT-B3310|GT-B3410|GT-B3730|GT-B3740|GT-B5510|GT-B5512|GT-B5722|GT-B6520|GT-B7300|GT-B7320|\n GT-B7330|GT-B7350|GT-B7510|GT-B7722|GT-B7800|GT-C3010|GT-C3011|GT-C3060|GT-C3200|GT-C3212|GT-C3212I|\n GT-C3262|GT-C3222|GT-C3300|GT-C3300K|GT-C3303|GT-C3303K|GT-C3310|GT-C3322|GT-C3330|GT-C3350|GT-C3500|\n GT-C3510|GT-C3530|GT-C3630|GT-C3780|GT-C5010|GT-C5212|GT-C6620|GT-C6625|GT-C6712|GT-E1050|GT-E1070|\n GT-E1075|GT-E1080|GT-E1081|GT-E1085|GT-E1087|GT-E1100|GT-E1107|GT-E1110|GT-E1120|GT-E1125|GT-E1130|\n GT-E1160|GT-E1170|GT-E1175|GT-E1180|GT-E1182|GT-E1200|GT-E1210|GT-E1225|GT-E1230|GT-E1390|GT-E2100|\n GT-E2120|GT-E2121|GT-E2152|GT-E2220|GT-E2222|GT-E2230|GT-E2232|GT-E2250|GT-E2370|GT-E2550|GT-E2652|\n GT-E3210|GT-E3213|GT-I5500|GT-I5503|GT-I5700|GT-I5800|GT-I5801|GT-I6410|GT-I6420|GT-I7110|GT-I7410|\n GT-I7500|GT-I8000|GT-I8150|GT-I8160|GT-I8190|GT-I8320|GT-I8330|GT-I8350|GT-I8530|GT-I8700|GT-I8703|\n GT-I8910|GT-I9000|GT-I9001|GT-I9003|GT-I9010|GT-I9020|GT-I9023|GT-I9070|GT-I9082|GT-I9100|GT-I9103|\n GT-I9220|GT-I9250|GT-I9300|GT-I9305|GT-I9500|GT-I9505|GT-M3510|GT-M5650|GT-M7500|GT-M7600|GT-M7603|\n GT-M8800|GT-M8910|GT-N7000|GT-S3110|GT-S3310|GT-S3350|GT-S3353|GT-S3370|GT-S3650|GT-S3653|GT-S3770|\n GT-S3850|GT-S5210|GT-S5220|GT-S5229|GT-S5230|GT-S5233|GT-S5250|GT-S5253|GT-S5260|GT-S5263|GT-S5270|\n GT-S5300|GT-S5330|GT-S5350|GT-S5360|GT-S5363|GT-S5369|GT-S5380|GT-S5380D|GT-S5560|GT-S5570|GT-S5600|\n GT-S5603|GT-S5610|GT-S5620|GT-S5660|GT-S5670|GT-S5690|GT-S5750|GT-S5780|GT-S5830|GT-S5839|GT-S6102|\n GT-S6500|GT-S7070|GT-S7200|GT-S7220|GT-S7230|GT-S7233|GT-S7250|GT-S7500|GT-S7530|GT-S7550|GT-S7562|\n GT-S7710|GT-S8000|GT-S8003|GT-S8500|GT-S8530|GT-S8600|SCH-A310|SCH-A530|SCH-A570|SCH-A610|SCH-A630|\n SCH-A650|SCH-A790|SCH-A795|SCH-A850|SCH-A870|SCH-A890|SCH-A930|SCH-A950|SCH-A970|SCH-A990|SCH-I100|\n SCH-I110|SCH-I400|SCH-I405|SCH-I500|SCH-I510|SCH-I515|SCH-I600|SCH-I730|SCH-I760|SCH-I770|SCH-I830|\n SCH-I910|SCH-I920|SCH-I959|SCH-LC11|SCH-N150|SCH-N300|SCH-R100|SCH-R300|SCH-R351|SCH-R400|SCH-R410|\n SCH-T300|SCH-U310|SCH-U320|SCH-U350|SCH-U360|SCH-U365|SCH-U370|SCH-U380|SCH-U410|SCH-U430|SCH-U450|\n SCH-U460|SCH-U470|SCH-U490|SCH-U540|SCH-U550|SCH-U620|SCH-U640|SCH-U650|SCH-U660|SCH-U700|SCH-U740|\n SCH-U750|SCH-U810|SCH-U820|SCH-U900|SCH-U940|SCH-U960|SCS-26UC|SGH-A107|SGH-A117|SGH-A127|SGH-A137|\n SGH-A157|SGH-A167|SGH-A177|SGH-A187|SGH-A197|SGH-A227|SGH-A237|SGH-A257|SGH-A437|SGH-A517|SGH-A597|\n SGH-A637|SGH-A657|SGH-A667|SGH-A687|SGH-A697|SGH-A707|SGH-A717|SGH-A727|SGH-A737|SGH-A747|SGH-A767|\n SGH-A777|SGH-A797|SGH-A817|SGH-A827|SGH-A837|SGH-A847|SGH-A867|SGH-A877|SGH-A887|SGH-A897|SGH-A927|\n SGH-B100|SGH-B130|SGH-B200|SGH-B220|SGH-C100|SGH-C110|SGH-C120|SGH-C130|SGH-C140|SGH-C160|SGH-C170|\n SGH-C180|SGH-C200|SGH-C207|SGH-C210|SGH-C225|SGH-C230|SGH-C417|SGH-C450|SGH-D307|SGH-D347|SGH-D357|\n SGH-D407|SGH-D415|SGH-D780|SGH-D807|SGH-D980|SGH-E105|SGH-E200|SGH-E315|SGH-E316|SGH-E317|SGH-E335|\n SGH-E590|SGH-E635|SGH-E715|SGH-E890|SGH-F300|SGH-F480|SGH-I200|SGH-I300|SGH-I320|SGH-I550|SGH-I577|\n SGH-I600|SGH-I607|SGH-I617|SGH-I627|SGH-I637|SGH-I677|SGH-I700|SGH-I717|SGH-I727|SGH-i747M|SGH-I777|\n SGH-I780|SGH-I827|SGH-I847|SGH-I857|SGH-I896|SGH-I897|SGH-I900|SGH-I907|SGH-I917|SGH-I927|SGH-I937|\n SGH-I997|SGH-J150|SGH-J200|SGH-L170|SGH-L700|SGH-M110|SGH-M150|SGH-M200|SGH-N105|SGH-N500|SGH-N600|\n SGH-N620|SGH-N625|SGH-N700|SGH-N710|SGH-P107|SGH-P207|SGH-P300|SGH-P310|SGH-P520|SGH-P735|SGH-P777|\n SGH-Q105|SGH-R210|SGH-R220|SGH-R225|SGH-S105|SGH-S307|SGH-T109|SGH-T119|SGH-T139|SGH-T209|SGH-T219|\n SGH-T229|SGH-T239|SGH-T249|SGH-T259|SGH-T309|SGH-T319|SGH-T329|SGH-T339|SGH-T349|SGH-T359|SGH-T369|\n SGH-T379|SGH-T409|SGH-T429|SGH-T439|SGH-T459|SGH-T469|SGH-T479|SGH-T499|SGH-T509|SGH-T519|SGH-T539|\n SGH-T559|SGH-T589|SGH-T609|SGH-T619|SGH-T629|SGH-T639|SGH-T659|SGH-T669|SGH-T679|SGH-T709|SGH-T719|\n SGH-T729|SGH-T739|SGH-T746|SGH-T749|SGH-T759|SGH-T769|SGH-T809|SGH-T819|SGH-T839|SGH-T919|SGH-T929|\n SGH-T939|SGH-T959|SGH-T989|SGH-U100|SGH-U200|SGH-U800|SGH-V205|SGH-V206|SGH-X100|SGH-X105|SGH-X120|\n SGH-X140|SGH-X426|SGH-X427|SGH-X475|SGH-X495|SGH-X497|SGH-X507|SGH-X600|SGH-X610|SGH-X620|SGH-X630|\n SGH-X700|SGH-X820|SGH-X890|SGH-Z130|SGH-Z150|SGH-Z170|SGH-ZX10|SGH-ZX20|SHW-M110|SPH-A120|SPH-A400|\n SPH-A420|SPH-A460|SPH-A500|SPH-A560|SPH-A600|SPH-A620|SPH-A660|SPH-A700|SPH-A740|SPH-A760|SPH-A790|\n SPH-A800|SPH-A820|SPH-A840|SPH-A880|SPH-A900|SPH-A940|SPH-A960|SPH-D600|SPH-D700|SPH-D710|SPH-D720|\n SPH-I300|SPH-I325|SPH-I330|SPH-I350|SPH-I500|SPH-I600|SPH-I700|SPH-L700|SPH-M100|SPH-M220|SPH-M240|\n SPH-M300|SPH-M305|SPH-M320|SPH-M330|SPH-M350|SPH-M360|SPH-M370|SPH-M380|SPH-M510|SPH-M540|SPH-M550|\n SPH-M560|SPH-M570|SPH-M580|SPH-M610|SPH-M620|SPH-M630|SPH-M800|SPH-M810|SPH-M850|SPH-M900|SPH-M910|\n SPH-M920|SPH-M930|SPH-N100|SPH-N200|SPH-N240|SPH-N300|SPH-N400|SPH-Z400|SWC-E100|SCH-i909|GT-N7100|\n GT-N7105|SCH-I535|SM-N900A|SM-N900T|SGH-I317|SGH-T999L|GT-S5360B|GT-I8262|GT-S6802|GT-S6312|GT-S6310|GT-S5312|\n GT-S5310|GT-I9105|GT-I8510|GT-S6790N|SM-G7105|SM-N9005|GT-S5301|GT-I9295|GT-I9195|SM-C101|GT-S7392|GT-S7560|\n GT-B7610|GT-I5510|GT-S7582|GT-S7530E|GT-I8750|SM-G9006V|SM-G9008V|SM-G9009D|SM-G900A|SM-G900D|SM-G900F|\n SM-G900H|SM-G900I|SM-G900J|SM-G900K|SM-G900L|SM-G900M|SM-G900P|SM-G900R4|SM-G900S|SM-G900T|SM-G900V|\n SM-G900W8|SHV-E160K|SCH-P709|SCH-P729|SM-T2558|GT-I9205|SM-G9350|SM-J120F|SM-G920F|SM-G920V|SM-G930F|\n SM-N910C|SM-A310F|GT-I9190|SM-J500FN|SM-G903F|SM-J330F"),LG:new RegExp("\\bLG\\b;|LG[- ]?(C800|C900|E400|E610|E900|E-900|F160|F180K|F180L|F180S|730|855|L160|LS740|LS840|LS970|\n LU6200|MS690|MS695|MS770|MS840|MS870|MS910|P500|P700|P705|VM696|AS680|AS695|AX840|C729|E970|GS505|272|\n C395|E739BK|E960|L55C|L75C|LS696|LS860|P769BK|P350|P500|P509|P870|UN272|US730|VS840|VS950|LN272|LN510|\n LS670|LS855|LW690|MN270|MN510|P509|P769|P930|UN200|UN270|UN510|UN610|US670|US740|US760|UX265|UX840|VN271|\n VN530|VS660|VS700|VS740|VS750|VS910|VS920|VS930|VX9200|VX11000|AX840A|LW770|P506|P925|P999|E612|D955|D802|\n MS323|M257)"),SONY:/SonyST|SonyLT|SonyEricsson|SonyEricssonLT15iv|LT18i|E10i|LT28h|LT26w|SonyEricssonMT27i|C5303|C6902|C6903|C6906|C6943|D2533/,ASUS:/Asus.*Galaxy|PadFone.*Mobile/,NOKIA_LUMIA:/Lumia [0-9]{3,4}/,MICROMAX:/Micromax.*\b(A210|A92|A88|A72|A111|A110Q|A115|A116|A110|A90S|A26|A51|A35|A54|A25|A27|A89|A68|A65|A57|A90)\b/,PALM:/PalmSource|Palm/,VERTU:/Vertu|Vertu.*Ltd|Vertu.*Ascent|Vertu.*Ayxta|Vertu.*Constellation(F|Quest)?|Vertu.*Monika|Vertu.*Signature/,PANTECH:new RegExp("PANTECH|IM-A850S|IM-A840S|IM-A830L|IM-A830K|IM-A830S|IM-A820L|IM-A810K|IM-A810S|IM-A800S|IM-T100K|\n IM-A725L|IM-A780L|IM-A775C|IM-A770K|IM-A760S|IM-A750K|IM-A740S|IM-A730S|IM-A720L|IM-A710K|IM-A690L|\n IM-A690S|IM-A650S|IM-A630K|IM-A600S|VEGA PTL21|PT003|P8010|ADR910L|P6030|P6020|P9070|P4100|P9060|P5000|\n CDM8992|TXT8045|ADR8995|IS11PT|P2030|P6010|P8000|PT002|IS06|CDM8999|P9050|PT001|TXT8040|P2020|P9020|\n P2000|P7040|P7000|C790"),FLY:/IQ230|IQ444|IQ450|IQ440|IQ442|IQ441|IQ245|IQ256|IQ236|IQ255|IQ235|IQ245|IQ275|IQ240|IQ285|IQ280|IQ270|IQ260|IQ250/,WIKO:new RegExp("KITE 4G|HIGHWAY|GETAWAY|STAIRWAY|DARKSIDE|DARKFULL|DARKNIGHT|DARKMOON|SLIDE|WAX 4G|RAINBOW|BLOOM|\n SUNSET|GOA(?!nna)|LENNY|BARRY|IGGY|OZZY|CINK FIVE|CINK PEAX|CINK PEAX 2|CINK SLIM|CINK SLIM 2|CINK +|\n CINK KING|CINK PEAX|CINK SLIM|SUBLIM"),I_MOBILE:/i-mobile (IQ|i-STYLE|idea|ZAA|Hitz)/,SIMVALLEY:/\b(SP-80|XT-930|SX-340|XT-930|SX-310|SP-360|SP60|SPT-800|SP-120|SPT-800|SP-140|SPX-5|SPX-8|SP-100|SPX-8|SPX-12)\b/,WOLFGANG:/AT-B24D|AT-AS50HD|AT-AS40W|AT-AS55HD|AT-AS45q2|AT-B26D|AT-AS50Q/,ALCATEL:/Alcatel/,NINTENDO:/Nintendo (3DS|Switch)/,AMOI:/Amoi/,INQ:/INQ/,VITA:/\bVita\b/,BLACKBERRY:/\bBlackBerry\b|\bBB10\b|rim[0-9]+/,FIREFOX_OS:/\bFirefox-OS\b/,IPHONE:/\biPhone\b/,iPod:/\biPod\b/,ANDROID:/\bAndroid\b/,WINDOWS_PHONE:/\bWindows-Phone\b/,GENERIC_PHONE:new RegExp("Tapatalk|PDA;|SAGEM|\\bmmp\\b|pocket|\\bpsp\\b|symbian|Smartphone|smartfon|treo|up.browser|\n up.link|vodafone|\\bwap\\b|nokia|Nokia|Series40|Series60|S60|SonyEricsson|N900|MAUI.*WAP.*Browser")},jit={iPad:/iPad|iPad.*Mobile/,NexusTablet:/Android.*Nexus[\s]+(7|9|10)/,GoogleTablet:/Android.*Pixel C/,SamsungTablet:new RegExp("SAMSUNG.*Tablet|Galaxy.*Tab|SC-01C|GT-P1000|GT-P1003|GT-P1010|GT-P3105|GT-P6210|\n GT-P6800|GT-P6810|GT-P7100|GT-P7300|GT-P7310|GT-P7500|GT-P7510|SCH-I800|SCH-I815|SCH-I905|\n SGH-I957|SGH-I987|SGH-T849|SGH-T859|SGH-T869|SPH-P100|GT-P3100|GT-P3108|GT-P3110|GT-P5100|\n GT-P5110|GT-P6200|GT-P7320|GT-P7511|GT-N8000|GT-P8510|SGH-I497|SPH-P500|SGH-T779|SCH-I705|\n SCH-I915|GT-N8013|GT-P3113|GT-P5113|GT-P8110|GT-N8010|GT-N8005|GT-N8020|GT-P1013|GT-P6201|\n GT-P7501|GT-N5100|GT-N5105|GT-N5110|SHV-E140K|SHV-E140L|SHV-E140S|SHV-E150S|SHV-E230K|SHV-E230L|\n SHV-E230S|SHW-M180K|SHW-M180L|SM-T290|SHW-M180S|SHW-M180W|SHW-M300W|SHW-M305W|SHW-M380K|SHW-M380S|SHW-M380W|\n SHW-M430W|SHW-M480K|SHW-M480S|SHW-M480W|SHW-M485W|SHW-M486W|SHW-M500W|GT-I9228|SCH-P739|SCH-I925|\n GT-I9200|GT-P5200|GT-P5210|GT-P5210X|SM-T311|SM-T310|SM-T310X|SM-T210|SM-T210R|SM-T211|SM-P600|\n SM-P601|SM-P605|SM-P900|SM-P901|SM-T217|SM-T217A|SM-T217S|SM-P6000|SM-T3100|SGH-I467|XE500|SM-T110|\n GT-P5220|GT-I9200X|GT-N5110X|GT-N5120|SM-P905|SM-T111|SM-T2105|SM-T315|SM-T320|SM-T320X|SM-T321|\n SM-T510|SM-T520|SM-T525|SM-T530NU|SM-T230NU|SM-T330NU|SM-T900|XE500T1C|SM-P605V|SM-P905V|SM-T337V|SM-T537V|\n SM-T707V|SM-T807V|SM-P600X|SM-P900X|SM-T210X|SM-T230|SM-T230X|SM-T325|GT-P7503|SM-T531|SM-T330|\n SM-T530|SM-T705|SM-T705C|SM-T535|SM-T331|SM-T800|SM-T700|SM-T537|SM-T807|SM-P907A|SM-T337A|SM-T537A|\n SM-T707A|SM-T807A|SM-T237|SM-T807P|SM-P607T|SM-T217T|SM-T337T|SM-T807T|SM-T116NQ|SM-T116BU|SM-P550|\n SM-T350|SM-T550|SM-T9000|SM-P9000|SM-T705Y|SM-T805|GT-P3113|SM-T710|SM-T810|SM-T815|SM-T360|SM-T533|\n SM-T113|SM-T335|SM-T715|SM-T560|SM-T670|SM-T677|SM-T377|SM-T567|SM-T357T|SM-T555|SM-T561|SM-T713|\n SM-T719|SM-T813|SM-T819|SM-T580|SM-T590|SM-T355Y?|SM-T280|SM-T817A|SM-T820|SM-W700|SM-P580|SM-T587|SM-P350|\n SM-P555M|SM-P355M|SM-T113NU|SM-T815Y|SM-T585|SM-T285|SM-T825|SM-W708|SM-T835"),Kindle:new RegExp("Kindle|Silk.*Accelerated|Android.*\\b(KFOT|KFTT|KFJWI|KFJWA|KFOTE|KFSOWI|KFTHWI|KFTHWA|KFAPWI|\n KFAPWA|WFJWAE|KFSAWA|KFSAWI|KFASWI|KFARWI|KFFOWI|KFGIWI|KFMEWI)\\b|Android.*Silk/[0-9.]+ like Chrome /[0-9.]+ (?!Mobile)"),SurfaceTablet:/Windows NT [0-9.]+; ARM;.*(Tablet|ARMBJS)/,HPTablet:/HP Slate (7|8|10)|HP ElitePad 900|hp-tablet|EliteBook.*Touch|HP 8|Slate 21|HP SlateBook 10/,AsusTablet:new RegExp("^.*PadFone((?!Mobile).)*$|Transformer|TF101|TF101G|TF300T|TF300TG|TF300TL|TF700T|TF700KL|\n TF701T|TF810C|ME171|ME301T|ME302C|ME371MG|ME370T|ME372MG|ME172V|ME173X|ME400C|\n Slider SL101|\\bK00F\\b|\\bK00C\\b|\\bK00E\\b|\\bK00L\\b|TX201LA|ME176C|ME102A|\\bM80TA\\b|ME372CL|\n ME560CG|ME372CG|ME302KL| K010 | K011 | K017 | K01E |ME572C|ME103K|ME170C|ME171C|\\bME70C\\b|ME581C|\n ME581CL|ME8510C|ME181C|P01Y|PO1MA|P01Z|\\bP027\\b|\\bP024\\b|\\bP00C\\b"),BlackBerryTablet:/PlayBook|RIM Tablet/,HTCtablet:/HTC_Flyer_P512|HTC Flyer|HTC Jetstream|HTC-P715a|HTC EVO View 4G|PG41200|PG09410/,MotorolaTablet:/xoom|sholest|MZ615|MZ605|MZ505|MZ601|MZ602|MZ603|MZ604|MZ606|MZ607|MZ608|MZ609|MZ615|MZ616|MZ617/,NookTablet:/Android.*Nook|NookColor|nook browser|BNRV200|BNRV200A|BNTV250|BNTV250A|BNTV400|BNTV600|LogicPD Zoom2/,AcerTablet:new RegExp("Android.*; \\b(A100|A101|A110|A200|A210|A211|A500|A501|A510|A511|A700|A701|W500|W500P|W501|\n W501P|W510|W511|W700|G100|G100W|B1-A71|B1-710|B1-711|A1-810|A1-811|A1-830)\\b|W3-810|\\bA3-A10\\b|\\bA3-A11\\b|\n \\bA3-A20\\b|\\bA3-A30"),ToshibaTablet:/Android.*(AT100|AT105|AT200|AT205|AT270|AT275|AT300|AT305|AT1S5|AT500|AT570|AT700|AT830)|TOSHIBA.*FOLIO/,LGTablet:/\bL-06C|LG-V909|LG-V900|LG-V700|LG-V510|LG-V500|LG-V410|LG-V400|LG-VK810\b/,FujitsuTablet:/Android.*\b(F-01D|F-02F|F-05E|F-10D|M532|Q572)\b/,PrestigioTablet:new RegExp("PMP3170B|PMP3270B|PMP3470B|PMP7170B|PMP3370B|PMP3570C|PMP5870C|PMP3670B|PMP5570C|\n PMP5770D|PMP3970B|PMP3870C|PMP5580C|PMP5880D|PMP5780D|PMP5588C|PMP7280C|PMP7280C3G|PMP7280|PMP7880D|\n PMP5597D|PMP5597|PMP7100D|PER3464|PER3274|PER3574|PER3884|PER5274|PER5474|PMP5097CPRO|PMP5097|PMP7380D|\n PMP5297C|PMP5297C_QUAD|PMP812E|PMP812E3G|PMP812F|PMP810E|PMP880TD|PMT3017|PMT3037|PMT3047|PMT3057|PMT7008|\n PMT5887|PMT5001|PMT5002"),LenovoTablet:new RegExp("Lenovo TAB|Idea(Tab|Pad)( A1|A10| K1|)|ThinkPad([ ]+)?Tablet|YT3-850M|YT3-X90L|YT3-X90F|\n YT3-X90X|Lenovo.*(S2109|S2110|S5000|S6000|K3011|A3000|A3500|A1000|A2107|A2109|A1107|A5500|A7600|B6000|\n B8000|B8080)(-|)(FL|F|HV|H|)|TB-X103F|TB-X304F|TB-X304L|TB-X704F|TB-8703F|Tab2A7-10F|TB2-X30L"),DellTablet:/Venue 11|Venue 8|Venue 7|Dell Streak 10|Dell Streak 7/,YarvikTablet:new RegExp("Android.*\\b(TAB210|TAB211|TAB224|TAB250|TAB260|TAB264|TAB310|TAB360|TAB364|TAB410|TAB411|\n TAB420|TAB424|TAB450|TAB460|TAB461|TAB464|TAB465|TAB467|TAB468|TAB07-100|TAB07-101|TAB07-150|TAB07-151|\n TAB07-152|TAB07-200|TAB07-201-3G|TAB07-210|TAB07-211|TAB07-212|TAB07-214|TAB07-220|TAB07-400|TAB07-485|\n TAB08-150|TAB08-200|TAB08-201-3G|TAB08-201-30|TAB09-100|TAB09-211|TAB09-410|TAB10-150|TAB10-201|TAB10-211|\n TAB10-400|TAB10-410|TAB13-201|TAB274EUK|TAB275EUK|TAB374EUK|TAB462EUK|TAB474EUK|TAB9-200)\\b"),MedionTablet:/Android.*\bOYO\b|LIFE.*(P9212|P9514|P9516|S9512)|LIFETAB/,ArnovaTablet:/97G4|AN10G2|AN7bG3|AN7fG3|AN8G3|AN8cG3|AN7G3|AN9G3|AN7dG3|AN7dG3ST|AN7dG3ChildPad|AN10bG3|AN10bG3DT|AN9G2/,IntensoTablet:/INM8002KP|INM1010FP|INM805ND|Intenso Tab|TAB1004/,IRUTablet:/M702pro/,MegafonTablet:/MegaFon V9|\bZTE V9\b|Android.*\bMT7A\b/,EbodaTablet:/E-Boda (Supreme|Impresspeed|Izzycomm|Essential)/,AllViewTablet:/Allview.*(Viva|Alldro|City|Speed|All TV|Frenzy|Quasar|Shine|TX1|AX1|AX2)/,ArchosTablet:new RegExp("\\b(101G9|80G9|A101IT)\\b|Qilive 97R|Archos5|\\bARCHOS (70|79|80|90|97|101|FAMILYPAD|)(b|c|)(G10|\n Cobalt| TITANIUM(HD|)| Xenon| Neon|XSK| 2| XS 2| PLATINUM| CARBON|GAMEPAD)\\b"),AinolTablet:/NOVO7|NOVO8|NOVO10|Novo7Aurora|Novo7Basic|NOVO7PALADIN|novo9-Spark/,NokiaLumiaTablet:/Lumia 2520/,SonyTablet:new RegExp("Sony.*Tablet|Xperia Tablet|Sony Tablet S|SO-03E|SGPT12|SGPT13|SGPT114|SGPT121|SGPT122|SGPT123|\n SGPT111|SGPT112|SGPT113|SGPT131|SGPT132|SGPT133|SGPT211|SGPT212|SGPT213|SGP311|SGP312|SGP321|EBRD1101|\n EBRD1102|EBRD1201|SGP351|SGP341|SGP511|SGP512|SGP521|SGP541|SGP551|SGP621|SGP641|SGP612|SOT31|SGP771|SGP611|\n SGP612|SGP712"),PhilipsTablet:/\b(PI2010|PI3000|PI3100|PI3105|PI3110|PI3205|PI3210|PI3900|PI4010|PI7000|PI7100)\b/,CubeTablet:/Android.*(K8GT|U9GT|U10GT|U16GT|U17GT|U18GT|U19GT|U20GT|U23GT|U30GT)|CUBE U8GT/,CobyTablet:new RegExp("MID1042|MID1045|MID1125|MID1126|MID7012|MID7014|MID7015|MID7034|MID7035|MID7036|MID7042|MID7048|\n MID7127|MID8042|MID8048|MID8127|MID9042|MID9740|MID9742|MID7022|MID7010"),MIDTablet:new RegExp("M9701|M9000|M9100|M806|M1052|M806|T703|MID701|MID713|MID710|MID727|MID760|MID830|MID728|MID933|\n MID125|MID810|MID732|MID120|MID930|MID800|MID731|MID900|MID100|MID820|MID735|MID980|MID130|MID833|MID737|\n MID960|MID135|MID860|MID736|MID140|MID930|MID835|MID733|MID4X10"),MSITablet:new RegExp("MSI \\b(Primo 73K|Primo 73L|Primo 81L|Primo 77|Primo 93|Primo 75|Primo 76|Primo 73|Primo 81|\n Primo 91|Primo 90|Enjoy 71|Enjoy 7|Enjoy 10)\\b"),SMiTTablet:/Android.*(\bMID\b|MID-560|MTV-T1200|MTV-PND531|MTV-P1101|MTV-PND530)/,RockChipTablet:/Android.*(RK2818|RK2808A|RK2918|RK3066)|RK2738|RK2808A/,FlyTablet:/IQ310|Fly Vision/,bqTablet:new RegExp("Android.*(bq)?.*(Elcano|Curie|Edison|Maxwell|Kepler|Pascal|Tesla|Hypatia|Platon|Newton|\n Livingstone|Cervantes|Avant|Aquaris ([E|M]10|M8))|Maxwell.*Lite|Maxwell.*Plus"),HuaweiTablet:new RegExp("MediaPad|MediaPad 7 Youth|MediaPad T3 10|IDEOS S7|S7-201c|S7-202u|S7-101|S7-103|S7-104|S7-105|S7-106|\n S7-201|S7-Slim|M2-A01L|BAH-L09|BAH-W09|AGS-W09"),NecTablet:/\bN-06D|\bN-08D/,PantechTablet:/Pantech.*P4100/,BronchoTablet:/Broncho.*(N701|N708|N802|a710)/,VersusTablet:/TOUCHPAD.*[78910]|\bTOUCHTAB\b/,ZyncTablet:/z1000|Z99 2G|z99|z930|z999|z990|z909|Z919|z900/,PositivoTablet:/TB07STA|TB10STA|TB07FTA|TB10FTA/,NabiTablet:/Android.*\bNabi/,KoboTablet:/Kobo Touch|\bK080\b|\bVox\b Build|\bArc\b Build/,DanewTablet:/DSlide.*\b(700|701R|702|703R|704|802|970|971|972|973|974|1010|1012)\b/,TexetTablet:new RegExp("NaviPad|TB-772A|TM-7045|TM-7055|TM-9750|TM-7016|TM-7024|TM-7026|TM-7041|TM-7043|TM-7047|\n TM-8041|TM-9741|TM-9747|TM-9748|TM-9751|TM-7022|TM-7021|TM-7020|TM-7011|TM-7010|TM-7023|TM-7025|\n TM-7037W|TM-7038W|TM-7027W|TM-9720|TM-9725|TM-9737W|TM-1020|TM-9738W|TM-9740|TM-9743W|TB-807A|TB-771A|\n TB-727A|TB-725A|TB-719A|TB-823A|TB-805A|TB-723A|TB-715A|TB-707A|TB-705A|TB-709A|TB-711A|TB-890HD|\n TB-880HD|TB-790HD|TB-780HD|TB-770HD|TB-721HD|TB-710HD|TB-434HD|TB-860HD|TB-840HD|TB-760HD|TB-750HD|\n TB-740HD|TB-730HD|TB-722HD|TB-720HD|TB-700HD|TB-500HD|TB-470HD|TB-431HD|TB-430HD|TB-506|TB-504|TB-446|\n TB-436|TB-416|TB-146SE|TB-126SE"),PlaystationTablet:/Playstation.*(Portable|Vita)/,TrekstorTablet:/ST10416-1|VT10416-1|ST70408-1|ST702xx-1|ST702xx-2|ST80208|ST97216|ST70104-2|VT10416-2|ST10216-2A|SurfTab/,PyleAudioTablet:/\b(PTBL10CEU|PTBL10C|PTBL72BC|PTBL72BCEU|PTBL7CEU|PTBL7C|PTBL92BC|PTBL92BCEU|PTBL9CEU|PTBL9CUK|PTBL9C)\b/,AdvanTablet:new RegExp("Android.* \\b(E3A|T3X|T5C|T5B|T3E|T3C|T3B|T1J|T1F|T2A|T1H|T1i|E1C|T1-E|T5-A|T4|E1-B|T2Ci|\n T1-B|T1-D|O1-A|E1-A|T1-A|T3A|T4i)\\b"),DanyTechTablet:"Genius Tab G3|Genius Tab S2|Genius Tab Q3|Genius Tab G4|Genius Tab Q4|Genius Tab G-II|\n Genius TAB GII|Genius TAB GIII|Genius Tab S1",GalapadTablet:/Android.*\bG1\b(?!\))/,MicromaxTablet:/Funbook|Micromax.*\b(P250|P560|P360|P362|P600|P300|P350|P500|P275)\b/,KarbonnTablet:/Android.*\b(A39|A37|A34|ST8|ST10|ST7|Smart Tab3|Smart Tab2)\b/,AllFineTablet:/Fine7 Genius|Fine7 Shine|Fine7 Air|Fine8 Style|Fine9 More|Fine10 Joy|Fine11 Wide/,PROSCANTablet:new RegExp("\\b(PEM63|PLT1023G|PLT1041|PLT1044|PLT1044G|PLT1091|PLT4311|PLT4311PL|PLT4315|PLT7030|\n PLT7033|PLT7033D|PLT7035|PLT7035D|PLT7044K|PLT7045K|PLT7045KB|PLT7071KG|PLT7072|PLT7223G|PLT7225G|\n PLT7777G|PLT7810K|PLT7849G|PLT7851G|PLT7852G|PLT8015|PLT8031|PLT8034|PLT8036|PLT8080K|PLT8082|PLT8088|\n PLT8223G|PLT8234G|PLT8235G|PLT8816K|PLT9011|PLT9045K|PLT9233G|PLT9735|PLT9760G|PLT9770G)\\b"),YONESTablet:/BQ1078|BC1003|BC1077|RK9702|BC9730|BC9001|IT9001|BC7008|BC7010|BC708|BC728|BC7012|BC7030|BC7027|BC7026/,ChangJiaTablet:new RegExp("TPC7102|TPC7103|TPC7105|TPC7106|TPC7107|TPC7201|TPC7203|TPC7205|TPC7210|TPC7708|TPC7709|\n TPC7712|TPC7110|TPC8101|TPC8103|TPC8105|TPC8106|TPC8203|TPC8205|TPC8503|TPC9106|TPC9701|TPC97101|TPC97103|\n TPC97105|TPC97106|TPC97111|TPC97113|TPC97203|TPC97603|TPC97809|TPC97205|TPC10101|TPC10103|TPC10106|\n TPC10111|TPC10203|TPC10205|TPC10503"),GUTablet:/TX-A1301|TX-M9002|Q702|kf026/,PointOfViewTablet:new RegExp("TAB-P506|TAB-navi-7-3G-M|TAB-P517|TAB-P-527|TAB-P701|TAB-P703|TAB-P721|TAB-P731N|\n TAB-P741|TAB-P825|TAB-P905|TAB-P925|TAB-PR945|TAB-PL1015|TAB-P1025|TAB-PI1045|TAB-P1325|TAB-PROTAB[0-9]+|\n TAB-PROTAB25|TAB-PROTAB26|TAB-PROTAB27|TAB-PROTAB26XL|TAB-PROTAB2-IPS9|TAB-PROTAB30-IPS9|TAB-PROTAB25XXL|\n TAB-PROTAB26-IPS10|TAB-PROTAB30-IPS10"),OvermaxTablet:new RegExp("OV-(SteelCore|NewBase|Basecore|Baseone|Exellen|Quattor|EduTab|Solution|ACTION|BasicTab|TeddyTab|\n MagicTab|Stream|TB-08|TB-09)|Qualcore 1027"),HCLTablet:/HCL.*Tablet|Connect-3G-2.0|Connect-2G-2.0|ME Tablet U1|ME Tablet U2|ME Tablet G1|ME Tablet X1|ME Tablet Y2|ME Tablet Sync/,DPSTablet:/DPS Dream 9|DPS Dual 7/,VistureTablet:/V97 HD|i75 3G|Visture V4( HD)?|Visture V5( HD)?|Visture V10/,CrestaTablet:/CTP(-)?810|CTP(-)?818|CTP(-)?828|CTP(-)?838|CTP(-)?888|CTP(-)?978|CTP(-)?980|CTP(-)?987|CTP(-)?988|CTP(-)?989/,MediatekTablet:/\bMT8125|MT8389|MT8135|MT8377\b/,ConcordeTablet:/Concorde([ ]+)?Tab|ConCorde ReadMan/,GoCleverTablet:new RegExp("GOCLEVER TAB|A7GOCLEVER|M1042|M7841|M742|R1042BK|R1041|TAB A975|TAB A7842|TAB A741|TAB A741L|TAB M723G|\n TAB M721|TAB A1021|TAB I921|TAB R721|TAB I720|TAB T76|TAB R70|TAB R76.2|TAB R106|TAB R83.2|TAB M813G|TAB I721|\n GCTA722|TAB I70|TAB I71|TAB S73|TAB R73|TAB R74|TAB R93|TAB R75|TAB R76.1|TAB A73|TAB A93|TAB A93.2|TAB T72|\n TAB R83|TAB R974|TAB R973|TAB A101|TAB A103|TAB A104|TAB A104.2|R105BK|M713G|A972BK|TAB A971|TAB R974.2|\n TAB R104|TAB R83.3|TAB A1042"),ModecomTablet:new RegExp("FreeTAB 9000|FreeTAB 7.4|FreeTAB 7004|FreeTAB 7800|FreeTAB 2096|FreeTAB 7.5|FreeTAB 1014|\n FreeTAB 1001 |FreeTAB 8001|FreeTAB 9706|FreeTAB 9702|FreeTAB 7003|FreeTAB 7002|FreeTAB 1002|FreeTAB 7801|\n FreeTAB 1331|FreeTAB 1004|FreeTAB 8002|FreeTAB 8014|FreeTAB 9704|FreeTAB 1003"),VoninoTablet:new RegExp("\\b(Argus[ _]?S|Diamond[ _]?79HD|Emerald[ _]?78E|Luna[ _]?70C|Onyx[ _]?S|Onyx[ _]?Z|\n Orin[ _]?HD|Orin[ _]?S|Otis[ _]?S|SpeedStar[ _]?S|Magnet[ _]?M9|Primus[ _]?94[ _]?3G|Primus[ _]?94HD|\n Primus[ _]?QS|Android.*\\bQ8\\b|Sirius[ _]?EVO[ _]?QS|Sirius[ _]?QS|Spirit[ _]?S)\\b"),ECSTablet:/V07OT2|TM105A|S10OT1|TR10CS1/,StorexTablet:/eZee[_']?(Tab|Go)[0-9]+|TabLC7|Looney Tunes Tab/,VodafoneTablet:/SmartTab([ ]+)?[0-9]+|SmartTabII10|SmartTabII7|VF-1497/,EssentielBTablet:/Smart[ ']?TAB[ ]+?[0-9]+|Family[ ']?TAB2/,RossMoorTablet:/RM-790|RM-997|RMD-878G|RMD-974R|RMT-705A|RMT-701|RME-601|RMT-501|RMT-711/,iMobileTablet:/i-mobile i-note/,TolinoTablet:/tolino tab [0-9.]+|tolino shine/,AudioSonicTablet:/\bC-22Q|T7-QC|T-17B|T-17P\b/,AMPETablet:/Android.* A78 /,SkkTablet:/Android.* (SKYPAD|PHOENIX|CYCLOPS)/,TecnoTablet:/TECNO P9|TECNO DP8D/,JXDTablet:new RegExp("Android.* \\b(F3000|A3300|JXD5000|JXD3000|JXD2000|JXD300B|JXD300|S5800|S7800|S602b|S5110b|S7300|\n S5300|S602|S603|S5100|S5110|S601|S7100a|P3000F|P3000s|P101|P200s|P1000m|P200m|P9100|P1000s|S6600b|S908|\n P1000|P300|S18|S6600|S9100)\\b"),iJoyTablet:new RegExp("Tablet (Spirit 7|Essentia|Galatea|Fusion|Onix 7|Landa|Titan|Scooby|Deox|Stella|Themis|Argon|\n Unique 7|Sygnus|Hexen|Finity 7|Cream|Cream X2|Jade|Neon 7|Neron 7|Kandy|Scape|Saphyr 7|Rebel|Biox|Rebel|\n Rebel 8GB|Myst|Draco 7|Myst|Tab7-004|Myst|Tadeo Jones|Tablet Boing|Arrow|Draco Dual Cam|Aurix|Mint|Amity|\n Revolution|Finity 9|Neon 9|T9w|Amity 4GB Dual Cam|Stone 4GB|Stone 8GB|Andromeda|Silken|X2|Andromeda II|\n Halley|Flame|Saphyr 9,7|Touch 8|Planet|Triton|Unique 10|Hexen 10|Memphis 4GB|Memphis 8GB|Onix 10)"),FX2Tablet:/FX2 PAD7|FX2 PAD10/,XoroTablet:new RegExp("KidsPAD 701|PAD[ ]?712|PAD[ ]?714|PAD[ ]?716|PAD[ ]?717|PAD[ ]?718|PAD[ ]?720|PAD[ ]?721|\n PAD[ ]?722|PAD[ ]?790|PAD[ ]?792|PAD[ ]?900|PAD[ ]?9715D|PAD[ ]?9716DR|PAD[ ]?9718DR|PAD[ ]?9719QR|\n PAD[ ]?9720QR|TelePAD1030|Telepad1032|TelePAD730|TelePAD731|TelePAD732|TelePAD735Q|TelePAD830|TelePAD9730|\n TelePAD795|MegaPAD 1331|MegaPAD 1851|MegaPAD 2151"),ViewsonicTablet:/ViewPad 10pi|ViewPad 10e|ViewPad 10s|ViewPad E72|ViewPad7|ViewPad E100|ViewPad 7e|ViewSonic VB733|VB100a/,VerizonTablet:/QTAQZ3|QTAIR7|QTAQTZ3|QTASUN1|QTASUN2|QTAXIA1/,OdysTablet:/LOOX|XENO10|ODYS[ -](Space|EVO|Xpress|NOON)|\bXELIO\b|Xelio10Pro|XELIO7PHONETAB|XELIO10EXTREME|XELIOPT2|NEO_QUAD10/,CaptivaTablet:/CAPTIVA PAD/,IconbitTablet:new RegExp("NetTAB|NT-3702|NT-3702S|NT-3702S|NT-3603P|NT-3603P|NT-0704S|NT-0704S|NT-3805C|NT-3805C|\n NT-0806C|NT-0806C|NT-0909T|NT-0909T|NT-0907S|NT-0907S|NT-0902S|NT-0902S"),TeclastTablet:new RegExp("T98 4G|\\bP80\\b|\\bX90HD\\b|X98 Air|X98 Air 3G|\\bX89\\b|P80 3G|\\bX80h\\b|P98 Air|\n \\bX89HD\\b|P98 3G|\\bP90HD\\b|P89 3G|X98 3G|\\bP70h\\b|P79HD 3G|G18d 3G|\\bP79HD\\b|\\bP89s\\b|\\bA88\\b|\n \\bP10HD\\b|\\bP19HD\\b|G18 3G|\\bP78HD\\b|\\bA78\\b|\\bP75\\b|G17s 3G|G17h 3G|\\bP85t\\b|\\bP90\\b|\n \\bP11\\b|\\bP98t\\b|\\bP98HD\\b|\\bG18d\\b|\\bP85s\\b|\\bP11HD\\b|\\bP88s\\b|\\bA80HD\\b|\\bA80se\\b|\n \\bA10h\\b|\\bP89\\b|\\bP78s\\b|\\bG18\\b|\\bP85\\b|\\bA70h\\b|\\bA70\\b|\\bG17\\b|\\bP18\\b|\\bA80s\\b|\n \\bA11s\\b|\\bP88HD\\b|\\bA80h\\b|\\bP76s\\b|\\bP76h\\b|\\bP98\\b|\\bA10HD\\b|\\bP78\\b|\\bP88\\b|\\bA11\\b|\n \\bA10t\\b|\\bP76a\\b|\\bP76t\\b|\\bP76e\\b|\\bP85HD\\b|\\bP85a\\b|\\bP86\\b|\\bP75HD\\b|\\bP76v\\b|\\bA12\\b|\n \\bP75a\\b|\\bA15\\b|\\bP76Ti\\b|\\bP81HD\\b|\\bA10\\b|\\bT760VE\\b|\\bT720HD\\b|\\bP76\\b|\\bP73\\b|\\bP71\\b|\n \\bP72\\b|\\bT720SE\\b|\\bC520Ti\\b|\\bT760\\b|\\bT720VE\\b|T720-3GE|T720-WiFi"),OndaTablet:new RegExp("\\b(V975i|Vi30|VX530|V701|Vi60|V701s|Vi50|V801s|V719|Vx610w|VX610W|V819i|Vi10|VX580W|Vi10|\n V711s|V813|V811|V820w|V820|Vi20|V711|VI30W|V712|V891w|V972|V819w|V820w|Vi60|V820w|V711|V813s|V801|V819|\n V975s|V801|V819|V819|V818|V811|V712|V975m|V101w|V961w|V812|V818|V971|V971s|V919|V989|V116w|V102w|V973|\n Vi40)\\b[s]+|V10 \\b4G\\b"),JaytechTablet:/TPC-PA762/,BlaupunktTablet:/Endeavour 800NG|Endeavour 1010/,DigmaTablet:/\b(iDx10|iDx9|iDx8|iDx7|iDxD7|iDxD8|iDsQ8|iDsQ7|iDsQ8|iDsD10|iDnD7|3TS804H|iDsQ11|iDj7|iDs10)\b/,EvolioTablet:/ARIA_Mini_wifi|Aria[ _]Mini|Evolio X10|Evolio X7|Evolio X8|\bEvotab\b|\bNeura\b/,LavaTablet:/QPAD E704|\bIvoryS\b|E-TAB IVORY|\bE-TAB\b/,AocTablet:/MW0811|MW0812|MW0922|MTK8382|MW1031|MW0831|MW0821|MW0931|MW0712/,MpmanTablet:new RegExp("MP11 OCTA|MP10 OCTA|MPQC1114|MPQC1004|MPQC994|MPQC974|MPQC973|MPQC804|MPQC784|MPQC780|\n \\bMPG7\\b|MPDCG75|MPDCG71|MPDC1006|MP101DC|MPDC9000|MPDC905|MPDC706HD|MPDC706|MPDC705|MPDC110|\n MPDC100|MPDC99|MPDC97|MPDC88|MPDC8|MPDC77|MP709|MID701|MID711|MID170|MPDC703|MPQC1010"),CelkonTablet:/CT695|CT888|CT[\s]?910|CT7 Tab|CT9 Tab|CT3 Tab|CT2 Tab|CT1 Tab|C820|C720|\bCT-1\b/,WolderTablet:new RegExp("miTab \\b(DIAMOND|SPACE|BROOKLYN|NEO|FLY|MANHATTAN|FUNK|EVOLUTION|SKY|GOCAR|IRON|GENIUS|\n POP|MINT|EPSILON|BROADWAY|JUMP|HOP|LEGEND|NEW AGE|LINE|ADVANCE|FEEL|FOLLOW|LIKE|LINK|LIVE|THINK|\n FREEDOM|CHICAGO|CLEVELAND|BALTIMORE-GH|IOWA|BOSTON|SEATTLE|PHOENIX|DALLAS|IN 101|MasterChef)\\b"),MediacomTablet:"M-MPI10C3G|M-SP10EG|M-SP10EGP|M-SP10HXAH|M-SP7HXAH|M-SP10HXBH|M-SP8HXAH|M-SP8MXA",MiTablet:/\bMI PAD\b|\bHM NOTE 1W\b/,NibiruTablet:/Nibiru M1|Nibiru Jupiter One/,NexoTablet:/NEXO NOVA|NEXO 10|NEXO AVIO|NEXO FREE|NEXO GO|NEXO EVO|NEXO 3G|NEXO SMART|NEXO KIDDO|NEXO MOBI/,LeaderTablet:new RegExp("TBLT10Q|TBLT10I|TBL-10WDKB|TBL-10WDKBO2013|TBL-W230V2|TBL-W450|TBL-W500|SV572|TBLT7I|\n TBA-AC7-8G|TBLT79|TBL-8W16|TBL-10W32|TBL-10WKB|TBL-W100"),UbislateTablet:/UbiSlate[\s]?7C/,PocketBookTablet:/Pocketbook/,KocasoTablet:/\b(TB-1207)\b/,HisenseTablet:/\b(F5281|E2371)\b/,Hudl:/Hudl HT7S3|Hudl 2/,TelstraTablet:/T-Hub2/,GenericTablet:new RegExp("Android.*\\b97D\\b|Tablet(?!.*PC)|BNTV250A|MID-WCDMA|LogicPD Zoom2|\\bA7EB\\b|CatNova8|\n A1_07|CT704|CT1002|\\bM721\\b|rk30sdk|\\bEVOTAB\\b|M758A|ET904|ALUMIUM10|Smartfren Tab|Endeavour 1010|\n Tablet-PC-4|Tagi Tab|\\bM6pro\\b|CT1020W|arc 10HD|\\bTP750\\b|\\bQTAQZ3\\b|WVT101|TM1088|KT107")},Iit={BLACKBERRY:"Blackberry",FIREFOX_OS:"Firefox-OS",CHROME_BOOK:"Chrome-Book",WINDOWS_PHONE:"Windows-Phone",VITA:"Vita",PS4:"PS4",CHROMECAST:"Chromecast",APPLE_TV:"Apple-TV",GOOGLE_TV:"Google-TV",ANDROID:"Android",Tesla:"Tesla",iPad:"iPad",IPHONE:"iPhone",iPod:"iPod",UNKNOWN:"Unknown",HTC:"HTC",NEXUS_PHONE:"Nexus Phone",NexusTablet:"Nexus Tablet",DELL:"Dell",MOTOROLA:"Motorola",SAMSUNG:"Samsung",LG:"LG",SONY:"Sony",ASUS:"Asus",NOKIA_LUMIA:"Nokia Lumia",MICROMAX:"Micromax",PALM:"Palm",VERTU:"Vertu",PANTECH:"PANTECH",FLY:"Fly",WIKO:"WIKO",I_MOBILE:"i-mobile",SIMVALLEY:"Simvalley",WOLFGANG:"Wolfgang",ALCATEL:"Alcatel",NINTENDO:"Nintendo",AMOI:"Amoi",INQ:"INQ",GENERIC_PHONE:"Generic Phone"},Dit=Object.assign({},Ait,jit,{FIREFOX_OS:{and:[/\bFirefox\b/,/\bMobile\b/]},CHROME_BOOK:/\bCrOS\b/,PS4:/\bMozilla\/5.0 \(PlayStation 4\b/,CHROMECAST:/\bCrKey\b/,APPLE_TV:/^iTunes-AppleTV\/4.1$/,GOOGLE_TV:/\bGoogleTV\b/,Tesla:/Tesla\/([0-9]{4}.[0-9]{1,2}.?[0-9]{0,2}.?[0-9]{0,2})-(.{7})/}),Rit={WINDOWS_3_11:/Win16/,WINDOWS_95:/(Windows 95|Win95|Windows_95)/,WINDOWS_ME:/(Win 9x 4.90|Windows ME)/,WINDOWS_98:/(Windows 98|Win98)/,WINDOWS_CE:/Windows CE/,WINDOWS_2000:/(Windows NT 5.0|Windows 2000)/,WINDOWS_XP:/(Windows NT 5.1|Windows XP)/,WINDOWS_SERVER_2003:/Windows NT 5.2/,WINDOWS_VISTA:/Windows NT 6.0/,WINDOWS_7:/(Windows 7|Windows NT 6.1)/,WINDOWS_8_1:/(Windows 8.1|Windows NT 6.3)/,WINDOWS_8:/(Windows 8|Windows NT 6.2)/,WINDOWS_10:/(Windows NT 10.0)/,WINDOWS_PHONE_7_5:/(Windows Phone OS 7.5)/,WINDOWS_PHONE_8_1:/(Windows Phone 8.1)/,WINDOWS_PHONE_10:/(Windows Phone 10)/,WINDOWS_NT_4_0:{and:[/(Windows NT 4.0|WinNT4.0|WinNT|Windows NT)/,{not:/Windows NT 10.0/}]},MACOSX:/(MAC OS X\s*[^ 0-9])/,MACOSX_3:/(Darwin 10.3|Mac OS X 10.3)/,MACOSX_4:/(Darwin 10.4|Mac OS X 10.4)/,MACOSX_5:/(Mac OS X 10.5)/,MACOSX_6:/(Mac OS X 10.6)/,MACOSX_7:/(Mac OS X 10.7)/,MACOSX_8:/(Mac OS X 10.8)/,MACOSX_9:/(Mac OS X 10.9)/,MACOSX_10:/(Mac OS X 10.10)/,MACOSX_11:/(Mac OS X 10.11)/,MACOSX_12:/(Mac OS X 10.12)/,MACOSX_13:/(Mac OS X 10.13)/,MACOSX_14:/(Mac OS X 10.14)/,MACOSX_15:/(Mac OS X 10.15)/,iOS:/(iPhone OS\s*[0-9_]+)/},Lit={CHROME:[/\bChrome\/([\d\.]+)\b/,/\bCriOS\/([\d\.]+)\b/,/\bHeadlessChrome\/([\d\.]+)\b/],FIREFOX:[/\bFirefox\/([\d\.]+)\b/,/\bFxiOS\/([\d\.]+)\b/],SAFARI:[/\bVersion\/([\d\.]+)\b/,/\bSafari\/([\d\.]+)\b/],OPERA:[/\bVersion\/([\d\.]+)\b/,/\bOPR\/([\d\.]+)\b/],IE:[/\bMSIE ([\d\.]+\w?)\b/,/\brv:([\d\.]+\w?)\b/],MS_EDGE:/\bEdg(?:e|A|iOS)\/([\d\.]+)\b/,MS_EDGE_CHROMIUM:/\bEdg\/([\d\.]+)\b/,SAMSUNG:/\bSamsungBrowser\/([\d\.]+)\b/,UCBROWSER:/\bUCBrowser\/([\d\.]+)\b/},Fit=Object.keys(Rit).reduce((function(t,e){return t[e]=Rit[e],t}),{}),Nit=Object.keys(Lit).reduce((function(t,e){return t[Pit[e]]=Lit[e],t}),{}),Bit=Object.freeze({BROWSERS:Pit,MOBILES_RE:Ait,TABLETS_RE:jit,DEVICES:Iit,OS:{WINDOWS:"Windows",MAC:"Mac",IOS:"iOS",ANDROID:"Android",LINUX:"Linux",UNIX:"Unix",FIREFOX_OS:"Firefox-OS",CHROME_OS:"Chrome-OS",WINDOWS_PHONE:"Windows-Phone",UNKNOWN:"Unknown"},OS_VERSIONS:{WINDOWS_3_11:"windows-3-11",WINDOWS_95:"windows-95",WINDOWS_ME:"windows-me",WINDOWS_98:"windows-98",WINDOWS_CE:"windows-ce",WINDOWS_2000:"windows-2000",WINDOWS_XP:"windows-xp",WINDOWS_SERVER_2003:"windows-server-2003",WINDOWS_VISTA:"windows-vista",WINDOWS_7:"windows-7",WINDOWS_8_1:"windows-8-1",WINDOWS_8:"windows-8",WINDOWS_10:"windows-10",WINDOWS_PHONE_7_5:"windows-phone-7-5",WINDOWS_PHONE_8_1:"windows-phone-8-1",WINDOWS_PHONE_10:"windows-phone-10",WINDOWS_NT_4_0:"windows-nt-4-0",MACOSX_15:"mac-os-x-15",MACOSX_14:"mac-os-x-14",MACOSX_13:"mac-os-x-13",MACOSX_12:"mac-os-x-12",MACOSX_11:"mac-os-x-11",MACOSX_10:"mac-os-x-10",MACOSX_9:"mac-os-x-9",MACOSX_8:"mac-os-x-8",MACOSX_7:"mac-os-x-7",MACOSX_6:"mac-os-x-6",MACOSX_5:"mac-os-x-5",MACOSX_4:"mac-os-x-4",MACOSX_3:"mac-os-x-3",MACOSX_2:"mac-os-x-2",MACOSX:"mac-os-x",iOS:"iOS",UNKNOWN:"unknown"},OS_RE:{WINDOWS:{and:[{or:[/\bWindows|(Win\d\d)\b/,/\bWin 9x\b/]},{not:/\bWindows Phone\b/}]},MAC:{and:[/\bMac OS\b/,{not:{or:[/\biPhone\b/,/\bWindows Phone\b/]}}]},IOS:{and:[{or:[/\biPad\b/,/\biPhone\b/,/\biPod\b/]},{not:/\bWindows Phone\b/}]},ANDROID:{and:[/\bAndroid\b/,{not:/\bWindows Phone\b/}]},LINUX:/\bLinux\b/,UNIX:/\bUNIX\b/,FIREFOX_OS:{and:[/\bFirefox\b/,/Mobile\b/]},CHROME_OS:/\bCrOS\b/,WINDOWS_PHONE:{or:[/\bIEMobile\b/,/\bWindows Phone\b/]},PS4:/\bMozilla\/5.0 \(PlayStation 4\b/,VITA:/\bMozilla\/5.0 \(Play(S|s)tation Vita\b/},BROWSERS_RE:{CHROME:{and:[{or:[/\bChrome\b/,/\bCriOS\b/,/\bHeadlessChrome\b/]},{not:{or:[/\bOPR\b/,/\bEdg(e|A|iOS)\b/,/\bEdg\/\b/,/\bSamsungBrowser\b/,/\bUCBrowser\b/]}}]},FIREFOX:{or:[/\bFirefox\b/,/\bFxiOS\b/]},SAFARI:{and:[/^((?!CriOS).)*\Safari\b.*$/,{not:{or:[/\bOPR\b/,/\bEdg(e|A|iOS)\b/,/\bEdg\/\b/,/\bWindows Phone\b/,/\bSamsungBrowser\b/,/\bUCBrowser\b/]}}]},OPERA:{or:[/Opera\b/,/\bOPR\b/]},IE:{or:[/\bMSIE\b/,/\bTrident\b/,/^Mozilla\/5\.0 \(Windows NT 10\.0; Win64; x64\)$/]},MS_EDGE:{or:[/\bEdg(e|A|iOS)\b/]},MS_EDGE_CHROMIUM:/\bEdg\/\b/,PS4:/\bMozilla\/5.0 \(PlayStation 4\b/,VITA:/\bMozilla\/5.0 \(Play(S|s)tation Vita\b/,FB_MESSANGER:/\bFBAN\/MessengerForiOS\b/,SAMSUNG:/\bSamsungBrowser\b/,UCBROWSER:/\bUCBrowser\b/},DEVICES_RE:Dit,OS_VERSIONS_RE_MAP:Rit,BROWSER_VERSIONS_RE_MAP:Lit,OS_VERSIONS_RE:Fit,BROWSER_VERSIONS_RE:Nit}),Hit=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,[{key:"test",value:function(t,e){var n=this;return"string"==typeof e&&(e=new RegExp(e)),e instanceof RegExp?e.test(t):e&&Array.isArray(e.and)?e.and.every((function(e){return n.test(t,e)})):e&&Array.isArray(e.or)?e.or.some((function(e){return n.test(t,e)})):!(!e||!e.not||n.test(t,e.not))}},{key:"exec",value:function(t,e){var n=this;return"string"==typeof e&&(e=new RegExp(e)),e instanceof RegExp?e.exec(t):e&&Array.isArray(e)?e.reduce((function(e,i){return e||n.exec(t,i)}),null):null}}]),t}(),zit=function(){var t=function(){function t(e){Object(m.a)(this,t),this.platformId=e,this.ua="",this.userAgent="",this.os="",this.browser="",this.device="",this.os_version="",this.browser_version="",this.reTree=new Hit,dd(this.platformId)&&"undefined"!=typeof window&&(this.userAgent=window.navigator.userAgent),this.setDeviceInfo(this.userAgent)}return Object(g.a)(t,[{key:"setDeviceInfo",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.userAgent;e!==this.userAgent&&(this.userAgent=e);var n=[{const:"OS",prop:"os"},{const:"BROWSERS",prop:"browser"},{const:"DEVICES",prop:"device"},{const:"OS_VERSIONS",prop:"os_version"}];if(n.forEach((function(n){t[n.prop]=Object.keys(Bit[n.const]).reduce((function(i,r){return"device"===Bit[n.const][r]&&dd(t.platformId)&&(t.reTree.test(t.userAgent,jit.iPad)||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1)?(i[Bit[n.const][r]]="iPad",Object):(i[Bit[n.const][r]]=t.reTree.test(e,Bit["".concat(n.const,"_RE")][r]),i)}),{})})),n.forEach((function(e){t[e.prop]=Object.keys(Bit[e.const]).map((function(t){return Bit[e.const][t]})).reduce((function(n,i){return"device"===e.prop&&n===Bit[e.const].ANDROID?t[e.prop][i]?i:n:n===Bit[e.const].UNKNOWN&&t[e.prop][i]?i:n}),Bit[e.const].UNKNOWN)})),this.browser_version="0",this.browser!==Pit.UNKNOWN){var i=Nit[this.browser],r=this.reTree.exec(e,i);r&&(this.browser_version=r[1])}}},{key:"getDeviceInfo",value:function(){return{userAgent:this.userAgent,os:this.os,browser:this.browser,device:this.device,os_version:this.os_version,browser_version:this.browser_version}}},{key:"isMobile",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.userAgent;if(this.isTablet(e))return!1;var n=Object.keys(Ait).find((function(n){return t.reTree.test(e,Ait[n])}));return!!n}},{key:"isTablet",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.userAgent;if(dd(this.platformId)&&(this.reTree.test(this.userAgent,jit.iPad)||"undefined"!=typeof navigator&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1))return!0;var n=Object.keys(jit).find((function(n){return!!t.reTree.test(e,jit[n])}));return!!n}},{key:"isDesktop",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.userAgent,e=[Iit.PS4,Iit.CHROME_BOOK,Iit.UNKNOWN];return(this.device!==Iit.UNKNOWN||!this.isMobile(t)&&!this.isTablet(t))&&e.indexOf(this.device)>-1}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(vl))},t.\u0275prov=R({token:t,factory:function(e){return t.\u0275fac(e)},providedIn:"root"}),t.ngInjectableDef=L({factory:function(){return new t(wt(vl))},token:t,providedIn:"root"}),t}(),Vit=function(){var t=Eit=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"forRoot",value:function(){return{ngModule:Eit,providers:[zit]}}}]),t}();return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd]]}),t}();function Uit(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Name for screenshot is required"),va())}function qit(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Entered name is incorrect"),va())}var Git=function(t){return{"is-invalid":t}},Wit=function(){function t(t,e,n,i,r){this.dialogRef=t,this.toasterService=e,this.formBuilder=n,this.electronService=i,this.deviceService=r,this.filetype="svg",this.nameForm=this.formBuilder.group({screenshotName:new hp("screenshot-"+Date.now(),[kf.required])}),this.isPngAvailable=this.electronService.isWindows||"Windows"===this.deviceService.getDeviceInfo().os}return t.prototype.ngOnInit=function(){},Object.defineProperty(t.prototype,"form",{get:function(){return this.nameForm.controls},enumerable:!1,configurable:!0}),t.prototype.onAddClick=function(){if(!this.nameForm.invalid){var t={name:this.nameForm.get("screenshotName").value,filetype:this.filetype};this.dialogRef.close(t)}},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.onKeyDown=function(t){"Enter"===t.key&&this.onAddClick()},t.prototype.setFiletype=function(t){this.isPngAvailable&&(this.filetype=t)},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(Y2),da(Jp),da(mX),da(zit))},t.\u0275cmp=Ht({type:t,selectors:[["app-screenshot-dialog"]],decls:17,vars:7,consts:[["mat-dialog-title",""],["aria-label","Sorting",1,"radio-group"],["value","1","checked","",3,"click"],["value","2",3,"disabled","click"],[1,"name-form",3,"formGroup"],[1,"name-form"],["matInput","","type","text","formControlName","screenshotName","placeholder","Please enter name",3,"ngClass","keydown"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Take a screenshot"),va(),ga(2,"mat-radio-group",1),ga(3,"mat-radio-button",2),xa("click",(function(){return e.setFiletype("svg")})),ds(4,"SVG"),va(),ga(5,"mat-radio-button",3),xa("click",(function(){return e.setFiletype("png")})),ds(6,"PNG"),va(),va(),ga(7,"form",4),ga(8,"mat-form-field",5),ga(9,"input",6),xa("keydown",(function(t){return e.onKeyDown(t)})),va(),ua(10,Uit,2,0,"mat-error",7),ua(11,qit,2,0,"mat-error",7),va(),ga(12,"div",8),ga(13,"button",9),xa("click",(function(){return e.onNoClick()})),ds(14,"Cancel"),va(),ga(15,"button",10),xa("click",(function(){return e.onAddClick()})),ds(16,"Take a screenshot"),va(),va(),va()),2&t&&(Qi(5),pa("disabled",!e.isPngAvailable),Qi(2),pa("formGroup",e.nameForm),Qi(2),pa("ngClass",Ic(5,Git,null==e.form.acreenshotName?null:e.form.acreenshotName.errors)),Qi(1),pa("ngIf",(null==e.form.screenshotName?null:e.form.screenshotName.touched)&&(null==e.form.screenshotName?null:e.form.screenshotName.errors)&&(null==e.form.screenshotName?null:e.form.screenshotName.errors.required)),Qi(1),pa("ngIf",(null==e.form.screenshotName?null:e.form.screenshotName.touched)&&(null==e.form.screenshotName?null:e.form.screenshotName.errors)&&(null==e.form.acreenshotName?null:e.form.acreenshotName.errors.invalidName)))},directives:[r1,A6,D6,xp,gf,Pp,Y3,s5,cf,mf,Fp,Oh,Ah,a1,a2,R3],styles:[".name-form[_ngcontent-%COMP%]{width:100%}.radio-group[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"]}),t}(),Kit=function(){function t(t,e){var n=this;this._mainTheme$=new Pm.a("theme-default"),this._darkMode$=new Pm.a(!1),this.themeLinks=[],this.darkMode$=this._darkMode$.asObservable(),this.themeChanged=new Uc,this.savedTheme="dark",this.head=e.head,this._renderer=t.createRenderer(null,null),this.theme$=Object(OX.b)(this._mainTheme$,this._darkMode$),this.theme$.subscribe((function(t){var e=t[0],i=t[1];return UQ(n,void 0,void 0,(function(){return qQ(this,(function(t){switch(t.label){case 0:return[4,this.loadCss(i?e+"-dark.css":e+".css")];case 1:return t.sent(),2==this.themeLinks.length&&this._renderer.removeChild(this.head,this.themeLinks.shift()),[2]}}))}))}))}return t.prototype.getActualTheme=function(){return this.savedTheme},t.prototype.setMainTheme=function(t){this._mainTheme$.next(t)},t.prototype.setDarkMode=function(t){this._darkMode$.next(t),localStorage.removeItem("theme"),t?(this.savedTheme="dark",this.themeChanged.emit(this.savedTheme),localStorage.setItem("theme","dark")):(this.savedTheme="light",this.themeChanged.emit(this.savedTheme),localStorage.setItem("theme","light"))},t.prototype.loadCss=function(t){return UQ(this,void 0,void 0,(function(){var e=this;return qQ(this,(function(n){return[2,new Promise((function(n){var i=e._renderer.createElement("link");e._renderer.setAttribute(i,"rel","stylesheet"),e._renderer.setAttribute(i,"type","text/css"),e._renderer.setAttribute(i,"href",t),e._renderer.setProperty(i,"onload",n),e._renderer.appendChild(e.head,i),e.themeLinks=GQ(e.themeLinks,[i])}))]}))}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Gs),_t(du))},providedIn:"root"}),t}(),Xit=function(){function t(){}return t.prototype.getDrawingElement=function(){var t=new z0;return t.height=100,t.width=100,t.fill="#000000",t.fill_opacity=0,t.font_family="Noto Sans",t.font_size=11,t.font_weight="bold",t},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Yit=function(){function t(){}return t.prototype.getDrawingElement=function(){var t=new k9;return t.fill="#ffffff",t.fill_opacity=1,t.stroke="#000000",t.stroke_width=2,t.cx=100,t.cy=100,t.rx=100,t.ry=100,t.width=200,t.height=200,t},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Zit=function(){function t(){}return t.prototype.getDrawingElement=function(){var t=new b9;return t.fill="#ffffff",t.fill_opacity=1,t.stroke="#000000",t.stroke_width=2,t.width=200,t.height=100,t},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),Qit=function(){function t(){}return t.prototype.getDrawingElement=function(){var t=new _9;return t.stroke="#000000",t.stroke_width=2,t.x1=0,t.x2=200,t.y1=0,t.y2=0,t.width=100,t.height=0,t},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),$it=function(){function t(t,e,n,i){this.textElementFactory=t,this.ellipseElementFactory=e,this.rectangleElementFactory=n,this.lineElementFactory=i,this.availableFactories={text:this.textElementFactory,ellipse:this.ellipseElementFactory,rectangle:this.rectangleElementFactory,line:this.lineElementFactory}}return t.prototype.getDrawingMock=function(t){this.factory=this.availableFactories[t];var e=new I9;return e.element=this.factory.getDrawingElement(),e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Xit),_t(Yit),_t(Zit),_t(Qit))}}),t}(),Jit=function(){function t(t,e,n,i,r){this.drawingService=t,this.drawingsDataSource=e,this.drawingsEventSource=n,this.drawingsFactory=i,this.mapDrawingToSvgConverter=r,this.drawingSaved=new Uc}return t.prototype.ngOnInit=function(){var t=this;this.pointToAddSelected=this.drawingsEventSource.pointToAddSelected.subscribe((function(e){return t.onDrawingSaved(e)}))},t.prototype.ngOnChanges=function(t){t.selectedDrawing&&!t.selectedDrawing.isFirstChange()&&(this.selectedDrawing=t.selectedDrawing.currentValue,"text"!==this.selectedDrawing&&this.drawingsEventSource.selected.emit(this.selectedDrawing))},t.prototype.onDrawingSaved=function(t){var e=this,n=this.drawingsFactory.getDrawingMock(this.selectedDrawing),i=this.mapDrawingToSvgConverter.convert(n);this.drawingService.add(this.server,this.project.project_id,t.x,t.y,i).subscribe((function(t){e.drawingsDataSource.add(t),e.drawingSaved.emit(!0)}))},t.prototype.ngOnDestroy=function(){this.pointToAddSelected.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(x9),da(E9),da(Jnt),da($it),da(R9))},t.\u0275cmp=Ht({type:t,selectors:[["app-drawing-added"]],inputs:{server:"server",project:"project",selectedDrawing:"selectedDrawing"},outputs:{drawingSaved:"drawingSaved"},features:[Ms],decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),trt=function(t){return{selected:t}};function ert(t,e){if(1&t){var n=ka();ga(0,"button",12),xa("click",(function(){return Se(n),Aa().addDrawing("line")})),Qe(),ga(1,"svg",13),ba(2,"line",14),va(),va()}if(2&t){var i=Aa();Qi(2),pa("ngClass",Ic(1,trt,i.drawTools.isLineChosen))}}function nrt(t,e){if(1&t){var n=ka();ga(0,"button",12),xa("click",(function(){return Se(n),Aa().addDrawing("line")})),Qe(),ga(1,"svg",13),ba(2,"line",15),va(),va()}if(2&t){var i=Aa();Qi(2),pa("ngClass",Ic(1,trt,i.drawTools.isLineChosen))}}var irt=function(t,e){return{unmarkedLight:t,marked:e}},rrt=function(t){return{unmarkedLight:t}},ort=function(){function t(t,e,n,i,r,o){this.toolsService=t,this.mapSettingsService=e,this.drawingService=n,this.symbolService=i,this.dialog=r,this.themeService=o,this.drawTools={isRectangleChosen:!1,isEllipseChosen:!1,isLineChosen:!1,isTextChosen:!1},this.isLocked=!1,this.isLightThemeEnabled=!1}return t.prototype.ngOnInit=function(){this.isLightThemeEnabled="light"===this.themeService.getActualTheme()},t.prototype.getCssClassForIcon=function(t){return"text"===t?{unmarkedLight:!this.drawTools.isTextChosen&&this.isLightThemeEnabled,marked:this.drawTools.isTextChosen}:"rectangle"===t?{unmarkedLight:!this.drawTools.isRectangleChosen&&this.isLightThemeEnabled,marked:this.drawTools.isRectangleChosen}:{unmarkedLight:!this.drawTools.isEllipseChosen&&this.isLightThemeEnabled,marked:this.drawTools.isEllipseChosen}},t.prototype.takeScreenshot=function(){var t=this;this.dialog.open(Wit,{width:"400px",autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(e){e&&t.saveImage(e)}))},t.prototype.saveImage=function(t){return UQ(this,void 0,void 0,(function(){var e,n,i,r,o,a,s,c;return qQ(this,(function(l){switch(l.label){case 0:if("png"!==t.filetype)return[3,4];e=document.getElementsByTagName("svg")[0].outerHTML.split("image"),n=1,l.label=1;case 1:return n<e.length?(i=e[n].split('"'),r=i[1].split("/"),[4,this.symbolService.raw(this.server,r[7]).toPromise()]):[3,3];case 2:return o=l.sent(),a=o.split("--\x3e"),e[n]=a[1].substring(2),n+=2,[3,1];case 3:return s=e.join(),(c=document.createElement("div")).innerHTML=s,kit.saveSvgAsPng(c.firstChild,t.name+".png"),[3,5];case 4:Ww("svg").attr("version",1.1).attr("xmlns","http://www.w3.org/2000/svg").node(),u=Ww("svg").node(),h=""+t.name,function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"untitled",n=URL.createObjectURL(new Blob([t.source],{type:"text/xml"}));Tit("".concat(e,".svg"),n,(function(){return URL.revokeObjectURL(n)}))}(function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.css,i=void 0===n?"inline":n;if(!(t instanceof SVGElement))throw new Error("SVG element is required");t.setAttribute("version","1.1"),t.removeAttribute("xmlns"),t.removeAttribute("xlink"),t.hasAttributeNS(Sit,"xmlns")||t.setAttributeNS(Sit,"xmlns","http://www.w3.org/2000/svg"),t.hasAttributeNS(Sit,"xmlns:xlink")||t.setAttributeNS(Sit,"xmlns:xlink","http://www.w3.org/1999/xlink"),"inline"===i?Oit(t,xit()):"internal"===i&&Mit(t);var r=(new XMLSerializer).serializeToString(t),o=t.getBoundingClientRect(),a={top:o.top,left:o.left,width:o.width,height:o.height,class:t.getAttribute("class"),id:t.getAttribute("id"),name:t.getAttribute("name"),childElementCount:t.childElementCount,source:Cit+r};return a}(u,d),h||function(t){if(!(t instanceof SVGElement))throw new Error("SVG Element is required");return t.getAttribute("id")||t.getAttribute("class")||document.title.replace(/[^a-z0-9]/gi,"-").toLowerCase()||"untitled"}(u)),l.label=5;case 5:return[2]}var u,h,d}))}))},t.prototype.addDrawing=function(t){switch(t){case"rectangle":this.drawTools.isTextChosen=!1,this.drawTools.isEllipseChosen=!1,this.drawTools.isRectangleChosen=!this.drawTools.isRectangleChosen,this.drawTools.isLineChosen=!1;break;case"ellipse":this.drawTools.isTextChosen=!1,this.drawTools.isEllipseChosen=!this.drawTools.isEllipseChosen,this.drawTools.isRectangleChosen=!1,this.drawTools.isLineChosen=!1;break;case"line":this.drawTools.isTextChosen=!1,this.drawTools.isEllipseChosen=!1,this.drawTools.isRectangleChosen=!1,this.drawTools.isLineChosen=!this.drawTools.isLineChosen;break;case"text":this.drawTools.isTextChosen=!this.drawTools.isTextChosen,this.drawTools.isEllipseChosen=!1,this.drawTools.isRectangleChosen=!1,this.drawTools.isLineChosen=!1,this.toolsService.textAddingToolActivation(this.drawTools.isTextChosen)}this.selectedDrawing=this.selectedDrawing===t?"":t},t.prototype.onDrawingSaved=function(){this.resetDrawToolChoice()},t.prototype.resetDrawToolChoice=function(){this.drawTools.isRectangleChosen=!1,this.drawTools.isEllipseChosen=!1,this.drawTools.isLineChosen=!1,this.drawTools.isTextChosen=!1,this.selectedDrawing="",this.toolsService.textAddingToolActivation(this.drawTools.isTextChosen)},t.prototype.changeLockValue=function(){this.isLocked=!this.isLocked,this.mapSettingsService.changeMapLockValue(this.isLocked)},t.prototype.uploadImageFile=function(t){this.readImageFile(t.target)},t.prototype.readImageFile=function(t){var e=this,n=t.files[0],i=new FileReader,r=new Image;i.onloadend=function(){var t=e.createSvgFileForImage(i.result,r);e.drawingService.add(e.server,e.project.project_id,-r.width/2,-r.height/2,t).subscribe((function(){}))},r.onload=function(){i.readAsDataURL(n)},r.src=window.URL.createObjectURL(n)},t.prototype.createSvgFileForImage=function(t,e){return'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="'+e.height+'" \n width="'+e.width+'">\n<image height="'+e.height+'" width="'+e.width+'" xlink:href="'+t+'"/>\n</svg>'},t.prototype.ngOnDestroy=function(){},t.\u0275fac=function(e){return new(e||t)(da($nt),da($8),da(x9),da(a9),da(e1),da(Kit))},t.\u0275cmp=Ht({type:t,selectors:[["app-project-map-menu"]],inputs:{project:"project",server:"server"},decls:24,vars:15,consts:[["matTooltip","Add a note","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],[3,"ngClass"],["type","file","accept",".svg, .bmp, .jpeg, .jpg, .gif, .png",1,"non-visible",3,"change"],["file",""],["matTooltip","Insert a picture","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["matTooltip","Draw a rectangle","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["matTooltip","Draw an ellipse","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["matTooltip","Draw a line","matTooltipClass","custom-tooltip","mat-icon-button","","class","menu-button",3,"click",4,"ngIf"],["matTooltip","Lock or unlock all items","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["matTooltip","Take a screenshot","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],[3,"server","project","selectedDrawing","drawingSaved"],["id","crowbar-workspace"],["matTooltip","Draw a line","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["height","40","width","40"],["x1","30","y1","10","x2","10","y2","30",2,"stroke","white","stroke-width","2",3,"ngClass"],["x1","30","y1","10","x2","10","y2","30",2,"stroke","black","stroke-width","2",3,"ngClass"]],template:function(t,e){if(1&t){var n=ka();ga(0,"button",0),xa("click",(function(){return e.addDrawing("text")})),ga(1,"mat-icon",1),ds(2,"create"),va(),va(),ga(3,"input",2,3),xa("change",(function(t){return e.uploadImageFile(t)})),va(),ga(5,"button",4),xa("click",(function(){return Se(n),ha(4).click()})),ga(6,"mat-icon"),ds(7,"image"),va(),va(),ga(8,"button",5),xa("click",(function(){return e.addDrawing("rectangle")})),ga(9,"mat-icon",1),ds(10,"crop_3_2"),va(),va(),ga(11,"button",6),xa("click",(function(){return e.addDrawing("ellipse")})),ga(12,"mat-icon",1),ds(13,"panorama_fish_eye"),va(),va(),ua(14,ert,3,3,"button",7),ua(15,nrt,3,3,"button",7),ga(16,"button",8),xa("click",(function(){return e.changeLockValue()})),ga(17,"mat-icon",1),ds(18,"lock"),va(),va(),ga(19,"button",9),xa("click",(function(){return e.takeScreenshot()})),ga(20,"mat-icon",1),ds(21,"photo_camera"),va(),va(),ga(22,"app-drawing-added",10),xa("drawingSaved",(function(){return e.onDrawingSaved()})),va(),ba(23,"div",11)}2&t&&(Qi(1),pa("ngClass",e.getCssClassForIcon("text")),Qi(8),pa("ngClass",e.getCssClassForIcon("rectangle")),Qi(3),pa("ngClass",e.getCssClassForIcon("ellipse")),Qi(2),pa("ngIf",!e.isLightThemeEnabled),Qi(1),pa("ngIf",e.isLightThemeEnabled),Qi(2),pa("ngClass",Dc(10,irt,!e.isLocked&&e.isLightThemeEnabled,e.isLocked)),Qi(3),pa("ngClass",Ic(13,rrt,!e.isLocked&&e.isLightThemeEnabled)),Qi(2),pa("server",e.server)("project",e.project)("selectedDrawing",e.selectedDrawing))},directives:[a2,k4,x2,Oh,Ah,Jit],styles:[".menu-button[_ngcontent-%COMP%]{outline:0!important;transition:.5s;margin-bottom:16px;width:40px;margin-right:12px!important;margin-left:12px!important;background:transparent;padding:0;border:none;background-color:transparent}mat-divider.divider[_ngcontent-%COMP%]{height:40px;margin-left:1px;margin-right:7px;width:10px;color:grey}.non-visible[_ngcontent-%COMP%]{display:none}.unmarked[_ngcontent-%COMP%]{color:#fff!important}.unmarkedLight[_ngcontent-%COMP%]{color:#000!important}.marked[_ngcontent-%COMP%]{color:#0097a7!important}"],changeDetection:0}),t}(),art=n("EcEN");function srt(t,e){if(1&t){var n=ka();ga(0,"div",1),ga(1,"button",2),xa("click",(function(){return Se(n),Aa().onNoClick()})),ds(2,"No"),va(),ga(3,"button",3),xa("click",(function(){return Se(n),Aa().onYesClick()})),ds(4," Yes "),va(),va()}}function crt(t,e){if(1&t){var n=ka();ga(0,"div",1),ga(1,"button",4),xa("click",(function(){return Se(n),Aa().onNoClick()})),ds(2,"Ok"),va(),va()}}var lrt=function(){function t(t,e){this.dialogRef=t,this.data=e,this.existingProject=e.existingProject}return t.prototype.ngOnInit=function(){"opened"===this.existingProject.status?(this.confirmationMessage="Project "+this.existingProject.name+" is open. You can not overwrite it.",this.isOpen=!0):this.confirmationMessage="Project "+this.existingProject.name+" already exist, overwrite it?"},t.prototype.onNoClick=function(){this.dialogRef.close(!1)},t.prototype.onYesClick=function(){this.dialogRef.close(!0)},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(Q0))},t.\u0275cmp=Ht({type:t,selectors:[["app-import-project-dialog"]],decls:4,vars:3,consts:[["mat-dialog-actions","",4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",1,"cancelButton",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",1,"confirmButton",3,"click"],["mat-button","","color","accent",3,"click"]],template:function(t,e){1&t&&(ga(0,"span"),ds(1),va(),ua(2,srt,5,0,"div",0),ua(3,crt,3,0,"div",0)),2&t&&(Qi(1),fs(e.confirmationMessage),Qi(1),pa("ngIf",!e.isOpen),Qi(1),pa("ngIf",e.isOpen))},directives:[Ah,a1,a2],styles:[""]}),t}(),urt=function(){function t(){}return t.prototype.get=function(t){return new RegExp(/[~`!#$%\^&*+=\[\]\\';,/{}|\\":<>\?]/).test(t.value)?{invalidName:!0}:null},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function hrt(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Project name is required"),va())}function drt(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Project name is incorrect"),va())}var frt=function(t){return{empty:t}},prt=function(t){return{"is-invalid":t}},mrt=function(t){return{width:t}},grt=function(){function t(t,e,n,i,r,o){this.dialog=t,this.dialogRef=e,this.data=n,this.formBuilder=i,this.projectService=r,this.projectNameValidator=o,this.isImportEnabled=!1,this.isFinishEnabled=!1,this.isDeleteVisible=!1,this.resultMessage="The project is being imported... Please wait",this.submitted=!1,this.isFirstStepCompleted=!1,this.onImportProject=new Uc,this.projectNameForm=this.formBuilder.group({projectName:new hp(null,[kf.required,o.get])})}return t.prototype.ngOnInit=function(){var t=this;this.uploader=new wX({}),this.uploader.onAfterAddingFile=function(t){t.withCredentials=!1},this.uploader.onErrorItem=function(e,n,i,r){var o=JSON.parse(n);t.resultMessage="An error occured: "+o.message,t.isFinishEnabled=!0},this.uploader.onCompleteItem=function(e,n,i,r){t.onImportProject.emit(t.uuid),t.resultMessage="Project was imported succesfully!",t.isFinishEnabled=!0}},Object.defineProperty(t.prototype,"form",{get:function(){return this.projectNameForm.controls},enumerable:!1,configurable:!0}),t.prototype.uploadProjectFile=function(t){this.projectNameForm.controls.projectName.setValue(t.target.files[0].name.split(".")[0]),this.isImportEnabled=!0,this.isDeleteVisible=!0},t.prototype.onImportClick=function(){var t=this;this.projectNameForm.invalid?this.submitted=!0:this.projectService.list(this.server).subscribe((function(e){var n=t.projectNameForm.controls.projectName.value,i=e.find((function(t){return t.name===n}));i?t.openConfirmationDialog(i):t.importProject()}))},t.prototype.importProject=function(){var t=this.prepareUploadPath();this.uploader.queue.forEach((function(e){return e.url=t})),this.isFirstStepCompleted=!0,this.uploader.uploadItem(this.uploader.queue[0])},t.prototype.openConfirmationDialog=function(t){var e=this;this.dialog.open(lrt,{width:"300px",height:"150px",data:{existingProject:t},autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(n){n&&e.projectService.close(e.server,t.project_id).subscribe((function(){e.projectService.delete(e.server,t.project_id).subscribe((function(){e.importProject()}))}))}))},t.prototype.onNoClick=function(){this.uploader.cancelAll(),this.dialogRef.close()},t.prototype.onFinishClick=function(){this.dialogRef.close()},t.prototype.onDeleteClick=function(){this.uploader.queue.pop(),this.isImportEnabled=!1,this.isDeleteVisible=!1,this.projectNameForm.controls.projectName.setValue("")},t.prototype.prepareUploadPath=function(){return this.uuid=Object(art.v4)(),this.projectService.getUploadPath(this.server,this.uuid,this.projectNameForm.controls.projectName.value)},t.\u0275fac=function(e){return new(e||t)(da(e1),da(Z0),da(Q0),da(Jp),da($Q),da(urt))},t.\u0275cmp=Ht({type:t,selectors:[["app-import-project-dialog"]],features:[Ns([urt])],decls:29,vars:19,consts:[["mat-dialog-title",""],[3,"hidden"],[1,"file-name-form",3,"formGroup"],["type","file","accept",".gns3project, .gns3p","ng2FileSelect","",1,"non-visible",3,"uploader","change"],["file",""],["mat-raised-button","","color","primary","matTooltip","Import your .gns3p or .gns3project file","matTooltipClass","custom-tooltip",1,"file-button",3,"click"],[1,"file-name-form-field",3,"ngClass"],["matInput","","type","text","formControlName","projectName","placeholder","Please enter name",3,"ngClass"],[4,"ngIf"],[1,"delete-button",3,"hidden"],["color","primary",1,"delete-icon",3,"click"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"disabled","click"],[1,"progress"],["role","progressbar",1,"progress-bar",3,"ngStyle"],[1,"result-message-box"]],template:function(t,e){if(1&t){var n=ka();ga(0,"h1",0),ds(1,"Import project"),va(),ga(2,"div",1),ga(3,"form",2),ga(4,"input",3,4),xa("change",(function(t){return e.uploadProjectFile(t)})),va(),ga(6,"button",5),xa("click",(function(){return Se(n),ha(5).click()})),ds(7,"Choose file"),va(),ga(8,"mat-form-field",6),ba(9,"input",7),ua(10,hrt,2,0,"mat-error",8),ua(11,drt,2,0,"mat-error",8),va(),ga(12,"button",9),ga(13,"mat-icon",10),xa("click",(function(){return e.onDeleteClick()})),ds(14,"clear"),va(),va(),ga(15,"div",11),ga(16,"button",12),xa("click",(function(){return e.onNoClick()})),ds(17,"Cancel"),va(),ga(18,"button",13),xa("click",(function(){return e.onImportClick()})),ds(19," Import "),va(),va(),va(),va(),ga(20,"div",1),ga(21,"div",14),ba(22,"div",15),va(),ga(23,"div",16),ga(24,"span"),ds(25),va(),va(),ga(26,"div",11),ga(27,"button",13),xa("click",(function(){return e.onNoClick()})),ds(28," Finish "),va(),va(),va()}2&t&&(Qi(2),pa("hidden",e.isFirstStepCompleted),Qi(1),pa("formGroup",e.projectNameForm),Qi(1),pa("uploader",e.uploader),Qi(4),pa("ngClass",Ic(13,frt,!e.isDeleteVisible)),Qi(1),pa("ngClass",Ic(15,prt,e.form.projectName.errors)),Qi(1),pa("ngIf",e.form.projectName.errors&&e.form.projectName.errors.required),Qi(1),pa("ngIf",e.form.projectName.errors&&e.form.projectName.errors.invalidName),Qi(1),pa("hidden",!e.isDeleteVisible),Qi(6),pa("disabled",!e.isImportEnabled),Qi(2),pa("hidden",!e.isFirstStepCompleted),Qi(2),pa("ngStyle",Ic(17,mrt,e.uploader.progress+"%")),Qi(3),fs(e.resultMessage),Qi(2),pa("disabled",!e.isFinishEnabled))},directives:[r1,xp,gf,Pp,kX,a2,k4,Y3,Oh,s5,cf,mf,Fp,Ah,x2,a1,Hh,R3],styles:['.non-visible[_ngcontent-%COMP%]{display:none}.file-button[_ngcontent-%COMP%]{width:100%;margin-top:5px;margin-bottom:10px;padding:0}.file-name-form[_ngcontent-%COMP%]{float:right;width:100%}.file-name-form-field[_ngcontent-%COMP%]{width:90%}.empty[_ngcontent-%COMP%]{width:100%}.delete-button[_ngcontent-%COMP%]{background:transparent;border:none;outline:0;width:10%}.delete-icon[_ngcontent-%COMP%]{vertical-align:"middle"}.result-message-box[_ngcontent-%COMP%]{margin-top:10px;text-align:center}.progress-bar[_ngcontent-%COMP%]{background-color:#0097a7}']}),t}();function vrt(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Project name is required"),va())}function brt(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Project name is incorrect"),va())}function yrt(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Project with this name exists"),va())}var _rt=function(t){return{"is-invalid":t}},wrt=function(){function t(t,e,n,i,r,o,a){this.dialogRef=t,this.router=e,this.dialog=n,this.projectService=i,this.toasterService=r,this.formBuilder=o,this.projectNameValidator=a,this.onAddProject=new Uc}return t.prototype.ngOnInit=function(){var t,e;this.projectNameForm=this.formBuilder.group({projectName:new hp(null,[kf.required,this.projectNameValidator.get],[(t=this.server,e=this.projectService,function(n){return Object(l1.a)(500).pipe(Object(LX.a)((function(){return e.list(t)})),Object(ef.a)((function(t){return t.find((function(t){return t.name===n.value}))?{projectExist:!0}:null})))})])})},Object.defineProperty(t.prototype,"form",{get:function(){return this.projectNameForm.controls},enumerable:!1,configurable:!0}),t.prototype.onAddClick=function(){var t=this;this.projectNameForm.invalid||this.projectService.list(this.server).subscribe((function(e){var n=t.projectNameForm.controls.projectName.value,i=e.find((function(t){return t.name===n}));i?t.openConfirmationDialog(i):t.addProject()}))},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.addProject=function(){var t=this;this.uuid=Object(art.v4)(),this.projectService.add(this.server,this.projectNameForm.controls.projectName.value,this.uuid).subscribe((function(e){t.dialogRef.close(),t.toasterService.success("Project "+e.name+" added"),t.router.navigate(["/server",t.server.id,"project",e.project_id])}))},t.prototype.onKeyDown=function(t){"Enter"===t.key&&this.onAddClick()},t.prototype.openConfirmationDialog=function(t){var e=this;this.dialog.open(lrt,{width:"300px",height:"150px",data:{existingProject:t},autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(n){n&&e.projectService.close(e.server,t.project_id).subscribe((function(){e.projectService.delete(e.server,t.project_id).subscribe((function(){e.addProject()}))}))}))},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(lQ),da(e1),da($Q),da(Y2),da(Jp),da(urt))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-blank-project-dialog"]],features:[Ns([urt])],decls:13,vars:7,consts:[["mat-dialog-title",""],[1,"file-name-form",3,"formGroup"],[1,"file-name-form-field"],["matInput","","type","text","formControlName","projectName","placeholder","Please enter name",3,"ngClass","keydown"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",1,"add-project-button",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Create new project"),va(),ga(2,"form",1),ga(3,"mat-form-field",2),ga(4,"input",3),xa("keydown",(function(t){return e.onKeyDown(t)})),va(),ua(5,vrt,2,0,"mat-error",4),ua(6,brt,2,0,"mat-error",4),ua(7,yrt,2,0,"mat-error",4),va(),ga(8,"div",5),ga(9,"button",6),xa("click",(function(){return e.onNoClick()})),ds(10,"Cancel"),va(),ga(11,"button",7),xa("click",(function(){return e.onAddClick()})),ds(12,"Add project"),va(),va(),va()),2&t&&(Qi(2),pa("formGroup",e.projectNameForm),Qi(2),pa("ngClass",Ic(5,_rt,null==e.form.projectName?null:e.form.projectName.errors)),Qi(1),pa("ngIf",(null==e.form.projectName?null:e.form.projectName.touched)&&(null==e.form.projectName?null:e.form.projectName.errors)&&(null==e.form.projectName?null:e.form.projectName.errors.required)),Qi(1),pa("ngIf",(null==e.form.projectName?null:e.form.projectName.errors)&&(null==e.form.projectName?null:e.form.projectName.errors.invalidName)),Qi(1),pa("ngIf",(null==e.form.projectName?null:e.form.projectName.errors)&&(null==e.form.projectName?null:e.form.projectName.errors.projectExist)))},directives:[r1,xp,gf,Pp,Y3,s5,cf,mf,Fp,Oh,Ah,a1,a2,R3],styles:[".file-name-form-field[_ngcontent-%COMP%]{width:100%}.project-snackbar[_ngcontent-%COMP%]{background:#2196f3}"]}),t}();function krt(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Project name is required"),va())}function Crt(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Project name is incorrect"),va())}var Srt=function(t){return{"is-invalid":t}},xrt=function(){function t(t,e,n,i,r,o){this.dialogRef=t,this.projectService=e,this.nodesDataSource=n,this.toasterService=i,this.formBuilder=r,this.projectNameValidator=o,this.onAddProject=new Uc,this.projectNameForm=this.formBuilder.group({projectName:new hp(null,[kf.required,o.get])})}return t.prototype.ngOnInit=function(){},Object.defineProperty(t.prototype,"form",{get:function(){return this.projectNameForm.controls},enumerable:!1,configurable:!0}),t.prototype.onAddClick=function(){var t=this;this.projectNameForm.invalid||this.projectService.list(this.server).subscribe((function(e){var n=t.projectNameForm.controls.projectName.value;e.find((function(t){return t.name===n}))?t.toasterService.error("Project with this name already exists."):t.nodesDataSource.getItems().filter((function(t){return"started"===t.status&&"vpcs"===t.node_type||"started"===t.status&&"virtualbox"===t.node_type||"started"===t.status&&"vmware"===t.node_type})).length>0?t.toasterService.error("Please stop all nodes in order to save project."):t.addProject()}))},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.addProject=function(){var t=this;this.projectService.duplicate(this.server,this.project.project_id,this.projectNameForm.controls.projectName.value).subscribe((function(e){t.dialogRef.close(),t.toasterService.success("Project "+e.name+" added")}))},t.prototype.onKeyDown=function(t){"Enter"===t.key&&this.onAddClick()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da($Q),da(M9),da(Y2),da(Jp),da(urt))},t.\u0275cmp=Ht({type:t,selectors:[["app-save-project-dialog"]],features:[Ns([urt])],decls:12,vars:6,consts:[["mat-dialog-title",""],[1,"file-name-form",3,"formGroup"],[1,"file-name-form-field"],["matInput","","type","text","formControlName","projectName","placeholder","Please enter name",3,"ngClass","keydown"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Save project as"),va(),ga(2,"form",1),ga(3,"mat-form-field",2),ga(4,"input",3),xa("keydown",(function(t){return e.onKeyDown(t)})),va(),ua(5,krt,2,0,"mat-error",4),ua(6,Crt,2,0,"mat-error",4),va(),ga(7,"div",5),ga(8,"button",6),xa("click",(function(){return e.onNoClick()})),ds(9,"Cancel"),va(),ga(10,"button",7),xa("click",(function(){return e.onAddClick()})),ds(11,"Save project"),va(),va(),va()),2&t&&(Qi(2),pa("formGroup",e.projectNameForm),Qi(2),pa("ngClass",Ic(4,Srt,null==e.form.projectName?null:e.form.projectName.errors)),Qi(1),pa("ngIf",(null==e.form.projectName?null:e.form.projectName.touched)&&(null==e.form.projectName?null:e.form.projectName.errors)&&(null==e.form.projectName?null:e.form.projectName.errors.required)),Qi(1),pa("ngIf",(null==e.form.projectName?null:e.form.projectName.touched)&&(null==e.form.projectName?null:e.form.projectName.errors)&&(null==e.form.projectName?null:e.form.projectName.errors.invalidName)))},directives:[r1,xp,gf,Pp,Y3,s5,cf,mf,Fp,Oh,Ah,a1,a2,R3],styles:[".file-name-form-field[_ngcontent-%COMP%]{width:100%}.project-snackbar[_ngcontent-%COMP%]{background:#2196f3}"]}),t}();function Ort(t,e){1&t&&(ga(0,"th",26),ds(1,"Name"),va())}function Mrt(t,e){if(1&t&&(ga(0,"td",27),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps("",n.name," ")}}function Trt(t,e){1&t&&(ga(0,"th",26),ds(1,"Value"),va())}function Ert(t,e){if(1&t&&(ga(0,"td",27),ds(1),va()),2&t){var n=e.$implicit;Qi(1),fs(n.value)}}function Prt(t,e){1&t&&(ga(0,"th",26),ds(1,"Actions"),va())}function Art(t,e){if(1&t){var n=ka();ga(0,"td",27),ga(1,"button",28),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().deleteVariable(t)})),ga(2,"mat-icon",29),ds(3,"delete"),va(),va(),va()}}function jrt(t,e){1&t&&ba(0,"tr",30)}function Irt(t,e){1&t&&ba(0,"tr",31)}var Drt=function(){return{standalone:!0}},Rrt=function(){function t(t,e,n,i,r){this.dialogRef=t,this.formBuilder=e,this.projectService=n,this.toasterService=i,this.nonNegativeValidator=r,this.displayedColumns=["name","value","actions"],this.variables=[],this.formGroup=this.formBuilder.group({projectName:new hp("",[kf.required]),width:new hp("",[kf.required,r.get]),height:new hp("",[kf.required,r.get]),nodeGridSize:new hp("",[kf.required,r.get]),drawingGridSize:new hp("",[kf.required,r.get])}),this.variableFormGroup=this.formBuilder.group({name:new hp("",[kf.required]),value:new hp("",[kf.required])})}return t.prototype.ngOnInit=function(){var t=this;this.formGroup.controls.projectName.setValue(this.project.name),this.formGroup.controls.width.setValue(this.project.scene_width),this.formGroup.controls.height.setValue(this.project.scene_height),this.formGroup.controls.nodeGridSize.setValue(this.project.grid_size),this.formGroup.controls.drawingGridSize.setValue(this.project.drawing_grid_size),this.project.variables&&this.project.variables.forEach((function(e){return t.variables.push(e)})),this.auto_close=!this.project.auto_close},t.prototype.addVariable=function(){if(this.variableFormGroup.valid){var t={name:this.variableFormGroup.get("name").value,value:this.variableFormGroup.get("value").value};this.variables=this.variables.concat([t])}else this.toasterService.error("Fill all required fields with correct values.")},t.prototype.deleteVariable=function(t){this.variables=this.variables.filter((function(e){return e!==t}))},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.onYesClick=function(){var t=this;this.formGroup.valid?(this.project.name=this.formGroup.get("projectName").value,this.project.scene_width=this.formGroup.get("width").value,this.project.scene_height=this.formGroup.get("height").value,this.project.drawing_grid_size=this.formGroup.get("drawingGridSize").value,this.project.grid_size=this.formGroup.get("nodeGridSize").value,this.project.variables=this.variables,this.project.auto_close=!this.project.auto_close,this.projectService.update(this.server,this.project).subscribe((function(e){t.toasterService.success("Project "+e.name+" updated."),t.onNoClick()}))):this.toasterService.error("Fill all required fields with correct values.")},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(Jp),da($Q),da(Y2),da(L9))},t.\u0275cmp=Ht({type:t,selectors:[["app-edit-project-dialog"]],decls:49,vars:17,consts:[["mat-dialog-title",""],[1,"modal-form-container"],["label","General"],[3,"formGroup"],[1,"form-field"],["matInput","","formControlName","projectName","placeholder","Project name","type","text"],["matInput","","formControlName","width","placeholder","Scene width (px)","type","number"],["matInput","","formControlName","height","placeholder","Scene height (px)","type","number"],["matInput","","formControlName","nodeGridSize","placeholder","Node grid size","type","number"],["matInput","","formControlName","drawingGridSize","placeholder","Drawing grid size","type","number"],[3,"ngModelOptions","ngModel","ngModelChange"],["label","Global variables"],["matInput","","formControlName","name","placeholder","Name","type","text"],["matInput","","formControlName","value","placeholder","Value","type","text"],["mat-button","","mat-raised-button","","color","primary",1,"form-field",3,"click"],["mat-table","",1,"table",3,"dataSource"],["matColumnDef","name"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","value"],["matColumnDef","actions"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],["mat-header-cell",""],["mat-cell",""],["mat-icon-button","","matTooltip","Delete variable","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Delete adapter"],["mat-header-row",""],["mat-row",""]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Edit project"),va(),ga(2,"div",1),ga(3,"mat-tab-group"),ga(4,"mat-tab",2),ga(5,"form",3),ga(6,"mat-form-field",4),ba(7,"input",5),va(),ga(8,"mat-form-field",4),ba(9,"input",6),va(),ga(10,"mat-form-field",4),ba(11,"input",7),va(),ga(12,"mat-form-field",4),ba(13,"input",8),va(),ga(14,"mat-form-field",4),ba(15,"input",9),va(),va(),ga(16,"mat-checkbox",10),xa("ngModelChange",(function(t){return e.project.auto_open=t})),ds(17," Open this project in the background when GNS3 server starts "),va(),ga(18,"mat-checkbox",10),xa("ngModelChange",(function(t){return e.project.auto_start=t})),ds(19," Start all nodes when this project is opened "),va(),ga(20,"mat-checkbox",10),xa("ngModelChange",(function(t){return e.auto_close=t})),ds(21," Leave this project running in the background after closing "),va(),ga(22,"mat-checkbox",10),xa("ngModelChange",(function(t){return e.project.show_interface_labels=t})),ds(23," Show interface labels at start "),va(),va(),ga(24,"mat-tab",11),ga(25,"form",3),ga(26,"mat-form-field",4),ba(27,"input",12),va(),ga(28,"mat-form-field",4),ba(29,"input",13),va(),va(),ga(30,"button",14),xa("click",(function(){return e.addVariable()})),ds(31,"Add variable"),va(),ga(32,"table",15),ya(33,16),ua(34,Ort,2,0,"th",17),ua(35,Mrt,2,1,"td",18),_a(),ya(36,19),ua(37,Trt,2,0,"th",17),ua(38,Ert,2,1,"td",18),_a(),ya(39,20),ua(40,Prt,2,0,"th",17),ua(41,Art,4,0,"td",18),_a(),ua(42,jrt,1,0,"tr",21),ua(43,Irt,1,0,"tr",22),va(),va(),va(),va(),ga(44,"div",23),ga(45,"button",24),xa("click",(function(){return e.onNoClick()})),ds(46,"Cancel"),va(),ga(47,"button",25),xa("click",(function(){return e.onYesClick()})),ds(48,"Apply"),va(),va()),2&t&&(Qi(5),pa("formGroup",e.formGroup),Qi(11),pa("ngModelOptions",jc(13,Drt))("ngModel",e.project.auto_open),Qi(2),pa("ngModelOptions",jc(14,Drt))("ngModel",e.project.auto_start),Qi(2),pa("ngModelOptions",jc(15,Drt))("ngModel",e.auto_close),Qi(2),pa("ngModelOptions",jc(16,Drt))("ngModel",e.project.show_interface_labels),Qi(3),pa("formGroup",e.variableFormGroup),Qi(7),pa("dataSource",e.variables),Qi(10),pa("matHeaderRowDef",e.displayedColumns),Qi(1),pa("matRowDefColumns",e.displayedColumns))},directives:[r1,U1,I1,xp,gf,Pp,Y3,s5,cf,mf,Fp,Ef,F5,Sp,a2,$5,n4,t4,J5,a4,c4,a1,i4,o4,k4,x2,l4,h4],styles:[".form-field[_ngcontent-%COMP%]{width:100%}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}"]}),t}();function Lrt(t,e){}var Frt=new ht("MatBottomSheetData"),Nrt=function t(){Object(m.a)(this,t),this.data=null,this.hasBackdrop=!0,this.disableClose=!1,this.ariaLabel=null,this.closeOnNavigation=!0,this.autoFocus=!1,this.restoreFocus=!0},Brt={bottomSheetState:Jg("state",[rv("void, hidden",iv({transform:"translateY(100%)"})),rv("visible",iv({transform:"translateY(0%)"})),av("visible => void, visible => hidden",tv("".concat(Y$.COMPLEX," ").concat(X$.ACCELERATION_CURVE))),av("void => visible",tv("".concat(Y$.EXITING," ").concat(X$.DECELERATION_CURVE)))])},Hrt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s){var c;return Object(m.a)(this,n),(c=e.call(this))._elementRef=t,c._changeDetectorRef=i,c._focusTrapFactory=r,c.bottomSheetConfig=s,c._animationState="void",c._animationStateChanged=new Uc,c._elementFocusedBeforeOpened=null,c.attachDomPortal=function(t){return c._validatePortalAttached(),c._setPanelClass(),c._savePreviouslyFocusedElement(),c._portalOutlet.attachDomPortal(t)},c._document=a,c._breakpointSubscription=o.observe(["(min-width: 960px) and (max-width: 1279.99px)","(min-width: 1280px) and (max-width: 1919.99px)","(min-width: 1920px)"]).subscribe((function(){c._toggleClass("mat-bottom-sheet-container-medium",o.isMatched("(min-width: 960px) and (max-width: 1279.99px)")),c._toggleClass("mat-bottom-sheet-container-large",o.isMatched("(min-width: 1280px) and (max-width: 1919.99px)")),c._toggleClass("mat-bottom-sheet-container-xlarge",o.isMatched("(min-width: 1920px)"))})),c}return Object(g.a)(n,[{key:"attachComponentPortal",value:function(t){return this._validatePortalAttached(),this._setPanelClass(),this._savePreviouslyFocusedElement(),this._portalOutlet.attachComponentPortal(t)}},{key:"attachTemplatePortal",value:function(t){return this._validatePortalAttached(),this._setPanelClass(),this._savePreviouslyFocusedElement(),this._portalOutlet.attachTemplatePortal(t)}},{key:"enter",value:function(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.detectChanges())}},{key:"exit",value:function(){this._destroyed||(this._animationState="hidden",this._changeDetectorRef.markForCheck())}},{key:"ngOnDestroy",value:function(){this._breakpointSubscription.unsubscribe(),this._destroyed=!0}},{key:"_onAnimationDone",value:function(t){"hidden"===t.toState?this._restoreFocus():"visible"===t.toState&&this._trapFocus(),this._animationStateChanged.emit(t)}},{key:"_onAnimationStart",value:function(t){this._animationStateChanged.emit(t)}},{key:"_toggleClass",value:function(t,e){var n=this._elementRef.nativeElement.classList;e?n.add(t):n.remove(t)}},{key:"_validatePortalAttached",value:function(){if(this._portalOutlet.hasAttached())throw Error("Attempting to attach bottom sheet content after content is already attached")}},{key:"_setPanelClass",value:function(){var t=this._elementRef.nativeElement,e=this.bottomSheetConfig.panelClass;Array.isArray(e)?e.forEach((function(e){return t.classList.add(e)})):e&&t.classList.add(e)}},{key:"_trapFocus",value:function(){var t=this._elementRef.nativeElement;if(this._focusTrap||(this._focusTrap=this._focusTrapFactory.create(t)),this.bottomSheetConfig.autoFocus)this._focusTrap.focusInitialElementWhenReady();else{var e=this._document.activeElement;e===t||t.contains(e)||t.focus()}}},{key:"_restoreFocus",value:function(){var t=this._elementFocusedBeforeOpened;if(this.bottomSheetConfig.restoreFocus&&t&&"function"==typeof t.focus){var e=this._document.activeElement,n=this._elementRef.nativeElement;e&&e!==this._document.body&&e!==n&&!n.contains(e)||t.focus()}this._focusTrap&&this._focusTrap.destroy()}},{key:"_savePreviouslyFocusedElement",value:function(){var t=this;this._elementFocusedBeforeOpened=this._document.activeElement,this._elementRef.nativeElement.focus&&Promise.resolve().then((function(){return t._elementRef.nativeElement.focus()}))}}]),n}(L$);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(v$),da(R2),da(du,8),da(Nrt))},t.\u0275cmp=Ht({type:t,selectors:[["mat-bottom-sheet-container"]],viewQuery:function(t,e){var n;1&t&&el(B$,!0),2&t&&tl(n=sl())&&(e._portalOutlet=n.first)},hostAttrs:["tabindex","-1","role","dialog","aria-modal","true",1,"mat-bottom-sheet-container"],hostVars:2,hostBindings:function(t,e){1&t&&Oa("@state.start",(function(t){return e._onAnimationStart(t)}))("@state.done",(function(t){return e._onAnimationDone(t)})),2&t&&(oa("aria-label",null==e.bottomSheetConfig?null:e.bottomSheetConfig.ariaLabel),ys("@state",e._animationState))},features:[ws],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,e){1&t&&ua(0,Lrt,0,0,"ng-template",0)},directives:[B$],styles:[".mat-bottom-sheet-container{padding:8px 16px;min-width:100vw;box-sizing:border-box;display:block;outline:0;max-height:80vh;overflow:auto}.cdk-high-contrast-active .mat-bottom-sheet-container{outline:1px solid}.mat-bottom-sheet-container-xlarge,.mat-bottom-sheet-container-large,.mat-bottom-sheet-container-medium{border-top-left-radius:4px;border-top-right-radius:4px}.mat-bottom-sheet-container-medium{min-width:384px;max-width:calc(100vw - 128px)}.mat-bottom-sheet-container-large{min-width:512px;max-width:calc(100vw - 256px)}.mat-bottom-sheet-container-xlarge{min-width:576px;max-width:calc(100vw - 384px)}\n"],encapsulation:2,data:{animation:[Brt.bottomSheetState]},changeDetection:0}),t}(),zrt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[w0,$$,z$],$$]}),t}(),Vrt=function(){function t(e,n,i){var r=this;Object(m.a)(this,t),this._overlayRef=n,this._afterDismissed=new w.b,this._afterOpened=new w.b,this.containerInstance=e,this.disableClose=e.bottomSheetConfig.disableClose,e._animationStateChanged.pipe(Object(vg.a)((function(t){return"done"===t.phaseName&&"visible"===t.toState})),Object(FX.a)(1)).subscribe((function(){r._afterOpened.next(),r._afterOpened.complete()})),e._animationStateChanged.pipe(Object(vg.a)((function(t){return"done"===t.phaseName&&"hidden"===t.toState})),Object(FX.a)(1)).subscribe((function(){clearTimeout(r._closeFallbackTimeout),n.dispose()})),n.detachments().pipe(Object(FX.a)(1)).subscribe((function(){r._afterDismissed.next(r._result),r._afterDismissed.complete()})),Object(C.a)(n.backdropClick(),n.keydownEvents().pipe(Object(vg.a)((function(t){return 27===t.keyCode})))).subscribe((function(t){r.disableClose||"keydown"===t.type&&JQ(t)||(t.preventDefault(),r.dismiss())}))}return Object(g.a)(t,[{key:"dismiss",value:function(t){var e=this;this._afterDismissed.closed||(this.containerInstance._animationStateChanged.pipe(Object(vg.a)((function(t){return"start"===t.phaseName})),Object(FX.a)(1)).subscribe((function(t){e._closeFallbackTimeout=setTimeout((function(){e._overlayRef.dispose()}),t.totalTime+100),e._overlayRef.detachBackdrop()})),this._result=t,this.containerInstance.exit())}},{key:"afterDismissed",value:function(){return this._afterDismissed.asObservable()}},{key:"afterOpened",value:function(){return this._afterOpened.asObservable()}},{key:"backdropClick",value:function(){return this._overlayRef.backdropClick()}},{key:"keydownEvents",value:function(){return this._overlayRef.keydownEvents()}}]),t}(),Urt=new ht("mat-bottom-sheet-default-options"),qrt=function(){var t=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this._overlay=e,this._injector=n,this._parentBottomSheet=i,this._location=r,this._defaultOptions=o,this._bottomSheetRefAtThisLevel=null}return Object(g.a)(t,[{key:"open",value:function(t,e){var n=this,i=function(t,e){return Object.assign(Object.assign({},t),e)}(this._defaultOptions||new Nrt,e),r=this._createOverlay(i),o=this._attachContainer(r,i),a=new Vrt(o,r,this._location);if(t instanceof fc)o.attachTemplatePortal(new D$(t,null,{$implicit:i.data,bottomSheetRef:a}));else{var s=new I$(t,void 0,this._createInjector(i,a)),c=o.attachComponentPortal(s);a.instance=c.instance}return a.afterDismissed().subscribe((function(){n._openedBottomSheetRef==a&&(n._openedBottomSheetRef=null)})),this._openedBottomSheetRef?(this._openedBottomSheetRef.afterDismissed().subscribe((function(){return a.containerInstance.enter()})),this._openedBottomSheetRef.dismiss()):a.containerInstance.enter(),this._openedBottomSheetRef=a,a}},{key:"dismiss",value:function(t){this._openedBottomSheetRef&&this._openedBottomSheetRef.dismiss(t)}},{key:"ngOnDestroy",value:function(){this._bottomSheetRefAtThisLevel&&this._bottomSheetRefAtThisLevel.dismiss()}},{key:"_attachContainer",value:function(t,e){var n=new V$(e&&e.viewContainerRef&&e.viewContainerRef.injector||this._injector,new WeakMap([[Nrt,e]])),i=new I$(Hrt,e.viewContainerRef,n);return t.attach(i).instance}},{key:"_createOverlay",value:function(t){var e=new $J({direction:t.direction,hasBackdrop:t.hasBackdrop,disposeOnNavigation:t.closeOnNavigation,maxWidth:"100%",scrollStrategy:t.scrollStrategy||this._overlay.scrollStrategies.block(),positionStrategy:this._overlay.position().global().centerHorizontally().bottom("0")});return t.backdropClass&&(e.backdropClass=t.backdropClass),this._overlay.create(e)}},{key:"_createInjector",value:function(t,e){var n=t&&t.viewContainerRef&&t.viewContainerRef.injector,i=new WeakMap([[Vrt,e],[Frt,t.data]]);return!t.direction||n&&n.get(gm,null)||i.set(gm,{value:t.direction,change:Object(lm.a)()}),new V$(n||this._injector,i)}},{key:"_openedBottomSheetRef",get:function(){var t=this._parentBottomSheet;return t?t._openedBottomSheetRef:this._bottomSheetRefAtThisLevel},set:function(t){this._parentBottomSheet?this._parentBottomSheet._openedBottomSheetRef=t:this._bottomSheetRefAtThisLevel=t}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(m0),_t(Xo),_t(t,12),_t(Mu,8),_t(Urt,8))},t.\u0275prov=R({factory:function(){return new t(_t(m0),_t(dt),_t(t,12),_t(Mu,8),_t(Urt,8))},token:t,providedIn:zrt}),t}(),Grt=function(t){return{lightTheme:t}},Wrt=function(){function t(t,e){this.bottomSheetRef=t,this.themeService=e,this.projectMessage="",this.isLightThemeEnabled=!1}return t.prototype.ngOnInit=function(){this.isLightThemeEnabled="light"===this.themeService.getActualTheme()},t.prototype.onNoClick=function(){this.bottomSheetRef.dismiss(!1)},t.prototype.onYesClick=function(){this.bottomSheetRef.dismiss(!0)},t.\u0275fac=function(e){return new(e||t)(da(Vrt),da(Kit))},t.\u0275cmp=Ht({type:t,selectors:[["app-navigation-dialog"]],decls:8,vars:4,consts:[[1,"dialogWrapper",3,"ngClass"],[1,"title"],["mat-button","",3,"click"],["mat-button","",1,"confirmButton",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ds(2),va(),ga(3,"div"),ga(4,"button",2),xa("click",(function(){return e.onNoClick()})),ds(5,"No"),va(),ga(6,"button",3),xa("click",(function(){return e.onYesClick()})),ds(7,"Yes"),va(),va(),va()),2&t&&(pa("ngClass",Ic(2,Grt,e.isLightThemeEnabled)),Qi(2),ps(" Do you want to navigate to ",e.projectMessage,"?"))},directives:[Oh,a2],styles:[".dialogWrapper[_ngcontent-%COMP%]{background-color:#263238;padding:10px 20px;margin-bottom:-8px;display:flex;justify-content:space-between;align-items:center}.lightTheme[_ngcontent-%COMP%]{background-color:#fff!important}.title[_ngcontent-%COMP%]{margin-right:10px;margin-left:10px}"]}),t}(),Krt=function(t){return{lightTheme:t}},Xrt=function(){function t(t,e){this.bottomSheetRef=t,this.themeService=e,this.message="",this.isLightThemeEnabled=!1}return t.prototype.ngOnInit=function(){this.isLightThemeEnabled="light"===this.themeService.getActualTheme()},t.prototype.onNoClick=function(){this.bottomSheetRef.dismiss(!1)},t.prototype.onYesClick=function(){this.bottomSheetRef.dismiss(!0)},t.\u0275fac=function(e){return new(e||t)(da(Vrt),da(Kit))},t.\u0275cmp=Ht({type:t,selectors:[["app-confirmation-bottomsheet"]],decls:8,vars:4,consts:[[1,"dialogWrapper",3,"ngClass"],[1,"title"],["mat-button","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ds(2),va(),ga(3,"div"),ga(4,"button",2),xa("click",(function(){return e.onNoClick()})),ds(5,"No"),va(),ga(6,"button",2),xa("click",(function(){return e.onYesClick()})),ds(7,"Yes"),va(),va(),va()),2&t&&(pa("ngClass",Ic(2,Krt,e.isLightThemeEnabled)),Qi(2),fs(e.message))},directives:[Oh,a2],styles:[".dialogWrapper[_ngcontent-%COMP%]{background-color:#263238;padding:10px 20px;margin-bottom:-8px;display:flex;justify-content:space-between;align-items:center}.lightTheme[_ngcontent-%COMP%]{background-color:#fff!important}.title[_ngcontent-%COMP%]{margin-right:10px;margin-left:10px}"]}),t}(),Yrt=function(){function t(t){this.httpServer=t}return t.prototype.notificationsPath=function(t){return"ws://"+t.host+":"+t.port+"/v2/notifications/ws"},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function Zrt(t,e){if(1&t&&(ga(0,"mat-option",19),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Qrt(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",16),ga(1,"mat-select",17),xa("selectionChange",(function(t){return Se(n),Aa(2)._changePageSize(t.value)})),ua(2,Zrt,2,2,"mat-option",18),va(),va()}if(2&t){var i=Aa(2);pa("color",i.color),Qi(1),pa("value",i.pageSize)("disabled",i.disabled)("aria-label",i._intl.itemsPerPageLabel),Qi(1),pa("ngForOf",i._displayedPageSizeOptions)}}function $rt(t,e){if(1&t&&(ga(0,"div",20),ds(1),va()),2&t){var n=Aa(2);Qi(1),fs(n.pageSize)}}function Jrt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ds(2),va(),ua(3,Qrt,3,5,"mat-form-field",14),ua(4,$rt,2,1,"div",15),va()),2&t){var n=Aa();Qi(2),ps(" ",n._intl.itemsPerPageLabel," "),Qi(1),pa("ngIf",n._displayedPageSizeOptions.length>1),Qi(1),pa("ngIf",n._displayedPageSizeOptions.length<=1)}}function tot(t,e){if(1&t){var n=ka();ga(0,"button",21),xa("click",(function(){return Se(n),Aa().firstPage()})),Qe(),ga(1,"svg",7),ba(2,"path",22),va(),va()}if(2&t){var i=Aa();pa("matTooltip",i._intl.firstPageLabel)("matTooltipDisabled",i._previousButtonsDisabled())("matTooltipPosition","above")("disabled",i._previousButtonsDisabled()),oa("aria-label",i._intl.firstPageLabel)}}function eot(t,e){if(1&t){var n=ka();Qe(),$e(),ga(0,"button",23),xa("click",(function(){return Se(n),Aa().lastPage()})),Qe(),ga(1,"svg",7),ba(2,"path",24),va(),va()}if(2&t){var i=Aa();pa("matTooltip",i._intl.lastPageLabel)("matTooltipDisabled",i._nextButtonsDisabled())("matTooltipPosition","above")("disabled",i._nextButtonsDisabled()),oa("aria-label",i._intl.lastPageLabel)}}var not=function(){var t=function t(){Object(m.a)(this,t),this.changes=new w.b,this.itemsPerPageLabel="Items per page:",this.nextPageLabel="Next page",this.previousPageLabel="Previous page",this.firstPageLabel="First page",this.lastPageLabel="Last page",this.getRangeLabel=function(t,e,n){if(0==n||0==e)return"0 of ".concat(n);var i=t*e,r=i<(n=Math.max(n,0))?Math.min(i+e,n):i+e;return"".concat(i+1," \u2013 ").concat(r," of ").concat(n)}};return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:function(){return new t},token:t,providedIn:"root"}),t}(),iot={provide:not,deps:[[new E,new A,not]],useFactory:function(t){return t||new not}},rot=new ht("MAT_PAGINATOR_DEFAULT_OPTIONS"),oot=J$(rJ((function t(){Object(m.a)(this,t)}))),aot=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;if(Object(m.a)(this,n),(o=e.call(this))._intl=t,o._changeDetectorRef=i,o._pageIndex=0,o._length=0,o._pageSizeOptions=[],o._hidePageSize=!1,o._showFirstLastButtons=!1,o.page=new Uc,o._intlChanges=t.changes.subscribe((function(){return o._changeDetectorRef.markForCheck()})),r){var a=r.pageSize,s=r.pageSizeOptions,c=r.hidePageSize,l=r.showFirstLastButtons;null!=a&&(o._pageSize=a),null!=s&&(o._pageSizeOptions=s),null!=c&&(o._hidePageSize=c),null!=l&&(o._showFirstLastButtons=l)}return o}return Object(g.a)(n,[{key:"ngOnInit",value:function(){this._initialized=!0,this._updateDisplayedPageSizeOptions(),this._markInitialized()}},{key:"ngOnDestroy",value:function(){this._intlChanges.unsubscribe()}},{key:"nextPage",value:function(){if(this.hasNextPage()){var t=this.pageIndex;this.pageIndex++,this._emitPageEvent(t)}}},{key:"previousPage",value:function(){if(this.hasPreviousPage()){var t=this.pageIndex;this.pageIndex--,this._emitPageEvent(t)}}},{key:"firstPage",value:function(){if(this.hasPreviousPage()){var t=this.pageIndex;this.pageIndex=0,this._emitPageEvent(t)}}},{key:"lastPage",value:function(){if(this.hasNextPage()){var t=this.pageIndex;this.pageIndex=this.getNumberOfPages()-1,this._emitPageEvent(t)}}},{key:"hasPreviousPage",value:function(){return this.pageIndex>=1&&0!=this.pageSize}},{key:"hasNextPage",value:function(){var t=this.getNumberOfPages()-1;return this.pageIndex<t&&0!=this.pageSize}},{key:"getNumberOfPages",value:function(){return this.pageSize?Math.ceil(this.length/this.pageSize):0}},{key:"_changePageSize",value:function(t){var e=this.pageIndex;this.pageIndex=Math.floor(this.pageIndex*this.pageSize/t)||0,this.pageSize=t,this._emitPageEvent(e)}},{key:"_nextButtonsDisabled",value:function(){return this.disabled||!this.hasNextPage()}},{key:"_previousButtonsDisabled",value:function(){return this.disabled||!this.hasPreviousPage()}},{key:"_updateDisplayedPageSizeOptions",value:function(){this._initialized&&(this.pageSize||(this._pageSize=0!=this.pageSizeOptions.length?this.pageSizeOptions[0]:50),this._displayedPageSizeOptions=this.pageSizeOptions.slice(),-1===this._displayedPageSizeOptions.indexOf(this.pageSize)&&this._displayedPageSizeOptions.push(this.pageSize),this._displayedPageSizeOptions.sort((function(t,e){return t-e})),this._changeDetectorRef.markForCheck())}},{key:"_emitPageEvent",value:function(t){this.page.emit({previousPageIndex:t,pageIndex:this.pageIndex,pageSize:this.pageSize,length:this.length})}},{key:"pageIndex",get:function(){return this._pageIndex},set:function(t){this._pageIndex=Math.max(im(t),0),this._changeDetectorRef.markForCheck()}},{key:"length",get:function(){return this._length},set:function(t){this._length=im(t),this._changeDetectorRef.markForCheck()}},{key:"pageSize",get:function(){return this._pageSize},set:function(t){this._pageSize=Math.max(im(t),0),this._updateDisplayedPageSizeOptions()}},{key:"pageSizeOptions",get:function(){return this._pageSizeOptions},set:function(t){this._pageSizeOptions=(t||[]).map((function(t){return im(t)})),this._updateDisplayedPageSizeOptions()}},{key:"hidePageSize",get:function(){return this._hidePageSize},set:function(t){this._hidePageSize=nm(t)}},{key:"showFirstLastButtons",get:function(){return this._showFirstLastButtons},set:function(t){this._showFirstLastButtons=nm(t)}}]),n}(oot);return t.\u0275fac=function(e){return new(e||t)(da(not),da(Po),da(rot,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-paginator"]],hostAttrs:[1,"mat-paginator"],inputs:{disabled:"disabled",pageIndex:"pageIndex",length:"length",pageSize:"pageSize",pageSizeOptions:"pageSizeOptions",hidePageSize:"hidePageSize",showFirstLastButtons:"showFirstLastButtons",color:"color"},outputs:{page:"page"},exportAs:["matPaginator"],features:[ws],decls:14,vars:14,consts:[[1,"mat-paginator-outer-container"],[1,"mat-paginator-container"],["class","mat-paginator-page-size",4,"ngIf"],[1,"mat-paginator-range-actions"],[1,"mat-paginator-range-label"],["mat-icon-button","","type","button","class","mat-paginator-navigation-first",3,"matTooltip","matTooltipDisabled","matTooltipPosition","disabled","click",4,"ngIf"],["mat-icon-button","","type","button",1,"mat-paginator-navigation-previous",3,"matTooltip","matTooltipDisabled","matTooltipPosition","disabled","click"],["viewBox","0 0 24 24","focusable","false",1,"mat-paginator-icon"],["d","M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"],["mat-icon-button","","type","button",1,"mat-paginator-navigation-next",3,"matTooltip","matTooltipDisabled","matTooltipPosition","disabled","click"],["d","M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"],["mat-icon-button","","type","button","class","mat-paginator-navigation-last",3,"matTooltip","matTooltipDisabled","matTooltipPosition","disabled","click",4,"ngIf"],[1,"mat-paginator-page-size"],[1,"mat-paginator-page-size-label"],["class","mat-paginator-page-size-select",3,"color",4,"ngIf"],["class","mat-paginator-page-size-value",4,"ngIf"],[1,"mat-paginator-page-size-select",3,"color"],[3,"value","disabled","aria-label","selectionChange"],[3,"value",4,"ngFor","ngForOf"],[3,"value"],[1,"mat-paginator-page-size-value"],["mat-icon-button","","type","button",1,"mat-paginator-navigation-first",3,"matTooltip","matTooltipDisabled","matTooltipPosition","disabled","click"],["d","M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6 6 6zM6 6h2v12H6z"],["mat-icon-button","","type","button",1,"mat-paginator-navigation-last",3,"matTooltip","matTooltipDisabled","matTooltipPosition","disabled","click"],["d","M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6-6-6zM16 6h2v12h-2z"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ua(2,Jrt,5,3,"div",2),ga(3,"div",3),ga(4,"div",4),ds(5),va(),ua(6,tot,3,5,"button",5),ga(7,"button",6),xa("click",(function(){return e.previousPage()})),Qe(),ga(8,"svg",7),ba(9,"path",8),va(),va(),$e(),ga(10,"button",9),xa("click",(function(){return e.nextPage()})),Qe(),ga(11,"svg",7),ba(12,"path",10),va(),va(),ua(13,eot,3,5,"button",11),va(),va(),va()),2&t&&(Qi(2),pa("ngIf",!e.hidePageSize),Qi(3),ps(" ",e._intl.getRangeLabel(e.pageIndex,e.pageSize,e.length)," "),Qi(1),pa("ngIf",e.showFirstLastButtons),Qi(1),pa("matTooltip",e._intl.previousPageLabel)("matTooltipDisabled",e._previousButtonsDisabled())("matTooltipPosition","above")("disabled",e._previousButtonsDisabled()),oa("aria-label",e._intl.previousPageLabel),Qi(3),pa("matTooltip",e._intl.nextPageLabel)("matTooltipDisabled",e._nextButtonsDisabled())("matTooltipPosition","above")("disabled",e._nextButtonsDisabled()),oa("aria-label",e._intl.nextPageLabel),Qi(3),pa("ngIf",e.showFirstLastButtons))},directives:[Ah,a2,k4,Y3,O5,Eh,EJ],styles:[".mat-paginator{display:block}.mat-paginator-outer-container{display:flex}.mat-paginator-container{display:flex;align-items:center;justify-content:flex-end;padding:0 8px;flex-wrap:wrap-reverse;width:100%}.mat-paginator-page-size{display:flex;align-items:baseline;margin-right:8px}[dir=rtl] .mat-paginator-page-size{margin-right:0;margin-left:8px}.mat-paginator-page-size-label{margin:0 4px}.mat-paginator-page-size-select{margin:6px 4px 0 4px;width:56px}.mat-paginator-page-size-select.mat-form-field-appearance-outline{width:64px}.mat-paginator-page-size-select.mat-form-field-appearance-fill{width:64px}.mat-paginator-range-label{margin:0 32px 0 24px}.mat-paginator-range-actions{display:flex;align-items:center}.mat-paginator-icon{width:28px;fill:currentColor}[dir=rtl] .mat-paginator-icon{transform:rotate(180deg)}\n"],encapsulation:2,changeDetection:0}),t}(),sot=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[iot],imports:[[hd,c2,M5,S4]]}),t}(),cot=function(){function t(t){this.httpServer=t}return t.prototype.getAppliances=function(t){return this.httpServer.get(t,"/appliances")},t.prototype.getAppliance=function(t,e){return this.httpServer.get(t,e)},t.prototype.getUploadPath=function(t,e,n){return"http://"+t.host+":"+t.port+"/v2/compute/"+e+"/images/"+n},t.prototype.updateAppliances=function(t){return this.httpServer.get(t,"/appliances?update=yes")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function lot(t,e){if(1&t&&(ga(0,"div"),ds(1),va()),2&t){var n=Aa();Qi(1),ps(" Adapters: ",n.appliance.qemu.adapters," ")}}function uot(t,e){if(1&t&&(ga(0,"div"),ds(1),va()),2&t){var n=Aa();Qi(1),ps(" Console type: ",n.appliance.qemu.console_type," ")}}var hot=function(){function t(t,e){this.dialogRef=t,this.data=e}return t.prototype.onNoClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(Q0))},t.\u0275cmp=Ht({type:t,selectors:[["appliance-info-dialog"]],decls:15,vars:6,consts:[[1,"title-container"],["mat-dialog-title",""],["mat-dialog-content",""],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","tabindex","-1","color","accent",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"h1",1),ds(2),va(),va(),ga(3,"div",2),ga(4,"div"),ds(5),va(),ga(6,"div"),ds(7),va(),ga(8,"div"),ds(9),va(),ua(10,lot,2,1,"div",3),ua(11,uot,2,1,"div",3),va(),ga(12,"div",4),ga(13,"button",5),xa("click",(function(){return e.onNoClick()})),ds(14,"Close"),va(),va()),2&t&&(Qi(2),fs(e.appliance.name),Qi(3),ps(" Vendor: ",e.appliance.vendor_name," "),Qi(2),ps(" Status: ",e.appliance.status," "),Qi(2),ps(" Maintainer: ",e.appliance.maintainer," "),Qi(1),pa("ngIf",e.appliance.qemu),Qi(1),pa("ngIf",e.appliance.qemu))},directives:[r1,o1,Ah,a1,a2],encapsulation:2}),t}(),dot=function(){return function(){}}(),fot=function(){return function(){}}(),pot=function(){function t(t){this.httpServer=t}return t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.getImages=function(t){return this.httpServer.get(t,"/compute/docker/images")},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),mot=function(){return function(){}}(),got=function(){function t(t){this.httpServer=t}return t.prototype.getImages=function(t){return this.httpServer.get(t,"/compute/dynamips/images")},t.prototype.getImagePath=function(t,e){return"http://"+t.host+":"+t.port+"/v2/compute/dynamips/images/"+e},t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),vot=function(){function t(t){this.httpServer=t}return t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.getImages=function(t){return this.httpServer.get(t,"/compute/iou/images")},t.prototype.getImagePath=function(t,e){return"http://"+t.host+":"+t.port+"/v2/compute/iou/images/"+e},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),bot=function(){return function(){}}(),yot=function(){function t(t){this.httpServer=t,this.newTemplateCreated=new w.b}return t.prototype.list=function(t){return this.httpServer.get(t,"/templates")},t.prototype.deleteTemplate=function(t,e){return this.httpServer.delete(t,"/templates/"+e,{observe:"body"})},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),_ot=function(){function t(t){this.httpServer=t}return t.prototype.getComputes=function(t){return this.httpServer.get(t,"/computes")},t.prototype.getUploadPath=function(t,e,n){return"http://"+t.host+":"+t.port+"/v2/"+e+"/images/"+n},t.prototype.getStatistics=function(t){return this.httpServer.get(t,"/statistics")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),wot=function(){function t(t){this.dialogRef=t}return t.prototype.ngOnInit=function(){},t.prototype.onNoClick=function(){this.dialogRef.close(!1)},t.prototype.onYesClick=function(){this.dialogRef.close(!0)},t.\u0275fac=function(e){return new(e||t)(da(Z0))},t.\u0275cmp=Ht({type:t,selectors:[["app-information-dialog"]],decls:7,vars:1,consts:[["mat-dialog-actions",""],["mat-button","","color","accent",1,"cancelButton",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",1,"confirmButton",3,"click"]],template:function(t,e){1&t&&(ga(0,"span"),ds(1),va(),ga(2,"div",0),ga(3,"button",1),xa("click",(function(){return e.onNoClick()})),ds(4,"No"),va(),ga(5,"button",2),xa("click",(function(){return e.onYesClick()})),ds(6," Yes "),va(),va()),2&t&&(Qi(1),fs(e.confirmationMessage))},directives:[a1,a2],styles:[""]}),t}();function kot(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Template name is required"),va())}function Cot(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Template name is incorrect"),va())}function Sot(t,e){1&t&&(ga(0,"mat-error"),ds(1,"Template with this name exists"),va())}var xot=function(t){return{"is-invalid":t}},Oot=function(){function t(t,e,n,i,r,o,a,s){this.dialogRef=t,this.router=e,this.dialog=n,this.toasterService=i,this.formBuilder=r,this.templateNameValidator=o,this.templateService=a,this.data=s}return t.prototype.ngOnInit=function(){var t,e,n=this;this.templateNameForm=this.formBuilder.group({templateName:new hp(this.data.name,[kf.required,this.templateNameValidator.get],[(t=this.server,e=this.templateService,function(n){return Object(l1.a)(500).pipe(Object(LX.a)((function(){return e.list(t)})),Object(ef.a)((function(t){return t.find((function(t){return t.name===n.value}))?{templateExist:!0}:null})))})])}),setTimeout((function(){n.templateNameForm.controls.templateName.markAsTouched()}),100)},Object.defineProperty(t.prototype,"form",{get:function(){return this.templateNameForm.controls},enumerable:!1,configurable:!0}),t.prototype.onAddClick=function(){var t=this;this.templateNameForm.invalid?this.toasterService.error("Please enter correct name for new template"):this.templateService.list(this.server).subscribe((function(e){var n=t.templateNameForm.controls.templateName.value;e.find((function(t){return t.name===n}))?t.toasterService.error("Template with this name exists"):t.dialogRef.close(t.templateNameForm.controls.templateName.value)}))},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.onKeyDown=function(t){"Enter"===t.key&&this.onAddClick()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(lQ),da(e1),da(Y2),da(Jp),da(urt),da(yot),da(Q0))},t.\u0275cmp=Ht({type:t,selectors:[["app-template-name-dialog"]],features:[Ns([urt])],decls:13,vars:7,consts:[["mat-dialog-title",""],[1,"file-name-form",3,"formGroup"],[1,"file-name-form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Template name",3,"ngClass","keydown"],[4,"ngIf"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",1,"add-project-button",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Please enter name for the new template"),va(),ga(2,"form",1),ga(3,"mat-form-field",2),ga(4,"input",3),xa("keydown",(function(t){return e.onKeyDown(t)})),va(),ua(5,kot,2,0,"mat-error",4),ua(6,Cot,2,0,"mat-error",4),ua(7,Sot,2,0,"mat-error",4),va(),ga(8,"div",5),ga(9,"button",6),xa("click",(function(){return e.onNoClick()})),ds(10,"Cancel"),va(),ga(11,"button",7),xa("click",(function(){return e.onAddClick()})),ds(12,"Add template"),va(),va(),va()),2&t&&(Qi(2),pa("formGroup",e.templateNameForm),Qi(2),pa("ngClass",Ic(5,xot,null==e.form.templateName?null:e.form.templateName.errors)),Qi(1),pa("ngIf",(null==e.form.templateName?null:e.form.templateName.touched)&&(null==e.form.templateName?null:e.form.templateName.errors)&&(null==e.form.templateName?null:e.form.templateName.errors.required)),Qi(1),pa("ngIf",(null==e.form.templateName?null:e.form.templateName.errors)&&(null==e.form.templateName?null:e.form.templateName.errors.invalidName)),Qi(1),pa("ngIf",(null==e.form.templateName?null:e.form.templateName.errors)&&(null==e.form.templateName?null:e.form.templateName.errors.templateExist)))},directives:[r1,xp,gf,Pp,Y3,s5,cf,mf,Fp,Oh,Ah,a1,a2,R3],styles:[".file-name-form-field[_ngcontent-%COMP%]{width:100%}.project-snackbar[_ngcontent-%COMP%]{background:#2196f3}"]}),t}();function Mot(t,e){1&t&&Da(0)}var Tot=["*"],Eot=function(){var t=function(){function t(e){Object(m.a)(this,t),this._elementRef=e}return Object(g.a)(t,[{key:"focus",value:function(){this._elementRef.nativeElement.focus()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","cdkStepHeader",""]],hostAttrs:["role","tab"]}),t}(),Pot=function(){var t=function t(e){Object(m.a)(this,t),this.template=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["","cdkStepLabel",""]]}),t}(),Aot=0,jot=new ht("STEPPER_GLOBAL_OPTIONS"),Iot=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._stepper=e,this.interacted=!1,this._editable=!0,this._optional=!1,this._completedOverride=null,this._customError=null,this._stepperOptions=n||{},this._displayDefaultIndicatorType=!1!==this._stepperOptions.displayDefaultIndicatorType,this._showError=!!this._stepperOptions.showError}return Object(g.a)(t,[{key:"_getDefaultCompleted",value:function(){return this.stepControl?this.stepControl.valid&&this.interacted:this.interacted}},{key:"_getDefaultError",value:function(){return this.stepControl&&this.stepControl.invalid&&this.interacted}},{key:"select",value:function(){this._stepper.selected=this}},{key:"reset",value:function(){this.interacted=!1,null!=this._completedOverride&&(this._completedOverride=!1),null!=this._customError&&(this._customError=!1),this.stepControl&&this.stepControl.reset()}},{key:"ngOnChanges",value:function(){this._stepper._stateChanged()}},{key:"editable",get:function(){return this._editable},set:function(t){this._editable=nm(t)}},{key:"optional",get:function(){return this._optional},set:function(t){this._optional=nm(t)}},{key:"completed",get:function(){return null==this._completedOverride?this._getDefaultCompleted():this._completedOverride},set:function(t){this._completedOverride=nm(t)}},{key:"hasError",get:function(){return null==this._customError?this._getDefaultError():this._customError},set:function(t){this._customError=nm(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Y((function(){return Dot}))),da(jot,8))},t.\u0275cmp=Ht({type:t,selectors:[["cdk-step"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,Pot,!0),2&t&&tl(i=sl())&&(e.stepLabel=i.first)},viewQuery:function(t,e){var n;1&t&&el(fc,!0),2&t&&tl(n=sl())&&(e.content=n.first)},inputs:{editable:"editable",optional:"optional",completed:"completed",hasError:"hasError",stepControl:"stepControl",label:"label",errorMessage:"errorMessage",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],state:"state"},exportAs:["cdkStep"],features:[Ms],ngContentSelectors:Tot,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),ua(0,Mot,1,0,"ng-template"))},encapsulation:2,changeDetection:0}),t}(),Dot=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._dir=e,this._changeDetectorRef=n,this._elementRef=i,this._destroyed=new w.b,this._linear=!1,this._selectedIndex=0,this.selectionChange=new Uc,this._orientation="horizontal",this._groupId=Aot++,this._document=r}return Object(g.a)(t,[{key:"ngAfterViewInit",value:function(){var t=this;this._keyManager=new d$(this._stepHeader).withWrap().withVerticalOrientation("vertical"===this._orientation),(this._dir?this._dir.change:Object(lm.a)()).pipe(Object(NX.a)(this._layoutDirection()),Object(Am.a)(this._destroyed)).subscribe((function(e){return t._keyManager.withHorizontalOrientation(e)})),this._keyManager.updateActiveItem(this._selectedIndex),this.steps.changes.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){t.selected||(t._selectedIndex=Math.max(t._selectedIndex-1,0))}))}},{key:"ngOnDestroy",value:function(){this._destroyed.next(),this._destroyed.complete()}},{key:"next",value:function(){this.selectedIndex=Math.min(this._selectedIndex+1,this.steps.length-1)}},{key:"previous",value:function(){this.selectedIndex=Math.max(this._selectedIndex-1,0)}},{key:"reset",value:function(){this._updateSelectedItemIndex(0),this.steps.forEach((function(t){return t.reset()})),this._stateChanged()}},{key:"_getStepLabelId",value:function(t){return"cdk-step-label-".concat(this._groupId,"-").concat(t)}},{key:"_getStepContentId",value:function(t){return"cdk-step-content-".concat(this._groupId,"-").concat(t)}},{key:"_stateChanged",value:function(){this._changeDetectorRef.markForCheck()}},{key:"_getAnimationDirection",value:function(t){var e=t-this._selectedIndex;return e<0?"rtl"===this._layoutDirection()?"next":"previous":e>0?"rtl"===this._layoutDirection()?"previous":"next":"current"}},{key:"_getIndicatorType",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"number",n=this.steps.toArray()[t],i=this._isCurrentStep(t);return n._displayDefaultIndicatorType?this._getDefaultIndicatorLogic(n,i):this._getGuidelineLogic(n,i,e)}},{key:"_getDefaultIndicatorLogic",value:function(t,e){return t._showError&&t.hasError&&!e?"error":!t.completed||e?"number":t.editable?"edit":"done"}},{key:"_getGuidelineLogic",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"number";return t._showError&&t.hasError&&!e?"error":t.completed&&!e?"done":t.completed&&e?n:t.editable&&e?"edit":n}},{key:"_isCurrentStep",value:function(t){return this._selectedIndex===t}},{key:"_getFocusIndex",value:function(){return this._keyManager?this._keyManager.activeItemIndex:this._selectedIndex}},{key:"_updateSelectedItemIndex",value:function(t){var e=this.steps.toArray();this.selectionChange.emit({selectedIndex:t,previouslySelectedIndex:this._selectedIndex,selectedStep:e[t],previouslySelectedStep:e[this._selectedIndex]}),this._containsFocus()?this._keyManager.setActiveItem(t):this._keyManager.updateActiveItem(t),this._selectedIndex=t,this._stateChanged()}},{key:"_onKeydown",value:function(t){var e=JQ(t),n=t.keyCode,i=this._keyManager;null==i.activeItemIndex||e||32!==n&&13!==n?36===n?(i.setFirstItemActive(),t.preventDefault()):35===n?(i.setLastItemActive(),t.preventDefault()):i.onKeydown(t):(this.selectedIndex=i.activeItemIndex,t.preventDefault())}},{key:"_anyControlsInvalidOrPending",value:function(t){var e=this.steps.toArray();return e[this._selectedIndex].interacted=!0,!!(this._linear&&t>=0)&&e.slice(0,t).some((function(t){var e=t.stepControl;return(e?e.invalid||e.pending||!t.interacted:!t.completed)&&!t.optional&&!t._completedOverride}))}},{key:"_layoutDirection",value:function(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}},{key:"_containsFocus",value:function(){if(!this._document||!this._elementRef)return!1;var t=this._elementRef.nativeElement,e=this._document.activeElement;return t===e||t.contains(e)}},{key:"steps",get:function(){return this._steps}},{key:"linear",get:function(){return this._linear},set:function(t){this._linear=nm(t)}},{key:"selectedIndex",get:function(){return this._selectedIndex},set:function(t){var e=im(t);if(this.steps){if(e<0||e>this.steps.length-1)throw Error("cdkStepper: Cannot assign out-of-bounds value to `selectedIndex`.");this._selectedIndex!=e&&!this._anyControlsInvalidOrPending(e)&&(e>=this._selectedIndex||this.steps.toArray()[e].editable)&&this._updateSelectedItemIndex(t)}else this._selectedIndex=e}},{key:"selected",get:function(){return this.steps?this.steps.toArray()[this.selectedIndex]:void 0},set:function(t){this.selectedIndex=this.steps?this.steps.toArray().indexOf(t):-1}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(gm,8),da(Po),da(Us),da(du))},t.\u0275dir=Wt({type:t,selectors:[["","cdkStepper",""]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,Iot,!0),rl(n,Eot,!0)),2&t&&(tl(i=sl())&&(e._steps=i),tl(i=sl())&&(e._stepHeader=i))},inputs:{linear:"linear",selectedIndex:"selectedIndex",selected:"selected"},outputs:{selectionChange:"selectionChange"},exportAs:["cdkStepper"]}),t}(),Rot=function(){var t=function(){function t(e){Object(m.a)(this,t),this._stepper=e,this.type="submit"}return Object(g.a)(t,[{key:"_handleClick",value:function(){this._stepper.next()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Dot))},t.\u0275dir=Wt({type:t,selectors:[["button","cdkStepperNext",""]],hostVars:1,hostBindings:function(t,e){1&t&&xa("click",(function(){return e._handleClick()})),2&t&&bs("type",e.type)},inputs:{type:"type"}}),t}(),Lot=function(){var t=function(){function t(e){Object(m.a)(this,t),this._stepper=e,this.type="button"}return Object(g.a)(t,[{key:"_handleClick",value:function(){this._stepper.previous()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Dot))},t.\u0275dir=Wt({type:t,selectors:[["button","cdkStepperPrevious",""]],hostVars:1,hostBindings:function(t,e){1&t&&xa("click",(function(){return e._handleClick()})),2&t&&bs("type",e.type)},inputs:{type:"type"}}),t}(),Fot=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[bm]]}),t}();function Not(t,e){if(1&t&&wa(0,9),2&t){var n=Aa();pa("ngTemplateOutlet",n.iconOverrides[n.state])("ngTemplateOutletContext",n._getIconContext())}}function Bot(t,e){if(1&t&&(ga(0,"span"),ds(1),va()),2&t){var n=Aa(2);Qi(1),fs(n._getDefaultTextForState(n.state))}}function Hot(t,e){if(1&t&&(ga(0,"mat-icon"),ds(1),va()),2&t){var n=Aa(2);Qi(1),fs(n._getDefaultTextForState(n.state))}}function zot(t,e){1&t&&(ya(0,10),ua(1,Bot,2,1,"span",11),ua(2,Hot,2,1,"mat-icon",12),_a()),2&t&&(pa("ngSwitch",Aa().state),Qi(1),pa("ngSwitchCase","number"))}function Vot(t,e){1&t&&wa(0,13),2&t&&pa("ngTemplateOutlet",Aa()._templateLabel().template)}function Uot(t,e){if(1&t&&(ga(0,"div",14),ds(1),va()),2&t){var n=Aa();Qi(1),fs(n.label)}}function qot(t,e){if(1&t&&(ga(0,"div",15),ds(1),va()),2&t){var n=Aa();Qi(1),fs(n._intl.optionalLabel)}}function Got(t,e){if(1&t&&(ga(0,"div",16),ds(1),va()),2&t){var n=Aa();Qi(1),fs(n.errorMessage)}}function Wot(t,e){1&t&&Da(0)}var Kot=["*"];function Xot(t,e){1&t&&ba(0,"div",6)}function Yot(t,e){if(1&t){var n=ka();ya(0),ga(1,"mat-step-header",4),xa("click",(function(){return e.$implicit.select()}))("keydown",(function(t){return Se(n),Aa()._onKeydown(t)})),va(),ua(2,Xot,1,0,"div",5),_a()}if(2&t){var i=e.$implicit,r=e.index,o=e.last,a=Aa();Qi(1),pa("tabIndex",a._getFocusIndex()===r?0:-1)("id",a._getStepLabelId(r))("index",r)("state",a._getIndicatorType(r,i.state))("label",i.stepLabel||i.label)("selected",a.selectedIndex===r)("active",i.completed||a.selectedIndex===r||!a.linear)("optional",i.optional)("errorMessage",i.errorMessage)("iconOverrides",a._iconOverrides)("disableRipple",a.disableRipple),oa("aria-posinset",r+1)("aria-setsize",a.steps.length)("aria-controls",a._getStepContentId(r))("aria-selected",a.selectedIndex==r)("aria-label",i.ariaLabel||null)("aria-labelledby",!i.ariaLabel&&i.ariaLabelledby?i.ariaLabelledby:null),Qi(1),pa("ngIf",!o)}}function Zot(t,e){if(1&t){var n=ka();ga(0,"div",7),xa("@stepTransition.done",(function(t){return Se(n),Aa()._animationDone.next(t)})),wa(1,8),va()}if(2&t){var i=e.$implicit,r=e.index,o=Aa();pa("@stepTransition",o._getAnimationDirection(r))("id",o._getStepContentId(r)),oa("tabindex",o.selectedIndex===r?0:null)("aria-labelledby",o._getStepLabelId(r))("aria-expanded",o.selectedIndex===r),Qi(1),pa("ngTemplateOutlet",i.content)}}function Qot(t,e){if(1&t){var n=ka();ga(0,"div",1),ga(1,"mat-step-header",2),xa("click",(function(){return e.$implicit.select()}))("keydown",(function(t){return Se(n),Aa()._onKeydown(t)})),va(),ga(2,"div",3),ga(3,"div",4),xa("@stepTransition.done",(function(t){return Se(n),Aa()._animationDone.next(t)})),ga(4,"div",5),wa(5,6),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=e.index,o=e.last,a=Aa();Qi(1),pa("tabIndex",a._getFocusIndex()==r?0:-1)("id",a._getStepLabelId(r))("index",r)("state",a._getIndicatorType(r,i.state))("label",i.stepLabel||i.label)("selected",a.selectedIndex===r)("active",i.completed||a.selectedIndex===r||!a.linear)("optional",i.optional)("errorMessage",i.errorMessage)("iconOverrides",a._iconOverrides)("disableRipple",a.disableRipple),oa("aria-posinset",r+1)("aria-setsize",a.steps.length)("aria-controls",a._getStepContentId(r))("aria-selected",a.selectedIndex===r)("aria-label",i.ariaLabel||null)("aria-labelledby",!i.ariaLabel&&i.ariaLabelledby?i.ariaLabelledby:null),Qi(1),Qa("mat-stepper-vertical-line",!o),Qi(1),pa("@stepTransition",a._getAnimationDirection(r))("id",a._getStepContentId(r)),oa("tabindex",a.selectedIndex===r?0:null)("aria-labelledby",a._getStepLabelId(r))("aria-expanded",a.selectedIndex===r),Qi(2),pa("ngTemplateOutlet",i.content)}}var $ot=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Pot);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matStepLabel",""]],features:[ws]});var e=zn(t);return t}(),Jot=function(){var t=function t(){Object(m.a)(this,t),this.changes=new w.b,this.optionalLabel="Optional"};return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:function(){return new t},token:t,providedIn:"root"}),t}(),tat={provide:Jot,deps:[[new E,new A,Jot]],useFactory:function(t){return t||new Jot}},eat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,r))._intl=t,a._focusMonitor=i,a._intlSubscription=t.changes.subscribe((function(){return o.markForCheck()})),a}return Object(g.a)(n,[{key:"ngAfterViewInit",value:function(){this._focusMonitor.monitor(this._elementRef,!0)}},{key:"ngOnDestroy",value:function(){this._intlSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._elementRef)}},{key:"focus",value:function(){this._focusMonitor.focusVia(this._elementRef,"program")}},{key:"_stringLabel",value:function(){return this.label instanceof $ot?null:this.label}},{key:"_templateLabel",value:function(){return this.label instanceof $ot?this.label:null}},{key:"_getHostElement",value:function(){return this._elementRef.nativeElement}},{key:"_getIconContext",value:function(){return{index:this.index,active:this.active,optional:this.optional}}},{key:"_getDefaultTextForState",value:function(t){return"number"==t?"".concat(this.index+1):"edit"==t?"create":"error"==t?"warning":t}}]),n}(Eot);return t.\u0275fac=function(e){return new(e||t)(da(Jot),da(S$),da(Us),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["mat-step-header"]],hostAttrs:["role","tab",1,"mat-step-header","mat-focus-indicator"],inputs:{state:"state",label:"label",errorMessage:"errorMessage",iconOverrides:"iconOverrides",index:"index",selected:"selected",active:"active",optional:"optional",disableRipple:"disableRipple"},features:[ws],decls:10,vars:19,consts:[["matRipple","",1,"mat-step-header-ripple",3,"matRippleTrigger","matRippleDisabled"],[1,"mat-step-icon-content",3,"ngSwitch"],[3,"ngTemplateOutlet","ngTemplateOutletContext",4,"ngSwitchCase"],[3,"ngSwitch",4,"ngSwitchDefault"],[1,"mat-step-label"],[3,"ngTemplateOutlet",4,"ngIf"],["class","mat-step-text-label",4,"ngIf"],["class","mat-step-optional",4,"ngIf"],["class","mat-step-sub-label-error",4,"ngIf"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],[3,"ngSwitch"],[4,"ngSwitchCase"],[4,"ngSwitchDefault"],[3,"ngTemplateOutlet"],[1,"mat-step-text-label"],[1,"mat-step-optional"],[1,"mat-step-sub-label-error"]],template:function(t,e){1&t&&(ba(0,"div",0),ga(1,"div"),ga(2,"div",1),ua(3,Not,1,2,"ng-container",2),ua(4,zot,3,2,"ng-container",3),va(),va(),ga(5,"div",4),ua(6,Vot,1,1,"ng-container",5),ua(7,Uot,2,1,"div",6),ua(8,qot,2,1,"div",7),ua(9,Got,2,1,"div",8),va()),2&t&&(pa("matRippleTrigger",e._getHostElement())("matRippleDisabled",e.disableRipple),Qi(1),vs("mat-step-icon-state-",e.state," mat-step-icon"),Qa("mat-step-icon-selected",e.selected),Qi(1),pa("ngSwitch",!(!e.iconOverrides||!e.iconOverrides[e.state])),Qi(1),pa("ngSwitchCase",!0),Qi(2),Qa("mat-step-label-active",e.active)("mat-step-label-selected",e.selected)("mat-step-label-error","error"==e.state),Qi(1),pa("ngIf",e._templateLabel()),Qi(1),pa("ngIf",e._stringLabel()),Qi(1),pa("ngIf",e.optional&&"error"!=e.state),Qi(1),pa("ngIf","error"==e.state))},directives:[yJ,Rh,Lh,Fh,Ah,zh,x2],styles:[".mat-step-header{overflow:hidden;outline:none;cursor:pointer;position:relative;box-sizing:content-box;-webkit-tap-highlight-color:transparent}.mat-step-optional,.mat-step-sub-label-error{font-size:12px}.mat-step-icon{border-radius:50%;height:24px;width:24px;flex-shrink:0;position:relative}.mat-step-icon-content,.mat-step-icon .mat-icon{position:absolute;top:50%;left:50%;transform:translate(-50%, -50%)}.mat-step-icon .mat-icon{font-size:16px;height:16px;width:16px}.mat-step-icon-state-error .mat-icon{font-size:24px;height:24px;width:24px}.mat-step-label{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:50px;vertical-align:middle}.mat-step-text-label{text-overflow:ellipsis;overflow:hidden}.mat-step-header .mat-step-header-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}\n"],encapsulation:2,changeDetection:0}),t}(),nat={horizontalStepTransition:Jg("stepTransition",[rv("previous",iv({transform:"translate3d(-100%, 0, 0)",visibility:"hidden"})),rv("current",iv({transform:"none",visibility:"visible"})),rv("next",iv({transform:"translate3d(100%, 0, 0)",visibility:"hidden"})),av("* => *",tv("500ms cubic-bezier(0.35, 0, 0.25, 1)"))]),verticalStepTransition:Jg("stepTransition",[rv("previous",iv({height:"0px",visibility:"hidden"})),rv("next",iv({height:"0px",visibility:"hidden"})),rv("current",iv({height:"*",visibility:"visible"})),av("* <=> current",tv("225ms cubic-bezier(0.4, 0.0, 0.2, 1)"))])},iat=function(){var t=function t(e){Object(m.a)(this,t),this.templateRef=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["ng-template","matStepperIcon",""]],inputs:{name:["matStepperIcon","name"]}}),t}(),rat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,r))._errorStateMatcher=i,o}return Object(g.a)(n,[{key:"isErrorState",value:function(t,e){return this._errorStateMatcher.isErrorState(t,e)||!!(t&&t.invalid&&this.interacted)}}]),n}(Iot);return t.\u0275fac=function(e){return new(e||t)(da(Y((function(){return oat}))),da(oJ,4),da(jot,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-step"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,$ot,!0),2&t&&tl(i=sl())&&(e.stepLabel=i.first)},exportAs:["matStep"],features:[Ns([{provide:oJ,useExisting:t},{provide:Iot,useExisting:t}]),ws],ngContentSelectors:Kot,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),ua(0,Wot,1,0,"ng-template"))},encapsulation:2,changeDetection:0}),t}(),oat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments)).animationDone=new Uc,t._iconOverrides={},t._animationDone=new w.b,t}return Object(g.a)(n,[{key:"ngAfterContentInit",value:function(){var t=this;this._icons.forEach((function(e){return t._iconOverrides[e.name]=e.templateRef})),this._steps.changes.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){t._stateChanged()})),this._animationDone.pipe(Object(RJ.a)((function(t,e){return t.fromState===e.fromState&&t.toState===e.toState})),Object(Am.a)(this._destroyed)).subscribe((function(e){"current"===e.toState&&t.animationDone.emit()}))}}]),n}(Dot);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matStepper",""]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,rat,!0),rl(n,iat,!0)),2&t&&(tl(i=sl())&&(e._steps=i),tl(i=sl())&&(e._icons=i))},viewQuery:function(t,e){var n;1&t&&nl(eat,!0),2&t&&tl(n=sl())&&(e._stepHeader=n)},inputs:{disableRipple:"disableRipple"},outputs:{animationDone:"animationDone"},features:[Ns([{provide:Dot,useExisting:t}]),ws]});var e=zn(t);return t}(),aat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments)).labelPosition="end",t}return n}(oat);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-horizontal-stepper"]],hostAttrs:["aria-orientation","horizontal","role","tablist",1,"mat-stepper-horizontal"],hostVars:4,hostBindings:function(t,e){2&t&&Qa("mat-stepper-label-position-end","end"==e.labelPosition)("mat-stepper-label-position-bottom","bottom"==e.labelPosition)},inputs:{selectedIndex:"selectedIndex",labelPosition:"labelPosition"},exportAs:["matHorizontalStepper"],features:[Ns([{provide:oat,useExisting:t},{provide:Dot,useExisting:t}]),ws],decls:4,vars:2,consts:[[1,"mat-horizontal-stepper-header-container"],[4,"ngFor","ngForOf"],[1,"mat-horizontal-content-container"],["class","mat-horizontal-stepper-content","role","tabpanel",3,"id",4,"ngFor","ngForOf"],[1,"mat-horizontal-stepper-header",3,"tabIndex","id","index","state","label","selected","active","optional","errorMessage","iconOverrides","disableRipple","click","keydown"],["class","mat-stepper-horizontal-line",4,"ngIf"],[1,"mat-stepper-horizontal-line"],["role","tabpanel",1,"mat-horizontal-stepper-content",3,"id"],[3,"ngTemplateOutlet"]],template:function(t,e){1&t&&(ga(0,"div",0),ua(1,Yot,3,18,"ng-container",1),va(),ga(2,"div",2),ua(3,Zot,2,6,"div",3),va()),2&t&&(Qi(1),pa("ngForOf",e.steps),Qi(2),pa("ngForOf",e.steps))},directives:[Eh,eat,Ah,zh],styles:['.mat-stepper-vertical,.mat-stepper-horizontal{display:block}.mat-horizontal-stepper-header-container{white-space:nowrap;display:flex;align-items:center}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header-container{align-items:flex-start}.mat-stepper-horizontal-line{border-top-width:1px;border-top-style:solid;flex:auto;height:0;margin:0 -16px;min-width:32px}.mat-stepper-label-position-bottom .mat-stepper-horizontal-line{margin:0;min-width:0;position:relative}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::before,.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::after,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::after{border-top-width:1px;border-top-style:solid;content:"";display:inline-block;height:0;position:absolute;width:calc(50% - 20px)}.mat-horizontal-stepper-header{display:flex;height:72px;overflow:hidden;align-items:center;padding:0 24px}.mat-horizontal-stepper-header .mat-step-icon{margin-right:8px;flex:none}[dir=rtl] .mat-horizontal-stepper-header .mat-step-icon{margin-right:0;margin-left:8px}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header{box-sizing:border-box;flex-direction:column;height:auto}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::after,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::after{right:0}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::before{left:0}[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:last-child::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:first-child::after{display:none}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header .mat-step-icon{margin-right:0;margin-left:0}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header .mat-step-label{padding:16px 0 0 0;text-align:center;width:100%}.mat-vertical-stepper-header{display:flex;align-items:center;height:24px}.mat-vertical-stepper-header .mat-step-icon{margin-right:12px}[dir=rtl] .mat-vertical-stepper-header .mat-step-icon{margin-right:0;margin-left:12px}.mat-horizontal-stepper-content{outline:0}.mat-horizontal-stepper-content[aria-expanded=false]{height:0;overflow:hidden}.mat-horizontal-content-container{overflow:hidden;padding:0 24px 24px 24px}.mat-vertical-content-container{margin-left:36px;border:0;position:relative}[dir=rtl] .mat-vertical-content-container{margin-left:0;margin-right:36px}.mat-stepper-vertical-line::before{content:"";position:absolute;left:0;border-left-width:1px;border-left-style:solid}[dir=rtl] .mat-stepper-vertical-line::before{left:auto;right:0}.mat-vertical-stepper-content{overflow:hidden;outline:0}.mat-vertical-content{padding:0 24px 24px 24px}.mat-step:last-child .mat-vertical-content-container{border:none}\n'],encapsulation:2,data:{animation:[nat.horizontalStepTransition]},changeDetection:0});var e=zn(t);return t}(),sat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,t,i,r,o))._orientation="vertical",a}return n}(oat);return t.\u0275fac=function(e){return new(e||t)(da(gm,8),da(Po),da(Us),da(du))},t.\u0275cmp=Ht({type:t,selectors:[["mat-vertical-stepper"]],hostAttrs:["aria-orientation","vertical","role","tablist",1,"mat-stepper-vertical"],inputs:{selectedIndex:"selectedIndex"},exportAs:["matVerticalStepper"],features:[Ns([{provide:oat,useExisting:t},{provide:Dot,useExisting:t}]),ws],decls:1,vars:1,consts:[["class","mat-step",4,"ngFor","ngForOf"],[1,"mat-step"],[1,"mat-vertical-stepper-header",3,"tabIndex","id","index","state","label","selected","active","optional","errorMessage","iconOverrides","disableRipple","click","keydown"],[1,"mat-vertical-content-container"],["role","tabpanel",1,"mat-vertical-stepper-content",3,"id"],[1,"mat-vertical-content"],[3,"ngTemplateOutlet"]],template:function(t,e){1&t&&ua(0,Qot,6,25,"div",0),2&t&&pa("ngForOf",e.steps)},directives:[Eh,eat,zh],styles:['.mat-stepper-vertical,.mat-stepper-horizontal{display:block}.mat-horizontal-stepper-header-container{white-space:nowrap;display:flex;align-items:center}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header-container{align-items:flex-start}.mat-stepper-horizontal-line{border-top-width:1px;border-top-style:solid;flex:auto;height:0;margin:0 -16px;min-width:32px}.mat-stepper-label-position-bottom .mat-stepper-horizontal-line{margin:0;min-width:0;position:relative}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::before,.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::after,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::after{border-top-width:1px;border-top-style:solid;content:"";display:inline-block;height:0;position:absolute;width:calc(50% - 20px)}.mat-horizontal-stepper-header{display:flex;height:72px;overflow:hidden;align-items:center;padding:0 24px}.mat-horizontal-stepper-header .mat-step-icon{margin-right:8px;flex:none}[dir=rtl] .mat-horizontal-stepper-header .mat-step-icon{margin-right:0;margin-left:8px}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header{box-sizing:border-box;flex-direction:column;height:auto}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::after,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::after{right:0}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::before{left:0}[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:last-child::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:first-child::after{display:none}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header .mat-step-icon{margin-right:0;margin-left:0}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header .mat-step-label{padding:16px 0 0 0;text-align:center;width:100%}.mat-vertical-stepper-header{display:flex;align-items:center;height:24px}.mat-vertical-stepper-header .mat-step-icon{margin-right:12px}[dir=rtl] .mat-vertical-stepper-header .mat-step-icon{margin-right:0;margin-left:12px}.mat-horizontal-stepper-content{outline:0}.mat-horizontal-stepper-content[aria-expanded=false]{height:0;overflow:hidden}.mat-horizontal-content-container{overflow:hidden;padding:0 24px 24px 24px}.mat-vertical-content-container{margin-left:36px;border:0;position:relative}[dir=rtl] .mat-vertical-content-container{margin-left:0;margin-right:36px}.mat-stepper-vertical-line::before{content:"";position:absolute;left:0;border-left-width:1px;border-left-style:solid}[dir=rtl] .mat-stepper-vertical-line::before{left:auto;right:0}.mat-vertical-stepper-content{overflow:hidden;outline:0}.mat-vertical-content{padding:0 24px 24px 24px}.mat-step:last-child .mat-vertical-content-container{border:none}\n'],encapsulation:2,data:{animation:[nat.verticalStepTransition]},changeDetection:0}),t}(),cat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Rot);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["button","matStepperNext",""]],hostVars:1,hostBindings:function(t,e){2&t&&bs("type",e.type)},inputs:{type:"type"},features:[ws]});var e=zn(t);return t}(),lat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Lot);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["button","matStepperPrevious",""]],hostVars:1,hostBindings:function(t,e){2&t&&bs("type",e.type)},inputs:{type:"type"},features:[ws]});var e=zn(t);return t}(),uat=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[tat,oJ],imports:[[$$,hd,z$,c2,Fot,O2,_J],$$]}),t}(),hat=["mat-sort-header",""];function dat(t,e){if(1&t){var n=ka();ga(0,"div",3),xa("@arrowPosition.start",(function(){return Se(n),Aa()._disableViewStateAnimation=!0}))("@arrowPosition.done",(function(){return Se(n),Aa()._disableViewStateAnimation=!1})),ba(1,"div",4),ga(2,"div",5),ba(3,"div",6),ba(4,"div",7),ba(5,"div",8),va(),va()}if(2&t){var i=Aa();pa("@arrowOpacity",i._getArrowViewState())("@arrowPosition",i._getArrowViewState())("@allowChildren",i._getArrowDirectionState()),Qi(2),pa("@indicator",i._getArrowDirectionState()),Qi(1),pa("@leftPointer",i._getArrowDirectionState()),Qi(1),pa("@rightPointer",i._getArrowDirectionState())}}var fat=["*"],pat=rJ(J$((function t(){Object(m.a)(this,t)}))),mat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments)).sortables=new Map,t._stateChanges=new w.b,t.start="asc",t._direction="",t.sortChange=new Uc,t}return Object(g.a)(n,[{key:"register",value:function(t){if(!t.id)throw Error("MatSortHeader must be provided with a unique id.");if(this.sortables.has(t.id))throw Error("Cannot have two MatSortables with the same id (".concat(t.id,")."));this.sortables.set(t.id,t)}},{key:"deregister",value:function(t){this.sortables.delete(t.id)}},{key:"sort",value:function(t){this.active!=t.id?(this.active=t.id,this.direction=t.start?t.start:this.start):this.direction=this.getNextSortDirection(t),this.sortChange.emit({active:this.active,direction:this.direction})}},{key:"getNextSortDirection",value:function(t){if(!t)return"";var e,n,i=(e=null!=t.disableClear?t.disableClear:this.disableClear,n=["asc","desc"],"desc"==(t.start||this.start)&&n.reverse(),e||n.push(""),n),r=i.indexOf(this.direction)+1;return r>=i.length&&(r=0),i[r]}},{key:"ngOnInit",value:function(){this._markInitialized()}},{key:"ngOnChanges",value:function(){this._stateChanges.next()}},{key:"ngOnDestroy",value:function(){this._stateChanges.complete()}},{key:"direction",get:function(){return this._direction},set:function(t){if(ii()&&t&&"asc"!==t&&"desc"!==t)throw function(t){return Error("".concat(t," is not a valid sort direction ('asc' or 'desc')."))}(t);this._direction=t}},{key:"disableClear",get:function(){return this._disableClear},set:function(t){this._disableClear=nm(t)}}]),n}(pat);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matSort",""]],hostAttrs:[1,"mat-sort"],inputs:{disabled:["matSortDisabled","disabled"],start:["matSortStart","start"],direction:["matSortDirection","direction"],disableClear:["matSortDisableClear","disableClear"],active:["matSortActive","active"]},outputs:{sortChange:"matSortChange"},exportAs:["matSort"],features:[ws,Ms]});var e=zn(t);return t}(),gat=Y$.ENTERING+" "+X$.STANDARD_CURVE,vat={indicator:Jg("indicator",[rv("active-asc, asc",iv({transform:"translateY(0px)"})),rv("active-desc, desc",iv({transform:"translateY(10px)"})),av("active-asc <=> active-desc",tv(gat))]),leftPointer:Jg("leftPointer",[rv("active-asc, asc",iv({transform:"rotate(-45deg)"})),rv("active-desc, desc",iv({transform:"rotate(45deg)"})),av("active-asc <=> active-desc",tv(gat))]),rightPointer:Jg("rightPointer",[rv("active-asc, asc",iv({transform:"rotate(45deg)"})),rv("active-desc, desc",iv({transform:"rotate(-45deg)"})),av("active-asc <=> active-desc",tv(gat))]),arrowOpacity:Jg("arrowOpacity",[rv("desc-to-active, asc-to-active, active",iv({opacity:1})),rv("desc-to-hint, asc-to-hint, hint",iv({opacity:.54})),rv("hint-to-desc, active-to-desc, desc, hint-to-asc, active-to-asc, asc, void",iv({opacity:0})),av("* => asc, * => desc, * => active, * => hint, * => void",tv("0ms")),av("* <=> *",tv(gat))]),arrowPosition:Jg("arrowPosition",[av("* => desc-to-hint, * => desc-to-active",tv(gat,ov([iv({transform:"translateY(-25%)"}),iv({transform:"translateY(0)"})]))),av("* => hint-to-desc, * => active-to-desc",tv(gat,ov([iv({transform:"translateY(0)"}),iv({transform:"translateY(25%)"})]))),av("* => asc-to-hint, * => asc-to-active",tv(gat,ov([iv({transform:"translateY(25%)"}),iv({transform:"translateY(0)"})]))),av("* => hint-to-asc, * => active-to-asc",tv(gat,ov([iv({transform:"translateY(0)"}),iv({transform:"translateY(-25%)"})]))),rv("desc-to-hint, asc-to-hint, hint, desc-to-active, asc-to-active, active",iv({transform:"translateY(0)"})),rv("hint-to-desc, active-to-desc, desc",iv({transform:"translateY(-25%)"})),rv("hint-to-asc, active-to-asc, asc",iv({transform:"translateY(25%)"}))]),allowChildren:Jg("allowChildren",[av("* <=> *",[cv("@*",sv(),{optional:!0})])])},bat=function(){var t=function t(){Object(m.a)(this,t),this.changes=new w.b,this.sortButtonLabel=function(t){return"Change sorting for ".concat(t)}};return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=R({factory:function(){return new t},token:t,providedIn:"root"}),t}(),yat={provide:bat,deps:[[new E,new A,bat]],useFactory:function(t){return t||new bat}},_at=J$((function t(){Object(m.a)(this,t)})),wat=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s){var c;if(Object(m.a)(this,n),(c=e.call(this))._intl=t,c._sort=r,c._columnDef=o,c._focusMonitor=a,c._elementRef=s,c._showIndicatorHint=!1,c._arrowDirection="",c._disableViewStateAnimation=!1,c.arrowPosition="after",!r)throw Error("MatSortHeader must be placed within a parent element with the MatSort directive.");return c._rerenderSubscription=Object(C.a)(r.sortChange,r._stateChanges,t.changes).subscribe((function(){c._isSorted()&&c._updateArrowDirection(),!c._isSorted()&&c._viewState&&"active"===c._viewState.toState&&(c._disableViewStateAnimation=!1,c._setAnimationTransitionState({fromState:"active",toState:c._arrowDirection})),i.markForCheck()})),c}return Object(g.a)(n,[{key:"ngOnInit",value:function(){!this.id&&this._columnDef&&(this.id=this._columnDef.name),this._updateArrowDirection(),this._setAnimationTransitionState({toState:this._isSorted()?"active":this._arrowDirection}),this._sort.register(this)}},{key:"ngAfterViewInit",value:function(){var t=this;this._focusMonitor.monitor(this._elementRef,!0).subscribe((function(e){return t._setIndicatorHintVisible(!!e)}))}},{key:"ngOnDestroy",value:function(){this._focusMonitor.stopMonitoring(this._elementRef),this._sort.deregister(this),this._rerenderSubscription.unsubscribe()}},{key:"_setIndicatorHintVisible",value:function(t){this._isDisabled()&&t||(this._showIndicatorHint=t,this._isSorted()||(this._updateArrowDirection(),this._setAnimationTransitionState(this._showIndicatorHint?{fromState:this._arrowDirection,toState:"hint"}:{fromState:"hint",toState:this._arrowDirection})))}},{key:"_setAnimationTransitionState",value:function(t){this._viewState=t,this._disableViewStateAnimation&&(this._viewState={toState:t.toState})}},{key:"_handleClick",value:function(){if(!this._isDisabled()){this._sort.sort(this),"hint"!==this._viewState.toState&&"active"!==this._viewState.toState||(this._disableViewStateAnimation=!0);var t=this._isSorted()?{fromState:this._arrowDirection,toState:"active"}:{fromState:"active",toState:this._arrowDirection};this._setAnimationTransitionState(t),this._showIndicatorHint=!1}}},{key:"_isSorted",value:function(){return this._sort.active==this.id&&("asc"===this._sort.direction||"desc"===this._sort.direction)}},{key:"_getArrowDirectionState",value:function(){return"".concat(this._isSorted()?"active-":"").concat(this._arrowDirection)}},{key:"_getArrowViewState",value:function(){var t=this._viewState.fromState;return(t?"".concat(t,"-to-"):"")+this._viewState.toState}},{key:"_updateArrowDirection",value:function(){this._arrowDirection=this._isSorted()?this._sort.direction:this.start||this._sort.start}},{key:"_isDisabled",value:function(){return this._sort.disabled||this.disabled}},{key:"_getAriaSortAttribute",value:function(){return this._isSorted()?"asc"==this._sort.direction?"ascending":"descending":null}},{key:"_renderArrow",value:function(){return!this._isDisabled()||this._isSorted()}},{key:"disableClear",get:function(){return this._disableClear},set:function(t){this._disableClear=nm(t)}}]),n}(_at);return t.\u0275fac=function(e){return new(e||t)(da(bat),da(Po),da(mat,8),da("MAT_SORT_HEADER_COLUMN_DEF",8),da(S$),da(Us))},t.\u0275cmp=Ht({type:t,selectors:[["","mat-sort-header",""]],hostAttrs:[1,"mat-sort-header"],hostVars:3,hostBindings:function(t,e){1&t&&xa("click",(function(){return e._handleClick()}))("mouseenter",(function(){return e._setIndicatorHintVisible(!0)}))("mouseleave",(function(){return e._setIndicatorHintVisible(!1)})),2&t&&(oa("aria-sort",e._getAriaSortAttribute()),Qa("mat-sort-header-disabled",e._isDisabled()))},inputs:{disabled:"disabled",arrowPosition:"arrowPosition",disableClear:"disableClear",id:["mat-sort-header","id"],start:"start"},exportAs:["matSortHeader"],features:[ws],attrs:hat,ngContentSelectors:fat,decls:4,vars:7,consts:[[1,"mat-sort-header-container"],["type","button",1,"mat-sort-header-button","mat-focus-indicator"],["class","mat-sort-header-arrow",4,"ngIf"],[1,"mat-sort-header-arrow"],[1,"mat-sort-header-stem"],[1,"mat-sort-header-indicator"],[1,"mat-sort-header-pointer-left"],[1,"mat-sort-header-pointer-right"],[1,"mat-sort-header-pointer-middle"]],template:function(t,e){1&t&&(Ia(),ga(0,"div",0),ga(1,"button",1),Da(2),va(),ua(3,dat,6,6,"div",2),va()),2&t&&(Qa("mat-sort-header-sorted",e._isSorted())("mat-sort-header-position-before","before"==e.arrowPosition),Qi(1),oa("disabled",e._isDisabled()||null)("aria-label",e._intl.sortButtonLabel(e.id)),Qi(2),pa("ngIf",e._renderArrow()))},directives:[Ah],styles:[".mat-sort-header-container{display:flex;cursor:pointer;align-items:center}.mat-sort-header-disabled .mat-sort-header-container{cursor:default}.mat-sort-header-position-before{flex-direction:row-reverse}.mat-sort-header-button{border:none;background:0 0;display:flex;align-items:center;padding:0;cursor:inherit;outline:0;font:inherit;color:currentColor}[mat-sort-header].cdk-keyboard-focused .mat-sort-header-button,[mat-sort-header].cdk-program-focused .mat-sort-header-button{border-bottom:solid 1px currentColor}.mat-sort-header-button::-moz-focus-inner{border:0}.mat-sort-header-arrow{height:12px;width:12px;min-width:12px;position:relative;display:flex;opacity:0}.mat-sort-header-arrow,[dir=rtl] .mat-sort-header-position-before .mat-sort-header-arrow{margin:0 0 0 6px}.mat-sort-header-position-before .mat-sort-header-arrow,[dir=rtl] .mat-sort-header-arrow{margin:0 6px 0 0}.mat-sort-header-stem{background:currentColor;height:10px;width:2px;margin:auto;display:flex;align-items:center}.cdk-high-contrast-active .mat-sort-header-stem{width:0;border-left:solid 2px}.mat-sort-header-indicator{width:100%;height:2px;display:flex;align-items:center;position:absolute;top:0;left:0}.mat-sort-header-pointer-middle{margin:auto;height:2px;width:2px;background:currentColor;transform:rotate(45deg)}.cdk-high-contrast-active .mat-sort-header-pointer-middle{width:0;height:0;border-top:solid 2px;border-left:solid 2px}.mat-sort-header-pointer-left,.mat-sort-header-pointer-right{background:currentColor;width:6px;height:2px;position:absolute;top:0}.cdk-high-contrast-active .mat-sort-header-pointer-left,.cdk-high-contrast-active .mat-sort-header-pointer-right{width:0;height:0;border-left:solid 6px;border-top:solid 2px}.mat-sort-header-pointer-left{transform-origin:right;left:0}.mat-sort-header-pointer-right{transform-origin:left;right:0}\n"],encapsulation:2,data:{animation:[vat.indicator,vat.leftPointer,vat.rightPointer,vat.arrowOpacity,vat.arrowPosition,vat.allowChildren]},changeDetection:0}),t}(),kat=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[yat],imports:[[hd]]}),t}(),Cat=function(){function t(){}return t.prototype.transform=function(t,e){return t?e?(e=e.toLowerCase(),t.filteredData.filter((function(t){return t.name.toLowerCase().includes(e)}))):t:[]},t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"datasourcefilter",type:t,pure:!0}),t}(),Sat=["stepper"];function xat(t,e){1&t&&ds(0,"Please select how you want to create new template")}function Oat(t,e){1&t&&ds(0),2&t&&fs(Aa().actionTitle)}function Mat(t,e){if(1&t&&(ga(0,"mat-option",33),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Tat(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Name "),va())}function Eat(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.name," ")}}function Pat(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Emulator "),va())}function Aat(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.emulator," ")}}function jat(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Vendor "),va())}function Iat(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.vendor_name," ")}}function Dat(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Actions "),va())}function Rat(t,e){if(1&t){var n=ka();ga(0,"mat-cell",34),ga(1,"button",35),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().install(t)})),ga(2,"mat-icon",36),ds(3,"archive"),va(),va(),ga(4,"button",37),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().showInfo(t)})),ga(5,"mat-icon",38),ds(6,"info"),va(),va(),va()}}function Lat(t,e){1&t&&ba(0,"mat-header-row")}function Fat(t,e){1&t&&ba(0,"mat-row")}function Nat(t,e){1&t&&ds(0),2&t&&fs(Aa(2).secondActionTitle)}function Bat(t,e){if(1&t&&(ga(0,"mat-option",33),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n.path," ")}}function Hat(t,e){1&t&&(ga(0,"span"),ga(1,"mat-icon",52),ds(2,"check"),va(),va())}function zat(t,e){1&t&&(ga(0,"span"),ga(1,"mat-icon",53),ds(2,"close"),va(),va())}function Vat(t,e){if(1&t){var n=ka();ga(0,"div",48),ga(1,"span"),ds(2),va(),ga(3,"div"),ua(4,Hat,3,0,"span",32),ua(5,zat,3,0,"span",32),ga(6,"input",49,50),xa("change",(function(t){return Se(n),Aa(4).importImage(t)})),va(),ga(8,"button",51),xa("click",(function(){return Se(n),ha(7).click()})),ds(9,"Import"),va(),ga(10,"button",51),xa("click",(function(){Se(n);var t=Aa().$implicit;return Aa(3).downloadImageFromVersion(t.images.hda_disk_image)})),ds(11,"Download"),va(),va(),va()}if(2&t){var i=Aa().$implicit,r=Aa(3);Qi(2),ps(" ",i.images.hda_disk_image," "),Qi(2),pa("ngIf",r.checkImageFromVersion(i.images.hda_disk_image)),Qi(1),pa("ngIf",!r.checkImageFromVersion(i.images.hda_disk_image)),Qi(1),pa("uploader",r.uploaderImage)}}function Uat(t,e){1&t&&(ga(0,"span"),ga(1,"mat-icon",52),ds(2,"check"),va(),va())}function qat(t,e){1&t&&(ga(0,"span"),ga(1,"mat-icon",53),ds(2,"close"),va(),va())}function Gat(t,e){if(1&t){var n=ka();ga(0,"div",48),ga(1,"span"),ds(2),va(),ga(3,"div"),ua(4,Uat,3,0,"span",32),ua(5,qat,3,0,"span",32),ga(6,"input",49,50),xa("change",(function(t){return Se(n),Aa(4).importImage(t)})),va(),ga(8,"button",51),xa("click",(function(){return Se(n),ha(7).click()})),ds(9,"Import"),va(),ga(10,"button",51),xa("click",(function(){Se(n);var t=Aa().$implicit;return Aa(3).downloadImageFromVersion(t.images.hdb_disk_image)})),ds(11,"Download"),va(),va(),va()}if(2&t){var i=Aa().$implicit,r=Aa(3);Qi(2),ps(" ",i.images.hdb_disk_image," "),Qi(2),pa("ngIf",r.checkImageFromVersion(i.images.hdb_disk_image)),Qi(1),pa("ngIf",!r.checkImageFromVersion(i.images.hdb_disk_image)),Qi(1),pa("uploader",r.uploaderImage)}}function Wat(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"div",45),ga(2,"span"),ds(3),va(),ga(4,"div"),ga(5,"button",46),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).createQemuTemplateFromVersion(t)})),ds(6,"Create"),va(),va(),va(),ua(7,Vat,12,4,"div",47),ua(8,Gat,12,4,"div",47),va()}if(2&t){var i=e.$implicit,r=Aa(3);Qi(3),ms("",r.applianceToInstall.name," version ",i.name,""),Qi(4),pa("ngIf",i.images.hda_disk_image),Qi(1),pa("ngIf",i.images.hdb_disk_image)}}var Kat=function(){return{standalone:!0}};function Xat(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"div"),ds(2," Server type"),ba(3,"br"),ga(4,"mat-radio-group",4),ga(5,"mat-radio-button",39),xa("click",(function(){return Se(n),Aa(2).setServerType("local")})),ds(6,"Install the appliance locally"),va(),ga(7,"mat-radio-button",40),xa("click",(function(){return Se(n),Aa(2).setServerType("gns3 vm")})),ds(8,"Install the appliance on the GNS3 VM"),va(),va(),va(),ga(9,"div"),ds(10," Qemu binary"),ba(11,"br"),ga(12,"mat-select",41),xa("ngModelChange",(function(t){return Se(n),Aa(2).selectedBinary=t})),ua(13,Bat,2,2,"mat-option",14),va(),va(),ga(14,"div"),ds(15," Install required files "),ga(16,"button",42),xa("click",(function(){return Se(n),Aa(2).refreshImages()})),ga(17,"mat-icon",43),ds(18,"refresh"),va(),va(),ba(19,"br"),ga(20,"div"),ua(21,Wat,9,4,"div",44),va(),va(),va()}if(2&t){var i=Aa(2);Qi(5),pa("disabled",!i.isLinuxPlatform)("checked",!i.isGns3VmChosen),Qi(2),pa("disabled",!i.isGns3VmAvailable)("checked",i.isGns3VmChosen),Qi(5),pa("ngModel",i.selectedBinary)("ngModelOptions",jc(8,Kat)),Qi(1),pa("ngForOf",i.qemuBinaries),Qi(8),pa("ngForOf",i.applianceToInstall.versions)}}function Yat(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"div"),ds(2," Server type"),ba(3,"br"),ga(4,"mat-radio-group",4),ga(5,"mat-radio-button",39),xa("click",(function(){return Se(n),Aa(2).setServerType("local")})),ds(6,"Install the appliance locally"),va(),ga(7,"mat-radio-button",40),xa("click",(function(){return Se(n),Aa(2).setServerType("gns3 vm")})),ds(8,"Install the appliance on the GNS3 VM"),va(),va(),va(),ga(9,"button",29),xa("click",(function(){return Se(n),Aa(2).createDockerTemplate()})),ds(10,"Create docker template"),va(),va()}if(2&t){var i=Aa(2);Qi(5),pa("disabled",!i.isLinuxPlatform)("checked",!i.isGns3VmChosen),Qi(2),pa("disabled",!i.isGns3VmAvailable)("checked",i.isGns3VmChosen)}}function Zat(t,e){if(1&t){var n=ka();ga(0,"mat-list-item"),ga(1,"div",45),ga(2,"div"),ds(3),va(),ga(4,"div"),ga(5,"input",49,50),xa("change",(function(t){return Se(n),Aa(3).importImage(t)})),va(),ga(7,"button",51),xa("click",(function(){return Se(n),ha(6).click()})),ds(8,"Import"),va(),ga(9,"button",46),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).createIosTemplate(t)})),ds(10,"Create"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=Aa(3);Qi(3),ps(" ",i.filename," "),Qi(2),pa("uploader",r.uploaderImage)}}function Qat(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"div"),ds(2," Server type"),ba(3,"br"),ga(4,"mat-radio-group",4),ga(5,"mat-radio-button",54),xa("click",(function(){return Se(n),Aa(2).setServerType("local")})),ds(6,"Install the appliance locally"),va(),ga(7,"mat-radio-button",40),xa("click",(function(){return Se(n),Aa(2).setServerType("gns3 vm")})),ds(8,"Install the appliance on the GNS3 VM"),va(),va(),va(),ga(9,"div"),ds(10," Install required files "),ga(11,"button",42),xa("click",(function(){return Se(n),Aa(2).refreshImages()})),ga(12,"mat-icon",43),ds(13,"refresh"),va(),va(),ba(14,"br"),ga(15,"mat-list"),ua(16,Zat,11,2,"mat-list-item",44),va(),va(),va()}if(2&t){var i=Aa(2);Qi(5),pa("checked",!i.isGns3VmChosen),Qi(2),pa("disabled",!i.isGns3VmAvailable)("checked",i.isGns3VmChosen),Qi(9),pa("ngForOf",i.applianceToInstall.images)}}function $at(t,e){if(1&t){var n=ka();ga(0,"mat-list-item"),ga(1,"div",45),ga(2,"div"),ds(3),va(),ga(4,"div"),ga(5,"input",49,50),xa("change",(function(t){return Se(n),Aa(3).importImage(t)})),va(),ga(7,"button",51),xa("click",(function(){return Se(n),ha(6).click()})),ds(8,"Import"),va(),ga(9,"button",46),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).createIouTemplate(t)})),ds(10,"Create"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=Aa(3);Qi(3),ps(" ",i.filename," "),Qi(2),pa("uploader",r.uploaderImage)}}function Jat(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"div"),ds(2," Server type"),ba(3,"br"),ga(4,"mat-radio-group",4),ga(5,"mat-radio-button",39),xa("click",(function(){return Se(n),Aa(2).setServerType("local")})),ds(6,"Install the appliance locally"),va(),ga(7,"mat-radio-button",40),xa("click",(function(){return Se(n),Aa(2).setServerType("gns3 vm")})),ds(8,"Install the appliance on the GNS3 VM"),va(),va(),va(),ga(9,"div"),ds(10," Install required files "),ga(11,"button",42),xa("click",(function(){return Se(n),Aa(2).refreshImages()})),ga(12,"mat-icon",43),ds(13,"refresh"),va(),va(),ba(14,"br"),ga(15,"mat-list"),ua(16,$at,11,2,"mat-list-item",44),va(),va(),va()}if(2&t){var i=Aa(2);Qi(5),pa("disabled",!i.isLinuxPlatform)("checked",!i.isGns3VmChosen),Qi(2),pa("disabled",!i.isGns3VmAvailable)("checked",i.isGns3VmChosen),Qi(9),pa("ngForOf",i.applianceToInstall.images)}}function tst(t,e){if(1&t){var n=ka();ga(0,"mat-step"),ua(1,Nat,1,1,"ng-template",3),ga(2,"mat-card",9),ds(3," Please configure GNS3 VM to install selected appliance "),va(),ga(4,"mat-card",9),ua(5,Xat,22,9,"div",32),ua(6,Yat,11,4,"div",32),ua(7,Qat,17,4,"div",32),ua(8,Jat,17,5,"div",32),va(),ga(9,"div"),ga(10,"button",30),ds(11,"Back"),va(),ga(12,"button",8),xa("click",(function(){return Se(n),Aa().onCloseClick()})),ds(13,"Cancel"),va(),va(),va()}if(2&t){var i=Aa();Qi(2),pa("hidden",!(!i.isLinuxPlatform&&!i.isGns3VmAvailable&&!i.applianceToInstall.dynamips)),Qi(2),pa("hidden",!(i.isLinuxPlatform||i.isGns3VmAvailable||i.applianceToInstall.dynamips)),Qi(1),pa("ngIf",i.applianceToInstall.qemu),Qi(1),pa("ngIf",i.applianceToInstall.docker),Qi(1),pa("ngIf",i.applianceToInstall.dynamips),Qi(1),pa("ngIf",i.applianceToInstall.iou)}}var est=function(){return[5,10,20,50,100]},nst=function(){function t(t,e,n,i,r,o,a,s,c,l,u,h,d){this.dialogRef=t,this.applianceService=e,this.changeDetector=n,this.toasterService=i,this.qemuService=r,this.dockerService=o,this.iosService=a,this.iouService=s,this.templateService=c,this.dialog=l,this.computeService=u,this.changeDetectorRef=h,this.progressService=d,this.action="install",this.actionTitle="Install appliance from server",this.secondActionTitle="Appliance settings",this.searchText="",this.allAppliances=[],this.appliances=[],this.isGns3VmAvailable=!1,this.isLinuxPlatform=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!1,this.qemuBinaries=[],this.categories=["all categories","router","multilayer_switch","guest","firewall"],this.category="all categories",this.displayedColumns=["name","emulator","vendor","actions"],this.qemuImages=[],this.iosImages=[],this.iouImages=[],this.templates=[]}return t.prototype.ngOnInit=function(){var t=this;this.templateService.list(this.server).subscribe((function(e){t.templates=e})),this.computeService.getComputes(this.server).subscribe((function(e){e.forEach((function(e){"vm"===e.compute_id&&(t.isGns3VmAvailable=!0,t.isGns3VmChosen=!0),"linux"===e.capabilities.platform&&(t.isLinuxPlatform=!0)}))})),this.qemuService.getImages(this.server).subscribe((function(e){t.qemuImages=e})),this.iosService.getImages(this.server).subscribe((function(e){t.iosImages=e})),this.iouService.getImages(this.server).subscribe((function(e){t.iouImages=e})),this.applianceService.getAppliances(this.server).subscribe((function(e){t.appliances=e,t.appliances.forEach((function(t){t.docker&&(t.emulator="Docker"),t.dynamips&&(t.emulator="Dynamips"),t.iou&&(t.emulator="Iou"),t.qemu&&(t.emulator="Qemu")})),t.allAppliances=e,t.dataSource=new m4(t.allAppliances),t.dataSource.paginator=t.paginator})),this.qemuService.getBinaries(this.server).subscribe((function(e){t.qemuBinaries=e})),this.uploader=new wX({}),this.uploader.onAfterAddingFile=function(t){t.withCredentials=!1},this.uploader.onErrorItem=function(e,n,i,r){t.toasterService.error("An error has occured")},this.uploader.onSuccessItem=function(e,n,i,r){t.toasterService.success("Appliance imported succesfully"),t.getAppliance(e.url)},this.uploaderImage=new wX({}),this.uploaderImage.onAfterAddingFile=function(t){t.withCredentials=!1},this.uploaderImage.onErrorItem=function(e,n,i,r){t.toasterService.error("An error has occured"),t.progressService.deactivate()},this.uploaderImage.onSuccessItem=function(e,n,i,r){t.toasterService.success("Image imported succesfully"),t.refreshImages(),t.progressService.deactivate()}},t.prototype.updateAppliances=function(){var t=this;this.progressService.activate(),this.applianceService.updateAppliances(this.server).subscribe((function(e){t.appliances=e,t.progressService.deactivate(),t.toasterService.success("Appliances are up-to-date.")}),(function(e){t.progressService.deactivate(),t.toasterService.error("Appliances were not updated correctly.")}))},t.prototype.refreshImages=function(){var t=this;this.qemuService.getImages(this.server).subscribe((function(e){t.qemuImages=e})),this.iosService.getImages(this.server).subscribe((function(e){t.iosImages=e})),this.iouService.getImages(this.server).subscribe((function(e){t.iouImages=e}))},t.prototype.getAppliance=function(t){var e=this,n=t.split("/v2");this.applianceService.getAppliance(this.server,n[n.length-1]).subscribe((function(t){e.applianceToInstall=t,setTimeout((function(){e.stepper.next()}),100)}))},t.prototype.addAppliance=function(t){var e,n=this,i=(t.target.files[0].name.split("-"),t.target.files[0].name),r=t.target.files[0],o=new FileReader;o.onloadend=function(){var t=JSON.parse(o.result);t.docker&&(e="docker"),t.dynamips&&(e="dynamips"),t.iou&&(e="iou"),t.qemu&&(e="qemu");var r=n.applianceService.getUploadPath(n.server,e,i);n.uploader.queue.forEach((function(t){return t.url=r}));var a=n.uploader.queue[0];a.options.disableMultipart=!0,n.uploader.uploadItem(a)},o.readAsText(r)},t.prototype.filterAppliances=function(t){var e=this,n=this.allAppliances.filter((function(t){return t.name.toLowerCase().includes(e.searchText.toLowerCase())}));this.appliances="all categories"!==this.category&&this.category?n.filter((function(t){return t.category===e.category})):n,this.dataSource=new m4(this.appliances),this.dataSource.paginator=this.paginator},t.prototype.setAction=function(t){this.action=t,"install"===t?this.actionTitle="Install appliance from server":"import"===t&&(this.actionTitle="Import an appliance file")},t.prototype.setServerType=function(t){"gns3 vm"===t?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.sortData=function(t){if(t.active&&""!==t.direction){var e=this.appliances.slice();this.appliances=e.sort((function(e,n){var i="asc"===t.direction;return"name"===t.active?ist(e.name,n.name,i):"emulator"===t.active?ist(e.emulator,n.emulator,i):"vendor"===t.active?ist(e.vendor_name,n.vendor_name,i):0}))}},t.prototype.onCloseClick=function(){this.dialogRef.close()},t.prototype.install=function(t){var e=this;this.applianceToInstall=t,setTimeout((function(){e.stepper.next(),e.applianceToInstall.qemu&&setTimeout((function(){if(e.qemuBinaries.length)if("x86_64"===e.applianceToInstall.qemu.arch)(t=e.qemuBinaries.filter((function(t){return t.path.includes("qemu-system-x86_64")}))).length&&(e.selectedBinary=t[0]);else if("i386"===e.applianceToInstall.qemu.arch)(t=e.qemuBinaries.filter((function(t){return t.path.includes("qemu-system-i386")}))).length&&(e.selectedBinary=t[0]);else if("x86_64"===e.applianceToInstall.qemu.arch){var t;(t=e.qemuBinaries.filter((function(t){return t.path.includes("qemu-system-arm")}))).length&&(e.selectedBinary=t[0])}else e.selectedBinary=e.qemuBinaries[0]}),100)}),100)},t.prototype.showInfo=function(t){this.dialog.open(hot,{width:"250px",data:{appliance:t}}).componentInstance.appliance=t},t.prototype.importImage=function(t){var e,n=this,i=(t.target.files[0].name.split("-"),t.target.files[0].name),r=t.target.files[0],o=new FileReader;o.onloadend=function(){n.applianceToInstall.qemu&&(e="qemu"),n.applianceToInstall.dynamips&&(e="dynamips"),n.applianceToInstall.iou&&(e="iou");var t=n.applianceService.getUploadPath(n.server,e,i);n.uploaderImage.queue.forEach((function(e){return e.url=t}));var r=n.uploaderImage.queue[0];r.options.disableMultipart=!0,n.uploaderImage.uploadItem(r),n.progressService.activate()},o.readAsText(r)},t.prototype.checkImageFromVersion=function(t){var e=this.applianceToInstall.images.filter((function(e){return e.filename===t}))[0];if(this.applianceToInstall.qemu){if(this.qemuImages.filter((function(t){return t.md5sum===e.md5sum})).length>0)return!0}else if(this.applianceToInstall.dynamips){if(this.iosImages.filter((function(t){return t.md5sum===e.md5sum})).length>0)return!0}else if(this.applianceToInstall.iou&&this.iouImages.filter((function(t){return t.md5sum===e.md5sum})).length>0)return!0;return!1},t.prototype.checkImages=function(t){return!!(t.images.hdb_disk_image&&this.checkImageFromVersion(t.images.hda_disk_image)&&this.checkImageFromVersion(t.images.hdb_disk_image))||!!this.checkImageFromVersion(t.images.hda_disk_image)},t.prototype.openConfirmationDialog=function(t,e){var n=this.dialog.open(wot,{width:"400px",height:"200px",autoFocus:!1,disableClose:!0});n.componentInstance.confirmationMessage=t,n.afterClosed().subscribe((function(t){t&&window.open(e)}))},t.prototype.downloadImage=function(t){t.direct_download_url?t.compression?this.openConfirmationDialog("The file is compressed with "+t.compression+", it must be uncompressed first.",t.direct_download_url):window.open(t.direct_download_url):this.openConfirmationDialog("Download will redirect you where the required file can be downloaded, you may have to be registered with the vendor in order to download the file.",t.download_url)},t.prototype.downloadImageFromVersion=function(t){var e=this;this.applianceToInstall.images.forEach((function(n){n.filename===t&&e.downloadImage(n)}))},t.prototype.getCategory=function(){return"multilayer_switch"===this.applianceToInstall.category?"switch":this.applianceToInstall.category},t.prototype.createIouTemplate=function(t){var e=this,n=new bot;n.nvram=this.applianceToInstall.iou.nvram,n.ram=this.applianceToInstall.iou.ram,n.ethernet_adapters=this.applianceToInstall.iou.ethernet_adapters,n.serial_adapters=this.applianceToInstall.iou.serial_adapters,n.startup_config=this.applianceToInstall.iou.startup_config,n.builtin=this.applianceToInstall.builtin,n.category=this.getCategory(),n.default_name_format=this.applianceToInstall.port_name_format,n.symbol=this.applianceToInstall.symbol,n.compute_id=this.isGns3VmChosen?"vm":"local",n.template_id=Object(art.v4)(),n.path=t.filename,n.template_type="iou";var i=this.dialog.open(Oot,{width:"400px",height:"250px",autoFocus:!1,disableClose:!0,data:{name:this.applianceToInstall.name}});i.componentInstance.server=this.server,i.afterClosed().subscribe((function(t){if(!t)return!1;n.name=t,e.iouService.addTemplate(e.server,n).subscribe((function(t){e.templateService.newTemplateCreated.next(t),e.toasterService.success("Template added"),e.dialogRef.close()}))}))},t.prototype.createIosTemplate=function(t){var e=this,n=new mot;n.chassis=this.applianceToInstall.dynamips.chassis,n.nvram=this.applianceToInstall.dynamips.nvram,n.platform=this.applianceToInstall.dynamips.platform,n.ram=this.applianceToInstall.dynamips.ram,n.startup_config=this.applianceToInstall.dynamips.startup_config,n.slot0=this.applianceToInstall.dynamips.slot0,n.slot1=this.applianceToInstall.dynamips.slot1,n.slot2=this.applianceToInstall.dynamips.slot2,n.slot3=this.applianceToInstall.dynamips.slot3,n.slot4=this.applianceToInstall.dynamips.slot4,n.slot5=this.applianceToInstall.dynamips.slot5,n.slot6=this.applianceToInstall.dynamips.slot6,n.slot7=this.applianceToInstall.dynamips.slot7,n.builtin=this.applianceToInstall.builtin,n.category=this.getCategory(),n.default_name_format=this.applianceToInstall.port_name_format,n.symbol=this.applianceToInstall.symbol,n.compute_id=this.isGns3VmChosen?"vm":"local",n.template_id=Object(art.v4)(),n.image=t.filename,n.template_type="dynamips";var i=this.dialog.open(Oot,{width:"400px",height:"250px",autoFocus:!1,disableClose:!0,data:{name:this.applianceToInstall.name}});i.componentInstance.server=this.server,i.afterClosed().subscribe((function(t){if(!t)return!1;n.name=t,e.iosService.addTemplate(e.server,n).subscribe((function(t){e.templateService.newTemplateCreated.next(t),e.toasterService.success("Template added"),e.dialogRef.close()}))}))},t.prototype.createDockerTemplate=function(){var t=this,e=new fot;e.adapters=this.applianceToInstall.docker.adapters,e.console_type=this.applianceToInstall.docker.console_type,e.builtin=this.applianceToInstall.builtin,e.category=this.getCategory(),e.default_name_format=this.applianceToInstall.port_name_format,e.symbol=this.applianceToInstall.symbol,e.compute_id=this.isGns3VmChosen?"vm":"local",e.template_id=Object(art.v4)(),e.image=this.applianceToInstall.docker.image,e.template_type="docker";var n=this.dialog.open(Oot,{width:"400px",height:"250px",autoFocus:!1,disableClose:!0,data:{name:this.applianceToInstall.name}});n.componentInstance.server=this.server,n.afterClosed().subscribe((function(n){if(!n)return!1;e.name=n,t.dockerService.addTemplate(t.server,e).subscribe((function(e){t.templateService.newTemplateCreated.next(e),t.toasterService.success("Template added"),t.dialogRef.close()}))}))},t.prototype.createQemuTemplateFromVersion=function(t){var e=this;if(this.checkImages(t))if(this.selectedBinary){var n=new dot;n.ram=this.applianceToInstall.qemu.ram,n.adapters=this.applianceToInstall.qemu.adapters,n.adapter_type=this.applianceToInstall.qemu.adapter_type,n.boot_priority=this.applianceToInstall.qemu.boot_priority,n.console_type=this.applianceToInstall.qemu.console_type,n.hda_disk_interface=this.applianceToInstall.qemu.hda_disk_interface,n.hdb_disk_interface=this.applianceToInstall.qemu.hdb_disk_interface,n.hdc_disk_interface=this.applianceToInstall.qemu.hdc_disk_interface,n.hdd_disk_interface=this.applianceToInstall.qemu.hdd_disk_interface,n.builtin=this.applianceToInstall.builtin,n.category=this.getCategory(),n.first_port_name=this.applianceToInstall.first_port_name,n.port_name_format=this.applianceToInstall.port_name_format,n.symbol=this.applianceToInstall.symbol,n.qemu_path=this.selectedBinary.path,n.compute_id=this.isGns3VmChosen?"vm":"local",n.template_id=Object(art.v4)(),n.hda_disk_image=t.images.hda_disk_image,n.hdb_disk_image=t.images.hdb_disk_image,n.template_type="qemu",n.usage=this.applianceToInstall.usage;var i=this.dialog.open(Oot,{width:"400px",height:"250px",autoFocus:!1,disableClose:!0,data:{name:this.applianceToInstall.name}});i.componentInstance.server=this.server,i.afterClosed().subscribe((function(t){if(!t)return!1;n.name=t,e.qemuService.addTemplate(e.server,n).subscribe((function(t){e.templateService.newTemplateCreated.next(t),e.toasterService.success("Template added"),e.dialogRef.close()}))}))}else this.toasterService.error("Please select QEMU binary first");else this.toasterService.error("Please install required images first")},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(cot),da(Po),da(Y2),da(w6),da(pot),da(got),da(vot),da(yot),da(e1),da(_ot),da(Po),da(yet))},t.\u0275cmp=Ht({type:t,selectors:[["app-new-template-dialog"]],viewQuery:function(t,e){var n;1&t&&(el(aot,!0),el(Sat,!0)),2&t&&(tl(n=sl())&&(e.paginator=n.first),tl(n=sl())&&(e.stepper=n.first))},inputs:{server:"server",project:"project"},decls:56,vars:19,consts:[["mat-dialog-title",""],[3,"linear"],["stepper",""],["matStepLabel",""],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"click"],["mat-button","","matStepperNext",""],["mat-button","",3,"click"],[3,"hidden"],[1,"tableHeader"],[1,"filter-field"],["matInput","","placeholder","Filter",3,"ngModel","ngModelChange"],["placeholder","Category",3,"ngModelOptions","ngModel","selectionChange","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["matSort","","multiTemplateDataRows","",1,"mat-table",3,"dataSource","matSortChange"],["table",""],["matColumnDef","name"],[4,"matHeaderCellDef"],[4,"matCellDef"],["matColumnDef","emulator"],["matColumnDef","vendor"],["matColumnDef","actions"],["style","text-align: right",4,"matCellDef"],[4,"matHeaderRowDef"],[4,"matRowDef","matRowDefColumns"],["showFirstLastButtons","",3,"pageSizeOptions"],["type","file","accept",".gns3appliance, .gns3a","ng2FileSelect","",1,"non-visible",3,"uploader","change"],["file",""],["mat-raised-button","","color","primary",1,"create-button",3,"click"],["mat-button","","matStepperPrevious",""],["mat-button","",3,"hidden","click"],[4,"ngIf"],[3,"value"],[2,"text-align","right"],["mat-icon-button","","matTooltip","Install","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Install"],["mat-icon-button","","matTooltip","Show info","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Show info"],["value","1",1,"radio-button",3,"disabled","checked","click"],["value","2",1,"radio-button",3,"disabled","checked","click"],["placeholder","Qemu binary",1,"selection-group",3,"ngModel","ngModelOptions","ngModelChange"],["mat-icon-button","","matTooltip","Refresh list of images","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Refresh list of images"],[4,"ngFor","ngForOf"],[1,"list-item"],["mat-raised-button","","color","primary",1,"button",3,"click"],["class","list-item-inside",4,"ngIf"],[1,"list-item-inside"],["type","file","ng2FileSelect","",1,"non-visible",3,"uploader","change"],["file2",""],["mat-raised-button","",1,"button",3,"click"],["matTooltip","Ready to install","matTooltipClass","custom-tooltip"],["matTooltip","Missing","matTooltipClass","custom-tooltip"],["value","1",1,"radio-button",3,"checked","click"]],template:function(t,e){if(1&t){var n=ka();ga(0,"h1",0),ds(1,"Add new template"),va(),ga(2,"mat-horizontal-stepper",1,2),ga(4,"mat-step"),ua(5,xat,1,0,"ng-template",3),ga(6,"mat-radio-group",4),ga(7,"mat-radio-button",5),xa("click",(function(){return e.setAction("install")})),ds(8,"Install new appliance from the GNS server"),va(),ba(9,"br"),ga(10,"mat-radio-button",6),xa("click",(function(){return e.setAction("import")})),ds(11,"Import an appliance file"),va(),va(),ga(12,"div"),ga(13,"button",7),ds(14,"Next"),va(),ga(15,"button",8),xa("click",(function(){return e.onCloseClick()})),ds(16,"Cancel"),va(),va(),va(),ga(17,"mat-step"),ua(18,Oat,1,1,"ng-template",3),ga(19,"mat-card",9),ga(20,"div",10),ga(21,"mat-form-field",11),ga(22,"input",12),xa("ngModelChange",(function(t){return e.searchText=t})),va(),va(),ga(23,"mat-select",13),xa("selectionChange",(function(t){return e.filterAppliances(t)}))("ngModelChange",(function(t){return e.category=t})),ua(24,Mat,2,2,"mat-option",14),va(),va(),ga(25,"mat-table",15,16),xa("matSortChange",(function(t){return e.sortData(t)})),Nc(27,"datasourcefilter"),ya(28,17),ua(29,Tat,2,0,"mat-header-cell",18),ua(30,Eat,2,1,"mat-cell",19),_a(),ya(31,20),ua(32,Pat,2,0,"mat-header-cell",18),ua(33,Aat,2,1,"mat-cell",19),_a(),ya(34,21),ua(35,jat,2,0,"mat-header-cell",18),ua(36,Iat,2,1,"mat-cell",19),_a(),ya(37,22),ua(38,Dat,2,0,"mat-header-cell",18),ua(39,Rat,7,0,"mat-cell",23),_a(),ua(40,Lat,1,0,"mat-header-row",24),ua(41,Fat,1,0,"mat-row",25),va(),ba(42,"mat-paginator",26),va(),ga(43,"mat-card",9),ga(44,"input",27,28),xa("change",(function(t){return e.addAppliance(t)})),va(),ga(46,"button",29),xa("click",(function(){return Se(n),ha(45).click()})),ds(47,"Click to import appliance"),va(),va(),ga(48,"div"),ga(49,"button",30),ds(50,"Back"),va(),ga(51,"button",31),xa("click",(function(){return e.updateAppliances()})),ds(52,"Update from online registry"),va(),ga(53,"button",8),xa("click",(function(){return e.onCloseClick()})),ds(54,"Cancel"),va(),va(),va(),ua(55,tst,14,6,"mat-step",32),va()}2&t&&(Qi(2),pa("linear",!1),Qi(17),pa("hidden",!("install"===e.action)),Qi(3),pa("ngModel",e.searchText),Qi(1),pa("ngModelOptions",jc(17,Kat))("ngModel",e.category),Qi(1),pa("ngForOf",e.categories),Qi(1),pa("dataSource",Hc(27,14,e.dataSource,e.searchText)),Qi(15),pa("matHeaderRowDef",e.displayedColumns),Qi(1),pa("matRowDefColumns",e.displayedColumns),Qi(1),pa("pageSizeOptions",jc(18,est)),Qi(1),pa("hidden","install"===e.action),Qi(1),pa("uploader",e.uploader),Qi(7),pa("hidden","install"!==e.action),Qi(4),pa("ngIf",e.applianceToInstall))},directives:[r1,aat,rat,$ot,A6,D6,a2,cat,f3,Y3,s5,cf,mf,Sp,O5,Eh,$5,mat,n4,t4,J5,a4,c4,aot,kX,lat,Ah,EJ,i4,o4,k4,x2,l4,h4,_8,S8],pipes:[Cat],styles:[".radio-button[_ngcontent-%COMP%]{margin-bottom:30px}.filter-field[_ngcontent-%COMP%], .tableHeader[_ngcontent-%COMP%]{width:100%}.example-container[_ngcontent-%COMP%]{display:flex;flex-direction:column;max-height:500px;min-width:300px}.mat-table[_ngcontent-%COMP%]{overflow:auto;max-height:500px}.element-row[_ngcontent-%COMP%]{position:relative}.element-row[_ngcontent-%COMP%]:not(.expanded){cursor:pointer}.element-row[_ngcontent-%COMP%]:not(.expanded):hover{background:#f5f5f5}.element-row.expanded[_ngcontent-%COMP%]{border-bottom-color:transparent}.list-item[_ngcontent-%COMP%], .list-item-inside[_ngcontent-%COMP%]{display:flex;justify-content:space-between;width:100%;margin-bottom:15px}.list-item-inside[_ngcontent-%COMP%]{padding-left:30px}.button[_ngcontent-%COMP%]{margin-left:10px}.create-button[_ngcontent-%COMP%]{width:100%;margin-top:10px;margin-bottom:10px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.selection-group[_ngcontent-%COMP%]{padding-bottom:20px}"],data:{animation:[Jg("detailExpand",[rv("collapsed",iv({height:"0px",minHeight:"0",visibility:"hidden"})),rv("expanded",iv({height:"*",visibility:"visible"})),av("expanded <=> collapsed",tv("225ms cubic-bezier(0.4, 0.0, 0.2, 1)"))])]}}),t}();function ist(t,e,n){return((t=t.toLowerCase())<(e=e.toLowerCase())?-1:1)*(n?1:-1)}function rst(t,e){if(1&t&&(Qe(),ba(0,"circle",3)),2&t){var n=Aa();Za("animation-name","mat-progress-spinner-stroke-rotate-"+n.diameter)("stroke-dashoffset",n._strokeDashOffset,"px")("stroke-dasharray",n._strokeCircumference,"px")("stroke-width",n._circleStrokeWidth,"%"),oa("r",n._circleRadius)}}function ost(t,e){if(1&t&&(Qe(),ba(0,"circle",3)),2&t){var n=Aa();Za("stroke-dashoffset",n._strokeDashOffset,"px")("stroke-dasharray",n._strokeCircumference,"px")("stroke-width",n._circleStrokeWidth,"%"),oa("r",n._circleRadius)}}function ast(t,e){if(1&t&&(Qe(),ba(0,"circle",3)),2&t){var n=Aa();Za("animation-name","mat-progress-spinner-stroke-rotate-"+n.diameter)("stroke-dashoffset",n._strokeDashOffset,"px")("stroke-dasharray",n._strokeCircumference,"px")("stroke-width",n._circleStrokeWidth,"%"),oa("r",n._circleRadius)}}function sst(t,e){if(1&t&&(Qe(),ba(0,"circle",3)),2&t){var n=Aa();Za("stroke-dashoffset",n._strokeDashOffset,"px")("stroke-dasharray",n._strokeCircumference,"px")("stroke-width",n._circleStrokeWidth,"%"),oa("r",n._circleRadius)}}var cst=tJ((function t(e){Object(m.a)(this,t),this._elementRef=e}),"primary"),lst=new ht("mat-progress-spinner-default-options",{providedIn:"root",factory:function(){return{diameter:100}}}),ust=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){var s;Object(m.a)(this,n),(s=e.call(this,t))._elementRef=t,s._document=r,s._diameter=100,s._value=0,s._fallbackAnimation=!1,s.mode="determinate";var c=n._diameters;return c.has(r.head)||c.set(r.head,new Set([100])),s._fallbackAnimation=i.EDGE||i.TRIDENT,s._noopAnimations="NoopAnimations"===o&&!!a&&!a._forceAnimations,a&&(a.diameter&&(s.diameter=a.diameter),a.strokeWidth&&(s.strokeWidth=a.strokeWidth)),s}return Object(g.a)(n,[{key:"ngOnInit",value:function(){var t=this._elementRef.nativeElement;this._styleRoot=Em(t)||this._document.head,this._attachStyleNode();var e="mat-progress-spinner-indeterminate".concat(this._fallbackAnimation?"-fallback":"","-animation");t.classList.add(e)}},{key:"_attachStyleNode",value:function(){var t=this._styleRoot,e=this._diameter,i=n._diameters,r=i.get(t);if(!r||!r.has(e)){var o=this._document.createElement("style");o.setAttribute("mat-spinner-animation",e+""),o.textContent=this._getAnimationText(),t.appendChild(o),r||(r=new Set,i.set(t,r)),r.add(e)}}},{key:"_getAnimationText",value:function(){return"\n @keyframes mat-progress-spinner-stroke-rotate-DIAMETER {\n 0% { stroke-dashoffset: START_VALUE; transform: rotate(0); }\n 12.5% { stroke-dashoffset: END_VALUE; transform: rotate(0); }\n 12.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(72.5deg); }\n 25% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(72.5deg); }\n\n 25.0001% { stroke-dashoffset: START_VALUE; transform: rotate(270deg); }\n 37.5% { stroke-dashoffset: END_VALUE; transform: rotate(270deg); }\n 37.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(161.5deg); }\n 50% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(161.5deg); }\n\n 50.0001% { stroke-dashoffset: START_VALUE; transform: rotate(180deg); }\n 62.5% { stroke-dashoffset: END_VALUE; transform: rotate(180deg); }\n 62.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(251.5deg); }\n 75% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(251.5deg); }\n\n 75.0001% { stroke-dashoffset: START_VALUE; transform: rotate(90deg); }\n 87.5% { stroke-dashoffset: END_VALUE; transform: rotate(90deg); }\n 87.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(341.5deg); }\n 100% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(341.5deg); }\n }\n".replace(/START_VALUE/g,"".concat(.95*this._strokeCircumference)).replace(/END_VALUE/g,"".concat(.2*this._strokeCircumference)).replace(/DIAMETER/g,"".concat(this.diameter))}},{key:"diameter",get:function(){return this._diameter},set:function(t){this._diameter=im(t),!this._fallbackAnimation&&this._styleRoot&&this._attachStyleNode()}},{key:"strokeWidth",get:function(){return this._strokeWidth||this.diameter/10},set:function(t){this._strokeWidth=im(t)}},{key:"value",get:function(){return"determinate"===this.mode?this._value:0},set:function(t){this._value=Math.max(0,Math.min(100,im(t)))}},{key:"_circleRadius",get:function(){return(this.diameter-10)/2}},{key:"_viewBox",get:function(){var t=2*this._circleRadius+this.strokeWidth;return"0 0 ".concat(t," ").concat(t)}},{key:"_strokeCircumference",get:function(){return 2*Math.PI*this._circleRadius}},{key:"_strokeDashOffset",get:function(){return"determinate"===this.mode?this._strokeCircumference*(100-this._value)/100:this._fallbackAnimation&&"indeterminate"===this.mode?.2*this._strokeCircumference:null}},{key:"_circleStrokeWidth",get:function(){return this.strokeWidth/this.diameter*100}}]),n}(cst);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Cm),da(du,8),da(Cy,8),da(lst))},t.\u0275cmp=Ht({type:t,selectors:[["mat-progress-spinner"]],hostAttrs:["role","progressbar",1,"mat-progress-spinner"],hostVars:10,hostBindings:function(t,e){2&t&&(oa("aria-valuemin","determinate"===e.mode?0:null)("aria-valuemax","determinate"===e.mode?100:null)("aria-valuenow","determinate"===e.mode?e.value:null)("mode",e.mode),Za("width",e.diameter,"px")("height",e.diameter,"px"),Qa("_mat-animation-noopable",e._noopAnimations))},inputs:{color:"color",mode:"mode",diameter:"diameter",strokeWidth:"strokeWidth",value:"value"},exportAs:["matProgressSpinner"],features:[ws],decls:3,vars:8,consts:[["preserveAspectRatio","xMidYMid meet","focusable","false",3,"ngSwitch"],["cx","50%","cy","50%",3,"animation-name","stroke-dashoffset","stroke-dasharray","stroke-width",4,"ngSwitchCase"],["cx","50%","cy","50%",3,"stroke-dashoffset","stroke-dasharray","stroke-width",4,"ngSwitchCase"],["cx","50%","cy","50%"]],template:function(t,e){1&t&&(Qe(),ga(0,"svg",0),ua(1,rst,1,9,"circle",1),ua(2,ost,1,7,"circle",2),va()),2&t&&(Za("width",e.diameter,"px")("height",e.diameter,"px"),pa("ngSwitch","indeterminate"===e.mode),oa("viewBox",e._viewBox),Qi(1),pa("ngSwitchCase",!0),Qi(1),pa("ngSwitchCase",!1))},directives:[Rh,Lh],styles:[".mat-progress-spinner{display:block;position:relative}.mat-progress-spinner svg{position:absolute;transform:rotate(-90deg);top:0;left:0;transform-origin:center;overflow:visible}.mat-progress-spinner circle{fill:transparent;transform-origin:center;transition:stroke-dashoffset 225ms linear}._mat-animation-noopable.mat-progress-spinner circle{transition:none;animation:none}.mat-progress-spinner.mat-progress-spinner-indeterminate-animation[mode=indeterminate]{animation:mat-progress-spinner-linear-rotate 2000ms linear infinite}._mat-animation-noopable.mat-progress-spinner.mat-progress-spinner-indeterminate-animation[mode=indeterminate]{transition:none;animation:none}.mat-progress-spinner.mat-progress-spinner-indeterminate-animation[mode=indeterminate] circle{transition-property:stroke;animation-duration:4000ms;animation-timing-function:cubic-bezier(0.35, 0, 0.25, 1);animation-iteration-count:infinite}._mat-animation-noopable.mat-progress-spinner.mat-progress-spinner-indeterminate-animation[mode=indeterminate] circle{transition:none;animation:none}.mat-progress-spinner.mat-progress-spinner-indeterminate-fallback-animation[mode=indeterminate]{animation:mat-progress-spinner-stroke-rotate-fallback 10000ms cubic-bezier(0.87, 0.03, 0.33, 1) infinite}._mat-animation-noopable.mat-progress-spinner.mat-progress-spinner-indeterminate-fallback-animation[mode=indeterminate]{transition:none;animation:none}.mat-progress-spinner.mat-progress-spinner-indeterminate-fallback-animation[mode=indeterminate] circle{transition-property:stroke}._mat-animation-noopable.mat-progress-spinner.mat-progress-spinner-indeterminate-fallback-animation[mode=indeterminate] circle{transition:none;animation:none}@keyframes mat-progress-spinner-linear-rotate{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}@keyframes mat-progress-spinner-stroke-rotate-100{0%{stroke-dashoffset:268.606171575px;transform:rotate(0)}12.5%{stroke-dashoffset:56.5486677px;transform:rotate(0)}12.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(72.5deg)}25%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(72.5deg)}25.0001%{stroke-dashoffset:268.606171575px;transform:rotate(270deg)}37.5%{stroke-dashoffset:56.5486677px;transform:rotate(270deg)}37.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(161.5deg)}50%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(161.5deg)}50.0001%{stroke-dashoffset:268.606171575px;transform:rotate(180deg)}62.5%{stroke-dashoffset:56.5486677px;transform:rotate(180deg)}62.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(251.5deg)}75%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(251.5deg)}75.0001%{stroke-dashoffset:268.606171575px;transform:rotate(90deg)}87.5%{stroke-dashoffset:56.5486677px;transform:rotate(90deg)}87.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(341.5deg)}100%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(341.5deg)}}@keyframes mat-progress-spinner-stroke-rotate-fallback{0%{transform:rotate(0deg)}25%{transform:rotate(1170deg)}50%{transform:rotate(2340deg)}75%{transform:rotate(3510deg)}100%{transform:rotate(4680deg)}}\n"],encapsulation:2,changeDetection:0}),t._diameters=new WeakMap,t}(),hst=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){var s;return Object(m.a)(this,n),(s=e.call(this,t,i,r,o,a)).mode="indeterminate",s}return n}(ust);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Cm),da(du,8),da(Cy,8),da(lst))},t.\u0275cmp=Ht({type:t,selectors:[["mat-spinner"]],hostAttrs:["role","progressbar","mode","indeterminate",1,"mat-spinner","mat-progress-spinner"],hostVars:6,hostBindings:function(t,e){2&t&&(Za("width",e.diameter,"px")("height",e.diameter,"px"),Qa("_mat-animation-noopable",e._noopAnimations))},inputs:{color:"color"},features:[ws],decls:3,vars:8,consts:[["preserveAspectRatio","xMidYMid meet","focusable","false",3,"ngSwitch"],["cx","50%","cy","50%",3,"animation-name","stroke-dashoffset","stroke-dasharray","stroke-width",4,"ngSwitchCase"],["cx","50%","cy","50%",3,"stroke-dashoffset","stroke-dasharray","stroke-width",4,"ngSwitchCase"],["cx","50%","cy","50%"]],template:function(t,e){1&t&&(Qe(),ga(0,"svg",0),ua(1,ast,1,9,"circle",1),ua(2,sst,1,7,"circle",2),va()),2&t&&(Za("width",e.diameter,"px")("height",e.diameter,"px"),pa("ngSwitch","indeterminate"===e.mode),oa("viewBox",e._viewBox),Qi(1),pa("ngSwitchCase",!0),Qi(1),pa("ngSwitchCase",!1))},directives:[Rh,Lh],styles:[".mat-progress-spinner{display:block;position:relative}.mat-progress-spinner svg{position:absolute;transform:rotate(-90deg);top:0;left:0;transform-origin:center;overflow:visible}.mat-progress-spinner circle{fill:transparent;transform-origin:center;transition:stroke-dashoffset 225ms linear}._mat-animation-noopable.mat-progress-spinner circle{transition:none;animation:none}.mat-progress-spinner.mat-progress-spinner-indeterminate-animation[mode=indeterminate]{animation:mat-progress-spinner-linear-rotate 2000ms linear infinite}._mat-animation-noopable.mat-progress-spinner.mat-progress-spinner-indeterminate-animation[mode=indeterminate]{transition:none;animation:none}.mat-progress-spinner.mat-progress-spinner-indeterminate-animation[mode=indeterminate] circle{transition-property:stroke;animation-duration:4000ms;animation-timing-function:cubic-bezier(0.35, 0, 0.25, 1);animation-iteration-count:infinite}._mat-animation-noopable.mat-progress-spinner.mat-progress-spinner-indeterminate-animation[mode=indeterminate] circle{transition:none;animation:none}.mat-progress-spinner.mat-progress-spinner-indeterminate-fallback-animation[mode=indeterminate]{animation:mat-progress-spinner-stroke-rotate-fallback 10000ms cubic-bezier(0.87, 0.03, 0.33, 1) infinite}._mat-animation-noopable.mat-progress-spinner.mat-progress-spinner-indeterminate-fallback-animation[mode=indeterminate]{transition:none;animation:none}.mat-progress-spinner.mat-progress-spinner-indeterminate-fallback-animation[mode=indeterminate] circle{transition-property:stroke}._mat-animation-noopable.mat-progress-spinner.mat-progress-spinner-indeterminate-fallback-animation[mode=indeterminate] circle{transition:none;animation:none}@keyframes mat-progress-spinner-linear-rotate{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}@keyframes mat-progress-spinner-stroke-rotate-100{0%{stroke-dashoffset:268.606171575px;transform:rotate(0)}12.5%{stroke-dashoffset:56.5486677px;transform:rotate(0)}12.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(72.5deg)}25%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(72.5deg)}25.0001%{stroke-dashoffset:268.606171575px;transform:rotate(270deg)}37.5%{stroke-dashoffset:56.5486677px;transform:rotate(270deg)}37.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(161.5deg)}50%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(161.5deg)}50.0001%{stroke-dashoffset:268.606171575px;transform:rotate(180deg)}62.5%{stroke-dashoffset:56.5486677px;transform:rotate(180deg)}62.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(251.5deg)}75%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(251.5deg)}75.0001%{stroke-dashoffset:268.606171575px;transform:rotate(90deg)}87.5%{stroke-dashoffset:56.5486677px;transform:rotate(90deg)}87.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(341.5deg)}100%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(341.5deg)}}@keyframes mat-progress-spinner-stroke-rotate-fallback{0%{transform:rotate(0deg)}25%{transform:rotate(1170deg)}50%{transform:rotate(2340deg)}75%{transform:rotate(3510deg)}100%{transform:rotate(4680deg)}}\n"],encapsulation:2,changeDetection:0}),t}(),dst=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[$$,hd],$$]}),t}();function fst(t,e){1&t&&(ga(0,"div",4),ba(1,"mat-spinner",5),va())}function pst(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"div",7),ga(2,"mat-icon"),ds(3,"error_outline"),va(),va(),ga(4,"div"),ds(5),va(),ga(6,"div"),ga(7,"button",8),xa("click",(function(){return Se(n),Aa(2).refresh()})),ga(8,"mat-icon"),ds(9,"refresh"),va(),va(),ga(10,"button",9),ga(11,"mat-icon"),ds(12,"home"),va(),va(),va(),va()}if(2&t){var i=Aa(2);Qi(5),ps("Error occurred: ",i.error.message,"")}}function mst(t,e){if(1&t&&(ga(0,"div",1),ua(1,fst,2,0,"div",2),ua(2,pst,13,1,"div",3),va()),2&t){var n=Aa();Qi(1),pa("ngIf",n.visible&&!n.error),Qi(1),pa("ngIf",n.error)}}var gst=function(){function t(t,e){this.progressService=t,this.router=e,this.visible=!1}return t.prototype.ngOnInit=function(){var t=this;this.progressService.state.subscribe((function(e){t.visible=e.visible,e.error&&!t.error&&(t.error=e.error),e.clear&&(t.error=null)})),this.routerSubscription=this.router.events.subscribe((function(){t.progressService.clear()}))},t.prototype.refresh=function(){this.router.navigateByUrl(this.router.url)},t.prototype.ngOnDestroy=function(){this.routerSubscription.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(yet),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-progress"]],decls:1,vars:1,consts:[["class","overlay",4,"ngIf"],[1,"overlay"],["class","loading-spinner",4,"ngIf"],["class","error-state",4,"ngIf"],[1,"loading-spinner"],["color","primary"],[1,"error-state"],[1,"error-icon"],["mat-button","","matTooltip","Refresh page","matTooltipClass","custom-tooltip",3,"click"],["mat-button","","routerLink","/","matTooltip","Go to home","matTooltipClass","custom-tooltip"]],template:function(t,e){1&t&&ua(0,mst,3,2,"div",0),2&t&&pa("ngIf",e.visible||e.error)},directives:[Ah,hst,x2,a2,k4,hQ],styles:[".overlay[_ngcontent-%COMP%]{position:fixed;width:100%;height:100%;top:0;left:0;right:0;bottom:0;background-color:rgba(0,0,0,.5);z-index:2000}.error-state[_ngcontent-%COMP%], .loading-spinner[_ngcontent-%COMP%]{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%)}.error-state[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{text-align:center}.error-icon[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:64px;width:64px;height:64px}"]}),t}(),vst=function(){function t(t,e,n){this.drawingService=t,this.drawingsDataSource=e,this.drawingsEventSource=n}return t.prototype.ngOnInit=function(){var t=this;this.drawingDragged=this.drawingsEventSource.dragged.subscribe((function(e){return t.onDrawingDragged(e)}))},t.prototype.onDrawingDragged=function(t){var e=this,n=this.drawingsDataSource.get(t.datum.id);n.x+=t.dx,n.y+=t.dy,this.drawingService.updatePosition(this.server,this.project,n,n.x,n.y).subscribe((function(t){e.drawingsDataSource.update(t)}))},t.prototype.ngOnDestroy=function(){this.drawingDragged.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(x9),da(E9),da(Jnt))},t.\u0275cmp=Ht({type:t,selectors:[["app-drawing-dragged"]],inputs:{server:"server",project:"project"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),bst=function(){function t(t,e,n,i){this.drawingService=t,this.drawingsDataSource=e,this.drawingsEventSource=n,this.mapDrawingToSvgConverter=i}return t.prototype.ngOnInit=function(){var t=this;this.drawingResized=this.drawingsEventSource.resized.subscribe((function(e){return t.onDrawingResized(e)}))},t.prototype.onDrawingResized=function(t){var e=this,n=this.drawingsDataSource.get(t.datum.id),i=this.mapDrawingToSvgConverter.convert(t.datum);this.drawingService.updateSizeAndPosition(this.server,n,t.x,t.y,i).subscribe((function(t){e.drawingsDataSource.update(t)}))},t.prototype.ngOnDestroy=function(){this.drawingResized.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(x9),da(E9),da(Jnt),da(R9))},t.\u0275cmp=Ht({type:t,selectors:[["app-drawing-resized"]],inputs:{server:"server"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),yst=function(){function t(t,e,n){this.linkService=t,this.linksDataSource=e,this.linksEventSource=n}return t.prototype.ngOnInit=function(){var t=this;this.interfaceDragged=this.linksEventSource.interfaceDragged.subscribe((function(e){return t.onInterfaceLabelDragged(e)}))},t.prototype.onInterfaceLabelDragged=function(t){var e=this,n=this.linksDataSource.get(t.datum.linkId);n.nodes[0].node_id===t.datum.nodeId&&(n.nodes[0].label.x+=t.dx,n.nodes[0].label.y+=t.dy),n.nodes[1].node_id===t.datum.nodeId&&(n.nodes[1].label.x+=t.dx,n.nodes[1].label.y+=t.dy),this.linkService.updateNodes(this.server,n,n.nodes).subscribe((function(t){e.linksDataSource.update(t)}))},t.prototype.ngOnDestroy=function(){this.interfaceDragged.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(q9),da(G9),da(dit))},t.\u0275cmp=Ht({type:t,selectors:[["app-interface-label-dragged"]],inputs:{server:"server"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),_st=function(){function t(t,e,n,i,r,o){this.projectService=t,this.linkService=e,this.linksDataSource=n,this.linksEventSource=i,this.mapNodeToNode=r,this.mapPortToPort=o}return t.prototype.ngOnInit=function(){var t=this;this.linkCreated=this.linksEventSource.created.subscribe((function(e){return t.onLinkCreated(e)}))},t.prototype.onLinkCreated=function(t){var e=this,n=Math.abs(t.sourceNode.x-t.targetNode.x),i=Math.abs(t.sourceNode.y-t.targetNode.y),r=Math.sqrt(Math.pow(n,2)+Math.pow(i,2)),o=i/r,a=45/r*n,s=45/r*i,c=0,l=0,u=0,h=0;t.sourceNode.x<=t.targetNode.x&&t.sourceNode.y<=t.targetNode.y?(c=Math.floor(t.sourceNode.width/2)+Math.round(a)+5,l=Math.floor(t.sourceNode.height/2)+Math.round(s)+5,u=Math.floor(t.targetNode.width/2)-Math.round(a)-5-Math.round(20*o),h=Math.floor(t.targetNode.height/2)-Math.round(s)+5-Math.round(20*o)):t.sourceNode.x>t.targetNode.x&&t.sourceNode.y<t.targetNode.y?(c=Math.floor(t.sourceNode.width/2)-Math.round(a)-5-Math.round(20*o),l=Math.floor(t.sourceNode.height/2)+Math.round(s)+5-Math.round(20*o),u=Math.floor(t.targetNode.width/2)+Math.round(a)+5,h=Math.floor(t.targetNode.height/2)-Math.round(s)-5):t.sourceNode.x<t.targetNode.x&&t.sourceNode.y>t.targetNode.y?(c=Math.floor(t.sourceNode.width/2)+Math.round(a)+5-Math.round(20*o),l=Math.floor(t.sourceNode.height/2)-Math.round(s)-5-Math.round(20*o),u=Math.floor(t.targetNode.width/2)-Math.round(a)-5,h=Math.floor(t.targetNode.height/2)+Math.round(s)+5):t.sourceNode.x>=t.targetNode.x&&t.sourceNode.y>=t.targetNode.y&&(c=Math.floor(t.sourceNode.width/2)-Math.round(a)-5-Math.round(20*o),l=Math.floor(t.sourceNode.height/2)-Math.round(s)+5-Math.round(20*o),u=Math.floor(t.targetNode.width/2)+Math.round(a)+5,h=Math.floor(t.targetNode.height/2)+Math.round(s)+5);var d=this.mapNodeToNode.convert(t.sourceNode),f=this.mapPortToPort.convert(t.sourcePort),p=this.mapNodeToNode.convert(t.targetNode),m=this.mapPortToPort.convert(t.targetPort);this.linkService.createLink(this.server,d,f,p,m,c,l,u,h).subscribe((function(){e.projectService.links(e.server,e.project.project_id).subscribe((function(t){e.linksDataSource.set(t)}))}))},t.prototype.ngOnDestroy=function(){this.linkCreated.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da($Q),da(q9),da(G9),da(dit),da(jnt),da(Ant))},t.\u0275cmp=Ht({type:t,selectors:[["app-link-created"]],inputs:{server:"server",project:"project"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),wst=function(){function t(t,e,n){this.nodesDataSource=t,this.nodeService=e,this.nodesEventSource=n}return t.prototype.ngOnInit=function(){var t=this;this.nodeDragged=this.nodesEventSource.dragged.subscribe((function(e){return t.onNodeDragged(e)}))},t.prototype.onNodeDragged=function(t){var e=this,n=this.nodesDataSource.get(t.datum.id);n.x+=t.dx,n.y+=t.dy,this.nodeService.updatePosition(this.server,this.project,n,n.x,n.y).subscribe((function(t){e.nodesDataSource.update(t)}))},t.prototype.ngOnDestroy=function(){this.nodeDragged.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E2),da(pnt))},t.\u0275cmp=Ht({type:t,selectors:[["app-node-dragged"]],inputs:{server:"server",project:"project"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),kst=function(){function t(t,e,n,i){this.nodesDataSource=t,this.nodeService=e,this.nodesEventSource=n,this.mapLabelToLabel=i}return t.prototype.ngOnInit=function(){var t=this;this.nodeLabelDragged=this.nodesEventSource.labelDragged.subscribe((function(e){return t.onNodeLabelDragged(e)}))},t.prototype.onNodeLabelDragged=function(t){var e=this,n=this.nodesDataSource.get(t.datum.nodeId),i=t.datum;i.x+=t.dx,i.y+=t.dy;var r=this.mapLabelToLabel.convert(i);n.label=r,this.nodeService.updateLabel(this.server,n,n.label).subscribe((function(t){e.nodesDataSource.update(t)}))},t.prototype.ngOnDestroy=function(){this.nodeLabelDragged.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(M9),da(E2),da(pnt),da(Ent))},t.\u0275cmp=Ht({type:t,selectors:[["app-node-label-dragged"]],inputs:{server:"server"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),Cst=function(){function t(t,e,n,i,r,o){this.drawingService=t,this.drawingsDataSource=e,this.drawingsEventSource=n,this.drawingsFactory=i,this.mapDrawingToSvgConverter=r,this.context=o,this.drawingSaved=new Uc}return t.prototype.ngOnInit=function(){var t=this;this.textAdded=this.drawingsEventSource.textAdded.subscribe((function(e){return t.onTextAdded(e)}))},t.prototype.onTextAdded=function(t){var e=this,n=this.drawingsFactory.getDrawingMock("text");n.element.text=t.savedText;var i=this.mapDrawingToSvgConverter.convert(n);this.drawingService.add(this.server,this.project.project_id,(t.x-(this.context.getZeroZeroTransformationPoint().x+this.context.transformation.x))/this.context.transformation.k,(t.y-(this.context.getZeroZeroTransformationPoint().y+this.context.transformation.y))/this.context.transformation.k,i).subscribe((function(t){e.drawingsDataSource.add(t),e.drawingSaved.emit(!0)}))},t.prototype.ngOnDestroy=function(){this.textAdded.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(x9),da(E9),da(Jnt),da($it),da(R9),da(Ont))},t.\u0275cmp=Ht({type:t,selectors:[["app-text-added"]],inputs:{server:"server",project:"project"},outputs:{drawingSaved:"drawingSaved"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),Sst=function(){function t(t,e,n,i){this.drawingService=t,this.drawingsDataSource=e,this.drawingsEventSource=n,this.mapDrawingToSvgConverter=i}return t.prototype.ngOnInit=function(){var t=this;this.textEdited=this.drawingsEventSource.textEdited.subscribe((function(e){return t.onTextEdited(e)}))},t.prototype.onTextEdited=function(t){var e=this,n=new I9;n.element=t.textElement,n.element.text=t.editedText;var i=this.mapDrawingToSvgConverter.convert(n),r=this.drawingsDataSource.get(t.textDrawingId);this.drawingService.updateText(this.server,r,i).subscribe((function(t){e.drawingsDataSource.update(t),e.drawingsEventSource.textSaved.emit(!0)}))},t.prototype.ngOnDestroy=function(){this.textEdited.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(x9),da(E9),da(Jnt),da(R9))},t.\u0275cmp=Ht({type:t,selectors:[["app-text-edited"]],inputs:{server:"server"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),xst=["app-selection",""];function Ost(t,e){1&t&&(Qe(),ba(0,"path",2)),2&t&&oa("d",Aa().d)}var Mst=function(){function t(t){this.ref=t,this.started=!1,this.visible=!1,this.rectangleSelected=new Uc}return t.prototype.ngOnInit=function(){},t.prototype.ngAfterViewInit=function(){var t=this,e=k.a.fromEvent(this.svg,"mousedown").do((function(t){return t.preventDefault()}));e.subscribe((function(e){e.target===t.svg&&(t.started=!0,t.startX=e.clientX+window.scrollX,t.startY=e.clientY+window.scrollY,t.width=0,t.height=0,t.visible=!0,t.ref.detectChanges())}));var n=k.a.fromEvent(document,"mouseup").do((function(t){t.preventDefault()})),i=k.a.fromEvent(document,"mousemove").do((function(t){return t.stopPropagation()})),r=k.a.fromEvent(document,"scroll").startWith({}),o=k.a.combineLatest(i,r),a=e.mergeMap((function(e){return o.map((function(t){return t[0]})).do((function(e){t.started&&(t.visible=!0,t.width=e.clientX-t.startX+window.scrollX,t.height=e.clientY-t.startY+window.scrollY,t.ref.detectChanges(),t.selectedEvent([t.startX,t.startY],[t.width,t.height]))})).skipUntil(n.take(1).do((function(e){t.started&&(t.visible=!1,t.started=!1,t.width=e.clientX-t.startX+window.scrollX,t.height=e.clientY-t.startY+window.scrollY,t.ref.detectChanges(),t.selectedEvent([t.startX,t.startY],[t.width,t.height]))}))).take(1)}));this.draggable=a.subscribe((function(t){}))},t.prototype.ngOnDestroy=function(){this.draggable.unsubscribe()},Object.defineProperty(t.prototype,"d",{get:function(){return this.rect(this.startX,this.startY,this.width,this.height)},enumerable:!1,configurable:!0}),t.prototype.rect=function(t,e,n,i){return"M"+[t,e]+" l"+[n,0]+" l"+[0,i]+" l"+[-n,0]+"z"},t.prototype.selectedEvent=function(t,e){var n=Math.min(t[0],e[0]),i=Math.min(t[1],e[1]),r=Math.abs(t[0]-e[0]),o=Math.abs(t[1]-e[1]);this.rectangleSelected.emit(new Lnt(n,i,r,o))},t.\u0275fac=function(e){return new(e||t)(da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["","app-selection",""]],inputs:{svg:["app-selection","svg"]},outputs:{rectangleSelected:"selected"},attrs:xst,decls:2,vars:1,consts:[[1,"selection-line-tool"],["class","selection",4,"ngIf"],[1,"selection"]],template:function(t,e){1&t&&(Qe(),ga(0,"g",0),ua(1,Ost,1,1,"path",1),va()),2&t&&(Qi(1),pa("ngIf",e.visible))},directives:[Ah],styles:[""]}),t}(),Tst=function(){function t(){}return t.prototype.d=function(t){var e=[[t.source.x+t.source.width/2,t.source.y+t.source.height/2],[t.target.x+t.target.width/2,t.target.y+t.target.height/2]],n=QS();return n.moveTo(e[0][0],e[0][1]),n.lineTo(e[1][0],e[1][1]),n.toString()},t}(),Est=function(){function t(){}return t.prototype.linkToPoints=function(t){var e={x:t.source.x+t.source.width/2,y:t.source.y+t.source.height/2},n={x:t.target.x+t.target.width/2,y:t.target.y+t.target.height/2},i=n.x-e.x,r=n.y-e.y,o=Math.atan2(r,i),a=-Math.PI/4,s=[Math.cos(o+a),Math.sin(o+a)];return[[e.x,e.y],[e.x+i/2+15*s[0],e.y+r/2+15*s[1]],[n.x-i/2-15*s[0],n.y-r/2-15*s[1]],[n.x,n.y]]},t.prototype.d=function(t){var e=this.linkToPoints(t),n=QS();return n.moveTo(e[0][0],e[0][1]),n.lineTo(e[1][0],e[1][1]),n.lineTo(e[2][0],e[2][1]),n.lineTo(e[3][0],e[3][1]),n.toString()},t}(),Pst=["app-status",""];function Ast(t,e){if(1&t&&(Qe(),ba(0,"circle",3)),2&t){var n=Aa(2);oa("cx",n.point.x)("cy",n.point.y)}}function jst(t,e){if(1&t&&(Qe(),ba(0,"rect",4)),2&t){var n=Aa(2);oa("x",n.point.x-5)("y",n.point.y-5)}}function Ist(t,e){if(1&t&&(Qe(),ga(0,"g"),ua(1,Ast,1,2,"circle",1),ua(2,jst,1,2,"rect",2),va()),2&t){var n=Aa();Qi(1),pa("ngIf","started"==n.status),Qi(1),pa("ngIf","stopped"==n.status)}}var Dst=function(){function t(t,e){this.element=t,this.ref=e,this.data={status:"",path:null,direction:null,d:null}}return Object.defineProperty(t.prototype,"status",{get:function(){return this.data.status},set:function(t){this.data.status=t,this.ref.markForCheck()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"path",{get:function(){return this.data.path},set:function(t){this.data.path=t,this.ref.markForCheck()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"direction",{get:function(){return this.data.direction},set:function(t){this.data.direction=t,this.ref.markForCheck()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"d",{set:function(t){this.data.d!==t&&(this.data.d=t,this.ref.markForCheck())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"sourceStatusPoint",{get:function(){return this.path?this.path.nativeElement.getPointAtLength(45):null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"targetStatusPoint",{get:function(){return this.path?this.path.nativeElement.getPointAtLength(this.path.nativeElement.getTotalLength()-45):null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"point",{get:function(){return"source"===this.direction?this.sourceStatusPoint:this.targetStatusPoint},enumerable:!1,configurable:!0}),t.STOPPED_STATUS_RECT_WIDTH=10,t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["","app-status",""]],inputs:{status:["app-status","status"],path:"path",direction:"direction",d:"d"},attrs:Pst,decls:1,vars:1,consts:[[4,"ngIf"],["class","status_started","r","6","fill","#2ecc71",4,"ngIf"],["class","status_stopped","width","10","height","10","r","6","fill","red",4,"ngIf"],["r","6","fill","#2ecc71",1,"status_started"],["width","10","height","10","r","6","fill","red",1,"status_stopped"]],template:function(t,e){1&t&&ua(0,Ist,3,2,"g",0),2&t&&pa("ngIf",e.status&&e.point&&e.direction)},directives:[Ah],styles:[""]}),t}(),Rst=["textSvg"],Lst=["app-interface-label",""],Fst=function(){function t(t,e,n,i){this.elementRef=t,this.ref=e,this.sanitizer=n,this.cssFixer=i,this.label={x:0,y:0,text:"",style:"",rotation:0},this.borderSize=5,this.textWidth=0,this.textHeight=0}return t.prototype.ngOnInit=function(){},Object.defineProperty(t.prototype,"x",{set:function(t){this.label.x=t,this.ref.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"y",{set:function(t){this.label.y=t,this.ref.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"text",{get:function(){return this.label.text},set:function(t){this.label.text=t,this.ref.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"style",{set:function(t){this.label.style=this.cssFixer.fix(t),this.ref.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rotation",{set:function(t){this.label.rotation=t,this.ref.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"sanitizedStyle",{get:function(){return this.sanitizer.bypassSecurityTrustStyle(this.label.style)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rectX",{get:function(){return 0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rectY",{get:function(){return-this.textRef.nativeElement.getBBox().height-this.borderSize},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rectWidth",{get:function(){return this.textRef.nativeElement.getBBox().width+2*this.borderSize},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rectHeight",{get:function(){return this.textRef.nativeElement.getBBox().height+this.borderSize},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"transform",{get:function(){var t=this.elementRef.nativeElement.getBBox(),e=this.label.x,n=this.label.y+t.height;return"translate("+e+", "+n+") rotate("+this.label.rotation+", "+e+", "+n+")"},enumerable:!1,configurable:!0}),t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(Vd),da(Oet))},t.\u0275cmp=Ht({type:t,selectors:[["","app-interface-label",""]],viewQuery:function(t,e){var n;1&t&&nl(Rst,!0),2&t&&tl(n=sl())&&(e.textRef=n.first)},inputs:{ignore:["app-interface-label","ignore"],x:"x",y:"y",text:"text",style:"style",rotation:"rotation"},attrs:Lst,decls:5,vars:9,consts:[["width","100","height","100",1,"text_container"],["stroke-dasharray","3,3","stroke-width","0.5","fill","none","stroke","black"],[1,"interface_label"],["textSvg",""]],template:function(t,e){1&t&&(Qe(),ga(0,"g",0),ba(1,"rect",1),ga(2,"text",2,3),ds(4),va(),va()),2&t&&(oa("transform",e.transform),Qi(1),oa("x",e.rectX)("y",e.rectY)("width",e.rectWidth)("height",e.rectHeight),Qi(1),oa("style",e.sanitizedStyle,Ei)("x",e.borderSize)("y",0-e.borderSize),Qi(2),ps(" ",e.text," "))},styles:[""]}),t}(),Nst=["path"],Bst=["app-link",""];function Hst(t,e){1&t&&(Qe(),ba(0,"path",5,6)),2&t&&oa("d",Aa().d)}function zst(t,e){1&t&&(Qe(),ba(0,"path",7,6)),2&t&&oa("d",Aa().d)}function Vst(t,e){if(1&t&&(Qe(),ba(0,"g",8)),2&t){var n=Aa();$a(n.link.nodes[0].label.style),pa("x",n.link.source.x+n.link.nodes[0].label.x)("y",n.link.source.y+n.link.nodes[0].label.y)("text",n.link.nodes[0].label.text)("rotation",n.link.nodes[0].label.rotation)}}function Ust(t,e){if(1&t&&(Qe(),ba(0,"g",8)),2&t){var n=Aa();$a(n.link.nodes[1].label.style),pa("x",n.link.target.x+n.link.nodes[1].label.x)("y",n.link.target.y+n.link.nodes[1].label.y)("text",n.link.nodes[1].label.text)("rotation",n.link.nodes[1].label.rotation)}}var qst=function(){function t(t,e){this.multiLinkCalculatorHelper=t,this.ref=e,this.ethernetLinkStrategy=new Tst,this.serialLinkStrategy=new Est}return t.prototype.ngOnInit=function(){this.ref.detectChanges()},t.prototype.ngOnDestroy=function(){},Object.defineProperty(t.prototype,"strategy",{get:function(){return"serial"===this.link.linkType?this.serialLinkStrategy:this.ethernetLinkStrategy},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"transform",{get:function(){var t=this.multiLinkCalculatorHelper.linkTranslation(this.link.distance,this.link.source,this.link.target);return"translate ("+t.dx+", "+t.dy+")"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"d",{get:function(){return this.strategy.d(this.link)},enumerable:!1,configurable:!0}),t.\u0275fac=function(e){return new(e||t)(da(Xet),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["","app-link",""]],viewQuery:function(t,e){var n;1&t&&nl(Nst,!0),2&t&&tl(n=sl())&&(e.path=n.first)},inputs:{link:["app-link","link"],nodeChanged:["node-changed","nodeChanged"],showInterfaceLabels:["show-interface-labels","showInterfaceLabels"]},attrs:Bst,decls:7,vars:16,consts:[[1,"link"],["class","ethernet_link","stroke","#000","stroke-width","2",4,"ngIf"],["class","serial_link","stroke","#B22222","fill","none","stroke-width","2",4,"ngIf"],[3,"app-status","direction","path","d"],[3,"app-interface-label","x","y","text","style","rotation",4,"ngIf"],["stroke","#000","stroke-width","2",1,"ethernet_link"],["path",""],["stroke","#B22222","fill","none","stroke-width","2",1,"serial_link"],[3,"app-interface-label","x","y","text","rotation"]],template:function(t,e){1&t&&(Qe(),ga(0,"g",0),ua(1,Hst,2,1,"path",1),ua(2,zst,2,1,"path",2),ba(3,"g",3),ba(4,"g",3),ua(5,Vst,1,6,"g",4),ua(6,Ust,1,6,"g",4),va()),2&t&&(oa("link_id",e.link.id)("map-source",e.link.source.id)("map-target",e.link.target.id)("transform",e.transform),Qi(1),pa("ngIf","ethernet"==e.link.linkType),Qi(1),pa("ngIf","serial"==e.link.linkType),Qi(1),pa("app-status",e.link.source.status)("direction","source")("path",e.path)("d",e.d),Qi(1),pa("app-status",e.link.target.status)("direction","target")("path",e.path)("d",e.d),Qi(1),pa("ngIf",e.showInterfaceLabels),Qi(1),pa("ngIf",e.showInterfaceLabels))},directives:[Ah,Dst,Fst],styles:[""]}),t}(),Gst=["app-draggable",""],Wst=["*"],Kst=function(){return function(t,e,n,i){this.x=t,this.y=e,this.dx=n,this.dy=i}}(),Xst=function(){function t(t){this.elementRef=t,this.dragging=new Uc,this.dragged=new Uc}return t.prototype.ngOnInit=function(){},t.prototype.ngAfterViewInit=function(){var t=this,e=k.a.fromEvent(this.elementRef.nativeElement,"mousedown").do((function(t){return t.preventDefault()}));e.subscribe((function(e){t.posX=t.item.x,t.posY=t.item.y,t.startX=e.clientX,t.startY=e.clientY}));var n=k.a.fromEvent(document,"mouseup").do((function(t){t.preventDefault()})),i=k.a.fromEvent(document,"mousemove").do((function(t){return t.stopPropagation()})),r=k.a.fromEvent(document,"scroll").startWith({}),o=k.a.combineLatest(i,r),a=e.mergeMap((function(e){return o.map((function(t){return t[0]})).do((function(e){var n=t.startX-e.clientX,i=t.startY-e.clientY;t.item.x=Math.round(t.posX-n),t.item.y=Math.round(t.posY-i),t.dragging.emit(new Kst(t.item.x,t.item.y,-n,-i))})).skipUntil(n.take(1).do((function(e){var n=t.startX-e.clientX,i=t.startY-e.clientY;t.item.x=Math.round(t.posX-n),t.item.y=Math.round(t.posY-i),t.dragged.emit(new Kst(t.item.x,t.item.y,-n,-i))}))).take(1)}));this.draggable=a.subscribe((function(t){}))},t.prototype.ngOnDestroy=function(){this.draggable.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275cmp=Ht({type:t,selectors:[["","app-draggable",""]],inputs:{item:["app-draggable","item"]},outputs:{dragging:"dragging",dragged:"dragged"},attrs:Gst,ngContentSelectors:Wst,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),Da(0))},styles:[""]}),t}(),Yst=["label"],Zst=["image"],Qst=["app-node",""],$st=function(){function t(t,e,n,i,r,o){this.cssFixer=t,this.fontFixer=e,this.sanitizer=n,this.element=i,this.cd=r,this.nodesEventSource=o,this.labelHeight=0}return t.prototype.ngOnInit=function(){},t.prototype.ngOnDestroy=function(){},t.prototype.ngOnChanges=function(t){this.cd.detectChanges()},t.prototype.ngAfterViewInit=function(){this.labelHeight=this.getLabelHeight(),this.cd.detectChanges()},t.prototype.OnDragging=function(t){this.node.x=t.x,this.node.y=t.y,this.cd.detectChanges()},t.prototype.OnDragged=function(t){this.cd.detectChanges(),this.nodesEventSource.dragged.emit(new int(this.node,t.dx,t.dy))},Object.defineProperty(t.prototype,"symbol",{get:function(){var t=this,e=this.symbols.find((function(e){return e.symbol_id===t.node.symbol}));return e?"data:image/svg+xml;base64,"+btoa(e.raw):"data:image/svg+xml;base64,none"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"label_style",{get:function(){var t=this.cssFixer.fix(this.node.label.style);return t=this.fontFixer.fixStyles(t),this.sanitizer.bypassSecurityTrustStyle(t)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"label_x",{get:function(){return null===this.node.label.x?-this.label.nativeElement.getBBox().width/2:this.node.label.x+t.NODE_LABEL_MARGIN},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"label_y",{get:function(){return this.labelHeight=this.getLabelHeight(),null===this.node.label.x?-this.node.height/2-this.labelHeight:this.node.label.y+this.labelHeight-t.NODE_LABEL_MARGIN},enumerable:!1,configurable:!0}),t.prototype.getLabelHeight=function(){return this.label.nativeElement.getBBox().height},t.NODE_LABEL_MARGIN=3,t.\u0275fac=function(e){return new(e||t)(da(Oet),da(X9),da(Vd),da(Us),da(Po),da(pnt))},t.\u0275cmp=Ht({type:t,selectors:[["","app-node",""]],viewQuery:function(t,e){var n;1&t&&(nl(Yst,!0),nl(Zst,!0)),2&t&&(tl(n=sl())&&(e.label=n.first),tl(n=sl())&&(e.imageRef=n.first))},inputs:{node:["app-node","node"],symbols:"symbols",nodeChanged:["node-changed","nodeChanged"]},features:[Ms],attrs:Qst,decls:6,vars:11,consts:[[1,"node"],[3,"app-draggable","dragging","dragged"],["image",""],[1,"label"],["label",""]],template:function(t,e){1&t&&(Qe(),ga(0,"g",0),ga(1,"image",1,2),xa("dragging",(function(t){return e.OnDragging(t)}))("dragged",(function(t){return e.OnDragged(t)})),va(),ga(3,"text",3,4),ds(5),va(),va()),2&t&&(oa("transform","translate("+e.node.x+","+e.node.y+")"),Qi(1),pa("app-draggable",e.node),oa("width",e.node.width)("height",e.node.height)("x",0)("y",0)("href",e.symbol,null,"xlink"),Qi(2),oa("style",e.label_style,Ei)("x",e.label_x)("y",e.label_y),Qi(2),ps(" ",e.node.label.text," "))},directives:[Xst],styles:[""],changeDetection:0}),t}(),Jst=["app-ellipse",""],tct=function(){function t(t){this.qtDasharrayFixer=t}return t.prototype.ngOnInit=function(){},Object.defineProperty(t.prototype,"fill_opacity",{get:function(){return isFinite(this.ellipse.fill_opacity)?this.ellipse.fill_opacity:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"stroke_width",{get:function(){return isFinite(this.ellipse.stroke_width)?this.ellipse.stroke_width:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"stroke_dasharray",{get:function(){return this.ellipse.stroke_dasharray?this.qtDasharrayFixer.fix(this.ellipse.stroke_dasharray):null},enumerable:!1,configurable:!0}),t.\u0275fac=function(e){return new(e||t)(da(bnt))},t.\u0275cmp=Ht({type:t,selectors:[["","app-ellipse",""]],inputs:{ellipse:["app-ellipse","ellipse"]},attrs:Jst,decls:1,vars:9,consts:[[1,"ellipse_element","noselect"]],template:function(t,e){1&t&&(Qe(),ba(0,"ellipse",0)),2&t&&oa("fill",e.ellipse.fill)("fill-opacity",e.fill_opacity)("stroke",e.ellipse.stroke)("stroke-width",e.stroke_width)("stroke-dasharray",e.stroke_dasharray)("cx",e.ellipse.cx)("cy",e.ellipse.cy)("rx",e.ellipse.rx)("ry",e.ellipse.ry)},styles:[""]}),t}(),ect=["app-image",""],nct=function(){function t(){}return t.prototype.ngOnInit=function(){},t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["","app-image",""]],inputs:{image:["app-image","image"]},attrs:ect,decls:1,vars:3,consts:[[1,"image_element","noselect"]],template:function(t,e){1&t&&(Qe(),ba(0,"image",0)),2&t&&oa("href",e.image.data,null,"xlink")("width",e.image.width)("height",e.image.height)},styles:[""]}),t}(),ict=["app-line",""],rct=function(){function t(t){this.qtDasharrayFixer=t}return t.prototype.ngOnInit=function(){},Object.defineProperty(t.prototype,"stroke_width",{get:function(){return isFinite(this.line.stroke_width)?this.line.stroke_width:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"stroke_dasharray",{get:function(){return this.line.stroke_dasharray?this.qtDasharrayFixer.fix(this.line.stroke_dasharray):null},enumerable:!1,configurable:!0}),t.\u0275fac=function(e){return new(e||t)(da(bnt))},t.\u0275cmp=Ht({type:t,selectors:[["","app-line",""]],inputs:{line:["app-line","line"]},attrs:ict,decls:1,vars:7,consts:[[1,"line_element","noselect"]],template:function(t,e){1&t&&(Qe(),ba(0,"line",0)),2&t&&oa("stroke",e.line.stroke)("stroke-width",e.stroke_width)("stroke-dasharray",e.stroke_dasharray)("x1",e.line.x1)("x2",e.line.x2)("y1",e.line.y1)("y2",e.line.y2)},styles:[""]}),t}(),oct=["app-rect",""],act=function(){function t(t){this.qtDasharrayFixer=t}return t.prototype.ngOnInit=function(){},Object.defineProperty(t.prototype,"fill_opacity",{get:function(){return isFinite(this.rect.fill_opacity)?this.rect.fill_opacity:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"stroke_width",{get:function(){return isFinite(this.rect.stroke_width)?this.rect.stroke_width:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"stroke_dasharray",{get:function(){return this.rect.stroke_dasharray?this.qtDasharrayFixer.fix(this.rect.stroke_dasharray):null},enumerable:!1,configurable:!0}),t.\u0275fac=function(e){return new(e||t)(da(bnt))},t.\u0275cmp=Ht({type:t,selectors:[["","app-rect",""]],inputs:{rect:["app-rect","rect"]},attrs:oct,decls:1,vars:7,consts:[[1,"rect_element","noselect"]],template:function(t,e){1&t&&(Qe(),ba(0,"rect",0)),2&t&&oa("fill",e.rect.fill)("fill-opacity",e.fill_opacity)("stroke",e.rect.stroke)("stroke-width",e.stroke_width)("stroke-dasharray",e.stroke_dasharray)("width",e.rect.width)("height",e.rect.height)},styles:[""]}),t}(),sct=["text"],cct=["app-text",""];function lct(t,e){if(1&t&&(Qe(),ga(0,"tspan",3),ds(1),va()),2&t){var n=e.$implicit;oa("dy",0==e.index?"0em":"1.4em"),Qi(1),ps(" ",n," ")}}var uct=function(){function t(t,e){this.fontFixer=t,this.sanitizer=e,this.lines=[],this.transformation=""}return t.prototype.ngOnInit=function(){this.lines=this.getLines(this.text.text)},t.prototype.ngDoCheck=function(){this.transformation=this.calculateTransformation()},Object.defineProperty(t.prototype,"style",{get:function(){var t=this.fontFixer.fix(this.text),e=[];return t.font_family&&e.push('font-family: "'+this.text.font_family+'"'),t.font_size&&e.push("font-size: "+this.text.font_size+"pt"),t.font_weight&&e.push("font-weight: "+this.text.font_weight),this.sanitizer.bypassSecurityTrustStyle(e.join("; "))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"textDecoration",{get:function(){return this.text.text_decoration},enumerable:!1,configurable:!0}),t.prototype.calculateTransformation=function(){var e=this.textRef.nativeElement.getElementsByTagName("tspan");if(e.length>0){var n=this.textRef.nativeElement.getBBox().height/e.length;return"translate("+t.MARGIN+", "+(n-t.MARGIN)+")"}return""},t.prototype.getLines=function(t){return t.split(/\r?\n/)},t.MARGIN=4,t.\u0275fac=function(e){return new(e||t)(da(X9),da(Vd))},t.\u0275cmp=Ht({type:t,selectors:[["","app-text",""]],viewQuery:function(t,e){var n;1&t&&nl(sct,!0),2&t&&tl(n=sl())&&(e.textRef=n.first)},inputs:{text:["app-text","text"]},attrs:cct,decls:3,vars:5,consts:[[1,"text_element","noselect"],["text",""],[0,"xml","space","preserve","x","0",4,"ngFor","ngForOf"],[0,"xml","space","preserve","x","0"]],template:function(t,e){if(1&t&&(Qe(),ga(0,"text",0,1),ua(2,lct,2,2,"tspan",2),va()),2&t){var n=ha(1);oa("style",e.style,Ei)("text-decoration",e.textDecoration)("fill",n.fill)("transform",e.transformation),Qi(2),pa("ngForOf",e.lines)}},directives:[Eh],styles:[""]}),t}(),hct=["app-drawing",""];function dct(t,e){1&t&&(Qe(),ba(0,"g",6)),2&t&&pa("app-ellipse",Aa().drawing.element)}function fct(t,e){1&t&&(Qe(),ba(0,"g",7)),2&t&&pa("app-image",Aa().drawing.element)}function pct(t,e){1&t&&(Qe(),ba(0,"g",8)),2&t&&pa("app-line",Aa().drawing.element)}function mct(t,e){1&t&&(Qe(),ba(0,"g",9)),2&t&&pa("app-rect",Aa().drawing.element)}function gct(t,e){1&t&&(Qe(),ba(0,"g",10)),2&t&&pa("app-text",Aa().drawing.element)}var vct=function(){function t(t,e,n){this.svgToDrawingConverter=t,this.drawingsEventSource=e,this.cd=n}return t.prototype.ngOnInit=function(){try{this.drawing.element=this.svgToDrawingConverter.convert(this.drawing.svg)}catch(t){console.log("Cannot convert due to Error: '"+t+"'")}},t.prototype.OnDragging=function(t){this.drawing.x=t.x,this.drawing.y=t.y,this.cd.detectChanges()},t.prototype.OnDragged=function(t){this.cd.detectChanges(),this.drawingsEventSource.dragged.emit(new int(this.drawing,t.dx,t.dy))},t.prototype.is=function(t,e){return!!t&&("ellipse"===e?t instanceof k9:"image"===e?t instanceof g9:"line"===e?t instanceof _9:"rect"===e?t instanceof b9:"text"===e&&t instanceof z0)},Object.defineProperty(t.prototype,"transformation",{get:function(){return"translate("+this.drawing.x+","+this.drawing.y+") rotate("+this.drawing.rotation+")"},enumerable:!1,configurable:!0}),t.\u0275fac=function(e){return new(e||t)(da(S9),da(Jnt),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["","app-drawing",""]],inputs:{drawing:["app-drawing","drawing"]},attrs:hct,decls:6,vars:7,consts:[[1,"drawing",3,"app-draggable","dragging","dragged"],[3,"app-ellipse",4,"ngIf"],[3,"app-image",4,"ngIf"],[3,"app-line",4,"ngIf"],[3,"app-rect",4,"ngIf"],[3,"app-text",4,"ngIf"],[3,"app-ellipse"],[3,"app-image"],[3,"app-line"],[3,"app-rect"],[3,"app-text"]],template:function(t,e){1&t&&(Qe(),ga(0,"g",0),xa("dragging",(function(t){return e.OnDragging(t)}))("dragged",(function(t){return e.OnDragged(t)})),ua(1,dct,1,1,"g",1),ua(2,fct,1,1,"g",2),ua(3,pct,1,1,"g",3),ua(4,mct,1,1,"g",4),ua(5,gct,1,1,"g",5),va()),2&t&&(pa("app-draggable",e.drawing),oa("transform",e.transformation),Qi(1),pa("ngIf",e.is(e.drawing.element,"ellipse")),Qi(1),pa("ngIf",e.is(e.drawing.element,"image")),Qi(1),pa("ngIf",e.is(e.drawing.element,"line")),Qi(1),pa("ngIf",e.is(e.drawing.element,"rect")),Qi(1),pa("ngIf",e.is(e.drawing.element,"text")))},directives:[Xst,Ah,tct,nct,rct,act,uct],styles:[""]}),t}(),bct=["svg"];function yct(t,e){if(1&t&&(Qe(),ba(0,"g",12)),2&t){var n=e.$implicit,i=Aa(2);pa("app-link",n)("show-interface-labels",i.settings.show_interface_labels)}}function _ct(t,e){if(1&t&&(Qe(),ba(0,"g",13)),2&t){var n=e.$implicit,i=Aa(2);pa("app-node",n)("symbols",i.symbols)}}function wct(t,e){1&t&&(Qe(),ba(0,"g",14)),2&t&&pa("app-drawing",e.$implicit)}function kct(t,e){if(1&t&&(Qe(),ga(0,"g"),ga(1,"g",6),ua(2,yct,1,2,"g",7),va(),ga(3,"g",8),ua(4,_ct,1,2,"g",9),va(),ga(5,"g",10),ua(6,wct,1,1,"g",11),va(),va()),2&t){var n=e.$implicit;Qi(2),pa("ngForOf",n.links),Qi(2),pa("ngForOf",n.nodes),Qi(2),pa("ngForOf",n.drawings)}}var Cct=function(){function t(t,e,n,i,r,o,a){this.graphDataManager=t,this.context=e,this.mapChangeDetectorRef=n,this.canvasSizeDetector=i,this.changeDetectorRef=r,this.layersManger=o,this.graphLayout=a,this.nodes=[],this.links=[],this.drawings=[],this.symbols=[],this.width=1500,this.height=600,this.settings={show_interface_labels:!0}}return Object.defineProperty(t.prototype,"showInterfaceLabels",{set:function(t){this.settings.show_interface_labels=t,this.mapChangeDetectorRef.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"movingTool",{set:function(t){this.mapChangeDetectorRef.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selectionTool",{set:function(t){this.mapChangeDetectorRef.detectChanges()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"readonly",{set:function(t){},enumerable:!1,configurable:!0}),t.prototype.ngOnChanges=function(t){},t.prototype.ngOnInit=function(){var t=this;this.changesDetected=this.mapChangeDetectorRef.changesDetected.subscribe((function(){t.graphDataManager.setNodes(t.nodes),t.graphDataManager.setLinks(t.links),t.graphDataManager.setDrawings(t.drawings),t.graphDataManager.setSymbols(t.symbols),t.changeDetectorRef.detectChanges()}))},t.prototype.ngOnDestroy=function(){this.changesDetected.unsubscribe()},t.prototype.getSize=function(){return this.canvasSizeDetector.getOptimalSize(this.width,this.height)},Object.defineProperty(t.prototype,"layers",{get:function(){return this.layersManger.getLayersList()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"transform",{get:function(){var t=new Ont;return t.size=this.getSize(),"translate("+(t.getZeroZeroTransformationPoint().x+t.transformation.x)+", "+(t.getZeroZeroTransformationPoint().y+t.transformation.y)+") scale("+t.transformation.k+")"},enumerable:!1,configurable:!0}),t.prototype.onResize=function(t){},t.\u0275fac=function(e){return new(e||t)(da(Yet),da(Ont),da(_et),da(Qnt),da(Po),da(Net),da(Znt))},t.\u0275cmp=Ht({type:t,selectors:[["app-experimental-map"]],viewQuery:function(t,e){var n;1&t&&nl(bct,!0),2&t&&tl(n=sl())&&(e.svg=n.first)},hostBindings:function(t,e){1&t&&xa("resize",(function(t){return e.onResize(t)}),!1,yn)},inputs:{nodes:"nodes",links:"links",drawings:"drawings",symbols:"symbols",width:"width",height:"height",showInterfaceLabels:["show-interface-labels","showInterfaceLabels"],movingTool:["moving-tool","movingTool"],selectionTool:["selection-tool","selectionTool"],drawLinkTool:["draw-link-tool","drawLinkTool"],readonly:"readonly"},features:[Ms],decls:7,vars:5,consts:[["preserveAspectRatio","none",1,"map"],["svg",""],[4,"ngFor","ngForOf"],[3,"app-selection"],["id","grayscale"],["id","feGrayscale","type","saturate","values","0"],[1,"links"],[3,"app-link","show-interface-labels",4,"ngFor","ngForOf"],[1,"nodes"],[3,"app-node","symbols",4,"ngFor","ngForOf"],[1,"drawings"],[3,"app-drawing",4,"ngFor","ngForOf"],[3,"app-link","show-interface-labels"],[3,"app-node","symbols"],[3,"app-drawing"]],template:function(t,e){if(1&t&&(Qe(),ga(0,"svg",0,1),ga(2,"g"),ua(3,kct,7,3,"g",2),va(),ba(4,"g",3),ga(5,"filter",4),ba(6,"feColorMatrix",5),va(),va()),2&t){var n=ha(1);oa("width",e.width)("height",e.height),Qi(2),oa("transform",e.transform),Qi(1),pa("ngForOf",e.layers),Qi(1),pa("app-selection",n)}},directives:[Eh,Mst,qst,$st,vct],styles:["svg[_ngcontent-%COMP%]{display:block}"],changeDetection:0}),t}(),Sct=["*",[["mat-toolbar-row"]]],xct=["*","mat-toolbar-row"],Oct=tJ((function t(e){Object(m.a)(this,t),this._elementRef=e})),Mct=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-toolbar-row"]],hostAttrs:[1,"mat-toolbar-row"],exportAs:["matToolbarRow"]}),t}(),Tct=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t))._platform=i,o._document=r,o}return Object(g.a)(n,[{key:"ngAfterViewInit",value:function(){var t=this;ii()&&this._platform.isBrowser&&(this._checkToolbarMixedModes(),this._toolbarRows.changes.subscribe((function(){return t._checkToolbarMixedModes()})))}},{key:"_checkToolbarMixedModes",value:function(){var t=this;this._toolbarRows.length&&Array.from(this._elementRef.nativeElement.childNodes).filter((function(t){return!(t.classList&&t.classList.contains("mat-toolbar-row"))})).filter((function(e){return e.nodeType!==(t._document?t._document.COMMENT_NODE:8)})).some((function(t){return!(!t.textContent||!t.textContent.trim())}))&&function(){throw Error("MatToolbar: Attempting to combine different toolbar modes. Either specify multiple `<mat-toolbar-row>` elements explicitly or just place content inside of a `<mat-toolbar>` for a single row.")}()}}]),n}(Oct);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Cm),da(du))},t.\u0275cmp=Ht({type:t,selectors:[["mat-toolbar"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,Mct,!0),2&t&&tl(i=sl())&&(e._toolbarRows=i)},hostAttrs:[1,"mat-toolbar"],hostVars:4,hostBindings:function(t,e){2&t&&Qa("mat-toolbar-multiple-rows",e._toolbarRows.length>0)("mat-toolbar-single-row",0===e._toolbarRows.length)},inputs:{color:"color"},exportAs:["matToolbar"],features:[ws],ngContentSelectors:xct,decls:2,vars:0,template:function(t,e){1&t&&(Ia(Sct),Da(0),Da(1,1))},styles:[".cdk-high-contrast-active .mat-toolbar{outline:solid 1px}.mat-toolbar-row,.mat-toolbar-single-row{display:flex;box-sizing:border-box;padding:0 16px;width:100%;flex-direction:row;align-items:center;white-space:nowrap}.mat-toolbar-multiple-rows{display:flex;box-sizing:border-box;flex-direction:column;width:100%}\n"],encapsulation:2,changeDetection:0}),t}(),Ect=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[$$],$$]}),t}(),Pct=function(){function t(t,e,n,i,r){this.toasterService=t,this.dockerService=e,this.qemuService=n,this.iouService=i,this.iosService=r}return t.prototype.ngOnInit=function(){var t=this;this.uploader=new wX({}),this.uploader.onAfterAddingFile=function(t){t.withCredentials=!1},this.uploader.onErrorItem=function(e,n,i,r){t.toasterService.error("An error has occured")},this.uploader.onCompleteItem=function(e,n,i,r){"qemu"===t.template.template_type?t.qemuService.addTemplate(t.server,t.template).subscribe((function(){return t.onUploadComplete()})):"iou"===t.template.template_type?t.iouService.addTemplate(t.server,t.template).subscribe((function(){return t.onUploadComplete()})):"dynamips"===t.template.template_type?t.iosService.addTemplate(t.server,t.template).subscribe((function(){return t.onUploadComplete()})):"docker"===t.template.template_type&&t.dockerService.addTemplate(t.server,t.template).subscribe((function(){return t.onUploadComplete()}))}},t.prototype.onUploadComplete=function(){this.toasterService.success("Appliance imported successfully"),this.uploader.queue=[]},t.prototype.uploadAppliance=function(t){var e,n=this,i=t.target.files[0],r=i.name,o=new FileReader;o.onloadend=function(){var t=JSON.parse(o.result);if(t.qemu)(e=new dot).template_type="qemu",e.adapter_type=t.qemu.adapter_type,e.adapters=t.qemu.adapters,e.ram=t.qemu.ram,e.options=t.qemu.options,e.console_type=t.qemu.console_type;else if(t.iou)(e=new bot).template_type="iou",e.console_type=t.iou.console_type,e.console_auto_start=t.iou.console_auto_start,e.ethernet_adapters=t.iou.ethernet_adapters,e.l1_keepalives=t.iou.l1_keepalives,e.nvram=t.iou.nvram,e.ram=t.iou.ram,e.serial_adapters=t.iou.serial_adapters;else if(t.dynamips)(e=new mot).template_type="dynamips",e.platform=t.dynamips.platform,e.ram=t.dynamips.ram,e.nvram=t.dynamips.nvram,e.startup_config=t.dynamips.startup_config,e.wic0=t.dynamips.wic0,e.wic1=t.dynamips.wic1,e.wic2=t.dynamips.wic2,e.slot0=t.dynamips.slot0,e.slot1=t.dynamips.slot1,e.slot2=t.dynamips.slot2,e.slot3=t.dynamips.slot3,e.slot4=t.dynamips.slot4,e.slot5=t.dynamips.slot5,e.slot6=t.dynamips.slot6,e.slot7=t.dynamips.slot7;else{if(!t.docker)return void n.toasterService.error("Template type not supported");(e=new fot).template_type="docker",e.adapters=t.docker.adapters,e.console_type=t.docker.console_type,e.image=t.docker.image}e.name=t.name,e.category=t.category,e.builtin=!1,e.default_name_format="{name}-{0}",e.compute_id="vm",e.symbol="guest"===e.category?":/symbols/computer.svg":":/symbols/"+e.category+"_guest.svg",n.template=e;var i=n.getUploadPath(n.server,e.template_type,r);n.uploader.queue.forEach((function(t){return t.url=i})),n.uploader.uploadItem(n.uploader.queue[0])},o.readAsText(i)},t.prototype.getUploadPath=function(t,e,n){return"http://"+t.host+":"+t.port+"/v2/"+e+"/images/"+n},t.\u0275fac=function(e){return new(e||t)(da(Y2),da(pot),da(w6),da(vot),da(got))},t.\u0275cmp=Ht({type:t,selectors:[["app-import-appliance"]],inputs:{project:"project",server:"server"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),Act=function(){function t(){}return t.prototype.transform=function(t,e){return t?e?(e=e.toLowerCase(),t.filter((function(t){return t.name.toLowerCase().includes(e)}))):t:[]},t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"templatefilter",type:t,pure:!0}),t}();function jct(t,e){if(1&t&&(ga(0,"mat-option",18),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Ict(t,e){if(1&t&&(ga(0,"mat-option",18),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n.name," ")}}function Dct(t,e){if(1&t&&(ga(0,"mat-option",18),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Rct(t,e){if(1&t){var n=ka();ga(0,"mat-select",19),xa("valueChange",(function(t){return Se(n),Aa().selectedTemplate.compute_id=t})),ua(1,Dct,2,2,"mat-option",8),va()}if(2&t){var i=Aa();pa("value",i.selectedTemplate.compute_id),Qi(1),pa("ngForOf",i.nodeServers)}}var Lct=function(){return{standalone:!0}},Fct=function(){function t(t,e,n,i,r,o){this.dialogRef=t,this.templateService=e,this.formBuilder=n,this.data=i,this.toasterService=r,this.nonNegativeValidator=o,this.templateTypes=["cloud","ethernet_hub","ethernet_switch","docker","dynamips","vpcs","traceng","virtualbox","vmware","iou","qemu"],this.searchText="",this.nodeServers=["local","vm"],this.server=i.server,this.project=i.project,this.configurationForm=this.formBuilder.group({numberOfNodes:new hp(1,[kf.required,o.get])}),this.positionForm=this.formBuilder.group({top:new hp(0,kf.required),left:new hp(0,kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.templateService.list(this.server).subscribe((function(e){t.filteredTemplates=e,t.templates=e}))},t.prototype.onNoClick=function(){this.dialogRef.close()},t.prototype.filterTemplates=function(t){var e=this,n=this.templates.filter((function(t){return t.name.toLowerCase().includes(e.searchText.toLowerCase())}));this.filteredTemplates=n.filter((function(e){return e.template_type===t.value.toString()}))},t.prototype.chooseTemplate=function(t){this.selectedTemplate=t.value,"cloud"!==this.selectedTemplate.template_type&&"ethernet_hub"!==this.selectedTemplate.template_type&&"ethernet_switch"!==this.selectedTemplate.template_type||(this.selectedTemplate.compute_id="local")},t.prototype.onAddClick=function(){if(this.selectedTemplate&&0!==this.filteredTemplates.length)if(this.positionForm.valid&&this.configurationForm.valid&&this.selectedTemplate.compute_id){var t=this.positionForm.get("left").value,e=this.positionForm.get("top").value;if(t>this.project.scene_width/2||t<-this.project.scene_width/2||e>this.project.scene_height/2||e<-this.project.scene_height)this.toasterService.error("Please set correct position values.");else{var n={template:this.selectedTemplate,server:this.selectedTemplate.compute_id,numberOfNodes:this.configurationForm.get("numberOfNodes").value,x:t,y:e};this.dialogRef.close(n)}}else this.toasterService.error("Please fill all required fields.");else this.toasterService.error("Please firstly choose template.")},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(yot),da(Jp),da(Q0),da(Y2),da(L9))},t.\u0275cmp=Ht({type:t,selectors:[["app-template-list-dialog"]],decls:40,vars:18,consts:[[1,"title-container"],["mat-dialog-title",""],["mat-button","","color","accent",1,"top-button",3,"routerLink","click"],["mat-dialog-content","",1,"content"],["floatPlaceholder","never",1,"form-field"],["matInput","","placeholder","Search by name",3,"ngModel","ngModelOptions","ngModelChange"],[1,"form-field"],["placeholder","Filter templates by type",3,"ngModelOptions","ngModel","selectionChange","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["placeholder","Choose template",3,"ngModelOptions","ngModel","selectionChange","ngModelChange"],[3,"formGroup"],["type","number","matInput","","formControlName","numberOfNodes","placeholder","Enter number of nodes (default value is 1)"],["placeholder","Choose server for node",3,"value","valueChange",4,"ngIf"],["matInput","","type","number","formControlName","left"],["matInput","","type","number","formControlName","top"],["mat-dialog-actions","","align","end"],["mat-button","","tabindex","-1","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",1,"addButton",3,"click"],[3,"value"],["placeholder","Choose server for node",3,"value","valueChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"h1",1),ds(2,"Add a node"),va(),ga(3,"button",2),xa("click",(function(){return e.onNoClick()})),ds(4,"Go to template preferences"),va(),va(),ga(5,"div",3),ga(6,"div",0),ga(7,"h6"),ds(8,"Template"),va(),va(),ga(9,"mat-form-field",4),ga(10,"input",5),xa("ngModelChange",(function(t){return e.searchText=t})),va(),va(),ga(11,"mat-form-field",6),ga(12,"mat-select",7),xa("selectionChange",(function(t){return e.filterTemplates(t)}))("ngModelChange",(function(t){return e.selectedType=t})),ua(13,jct,2,2,"mat-option",8),va(),va(),ga(14,"mat-form-field",6),ga(15,"mat-select",9),xa("selectionChange",(function(t){return e.chooseTemplate(t)}))("ngModelChange",(function(t){return e.selectedTemplate=t})),ua(16,Ict,2,2,"mat-option",8),Nc(17,"templatefilter"),va(),va(),ga(18,"div",0),ga(19,"h6"),ds(20,"Configuration"),va(),va(),ga(21,"form",10),ga(22,"mat-form-field",6),ba(23,"input",11),va(),va(),ua(24,Rct,2,2,"mat-select",12),ga(25,"div",0),ga(26,"h6"),ds(27,"Position"),va(),va(),ga(28,"form",10),ds(29," Left:\xa0 "),ga(30,"mat-form-field"),ba(31,"input",13),va(),ds(32," Top:\xa0 "),ga(33,"mat-form-field"),ba(34,"input",14),va(),va(),va(),ga(35,"div",15),ga(36,"button",16),xa("click",(function(){return e.onNoClick()})),ds(37,"Close"),va(),ga(38,"button",17),xa("click",(function(){return e.onAddClick()})),ds(39,"Add"),va(),va()),2&t&&(Qi(3),La("routerLink","/server/",e.server.id,"/preferences"),Qi(7),pa("ngModel",e.searchText)("ngModelOptions",jc(15,Lct)),Qi(2),pa("ngModelOptions",jc(16,Lct))("ngModel",e.selectedType),Qi(1),pa("ngForOf",e.templateTypes),Qi(2),pa("ngModelOptions",jc(17,Lct))("ngModel",e.selectedTemplate),Qi(1),pa("ngForOf",Hc(17,12,e.filteredTemplates,e.searchText)),Qi(5),pa("formGroup",e.configurationForm),Qi(3),pa("ngIf",e.selectedTemplate),Qi(4),pa("formGroup",e.positionForm))},directives:[r1,a2,hQ,o1,Y3,s5,cf,mf,Sp,O5,Eh,xp,gf,Pp,Ef,Fp,Ah,a1,EJ],pipes:[Act],styles:[".header[_ngcontent-%COMP%]{min-height:64px;display:flex;align-items:baseline;padding:8px 24px 0;font-size:20px;justify-content:space-between}.mat-table[_ngcontent-%COMP%]{height:200px;overflow:scroll}.mat-form-field[_ngcontent-%COMP%]{font-size:16px;flex-grow:1}.form-field[_ngcontent-%COMP%]{width:100%}div[_ngcontent-%COMP%]{scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}h6[_ngcontent-%COMP%]{margin-top:5px;margin-bottom:10px;color:#0097a7}mat-table[_ngcontent-%COMP%]{scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}.filterBox[_ngcontent-%COMP%], .title-container[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.title-container[_ngcontent-%COMP%]{align-items:baseline}"]}),t}(),Nct=n("jtHE"),Bct=n("HjQM"),Hct=n.n(Bct),zct=n("HrJb"),Vct=function(){var t=function t(){Object(m.a)(this,t),this.currentDrag=new w.b};return t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)},providedIn:"root"}),t.ngInjectableDef=L({factory:function(){return new t},token:t,providedIn:"root"}),t}(),Uct=function(){var t=function t(e){Object(m.a)(this,t),this.elementRef=e,this.activeLongPressDrag=!1,this.longPressConfig={duration:300,delta:30}};return t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","mwlDraggableScrollContainer",""]],inputs:{activeLongPressDrag:"activeLongPressDrag",longPressConfig:"longPressConfig"}}),t}();function qct(t,e,n){n&&n.split(" ").forEach((function(n){return t.addClass(e.nativeElement,n)}))}function Gct(t,e,n){n&&n.split(" ").forEach((function(n){return t.removeClass(e.nativeElement,n)}))}var Wct=function(){var t=function(){function t(e,n,i,r,o,a,s){Object(m.a)(this,t),this.element=e,this.renderer=n,this.draggableHelper=i,this.zone=r,this.vcr=o,this.scrollContainer=a,this.document=s,this.dragAxis={x:!0,y:!0},this.dragSnapGrid={},this.ghostDragEnabled=!0,this.showOriginalElementWhileDragging=!1,this.dragCursor="",this.autoScroll={margin:20},this.dragPointerDown=new Uc,this.dragStart=new Uc,this.ghostElementCreated=new Uc,this.dragging=new Uc,this.dragEnd=new Uc,this.pointerDown$=new w.b,this.pointerMove$=new w.b,this.pointerUp$=new w.b,this.eventListenerSubscriptions={},this.destroy$=new w.b,this.timeLongPress={timerBegin:0,timerEnd:0}}return Object(g.a)(t,[{key:"ngOnInit",value:function(){var t=this;this.checkEventListeners();var e=this.pointerDown$.pipe(Object(vg.a)((function(){return t.canDrag()})),Object(IX.a)((function(e){e.event.stopPropagation&&!t.scrollContainer&&e.event.stopPropagation();var n=t.renderer.createElement("style");t.renderer.setAttribute(n,"type","text/css"),t.renderer.appendChild(n,t.renderer.createText("\n body * {\n -moz-user-select: none;\n -ms-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n }\n ")),requestAnimationFrame((function(){t.document.head.appendChild(n)}));var i=t.getScrollPosition(),r=new k.a((function(e){return t.renderer.listen(t.scrollContainer?t.scrollContainer.elementRef.nativeElement:"window","scroll",(function(t){return e.next(t)}))})).pipe(Object(NX.a)(i),Object(ef.a)((function(){return t.getScrollPosition()}))),o=new w.b,a=new Nct.a;t.zone.run((function(){t.dragPointerDown.next({x:0,y:0})}));var s=Object(C.a)(t.pointerUp$,t.pointerDown$,a,t.destroy$).pipe(Object(S.a)()),c=Object(OX.b)([t.pointerMove$,r]).pipe(Object(ef.a)((function(t){var n=l(t,2),i=n[0],r=n[1];return{currentDrag$:o,transformX:i.clientX-e.clientX,transformY:i.clientY-e.clientY,clientX:i.clientX,clientY:i.clientY,scrollLeft:r.left,scrollTop:r.top}})),Object(ef.a)((function(e){return t.dragSnapGrid.x&&(e.transformX=Math.round(e.transformX/t.dragSnapGrid.x)*t.dragSnapGrid.x),t.dragSnapGrid.y&&(e.transformY=Math.round(e.transformY/t.dragSnapGrid.y)*t.dragSnapGrid.y),e})),Object(ef.a)((function(e){return t.dragAxis.x||(e.transformX=0),t.dragAxis.y||(e.transformY=0),e})),Object(ef.a)((function(t){return Object.assign({},t,{x:t.transformX+(t.scrollLeft-i.left),y:t.transformY+(t.scrollTop-i.top)})})),Object(vg.a)((function(e){return!t.validateDrag||t.validateDrag({x:e.x,y:e.y,transform:{x:e.transformX,y:e.transformY}})})),Object(Am.a)(s),Object(S.a)()),u=c.pipe(Object(FX.a)(1),Object(S.a)()),h=c.pipe(Object(HX.a)(1),Object(S.a)());return u.subscribe((function(e){var n=e.clientX,i=e.clientY,r=e.x,s=e.y;if(t.zone.run((function(){t.dragStart.next({cancelDrag$:a})})),t.scroller=Hct()([t.scrollContainer?t.scrollContainer.elementRef.nativeElement:t.document.defaultView],Object.assign({},t.autoScroll,{autoScroll:function(){return!0}})),qct(t.renderer,t.element,t.dragActiveClass),t.ghostDragEnabled){var c=t.element.nativeElement.getBoundingClientRect(),l=t.element.nativeElement.cloneNode(!0);if(t.showOriginalElementWhileDragging||t.renderer.setStyle(t.element.nativeElement,"visibility","hidden"),t.ghostElementAppendTo?t.ghostElementAppendTo.appendChild(l):t.element.nativeElement.parentNode.insertBefore(l,t.element.nativeElement.nextSibling),t.ghostElement=l,t.document.body.style.cursor=t.dragCursor,t.setElementStyles(l,{position:"fixed",top:"".concat(c.top,"px"),left:"".concat(c.left,"px"),width:"".concat(c.width,"px"),height:"".concat(c.height,"px"),cursor:t.dragCursor,margin:"0",willChange:"transform",pointerEvents:"none"}),t.ghostElementTemplate){var u=t.vcr.createEmbeddedView(t.ghostElementTemplate);l.innerHTML="",u.rootNodes.filter((function(t){return t instanceof Node})).forEach((function(t){l.appendChild(t)})),h.subscribe((function(){t.vcr.remove(t.vcr.indexOf(u))}))}t.zone.run((function(){t.ghostElementCreated.emit({clientX:n-r,clientY:i-s,element:l})})),h.subscribe((function(){l.parentElement.removeChild(l),t.ghostElement=null,t.renderer.setStyle(t.element.nativeElement,"visibility","")}))}t.draggableHelper.currentDrag.next(o)})),h.pipe(Object(IX.a)((function(t){var e=a.pipe(Object(zct.a)(),Object(FX.a)(1),Object(ef.a)((function(e){return Object.assign({},t,{dragCancelled:e>0})})));return a.complete(),e}))).subscribe((function(e){var n=e.x,i=e.y,r=e.dragCancelled;t.scroller.destroy(),t.zone.run((function(){t.dragEnd.next({x:n,y:i,dragCancelled:r})})),Gct(t.renderer,t.element,t.dragActiveClass),o.complete()})),Object(C.a)(s,h).pipe(Object(FX.a)(1)).subscribe((function(){requestAnimationFrame((function(){t.document.head.removeChild(n)}))})),c})),Object(S.a)());Object(C.a)(e.pipe(Object(FX.a)(1),Object(ef.a)((function(t){return[,t]}))),e.pipe(Object(FJ.a)())).pipe(Object(vg.a)((function(t){var e=l(t,2),n=e[0],i=e[1];return!n||n.x!==i.x||n.y!==i.y})),Object(ef.a)((function(t){return l(t,2)[1]})),Object(LJ.a)(0,DJ.a)).subscribe((function(e){var n=e.x,i=e.y,r=e.currentDrag$,o=e.clientX,a=e.clientY,s=e.transformX,c=e.transformY;if(t.zone.run((function(){t.dragging.next({x:n,y:i})})),t.ghostElement){var l="translate3d(".concat(s,"px, ").concat(c,"px, 0px)");t.setElementStyles(t.ghostElement,{transform:l,"-webkit-transform":l,"-ms-transform":l,"-moz-transform":l,"-o-transform":l})}r.next({clientX:o,clientY:a,dropData:t.dropData})}))}},{key:"ngOnChanges",value:function(t){t.dragAxis&&this.checkEventListeners()}},{key:"ngOnDestroy",value:function(){this.unsubscribeEventListeners(),this.pointerDown$.complete(),this.pointerMove$.complete(),this.pointerUp$.complete(),this.destroy$.next()}},{key:"checkEventListeners",value:function(){var t=this,e=this.canDrag(),n=Object.keys(this.eventListenerSubscriptions).length>0;e&&!n?this.zone.runOutsideAngular((function(){t.eventListenerSubscriptions.mousedown=t.renderer.listen(t.element.nativeElement,"mousedown",(function(e){t.onMouseDown(e)})),t.eventListenerSubscriptions.mouseup=t.renderer.listen("document","mouseup",(function(e){t.onMouseUp(e)})),t.eventListenerSubscriptions.touchstart=t.renderer.listen(t.element.nativeElement,"touchstart",(function(e){t.onTouchStart(e)})),t.eventListenerSubscriptions.touchend=t.renderer.listen("document","touchend",(function(e){t.onTouchEnd(e)})),t.eventListenerSubscriptions.touchcancel=t.renderer.listen("document","touchcancel",(function(e){t.onTouchEnd(e)})),t.eventListenerSubscriptions.mouseenter=t.renderer.listen(t.element.nativeElement,"mouseenter",(function(){t.onMouseEnter()})),t.eventListenerSubscriptions.mouseleave=t.renderer.listen(t.element.nativeElement,"mouseleave",(function(){t.onMouseLeave()}))})):!e&&n&&this.unsubscribeEventListeners()}},{key:"onMouseDown",value:function(t){var e=this;0===t.button&&(this.eventListenerSubscriptions.mousemove||(this.eventListenerSubscriptions.mousemove=this.renderer.listen("document","mousemove",(function(t){e.pointerMove$.next({event:t,clientX:t.clientX,clientY:t.clientY})}))),this.pointerDown$.next({event:t,clientX:t.clientX,clientY:t.clientY}))}},{key:"onMouseUp",value:function(t){0===t.button&&(this.eventListenerSubscriptions.mousemove&&(this.eventListenerSubscriptions.mousemove(),delete this.eventListenerSubscriptions.mousemove),this.pointerUp$.next({event:t,clientX:t.clientX,clientY:t.clientY}))}},{key:"onTouchStart",value:function(t){var e,n,i,r=this;if((this.scrollContainer&&this.scrollContainer.activeLongPressDrag||this.touchStartLongPress)&&(this.timeLongPress.timerBegin=Date.now(),n=!1,i=this.hasScrollbar(),e=this.getScrollPosition()),!this.eventListenerSubscriptions.touchmove){var o=Object(IJ.a)(this.document,"contextmenu").subscribe((function(t){t.preventDefault()})),a=Object(IJ.a)(this.document,"touchmove",{passive:!1}).subscribe((function(o){(r.scrollContainer&&r.scrollContainer.activeLongPressDrag||r.touchStartLongPress)&&!n&&i&&(n=r.shouldBeginDrag(t,o,e)),(r.scrollContainer&&r.scrollContainer.activeLongPressDrag||r.touchStartLongPress)&&i&&!n||(o.preventDefault(),r.pointerMove$.next({event:o,clientX:o.targetTouches[0].clientX,clientY:o.targetTouches[0].clientY}))}));this.eventListenerSubscriptions.touchmove=function(){o.unsubscribe(),a.unsubscribe()}}this.pointerDown$.next({event:t,clientX:t.touches[0].clientX,clientY:t.touches[0].clientY})}},{key:"onTouchEnd",value:function(t){this.eventListenerSubscriptions.touchmove&&(this.eventListenerSubscriptions.touchmove(),delete this.eventListenerSubscriptions.touchmove,(this.scrollContainer&&this.scrollContainer.activeLongPressDrag||this.touchStartLongPress)&&this.enableScroll()),this.pointerUp$.next({event:t,clientX:t.changedTouches[0].clientX,clientY:t.changedTouches[0].clientY})}},{key:"onMouseEnter",value:function(){this.setCursor(this.dragCursor)}},{key:"onMouseLeave",value:function(){this.setCursor("")}},{key:"canDrag",value:function(){return this.dragAxis.x||this.dragAxis.y}},{key:"setCursor",value:function(t){this.eventListenerSubscriptions.mousemove||this.renderer.setStyle(this.element.nativeElement,"cursor",t)}},{key:"unsubscribeEventListeners",value:function(){var t=this;Object.keys(this.eventListenerSubscriptions).forEach((function(e){t.eventListenerSubscriptions[e](),delete t.eventListenerSubscriptions[e]}))}},{key:"setElementStyles",value:function(t,e){var n=this;Object.keys(e).forEach((function(i){n.renderer.setStyle(t,i,e[i])}))}},{key:"getScrollElement",value:function(){return this.scrollContainer?this.scrollContainer.elementRef.nativeElement:this.document.body}},{key:"getScrollPosition",value:function(){return this.scrollContainer?{top:this.scrollContainer.elementRef.nativeElement.scrollTop,left:this.scrollContainer.elementRef.nativeElement.scrollLeft}:{top:window.pageYOffset||this.document.documentElement.scrollTop,left:window.pageXOffset||this.document.documentElement.scrollLeft}}},{key:"shouldBeginDrag",value:function(t,e,n){var i=this.getScrollPosition(),r=Math.abs(i.top-n.top),o=Math.abs(i.left-n.left),a=Math.abs(e.targetTouches[0].clientX-t.touches[0].clientX)-o,s=Math.abs(e.targetTouches[0].clientY-t.touches[0].clientY)-r,c=this.touchStartLongPress?this.touchStartLongPress:{delta:this.scrollContainer.longPressConfig.delta,delay:this.scrollContainer.longPressConfig.duration};return(a+s>c.delta||r>0||o>0)&&(this.timeLongPress.timerBegin=Date.now()),this.timeLongPress.timerEnd=Date.now(),this.timeLongPress.timerEnd-this.timeLongPress.timerBegin>=c.delay&&(this.disableScroll(),!0)}},{key:"enableScroll",value:function(){this.scrollContainer&&this.renderer.setStyle(this.scrollContainer.elementRef.nativeElement,"overflow",""),this.renderer.setStyle(this.document.body,"overflow","")}},{key:"disableScroll",value:function(){this.scrollContainer&&this.renderer.setStyle(this.scrollContainer.elementRef.nativeElement,"overflow","hidden"),this.renderer.setStyle(this.document.body,"overflow","hidden")}},{key:"hasScrollbar",value:function(){var t=this.getScrollElement();return t.scrollWidth>t.clientWidth||t.scrollHeight>t.clientHeight}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Ks),da(Vct),da(jl),da(mc),da(Uct,8),da(du))},t.\u0275dir=Wt({type:t,selectors:[["","mwlDraggable",""]],inputs:{dragAxis:"dragAxis",dragSnapGrid:"dragSnapGrid",ghostDragEnabled:"ghostDragEnabled",showOriginalElementWhileDragging:"showOriginalElementWhileDragging",dragCursor:"dragCursor",autoScroll:"autoScroll",dropData:"dropData",validateDrag:"validateDrag",dragActiveClass:"dragActiveClass",ghostElementAppendTo:"ghostElementAppendTo",ghostElementTemplate:"ghostElementTemplate",touchStartLongPress:"touchStartLongPress"},outputs:{dragPointerDown:"dragPointerDown",dragStart:"dragStart",ghostElementCreated:"ghostElementCreated",dragging:"dragging",dragEnd:"dragEnd"},features:[Ms]}),t}();function Kct(t,e,n){return t>=n.left&&t<=n.right&&e>=n.top&&e<=n.bottom}var Xct=function(){var t=function(){function t(e,n,i,r,o){Object(m.a)(this,t),this.element=e,this.draggableHelper=n,this.zone=i,this.renderer=r,this.scrollContainer=o,this.dragEnter=new Uc,this.dragLeave=new Uc,this.dragOver=new Uc,this.drop=new Uc}return Object(g.a)(t,[{key:"ngOnInit",value:function(){var t=this;this.currentDragSubscription=this.draggableHelper.currentDrag.subscribe((function(e){qct(t.renderer,t.element,t.dragActiveClass);var n,i,r={updateCache:!0},o=t.renderer.listen(t.scrollContainer?t.scrollContainer.elementRef.nativeElement:"window","scroll",(function(){r.updateCache=!0})),a=e.pipe(Object(ef.a)((function(e){var i=e.clientX,o=e.clientY;n=e.dropData,r.updateCache&&(r.rect=t.element.nativeElement.getBoundingClientRect(),t.scrollContainer&&(r.scrollContainerRect=t.scrollContainer.elementRef.nativeElement.getBoundingClientRect()),r.updateCache=!1);var a=Kct(i,o,r.rect);return r.scrollContainerRect?a&&Kct(i,o,r.scrollContainerRect):a}))),s=a.pipe(Object(RJ.a)());s.pipe(Object(vg.a)((function(t){return t}))).subscribe((function(){i=!0,qct(t.renderer,t.element,t.dragOverClass),t.zone.run((function(){t.dragEnter.next({dropData:n})}))})),a.pipe(Object(vg.a)((function(t){return t}))).subscribe((function(){t.zone.run((function(){t.dragOver.next({dropData:n})}))})),s.pipe(Object(FJ.a)(),Object(vg.a)((function(t){var e=l(t,2);return e[0]&&!e[1]}))).subscribe((function(){i=!1,Gct(t.renderer,t.element,t.dragOverClass),t.zone.run((function(){t.dragLeave.next({dropData:n})}))})),e.subscribe({complete:function(){o(),Gct(t.renderer,t.element,t.dragActiveClass),i&&(Gct(t.renderer,t.element,t.dragOverClass),t.zone.run((function(){t.drop.next({dropData:n})})))}})}))}},{key:"ngOnDestroy",value:function(){this.currentDragSubscription&&this.currentDragSubscription.unsubscribe()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Vct),da(jl),da(Ks),da(Uct,8))},t.\u0275dir=Wt({type:t,selectors:[["","mwlDroppable",""]],inputs:{dragOverClass:"dragOverClass",dragActiveClass:"dragActiveClass"},outputs:{dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop"}}),t}(),Yct=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}();function Zct(t,e){if(1&t&&(ga(0,"mat-option",11),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Qct(t,e){if(1&t){var n=ka();ga(0,"span",14),ga(1,"div",15),xa("dragStart",(function(t){return Se(n),Aa(3).dragStart(t)}))("dragEnd",(function(t){Se(n);var e=Aa(2).index,i=Aa();return i.dragEnd(t,i.filteredTemplates[e+1])})),ba(2,"img",16),va(),ga(3,"div",17),ds(4),va(),va()}if(2&t){var i=Aa(2).index,r=Aa();Qi(2),pa("src",r.getImageSourceForTemplate(r.filteredTemplates[i+1]),Pi),Qi(2),fs(r.filteredTemplates[i+1].name)}}function $ct(t,e){if(1&t){var n=ka();ga(0,"span",14),ga(1,"div",15),xa("dragStart",(function(t){return Se(n),Aa(3).dragStart(t)}))("dragEnd",(function(t){Se(n);var e=Aa(2).index,i=Aa();return i.dragEnd(t,i.filteredTemplates[e+2])})),ba(2,"img",16),va(),ga(3,"div",17),ds(4),va(),va()}if(2&t){var i=Aa(2).index,r=Aa();Qi(2),pa("src",r.getImageSourceForTemplate(r.filteredTemplates[i+2]),Pi),Qi(2),fs(r.filteredTemplates[i+2].name)}}function Jct(t,e){if(1&t){var n=ka();ga(0,"span",14),ga(1,"div",15),xa("dragStart",(function(t){return Se(n),Aa(3).dragStart(t)}))("dragEnd",(function(t){Se(n);var e=Aa(2).index,i=Aa();return i.dragEnd(t,i.filteredTemplates[e+3])})),ba(2,"img",16),va(),ga(3,"div",17),ds(4),va(),va()}if(2&t){var i=Aa(2).index,r=Aa();Qi(2),pa("src",r.getImageSourceForTemplate(r.filteredTemplates[i+3]),Pi),Qi(2),fs(r.filteredTemplates[i+3].name)}}function tlt(t,e){if(1&t){var n=ka();ga(0,"span",13),ga(1,"span",14),ga(2,"div",15),xa("dragStart",(function(t){return Se(n),Aa(2).dragStart(t)}))("dragEnd",(function(t){Se(n);var e=Aa().index,i=Aa();return i.dragEnd(t,i.filteredTemplates[e])})),ba(3,"img",16),va(),ga(4,"div",17),ds(5),va(),va(),ua(6,Qct,5,2,"span",18),ua(7,$ct,5,2,"span",18),ua(8,Jct,5,2,"span",18),va()}if(2&t){var i=Aa().index,r=Aa();Qi(3),pa("src",r.getImageSourceForTemplate(r.filteredTemplates[i]),Pi),Qi(2),fs(r.filteredTemplates[i].name),Qi(1),pa("ngIf",r.filteredTemplates[i+1]),Qi(1),pa("ngIf",r.filteredTemplates[i+2]),Qi(1),pa("ngIf",r.filteredTemplates[i+3])}}function elt(t,e){if(1&t&&(ga(0,"mat-list-item"),ua(1,tlt,9,5,"span",12),va()),2&t){var n=e.index;Qi(1),pa("ngIf",n%4==0)}}var nlt=function(){return{standalone:!0}},ilt=function(){function t(t,e,n,i){this.dialog=t,this.templateService=e,this.scaleService=n,this.symbolService=i,this.onNodeCreation=new Uc,this.templates=[],this.filteredTemplates=[],this.searchText="",this.templateTypes=["all","cloud","ethernet_hub","ethernet_switch","docker","dynamips","vpcs","traceng","virtualbox","vmware","iou","qemu"]}return t.prototype.ngOnInit=function(){var t=this;this.subscription=this.templateService.newTemplateCreated.subscribe((function(e){t.templates.push(e)})),this.templateService.list(this.server).subscribe((function(e){t.filteredTemplates=e,t.sortTemplates(),t.templates=e})),this.symbolService.list(this.server)},t.prototype.sortTemplates=function(){this.filteredTemplates=this.filteredTemplates.sort((function(t,e){return t.name<e.name?-1:1}))},t.prototype.filterTemplates=function(t){var e=this,n=this.templates.filter((function(t){return t.name.toLowerCase().includes(e.searchText.toLowerCase())}));this.filteredTemplates="all"!==this.selectedType&&this.selectedType?n.filter((function(t){return t.template_type===e.selectedType})):n,this.sortTemplates()},t.prototype.dragStart=function(t){var e=event.target.getBoundingClientRect();this.startX=event.clientX,this.startY=event.clientY,this.movementY=e.top-event.clientY,this.movementX=e.left-event.clientX},t.prototype.dragEnd=function(t,e){var n=this;this.symbolService.raw(this.server,e.symbol.substring(1)).subscribe((function(i){var r=+i.split('width="')[1].split('"')[0]?+i.split('width="')[1].split('"')[0]:0,o=n.scaleService.getScale(),a={template:e,server:"local",numberOfNodes:1,x:(n.startX+t.x-n.project.scene_width/2-r/2)*o+window.scrollX,y:(n.startY+t.y-n.project.scene_height/2)*o+window.scrollY};n.onNodeCreation.emit(a)}))},t.prototype.openDialog=function(){var t=this;this.dialog.open(Fct,{width:"600px",data:{server:this.server,project:this.project},autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(e){null!==e&&t.onNodeCreation.emit(e)}))},t.prototype.getImageSourceForTemplate=function(t){return"http://"+this.server.host+":"+this.server.port+"/v2/symbols/"+t.symbol+"/raw"},t.prototype.ngOnDestroy=function(){this.subscription.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(e1),da(yot),da(tit),da(a9))},t.\u0275cmp=Ht({type:t,selectors:[["app-template"]],inputs:{server:"server",project:"project"},outputs:{onNodeCreation:"onNodeCreation"},decls:18,vars:9,consts:[["matTooltip","Add a node","matTooltipClass","custom-tooltip","mat-icon-button","",1,"addNode",3,"matMenuTriggerFor"],["mainMenu","matMenu"],["mat-menu-item","",3,"click"],["floatPlaceholder","never",1,"form-field",3,"click"],["matInput","","placeholder","Search by name",3,"ngModel","ngModelOptions","keyup","ngModelChange"],[1,"form-field",3,"click"],["placeholder","Filter templates by type",3,"ngModelOptions","ngModel","selectionChange","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"menu"],[1,"templateList"],[4,"ngFor","ngForOf"],[3,"value"],["class","templateRow",4,"ngIf"],[1,"templateRow"],[1,"templateIcon"],["mwlDraggable","",3,"dragStart","dragEnd"],[1,"image",3,"src"],[1,"templateText"],["class","templateIcon",4,"ngIf"]],template:function(t,e){1&t&&(ga(0,"button",0),ga(1,"mat-icon"),ds(2,"add_to_queue"),va(),va(),ga(3,"mat-menu",null,1),ga(5,"button",2),xa("click",(function(){return e.openDialog()})),ga(6,"mat-icon"),ds(7,"add"),va(),ga(8,"span"),ds(9,"Open dialog to configure"),va(),va(),ga(10,"mat-form-field",3),xa("click",(function(t){return t.stopPropagation()})),ga(11,"input",4),xa("keyup",(function(t){return e.filterTemplates(t)}))("ngModelChange",(function(t){return e.searchText=t})),va(),va(),ga(12,"mat-form-field",5),xa("click",(function(t){return t.stopPropagation()})),ga(13,"mat-select",6),xa("selectionChange",(function(t){return e.filterTemplates(t)}))("ngModelChange",(function(t){return e.selectedType=t})),ua(14,Zct,2,2,"mat-option",7),va(),va(),ga(15,"div",8),ga(16,"div",9),ua(17,elt,2,1,"mat-list-item",10),va(),va(),va()),2&t&&(pa("matMenuTriggerFor",ha(4)),Qi(11),pa("ngModel",e.searchText)("ngModelOptions",jc(7,nlt)),Qi(2),pa("ngModelOptions",jc(8,nlt))("ngModel",e.selectedType),Qi(1),pa("ngForOf",e.templateTypes),Qi(3),pa("ngForOf",e.filteredTemplates))},directives:[a2,k4,N0,x2,D0,E0,Y3,s5,cf,mf,Sp,O5,Eh,EJ,S8,Ah,Wct],styles:[".mat-menu-panel{max-width:400px;max-height:500px}.menu[_ngcontent-%COMP%]{width:100%;overflow-y:scroll;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}.form-field[_ngcontent-%COMP%]{width:90%;margin-left:5%;margin-right:5%}.image[_ngcontent-%COMP%]{width:65px;height:65px;-webkit-filter:invert(0);filter:invert(0);--webkit-filter:invert(0)!important}.templateList[_ngcontent-%COMP%]{width:100%}.templateRow[_ngcontent-%COMP%]{display:flex;margin-bottom:10px}.templateText[_ngcontent-%COMP%]{word-wrap:break-word}.templateIcon[_ngcontent-%COMP%]{width:80px!important;padding:10px}"]}),t}(),rlt=function(){return function(){}}(),olt=function(){function t(t){this.httpServer=t}return t.prototype.create=function(t,e,n){return this.httpServer.post(t,"/projects/"+e+"/snapshots",n)},t.prototype.delete=function(t,e,n){return this.httpServer.delete(t,"/projects/"+e+"/snapshots/"+n)},t.prototype.list=function(t,e){return this.httpServer.get(t,"/projects/"+e+"/snapshots")},t.prototype.restore=function(t,e,n){return this.httpServer.post(t,"/projects/"+e+"/snapshots/"+n+"/restore",{})},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),alt=function(){function t(t,e,n,i,r,o){var a=this;this.dialogRef=t,this.formBuilder=e,this.toasterService=n,this.snapshotService=i,this.nodesDataSource=r,this.data=o,this.snapshot=new rlt,this.snapshots=[],this.server=o.server,this.project=o.project,this.inputForm=this.formBuilder.group({snapshotName:new hp("",kf.required)}),this.snapshotService.list(this.server,this.project.project_id).subscribe((function(t){t.forEach((function(t){a.snapshots.push(t.name)}))})),this.nodesDataSource.getItems().forEach((function(t){"stopped"===t.status||a.isAlwaysRunningNode(t.node_type)||(a.isInRunningState=!0)}))}return t.prototype.isAlwaysRunningNode=function(t){return!["qemu","docker","dynamips","vpcs","vmware","virtualbox","iou","traceng"].includes(t)},t.prototype.onAddClick=function(){this.inputForm.invalid?this.toasterService.error("Fill all required fields"):this.snapshots.includes(this.inputForm.get("snapshotName").value)?this.toasterService.error("Snapshot with this name already exists"):this.isInRunningState?this.toasterService.error("Project must be stopped in order to export it"):(this.snapshot.name=this.inputForm.get("snapshotName").value,this.dialogRef.close(this.snapshot))},t.prototype.onNoClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(Jp),da(Y2),da(olt),da(M9),da(Q0))},t.\u0275cmp=Ht({type:t,selectors:[["app-create-snapshot-dialog"]],decls:14,vars:3,consts:[[1,"title-container"],["mat-dialog-title",""],["mat-button","","color","accent",1,"top-button",3,"routerLink","click"],["mat-dialog-content",""],[3,"formGroup"],[1,"name-input"],["matInput","","tabindex","1","formControlName","snapshotName","placeholder","Name"],["mat-dialog-actions",""],["mat-button","","tabindex","-1","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"h1",1),ds(2,"Create snapshot"),va(),ga(3,"button",2),xa("click",(function(){return e.onNoClick()})),ds(4,"Go to snapshots"),va(),va(),ga(5,"div",3),ga(6,"form",4),ga(7,"mat-form-field",5),ba(8,"input",6),va(),va(),va(),ga(9,"div",7),ga(10,"button",8),xa("click",(function(){return e.onNoClick()})),ds(11,"No Thanks"),va(),ga(12,"button",9),xa("click",(function(){return e.onAddClick()})),ds(13,"Add"),va(),va()),2&t&&(Qi(3),Fa("routerLink","/server/",e.server.id,"/project/",e.project.project_id,"/snapshots"),Qi(3),pa("formGroup",e.inputForm))},directives:[r1,a2,hQ,o1,xp,gf,Pp,Y3,s5,cf,mf,Fp,a1],styles:[".title-container[_ngcontent-%COMP%]{display:flex;align-items:baseline;justify-content:space-between}.name-input[_ngcontent-%COMP%]{width:100%}.top-button[_ngcontent-%COMP%]{outline:none;background:transparent!important}.top-button[_ngcontent-%COMP%], button[_ngcontent-%COMP%]:focus{box-shadow:none!important}button[_ngcontent-%COMP%]:focus{outline:0!important;border:0!important}"]}),t}(),slt=["primaryValueBar"],clt=tJ((function t(e){Object(m.a)(this,t),this._elementRef=e}),"primary"),llt=new ht("mat-progress-bar-location",{providedIn:"root",factory:function(){var t=wt(du),e=t?t.location:null;return{getPathname:function(){return e?e.pathname+e.search:""}}}}),ult=0,hlt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;Object(m.a)(this,n),(a=e.call(this,t))._elementRef=t,a._ngZone=i,a._animationMode=r,a._isNoopAnimation=!1,a._value=0,a._bufferValue=0,a.animationEnd=new Uc,a._animationEndSubscription=_.a.EMPTY,a.mode="determinate",a.progressbarId="mat-progress-bar-".concat(ult++);var s=o?o.getPathname().split("#")[0]:"";return a._rectangleFillValue="url('".concat(s,"#").concat(a.progressbarId,"')"),a._isNoopAnimation="NoopAnimations"===r,a}return Object(g.a)(n,[{key:"_primaryTransform",value:function(){return{transform:"scaleX(".concat(this.value/100,")")}}},{key:"_bufferTransform",value:function(){return"buffer"===this.mode?{transform:"scaleX(".concat(this.bufferValue/100,")")}:null}},{key:"ngAfterViewInit",value:function(){var t=this;this._ngZone.runOutsideAngular((function(){var e=t._primaryValueBar.nativeElement;t._animationEndSubscription=Object(IJ.a)(e,"transitionend").pipe(Object(vg.a)((function(t){return t.target===e}))).subscribe((function(){"determinate"!==t.mode&&"buffer"!==t.mode||t._ngZone.run((function(){return t.animationEnd.next({value:t.value})}))}))}))}},{key:"ngOnDestroy",value:function(){this._animationEndSubscription.unsubscribe()}},{key:"value",get:function(){return this._value},set:function(t){this._value=dlt(im(t)||0)}},{key:"bufferValue",get:function(){return this._bufferValue},set:function(t){this._bufferValue=dlt(t||0)}}]),n}(clt);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(jl),da(Cy,8),da(llt,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-progress-bar"]],viewQuery:function(t,e){var n;1&t&&nl(slt,!0),2&t&&tl(n=sl())&&(e._primaryValueBar=n.first)},hostAttrs:["role","progressbar","aria-valuemin","0","aria-valuemax","100",1,"mat-progress-bar"],hostVars:4,hostBindings:function(t,e){2&t&&(oa("aria-valuenow","indeterminate"===e.mode||"query"===e.mode?null:e.value)("mode",e.mode),Qa("_mat-animation-noopable",e._isNoopAnimation))},inputs:{color:"color",mode:"mode",value:"value",bufferValue:"bufferValue"},outputs:{animationEnd:"animationEnd"},exportAs:["matProgressBar"],features:[ws],decls:9,vars:4,consts:[["width","100%","height","4","focusable","false",1,"mat-progress-bar-background","mat-progress-bar-element"],["x","4","y","0","width","8","height","4","patternUnits","userSpaceOnUse",3,"id"],["cx","2","cy","2","r","2"],["width","100%","height","100%"],[1,"mat-progress-bar-buffer","mat-progress-bar-element",3,"ngStyle"],[1,"mat-progress-bar-primary","mat-progress-bar-fill","mat-progress-bar-element",3,"ngStyle"],["primaryValueBar",""],[1,"mat-progress-bar-secondary","mat-progress-bar-fill","mat-progress-bar-element"]],template:function(t,e){1&t&&(Qe(),ga(0,"svg",0),ga(1,"defs"),ga(2,"pattern",1),ba(3,"circle",2),va(),va(),ba(4,"rect",3),va(),$e(),ba(5,"div",4),ba(6,"div",5,6),ba(8,"div",7)),2&t&&(Qi(2),pa("id",e.progressbarId),Qi(2),oa("fill",e._rectangleFillValue),Qi(1),pa("ngStyle",e._bufferTransform()),Qi(1),pa("ngStyle",e._primaryTransform()))},directives:[Hh],styles:['.mat-progress-bar{display:block;height:4px;overflow:hidden;position:relative;transition:opacity 250ms linear;width:100%}._mat-animation-noopable.mat-progress-bar{transition:none;animation:none}.mat-progress-bar .mat-progress-bar-element,.mat-progress-bar .mat-progress-bar-fill::after{height:100%;position:absolute;width:100%}.mat-progress-bar .mat-progress-bar-background{width:calc(100% + 10px)}.cdk-high-contrast-active .mat-progress-bar .mat-progress-bar-background{display:none}.mat-progress-bar .mat-progress-bar-buffer{transform-origin:top left;transition:transform 250ms ease}.cdk-high-contrast-active .mat-progress-bar .mat-progress-bar-buffer{border-top:solid 5px;opacity:.5}.mat-progress-bar .mat-progress-bar-secondary{display:none}.mat-progress-bar .mat-progress-bar-fill{animation:none;transform-origin:top left;transition:transform 250ms ease}.cdk-high-contrast-active .mat-progress-bar .mat-progress-bar-fill{border-top:solid 4px}.mat-progress-bar .mat-progress-bar-fill::after{animation:none;content:"";display:inline-block;left:0}.mat-progress-bar[dir=rtl],[dir=rtl] .mat-progress-bar{transform:rotateY(180deg)}.mat-progress-bar[mode=query]{transform:rotateZ(180deg)}.mat-progress-bar[mode=query][dir=rtl],[dir=rtl] .mat-progress-bar[mode=query]{transform:rotateZ(180deg) rotateY(180deg)}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-fill,.mat-progress-bar[mode=query] .mat-progress-bar-fill{transition:none}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-primary,.mat-progress-bar[mode=query] .mat-progress-bar-primary{-webkit-backface-visibility:hidden;backface-visibility:hidden;animation:mat-progress-bar-primary-indeterminate-translate 2000ms infinite linear;left:-145.166611%}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-primary.mat-progress-bar-fill::after,.mat-progress-bar[mode=query] .mat-progress-bar-primary.mat-progress-bar-fill::after{-webkit-backface-visibility:hidden;backface-visibility:hidden;animation:mat-progress-bar-primary-indeterminate-scale 2000ms infinite linear}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-secondary,.mat-progress-bar[mode=query] .mat-progress-bar-secondary{-webkit-backface-visibility:hidden;backface-visibility:hidden;animation:mat-progress-bar-secondary-indeterminate-translate 2000ms infinite linear;left:-54.888891%;display:block}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-secondary.mat-progress-bar-fill::after,.mat-progress-bar[mode=query] .mat-progress-bar-secondary.mat-progress-bar-fill::after{-webkit-backface-visibility:hidden;backface-visibility:hidden;animation:mat-progress-bar-secondary-indeterminate-scale 2000ms infinite linear}.mat-progress-bar[mode=buffer] .mat-progress-bar-background{-webkit-backface-visibility:hidden;backface-visibility:hidden;animation:mat-progress-bar-background-scroll 250ms infinite linear;display:block}.mat-progress-bar._mat-animation-noopable .mat-progress-bar-fill,.mat-progress-bar._mat-animation-noopable .mat-progress-bar-fill::after,.mat-progress-bar._mat-animation-noopable .mat-progress-bar-buffer,.mat-progress-bar._mat-animation-noopable .mat-progress-bar-primary,.mat-progress-bar._mat-animation-noopable .mat-progress-bar-primary.mat-progress-bar-fill::after,.mat-progress-bar._mat-animation-noopable .mat-progress-bar-secondary,.mat-progress-bar._mat-animation-noopable .mat-progress-bar-secondary.mat-progress-bar-fill::after,.mat-progress-bar._mat-animation-noopable .mat-progress-bar-background{animation:none;transition-duration:1ms}@keyframes mat-progress-bar-primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(83.67142%)}100%{transform:translateX(200.611057%)}}@keyframes mat-progress-bar-primary-indeterminate-scale{0%{transform:scaleX(0.08)}36.65%{animation-timing-function:cubic-bezier(0.334731, 0.12482, 0.785844, 1);transform:scaleX(0.08)}69.15%{animation-timing-function:cubic-bezier(0.06, 0.11, 0.6, 1);transform:scaleX(0.661479)}100%{transform:scaleX(0.08)}}@keyframes mat-progress-bar-secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(84.386165%)}100%{transform:translateX(160.277782%)}}@keyframes mat-progress-bar-secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:scaleX(0.08)}19.15%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:scaleX(0.457104)}44.15%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:scaleX(0.72796)}100%{transform:scaleX(0.08)}}@keyframes mat-progress-bar-background-scroll{to{transform:translateX(-8px)}}\n'],encapsulation:2,changeDetection:0}),t}();function dlt(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:100;return Math.max(e,Math.min(n,t))}var flt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd,$$],$$]}),t}(),plt=function(){function t(t,e){this.dialogRef=t,this.data=e}return t.prototype.onCancelClick=function(){this.dialogRef.close(t.CANCELLED)},t.prototype.ngOnInit=function(){},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(Q0))},t.\u0275cmp=Ht({type:t,selectors:[["app-progress-dialog"]],decls:7,vars:1,consts:[["mat-dialog-title",""],["mat-dialog-content",""],["color","primary","mode","determinate",3,"value"],["mat-dialog-actions",""],["mat-button","","tabindex","-1","color","accent",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Operation in progress"),va(),ga(2,"div",1),ba(3,"mat-progress-bar",2),va(),ga(4,"div",3),ga(5,"button",4),xa("click",(function(){return e.onCancelClick()})),ds(6,"Cancel"),va(),va()),2&t&&(Qi(3),pa("value",e.value))},directives:[r1,o1,hlt,a1,a2],styles:[""]}),t}(),mlt=function(){function t(t){this.dialog=t}return t.prototype.open=function(){return this.dialog.open(plt,{width:"250px",autoFocus:!1,disableClose:!0})},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(e1))}}),t}(),glt=function(){function t(t,e,n,i){this.dialog=t,this.snapshotService=e,this.progressDialogService=n,this.toaster=i}return t.prototype.ngOnInit=function(){},t.prototype.createSnapshotModal=function(){var t=this;this.dialog.open(alt,{width:"450px",data:{server:this.server,project:this.project},autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(e){if(e){var n=t.snapshotService.create(t.server,t.project.project_id,e),i=t.progressDialogService.open(),r=n.subscribe((function(n){t.toaster.success("Snapshot '"+e.name+"' has been created."),i.close()}));i.afterClosed().subscribe((function(t){t===plt.CANCELLED&&r.unsubscribe()}))}}))},t.\u0275fac=function(e){return new(e||t)(da(e1),da(olt),da(mlt),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-snapshot-menu-item"]],inputs:{project:"project",server:"server"},decls:3,vars:0,consts:[["matTooltip","Manage snapshots","matTooltipClass","custom-tooltip","mat-icon-button","",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.createSnapshotModal()})),ga(1,"mat-icon"),ds(2,"snooze"),va(),va())},directives:[a2,k4,x2],styles:[""]}),t}(),vlt=function(){function t(t,e,n,i,r,o){this.nodeService=t,this.nodesDataSource=e,this.toasterService=n,this.serverService=i,this.settingsService=r,this.electronService=o}return t.prototype.startConsoleForAllNodes=function(){return UQ(this,void 0,void 0,(function(){var t,e,n,i,r,o;return qQ(this,(function(a){switch(a.label){case 0:if(!this.electronService.isElectronApp)return[3,5];t=this.settingsService.get("console_command")?this.settingsService.get("console_command"):this.nodeService.getDefaultCommand(),e=this.nodesDataSource.getItems(),n=0,i=e,a.label=1;case 1:return n<i.length?(o={command:t,type:(r=i[n]).console_type,host:r.console_host,port:r.console,name:r.name,project_id:r.project_id,node_id:r.node_id,server_url:this.serverService.getServerUrl(this.server)},[4,this.electronService.remote.require("./console-executor.js").openConsole(o)]):[3,4];case 2:a.sent(),a.label=3;case 3:return n++,[3,1];case 4:return[3,6];case 5:this.toasterService.error("Option to start all nodes not available in web browser."),a.label=6;case 6:return[2]}}))}))},t.prototype.startNodes=function(){var t=this;this.nodeService.startAll(this.server,this.project).subscribe((function(){t.toasterService.success("All nodes successfully started")}))},t.prototype.stopNodes=function(){var t=this;this.nodeService.stopAll(this.server,this.project).subscribe((function(){t.toasterService.success("All nodes successfully stopped")}))},t.prototype.suspendNodes=function(){var t=this;this.nodeService.suspendAll(this.server,this.project).subscribe((function(){t.toasterService.success("All nodes successfully suspended")}))},t.prototype.reloadNodes=function(){var t=this;this.nodeService.reloadAll(this.server,this.project).subscribe((function(){t.toasterService.success("All nodes successfully reloaded")}))},t.\u0275fac=function(e){return new(e||t)(da(E2),da(M9),da(Y2),da(ZQ),da(QQ),da(mX))},t.\u0275cmp=Ht({type:t,selectors:[["app-nodes-menu"]],inputs:{project:"project",server:"server"},decls:15,vars:0,consts:[["matTooltip","Console connect to all nodes","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["matTooltip","Start/Resume all nodes","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["matTooltip","Suspend all nodes","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["matTooltip","Stop all nodes","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"],["matTooltip","Reload all nodes","matTooltipClass","custom-tooltip","mat-icon-button","",1,"menu-button",3,"click"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.startConsoleForAllNodes()})),ga(1,"mat-icon"),ds(2,"web_asset"),va(),va(),ga(3,"button",1),xa("click",(function(){return e.startNodes()})),ga(4,"mat-icon"),ds(5,"play_arrow"),va(),va(),ga(6,"button",2),xa("click",(function(){return e.suspendNodes()})),ga(7,"mat-icon"),ds(8,"pause"),va(),va(),ga(9,"button",3),xa("click",(function(){return e.stopNodes()})),ga(10,"mat-icon"),ds(11,"stop"),va(),va(),ga(12,"button",4),xa("click",(function(){return e.reloadNodes()})),ga(13,"mat-icon"),ds(14,"replay"),va(),va())},directives:[a2,k4,x2],styles:[".menu-button[_ngcontent-%COMP%]{outline:0!important;transition:.5s;margin-bottom:16px;width:40px;margin-right:12px!important;margin-left:12px!important;background:transparent;padding:0;border:none;background-color:transparent}.marked[_ngcontent-%COMP%]{color:#0097a7!important}"],changeDetection:0}),t}(),blt=function(){function t(t,e,n,i,r,o){this.hotkeysService=t,this.toaster=e,this.nodesService=n,this.projectService=i,this.mapNodeToNode=r,this.selectionManager=o}return t.prototype.ngOnInit=function(){var t=this;this.deleteHotkey=new ZK("del",(function(e){return t.onDeleteHandler(e)})),this.hotkeysService.add(this.deleteHotkey)},t.prototype.onDeleteHandler=function(t){var e=this;return this.projectService.isReadOnly(this.project)||this.selectionManager.getSelected().filter((function(t){return t instanceof ket})).forEach((function(t){var n=e.mapNodeToNode.convert(t);e.nodesService.delete(e.server,n).subscribe((function(t){e.toaster.success("Node has been deleted")}))})),!1},t.prototype.ngOnDestroy=function(){this.hotkeysService.remove(this.deleteHotkey)},t.\u0275fac=function(e){return new(e||t)(da($K),da(Y2),da(E2),da($Q),da(jnt),da(Zet))},t.\u0275cmp=Ht({type:t,selectors:[["app-project-map-shortcuts"]],inputs:{project:"project",server:"server"},decls:0,vars:0,template:function(t,e){},encapsulation:2}),t}();function ylt(t,e){1&t&&(Qe(),ga(0,"svg",9),ba(1,"rect",10),va())}function _lt(t,e){1&t&&(Qe(),ga(0,"svg",9),ba(1,"rect",11),va())}function wlt(t,e){if(1&t){var n=ka();ga(0,"button",6),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(2).chooseInterface(t)})),ua(1,ylt,2,0,"svg",7),ua(2,_lt,2,0,"svg",7),ga(3,"span",8),ds(4),va(),va()}if(2&t){var i=e.$implicit;pa("disabled",!i.available),Qi(1),pa("ngIf",i.available),Qi(1),pa("ngIf",!i.available),Qi(2),fs(i.name)}}function klt(t,e){if(1&t&&(ga(0,"div",1),ba(1,"span",2),ga(2,"mat-menu",3,4),ua(4,wlt,5,4,"button",5),va(),va()),2&t){var n=ha(3),i=Aa();Za("left",i.leftPosition)("top",i.topPosition),Qi(1),pa("matMenuTriggerFor",n),Qi(1),Za("min-height",0),Qi(2),pa("ngForOf",i.ports)}}var Clt=function(){function t(t,e){this.sanitizer=t,this.changeDetector=e,this.onChooseInterface=new Uc}return t.prototype.ngOnInit=function(){this.setPosition(0,0)},t.prototype.setPosition=function(t,e){this.topPosition=this.sanitizer.bypassSecurityTrustStyle(t+"px"),this.leftPosition=this.sanitizer.bypassSecurityTrustStyle(e+"px"),this.changeDetector.detectChanges()},t.prototype.open=function(t,e,n){this.node=t,this.filterNodePorts(),this.setPosition(e,n),this.contextMenu.openMenu()},t.prototype.filterNodePorts=function(){var t=this,e=[];this.links.forEach((function(n){n.nodes.forEach((function(n){n.node_id===t.node.node_id&&e.push(n)}))})),this.ports=[],this.node.ports.forEach((function(n){var i=e.filter((function(t){return t.adapter_number===n.adapter_number}));n.available=0===i.length||0===i.filter((function(t){return t.port_number===n.port_number})).length,t.ports.push(n)}))},t.prototype.chooseInterface=function(t){this.onChooseInterface.emit({node:this.node,port:t})},t.\u0275fac=function(e){return new(e||t)(da(Vd),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["app-node-select-interface"]],viewQuery:function(t,e){var n;1&t&&nl(N0,!0),2&t&&tl(n=sl())&&(e.contextMenu=n.first)},inputs:{links:"links"},outputs:{onChooseInterface:"onChooseInterface"},decls:1,vars:1,consts:[["class","context-menu",3,"left","top",4,"ngIf"],[1,"context-menu"],[3,"matMenuTriggerFor"],[1,"context-menu-items"],["selectInterfaceMenu","matMenu"],["mat-menu-item","",3,"disabled","click",4,"ngFor","ngForOf"],["mat-menu-item","",3,"disabled","click"],["width","10","height","10",4,"ngIf"],[1,"port"],["width","10","height","10"],["x","0","y","0","width","10","height","10","fill","green",1,"status"],["x","0","y","0","width","10","height","10","fill","red",1,"status"]],template:function(t,e){1&t&&ua(0,klt,5,8,"div",0),2&t&&pa("ngIf",e.node)},directives:[Ah,N0,D0,Eh,E0],styles:[".context-menu[_ngcontent-%COMP%]{position:absolute}.context-menu-items[_ngcontent-%COMP%]{min-height:0!important}.status[_ngcontent-%COMP%]{margin-right:10px}.port[_ngcontent-%COMP%]{margin-left:10px}"]}),t}(),Slt=function(){return function(t,e,n,i){this.sourceNode=t,this.sourcePort=e,this.targetNode=n,this.targetPort=i}}(),xlt=function(){function t(t,e,n,i,r,o){this.drawingLineTool=t,this.nodesEventSource=e,this.linksEventSource=n,this.mapNodeToNode=i,this.nodeToMapNode=r,this.portToMapPort=o}return t.prototype.ngOnInit=function(){var t=this;this.nodeClicked$=this.nodesEventSource.clicked.subscribe((function(e){var n=t.mapNodeToNode.convert(e.datum);t.nodeSelectInterfaceMenu.open(n,e.y,e.x)}))},t.prototype.ngOnDestroy=function(){this.drawingLineTool.isDrawing()&&this.drawingLineTool.stop(),this.nodeClicked$.unsubscribe()},t.prototype.onChooseInterface=function(t){var e=this.nodeToMapNode.convert(t.node),n=this.portToMapPort.convert(t.port);if(this.drawingLineTool.isDrawing()){var i=this.drawingLineTool.stop();this.linksEventSource.created.emit(new Slt(i.node,i.port,e,n))}else this.drawingLineTool.start(e.x+e.width/2,e.y+e.height/2,{node:e,port:n})},t.\u0275fac=function(e){return new(e||t)(da(Rnt),da(pnt),da(dit),da(jnt),da(Pet),da(Eet))},t.\u0275cmp=Ht({type:t,selectors:[["app-draw-link-tool"]],viewQuery:function(t,e){var n;1&t&&nl(Clt,!0),2&t&&tl(n=sl())&&(e.nodeSelectInterfaceMenu=n.first)},inputs:{links:"links"},decls:1,vars:1,consts:[[3,"links","onChooseInterface"]],template:function(t,e){1&t&&(ga(0,"app-node-select-interface",0),xa("onChooseInterface",(function(t){return e.onChooseInterface(t)})),va()),2&t&&pa("links",e.links)},directives:[Clt],styles:[""]}),t}();function Olt(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:3,i=Math.abs(t-e);return i<n}function Mlt(t,e,n,i){var r={top:t.top,bottom:t.bottom,left:t.left,right:t.right};return e.top&&(r.top+=i),e.bottom&&(r.bottom+=i),e.left&&(r.left+=n),e.right&&(r.right+=n),r.height=r.bottom-r.top,r.width=r.right-r.left,r}function Tlt(t){var e=t.clientY,n=t.rect;return e>=n.top&&e<=n.bottom}function Elt(t){var e=t.clientX,n=t.rect;return e>=n.left&&e<=n.right}function Plt(t){var e=t.clientX,n=t.clientY,i=t.allowedEdges,r=t.cursorPrecision,o=t.elm.nativeElement.getBoundingClientRect(),a={};return i.left&&Olt(e,o.left,r)&&Tlt({clientY:n,rect:o})&&(a.left=!0),i.right&&Olt(e,o.right,r)&&Tlt({clientY:n,rect:o})&&(a.right=!0),i.top&&Olt(n,o.top,r)&&Elt({clientX:e,rect:o})&&(a.top=!0),i.bottom&&Olt(n,o.bottom,r)&&Elt({clientX:e,rect:o})&&(a.bottom=!0),a}var Alt=Object.freeze({topLeft:"nw-resize",topRight:"ne-resize",bottomLeft:"sw-resize",bottomRight:"se-resize",leftOrRight:"col-resize",topOrBottom:"row-resize"});function jlt(t,e){return t.left&&t.top?e.topLeft:t.right&&t.top?e.topRight:t.left&&t.bottom?e.bottomLeft:t.right&&t.bottom?e.bottomRight:t.left||t.right?e.leftOrRight:t.top||t.bottom?e.topOrBottom:""}function Ilt(t){var e=t.initialRectangle,n=t.newRectangle,i={};return Object.keys(t.edges).forEach((function(t){i[t]=(n[t]||0)-(e[t]||0)})),i}var Dlt=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this.platformId=e,this.renderer=n,this.elm=i,this.zone=r,this.resizeEdges={},this.enableGhostResize=!1,this.resizeSnapGrid={},this.resizeCursors=Alt,this.resizeCursorPrecision=3,this.ghostElementPositioning="fixed",this.allowNegativeResizes=!1,this.mouseMoveThrottleMS=50,this.resizeStart=new Uc,this.resizing=new Uc,this.resizeEnd=new Uc,this.mouseup=new w.b,this.mousedown=new w.b,this.mousemove=new w.b,this.destroy$=new w.b,this.resizeEdges$=new w.b,this.pointerEventListeners=Rlt.getInstance(n,r)}return Object(g.a)(t,[{key:"ngOnInit",value:function(){var t,e=this,n=Object(C.a)(this.pointerEventListeners.pointerDown,this.mousedown),i=Object(C.a)(this.pointerEventListeners.pointerMove,this.mousemove).pipe(Object(DX.a)((function(e){t&&e.event.preventDefault()})),Object(S.a)()),r=Object(C.a)(this.pointerEventListeners.pointerUp,this.mouseup),o=function(){t&&t.clonedNode&&(e.elm.nativeElement.parentElement.removeChild(t.clonedNode),e.renderer.setStyle(e.elm.nativeElement,"visibility","inherit"))},a=function(){return Object.assign({},Alt,e.resizeCursors)};this.resizeEdges$.pipe(Object(NX.a)(this.resizeEdges),Object(ef.a)((function(){return e.resizeEdges&&Object.keys(e.resizeEdges).some((function(t){return!!e.resizeEdges[t]}))})),Object(LX.a)((function(t){return t?i:TX.a})),Object(LJ.a)(this.mouseMoveThrottleMS),Object(Am.a)(this.destroy$)).subscribe((function(n){var i=Plt({clientX:n.clientX,clientY:n.clientY,elm:e.elm,allowedEdges:e.resizeEdges,cursorPrecision:e.resizeCursorPrecision}),r=a();if(!t){var o=jlt(i,r);e.renderer.setStyle(e.elm.nativeElement,"cursor",o)}e.setElementClass(e.elm,"resize-left-hover",!0===i.left),e.setElementClass(e.elm,"resize-right-hover",!0===i.right),e.setElementClass(e.elm,"resize-top-hover",!0===i.top),e.setElementClass(e.elm,"resize-bottom-hover",!0===i.bottom)})),n.pipe(Object(IX.a)((function(o){function a(t){return{clientX:t.clientX-o.clientX,clientY:t.clientY-o.clientY}}var s=function(){var n={x:1,y:1};return t&&(e.resizeSnapGrid.left&&t.edges.left?n.x=+e.resizeSnapGrid.left:e.resizeSnapGrid.right&&t.edges.right&&(n.x=+e.resizeSnapGrid.right),e.resizeSnapGrid.top&&t.edges.top?n.y=+e.resizeSnapGrid.top:e.resizeSnapGrid.bottom&&t.edges.bottom&&(n.y=+e.resizeSnapGrid.bottom)),n};function c(t,e){return{x:Math.ceil(t.clientX/e.x),y:Math.ceil(t.clientY/e.y)}}return Object(C.a)(i.pipe(Object(FX.a)(1)).pipe(Object(ef.a)((function(t){return[,t]}))),i.pipe(Object(FJ.a)())).pipe(Object(ef.a)((function(t){var e=l(t,2),n=e[0],i=e[1];return[n?a(n):n,a(i)]}))).pipe(Object(vg.a)((function(t){var e=l(t,2),n=e[0],i=e[1];if(!n)return!0;var r=s(),o=c(n,r),a=c(i,r);return o.x!==a.x||o.y!==a.y}))).pipe(Object(ef.a)((function(t){var e=l(t,2)[1],n=s();return{clientX:Math.round(e.clientX/n.x)*n.x,clientY:Math.round(e.clientY/n.y)*n.y}}))).pipe(Object(Am.a)(Object(C.a)(r,n)))}))).pipe(Object(vg.a)((function(){return!!t}))).pipe(Object(ef.a)((function(e){return Mlt(t.startingRect,t.edges,e.clientX,e.clientY)}))).pipe(Object(vg.a)((function(t){return e.allowNegativeResizes||!!(t.height&&t.width&&t.height>0&&t.width>0)}))).pipe(Object(vg.a)((function(n){return!e.validateResize||e.validateResize({rectangle:n,edges:Ilt({edges:t.edges,initialRectangle:t.startingRect,newRectangle:n})})})),Object(Am.a)(this.destroy$)).subscribe((function(n){t&&t.clonedNode&&(e.renderer.setStyle(t.clonedNode,"height","".concat(n.height,"px")),e.renderer.setStyle(t.clonedNode,"width","".concat(n.width,"px")),e.renderer.setStyle(t.clonedNode,"top","".concat(n.top,"px")),e.renderer.setStyle(t.clonedNode,"left","".concat(n.left,"px"))),e.zone.run((function(){e.resizing.emit({edges:Ilt({edges:t.edges,initialRectangle:t.startingRect,newRectangle:n}),rectangle:n})})),t.currentRect=n})),n.pipe(Object(ef.a)((function(t){return t.edges||Plt({clientX:t.clientX,clientY:t.clientY,elm:e.elm,allowedEdges:e.resizeEdges,cursorPrecision:e.resizeCursorPrecision})}))).pipe(Object(vg.a)((function(t){return Object.keys(t).length>0})),Object(Am.a)(this.destroy$)).subscribe((function(n){t&&o();var i=function(t,e){var n=0,i=0,r=t.nativeElement.style,o=["transform","-ms-transform","-moz-transform","-o-transform"].map((function(t){return r[t]})).find((function(t){return!!t}));if(o&&o.includes("translate")&&(n=o.replace(/.*translate3?d?\(([0-9]*)px, ([0-9]*)px.*/,"$1"),i=o.replace(/.*translate3?d?\(([0-9]*)px, ([0-9]*)px.*/,"$2")),"absolute"===e)return{height:t.nativeElement.offsetHeight,width:t.nativeElement.offsetWidth,top:t.nativeElement.offsetTop-i,bottom:t.nativeElement.offsetHeight+t.nativeElement.offsetTop-i,left:t.nativeElement.offsetLeft-n,right:t.nativeElement.offsetWidth+t.nativeElement.offsetLeft-n};var a=t.nativeElement.getBoundingClientRect();return{height:a.height,width:a.width,top:a.top-i,bottom:a.bottom-i,left:a.left-n,right:a.right-n,scrollTop:t.nativeElement.scrollTop,scrollLeft:t.nativeElement.scrollLeft}}(e.elm,e.ghostElementPositioning);t={edges:n,startingRect:i,currentRect:i};var r=a(),s=jlt(t.edges,r);e.renderer.setStyle(document.body,"cursor",s),e.setElementClass(e.elm,"resize-active",!0),e.enableGhostResize&&(t.clonedNode=e.elm.nativeElement.cloneNode(!0),e.elm.nativeElement.parentElement.appendChild(t.clonedNode),e.renderer.setStyle(e.elm.nativeElement,"visibility","hidden"),e.renderer.setStyle(t.clonedNode,"position",e.ghostElementPositioning),e.renderer.setStyle(t.clonedNode,"left","".concat(t.startingRect.left,"px")),e.renderer.setStyle(t.clonedNode,"top","".concat(t.startingRect.top,"px")),e.renderer.setStyle(t.clonedNode,"height","".concat(t.startingRect.height,"px")),e.renderer.setStyle(t.clonedNode,"width","".concat(t.startingRect.width,"px")),e.renderer.setStyle(t.clonedNode,"cursor",jlt(t.edges,r)),e.renderer.addClass(t.clonedNode,"resize-ghost-element"),t.clonedNode.scrollTop=t.startingRect.scrollTop,t.clonedNode.scrollLeft=t.startingRect.scrollLeft),e.zone.run((function(){e.resizeStart.emit({edges:Ilt({edges:n,initialRectangle:i,newRectangle:i}),rectangle:Mlt(i,{},0,0)})}))})),r.pipe(Object(Am.a)(this.destroy$)).subscribe((function(){t&&(e.renderer.removeClass(e.elm.nativeElement,"resize-active"),e.renderer.setStyle(document.body,"cursor",""),e.renderer.setStyle(e.elm.nativeElement,"cursor",""),e.zone.run((function(){e.resizeEnd.emit({edges:Ilt({edges:t.edges,initialRectangle:t.startingRect,newRectangle:t.currentRect}),rectangle:t.currentRect})})),o(),t=null)}))}},{key:"ngOnChanges",value:function(t){t.resizeEdges&&this.resizeEdges$.next(this.resizeEdges)}},{key:"ngOnDestroy",value:function(){dd(this.platformId)&&this.renderer.setStyle(document.body,"cursor",""),this.mousedown.complete(),this.mouseup.complete(),this.mousemove.complete(),this.resizeEdges$.complete(),this.destroy$.next()}},{key:"setElementClass",value:function(t,e,n){n?this.renderer.addClass(t.nativeElement,e):this.renderer.removeClass(t.nativeElement,e)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(vl),da(Ks),da(Us),da(jl))},t.\u0275dir=Wt({type:t,selectors:[["","mwlResizable",""]],inputs:{resizeEdges:"resizeEdges",enableGhostResize:"enableGhostResize",resizeSnapGrid:"resizeSnapGrid",resizeCursors:"resizeCursors",resizeCursorPrecision:"resizeCursorPrecision",ghostElementPositioning:"ghostElementPositioning",allowNegativeResizes:"allowNegativeResizes",mouseMoveThrottleMS:"mouseMoveThrottleMS",validateResize:"validateResize"},outputs:{resizeStart:"resizeStart",resizing:"resizing",resizeEnd:"resizeEnd"},features:[Ms]}),t}(),Rlt=function(){function t(e,n){Object(m.a)(this,t),this.pointerDown=new k.a((function(t){var i,r;return n.runOutsideAngular((function(){i=e.listen("document","mousedown",(function(e){t.next({clientX:e.clientX,clientY:e.clientY,event:e})})),r=e.listen("document","touchstart",(function(e){t.next({clientX:e.touches[0].clientX,clientY:e.touches[0].clientY,event:e})}))})),function(){i(),r()}})).pipe(Object(S.a)()),this.pointerMove=new k.a((function(t){var i,r;return n.runOutsideAngular((function(){i=e.listen("document","mousemove",(function(e){t.next({clientX:e.clientX,clientY:e.clientY,event:e})})),r=e.listen("document","touchmove",(function(e){t.next({clientX:e.targetTouches[0].clientX,clientY:e.targetTouches[0].clientY,event:e})}))})),function(){i(),r()}})).pipe(Object(S.a)()),this.pointerUp=new k.a((function(t){var i,r,o;return n.runOutsideAngular((function(){i=e.listen("document","mouseup",(function(e){t.next({clientX:e.clientX,clientY:e.clientY,event:e})})),r=e.listen("document","touchend",(function(e){t.next({clientX:e.changedTouches[0].clientX,clientY:e.changedTouches[0].clientY,event:e})})),o=e.listen("document","touchcancel",(function(e){t.next({clientX:e.changedTouches[0].clientX,clientY:e.changedTouches[0].clientY,event:e})}))})),function(){i(),r(),o()}})).pipe(Object(S.a)())}return Object(g.a)(t,null,[{key:"getInstance",value:function(e,n){return t.instance||(t.instance=new t(e,n)),t.instance}}]),t}(),Llt=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this.renderer=e,this.element=n,this.zone=i,this.resizable=r,this.resizeEdges={},this.eventListeners={}}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this.unsubscribeEventListeners()}},{key:"onMousedown",value:function(t,e,n){var i=this;t.preventDefault(),this.zone.runOutsideAngular((function(){i.eventListeners.touchmove||(i.eventListeners.touchmove=i.renderer.listen(i.element.nativeElement,"touchmove",(function(t){i.onMousemove(t,t.targetTouches[0].clientX,t.targetTouches[0].clientY)}))),i.eventListeners.mousemove||(i.eventListeners.mousemove=i.renderer.listen(i.element.nativeElement,"mousemove",(function(t){i.onMousemove(t,t.clientX,t.clientY)}))),i.resizable.mousedown.next({clientX:e,clientY:n,edges:i.resizeEdges})}))}},{key:"onMouseup",value:function(t,e){var n=this;this.zone.runOutsideAngular((function(){n.unsubscribeEventListeners(),n.resizable.mouseup.next({clientX:t,clientY:e,edges:n.resizeEdges})}))}},{key:"onMousemove",value:function(t,e,n){this.resizable.mousemove.next({clientX:e,clientY:n,edges:this.resizeEdges,event:t})}},{key:"unsubscribeEventListeners",value:function(){var t=this;Object.keys(this.eventListeners).forEach((function(e){t.eventListeners[e](),delete t.eventListeners[e]}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Ks),da(Us),da(jl),da(Dlt))},t.\u0275dir=Wt({type:t,selectors:[["","mwlResizeHandle",""]],hostBindings:function(t,e){1&t&&xa("touchstart",(function(t){return e.onMousedown(t,t.touches[0].clientX,t.touches[0].clientY)}))("mousedown",(function(t){return e.onMousedown(t,t.clientX,t.clientY)}))("touchend",(function(t){return e.onMouseup(t.changedTouches[0].clientX,t.changedTouches[0].clientY)}))("touchcancel",(function(t){return e.onMouseup(t.changedTouches[0].clientX,t.changedTouches[0].clientY)}))("mouseup",(function(t){return e.onMouseup(t.clientX,t.clientY)}))},inputs:{resizeEdges:"resizeEdges"}}),t}(),Flt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}(),Nlt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.prototype.getItemKey=function(t){return t},e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return Blt(t||e)}}),e}(O9),Blt=zn(Nlt),Hlt=n("kiQV").version,zlt=["console"];function Vlt(t,e){if(1&t&&(ga(0,"span",12),ds(1),ba(2,"br"),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.message," ")}}var Ult=function(t){return{lightTheme:t}},qlt=function(){function t(t,e,n,i,r,o,a,s,c){this.projectWebServiceHandler=t,this.nodeService=e,this.nodesDataSource=n,this.logEventsDataSource=i,this.httpService=r,this.themeService=o,this.cd=a,this.nodeConsoleService=s,this.changeDetectorRef=c,this.version=Hlt,this.command="",this.filters=["all","errors","warnings","info","map updates","server requests"],this.selectedFilter="all",this.filteredEvents=[],this.regexStart=/^start (.*?)$/,this.regexStop=/^stop (.*?)$/,this.regexSuspend=/^suspend (.*?)$/,this.regexReload=/^reload (.*?)$/,this.regexShow=/^show (.*?)$/,this.regexConsole=/^console (.*?)$/,this.style={},this.isDraggingEnabled=!1,this.isLightThemeEnabled=!1,this.selected=new hp(0)}return t.prototype.ngOnInit=function(){var t=this;this.nodeConsoleService.consoleResized.subscribe((function(e){t.style={bottom:"20px",left:"20px",width:e.width+"px",height:e.height-70+"px"},t.changeDetectorRef.detectChanges()})),this.isLightThemeEnabled="light"===this.themeService.getActualTheme(),this.style={bottom:"20px",left:"20px",width:"720px",height:"340px"},this.nodeSubscription=this.projectWebServiceHandler.nodeNotificationEmitter.subscribe((function(e){var n,i=e.event;n=i.label?"Event received: "+e.action+" - "+t.printNode(i)+".":"Event received: "+e.action+" - "+i.name+".",t.showMessage({type:"map update",message:n})})),this.linkSubscription=this.projectWebServiceHandler.linkNotificationEmitter.subscribe((function(e){var n="Event received: "+e.action+" - "+t.printLink(e.event)+".";t.showMessage({type:"map update",message:n})})),this.drawingSubscription=this.projectWebServiceHandler.drawingNotificationEmitter.subscribe((function(e){var n="Event received: "+e.action+" - "+t.printDrawing(e.event)+".";t.showMessage({type:"map update",message:n})})),this.serverRequestsSubscription=this.httpService.requestsNotificationEmitter.subscribe((function(e){t.showMessage({type:"server request",message:e})})),this.errorSubscription=this.projectWebServiceHandler.errorNotificationEmitter.subscribe((function(e){t.showMessage({type:"error",message:e})})),this.warningSubscription=this.projectWebServiceHandler.warningNotificationEmitter.subscribe((function(e){t.showMessage({type:"warning",message:e})})),this.infoSubscription=this.projectWebServiceHandler.infoNotificationEmitter.subscribe((function(e){t.showMessage({type:"info",message:e})}))},t.prototype.ngAfterViewInit=function(){this.console.nativeElement.scrollTop=this.console.nativeElement.scrollHeight},t.prototype.ngOnDestroy=function(){this.nodeSubscription.unsubscribe(),this.linkSubscription.unsubscribe(),this.drawingSubscription.unsubscribe(),this.serverRequestsSubscription.unsubscribe(),this.errorSubscription.unsubscribe(),this.warningSubscription.unsubscribe(),this.infoSubscription.unsubscribe()},t.prototype.applyFilter=function(t){this.selectedFilter=t,this.filteredEvents=this.getFilteredEvents(),this.cd.detectChanges()},t.prototype.onKeyDown=function(t){"Enter"===t.key&&this.handleCommand()},t.prototype.handleCommand=function(){var t=this;if("help"===this.command||""===this.command)this.showCommand("Available commands: help, version, console {node name}, start all, start {node name}, stop all, stop {node name}, suspend all, suspend {node name}, reload all, reload {node name}, show {node name}.");else if("version"===this.command)this.showCommand("Current version: "+this.version);else if("start all"===this.command)this.showCommand("Starting all nodes..."),this.nodeService.startAll(this.server,this.project).subscribe((function(){t.showCommand("All nodes started.")}));else if("stop all"===this.command)this.showCommand("Stopping all nodes..."),this.nodeService.stopAll(this.server,this.project).subscribe((function(){t.showCommand("All nodes stopped.")}));else if("suspend all"===this.command)this.showCommand("Suspending all nodes..."),this.nodeService.suspendAll(this.server,this.project).subscribe((function(){t.showCommand("All nodes suspended.")}));else if("reload all"===this.command)this.showCommand("Reloading all nodes..."),this.nodeService.reloadAll(this.server,this.project).subscribe((function(){t.showCommand("All nodes reloaded.")}));else if(this.regexStart.test(this.command)||this.regexStop.test(this.command)||this.regexSuspend.test(this.command)||this.regexReload.test(this.command)||this.regexShow.test(this.command)||this.regexConsole.test(this.command)){var e=this.command.split(/[ ,]+/),n=this.nodesDataSource.getItems().find((function(t){return t.name.valueOf()===e[1].valueOf()}));n?this.regexStart.test(this.command)?(this.showCommand("Starting node "+e[1]+"..."),this.nodeService.start(this.server,n).subscribe((function(){return t.showCommand("Node "+n.name+" started.")}))):this.regexStop.test(this.command)?(this.showCommand("Stopping node "+e[1]+"..."),this.nodeService.stop(this.server,n).subscribe((function(){return t.showCommand("Node "+n.name+" stopped.")}))):this.regexSuspend.test(this.command)?(this.showCommand("Suspending node "+e[1]+"..."),this.nodeService.suspend(this.server,n).subscribe((function(){return t.showCommand("Node "+n.name+" suspended.")}))):this.regexReload.test(this.command)?(this.showCommand("Reloading node "+e[1]+"..."),this.nodeService.reload(this.server,n).subscribe((function(){return t.showCommand("Node "+n.name+" reloaded.")}))):this.regexConsole.test(this.command)?"started"===n.status?(this.showCommand("Launching console for node "+e[1]+"..."),"telnet"===n.console_type?location.assign("gns3+telnet://"+n.console_host+":"+n.console+"?name="+n.name+"&project_id="+n.project_id+"&node_id="+n.node_id):"vnc"===n.console_type?location.assign("gns3+vnc://"+n.console_host+":"+n.console+"?name="+n.name+"&project_id="+n.project_id+"&node_id="+n.node_id):"spice"===n.console_type?location.assign("gns3+spice://"+n.console_host+":"+n.console+"?name="+n.name+"&project_id="+n.project_id+"&node_id="+n.node_id):this.showCommand("Supported console types: telnet, vnc, spice.")):this.showCommand("This node must be started before a console can be opened."):this.regexShow.test(this.command)&&(this.showCommand("Information about node "+n.name+":"),this.showCommand(this.printNode(n))):this.showCommand("Node with "+e[1]+" name was not found.")}else this.showCommand("Unknown syntax: "+this.command);this.command="",this.cd.detectChanges()},t.prototype.clearConsole=function(){this.filteredEvents=[],this.console.nativeElement.scrollTop=this.console.nativeElement.scrollHeight},t.prototype.showCommand=function(t){this.showMessage({type:"command",message:t})},t.prototype.showMessage=function(t){var e=this;this.logEventsDataSource.add(t),this.filteredEvents=this.getFilteredEvents(),this.console.nativeElement.scrollTop=this.console.nativeElement.scrollHeight,setTimeout((function(){e.console.nativeElement.scrollTop=e.console.nativeElement.scrollHeight}),100),this.cd.detectChanges()},t.prototype.getFilteredEvents=function(){return"server requests"===this.selectedFilter?this.logEventsDataSource.getItems().filter((function(t){return"server request"===t.type})):"errors"===this.selectedFilter?this.logEventsDataSource.getItems().filter((function(t){return"error"===t.type})):"warnings"===this.selectedFilter?this.logEventsDataSource.getItems().filter((function(t){return"warning"===t.type})):"info"===this.selectedFilter?this.logEventsDataSource.getItems().filter((function(t){return"info"===t.type})):"map updates"===this.selectedFilter?this.logEventsDataSource.getItems().filter((function(t){return"map update"===t.type||"command"===t.type})):this.logEventsDataSource.getItems()},t.prototype.printNode=function(t){return"command_line: "+t.command_line+", \n compute_id: "+t.compute_id+", \n console: "+t.console+", \n console_host: "+t.console_host+", \n console_type: "+t.console_type+", \n first_port_name: "+t.first_port_name+", \n height: "+t.height+", \n label: "+t.label.text+", \n name: "+t.name+", \n node_directory: "+t.node_directory+", \n node_id: "+t.node_id+", \n node_type: "+t.node_type+", \n port_name_format: "+t.port_name_format+", \n port_segment_size: "+t.port_segment_size+", "+this.printPorts(t.ports)+"project_id: "+t.project_id+", \n status: "+t.status+", \n symbol: "+t.symbol+", \n symbol_url: "+t.symbol_url+", \n width: "+t.width+", \n x: "+t.x+", \n y: "+t.y+", \n z: "+t.z},t.prototype.printPorts=function(t){var e="ports: ";return t.forEach((function(t){e=e+"adapter_number: "+t.adapter_number+", \n link_type: "+t.link_type+", \n name: "+t.name+", \n port_number: "+t.port_number+", \n short_name: "+t.short_name+", "})),e},t.prototype.printLink=function(t){return"capture_file_name: "+t.capture_file_name+", \n capture_file_path: "+t.capture_file_path+", \n capturing: "+t.capturing+", \n link_id: "+t.link_id+", \n link_type: "+t.link_type+", \n project_id: "+t.project_id+", \n suspend: "+t.suspend+", "},t.prototype.printDrawing=function(t){return"drawing_id: "+t.drawing_id+", \n project_id: "+t.project_id+", \n rotation: "+t.rotation+", \n x: "+t.x+", \n y: "+t.y+", \n z: "+t.z},t.\u0275fac=function(e){return new(e||t)(da(vet),da(E2),da(M9),da(Nlt),da(YQ),da(Kit),da(Po),da(Q8),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["app-log-console"]],viewQuery:function(t,e){var n;1&t&&nl(zlt,!0),2&t&&tl(n=sl())&&(e.console=n.first)},inputs:{server:"server",project:"project"},decls:25,vars:16,consts:[[1,"consoleHeader"],[1,"consoleFiltering"],[1,"filterButton",3,"ngClass","matMenuTriggerFor"],["xPosition","after"],["filterMenu","matMenu"],["mat-menu-item","",3,"click"],[1,"console",3,"ngClass","ngStyle"],["console",""],["class","console-item",4,"ngFor","ngForOf"],[1,"consoleInput",3,"ngClass"],[1,"inputIcon"],["autofocus","","type","text",1,"commandLine",3,"ngClass","ngModel","keydown","ngModelChange"],[1,"console-item"]],template:function(t,e){if(1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"button",2),ds(3," Apply filter "),va(),ga(4,"mat-menu",3,4),ga(6,"button",5),xa("click",(function(){return e.applyFilter("all")})),ds(7,"all"),va(),ga(8,"button",5),xa("click",(function(){return e.applyFilter("errors")})),ds(9,"errors"),va(),ga(10,"button",5),xa("click",(function(){return e.applyFilter("warnings")})),ds(11,"warnings"),va(),ga(12,"button",5),xa("click",(function(){return e.applyFilter("info")})),ds(13,"info"),va(),ga(14,"button",5),xa("click",(function(){return e.applyFilter("map updates")})),ds(15,"map updates"),va(),ga(16,"button",5),xa("click",(function(){return e.applyFilter("server requests")})),ds(17,"server requests"),va(),va(),va(),va(),ga(18,"div",6,7),ua(20,Vlt,3,1,"span",8),va(),ga(21,"div",9),ga(22,"mat-icon",10),ds(23,"keyboard_arrow_right"),va(),ga(24,"input",11),xa("keydown",(function(t){return e.onKeyDown(t)}))("ngModelChange",(function(t){return e.command=t})),va(),va()),2&t){var n=ha(5);Qi(2),pa("ngClass",Ic(8,Ult,e.isLightThemeEnabled))("matMenuTriggerFor",n),Qi(16),pa("ngClass",Ic(10,Ult,e.isLightThemeEnabled))("ngStyle",e.style),Qi(2),pa("ngForOf",e.filteredEvents),Qi(1),pa("ngClass",Ic(12,Ult,e.isLightThemeEnabled)),Qi(3),pa("ngClass",Ic(14,Ult,e.isLightThemeEnabled))("ngModel",e.command)}},directives:[Oh,N0,D0,E0,Hh,Eh,x2,cf,mf,Sp],styles:[".consoleWrapper[_ngcontent-%COMP%]{box-shadow:0 4px 8px 0 rgba(0,0,0,.2),0 6px 20px 0 rgba(0,0,0,.19);position:fixed;bottom:20px;left:20px;height:180px;width:600px;background:#263238;color:#fff;overflow:hidden;font-size:12px}.lightTheme[_ngcontent-%COMP%]{background:#fff!important;color:#000}.filterButton[_ngcontent-%COMP%]{background:transparent;color:#fff;border:none;margin-top:0;outline:none;color:#dbd5d5;font-weight:700;padding:0}.consoleFiltering[_ngcontent-%COMP%]{display:flex}.consoleHeader[_ngcontent-%COMP%]{width:100%;height:40px;font-size:12px;overflow:hidden;display:flex;padding:2px;justify-content:space-between}.console[_ngcontent-%COMP%]{width:596px;height:120px;overflow-y:scroll;padding:2px;color:#dbd5d5;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.consoleInput[_ngcontent-%COMP%]{width:100%;height:30px;padding:2px;display:flex}.commandLine[_ngcontent-%COMP%]{background-color:transparent;color:#fff;border:none}.inputIcon[_ngcontent-%COMP%]{margin-top:2px}mat-icon[_ngcontent-%COMP%]{font-size:20px;width:20px;height:20px}input[_ngcontent-%COMP%]:focus{outline:none}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}.closeButton[_ngcontent-%COMP%]{cursor:pointer}"],changeDetection:0}),t}(),Glt=n("/POA"),Wlt=n("Fzww"),Klt=n("R9As"),Xlt=["terminal"],Ylt=function(){function t(t){this.consoleService=t,this.term=new Glt.Terminal,this.fitAddon=new Klt.FitAddon,this.copiedText=""}return t.prototype.ngOnInit=function(){var t=this;this.consoleService.consoleResized.subscribe((function(e){var n=Math.floor(e.width/9),i=Math.floor(e.height/17);t.consoleService.setNumberOfColumns(n),t.consoleService.setNumberOfRows(i),t.term.resize(n,i)})),this.consoleService.getNumberOfColumns()&&this.consoleService.getNumberOfRows()&&this.term.resize(this.consoleService.getNumberOfColumns(),this.consoleService.getNumberOfRows())},t.prototype.ngAfterViewInit=function(){var t=this;this.term.open(this.terminal.nativeElement);var e=new WebSocket(this.getUrl());e.onerror=function(e){t.term.write("Connection lost")},e.onclose=function(e){t.consoleService.closeConsoleForNode(t.node)};var n=new Wlt.AttachAddon(e);this.term.loadAddon(n),this.term.setOption("cursorBlink",!0),this.term.loadAddon(this.fitAddon),this.fitAddon.activate(this.term),this.term.focus(),this.term.attachCustomKeyEventHandler((function(t){return"KeyC"!==t.code&&"KeyV"!==t.code||!t.ctrlKey}))},t.prototype.getUrl=function(){return"ws://"+this.server.host+":"+this.server.port+"/v2/projects/"+this.node.project_id+"/nodes/"+this.node.node_id+"/console/ws"},t.\u0275fac=function(e){return new(e||t)(da(Q8))},t.\u0275cmp=Ht({type:t,selectors:[["app-web-console"]],viewQuery:function(t,e){var n;1&t&&nl(Xlt,!0),2&t&&tl(n=sl())&&(e.terminal=n.first)},inputs:{server:"server",project:"project",node:"node"},decls:2,vars:0,consts:[["id","terminal"],["terminal",""]],template:function(t,e){1&t&&ba(0,"div",0,1)},styles:['.xterm{font-feature-settings:"liga" 0;position:relative;-moz-user-select:none;user-select:none;-ms-user-select:none;-webkit-user-select:none}.xterm.focus,.xterm:focus{outline:none}.xterm .xterm-helpers{position:absolute;top:0;z-index:5}.xterm .xterm-helper-textarea{padding:0;border:0;margin:0;position:absolute;opacity:0;left:-9999em;top:0;width:0;height:0;z-index:-5;white-space:nowrap;overflow:hidden;resize:none}.xterm .composition-view{background:#000;color:#fff;display:none;position:absolute;white-space:nowrap;z-index:1}.xterm .composition-view.active{display:block}.xterm .xterm-viewport{background-color:#000;overflow-y:scroll;cursor:default;position:absolute;right:0;left:0;top:0;bottom:0}.xterm .xterm-screen{position:relative}.xterm .xterm-screen canvas{position:absolute;left:0;top:0}.xterm .xterm-scroll-area{visibility:hidden}.xterm-char-measure-element{display:inline-block;visibility:hidden;position:absolute;top:0;left:-9999em;line-height:normal}.xterm{cursor:text}.xterm.enable-mouse-events{cursor:default}.xterm.xterm-cursor-pointer{cursor:pointer}.xterm.column-select.focus{cursor:crosshair}.xterm .xterm-accessibility,.xterm .xterm-message{position:absolute;left:0;top:0;bottom:0;right:0;z-index:10;color:transparent}.xterm .live-region{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}.xterm-dim{opacity:.5}.xterm-underline{text-decoration:underline}'],encapsulation:2}),t}();function Zlt(t,e){if(1&t){var n=ka();ga(0,"div",10),xa("mousemove",(function(t){return Se(n),Aa().dragWidget(t)}),!1,_n)("mouseup",(function(){return Se(n),Aa().toggleDragging(!1)}),!1,_n),va()}}function Qlt(t,e){1&t&&(ga(0,"div",11),ds(1,"GNS3 console"),va())}function $lt(t,e){if(1&t){var n=ka();ga(0,"div",11),ds(1),va(),ga(2,"button",7),xa("click",(function(){Se(n);var t=Aa().index;return Aa().removeTab(t)})),ga(3,"mat-icon"),ds(4,"close"),va(),va()}if(2&t){var i=Aa().$implicit;Qi(1),fs(i.name)}}function Jlt(t,e){1&t&&(ga(0,"mat-tab",12),ua(1,$lt,5,1,"ng-template",4),va()),2&t&&pa("label",Aa().tab)}function tut(t,e){if(1&t){var n=ka();ga(0,"button",7),xa("click",(function(){return Se(n),Aa().minimize(!0)})),ga(1,"mat-icon"),ds(2,"remove"),va(),va()}}function eut(t,e){if(1&t){var n=ka();ga(0,"button",7),xa("click",(function(){return Se(n),Aa().minimize(!1)})),ga(1,"mat-icon"),ds(2,"web_asset"),va(),va()}}function nut(t,e){if(1&t&&(ga(0,"div",13),ba(1,"app-web-console",14),va()),2&t){var n=e.index,i=Aa();pa("hidden",i.isMinimized),Qi(1),pa("hidden",!(i.selected.value===n+1))("server",i.server)("node",i.nodes[n])}}var iut=function(t){return{lightTheme:t}},rut=function(){return{right:!0,left:!0,bottom:!0,top:!0}},out=function(){function t(t,e){this.consoleService=t,this.themeService=e,this.closeConsole=new Uc,this.filters=["all","errors","warnings","info","map updates","server requests"],this.selectedFilter="all",this.style={},this.styleInside={height:"120px"},this.isDraggingEnabled=!1,this.isLightThemeEnabled=!1,this.isMinimized=!1,this.resizedWidth=720,this.resizedHeight=480,this.nodes=[],this.selected=new hp(0)}return t.prototype.ngOnInit=function(){var t=this;this.isLightThemeEnabled="light"===this.themeService.getActualTheme(),this.style={bottom:"20px",left:"20px",width:"720px",height:"460px"},this.consoleService.nodeConsoleTrigger.subscribe((function(e){t.addTab(e,!0)})),this.consoleService.closeNodeConsoleTrigger.subscribe((function(e){var n=t.nodes.findIndex((function(t){return t.node_id===e.node_id}));t.removeTab(n)}))},t.prototype.minimize=function(t){this.isMinimized=t,this.style=t?{bottom:"20px",left:"20px",width:this.resizedWidth+"px",height:"56px"}:{bottom:"20px",left:"20px",width:this.resizedWidth+"px",height:this.resizedHeight+"px"}},t.prototype.addTab=function(t,e){this.minimize(!1),this.nodes.push(t),e&&this.selected.setValue(this.nodes.length),this.consoleService.openConsoles++},t.prototype.removeTab=function(t){this.nodes.splice(t,1),this.consoleService.openConsoles--},t.prototype.toggleDragging=function(t){this.isDraggingEnabled=t},t.prototype.dragWidget=function(t){var e=Number(t.movementX),n=Number(t.movementY),i=Number(this.style.width.split("px")[0]),r=Number(this.style.height.split("px")[0]),o=Number(this.style.left.split("px")[0])+e;if(this.style.top){var a=Number(this.style.top.split("px")[0])+n;this.style={position:"fixed",left:o+"px",top:a+"px",width:i+"px",height:r+"px"}}else{var s=Number(this.style.bottom.split("px")[0])-n;this.style={position:"fixed",left:o+"px",bottom:s+"px",width:i+"px",height:r+"px"}}},t.prototype.validate=function(t){return!(t.rectangle.width&&t.rectangle.height&&(t.rectangle.width<500||t.rectangle.height<100))},t.prototype.onResizeEnd=function(t){this.style={position:"fixed",left:t.rectangle.left+"px",top:t.rectangle.top+"px",width:t.rectangle.width+"px",height:t.rectangle.height+"px"},this.styleInside={height:t.rectangle.height-60+"px",width:t.rectangle.width+"px"},this.consoleService.consoleResized.next({width:t.rectangle.width,height:t.rectangle.height-53}),this.resizedWidth=t.rectangle.width,this.resizedHeight=t.rectangle.height},t.prototype.close=function(){this.closeConsole.emit(!1)},t.\u0275fac=function(e){return new(e||t)(da(Q8),da(Kit))},t.\u0275cmp=Ht({type:t,selectors:[["app-console-wrapper"]],inputs:{server:"server",project:"project"},outputs:{closeConsole:"closeConsole"},decls:14,vars:17,consts:[[3,"mousemove","mouseup",4,"ngIf"],["mwlResizable","",1,"consoleWrapper",3,"ngClass","ngStyle","validateResize","resizeEdges","enableGhostResize","mousedown","resizeStart","resizeEnd"],[1,"consoleHeader"],[1,"tabs",3,"selectedIndex","selectedIndexChange"],["mat-tab-label",""],[3,"label",4,"ngFor","ngForOf"],["style","color:white","mat-icon-button","",3,"click",4,"ngIf"],["mat-icon-button","",2,"color","white",3,"click"],[3,"hidden","server","project"],["class","xterm-console",3,"hidden",4,"ngFor","ngForOf"],[3,"mousemove","mouseup"],[1,"col",2,"margin-left","20px"],[3,"label"],[1,"xterm-console",3,"hidden"],[3,"hidden","server","node"]],template:function(t,e){1&t&&(ua(0,Zlt,1,0,"div",0),ga(1,"div",1),xa("mousedown",(function(){return e.toggleDragging(!0)}))("resizeStart",(function(){return e.toggleDragging(!1)}))("resizeEnd",(function(t){return e.onResizeEnd(t)})),ga(2,"div",2),ga(3,"mat-tab-group",3),xa("selectedIndexChange",(function(t){return e.selected.setValue(t)})),ga(4,"mat-tab"),ua(5,Qlt,2,0,"ng-template",4),va(),ua(6,Jlt,2,1,"mat-tab",5),va(),ua(7,tut,3,0,"button",6),ua(8,eut,3,0,"button",6),ga(9,"button",7),xa("click",(function(){return e.close()})),ga(10,"mat-icon"),ds(11,"close"),va(),va(),va(),ba(12,"app-log-console",8),ua(13,nut,2,4,"div",9),va()),2&t&&(pa("ngIf",e.isDraggingEnabled),Qi(1),pa("ngClass",Ic(14,iut,e.isLightThemeEnabled))("ngStyle",e.style)("validateResize",e.validate)("resizeEdges",jc(16,rut))("enableGhostResize",!0),Qi(2),pa("selectedIndex",e.selected.value),Qi(3),pa("ngForOf",e.nodes),Qi(1),pa("ngIf",!e.isMinimized),Qi(1),pa("ngIf",e.isMinimized),Qi(4),pa("hidden",!(0===e.selected.value)||e.isMinimized)("server",e.server)("project",e.project),Qi(1),pa("ngForOf",e.nodes))},directives:[Ah,Dlt,Oh,Hh,U1,I1,P1,Eh,a2,x2,qlt,Ylt],styles:[".consoleWrapper[_ngcontent-%COMP%]{box-shadow:0 4px 8px 0 rgba(0,0,0,.2),0 6px 20px 0 rgba(0,0,0,.19);position:fixed;bottom:20px;left:20px;height:180px;width:600px;background:#000!important;color:#fff;overflow:hidden;font-size:12px}.lightTheme[_ngcontent-%COMP%]{background:#fff!important;color:#000}.filterButton[_ngcontent-%COMP%]{background:transparent;color:#fff;border:none;margin-top:0;outline:none;color:#dbd5d5;font-weight:700;padding:0}.consoleFiltering[_ngcontent-%COMP%]{display:flex}.consoleHeader[_ngcontent-%COMP%]{width:100%;font-size:12px;overflow:hidden;display:flex;padding:2px;justify-content:space-between;background:#263238!important}[_nghost-%COMP%] .mat-tab-label{height:3rem!important;min-width:8rem!important}[_nghost-%COMP%] .mat-tab-label.mat-tab-label-active{border-bottom:2px solid #0097a7;box-sizing:border-box;font-weight:1200}[_nghost-%COMP%] .mat-ink-bar{display:none!important}.tabs[_ngcontent-%COMP%]{width:80%}.console[_ngcontent-%COMP%]{width:596px;height:120px;overflow-y:scroll;padding:2px;color:#dbd5d5;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.xterm-console[_ngcontent-%COMP%]{background:#000}.consoleInput[_ngcontent-%COMP%]{width:100%;height:30px;padding:2px;display:flex}.commandLine[_ngcontent-%COMP%]{background-color:transparent;color:#fff;border:none}.inputIcon[_ngcontent-%COMP%]{margin-top:2px}mat-icon[_ngcontent-%COMP%]{font-size:20px;width:20px;height:20px}input[_ngcontent-%COMP%]:focus{outline:none}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}.closeButton[_ngcontent-%COMP%]{cursor:pointer}"]}),t}();function aut(t,e){if(1&t){var n=ka();ga(0,"div",2),xa("mousemove",(function(t){return Se(n),Aa().dragWidget(t)}),!1,_n)("mouseup",(function(){return Se(n),Aa().toggleDragging(!1)}),!1,_n),va()}}function sut(t,e){1&t&&(Qe(),ga(0,"svg",28),ba(1,"rect",29),va())}function cut(t,e){1&t&&(Qe(),ga(0,"svg",28),ba(1,"rect",30),va())}function lut(t,e){1&t&&(Qe(),ga(0,"svg",28),ba(1,"rect",31),va())}function uut(t,e){if(1&t&&(ga(0,"div"),ds(1),va()),2&t){var n=Aa().$implicit;Qi(1),gs(" ",n.console_type," ",n.console_host,":",n.console," ")}}function hut(t,e){1&t&&(ga(0,"div"),ds(1," none "),va())}function dut(t,e){if(1&t&&(ga(0,"div",25),ga(1,"div"),ua(2,sut,2,0,"svg",26),ua(3,cut,2,0,"svg",26),ua(4,lut,2,0,"svg",26),ds(5),va(),ua(6,uut,2,3,"div",27),ua(7,hut,2,0,"div",27),va()),2&t){var n=e.$implicit;Qi(2),pa("ngIf","started"===n.status),Qi(1),pa("ngIf","suspended"===n.status),Qi(1),pa("ngIf","stopped"===n.status),Qi(1),ps(" ",n.name," "),Qi(1),pa("ngIf",null!=n.console&&null!=n.console&&"none"!=n.console_type),Qi(1),pa("ngIf",null==n.console||"none"===n.console_type)}}function fut(t,e){if(1&t&&(ga(0,"div",25),ga(1,"div"),ds(2),va(),ga(3,"div"),ds(4),va(),ga(5,"div"),ds(6),va(),va()),2&t){var n=e.$implicit,i=Aa(2);Qi(2),ps(" ",n.name," "),Qi(2),ps(" ",n.host," "),Qi(2),ps(" ",i.server.location," ")}}var put=function(t){return{lightTheme:t}},mut=function(){return{right:!0,left:!0,bottom:!0,top:!0}},gut=function(t){return{marked:t}},vut=function(t){return{notvisible:t}};function but(t,e){if(1&t){var n=ka();ga(0,"div",3),xa("mousedown",(function(){return Se(n),Aa().toggleDragging(!0)}))("resizeStart",(function(){return Se(n),Aa().toggleDragging(!1)}))("resizeEnd",(function(t){return Se(n),Aa().onResizeEnd(t)})),ga(1,"div",4),ga(2,"button",5),xa("click",(function(){return Se(n),Aa().toogleTopologyVisibility(!0)})),ds(3,"Map topology"),va(),ga(4,"button",5),xa("click",(function(){return Se(n),Aa().toogleTopologyVisibility(!1)})),ds(5,"Servers"),va(),ga(6,"mat-icon",6),xa("click",(function(){return Se(n),Aa().close()})),ds(7,"close"),va(),va(),ga(8,"div",7),ba(9,"mat-divider",8),ga(10,"div",9),ga(11,"mat-select",10),ga(12,"mat-optgroup",11),ga(13,"mat-option",12),xa("onSelectionChange",(function(){return Se(n),Aa().applyStatusFilter("started")})),ds(14,"started"),va(),ga(15,"mat-option",13),xa("onSelectionChange",(function(){return Se(n),Aa().applyStatusFilter("suspended")})),ds(16,"suspended"),va(),ga(17,"mat-option",14),xa("onSelectionChange",(function(){return Se(n),Aa().applyStatusFilter("stopped")})),ds(18,"stopped"),va(),va(),ga(19,"mat-optgroup",15),ga(20,"mat-option",16),xa("onSelectionChange",(function(){return Se(n),Aa().applyCaptureFilter("capture")})),ds(21,"active capture(s)"),va(),ga(22,"mat-option",17),xa("onSelectionChange",(function(){return Se(n),Aa().applyCaptureFilter("packet")})),ds(23,"active packet captures"),va(),va(),va(),va(),ga(24,"div",18),ga(25,"mat-select",19),xa("selectionChange",(function(){return Se(n),Aa().setSortingOrder()}))("valueChange",(function(t){return Se(n),Aa().sortingOrder=t})),ga(26,"mat-option",20),ds(27,"sort by name ascending"),va(),ga(28,"mat-option",21),ds(29,"sort by name descending"),va(),va(),va(),ba(30,"mat-divider",8),ga(31,"div",22),ua(32,dut,8,6,"div",23),va(),va(),ga(33,"div",7),ba(34,"mat-divider",8),ga(35,"div",24),ua(36,fut,7,3,"div",23),va(),va(),va()}if(2&t){var i=Aa();pa("ngStyle",i.style)("ngClass",Ic(13,put,i.isLightThemeEnabled))("validateResize",i.validate)("resizeEdges",jc(15,mut))("enableGhostResize",!0),Qi(2),pa("ngClass",Ic(16,gut,i.isTopologyVisible)),Qi(2),pa("ngClass",Ic(18,gut,!i.isTopologyVisible)),Qi(4),pa("ngClass",Ic(20,vut,!i.isTopologyVisible)),Qi(17),pa("value",i.sortingOrder),Qi(6),pa("ngStyle",i.styleInside),Qi(1),pa("ngForOf",i.filteredNodes),Qi(1),pa("ngClass",Ic(22,vut,i.isTopologyVisible)),Qi(3),pa("ngForOf",i.computes)}}var yut=function(){function t(t,e,n,i,r){this.nodesDataSource=t,this.projectService=e,this.computeService=n,this.linksDataSource=i,this.themeService=r,this.closeTopologySummary=new Uc,this.style={},this.styleInside={height:"280px"},this.subscriptions=[],this.nodes=[],this.filteredNodes=[],this.sortingOrder="asc",this.startedStatusFilterEnabled=!1,this.suspendedStatusFilterEnabled=!1,this.stoppedStatusFilterEnabled=!1,this.captureFilterEnabled=!1,this.packetFilterEnabled=!1,this.computes=[],this.isTopologyVisible=!0,this.isDraggingEnabled=!1,this.isLightThemeEnabled=!1}return t.prototype.ngOnInit=function(){var t=this;this.isLightThemeEnabled="light"===this.themeService.getActualTheme(),this.subscriptions.push(this.nodesDataSource.changes.subscribe((function(e){t.nodes=e,t.nodes.forEach((function(e){"0.0.0.0"!==e.console_host&&"0:0:0:0:0:0:0:0"!==e.console_host&&"::"!==e.console_host||(e.console_host=t.server.host)})),t.filteredNodes=e.sort("asc"===t.sortingOrder?t.compareAsc:t.compareDesc)}))),this.projectService.getStatistics(this.server,this.project.project_id).subscribe((function(e){t.projectsStatistics=e})),this.computeService.getComputes(this.server).subscribe((function(e){t.computes=e})),this.style={top:"20px",right:"20px",width:"300px",height:"400px"}},t.prototype.toggleDragging=function(t){this.isDraggingEnabled=t},t.prototype.dragWidget=function(t){var e=Number(t.movementX),n=Number(t.movementY),i=Number(this.style.width.split("px")[0]),r=Number(this.style.height.split("px")[0]),o=Number(this.style.top.split("px")[0])+n;if(this.style.left){var a=Number(this.style.left.split("px")[0])+e;this.style={position:"fixed",left:a+"px",top:o+"px",width:i+"px",height:r+"px"}}else{var s=Number(this.style.right.split("px")[0])-e;this.style={position:"fixed",right:s+"px",top:o+"px",width:i+"px",height:r+"px"}}},t.prototype.validate=function(t){return!(t.rectangle.width&&t.rectangle.height&&(t.rectangle.width<290||t.rectangle.height<260))},t.prototype.onResizeEnd=function(t){this.style={position:"fixed",left:t.rectangle.left+"px",top:t.rectangle.top+"px",width:t.rectangle.width+"px",height:t.rectangle.height+"px"},this.styleInside={height:t.rectangle.height-120+"px"}},t.prototype.toogleTopologyVisibility=function(t){this.isTopologyVisible=t},t.prototype.compareAsc=function(t,e){return t.name<e.name?-1:1},t.prototype.compareDesc=function(t,e){return t.name<e.name?1:-1},t.prototype.ngOnDestroy=function(){this.subscriptions.forEach((function(t){return t.unsubscribe()}))},t.prototype.setSortingOrder=function(){this.filteredNodes=this.filteredNodes.sort("asc"===this.sortingOrder?this.compareAsc:this.compareDesc)},t.prototype.applyStatusFilter=function(t){"started"===t?this.startedStatusFilterEnabled=!this.startedStatusFilterEnabled:"stopped"===t?this.stoppedStatusFilterEnabled=!this.stoppedStatusFilterEnabled:"suspended"===t&&(this.suspendedStatusFilterEnabled=!this.suspendedStatusFilterEnabled),this.applyFilters()},t.prototype.applyCaptureFilter=function(t){"capture"===t?this.captureFilterEnabled=!this.captureFilterEnabled:"packet"===t&&(this.packetFilterEnabled=!this.packetFilterEnabled),this.applyFilters()},t.prototype.applyFilters=function(){var t=[];this.startedStatusFilterEnabled&&(t=t.concat(this.nodes.filter((function(t){return"started"===t.status})))),this.stoppedStatusFilterEnabled&&(t=t.concat(this.nodes.filter((function(t){return"stopped"===t.status})))),this.suspendedStatusFilterEnabled&&(t=t.concat(this.nodes.filter((function(t){return"suspended"===t.status})))),this.startedStatusFilterEnabled||this.stoppedStatusFilterEnabled||this.suspendedStatusFilterEnabled||(t=t.concat(this.nodes)),this.captureFilterEnabled&&(t=this.checkCapturing(t)),this.packetFilterEnabled&&(t=this.checkPacketFilters(t)),this.filteredNodes=t.sort("asc"===this.sortingOrder?this.compareAsc:this.compareDesc)},t.prototype.checkCapturing=function(t){var e=this.linksDataSource.getItems(),n=[];e.forEach((function(t){t.capturing&&t.nodes.forEach((function(t){n.push(t.node_id)}))}));var i=[];return t.forEach((function(t){n.includes(t.node_id)&&i.push(t)})),i},t.prototype.checkPacketFilters=function(t){var e=this.linksDataSource.getItems(),n=[];e.forEach((function(t){(t.filters.bpf||t.filters.corrupt||t.filters.corrupt||t.filters.packet_loss||t.filters.frequency_drop)&&t.nodes.forEach((function(t){n.push(t.node_id)}))}));var i=[];return t.forEach((function(t){n.includes(t.node_id)&&i.push(t)})),i},t.prototype.close=function(){this.closeTopologySummary.emit(!1)},t.\u0275fac=function(e){return new(e||t)(da(M9),da($Q),da(_ot),da(G9),da(Kit))},t.\u0275cmp=Ht({type:t,selectors:[["app-topology-summary"]],inputs:{server:"server",project:"project"},outputs:{closeTopologySummary:"closeTopologySummary"},decls:2,vars:2,consts:[[3,"mousemove","mouseup",4,"ngIf"],["class","summaryWrapper","mwlResizable","",3,"ngStyle","ngClass","validateResize","resizeEdges","enableGhostResize","mousedown","resizeStart","resizeEnd",4,"ngIf"],[3,"mousemove","mouseup"],["mwlResizable","",1,"summaryWrapper",3,"ngStyle","ngClass","validateResize","resizeEdges","enableGhostResize","mousedown","resizeStart","resizeEnd"],[1,"summaryHeader"],["mat-button","",1,"titleButton",3,"ngClass","click"],[1,"closeButton",3,"click"],[3,"ngClass"],[1,"divider"],[1,"summaryFilters"],["placeholder","Filter nodes","multiple",""],["label","Status filter"],["value","started",3,"onSelectionChange"],["value","suspended",3,"onSelectionChange"],["value","stopped",3,"onSelectionChange"],["label","Capture filter"],["value","capture",3,"onSelectionChange"],["value","packet",3,"onSelectionChange"],[1,"summarySorting"],["placeholder","Sorting",3,"value","selectionChange","valueChange"],["value","asc"],["value","desc"],[1,"summaryContent",3,"ngStyle"],["class","nodeRow",4,"ngFor","ngForOf"],[1,"summaryContentServers"],[1,"nodeRow"],["width","10","height","10",4,"ngIf"],[4,"ngIf"],["width","10","height","10"],["x","0","y","0","width","10","height","10","fill","green",1,"status_started"],["x","0","y","0","width","10","height","10","fill","yellow",1,"status_suspended"],["x","0","y","0","width","10","height","10","fill","red",1,"status_stopped"]],template:function(t,e){1&t&&(ua(0,aut,1,0,"div",0),ua(1,but,37,24,"div",1)),2&t&&(pa("ngIf",e.isDraggingEnabled),Qi(1),pa("ngIf",e.projectsStatistics))},directives:[Ah,Dlt,Hh,Oh,a2,x2,a8,O5,xJ,EJ,Eh],styles:[".summaryWrapper[_ngcontent-%COMP%]{box-shadow:0 4px 8px 0 rgba(0,0,0,.2),0 6px 20px 0 rgba(0,0,0,.19);position:fixed;top:20px;right:20px;height:400px;width:300px;background:#263238;color:#fff;overflow:hidden;font-size:12px}.lightTheme[_ngcontent-%COMP%]{background:#fff!important;color:#000}.summaryHeaderMenu[_ngcontent-%COMP%]{height:24px}.summaryHeader[_ngcontent-%COMP%]{width:100%;height:34px;display:flex;justify-content:space-between;margin-right:5px}.summaryFilters[_ngcontent-%COMP%], .summarySorting[_ngcontent-%COMP%]{height:25px;margin-left:5px;margin-right:5px}.summaryContent[_ngcontent-%COMP%], .summaryContentServers[_ngcontent-%COMP%]{margin-left:5px;margin-right:5px;overflow:auto;scrollbar-color:#a9a9a9 #263238;scrollbar-width:thin}.summaryContentServers[_ngcontent-%COMP%]{max-height:350px}.titleButton[_ngcontent-%COMP%]{margin-left:5px;margin-top:4px;outline:none}.marked[_ngcontent-%COMP%]{color:#0097a7}.divider[_ngcontent-%COMP%]{margin-top:5px;margin-bottom:5px;width:100%;height:2px}.nodeRow[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:space-between;padding-right:5px}[_ngcontent-%COMP%]::-webkit-scrollbar{width:.5em}[_ngcontent-%COMP%]::-webkit-scrollbar-track{-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.3)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background-color:#a9a9a9;outline:1px solid #263238}.radio-group-wrapper[_ngcontent-%COMP%]{margin-top:5px}.radio-group[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.closeButton[_ngcontent-%COMP%]{cursor:pointer;font-size:24px;margin-top:8px;margin-right:5px}.filterBox[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.notvisible[_ngcontent-%COMP%]{display:none}"]}),t}();function _ut(t,e){if(1&t){var n=ka();ga(0,"app-d3-map",20),xa("nodeDragged",(function(t){return Se(n),Aa(2).onNodeDragged(t)}))("drawingDragged",(function(t){return Se(n),Aa(2).onDrawingDragged(t)}))("onLinkCreated",(function(t){return Se(n),Aa(2).onLinkCreated(t)}))("onDrawingResized",(function(t){return Se(n),Aa(2).onDrawingResized(t)})),va()}if(2&t){var i=Aa(2);pa("server",i.server)("project",i.project)("symbols",i.symbols)("nodes",i.nodes)("links",i.links)("drawings",i.drawings)("width",i.project.scene_width)("height",i.project.scene_height)("show-interface-labels",i.isInterfaceLabelVisible)("readonly",i.inReadOnlyMode)}}function wut(t,e){if(1&t&&ba(0,"app-experimental-map",21),2&t){var n=Aa(2);pa("symbols",n.symbols)("nodes",n.nodes)("links",n.links)("drawings",n.drawings)("width",n.project.scene_width)("height",n.project.scene_height)("show-interface-labels",n.isInterfaceLabelVisible)("selection-tool",n.tools.selection)("moving-tool",n.tools.moving)("draw-link-tool",n.tools.draw_link)("readonly",n.inReadOnlyMode)}}function kut(t,e){if(1&t&&(ga(0,"mat-toolbar-row"),ga(1,"button",35),ba(2,"mat-icon",36),va(),va()),2&t){Aa();var n=ha(5);Qi(1),pa("matMenuTriggerFor",n)}}function Cut(t,e){if(1&t&&(ga(0,"mat-toolbar-row"),ga(1,"button",35),ba(2,"mat-icon",37),va(),va()),2&t){Aa();var n=ha(5);Qi(1),pa("matMenuTriggerFor",n)}}function Sut(t,e){if(1&t){var n=ka();ga(0,"mat-toolbar-row"),ga(1,"app-template",38),xa("onNodeCreation",(function(t){return Se(n),Aa(3).onNodeCreation(t)})),va(),va()}if(2&t){var i=Aa(3);Qi(1),pa("server",i.server)("project",i.project)}}function xut(t,e){if(1&t){var n=ka();ga(0,"mat-toolbar-row"),ga(1,"button",39),xa("click",(function(){return Se(n),Aa(3).toggleDrawLineMode()})),ga(2,"mat-icon"),ds(3,"timeline"),va(),va(),va()}if(2&t){var i=Aa(3);Qi(1),pa("color",i.tools.draw_link?"primary":"basic")}}function Out(t,e){if(1&t&&(ga(0,"mat-toolbar-row"),ba(1,"app-snapshot-menu-item",7),va()),2&t){var n=Aa(3);Qi(1),pa("server",n.server)("project",n.project)}}function Mut(t,e){if(1&t){var n=ka();ga(0,"mat-toolbar-row"),ga(1,"button",40),xa("click",(function(){return Se(n),Aa(3).fitInView()})),ga(2,"mat-icon"),ds(3,"fullscreen"),va(),va(),va()}}function Tut(t,e){if(1&t){var n=ka();ga(0,"mat-toolbar-row"),ga(1,"button",41),xa("click",(function(){return Se(n),Aa(3).centerView()})),ga(2,"mat-icon"),ds(3,"center_focus_strong"),va(),va(),va()}}var Eut=function(t){return{lightTheme:t}},Put=function(t){return["/server",t,"projects"]},Aut=function(){return["/servers"]};function jut(t,e){if(1&t){var n=ka();ga(0,"div",22),ga(1,"mat-toolbar",23),ua(2,kut,3,1,"mat-toolbar-row",24),ua(3,Cut,3,1,"mat-toolbar-row",24),ga(4,"mat-menu",25,26),ga(6,"button",27),ga(7,"mat-icon"),ds(8,"work"),va(),ga(9,"span"),ds(10,"Go to projects"),va(),va(),ga(11,"button",27),ga(12,"mat-icon"),ds(13,"developer_board"),va(),ga(14,"span"),ds(15,"Go to servers"),va(),va(),ga(16,"button",27),ga(17,"mat-icon"),ds(18,"settings_applications"),va(),ga(19,"span"),ds(20,"Go to preferences"),va(),va(),ga(21,"button",27),ga(22,"mat-icon"),ds(23,"info"),va(),ga(24,"span"),ds(25,"Go to system status"),va(),va(),ga(26,"button",28),xa("click",(function(){return Se(n),Aa(2).addNewTemplate()})),ga(27,"mat-icon"),ds(28,"control_point"),va(),ga(29,"span"),ds(30,"New template"),va(),va(),ba(31,"app-import-appliance",7),ga(32,"button",29),ga(33,"mat-icon"),ds(34,"settings"),va(),ga(35,"span"),ds(36,"Project settings"),va(),va(),ga(37,"button",29),ga(38,"mat-icon"),ds(39,"view_module"),va(),ga(40,"span"),ds(41,"Map settings"),va(),va(),va(),ga(42,"mat-menu",25,30),ga(44,"div"),ga(45,"button",28),xa("click",(function(){return Se(n),Aa(2).addNewProject()})),ga(46,"mat-icon"),ds(47,"add"),va(),ga(48,"span"),ds(49,"Add new blank project"),va(),va(),ga(50,"button",28),xa("click",(function(){return Se(n),Aa(2).saveProject()})),ga(51,"mat-icon"),ds(52,"save"),va(),ga(53,"span"),ds(54,"Save project as"),va(),va(),ga(55,"button",28),xa("click",(function(){return Se(n),Aa(2).editProject()})),ga(56,"mat-icon"),ds(57,"edit"),va(),ga(58,"span"),ds(59,"Edit project"),va(),va(),ga(60,"button",28),xa("click",(function(){return Se(n),Aa(2).exportProject()})),ga(61,"mat-icon"),ds(62,"call_made"),va(),ga(63,"span"),ds(64,"Export portable project"),va(),va(),ga(65,"button",28),xa("click",(function(){return Se(n),Aa(2).importProject()})),ga(66,"mat-icon"),ds(67,"call_received"),va(),ga(68,"span"),ds(69,"Import portable project"),va(),va(),ga(70,"button",28),xa("click",(function(){return Se(n),Aa(2).closeProject()})),ga(71,"mat-icon"),ds(72,"close"),va(),ga(73,"span"),ds(74,"Close project"),va(),va(),ga(75,"button",28),xa("click",(function(){return Se(n),Aa(2).deleteProject()})),ga(76,"mat-icon"),ds(77,"delete"),va(),ga(78,"span"),ds(79,"Delete project"),va(),va(),va(),va(),ga(80,"mat-menu",25,31),ga(82,"div",32),ga(83,"mat-checkbox",33),xa("change",(function(t){return Se(n),Aa(2).toggleShowInterfaceLabels(t.checked)})),ds(84," Show interface labels "),va(),ba(85,"br"),ga(86,"mat-checkbox",33),xa("change",(function(t){return Se(n),Aa(2).toggleShowConsole(t.checked)})),ds(87," Show console "),va(),ba(88,"br"),ga(89,"mat-checkbox",33),xa("change",(function(t){return Se(n),Aa(2).toggleShowTopologySummary(t.checked)})),ds(90," Show topology/servers summary "),va(),ba(91,"br"),ga(92,"mat-checkbox",33),xa("change",(function(t){return Se(n),Aa(2).toggleNotifications(t.checked)})),ds(93," Show notifications "),va(),ba(94,"br"),ga(95,"mat-checkbox",33),xa("change",(function(t){return Se(n),Aa(2).toggleLayers(t.checked)})),ds(96," Show layers "),va(),ba(97,"br"),ga(98,"mat-checkbox",33),xa("change",(function(t){return Se(n),Aa(2).toggleGrid(t.checked)})),ds(99," Show grid "),va(),ba(100,"br"),ga(101,"mat-checkbox",33),xa("change",(function(t){return Se(n),Aa(2).toggleSnapToGrid(t.checked)})),ds(102," Snap to grid "),va(),ba(103,"br"),va(),va(),ua(104,Sut,2,2,"mat-toolbar-row",24),ua(105,xut,4,1,"mat-toolbar-row",24),ga(106,"mat-toolbar-row"),ga(107,"button",34),xa("click",(function(){return Se(n),Aa(2).toggleMovingMode()})),ga(108,"mat-icon"),ds(109,"zoom_out_map"),va(),va(),va(),ua(110,Out,2,2,"mat-toolbar-row",24),ua(111,Mut,4,0,"mat-toolbar-row",24),ua(112,Tut,4,0,"mat-toolbar-row",24),va(),va()}if(2&t){var i=ha(43),r=ha(81),o=Aa(2);Qi(1),pa("ngClass",Ic(27,Eut,o.isLightThemeEnabled)),Qi(1),pa("ngIf",!o.isLightThemeEnabled),Qi(1),pa("ngIf",o.isLightThemeEnabled),Qi(1),pa("overlapTrigger",!1),Qi(2),pa("routerLink",Ic(29,Put,o.server.id)),Qi(5),pa("routerLink",jc(31,Aut)),Qi(5),La("routerLink","/server/",o.server.id,"/preferences"),Qi(5),La("routerLink","/server/",o.server.id,"/systemstatus"),Qi(10),pa("server",o.server)("project",o.project),Qi(1),pa("matMenuTriggerFor",i),Qi(5),pa("matMenuTriggerFor",r),Qi(5),pa("overlapTrigger",!1),Qi(38),pa("overlapTrigger",!1),Qi(3),pa("ngModel",o.isInterfaceLabelVisible),Qi(3),pa("ngModel",o.isConsoleVisible),Qi(3),pa("ngModel",o.isTopologySummaryVisible),Qi(3),pa("ngModel",o.notificationsVisibility),Qi(3),pa("ngModel",o.layersVisibility),Qi(3),pa("ngModel",o.gridVisibility),Qi(3),pa("ngModel",o.project.snap_to_grid),Qi(3),pa("ngIf",!o.readonly),Qi(1),pa("ngIf",!o.readonly),Qi(2),pa("color",o.tools.moving?"primary":"basic"),Qi(3),pa("ngIf",!o.readonly),Qi(1),pa("ngIf",!o.readonly),Qi(1),pa("ngIf",!o.readonly)}}var Iut=function(t,e){return{lightTheme:t,shadowed:e}};function Dut(t,e){if(1&t){var n=ka();ga(0,"div",42),ga(1,"button",43),xa("click",(function(){return Se(n),Aa(2).showMenu()})),ga(2,"mat-icon",44),ds(3,"keyboard_arrow_right"),va(),va(),va()}if(2&t){var i=Aa(2);pa("ngClass",Dc(2,Iut,i.isLightThemeEnabled,!i.isProjectMapMenuVisible)),Qi(1),pa("ngClass",Ic(5,Eut,i.isLightThemeEnabled))}}var Rut=function(t,e){return{lightTheme:t,extended:e}};function Lut(t,e){if(1&t){var n=ka();ga(0,"div",45),ba(1,"app-nodes-menu",7),ba(2,"mat-divider",46),ba(3,"app-project-map-menu",7),ga(4,"button",43),xa("click",(function(){return Se(n),Aa(2).hideMenu()})),ga(5,"mat-icon",44),ds(6,"keyboard_arrow_left"),va(),va(),va()}if(2&t){var i=Aa(2);pa("ngClass",Dc(7,Rut,i.isLightThemeEnabled,i.isProjectMapMenuVisible)),Qi(1),pa("server",i.server)("project",i.project),Qi(1),pa("vertical",!0),Qi(1),pa("server",i.server)("project",i.project),Qi(1),pa("ngClass",Ic(10,Eut,i.isLightThemeEnabled))}}function Fut(t,e){if(1&t&&(ga(0,"div",13),ua(1,_ut,1,10,"app-d3-map",14),ua(2,wut,1,11,"app-experimental-map",15),ua(3,jut,113,32,"div",16),ua(4,Dut,4,7,"div",17),ua(5,Lut,7,12,"div",18),ba(6,"app-context-menu",19),va()),2&t){var n=Aa();Qi(1),pa("ngIf",!n.settings.angular_map),Qi(1),pa("ngIf",n.settings.angular_map),Qi(1),pa("ngIf",n.toolbarVisibility),Qi(1),pa("ngIf",n.toolbarVisibility),Qi(1),pa("ngIf",n.toolbarVisibility),Qi(1),pa("project",n.project)("server",n.server)}}function Nut(t,e){if(1&t&&ba(0,"app-project-map-shortcuts",19),2&t){var n=Aa();pa("project",n.project)("server",n.server)}}function But(t,e){1&t&&ba(0,"app-draw-link-tool",47),2&t&&pa("links",Aa().links)}function Hut(t,e){if(1&t){var n=ka();ga(0,"app-console-wrapper",48),xa("closeConsole",(function(t){return Se(n),Aa().toggleShowConsole(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("project",i.project)}}function zut(t,e){if(1&t){var n=ka();ga(0,"app-topology-summary",49),xa("closeTopologySummary",(function(t){return Se(n),Aa().toggleShowTopologySummary(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("project",i.project)}}var Vut=function(t){return{visible:t}},Uut=function(){function t(t,e,n,i,r,o,a,s,c,l,u,h,d,f,p,m,g,v,b,y,w,k,C,S,x,O,M,T,E,P,A,j,I,D,R,L,F,N,B,H,z,V,U,q){this.route=t,this.serverService=e,this.projectService=n,this.nodeService=i,this.drawingService=r,this.progressService=o,this.projectWebServiceHandler=a,this.mapChangeDetectorRef=s,this.nodeWidget=c,this.drawingsWidget=l,this.linkWidget=u,this.labelWidget=h,this.interfaceLabelWidget=d,this.mapNodeToNode=f,this.mapDrawingToDrawing=p,this.mapLabelToLabel=m,this.mapLinkToLink=g,this.mapLinkNodeToLinkNode=v,this.nodesDataSource=b,this.linksDataSource=y,this.drawingsDataSource=w,this.settingsService=k,this.toolsService=C,this.selectionManager=S,this.selectionTool=x,this.recentlyOpenedProjectService=O,this.movingEventSource=M,this.mapScaleService=T,this.nodeCreatedLabelStylesFixer=E,this.toasterService=P,this.dialog=A,this.router=j,this.mapNodesDataSource=I,this.mapLinksDataSource=D,this.mapDrawingsDataSource=R,this.mapSymbolsDataSource=L,this.mapSettingsService=F,this.ethernetLinkWidget=N,this.serialLinkWidget=B,this.bottomSheet=H,this.notificationService=z,this.themeService=V,this.title=U,this.nodeConsoleService=q,this.nodes=[],this.links=[],this.drawings=[],this.symbols=[],this.isProjectMapMenuVisible=!1,this.isConsoleVisible=!0,this.isTopologySummaryVisible=!0,this.isInterfaceLabelVisible=!1,this.notificationsVisibility=!1,this.layersVisibility=!1,this.gridVisibility=!1,this.toolbarVisibility=!0,this.tools={selection:!0,moving:!1,draw_link:!1,text_editing:!0},this.inReadOnlyMode=!1,this.scrollX=0,this.scrollY=0,this.scrollEnabled=!1,this.isLightThemeEnabled=!1,this.projectMapSubscription=new _.a}return t.prototype.ngOnInit=function(){var t=this;this.isLightThemeEnabled="light"===this.themeService.getActualTheme(),this.settings=this.settingsService.getAll(),this.isTopologySummaryVisible=this.mapSettingsService.isTopologySummaryVisible,this.isConsoleVisible=this.mapSettingsService.isLogConsoleVisible,this.mapSettingsService.logConsoleSubject.subscribe((function(e){return t.isConsoleVisible=e})),this.progressService.activate(),this.serverService.isServiceInitialized?this.getData():this.projectMapSubscription.add(this.serverService.serviceInitialized.subscribe((function(e){e&&t.getData()}))),this.projectMapSubscription.add(this.mapSettingsService.mapRenderedEmitter.subscribe((function(e){t.scrollEnabled&&t.centerCanvas()}))),this.projectMapSubscription.add(this.drawingsDataSource.changes.subscribe((function(e){t.drawings=e,t.mapChangeDetectorRef.detectChanges()}))),this.projectMapSubscription.add(this.nodesDataSource.changes.subscribe((function(e){t.server&&(e.forEach((function(e){e.symbol_url="http://"+t.server.host+":"+t.server.port+"/v2/symbols/"+e.symbol+"/raw"})),t.nodes=e,t.mapChangeDetectorRef.detectChanges())}))),this.projectMapSubscription.add(this.linksDataSource.changes.subscribe((function(e){t.links=e,t.mapChangeDetectorRef.detectChanges()}))),this.projectMapSubscription.add(this.projectWebServiceHandler.errorNotificationEmitter.subscribe((function(e){t.showMessage({type:"error",message:e})}))),this.projectMapSubscription.add(this.projectWebServiceHandler.warningNotificationEmitter.subscribe((function(e){t.showMessage({type:"warning",message:e})}))),this.notificationsVisibility="true"===localStorage.getItem("notificationsVisibility"),this.layersVisibility="true"===localStorage.getItem("layersVisibility"),this.gridVisibility="true"===localStorage.getItem("gridVisibility"),this.addKeyboardListeners()},t.prototype.getData=function(){var t=this,e=this.route.paramMap.subscribe((function(e){var n=parseInt(e.get("server_id"),10);Object(tf.a)(t.serverService.get(n)).pipe(Object(IX.a)((function(n){return n||t.router.navigate(["/servers"]),t.server=n,t.projectService.get(n,e.get("project_id")).pipe(Object(ef.a)((function(t){return t})))})),Object(IX.a)((function(e){return t.project=e,e||t.router.navigate(["/servers"]),t.projectService.open(t.server,t.project.project_id),t.title.setTitle(t.project.name),t.isInterfaceLabelVisible=t.mapSettingsService.showInterfaceLabels,t.recentlyOpenedProjectService.setServerId(t.server.id.toString()),t.recentlyOpenedProjectService.setProjectId(t.project.project_id),"opened"===t.project.status?new k.a((function(e){e.next(t.project)})):t.projectService.open(t.server,t.project.project_id)}))).subscribe((function(e){t.onProjectLoad(e)}),(function(e){t.progressService.setError(e)}),(function(){t.progressService.deactivate()}))}));this.projectMapSubscription.add(e)},t.prototype.addKeyboardListeners=function(){var t=this;Mousetrap.bind("ctrl++",(function(e){e.preventDefault(),t.zoomIn()})),Mousetrap.bind("ctrl+-",(function(e){e.preventDefault(),t.zoomOut()})),Mousetrap.bind("ctrl+0",(function(e){e.preventDefault(),t.resetZoom()})),Mousetrap.bind("ctrl+a",(function(e){e.preventDefault();var n=t.mapNodesDataSource.getItems(),i=t.mapDrawingsDataSource.getItems(),r=t.mapLinksDataSource.getItems(),o=t.mapSymbolsDataSource.getItems();t.selectionManager.setSelected(n.concat(i).concat(r).concat(o))})),Mousetrap.bind("ctrl+h",(function(e){e.preventDefault(),t.toolbarVisibility=!t.toolbarVisibility})),Mousetrap.bind("ctrl+shift+a",(function(e){e.preventDefault(),t.selectionManager.setSelected([])})),Mousetrap.bind("ctrl+shift+s",(function(e){e.preventDefault(),t.router.navigate(["/server",t.server.id,"preferences"])}))},t.prototype.onProjectLoad=function(t){var e=this;this.readonly=this.projectService.isReadOnly(t);var n=this.projectService.nodes(this.server,t.project_id).pipe(Object(IX.a)((function(n){return e.nodesDataSource.set(n),e.projectService.links(e.server,t.project_id)})),Object(IX.a)((function(n){return e.linksDataSource.set(n),e.projectService.drawings(e.server,t.project_id)}))).subscribe((function(n){e.drawingsDataSource.set(n),e.setUpMapCallbacks(),e.setUpProjectWS(t),e.progressService.deactivate()}));this.projectMapSubscription.add(n)},t.prototype.setUpProjectWS=function(t){var e=this;this.projectws=new WebSocket(this.projectService.notificationsPath(this.server,t.project_id)),this.projectws.onmessage=function(t){e.projectWebServiceHandler.handleMessage(JSON.parse(t.data))},this.projectws.onerror=function(t){e.toasterService.error("Connection to host lost. Error: "+t.data)}},t.prototype.setUpWS=function(){this.ws=new WebSocket(this.notificationService.notificationsPath(this.server))},t.prototype.setUpMapCallbacks=function(){var t=this;this.readonly||this.toolsService.selectionToolActivation(!0);var e=this.linkWidget.onContextMenu.subscribe((function(e){var n=t.mapLinkToLink.convert(e.link);t.contextMenu.openMenuForListOfElements([],[],[],[n],e.event.pageY,e.event.pageX)})),n=this.ethernetLinkWidget.onContextMenu.subscribe((function(e){var n=t.mapLinkToLink.convert(e.link);t.contextMenu.openMenuForListOfElements([],[],[],[n],e.event.pageY,e.event.pageX)})),i=this.serialLinkWidget.onContextMenu.subscribe((function(e){var n=t.mapLinkToLink.convert(e.link);t.contextMenu.openMenuForListOfElements([],[],[],[n],e.event.pageY,e.event.pageX)})),r=this.nodeWidget.onContextMenu.subscribe((function(e){var n=t.mapNodeToNode.convert(e.node);t.contextMenu.openMenuForNode(n,e.event.pageY,e.event.pageX)})),o=this.drawingsWidget.onContextMenu.subscribe((function(e){var n=t.mapDrawingToDrawing.convert(e.drawing);t.contextMenu.openMenuForDrawing(n,e.event.pageY,e.event.pageX)})),a=this.labelWidget.onContextMenu.subscribe((function(e){var n=t.mapLabelToLabel.convert(e.label),i=t.nodes.find((function(t){return t.node_id===e.label.nodeId}));t.contextMenu.openMenuForLabel(n,i,e.event.pageY,e.event.pageX)})),s=this.interfaceLabelWidget.onContextMenu.subscribe((function(e){var n=t.mapLinkNodeToLinkNode.convert(e.interfaceLabel),i=t.links.find((function(t){return t.link_id===e.interfaceLabel.linkId}));t.contextMenu.openMenuForInterfaceLabel(n,i,e.event.pageY,e.event.pageX)})),c=this.selectionTool.contextMenuOpened.subscribe((function(e){var n=t.selectionManager.getSelected();if(!(n.length<2)&&e instanceof MouseEvent){var i=[],r=[],o=[],a=[];n.forEach((function(e){e instanceof I9?i.push(t.mapDrawingToDrawing.convert(e)):e instanceof ket?r.push(t.mapNodeToNode.convert(e)):e instanceof Cet?o.push(t.mapLabelToLabel.convert(e)):e instanceof Iet&&a.push(t.mapLinkToLink.convert(e))})),t.contextMenu.openMenuForListOfElements(i,r,o,a,e.pageY,e.pageX)}}));this.projectMapSubscription.add(e),this.projectMapSubscription.add(n),this.projectMapSubscription.add(i),this.projectMapSubscription.add(r),this.projectMapSubscription.add(o),this.projectMapSubscription.add(c),this.projectMapSubscription.add(a),this.projectMapSubscription.add(s),this.mapChangeDetectorRef.detectChanges()},t.prototype.onNodeCreation=function(t){var e=this;t&&(this.progressService.activate(),this.nodeService.createFromTemplate(this.server,this.project,t.template,t.x,t.y,t.server).subscribe((function(n){e.projectService.nodes(e.server,e.project.project_id).subscribe((function(n){n.filter((function(t){return null===t.label.style})).forEach((function(t){var n=e.nodeCreatedLabelStylesFixer.fix(t);e.nodeService.updateLabel(e.server,t,n.label).subscribe()})),e.nodesDataSource.set(n),t.numberOfNodes--,t.numberOfNodes>0?(t.x=t.x+50<e.project.scene_width/2?t.x+50:t.x,t.y=t.y+50<e.project.scene_height/2?t.y+50:t.y,e.onNodeCreation(t)):e.progressService.deactivate()}))}),(function(t){e.toasterService.error(t.error.message),e.progressService.deactivate()})))},t.prototype.fitInView=function(){if(this.drawings.forEach((function(t){var e=t.svg.split('"'),n=parseInt(e[1],10),i=parseInt(e[3],10);t.element={width:i,height:n}})),0!==this.nodes.length||0!==this.drawings.length){var t,e,n,i,r=[];this.nodes.forEach((function(t){var e=new qut;e.node=t,e.top=t.y,e.left=t.x,e.bottom=t.y+t.height,e.right=t.x+t.width,t.y+t.label.y<e.top&&(e.top=t.y+t.label.y),t.x+t.label.x<e.left&&(e.left=t.x+t.label.x),t.y+t.label.y>e.bottom&&(e.bottom=t.y+t.label.y),t.x+t.label.x>e.right&&(e.right=t.x+t.label.x),r.push(e)}));var o=r.sort((function(t,e){return t.left-e.left}))[0],a=r.sort((function(t,e){return t.right-e.right}))[r.length-1],s=r.sort((function(t,e){return t.top-e.top}))[0],c=r.sort((function(t,e){return t.bottom-e.bottom}))[r.length-1],l=[];this.drawings.forEach((function(t){var e=new Gut;e.drawing=t,e.top=t.y,e.left=t.x,e.bottom=t.y+t.element.height,e.right=t.x+t.element.width,l.push(e)}));var u=l.sort((function(t,e){return t.left-e.left}))[0],h=l.sort((function(t,e){return t.right-e.right}))[l.length-1],d=l.sort((function(t,e){return t.top-e.top}))[0],f=l.sort((function(t,e){return t.bottom-e.bottom}))[l.length-1];u&&o?(t=o.left<u.left?o.left:u.left,e=a.right>h.right?a.right:h.right,n=s.top<d.top?s.top:d.top,i=c.bottom>f.bottom?c.bottom:f.bottom):o&&!u?(t=o.left,e=a.right,n=s.top,i=c.bottom):u&&!o?(t=u.left,e=h.right,n=d.top,i=f.bottom):(t=0,e=0,n=0,i=0),t-=20,e+=20,n-=20,i+=20;var p=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,m=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight,g=e-t,v=i-n,b=v/m,y=1/Math.max(g/p,b);y!==this.mapScaleService.currentScale?(this.mapScaleService.setScale(y),this.project.scene_width=this.project.scene_width*y,this.project.scene_height=this.project.scene_height*y,b<g?(this.scrollX=t*y-(p-g*y)/2+this.project.scene_width/2,this.scrollY=n*y+this.project.scene_height/2):(this.scrollX=t*y+this.project.scene_width/2,this.scrollY=n*y-(m-v*y)/2+this.project.scene_height/2)):(this.scrollX=t*y+this.project.scene_width/2,this.scrollY=n*y+this.project.scene_height/2),this.scrollEnabled=!0}},t.prototype.centerCanvas=function(){window.scrollTo(this.scrollX,this.scrollY),this.scrollEnabled=!1},t.prototype.centerView=function(){if(this.project){var t=this.project.scene_width-document.documentElement.clientWidth>0?(this.project.scene_width-document.documentElement.clientWidth)/2:0,e=this.project.scene_height-document.documentElement.clientHeight>0?(this.project.scene_height-document.documentElement.clientHeight)/2:0;window.scrollTo(t,e)}else this.toasterService.error("Please wait until all components are loaded.")},t.prototype.onDrawingSaved=function(){this.projectMapMenuComponent.resetDrawToolChoice()},Object.defineProperty(t.prototype,"readonly",{get:function(){return this.inReadOnlyMode},set:function(t){this.inReadOnlyMode=t,t?(this.tools.selection=!1,this.toolsService.selectionToolActivation(!1)):(this.tools.selection=!0,this.toolsService.selectionToolActivation(!0))},enumerable:!1,configurable:!0}),t.prototype.toggleMovingMode=function(){this.tools.moving=!this.tools.moving,this.movingEventSource.movingModeState.emit(this.tools.moving),this.readonly||(this.tools.selection=!this.tools.moving,this.toolsService.selectionToolActivation(this.tools.selection))},t.prototype.toggleDrawLineMode=function(){this.tools.draw_link=!this.tools.draw_link,this.toolsService.drawLinkToolActivation(this.tools.draw_link)},t.prototype.toggleShowInterfaceLabels=function(t){this.isInterfaceLabelVisible=t,this.mapSettingsService.toggleShowInterfaceLabels(this.isInterfaceLabelVisible),this.mapSettingsService.mapRenderedEmitter.emit(!0)},t.prototype.toggleShowConsole=function(t){this.isConsoleVisible=t,this.mapSettingsService.toggleLogConsole(this.isConsoleVisible)},t.prototype.toggleShowTopologySummary=function(t){this.isTopologySummaryVisible=t,this.mapSettingsService.toggleTopologySummary(this.isTopologySummaryVisible)},t.prototype.toggleNotifications=function(t){this.notificationsVisibility=t,this.notificationsVisibility?localStorage.setItem("notificationsVisibility","true"):localStorage.removeItem("notificationsVisibility")},t.prototype.toggleLayers=function(t){this.layersVisibility=t,this.mapSettingsService.toggleLayers(t),this.layersVisibility?localStorage.setItem("layersVisibility","true"):localStorage.removeItem("layersVisibility"),this.mapChild.applyMapSettingsChanges()},t.prototype.toggleGrid=function(t){this.gridVisibility=t,this.gridVisibility?localStorage.setItem("gridVisibility","true"):localStorage.removeItem("gridVisibility"),this.mapChild.gridVisibility=this.gridVisibility?1:0},t.prototype.toggleSnapToGrid=function(t){this.project.snap_to_grid=t},t.prototype.showMessage=function(t){this.notificationsVisibility&&("error"===t.type&&this.toasterService.error(t.message),"warning"===t.type&&this.toasterService.warning(t.message))},t.prototype.hideMenu=function(){this.projectMapMenuComponent.resetDrawToolChoice(),this.isProjectMapMenuVisible=!1},t.prototype.showMenu=function(){this.isProjectMapMenuVisible=!0},t.prototype.zoomIn=function(){this.mapScaleService.setScale(this.mapScaleService.getScale()+.1)},t.prototype.zoomOut=function(){var t=this.mapScaleService.getScale();t-.1>0&&this.mapScaleService.setScale(t-.1)},t.prototype.resetZoom=function(){this.mapScaleService.resetToDefault()},t.prototype.addNewProject=function(){this.dialog.open(wrt,{width:"400px",autoFocus:!1,disableClose:!0}).componentInstance.server=this.server},t.prototype.saveProject=function(){var t=this.dialog.open(xrt,{width:"400px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.project=this.project},t.prototype.editProject=function(){var t=this.dialog.open(Rrt,{width:"600px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.project=this.project},t.prototype.importProject=function(){var t=this,e="",n=this.dialog.open(grt,{width:"400px",autoFocus:!1,disableClose:!0});n.componentInstance.server=this.server;var i=n.componentInstance.onImportProject.subscribe((function(t){e=t}));n.afterClosed().subscribe((function(){if(i.unsubscribe(),e){t.bottomSheet.open(Wrt);var n=t.bottomSheet._openedBottomSheetRef;n.instance.projectMessage="imported project",n.afterDismissed().subscribe((function(n){n&&t.projectService.open(t.server,e).subscribe((function(){t.router.navigate(["/server",t.server.id,"project",e])}))}))}}))},t.prototype.exportProject=function(){this.nodes.filter((function(t){return"virtualbox"===t.node_type})).length>0?this.toasterService.error("Map with VirtualBox machines cannot be exported."):this.nodes.filter((function(t){return"started"===t.status&&"vpcs"===t.node_type||"started"===t.status&&"virtualbox"===t.node_type||"started"===t.status&&"vmware"===t.node_type})).length>0?this.toasterService.error("Project with running nodes cannot be exported."):location.assign(this.projectService.getExportPath(this.server,this.project))},t.prototype.uploadImageFile=function(t){this.readImageFile(t.target)},t.prototype.readImageFile=function(t){var e=this,n=t.files[0],i=new FileReader,r=new Image;i.onloadend=function(){e.drawingService.add(e.server,e.project.project_id,-r.width/2,-r.height/2,'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" \n height="'+r.height+'" width="'+r.width+'">\n<image height="'+r.height+'" width="'+r.width+'" \n xlink:href="'+i.result+'"/>\n</svg>').subscribe((function(){}))},r.onload=function(){i.readAsDataURL(n)},r.src=window.URL.createObjectURL(n)},t.prototype.closeProject=function(){var t=this;this.bottomSheet.open(Xrt);var e=this.bottomSheet._openedBottomSheetRef;e.instance.message="Do you want to close the project?",e.afterDismissed().subscribe((function(e){e&&t.projectService.close(t.server,t.project.project_id).subscribe((function(){t.router.navigate(["/server",t.server.id,"projects"])}))}))},t.prototype.deleteProject=function(){var t=this;this.bottomSheet.open(Xrt);var e=this.bottomSheet._openedBottomSheetRef;e.instance.message="Do you want to delete the project?",e.afterDismissed().subscribe((function(e){e&&t.projectService.delete(t.server,t.project.project_id).subscribe((function(){t.router.navigate(["/server",t.server.id,"projects"])}))}))},t.prototype.addNewTemplate=function(){var t=this.dialog.open(nst,{width:"1000px",maxHeight:"700px",autoFocus:!1,disableClose:!0}).componentInstance;t.server=this.server,t.project=this.project},t.prototype.ngOnDestroy=function(){this.nodeConsoleService.openConsoles=0,this.title.setTitle("GNS3 Web UI"),this.drawingsDataSource.clear(),this.nodesDataSource.clear(),this.linksDataSource.clear(),this.projectws&&this.projectws.OPEN&&this.projectws.close(),this.ws&&this.ws.OPEN&&this.ws.close(),this.projectMapSubscription.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da($Q),da(E2),da(x9),da(yet),da(vet),da(_et),da(mnt),da(Tnt),da(Knt),da(fnt),da(qnt),da(jnt),da(vit),da(Ent),da(_it),da(yit),da(M9),da(G9),da(E9),da(QQ),da($nt),da(Zet),da(Nnt),da(bit),da(iit),da(tit),da(wit),da(Y2),da(e1),da(lQ),da(Het),da(Vet),da(qet),da(Wet),da($8),da(Unt),da(znt),da(qrt),da(Yrt),da(Kit),da(Yd),da(Q8))},t.\u0275cmp=Ht({type:t,selectors:[["app-project-map"]],viewQuery:function(t,e){var n;1&t&&(nl(get,!0),nl(git,!0),nl(ort,!0)),2&t&&(tl(n=sl())&&(e.contextMenu=n.first),tl(n=sl())&&(e.mapChild=n.first),tl(n=sl())&&(e.projectMapMenuComponent=n.first))},decls:26,vars:35,consts:[["class","project-map",4,"ngIf"],[1,"zoom-buttons",3,"ngClass"],["matTooltip","Zoom in","matTooltipClass","custom-tooltip",1,"zoom-button",3,"ngClass","click"],["matTooltip","Reset zoom","matTooltipClass","custom-tooltip",1,"zoom-button",3,"ngClass","click"],["matTooltip","Zoom out","matTooltipClass","custom-tooltip",1,"zoom-button",3,"ngClass","click"],[3,"project","server",4,"ngIf"],[3,"links",4,"ngIf"],[3,"server","project"],[3,"server"],[3,"server","project","drawingSaved"],[3,"ngClass"],[3,"server","project","closeConsole",4,"ngIf"],[3,"server","project","closeTopologySummary",4,"ngIf"],[1,"project-map"],[3,"server","project","symbols","nodes","links","drawings","width","height","show-interface-labels","readonly","nodeDragged","drawingDragged","onLinkCreated","onDrawingResized",4,"ngIf"],[3,"symbols","nodes","links","drawings","width","height","show-interface-labels","selection-tool","moving-tool","draw-link-tool","readonly",4,"ngIf"],["class","project-toolbar",4,"ngIf"],["id","show-menu-wrapper",3,"ngClass",4,"ngIf"],["id","menu-wrapper",3,"ngClass",4,"ngIf"],[3,"project","server"],[3,"server","project","symbols","nodes","links","drawings","width","height","show-interface-labels","readonly","nodeDragged","drawingDragged","onLinkCreated","onDrawingResized"],[3,"symbols","nodes","links","drawings","width","height","show-interface-labels","selection-tool","moving-tool","draw-link-tool","readonly"],[1,"project-toolbar"],["color","primary",1,"project-toolbar",3,"ngClass"],[4,"ngIf"],[3,"overlapTrigger"],["mainMenu","matMenu"],["mat-menu-item","",3,"routerLink"],["mat-menu-item","",3,"click"],["mat-menu-item","",3,"matMenuTriggerFor"],["projectMenu","matMenu"],["viewMenu","matMenu"],[1,"options-item"],[3,"ngModel","change"],["matTooltip","Enable/disable moving mode","matTooltipClass","custom-tooltip","mat-icon-button","",3,"color","click"],["matTooltip","Open menu","matTooltipClass","custom-tooltip","mat-icon-button","",3,"matMenuTriggerFor"],["svgIcon","gns3"],["svgIcon","gns3black"],[3,"server","project","onNodeCreation"],["matTooltip","Add a link","matTooltipClass","custom-tooltip","mat-icon-button","",3,"color","click"],["matTooltip","Fit in view","matTooltipClass","custom-tooltip","mat-icon-button","",3,"click"],["matTooltip","Center view","matTooltipClass","custom-tooltip","mat-icon-button","",3,"click"],["id","show-menu-wrapper",3,"ngClass"],["mat-icon-button","",1,"arrow-button",3,"ngClass","click"],[1,"unmarked"],["id","menu-wrapper",3,"ngClass"],[1,"divider",3,"vertical"],[3,"links"],[3,"server","project","closeConsole"],[3,"server","project","closeTopologySummary"]],template:function(t,e){1&t&&(ua(0,Fut,7,7,"div",0),ga(1,"div",1),ga(2,"button",2),xa("click",(function(){return e.zoomIn()})),ga(3,"mat-icon"),ds(4,"zoom_in"),va(),va(),ga(5,"button",3),xa("click",(function(){return e.resetZoom()})),ga(6,"mat-icon"),ds(7,"adjust"),va(),va(),ga(8,"button",4),xa("click",(function(){return e.zoomOut()})),ga(9,"mat-icon"),ds(10,"zoom_out"),va(),va(),va(),ba(11,"app-progress"),ua(12,Nut,1,2,"app-project-map-shortcuts",5),ua(13,But,1,1,"app-draw-link-tool",6),ba(14,"app-drawing-dragged",7),ba(15,"app-drawing-resized",8),ba(16,"app-interface-label-dragged",8),ba(17,"app-link-created",7),ba(18,"app-node-dragged",7),ba(19,"app-node-label-dragged",8),ga(20,"app-text-added",9),xa("drawingSaved",(function(){return e.onDrawingSaved()})),va(),ba(21,"app-text-edited",8),ga(22,"div",10),ua(23,Hut,1,2,"app-console-wrapper",11),va(),ga(24,"div",10),ua(25,zut,1,2,"app-topology-summary",12),va()),2&t&&(pa("ngIf",e.project),Qi(1),pa("ngClass",Ic(23,Eut,e.isLightThemeEnabled)),Qi(1),pa("ngClass",Ic(25,Eut,e.isLightThemeEnabled)),Qi(3),pa("ngClass",Ic(27,Eut,e.isLightThemeEnabled)),Qi(3),pa("ngClass",Ic(29,Eut,e.isLightThemeEnabled)),Qi(4),pa("ngIf",e.project),Qi(1),pa("ngIf",e.tools.draw_link),Qi(1),pa("server",e.server)("project",e.project),Qi(1),pa("server",e.server),Qi(1),pa("server",e.server),Qi(1),pa("server",e.server)("project",e.project),Qi(1),pa("server",e.server)("project",e.project),Qi(1),pa("server",e.server),Qi(1),pa("server",e.server)("project",e.project),Qi(1),pa("server",e.server),Qi(1),pa("ngClass",Ic(31,Vut,!e.isConsoleVisible)),Qi(1),pa("ngIf",e.project),Qi(1),pa("ngClass",Ic(33,Vut,!e.isTopologySummaryVisible)),Qi(1),pa("ngIf",e.project))},directives:[Ah,Oh,k4,x2,gst,vst,bst,yst,_st,wst,kst,Cst,Sst,get,git,Cct,Tct,D0,E0,hQ,Pct,N0,F5,mf,Sp,Mct,a2,ilt,glt,vlt,a8,ort,blt,xlt,out,yut],styles:[".wrapper{height:600px}.project-map,app-map,app-project-map,app-root{width:auto}svg.map{background-color:#f0f0f0}g.node:hover{background-color:#0097a7}.project-toolbar{width:70px;position:fixed;top:20px;left:20px;box-shadow:0 4px 8px 0 rgba(0,0,0,.2),0 6px 20px 0 rgba(0,0,0,.19)}img{-webkit-filter:invert(1);filter:invert(1)}.lightTheme{background:#fff!important;color:#000!important}#show-menu-wrapper{position:fixed;background:transparent;top:20px;left:92px;background:#263238;height:72px;padding-top:16px}#show-menu-wrapper .arrow-button{outline:0!important}.shadowed{box-shadow:0 4px 8px -4px rgba(0,0,0,.2),0 6px 20px -20px rgba(0,0,0,.19)}.non-visible{display:none}#menu-wrapper{position:fixed;background:transparent;top:20px;left:92px;background:#263238;height:72px;padding-top:16px;padding-bottom:16px;transition:35s;width:0;overflow:hidden;transition:.15s;box-shadow:0 4px 8px 0 rgba(0,0,0,.2),0 6px 20px 0 rgba(0,0,0,.19);display:flex}#menu-wrapper .menu-button{width:40px;margin-right:12px!important;margin-left:12px!important;background:transparent;padding:0;border:none;background-color:transparent}#menu-wrapper .arrow-button,#menu-wrapper .menu-button{outline:0!important;transition:.5s;margin-bottom:16px}.extended{width:830px!important;height:100%;overflow:hidden}mat-divider.divider{height:40px;margin-left:1px;margin-right:7px;width:10px;color:grey}.zoom-buttons{position:fixed;background:#263238;bottom:20px;right:20px;display:grid;color:#fff}.zoom-buttons .zoom-button{outline:none;height:40px;width:40px;background:transparent;border:none;color:#fff;font-size:1.25rem;font-weight:700}.zoom-buttons .zoom-button mat-icon{margin-left:-6px}@-moz-document url-prefix(){.mat-drawer-content{display:inline!important}}.shadow{box-shadow:0 4px 8px 0 rgba(0,0,0,.2),0 6px 20px 0 rgba(0,0,0,.19)}.mat-drawer-backdrop.mat-drawer-shown{background-color:transparent}.project-toolbar .mat-toolbar-multiple-rows{width:auto!important}.loading-spinner{position:absolute;top:50%;width:100px;margin-left:-50px;margin-top:-50px;left:50%}line.selected{stroke:#0097a7!important}g.selected,svg.map image.chosen,svg.map image:hover{-webkit-filter:grayscale(100%);-moz-filter:grayscale(100%);-ms-filter:grayscale(100%);-o-filter:grayscale(100%);filter:grayscale(100%);-webkit-filter:grey;filter:gray;-webkit-filter:url(#grayscale);filter:url(#grayscale)}path.selected{stroke:#8b0000}.selected>.interface_label_border{stroke:#000;fill:none}.selection-line-tool .selection{fill:#7ccbe1;stroke:#66aec2;fill-opacity:.3;stroke-opacity:.7;stroke-width:1;stroke-dasharray:5,5}.noselect,g.node text{-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.project-toolbar button{outline:0;border:none;-moz-outline-style:none}.options-item{padding-left:15px;padding-right:15px}.context-menu-items .mat-menu-item{line-height:24px!important;height:24px!important;font-size:13px!important;padding:0 6px;outline:none!important}.context-menu-items .mat-menu-item .mat-icon{margin-right:3px}.context-menu-items .mat-menu-item:focus{background:none}.visible{display:none}mat-menu-panel{min-height:0}"],encapsulation:2}),t}(),qut=function(){return function(){}}(),Gut=function(){return function(){}}(),Wut=function(){function t(){this.dataChange=new Pm.a([])}return Object.defineProperty(t.prototype,"data",{get:function(){return this.dataChange.value},enumerable:!1,configurable:!0}),t.prototype.addServer=function(t){var e=this.data.slice();e.push(t),this.dataChange.next(e)},t.prototype.addServers=function(t){this.dataChange.next(t)},t.prototype.remove=function(t){var e=this.data.indexOf(t);e>=0&&(this.data.splice(e,1),this.dataChange.next(this.data.slice()))},t.prototype.find=function(t){return this.data.find((function(e){return e.name===t}))},t.prototype.findIndex=function(t){return this.data.findIndex((function(e){return e.name===t}))},t.prototype.update=function(t){var e=this.findIndex(t.name);e>=0&&(this.data[e]=t,this.dataChange.next(this.data.slice()))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function Kut(t,e){1&t&&(ga(0,"mat-error"),ds(1,"You must enter a value"),va())}function Xut(t,e){if(1&t&&(ga(0,"mat-option",12),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.key),Qi(1),ps(" ",n.name," ")}}function Yut(t,e){1&t&&(ga(0,"mat-form-field"),ba(1,"input",13),va())}function Zut(t,e){1&t&&(ga(0,"mat-form-field"),ba(1,"input",14),va())}function Qut(t,e){if(1&t&&(ga(0,"mat-option",12),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.key),Qi(1),ps(" ",n.name," ")}}function $ut(t,e){if(1&t&&(ga(0,"mat-form-field"),ga(1,"mat-select",15),ua(2,Qut,2,2,"mat-option",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngForOf",n.authorizations)}}function Jut(t,e){1&t&&(ga(0,"mat-form-field"),ba(1,"input",16),va())}function tht(t,e){1&t&&(ga(0,"mat-form-field"),ba(1,"input",17),va())}var eht=function(){function t(t,e,n,i,r){this.dialogRef=t,this.electronService=e,this.serverService=n,this.toasterService=i,this.data=r,this.authorizations=[{key:"none",name:"No authorization"},{key:"basic",name:"Basic authorization"}],this.locations=[],this.serverForm=new dp({name:new hp("",[kf.required]),location:new hp(""),path:new hp(""),ubridge_path:new hp(""),host:new hp("",[kf.required]),port:new hp("",[kf.required,kf.min(1)]),authorization:new hp("none"),login:new hp(""),password:new hp("")})}return t.prototype.getLocations=function(){return UQ(this,void 0,void 0,(function(){var t,e;return qQ(this,(function(n){switch(n.label){case 0:return[4,this.numberOfLocalServers()];case 1:return t=n.sent(),e=[],this.electronService.isElectronApp&&0===t&&e.push({key:"local",name:"Local"}),e.push({key:"remote",name:"Remote"}),[2,e]}}))}))},t.prototype.getDefaultLocation=function(){return UQ(this,void 0,void 0,(function(){var t;return qQ(this,(function(e){switch(e.label){case 0:return[4,this.numberOfLocalServers()];case 1:return t=e.sent(),this.electronService.isElectronApp&&0===t?[2,"local"]:[2,"remote"]}}))}))},t.prototype.numberOfLocalServers=function(){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(t){switch(t.label){case 0:return[4,this.serverService.findAll()];case 1:return[2,t.sent().filter((function(t){return"local"===t.location})).length]}}))}))},t.prototype.getDefaultHost=function(){return"127.0.0.1"},t.prototype.getDefaultPort=function(){return 3080},t.prototype.getDefaultLocalServerPath=function(){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(t){switch(t.label){case 0:return this.electronService.isElectronApp?[4,this.electronService.remote.require("./local-server.js").getLocalServerPath()]:[3,2];case 1:return[2,t.sent()];case 2:return[2]}}))}))},t.prototype.getDefaultUbridgePath=function(){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(t){switch(t.label){case 0:return this.electronService.isElectronApp?[4,this.electronService.remote.require("./local-server.js").getUbridgePath()]:[3,2];case 1:return[2,t.sent()];case 2:return[2]}}))}))},t.prototype.ngOnInit=function(){return UQ(this,void 0,void 0,(function(){var t,e,n,i,r=this;return qQ(this,(function(o){switch(o.label){case 0:return t=this,[4,this.getLocations()];case 1:return t.locations=o.sent(),[4,this.getDefaultLocalServerPath()];case 2:return e=o.sent(),[4,this.getDefaultUbridgePath()];case 3:return n=o.sent(),this.serverForm.get("location").valueChanges.subscribe((function(t){var i=r.serverForm.get("path"),o=r.serverForm.get("ubridge_path");"local"===t?(i.setValue(e),i.setValidators([kf.required]),o.setValue(n),o.setValidators([kf.required])):(i.setValue(""),i.clearValidators(),o.setValue(""),o.clearValidators()),[i,o].forEach((function(t){t.updateValueAndValidity({onlySelf:!0})}))})),this.serverForm.get("authorization").valueChanges.subscribe((function(t){var e=r.serverForm.get("login"),n=r.serverForm.get("password");"none"===t?(e.clearValidators(),n.clearValidators()):(e.setValidators([kf.required]),n.setValidators([kf.required])),[e,n].forEach((function(t){t.updateValueAndValidity({onlySelf:!0})}))})),[4,this.getDefaultLocation()];case 4:return i=o.sent(),this.serverForm.get("location").setValue(i),this.serverForm.get("host").setValue(this.getDefaultHost()),this.serverForm.get("port").setValue(this.getDefaultPort()),this.serverForm.get("authorization").setValue("none"),[2]}}))}))},t.prototype.onAddClick=function(){var t=this;if(this.serverForm.valid){var e=Object.assign({},this.serverForm.value);this.serverService.checkServerVersion(e).subscribe((function(n){n.version.split(".")[1]>=2&&n.version.split(".")[0]>=2?(t.dialogRef.close(e),t.toasterService.success("Server "+e.name+" added.")):(t.dialogRef.close(),t.toasterService.error("Server version is not supported."))}),(function(e){t.toasterService.error("Cannot connect to the server: "+e)}))}},t.prototype.onNoClick=function(){this.dialogRef.close()},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(mX),da(ZQ),da(Y2),da(Q0))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-server-dialog"]],decls:24,vars:8,consts:[["mat-dialog-title",""],[3,"formGroup"],["mat-dialog-content",""],["matInput","","tabindex","1","formControlName","name","placeholder","Name"],[4,"ngIf"],["placeholder","Location","formControlName","location"],[3,"value",4,"ngFor","ngForOf"],["matInput","","tabindex","1","formControlName","host","placeholder","Host"],["matInput","","tabindex","1","formControlName","port","placeholder","Port"],["mat-dialog-actions",""],["mat-button","","tabindex","-1","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"],[3,"value"],["matInput","","tabindex","1","formControlName","path","placeholder","Local server path"],["matInput","","tabindex","1","formControlName","ubridge_path","placeholder","Ubridge path"],["placeholder","Authorization","formControlName","authorization"],["matInput","","tabindex","1","formControlName","login","placeholder","Login"],["matInput","","tabindex","1","formControlName","password","placeholder","Password"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Add server"),va(),ga(2,"form",1),ga(3,"div",2),ga(4,"mat-form-field"),ba(5,"input",3),ua(6,Kut,2,0,"mat-error",4),va(),ga(7,"mat-form-field"),ga(8,"mat-select",5),ua(9,Xut,2,2,"mat-option",6),va(),va(),ua(10,Yut,2,0,"mat-form-field",4),ua(11,Zut,2,0,"mat-form-field",4),ga(12,"mat-form-field"),ba(13,"input",7),va(),ga(14,"mat-form-field"),ba(15,"input",8),va(),ua(16,$ut,3,1,"mat-form-field",4),ua(17,Jut,2,0,"mat-form-field",4),ua(18,tht,2,0,"mat-form-field",4),va(),ga(19,"div",9),ga(20,"button",10),xa("click",(function(){return e.onNoClick()})),ds(21,"No Thanks"),va(),ga(22,"button",11),xa("click",(function(){return e.onAddClick()})),ds(23,"Add"),va(),va(),va()),2&t&&(Qi(2),pa("formGroup",e.serverForm),Qi(4),pa("ngIf",e.serverForm.get("name").hasError("required")),Qi(3),pa("ngForOf",e.locations),Qi(1),pa("ngIf","local"===e.serverForm.get("location").value),Qi(1),pa("ngIf","local"===e.serverForm.get("location").value),Qi(5),pa("ngIf","remote"===e.serverForm.get("location").value),Qi(1),pa("ngIf","basic"===e.serverForm.get("authorization").value),Qi(1),pa("ngIf","basic"===e.serverForm.get("authorization").value))},directives:[r1,xp,gf,Pp,o1,Y3,s5,cf,mf,Fp,Ah,O5,Eh,a1,a2,R3,EJ],encapsulation:2}),t}(),nht=function(){function t(t){var e=this;this.electronService=t,this.serverStatusChanged=new w.b,this.electronService.isElectronApp&&this.electronService.ipcRenderer.on(this.statusChannel,(function(t,n){e.serverStatusChanged.next(n)}))}return Object.defineProperty(t.prototype,"statusChannel",{get:function(){return"local-server-status-events"},enumerable:!1,configurable:!0}),t.prototype.start=function(t){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(e){switch(e.label){case 0:return this.serverStatusChanged.next({serverName:t.name,status:"starting",message:""}),[4,this.electronService.remote.require("./local-server.js").startLocalServer(t)];case 1:return[2,e.sent()]}}))}))},t.prototype.stop=function(t){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(e){switch(e.label){case 0:return[4,this.electronService.remote.require("./local-server.js").stopLocalServer(t)];case 1:return[2,e.sent()]}}))}))},t.prototype.stopAll=function(){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(t){switch(t.label){case 0:return[4,this.electronService.remote.require("./local-server.js").stopAllLocalServers()];case 1:return[2,t.sent()]}}))}))},t.prototype.getRunningServers=function(){return this.electronService.isElectronApp?this.electronService.remote.require("./local-server.js").getRunningServers():[]},t.prototype.ngOnDestroy=function(){this.electronService.isElectronApp&&this.electronService.ipcRenderer.removeAllListeners(this.statusChannel)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(mX))}}),t}(),iht=function(){function t(){}return Object.defineProperty(t.prototype,"child_process",{get:function(){return this._child_process||(this._child_process=window.require?window.require("child_process"):null),this._child_process},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isElectronApp",{get:function(){return!!window.navigator.userAgent.match(/Electron/)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"childProcess",{get:function(){return this.child_process?this.child_process:null},enumerable:!0,configurable:!0}),t}(),rht=function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function i(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}(),oht=function(t){function e(){return t.call(this)||this}return rht(e,t),e.\u0275fac=function(t){return new(t||e)},e.\u0275prov=R({token:e,factory:function(t){return e.\u0275fac(t)}}),e}(iht),aht=function(){function t(){}return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[{provide:iht,useClass:oht}]}),t}(),sht=n("M6kn"),cht=function(){function t(t){this.httpServer=t}return t.prototype.get=function(t){return this.httpServer.get(t,"/version")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function lht(t,e){if(1&t){var n=ka();ga(0,"mat-card",2),ga(1,"mat-card-content",3),ds(2," We've discovered GNS3 server on "),ga(3,"b"),ds(4),va(),ds(5,", would you like to add to the list? "),va(),ga(6,"mat-card-actions",4),ga(7,"button",5),xa("click",(function(){Se(n);var t=Aa();return t.ignore(t.discoveredServer)})),ds(8,"NO"),va(),ga(9,"button",6),xa("click",(function(){Se(n);var t=Aa();return t.accept(t.discoveredServer)})),ds(10,"YES"),va(),va(),va()}if(2&t){var i=Aa();Qi(4),ms("",i.discoveredServer.host,":",i.discoveredServer.port,"")}}function uht(t,e){1&t&&ba(0,"mat-divider")}var hht=function(){function t(t,e,n){this.versionService=t,this.serverService=e,this.serverDatabase=n,this.defaultServers=[{host:"127.0.0.1",port:3080}]}return t.prototype.ngOnInit=function(){var t=this;this.serverService.isServiceInitialized&&this.discoverFirstAvailableServer(),this.serverService.serviceInitialized.subscribe((function(e){return UQ(t,void 0,void 0,(function(){return qQ(this,(function(t){return e&&this.discoverFirstAvailableServer(),[2]}))}))}))},t.prototype.discoverFirstAvailableServer=function(){var t=this;Object(Jd.a)(sht.Observable.fromPromise(this.serverService.findAll()).pipe(Object(ef.a)((function(t){return t}))),this.discovery()).subscribe((function(e){var n=e[1];e[0].forEach((function(t){n=n.filter((function(e){return!(e.host==t.host&&e.port==t.port)}))})),n.length>0&&(t.discoveredServer=n.shift())}))},t.prototype.discovery=function(){var t=this,e=[];return this.defaultServers.forEach((function(n){e.push(t.isServerAvailable(n.host,n.port).catch((function(t){return sht.Observable.of(null)})))})),new sht.Observable((function(t){Object(Jd.a)(e).subscribe((function(e){t.next(e.filter((function(t){return null!=t}))),t.complete()}))}))},t.prototype.isServerAvailable=function(t,e){var n=new BQ;return n.host=t,n.port=e,this.versionService.get(n).flatMap((function(t){return sht.Observable.of(n)}))},t.prototype.ignore=function(t){this.discoveredServer=null},t.prototype.accept=function(t){var e=this;null==t.name&&(t.name=t.host),t.location="remote",this.serverService.create(t).then((function(t){e.serverDatabase.addServer(t),e.discoveredServer=null}))},t.\u0275fac=function(e){return new(e||t)(da(cht),da(ZQ),da(Wut))},t.\u0275cmp=Ht({type:t,selectors:[["app-server-discovery"]],decls:2,vars:2,consts:[["class","info",4,"ngIf"],[4,"ngIf"],[1,"info"],["align","center"],["align","right"],["mat-button","","color","accent",3,"click"],["mat-button","",3,"click"]],template:function(t,e){1&t&&(ua(0,lht,11,2,"mat-card",0),ua(1,uht,1,0,"mat-divider",1)),2&t&&(pa("ngIf",e.discoveredServer),Qi(1),pa("ngIf",e.discoveredServer))},directives:[Ah,f3,n3,o3,a2,a8],styles:[""]}),t}();function dht(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," ID "),va())}function fht(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.id," ")}}function pht(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Name "),va())}var mht=function(t){return["/server",t,"projects"]};function ght(t,e){if(1&t&&(ga(0,"a",22),ds(1),va()),2&t){var n=Aa().$implicit;pa("routerLink",Ic(2,mht,n.id)),Qi(1),fs(n.name)}}function vht(t,e){if(1&t&&(ga(0,"span"),ds(1),va()),2&t){var n=Aa().$implicit;Qi(1),fs(n.name)}}function bht(t,e){if(1&t&&(ga(0,"mat-cell"),ua(1,ght,2,4,"a",20),ua(2,vht,2,1,"span",21),va()),2&t){var n=e.$implicit,i=Aa();Qi(1),pa("ngIf","running"===i.getServerStatus(n)||"remote"===n.location||"bundled"===n.location),Qi(1),pa("ngIf","running"!=i.getServerStatus(n)&&"remote"!==n.location&&"bundled"!==n.location)}}function yht(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Location "),va())}function _ht(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.location," ")}}function wht(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Host "),va())}function kht(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.host," ")}}function Cht(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Port "),va())}function Sht(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.port," ")}}function xht(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Actions "),va())}function Oht(t,e){if(1&t){var n=ka();ga(0,"button",26),xa("click",(function(){Se(n);var t=Aa().$implicit;return Aa().startServer(t)})),ga(1,"mat-icon",28),ds(2,"play_arrow"),va(),va()}}function Mht(t,e){if(1&t){var n=ka();ga(0,"button",26),xa("click",(function(){Se(n);var t=Aa().$implicit;return Aa().stopServer(t)})),ga(1,"mat-icon",29),ds(2,"stop"),va(),va()}}function Tht(t,e){1&t&&ba(0,"mat-spinner",30),2&t&&pa("diameter",24)}function Eht(t,e){if(1&t){var n=ka();ga(0,"mat-cell",23),ua(1,Oht,3,0,"button",24),ua(2,Mht,3,0,"button",24),ua(3,Tht,1,1,"mat-spinner",25),ga(4,"button",26),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().deleteServer(t)})),ga(5,"mat-icon",27),ds(6,"delete"),va(),va(),va()}if(2&t){var i=e.$implicit,r=Aa();Qi(1),pa("ngIf","local"===i.location&&"stopped"===r.getServerStatus(i)),Qi(1),pa("ngIf","local"===i.location&&"running"===r.getServerStatus(i)),Qi(1),pa("ngIf","local"===i.location&&"starting"===r.getServerStatus(i))}}function Pht(t,e){1&t&&ba(0,"mat-header-row")}function Aht(t,e){1&t&&ba(0,"mat-row")}function jht(t,e){if(1&t){var n=ka();ga(0,"button",31),xa("click",(function(){return Se(n),Aa().startLocalServer()})),ds(1,"Start local server"),va()}}var Iht=function(){function t(t,e,n,i,r,o,a,s){this.dialog=t,this.serverService=e,this.serverDatabase=n,this.serverManagement=i,this.changeDetector=r,this.electronService=o,this.childProcessService=a,this.bottomSheet=s,this.displayedColumns=["id","name","location","ip","port","actions"],this.isElectronApp=!1}return t.prototype.getServers=function(){var t=this,e=this.serverManagement.getRunningServers();this.serverService.findAll().then((function(n){n.forEach((function(t){e.findIndex((function(e){return t.name===e}))>=0&&(t.status="running")})),n.forEach((function(e){t.serverService.checkServerVersion(e).subscribe((function(n){n.version.split(".")[1]>=2&&n.version.split(".")[0]>=2&&(t.serverDatabase.find(e.name)||t.serverDatabase.addServer(e))}),(function(t){}))}))}))},t.prototype.ngOnInit=function(){var t=this;this.isElectronApp=this.electronService.isElectronApp,this.serverService.isServiceInitialized&&this.getServers(),this.serverService.serviceInitialized.subscribe((function(e){return UQ(t,void 0,void 0,(function(){return qQ(this,(function(t){return e&&this.getServers(),[2]}))}))})),this.dataSource=new Dht(this.serverDatabase),this.serverStatusSubscription=this.serverManagement.serverStatusChanged.subscribe((function(e){var n=t.serverDatabase.find(e.serverName);n&&("starting"===e.status&&(n.status="starting"),"stopped"===e.status&&(n.status="stopped"),"errored"===e.status&&(n.status="stopped"),"started"===e.status&&(n.status="running"),t.serverDatabase.update(n),t.changeDetector.detectChanges())}))},t.prototype.ngOnDestroy=function(){this.serverStatusSubscription.unsubscribe()},t.prototype.startLocalServer=function(){var t=this.serverDatabase.data.find((function(t){return"bundled"===t.location||"local"}));this.startServer(t)},t.prototype.createModal=function(){var t=this;this.dialog.open(eht,{width:"350px",autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(e){e&&t.serverService.create(e).then((function(e){t.serverDatabase.addServer(e)}))}))},t.prototype.getServerStatus=function(t){if("local"===t.location)return void 0===t.status?"stopped":t.status},t.prototype.deleteServer=function(t){var e=this;this.bottomSheet.open(Xrt);var n=this.bottomSheet._openedBottomSheetRef;n.instance.message="Do you want to delete the server?",n.afterDismissed().subscribe((function(n){n&&e.serverService.delete(t).then((function(){e.serverDatabase.remove(t)}))}))},t.prototype.startServer=function(t){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(e){switch(e.label){case 0:return[4,this.serverManagement.start(t)];case 1:return e.sent(),[2]}}))}))},t.prototype.stopServer=function(t){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(e){switch(e.label){case 0:return[4,this.serverManagement.stop(t)];case 1:return e.sent(),[2]}}))}))},t.\u0275fac=function(e){return new(e||t)(da(e1),da(ZQ),da(Wut),da(nht),da(Po),da(mX),da(iht),da(qrt))},t.\u0275cmp=Ht({type:t,selectors:[["app-server-list"]],decls:33,vars:4,consts:[[1,"content"],[1,"default-header"],[1,"default-content"],[1,"mat-elevation-z8"],[3,"dataSource"],["table",""],["matColumnDef","id"],[4,"matHeaderCellDef"],[4,"matCellDef"],["matColumnDef","name"],["matColumnDef","location"],["matColumnDef","ip"],["matColumnDef","port"],["matColumnDef","actions"],["style","text-align: right",4,"matCellDef"],[4,"matHeaderRowDef"],[4,"matRowDef","matRowDefColumns"],[1,"buttons-bar"],["mat-raised-button","","class","button",3,"click",4,"ngIf"],["mat-raised-button","","color","primary",1,"button",3,"click"],["class","table-link",3,"routerLink",4,"ngIf"],[4,"ngIf"],[1,"table-link",3,"routerLink"],[2,"text-align","right"],["mat-icon-button","",3,"click",4,"ngIf"],[3,"diameter",4,"ngIf"],["mat-icon-button","",3,"click"],["aria-label","Remove server"],["aria-label","Start server"],["aria-label","Stop server"],[3,"diameter"],["mat-raised-button","",1,"button",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"h1"),ds(3,"Servers"),va(),va(),ga(4,"div",2),ba(5,"app-server-discovery"),ga(6,"div",3),ga(7,"mat-table",4,5),ya(9,6),ua(10,dht,2,0,"mat-header-cell",7),ua(11,fht,2,1,"mat-cell",8),_a(),ya(12,9),ua(13,pht,2,0,"mat-header-cell",7),ua(14,bht,3,2,"mat-cell",8),_a(),ya(15,10),ua(16,yht,2,0,"mat-header-cell",7),ua(17,_ht,2,1,"mat-cell",8),_a(),ya(18,11),ua(19,wht,2,0,"mat-header-cell",7),ua(20,kht,2,1,"mat-cell",8),_a(),ya(21,12),ua(22,Cht,2,0,"mat-header-cell",7),ua(23,Sht,2,1,"mat-cell",8),_a(),ya(24,13),ua(25,xht,2,0,"mat-header-cell",7),ua(26,Eht,7,3,"mat-cell",14),_a(),ua(27,Pht,1,0,"mat-header-row",15),ua(28,Aht,1,0,"mat-row",16),va(),va(),ga(29,"div",17),ua(30,jht,2,0,"button",18),ga(31,"button",19),xa("click",(function(){return e.createModal()})),ds(32,"Add server"),va(),va(),va(),va()),2&t&&(Qi(7),pa("dataSource",e.dataSource),Qi(20),pa("matHeaderRowDef",e.displayedColumns),Qi(1),pa("matRowDefColumns",e.displayedColumns),Qi(2),pa("ngIf",e.isElectronApp))},directives:[hht,$5,n4,t4,J5,a4,c4,Ah,a2,i4,o4,dQ,x2,hst,l4,h4],styles:[".buttons-bar[_ngcontent-%COMP%]{padding-top:0}.button[_ngcontent-%COMP%]{margin:20px!important}"]}),t}(),Dht=function(t){function e(e){var n=t.call(this)||this;return n.serverDatabase=e,n}return zQ(e,t),e.prototype.connect=function(){var t=this;return Object(C.a)(this.serverDatabase.dataChange).pipe(Object(ef.a)((function(){return t.serverDatabase.data})))},e.prototype.disconnect=function(){},e}(um),Rht=function(){function t(t,e){this.dialogRef=t,this.projectService=e}return t.prototype.ngOnInit=function(){this.name=this.project.name},t.prototype.onCloseClick=function(){this.dialogRef.close()},t.prototype.onSaveClick=function(){var t=this;this.projectService.duplicate(this.server,this.project.project_id,this.name).subscribe((function(){t.dialogRef.close()}))},t.\u0275fac=function(e){return new(e||t)(da(Z0),da($Q))},t.\u0275cmp=Ht({type:t,selectors:[["app-choose-name-dialog"]],inputs:{server:"server",project:"project"},decls:10,vars:1,consts:[["mat-dialog-title",""],[1,"modal-form-container"],[1,"form-field"],["matInput","","placeholder","Project name","type","text",3,"ngModel","ngModelChange"],["mat-dialog-actions",""],["mat-button","","color","accent",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"h1",0),ds(1,"Please choose name for exporting project"),va(),ga(2,"div",1),ga(3,"mat-form-field",2),ga(4,"input",3),xa("ngModelChange",(function(t){return e.name=t})),va(),va(),va(),ga(5,"div",4),ga(6,"button",5),xa("click",(function(){return e.onCloseClick()})),ds(7,"Cancel"),va(),ga(8,"button",6),xa("click",(function(){return e.onSaveClick()})),ds(9,"Apply"),va(),va()),2&t&&(Qi(4),pa("ngModel",e.name))},directives:[r1,Y3,s5,cf,mf,Sp,a1,a2],styles:[".form-field[_ngcontent-%COMP%]{width:100%}"]}),t}(),Lht=function(){function t(t){this.dialogRef=t,this.message="Do you want to configure GNS3 VM?"}return t.prototype.ngOnInit=function(){},t.prototype.onNoClick=function(){this.dialogRef.close(!1)},t.prototype.onYesClick=function(){this.dialogRef.close(!0)},t.\u0275fac=function(e){return new(e||t)(da(Z0))},t.\u0275cmp=Ht({type:t,selectors:[["app-configure-gns3-vm-dialog"]],decls:7,vars:1,consts:[[1,"message"],["mat-dialog-actions",""],["mat-button","","color","accent",1,"cancelButton",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",1,"confirmButton",3,"click"]],template:function(t,e){1&t&&(ga(0,"span",0),ds(1),va(),ga(2,"div",1),ga(3,"button",2),xa("click",(function(){return e.onNoClick()})),ds(4,"No"),va(),ga(5,"button",3),xa("click",(function(){return e.onYesClick()})),ds(6," Yes "),va(),va()),2&t&&(Qi(1),fs(e.message))},directives:[a1,a2],styles:[""]}),t}();function Fht(t,e){1&t&&(ga(0,"mat-header-cell",21),ds(1," Name "),va())}var Nht=function(t,e){return["/server",t,"project",e]};function Bht(t,e){if(1&t&&(ga(0,"mat-cell"),ga(1,"a",22),ds(2),va(),va()),2&t){var n=e.$implicit,i=Aa();Qi(1),pa("routerLink",Dc(2,Nht,i.server.id,n.project_id)),Qi(1),fs(n.name)}}function Hht(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Actions "),va())}function zht(t,e){if(1&t){var n=ka();ga(0,"button",28),xa("click",(function(){Se(n);var t=Aa().$implicit;return Aa().open(t)})),ga(1,"mat-icon",29),ds(2,"play_arrow"),va(),va()}}function Vht(t,e){if(1&t){var n=ka();ga(0,"button",30),xa("click",(function(){Se(n);var t=Aa().$implicit;return Aa().close(t)})),ga(1,"mat-icon",31),ds(2,"pause"),va(),va()}}function Uht(t,e){if(1&t){var n=ka();ga(0,"button",32),xa("click",(function(){Se(n);var t=Aa().$implicit;return Aa().duplicate(t)})),ga(1,"mat-icon",33),ds(2,"filter_2"),va(),va()}}function qht(t,e){if(1&t){var n=ka();ga(0,"button",34),xa("click",(function(){Se(n);var t=Aa().$implicit;return Aa().delete(t)})),ga(1,"mat-icon",35),ds(2,"delete"),va(),va()}}function Ght(t,e){if(1&t&&(ga(0,"mat-cell",23),ua(1,zht,3,0,"button",24),ua(2,Vht,3,0,"button",25),ua(3,Uht,3,0,"button",26),ua(4,qht,3,0,"button",27),va()),2&t){var n=e.$implicit;Qi(1),pa("ngIf","closed"==n.status),Qi(1),pa("ngIf","opened"==n.status),Qi(1),pa("ngIf","closed"==n.status),Qi(1),pa("ngIf","closed"==n.status)}}function Wht(t,e){1&t&&ba(0,"mat-header-row")}function Kht(t,e){1&t&&ba(0,"mat-row")}var Xht=function(){return{standalone:!0}},Yht=function(){function t(t,e,n,i,r,o,a,s,c){this.route=t,this.projectService=e,this.settingsService=n,this.progressService=i,this.dialog=r,this.router=o,this.bottomSheet=a,this.toasterService=s,this.electronService=c,this.projectDatabase=new Zht,this.displayedColumns=["name","actions"],this.searchText=""}return t.prototype.ngOnInit=function(){var t=this;this.server=this.route.snapshot.data.server,this.server||this.router.navigate(["/servers"]),this.refresh(),this.sort.sort({id:"name",start:"asc"}),this.dataSource=new Qht(this.projectDatabase,this.sort),this.settings=this.settingsService.getAll(),this.projectService.projectListSubject.subscribe((function(){return t.refresh()}));var e=localStorage.getItem("gns3vmConfig");this.electronService.isElectronApp&&"configured"!==e&&this.dialog.open(Lht,{width:"350px",height:"120px",autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(e){e&&(localStorage.setItem("gns3vmConfig","configured"),t.router.navigate(["/server",t.server.id,"preferences","gns3vm"]))}))},t.prototype.goToPreferences=function(){var t=this;this.router.navigate(["/server",this.server.id,"preferences"]).catch((function(e){return t.toasterService.error("Cannot navigate to the preferences")}))},t.prototype.refresh=function(){var t=this;this.projectService.list(this.server).subscribe((function(e){t.projectDatabase.addProjects(e)}),(function(e){t.progressService.setError(e)}))},t.prototype.delete=function(t){var e=this;this.bottomSheet.open(Xrt);var n=this.bottomSheet._openedBottomSheetRef;n.instance.message="Do you want to delete the project?",n.afterDismissed().subscribe((function(n){n&&e.projectService.delete(e.server,t.project_id).subscribe((function(){e.refresh()}))}))},t.prototype.open=function(t){var e=this;this.progressService.activate(),this.projectService.open(this.server,t.project_id).subscribe((function(){e.refresh()}),(function(){e.refresh(),e.progressService.deactivate(),e.toasterService.error("Project was deleted.")}),(function(){e.progressService.deactivate()}))},t.prototype.close=function(t){var e=this;this.bottomSheet.open(Xrt);var n=this.bottomSheet._openedBottomSheetRef;n.instance.message="Do you want to close the project?",n.afterDismissed().subscribe((function(n){n&&e.projectService.close(e.server,t.project_id).subscribe((function(){e.refresh(),e.progressService.deactivate()}))}))},t.prototype.duplicate=function(t){var e=this,n=this.dialog.open(Rht,{width:"400px",autoFocus:!1,disableClose:!0}),i=n.componentInstance;i.server=this.server,i.project=t,n.afterClosed().subscribe((function(){e.refresh()}))},t.prototype.addBlankProject=function(){this.dialog.open(wrt,{width:"400px",autoFocus:!1,disableClose:!0}).componentInstance.server=this.server},t.prototype.importProject=function(){var t=this,e="",n=this.dialog.open(grt,{width:"400px",autoFocus:!1,disableClose:!0});n.componentInstance.server=this.server;var i=n.componentInstance.onImportProject.subscribe((function(t){e=t}));n.afterClosed().subscribe((function(){if(t.refresh(),i.unsubscribe(),e){t.bottomSheet.open(Wrt);var n=t.bottomSheet._openedBottomSheetRef;n.instance.projectMessage="imported project",n.afterDismissed().subscribe((function(n){n&&t.projectService.open(t.server,e).subscribe((function(){t.router.navigate(["/server",t.server.id,"project",e])}))}))}}))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da($Q),da(QQ),da(yet),da(e1),da(lQ),da(qrt),da(Y2),da(mX))},t.\u0275cmp=Ht({type:t,selectors:[["app-projects"]],viewQuery:function(t,e){var n;1&t&&el(mat,!0),2&t&&tl(n=sl())&&(e.sort=n.first)},decls:27,vars:9,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["mat-raised-button","",1,"add-button",3,"click"],["mat-raised-button","","color","primary",1,"add-button",3,"click"],["mat-raised-button","","color","primary",1,"import-button",3,"click"],[1,"full-width"],["matInput","","placeholder","Search by name",3,"ngModel","ngModelOptions","ngModelChange"],[1,"default-content"],[1,"mat-elevation-z8"],["matSort","",3,"dataSource"],["table",""],["matColumnDef","name"],["mat-sort-header","",4,"matHeaderCellDef"],[4,"matCellDef"],["matColumnDef","actions"],[4,"matHeaderCellDef"],["style","text-align: right",4,"matCellDef"],[4,"matHeaderRowDef"],[4,"matRowDef","matRowDefColumns"],["mat-sort-header",""],[1,"table-link",3,"routerLink"],[2,"text-align","right"],["mat-icon-button","","matTooltip","Open project","matTooltipClass","custom-tooltip",3,"click",4,"ngIf"],["mat-icon-button","","matTooltip","Close project","matTooltipClass","custom-tooltip",3,"click",4,"ngIf"],["mat-icon-button","","matTooltip","Duplicate project","matTooltipClass","custom-tooltip",3,"click",4,"ngIf"],["mat-icon-button","","matTooltip","Delete project","matTooltipClass","custom-tooltip",3,"click",4,"ngIf"],["mat-icon-button","","matTooltip","Open project","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Open project"],["mat-icon-button","","matTooltip","Close project","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Close project"],["mat-icon-button","","matTooltip","Duplicate project","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Duplicate project"],["mat-icon-button","","matTooltip","Delete project","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Delete project"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Projects"),va(),ga(5,"button",4),xa("click",(function(){return e.goToPreferences()})),ds(6," Go to preferences "),va(),ga(7,"button",5),xa("click",(function(){return e.addBlankProject()})),ds(8," Add blank project "),va(),ga(9,"button",6),xa("click",(function(){return e.importProject()})),ds(10," Import project "),va(),va(),va(),ga(11,"form"),ga(12,"mat-form-field",7),ga(13,"input",8),xa("ngModelChange",(function(t){return e.searchText=t})),va(),va(),va(),ga(14,"div",9),ga(15,"div",10),ga(16,"mat-table",11,12),Nc(18,"projectsfilter"),ya(19,13),ua(20,Fht,2,0,"mat-header-cell",14),ua(21,Bht,3,5,"mat-cell",15),_a(),ya(22,16),ua(23,Hht,2,0,"mat-header-cell",17),ua(24,Ght,5,4,"mat-cell",18),_a(),ua(25,Wht,1,0,"mat-header-row",19),ua(26,Kht,1,0,"mat-row",20),va(),va(),va(),va()),2&t&&(Qi(13),pa("ngModel",e.searchText)("ngModelOptions",jc(8,Xht)),Qi(3),pa("dataSource",Hc(18,5,e.dataSource,e.searchText)),Qi(9),pa("matHeaderRowDef",e.displayedColumns),Qi(1),pa("matRowDefColumns",e.displayedColumns))},styles:[".add-button[_ngcontent-%COMP%], .import-button[_ngcontent-%COMP%]{height:40px;margin:20px}.full-width[_ngcontent-%COMP%]{width:940px;margin-left:-470px;left:50%}"]}),t}(),Zht=function(){function t(){this.dataChange=new Pm.a([])}return Object.defineProperty(t.prototype,"data",{get:function(){return this.dataChange.value},enumerable:!1,configurable:!0}),t.prototype.addProjects=function(t){this.dataChange.next(t)},t.prototype.remove=function(t){var e=this.data.indexOf(t);e>=0&&(this.data.splice(e,1),this.dataChange.next(this.data.slice()))},t}(),Qht=function(t){function e(e,n){var i=t.call(this)||this;return i.projectDatabase=e,i.sort=n,i}return zQ(e,t),e.prototype.connect=function(){var t=this;return C.a.apply(void 0,[this.projectDatabase.dataChange,this.sort.sortChange]).pipe(Object(ef.a)((function(){return t.sort.active&&""!==t.sort.direction?t.projectDatabase.data.sort((function(e,n){var i=e[t.sort.active],r=n[t.sort.active];return((isNaN(+i)?i:+i)<(isNaN(+r)?r:+r)?-1:1)*("asc"===t.sort.direction?1:-1)})):t.projectDatabase.data})))},e.prototype.disconnect=function(){},e}(um);function $ht(t,e){if(1&t){var n=ka();ga(0,"button",13),xa("click",(function(){return Se(n),Aa().backToProject()})),ds(1,"Back to project"),va()}}var Jht=function(){function t(t,e,n,i,r,o){this.electronService=t,this.recentlyOpenedProjectService=e,this.serverManagement=n,this.toasterService=i,this.progressService=r,this.router=o,this.isInstalledSoftwareAvailable=!1,this.uiVersion=Hlt,this.shouldStopServersOnClosing=!0}return t.prototype.ngOnInit=function(){var t=this;this.recentlyOpenedServerId=this.recentlyOpenedProjectService.getServerId(),this.recentlyOpenedProjectId=this.recentlyOpenedProjectService.getProjectId(),this.isInstalledSoftwareAvailable=this.electronService.isElectronApp,this.serverStatusSubscription=this.serverManagement.serverStatusChanged.subscribe((function(e){"errored"===e.status&&(console.error(e.message),t.toasterService.error(e.message)),"stderr"===e.status&&(console.error(e.message),t.toasterService.error(e.message))})),this.shouldStopServersOnClosing=this.electronService.isElectronApp},t.prototype.backToProject=function(){var t=this;this.router.navigate(["/server",this.recentlyOpenedServerId,"project",this.recentlyOpenedProjectId]).catch((function(e){return t.toasterService.error("Cannot navigate to the last opened project")}))},t.prototype.onBeforeUnload=function(t){return UQ(this,void 0,void 0,(function(){return qQ(this,(function(e){switch(e.label){case 0:return this.shouldStopServersOnClosing?(t.preventDefault(),t.returnValue=!1,this.progressService.activate(),[4,this.serverManagement.stopAll()]):[2];case 1:return e.sent(),this.shouldStopServersOnClosing=!1,this.progressService.deactivate(),window.close(),[2,!1]}}))}))},t.prototype.ngOnDestroy=function(){this.serverStatusSubscription.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(mX),da(bit),da(nht),da(Y2),da(yet),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-default-layout"]],hostBindings:function(t,e){1&t&&xa("beforeunload",(function(t){return e.onBeforeUnload(t)}),!1,yn)},decls:33,vars:4,consts:[["color","primary"],["mat-icon-button",""],["svgIcon","gns3"],["mat-button","","routerLink","/servers"],["mat-button","",3,"click",4,"ngIf"],[1,"fill-space"],["mat-button","",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","","routerLink","/settings"],["mat-menu-item","","routerLink","/installed-software",3,"disabled"],["mat-menu-item","","routerLink","/help"],[1,"mat-app-background"],[1,"footer","mat-app-background"],["mat-button","",3,"click"]],template:function(t,e){if(1&t&&(ga(0,"header"),ga(1,"mat-toolbar",0),ga(2,"button",1),ba(3,"mat-icon",2),va(),ga(4,"button",3),ds(5,"Servers"),va(),ua(6,$ht,2,0,"button",4),ba(7,"span",5),ga(8,"button",6),ga(9,"mat-icon"),ds(10,"more_vert"),va(),va(),ga(11,"mat-menu",null,7),ga(13,"button",8),ga(14,"mat-icon"),ds(15,"settings"),va(),ga(16,"span"),ds(17,"Settings"),va(),va(),ga(18,"button",9),ga(19,"mat-icon"),ds(20,"cloud_download"),va(),ga(21,"span"),ds(22,"Installed software"),va(),va(),ga(23,"button",10),ga(24,"mat-icon"),ds(25,"help"),va(),ga(26,"span"),ds(27,"Help"),va(),va(),va(),va(),va(),ga(28,"main",11),ba(29,"router-outlet"),va(),ba(30,"app-progress"),ga(31,"footer",12),ds(32),va()),2&t){var n=ha(12);Qi(6),pa("ngIf",e.recentlyOpenedProjectId&&e.recentlyOpenedServerId),Qi(2),pa("matMenuTriggerFor",n),Qi(10),pa("disabled",!e.isInstalledSoftwareAvailable),Qi(14),ps(" GNS3 Web UI \xa9 2020 - v",e.uiVersion,"\n")}},directives:[Tct,a2,x2,hQ,Ah,N0,D0,E0,mQ,gst],styles:["app-default-layout,app-root,body,html{height:100%}app-default-layout{display:flex;flex-direction:column;height:100vh}.footer{padding:20px;margin:auto 0 0}.default-content{margin:0 auto;max-width:940px;padding-top:20px;padding-bottom:20px}header{box-shadow:0 3px 5px -1px rgba(0,0,0,.2),0 6px 10px 0 rgba(0,0,0,.14),0 1px 18px 0 rgba(0,0,0,.12);z-index:10}.default-header h1{font-weight:300;margin:0;font-size:20px;padding:28px 8px}.default-header{margin:0 auto;max-width:940px}.buttons-bar{padding-top:10px;text-align:right}.fill-space{flex:1 1 auto}.container>*{width:100%}.container{padding:0}.mat-dialog-content>*{width:100%}"],encapsulation:2}),t}(),tdt=function(){function t(t){this.electronService=t}return t.prototype.get=function(){if(this.electronService.isElectronApp)return this.electronService.isLinux?'xfce4-terminal --tab -T "%d" -e "telnet %h %p"':this.electronService.isWindows?'putty.exe -telnet %h %p -loghost "%d"':void 0},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(mX))}}),t}(),edt=function(){function t(t,e){this.defaultConsoleService=t,this.settingsService=e}return Object.defineProperty(t.prototype,"command",{get:function(){var t=this.settingsService.get("console_command");return void 0===t?this.defaultConsoleService.get():t},set:function(t){this.settingsService.set("console_command",t)},enumerable:!1,configurable:!0}),t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(tdt),_t(QQ))}}),t}(),ndt=0,idt=function(){var t=function(){function t(){Object(m.a)(this,t),this._stateChanges=new w.b,this._openCloseAllActions=new w.b,this.id="cdk-accordion-".concat(ndt++),this._multi=!1}return Object(g.a)(t,[{key:"openAll",value:function(){this._openCloseAll(!0)}},{key:"closeAll",value:function(){this._openCloseAll(!1)}},{key:"ngOnChanges",value:function(t){this._stateChanges.next(t)}},{key:"ngOnDestroy",value:function(){this._stateChanges.complete()}},{key:"_openCloseAll",value:function(t){this.multi&&this._openCloseAllActions.next(t)}},{key:"multi",get:function(){return this._multi},set:function(t){this._multi=nm(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["cdk-accordion"],["","cdkAccordion",""]],inputs:{multi:"multi"},exportAs:["cdkAccordion"],features:[Ms]}),t}(),rdt=0,odt=function(){var t=function(){function t(e,n,i){var r=this;Object(m.a)(this,t),this.accordion=e,this._changeDetectorRef=n,this._expansionDispatcher=i,this._openCloseAllSubscription=_.a.EMPTY,this.closed=new Uc,this.opened=new Uc,this.destroyed=new Uc,this.expandedChange=new Uc,this.id="cdk-accordion-child-".concat(rdt++),this._expanded=!1,this._disabled=!1,this._removeUniqueSelectionListener=function(){},this._removeUniqueSelectionListener=i.listen((function(t,e){r.accordion&&!r.accordion.multi&&r.accordion.id===e&&r.id!==t&&(r.expanded=!1)})),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}},{key:"toggle",value:function(){this.disabled||(this.expanded=!this.expanded)}},{key:"close",value:function(){this.disabled||(this.expanded=!1)}},{key:"open",value:function(){this.disabled||(this.expanded=!0)}},{key:"_subscribeToOpenCloseAllActions",value:function(){var t=this;return this.accordion._openCloseAllActions.subscribe((function(e){t.disabled||(t.expanded=e)}))}},{key:"expanded",get:function(){return this._expanded},set:function(t){t=nm(t),this._expanded!==t&&(this._expanded=t,this.expandedChange.emit(t),t?(this.opened.emit(),this._expansionDispatcher.notify(this.id,this.accordion?this.accordion.id:this.id)):this.closed.emit(),this._changeDetectorRef.markForCheck())}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(idt,12),da(Po),da(pm))},t.\u0275dir=Wt({type:t,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:"expanded",disabled:"disabled"},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],features:[Ns([{provide:idt,useValue:void 0}])]}),t}(),adt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)}}),t}(),sdt=["body"];function cdt(t,e){}var ldt=[[["mat-expansion-panel-header"]],"*",[["mat-action-row"]]],udt=["mat-expansion-panel-header","*","mat-action-row"];function hdt(t,e){1&t&&ba(0,"span",2),2&t&&pa("@indicatorRotate",Aa()._getExpandedState())}var ddt=[[["mat-panel-title"]],[["mat-panel-description"]],"*"],fdt=["mat-panel-title","mat-panel-description","*"],pdt=new ht("MAT_ACCORDION"),mdt={indicatorRotate:Jg("indicatorRotate",[rv("collapsed, void",iv({transform:"rotate(0deg)"})),rv("expanded",iv({transform:"rotate(180deg)"})),av("expanded <=> collapsed, void => collapsed",tv("225ms cubic-bezier(0.4,0.0,0.2,1)"))]),bodyExpansion:Jg("bodyExpansion",[rv("collapsed, void",iv({height:"0px",visibility:"hidden"})),rv("expanded",iv({height:"*",visibility:"visible"})),av("expanded <=> collapsed, void => collapsed",tv("225ms cubic-bezier(0.4,0.0,0.2,1)"))])},gdt=function(){var t=function t(e){Object(m.a)(this,t),this._template=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["ng-template","matExpansionPanelContent",""]]}),t}(),vdt=0,bdt=new ht("MAT_EXPANSION_PANEL_DEFAULT_OPTIONS"),ydt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,s,c){var l;return Object(m.a)(this,n),(l=e.call(this,t,i,r))._viewContainerRef=o,l._animationMode=s,l._hideToggle=!1,l.afterExpand=new Uc,l.afterCollapse=new Uc,l._inputChanges=new w.b,l._headerId="mat-expansion-panel-header-".concat(vdt++),l._bodyAnimationDone=new w.b,l.accordion=t,l._document=a,l._bodyAnimationDone.pipe(Object(RJ.a)((function(t,e){return t.fromState===e.fromState&&t.toState===e.toState}))).subscribe((function(t){"void"!==t.fromState&&("expanded"===t.toState?l.afterExpand.emit():"collapsed"===t.toState&&l.afterCollapse.emit())})),c&&(l.hideToggle=c.hideToggle),l}return Object(g.a)(n,[{key:"_hasSpacing",value:function(){return!!this.accordion&&this.expanded&&"default"===this.accordion.displayMode}},{key:"_getExpandedState",value:function(){return this.expanded?"expanded":"collapsed"}},{key:"toggle",value:function(){this.expanded=!this.expanded}},{key:"close",value:function(){this.expanded=!1}},{key:"open",value:function(){this.expanded=!0}},{key:"ngAfterContentInit",value:function(){var t=this;this._lazyContent&&this.opened.pipe(Object(NX.a)(null),Object(vg.a)((function(){return t.expanded&&!t._portal})),Object(FX.a)(1)).subscribe((function(){t._portal=new D$(t._lazyContent._template,t._viewContainerRef)}))}},{key:"ngOnChanges",value:function(t){this._inputChanges.next(t)}},{key:"ngOnDestroy",value:function(){Object(o.a)(Object(a.a)(n.prototype),"ngOnDestroy",this).call(this),this._bodyAnimationDone.complete(),this._inputChanges.complete()}},{key:"_containsFocus",value:function(){if(this._body){var t=this._document.activeElement,e=this._body.nativeElement;return t===e||e.contains(t)}return!1}},{key:"hideToggle",get:function(){return this._hideToggle||this.accordion&&this.accordion.hideToggle},set:function(t){this._hideToggle=nm(t)}},{key:"togglePosition",get:function(){return this._togglePosition||this.accordion&&this.accordion.togglePosition},set:function(t){this._togglePosition=t}}]),n}(odt);return t.\u0275fac=function(e){return new(e||t)(da(pdt,12),da(Po),da(pm),da(mc),da(du),da(Cy,8),da(bdt,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-expansion-panel"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,gdt,!0),2&t&&tl(i=sl())&&(e._lazyContent=i.first)},viewQuery:function(t,e){var n;1&t&&nl(sdt,!0),2&t&&tl(n=sl())&&(e._body=n.first)},hostAttrs:[1,"mat-expansion-panel"],hostVars:6,hostBindings:function(t,e){2&t&&Qa("mat-expanded",e.expanded)("_mat-animation-noopable","NoopAnimations"===e._animationMode)("mat-expansion-panel-spacing",e._hasSpacing())},inputs:{disabled:"disabled",expanded:"expanded",hideToggle:"hideToggle",togglePosition:"togglePosition"},outputs:{opened:"opened",closed:"closed",expandedChange:"expandedChange",afterExpand:"afterExpand",afterCollapse:"afterCollapse"},exportAs:["matExpansionPanel"],features:[Ns([{provide:pdt,useValue:void 0}]),ws,Ms],ngContentSelectors:udt,decls:7,vars:4,consts:[["role","region",1,"mat-expansion-panel-content",3,"id"],["body",""],[1,"mat-expansion-panel-body"],[3,"cdkPortalOutlet"]],template:function(t,e){1&t&&(Ia(ldt),Da(0),ga(1,"div",0,1),xa("@bodyExpansion.done",(function(t){return e._bodyAnimationDone.next(t)})),ga(3,"div",2),Da(4,1),ua(5,cdt,0,0,"ng-template",3),va(),Da(6,2),va()),2&t&&(Qi(1),pa("@bodyExpansion",e._getExpandedState())("id",e.id),oa("aria-labelledby",e._headerId),Qi(4),pa("cdkPortalOutlet",e._portal))},directives:[B$],styles:[".mat-expansion-panel{box-sizing:content-box;display:block;margin:0;border-radius:4px;overflow:hidden;transition:margin 225ms cubic-bezier(0.4, 0, 0.2, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);position:relative}.mat-accordion .mat-expansion-panel:not(.mat-expanded),.mat-accordion .mat-expansion-panel:not(.mat-expansion-panel-spacing){border-radius:0}.mat-accordion .mat-expansion-panel:first-of-type{border-top-right-radius:4px;border-top-left-radius:4px}.mat-accordion .mat-expansion-panel:last-of-type{border-bottom-right-radius:4px;border-bottom-left-radius:4px}.cdk-high-contrast-active .mat-expansion-panel{outline:solid 1px}.mat-expansion-panel.ng-animate-disabled,.ng-animate-disabled .mat-expansion-panel,.mat-expansion-panel._mat-animation-noopable{transition:none}.mat-expansion-panel-content{display:flex;flex-direction:column;overflow:visible}.mat-expansion-panel-body{padding:0 24px 16px}.mat-expansion-panel-spacing{margin:16px 0}.mat-accordion>.mat-expansion-panel-spacing:first-child,.mat-accordion>*:first-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-top:0}.mat-accordion>.mat-expansion-panel-spacing:last-child,.mat-accordion>*:last-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-bottom:0}.mat-action-row{border-top-style:solid;border-top-width:1px;display:flex;flex-direction:row;justify-content:flex-end;padding:16px 8px 16px 24px}.mat-action-row button.mat-button-base,.mat-action-row button.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-action-row button.mat-button-base,[dir=rtl] .mat-action-row button.mat-mdc-button-base{margin-left:0;margin-right:8px}\n"],encapsulation:2,data:{animation:[mdt.bodyExpansion]},changeDetection:0}),t}(),_dt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-action-row"]],hostAttrs:[1,"mat-action-row"]}),t}(),wdt=function(){var t=function(){function t(e,n,i,r,o,a){var s=this;Object(m.a)(this,t),this.panel=e,this._element=n,this._focusMonitor=i,this._changeDetectorRef=r,this._animationMode=a,this._parentChangeSubscription=_.a.EMPTY;var c=e.accordion?e.accordion._stateChanges.pipe(Object(vg.a)((function(t){return!(!t.hideToggle&&!t.togglePosition)}))):TX.a;this._parentChangeSubscription=Object(C.a)(e.opened,e.closed,c,e._inputChanges.pipe(Object(vg.a)((function(t){return!!(t.hideToggle||t.disabled||t.togglePosition)})))).subscribe((function(){return s._changeDetectorRef.markForCheck()})),e.closed.pipe(Object(vg.a)((function(){return e._containsFocus()}))).subscribe((function(){return i.focusVia(n,"program")})),o&&(this.expandedHeight=o.expandedHeight,this.collapsedHeight=o.collapsedHeight)}return Object(g.a)(t,[{key:"_toggle",value:function(){this.disabled||this.panel.toggle()}},{key:"_isExpanded",value:function(){return this.panel.expanded}},{key:"_getExpandedState",value:function(){return this.panel._getExpandedState()}},{key:"_getPanelId",value:function(){return this.panel.id}},{key:"_getTogglePosition",value:function(){return this.panel.togglePosition}},{key:"_showToggle",value:function(){return!this.panel.hideToggle&&!this.panel.disabled}},{key:"_getHeaderHeight",value:function(){var t=this._isExpanded();return t&&this.expandedHeight?this.expandedHeight:!t&&this.collapsedHeight?this.collapsedHeight:null}},{key:"_keydown",value:function(t){switch(t.keyCode){case 32:case 13:JQ(t)||(t.preventDefault(),this._toggle());break;default:return void(this.panel.accordion&&this.panel.accordion._handleHeaderKeydown(t))}}},{key:"focus",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"program",e=arguments.length>1?arguments[1]:void 0;this._focusMonitor.focusVia(this._element,t,e)}},{key:"ngAfterViewInit",value:function(){var t=this;this._focusMonitor.monitor(this._element).subscribe((function(e){e&&t.panel.accordion&&t.panel.accordion._handleHeaderFocus(t)}))}},{key:"ngOnDestroy",value:function(){this._parentChangeSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._element)}},{key:"disabled",get:function(){return this.panel.disabled}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(ydt,1),da(Us),da(S$),da(Po),da(bdt,8),da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-expansion-panel-header"]],hostAttrs:["role","button",1,"mat-expansion-panel-header","mat-focus-indicator"],hostVars:15,hostBindings:function(t,e){1&t&&xa("click",(function(){return e._toggle()}))("keydown",(function(t){return e._keydown(t)})),2&t&&(oa("id",e.panel._headerId)("tabindex",e.disabled?-1:0)("aria-controls",e._getPanelId())("aria-expanded",e._isExpanded())("aria-disabled",e.panel.disabled),Za("height",e._getHeaderHeight()),Qa("mat-expanded",e._isExpanded())("mat-expansion-toggle-indicator-after","after"===e._getTogglePosition())("mat-expansion-toggle-indicator-before","before"===e._getTogglePosition())("_mat-animation-noopable","NoopAnimations"===e._animationMode))},inputs:{expandedHeight:"expandedHeight",collapsedHeight:"collapsedHeight"},ngContentSelectors:fdt,decls:5,vars:1,consts:[[1,"mat-content"],["class","mat-expansion-indicator",4,"ngIf"],[1,"mat-expansion-indicator"]],template:function(t,e){1&t&&(Ia(ddt),ga(0,"span",0),Da(1),Da(2,1),Da(3,2),va(),ua(4,hdt,1,1,"span",1)),2&t&&(Qi(4),pa("ngIf",e._showToggle()))},directives:[Ah],styles:['.mat-expansion-panel-header{display:flex;flex-direction:row;align-items:center;padding:0 24px;border-radius:inherit;transition:height 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel-header._mat-animation-noopable{transition:none}.mat-expansion-panel-header:focus,.mat-expansion-panel-header:hover{outline:none}.mat-expansion-panel-header.mat-expanded:focus,.mat-expansion-panel-header.mat-expanded:hover{background:inherit}.mat-expansion-panel-header:not([aria-disabled=true]){cursor:pointer}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before{flex-direction:row-reverse}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 16px 0 0}[dir=rtl] .mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 0 0 16px}.mat-content{display:flex;flex:1;flex-direction:row;overflow:hidden}.mat-expansion-panel-header-title,.mat-expansion-panel-header-description{display:flex;flex-grow:1;margin-right:16px}[dir=rtl] .mat-expansion-panel-header-title,[dir=rtl] .mat-expansion-panel-header-description{margin-right:0;margin-left:16px}.mat-expansion-panel-header-description{flex-grow:2}.mat-expansion-indicator::after{border-style:solid;border-width:0 2px 2px 0;content:"";display:inline-block;padding:3px;transform:rotate(45deg);vertical-align:middle}\n'],encapsulation:2,data:{animation:[mdt.indicatorRotate]},changeDetection:0}),t}(),kdt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-panel-description"]],hostAttrs:[1,"mat-expansion-panel-header-description"]}),t}(),Cdt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-panel-title"]],hostAttrs:[1,"mat-expansion-panel-header-title"]}),t}(),Sdt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments))._ownHeaders=new Gc,t._hideToggle=!1,t.displayMode="default",t.togglePosition="after",t}return Object(g.a)(n,[{key:"ngAfterContentInit",value:function(){var t=this;this._headers.changes.pipe(Object(NX.a)(this._headers)).subscribe((function(e){t._ownHeaders.reset(e.filter((function(e){return e.panel.accordion===t}))),t._ownHeaders.notifyOnChanges()})),this._keyManager=new d$(this._ownHeaders).withWrap()}},{key:"_handleHeaderKeydown",value:function(t){var e=t.keyCode,n=this._keyManager;36===e?JQ(t)||(n.setFirstItemActive(),t.preventDefault()):35===e?JQ(t)||(n.setLastItemActive(),t.preventDefault()):this._keyManager.onKeydown(t)}},{key:"_handleHeaderFocus",value:function(t){this._keyManager.updateActiveItem(t)}},{key:"hideToggle",get:function(){return this._hideToggle},set:function(t){this._hideToggle=nm(t)}}]),n}(idt);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-accordion"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,wdt,!0),2&t&&tl(i=sl())&&(e._headers=i)},hostAttrs:[1,"mat-accordion"],hostVars:2,hostBindings:function(t,e){2&t&&Qa("mat-accordion-multi",e.multi)},inputs:{multi:"multi",displayMode:"displayMode",togglePosition:"togglePosition",hideToggle:"hideToggle"},exportAs:["matAccordion"],features:[Ns([{provide:pdt,useExisting:t}]),ws]});var e=zn(t);return t}(),xdt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd,adt,z$]]}),t}(),Odt=function(){function t(t,e,n,i,r){this.settingsService=t,this.toaster=e,this.consoleService=n,this.themeService=i,this.mapSettingsService=r,this.settings=VQ({},QQ.DEFAULTS)}return t.prototype.ngOnInit=function(){this.settings=this.settingsService.getAll(),this.consoleCommand=this.consoleService.command,this.integrateLinksLabelsToLinks=this.mapSettingsService.integrateLinkLabelsToLinks},t.prototype.save=function(){this.settingsService.setAll(this.settings),this.toaster.success("Settings have been saved."),this.mapSettingsService.toggleIntegrateInterfaceLabels(this.integrateLinksLabelsToLinks)},t.prototype.setDarkMode=function(t){this.themeService.setDarkMode(t)},t.\u0275fac=function(e){return new(e||t)(da(QQ),da(Y2),da(edt),da(Kit),da($8))},t.\u0275cmp=Ht({type:t,selectors:[["app-settings"]],decls:45,vars:6,consts:[[1,"content"],[1,"default-header"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"expanded"],[3,"ngModel","ngModelChange"],[1,"full-width-field"],["matInput","","placeholder","console","readonly","true",3,"value"],["mat-icon-button","","matSuffix","","routerLink","/settings/console"],[1,"theme-panel"],["mat-raised-button","",3,"click"],[1,"buttons-bar"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"h1"),ds(3,"Settings"),va(),va(),ga(4,"div",2),ga(5,"div",3),ga(6,"mat-accordion"),ga(7,"mat-expansion-panel",4),ga(8,"mat-expansion-panel-header"),ga(9,"mat-panel-title"),ds(10," Local settings "),va(),ga(11,"mat-panel-description"),ds(12," Customize your local settings "),va(),va(),ga(13,"div"),ga(14,"mat-checkbox",5),xa("ngModelChange",(function(t){return e.settings.crash_reports=t})),ds(15,"Send anonymous crash reports"),va(),ba(16,"br"),ga(17,"mat-checkbox",5),xa("ngModelChange",(function(t){return e.integrateLinksLabelsToLinks=t})),ds(18,"Integrate link labels to links"),va(),va(),va(),ga(19,"mat-expansion-panel",4),ga(20,"mat-expansion-panel-header"),ga(21,"mat-panel-title"),ds(22," Console settings "),va(),ga(23,"mat-panel-description"),ds(24," Customize console settings "),va(),va(),ga(25,"div"),ga(26,"mat-form-field",6),ba(27,"input",7),ga(28,"a",8),ga(29,"mat-icon"),ds(30,"mode_edit"),va(),va(),va(),va(),va(),ga(31,"mat-expansion-panel",4),ga(32,"mat-expansion-panel-header"),ga(33,"mat-panel-title"),ds(34," Theme settings "),va(),ga(35,"mat-panel-description"),ds(36," Customize theme settings "),va(),va(),ga(37,"div",9),ga(38,"button",10),xa("click",(function(){return e.setDarkMode(!1)})),ds(39,"Switch to light theme"),va(),ga(40,"button",10),xa("click",(function(){return e.setDarkMode(!0)})),ds(41,"Switch to dark theme"),va(),va(),va(),va(),va(),ga(42,"div",11),ga(43,"button",12),xa("click",(function(){return e.save()})),ds(44,"Save settings"),va(),va(),va(),va()),2&t&&(Qi(7),pa("expanded",!0),Qi(7),pa("ngModel",e.settings.crash_reports),Qi(3),pa("ngModel",e.integrateLinksLabelsToLinks),Qi(2),pa("expanded",!1),Qi(8),pa("value",e.consoleCommand),Qi(4),pa("expanded",!1))},directives:[Sdt,ydt,wdt,Cdt,kdt,F5,mf,Sp,Y3,s5,s2,dQ,q3,x2,a2],styles:[".theme-panel[_ngcontent-%COMP%]{justify-content:space-between;display:flex;padding:10px}"]}),t}(),Mdt=function(){function t(t,e,n,i){this.router=t,this.serverService=e,this.progressService=n,this.document=i}return t.prototype.ngOnInit=function(){var t=this;this.progressService.activate(),setTimeout((function(){var e=parseInt(t.document.location.port,10)?parseInt(t.document.location.port,10):80;t.serverService.getLocalServer(t.document.location.hostname,e).then((function(e){t.progressService.deactivate(),t.router.navigate(["/server",e.id,"projects"])}))}),100)},t.\u0275fac=function(e){return new(e||t)(da(lQ),da(ZQ),da(yet),da(du))},t.\u0275cmp=Ht({type:t,selectors:[["app-bundled-server-finder"]],decls:1,vars:0,template:function(t,e){1&t&&ba(0,"app-progress")},directives:[gst],styles:[""]}),t}(),Tdt=function(){function t(t){this.route=t,this.serverId=""}return t.prototype.ngOnInit=function(){this.serverId=this.route.snapshot.paramMap.get("server_id")},t.\u0275fac=function(e){return new(e||t)(da(ZY))},t.\u0275cmp=Ht({type:t,selectors:[["app-preferences"]],decls:26,vars:9,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],[3,"routerLink"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Preferences"),va(),va(),va(),ga(5,"div",4),ga(6,"div",5),ga(7,"mat-nav-list"),ga(8,"mat-list-item",6),ds(9," GNS3 VM "),va(),ga(10,"mat-list-item",6),ds(11," Built-in "),va(),ga(12,"mat-list-item",6),ds(13," Dynamips "),va(),ga(14,"mat-list-item",6),ds(15," IOS on Unix "),va(),ga(16,"mat-list-item",6),ds(17," VPCS "),va(),ga(18,"mat-list-item",6),ds(19," QEMU "),va(),ga(20,"mat-list-item",6),ds(21," VirtualBox "),va(),ga(22,"mat-list-item",6),ds(23," VMware "),va(),ga(24,"mat-list-item",6),ds(25," Docker "),va(),va(),va(),va(),va()),2&t&&(Qi(8),La("routerLink","/server/",e.serverId,"/preferences/gns3vm"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/builtin"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/dynamips/templates"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/iou/templates"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/vpcs/templates"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/qemu/templates"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/virtualbox/templates"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/vmware/templates"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/docker/templates"))},directives:[y8,S8,hQ],styles:[".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Edt=function(){function t(t,e){this.dialogRef=t,this.data=e,this.templateName="",this.templateName=e.templateName}return t.prototype.ngOnInit=function(){},t.prototype.onNoClick=function(){this.dialogRef.close(!1)},t.prototype.onYesClick=function(){this.dialogRef.close(!0)},t.\u0275fac=function(e){return new(e||t)(da(Z0),da(Q0))},t.\u0275cmp=Ht({type:t,selectors:[["app-delete-confirmation-dialog"]],decls:11,vars:1,consts:[[1,"dialogcontainer"],["mat-dialog-title",""],["mat-dialog-content",""],[1,"spacer"],["mat-dialog-actions",""],["mat-button","","color","accent",1,"cancelButton",3,"click"],["mat-button","","tabindex","2","mat-raised-button","","color","primary",1,"confirmButton",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"h1",1),ds(2,"Delete template"),va(),ga(3,"div",2),ds(4),va(),ba(5,"div",3),ga(6,"div",4),ga(7,"button",5),xa("click",(function(){return e.onNoClick()})),ds(8," No "),va(),ga(9,"button",6),xa("click",(function(){return e.onYesClick()})),ds(10," Yes "),va(),va(),va()),2&t&&(Qi(4),ps("Are you sure you want to delete template ",e.templateName,"?"))},directives:[r1,o1,a1,a2],styles:[".dialogcontainer[_ngcontent-%COMP%]{height:100%;display:flex;flex-direction:column}.spacer[_ngcontent-%COMP%]{flex-grow:1}"]}),t}(),Pdt=function(){function t(t,e,n){this.templateService=t,this.dialog=e,this.toasterService=n,this.deleteEvent=new Uc}return t.prototype.deleteItem=function(t,e){var n=this;this.dialog.open(Edt,{width:"300px",height:"250px",data:{templateName:t},autoFocus:!1,disableClose:!0}).afterClosed().subscribe((function(i){i&&n.templateService.deleteTemplate(n.server,e).subscribe((function(i){n.deleteEvent.emit(e),n.toasterService.success("Template "+t+" deleted.")}))}))},t.\u0275fac=function(e){return new(e||t)(da(yot),da(e1),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-delete-template"]],inputs:{server:"server"},outputs:{deleteEvent:"deleteEvent"},decls:0,vars:0,template:function(t,e){},styles:[""]}),t}(),Adt=function(){function t(){this.emptyTemplatesListMessage="Empty templates list",this.textMessage&&(this.emptyTemplatesListMessage=this.textMessage)}return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["app-empty-templates-list"]],inputs:{textMessage:"textMessage"},decls:4,vars:1,consts:[[1,"default-content"],[1,"matCard"],[1,"header"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"mat-card",1),ga(2,"h6",2),ds(3),va(),va(),va()),2&t&&(Qi(3),ps(" ",e.emptyTemplatesListMessage," "))},directives:[f3],styles:[".header[_ngcontent-%COMP%]{text-align:center;color:#a9a9a9}"]}),t}();function jdt(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences")}function Idt(t,e){1&t&&(ga(0,"button",11),ds(1,"Add QEMU VM template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/qemu/addtemplate")}function Ddt(t,e){1&t&&ba(0,"app-empty-templates-list")}function Rdt(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),ga(13,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).copyTemplate(t)})),ga(14,"mat-icon"),ds(15,"content_copy"),va(),ga(16,"span"),ds(17,"Copy"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function Ldt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,Rdt,18,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.qemuTemplates)}}function Fdt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,Ldt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var Ndt=function(){function t(t,e,n,i){this.route=t,this.serverService=e,this.qemuService=n,this.router=i,this.qemuTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.qemuService.getTemplates(this.server).subscribe((function(e){t.qemuTemplates=e.filter((function(t){return"qemu"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.prototype.copyTemplate=function(t){this.router.navigate(["/server",this.server.id,"preferences","qemu","templates",t.template_id,"copy"])},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(w6),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-qemu-virtual-machines-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"QEMU VM templates"),va(),ua(5,jdt,2,1,"button",4),ua(6,Idt,2,1,"button",5),va(),va(),ua(7,Ddt,1,0,"app-empty-templates-list",6),ua(8,Fdt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.qemuTemplates.length),Qi(1),pa("ngIf",e.qemuTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Bdt=["customAdapters"],Hdt=function(){function t(){this.networkTypes=[],this.displayedColumns=[],this.closeConfiguratorEmitter=new Uc,this.saveConfigurationEmitter=new Uc,console.log(this.networkTypes)}return t.prototype.cancelConfigureCustomAdapters=function(){this.closeConfiguratorEmitter.emit(!1)},t.prototype.configureCustomAdapters=function(){var t=this;this.adapters=[],console.log(this.customAdapters),this.customAdapters.adapters.forEach((function(e){t.adapters.push({adapter_number:e.adapter_number,adapter_type:e.adapter_type})})),this.saveConfigurationEmitter.emit(this.adapters)},t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["app-custom-adapters"]],viewQuery:function(t,e){var n;1&t&&nl(Bdt,!0),2&t&&tl(n=sl())&&(e.customAdapters=n.first)},inputs:{networkTypes:"networkTypes",displayedColumns:"displayedColumns"},outputs:{closeConfiguratorEmitter:"closeConfiguratorEmitter",saveConfigurationEmitter:"saveConfigurationEmitter"},decls:15,vars:3,consts:[[1,"configurator"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"networkTypes","displayedColumns","adapters"],["customAdapters",""],[1,"buttons-bar"],["mat-button","",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Custom adapters configuration"),va(),va(),va(),ga(5,"div",4),ga(6,"div",5),ba(7,"app-custom-adapters-table",6,7),va(),ga(9,"div",8),ga(10,"button",9),xa("click",(function(){return e.cancelConfigureCustomAdapters()})),ds(11,"Cancel"),va(),ga(12,"button",10),xa("click",(function(){return e.configureCustomAdapters()})),ds(13,"Apply"),va(),ba(14,"br"),va(),va(),va()),2&t&&(Qi(7),pa("networkTypes",e.networkTypes)("displayedColumns",e.displayedColumns)("adapters",e.adapters))},directives:[p6,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),zdt=function(){function t(){this.symbolChangedEmitter=new Uc,this.chosenSymbol=""}return t.prototype.symbolChanged=function(t){this.chosenSymbol=t},t.prototype.chooseSymbol=function(){this.symbolChangedEmitter.emit(this.chosenSymbol)},t.prototype.cancelChooseSymbol=function(){this.symbolChangedEmitter.emit(this.symbol)},t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["app-symbols-menu"]],inputs:{server:"server",symbol:"symbol"},outputs:{symbolChangedEmitter:"symbolChangedEmitter"},decls:11,vars:2,consts:[[1,"configurator"],[1,"default-header"],[1,"row"],[1,"col"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",1,"top-button",3,"click"],[1,"default-content"],[3,"server","symbol","symbolChanged"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Symbol selection"),va(),ga(5,"button",4),xa("click",(function(){return e.cancelChooseSymbol()})),ds(6,"Cancel"),va(),ga(7,"button",5),xa("click",(function(){return e.chooseSymbol()})),ds(8,"Choose symbol"),va(),va(),va(),ga(9,"div",6),ga(10,"app-symbols",7),xa("symbolChanged",(function(t){return e.symbolChanged(t)})),va(),va(),va()),2&t&&(Qi(10),pa("server",e.server)("symbol",e.symbol))},directives:[a2,d9],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Vdt=["customAdaptersConfigurator"];function Udt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function qdt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.path),Qi(1),ps(" ",n.path," ")}}function Gdt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Wdt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Kdt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Xdt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Ydt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Zdt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Qdt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function $dt(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[0]),Qi(1),ms(" ",n[1]," (",n[0],") ")}}function Jdt(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",10),ga(1,"input",55),xa("ngModelChange",(function(t){return Se(n),Aa(2).qemuTemplate.cpu_throttling=t})),va(),va()}if(2&t){var i=Aa(2);Qi(1),pa("ngModel",i.qemuTemplate.cpu_throttling)}}function tft(t,e){if(1&t&&(ga(0,"mat-option",54),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function eft(t,e){if(1&t){var n=ka();ga(0,"div",8),ga(1,"mat-accordion"),ga(2,"mat-expansion-panel"),ga(3,"mat-expansion-panel-header"),ga(4,"mat-panel-title"),ds(5," General settings "),va(),va(),ga(6,"form",9),ga(7,"mat-form-field",10),ga(8,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.name=t})),va(),va(),ga(9,"mat-form-field",10),ga(10,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.default_name_format=t})),va(),va(),ga(11,"mat-form-field",10),ga(12,"input",13),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.symbol=t})),va(),va(),va(),ga(13,"button",14),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(14,"Choose symbol"),va(),ba(15,"br"),ba(16,"br"),ga(17,"mat-form-field",10),ga(18,"mat-select",15),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.category=t})),ua(19,Udt,2,2,"mat-option",16),va(),va(),ga(20,"mat-form-field",10),ga(21,"input",17),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.ram=t})),va(),ga(22,"span",18),ds(23,"MB"),va(),va(),ga(24,"mat-form-field",10),ga(25,"input",19),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.cpus=t})),va(),va(),ga(26,"mat-form-field",10),ga(27,"mat-select",20),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.qemu_path=t})),ua(28,qdt,2,2,"mat-option",16),va(),va(),ga(29,"mat-form-field",10),ga(30,"mat-select",21),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.boot_priority=t})),ua(31,Gdt,2,2,"mat-option",16),va(),va(),ga(32,"mat-form-field",10),ga(33,"mat-select",22),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.on_close=t})),ua(34,Wdt,2,2,"mat-option",16),va(),va(),ga(35,"mat-form-field",23),ga(36,"mat-select",24),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.console_type=t})),ua(37,Kdt,2,2,"mat-option",16),va(),va(),ga(38,"mat-checkbox",25),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.console_auto_start=t})),ds(39," Auto start console "),va(),va(),ga(40,"mat-expansion-panel"),ga(41,"mat-expansion-panel-header"),ga(42,"mat-panel-title"),ds(43," HDD "),va(),va(),ga(44,"mat-card"),ba(45,"mat-card-title"),ga(46,"mat-card-subtitle"),ds(47," HDA (Primary Master) "),va(),ga(48,"mat-card-content"),ga(49,"mat-form-field",10),ga(50,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.hda_disk_image=t})),va(),va(),ga(51,"mat-form-field",10),ga(52,"mat-select",27),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.hda_disk_interface=t})),ua(53,Xdt,2,2,"mat-option",16),va(),va(),va(),va(),ga(54,"mat-card"),ba(55,"mat-card-title"),ga(56,"mat-card-subtitle"),ds(57," HDB (Primary Slave) "),va(),ga(58,"mat-card-content"),ga(59,"mat-form-field",10),ga(60,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.hdb_disk_image=t})),va(),va(),ga(61,"mat-form-field",10),ga(62,"mat-select",27),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.hdb_disk_interface=t})),ua(63,Ydt,2,2,"mat-option",16),va(),va(),va(),va(),ga(64,"mat-card"),ba(65,"mat-card-title"),ga(66,"mat-card-subtitle"),ds(67," HDC (Secondary Master) "),va(),ga(68,"mat-card-content"),ga(69,"mat-form-field",10),ga(70,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.hdc_disk_image=t})),va(),va(),ga(71,"mat-form-field",10),ga(72,"mat-select",27),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.hdc_disk_interface=t})),ua(73,Zdt,2,2,"mat-option",16),va(),va(),va(),va(),ga(74,"mat-card"),ba(75,"mat-card-title"),ga(76,"mat-card-subtitle"),ds(77," HDD (Secondary Slave) "),va(),ga(78,"mat-card-content"),ga(79,"mat-form-field",10),ga(80,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.hdd_disk_image=t})),va(),va(),ga(81,"mat-form-field",10),ga(82,"mat-select",27),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.hdd_disk_interface=t})),ua(83,Qdt,2,2,"mat-option",16),va(),va(),va(),va(),va(),ga(84,"mat-expansion-panel"),ga(85,"mat-expansion-panel-header"),ga(86,"mat-panel-title"),ds(87," CD/DVD "),va(),va(),ga(88,"div"),ga(89,"button",28),xa("click",(function(){return Se(n),ha(92).click()})),ds(90,"Browse"),va(),ga(91,"input",29,30),xa("change",(function(t){return Se(n),Aa().uploadCdromImageFile(t)})),va(),ga(93,"mat-form-field",31),ga(94,"input",32),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.cdrom_image=t})),va(),va(),va(),va(),ga(95,"mat-expansion-panel"),ga(96,"mat-expansion-panel-header"),ga(97,"mat-panel-title"),ds(98," Network "),va(),va(),ga(99,"mat-form-field",10),ga(100,"input",33),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.adapters=t})),va(),va(),ga(101,"mat-form-field",10),ga(102,"input",34),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.first_port_name=t})),va(),va(),ga(103,"mat-form-field",10),ga(104,"input",35),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.port_name_format=t})),va(),va(),ga(105,"mat-form-field",10),ga(106,"input",36),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.port_segment_size=t})),va(),va(),ga(107,"mat-form-field",10),ga(108,"input",37),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.mac_address=t})),va(),va(),ga(109,"mat-form-field",10),ga(110,"mat-select",38),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.adapter_type=t})),ua(111,$dt,2,3,"mat-option",16),va(),va(),ga(112,"button",39),xa("click",(function(){return Se(n),Aa().setCustomAdaptersConfiguratorState(!0)})),ds(113,"Configure custom adapters"),va(),ba(114,"br"),ga(115,"mat-checkbox",25),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.legacy_networking=t})),ds(116," Use the legacy networking mode "),va(),va(),ga(117,"mat-expansion-panel"),ga(118,"mat-expansion-panel-header"),ga(119,"mat-panel-title"),ds(120," Advanced "),va(),va(),ga(121,"mat-card"),ba(122,"mat-card-title"),ga(123,"mat-card-subtitle"),ds(124," Linux boot specific settings "),va(),ga(125,"mat-card-content"),ga(126,"div"),ga(127,"button",28),xa("click",(function(){return Se(n),ha(130).click()})),ds(128,"Browse"),va(),ga(129,"input",29,40),xa("change",(function(t){return Se(n),Aa().uploadInitrdFile(t)})),va(),ga(131,"mat-form-field",31),ga(132,"input",41),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.initrd=t})),va(),va(),va(),ga(133,"div"),ga(134,"button",28),xa("click",(function(){return Se(n),Aa().filekerenelimage.click()})),ds(135,"Browse"),va(),ga(136,"input",29,42),xa("change",(function(t){return Se(n),Aa().uploadKernelImageFile(t)})),va(),ga(138,"mat-form-field",31),ga(139,"input",43),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.kernel_image=t})),va(),va(),va(),ga(140,"mat-form-field",10),ga(141,"input",44),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.kernel_command_line=t})),va(),va(),va(),va(),ga(142,"mat-card"),ba(143,"mat-card-title"),ga(144,"mat-card-subtitle"),ds(145," Bios "),va(),ga(146,"mat-card-content"),ga(147,"div"),ga(148,"button",28),xa("click",(function(){return Se(n),ha(151).click()})),ds(149,"Browse"),va(),ga(150,"input",29,45),xa("change",(function(t){return Se(n),Aa().uploadBiosFile(t)})),va(),ga(152,"mat-form-field",31),ga(153,"input",46),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.bios_image=t})),va(),va(),va(),va(),va(),ga(154,"mat-card"),ba(155,"mat-card-title"),ga(156,"mat-card-subtitle"),ds(157," Optimization "),va(),ga(158,"mat-card-content"),ga(159,"mat-checkbox",25),xa("ngModelChange",(function(t){return Se(n),Aa().activateCpuThrottling=t})),ds(160," Activate CPU throttling "),va(),ua(161,Jdt,2,1,"mat-form-field",47),ga(162,"mat-form-field",10),ga(163,"mat-select",48),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.process_priority=t})),ua(164,tft,2,2,"mat-option",16),va(),va(),va(),va(),ga(165,"mat-card"),ba(166,"mat-card-title"),ga(167,"mat-card-subtitle"),ds(168," Additional settings "),va(),ga(169,"mat-card-content"),ga(170,"mat-form-field",10),ga(171,"input",49),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.options=t})),va(),va(),ga(172,"mat-checkbox",25),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.linked_clone=t})),ds(173," Use as a linked base VM "),va(),va(),va(),va(),ga(174,"mat-expansion-panel"),ga(175,"mat-expansion-panel-header"),ga(176,"mat-panel-title"),ds(177," Usage "),va(),va(),ga(178,"mat-form-field",10),ga(179,"textarea",50),xa("ngModelChange",(function(t){return Se(n),Aa().qemuTemplate.usage=t})),va(),va(),va(),va(),ga(180,"div",51),ga(181,"button",52),xa("click",(function(){return Se(n),Aa().goBack()})),ds(182,"Cancel"),va(),ga(183,"button",53),xa("click",(function(){return Se(n),Aa().onSave()})),ds(184,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(6),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.qemuTemplate.name),Qi(2),pa("ngModel",i.qemuTemplate.default_name_format),Qi(2),pa("ngModel",i.qemuTemplate.symbol),Qi(6),pa("ngModel",i.qemuTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModel",i.qemuTemplate.ram),Qi(4),pa("ngModel",i.qemuTemplate.cpus),Qi(2),pa("ngModel",i.qemuTemplate.qemu_path),Qi(1),pa("ngForOf",i.binaries),Qi(2),pa("ngModel",i.qemuTemplate.boot_priority),Qi(1),pa("ngForOf",i.bootPriorities),Qi(2),pa("ngModel",i.qemuTemplate.on_close),Qi(1),pa("ngForOf",i.onCloseOptions),Qi(2),pa("ngModel",i.qemuTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModel",i.qemuTemplate.console_auto_start),Qi(12),pa("ngModel",i.qemuTemplate.hda_disk_image),Qi(2),pa("ngModel",i.qemuTemplate.hda_disk_interface),Qi(1),pa("ngForOf",i.diskInterfaces),Qi(7),pa("ngModel",i.qemuTemplate.hdb_disk_image),Qi(2),pa("ngModel",i.qemuTemplate.hdb_disk_interface),Qi(1),pa("ngForOf",i.diskInterfaces),Qi(7),pa("ngModel",i.qemuTemplate.hdc_disk_image),Qi(2),pa("ngModel",i.qemuTemplate.hdc_disk_interface),Qi(1),pa("ngForOf",i.diskInterfaces),Qi(7),pa("ngModel",i.qemuTemplate.hdd_disk_image),Qi(2),pa("ngModel",i.qemuTemplate.hdd_disk_interface),Qi(1),pa("ngForOf",i.diskInterfaces),Qi(11),pa("ngModel",i.qemuTemplate.cdrom_image),Qi(6),pa("ngModel",i.qemuTemplate.adapters),Qi(2),pa("ngModel",i.qemuTemplate.first_port_name),Qi(2),pa("ngModel",i.qemuTemplate.port_name_format),Qi(2),pa("ngModel",i.qemuTemplate.port_segment_size),Qi(2),pa("ngModel",i.qemuTemplate.mac_address),Qi(2),pa("ngModel",i.qemuTemplate.adapter_type),Qi(1),pa("ngForOf",i.networkTypes),Qi(4),pa("ngModel",i.qemuTemplate.legacy_networking),Qi(17),pa("ngModel",i.qemuTemplate.initrd),Qi(7),pa("ngModel",i.qemuTemplate.kernel_image),Qi(2),pa("ngModel",i.qemuTemplate.kernel_command_line),Qi(12),pa("ngModel",i.qemuTemplate.bios_image),Qi(6),pa("ngModel",i.activateCpuThrottling),Qi(2),pa("ngIf",i.activateCpuThrottling),Qi(2),pa("ngModel",i.qemuTemplate.process_priority),Qi(1),pa("ngForOf",i.priorities),Qi(7),pa("ngModel",i.qemuTemplate.options),Qi(1),pa("ngModel",i.qemuTemplate.linked_clone),Qi(7),pa("ngModel",i.qemuTemplate.usage)}}function nft(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",56),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.qemuTemplate.symbol)}}var ift=function(t){return{shadowed:t}},rft=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.qemuService=n,this.toasterService=i,this.configurationService=r,this.formBuilder=o,this.router=a,this.isSymbolSelectionOpened=!1,this.consoleTypes=[],this.diskInterfaces=[],this.networkTypes=[],this.bootPriorities=[],this.onCloseOptions=[],this.categories=[],this.priorities=[],this.binaries=[],this.activateCpuThrottling=!0,this.isConfiguratorOpened=!1,this.displayedColumns=["adapter_number","port_name","adapter_type","actions"],this.generalSettingsForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),symbol:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.qemuService.getTemplate(t.server,n).subscribe((function(n){t.qemuTemplate=n,t.fillCustomAdapters(),t.qemuService.getBinaries(e).subscribe((function(e){t.binaries=e}))}))}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.configurationService.getConsoleTypes(),this.diskInterfaces=this.configurationService.getDiskInterfaces(),this.networkTypes=this.configurationService.getNetworkTypes(),this.bootPriorities=this.configurationService.getBootPriorities(),this.onCloseOptions=this.configurationService.getOnCloseOptions(),this.categories=this.configurationService.getCategories(),this.priorities=this.configurationService.getPriorities()},t.prototype.uploadCdromImageFile=function(t){this.qemuTemplate.cdrom_image=t.target.files[0].name},t.prototype.uploadInitrdFile=function(t){this.qemuTemplate.initrd=t.target.files[0].name},t.prototype.uploadKernelImageFile=function(t){this.qemuTemplate.kernel_image=t.target.files[0].name},t.prototype.uploadBiosFile=function(t){this.qemuTemplate.bios_image=t.target.files[0].name},t.prototype.setCustomAdaptersConfiguratorState=function(t){var e=this;this.isConfiguratorOpened=t,t&&(this.fillCustomAdapters(),this.customAdaptersConfigurator.numberOfAdapters=this.qemuTemplate.adapters,this.customAdaptersConfigurator.adapters=[],this.qemuTemplate.custom_adapters.forEach((function(t){e.customAdaptersConfigurator.adapters.push({adapter_number:t.adapter_number,adapter_type:t.adapter_type})})))},t.prototype.saveCustomAdapters=function(t){this.setCustomAdaptersConfiguratorState(!1),this.qemuTemplate.custom_adapters=t},t.prototype.fillCustomAdapters=function(){var t=this.qemuTemplate.custom_adapters?this.qemuTemplate.custom_adapters:[];this.qemuTemplate.custom_adapters=[];for(var e=0;e<this.qemuTemplate.adapters;e++)this.qemuTemplate.custom_adapters.push(t[e]?t[e]:{adapter_number:e,adapter_type:"e1000"})},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","qemu","templates"])},t.prototype.onSave=function(){var t=this;this.generalSettingsForm.invalid?this.toasterService.error("Fill all required fields"):(this.activateCpuThrottling||(this.qemuTemplate.cpu_throttling=0),this.fillCustomAdapters(),this.qemuService.saveTemplate(this.server,this.qemuTemplate).subscribe((function(e){t.toasterService.success("Changes saved")})))},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.qemuTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(w6),da(Y2),da(k6),da(Jp),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-qemu-virtual-machine-template-details"]],viewQuery:function(t,e){var n;1&t&&nl(Vdt,!0),2&t&&tl(n=sl())&&(e.customAdaptersConfigurator=n.first)},decls:9,vars:8,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"hidden","networkTypes","displayedColumns","closeConfiguratorEmitter","saveConfigurationEmitter"],["customAdaptersConfigurator",""],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","defaultName","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","symbol","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["matInput","","type","number","placeholder","RAM",3,"ngModel","ngModelChange"],["matSuffix",""],["matInput","","type","number","placeholder","vCPUs",3,"ngModel","ngModelChange"],["placeholder","Qemu binary",3,"ngModel","ngModelChange"],["placeholder","Boot priority",3,"ngModel","ngModelChange"],["placeholder","On close",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModel","ngModelChange"],[3,"ngModel","ngModelChange"],["matInput","","placeholder","Disk image",3,"ngModel","ngModelChange"],["placeholder","Disk interface",3,"ngModel","ngModelChange"],["mat-raised-button","","color","primary",1,"file-button",3,"click"],["type","file",1,"nonvisible",3,"change"],["filecdrom",""],[1,"file-name-form-field"],["matInput","","type","text","placeholder","Image",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","Adapters",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","First port name",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Name format",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","Segment size",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Base MAC",3,"ngModel","ngModelChange"],["placeholder","Type",3,"ngModel","ngModelChange"],["mat-button","",1,"configButton",3,"click"],["fileinitrd",""],["matInput","","type","text","placeholder","Initial RAM disk (initrd)",3,"ngModel","ngModelChange"],["filekernelimage",""],["matInput","","type","text","placeholder","Kernel image",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Kernel command line",3,"ngModel","ngModelChange"],["filebios",""],["matInput","","type","text","placeholder","Bios image",3,"ngModel","ngModelChange"],["class","form-field",4,"ngIf"],["placeholder","Process priority",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Options",3,"ngModel","ngModelChange"],["matInput","","type","text",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],["matInput","","type","number","placeholder","Perecentage of CPU allowed",3,"ngModel","ngModelChange"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"QEMU VM configuration"),va(),va(),va(),ua(5,eft,185,49,"div",4),va(),ga(6,"app-custom-adapters",5,6),xa("closeConfiguratorEmitter",(function(t){return e.setCustomAdaptersConfiguratorState(t)}))("saveConfigurationEmitter",(function(t){return e.saveCustomAdapters(t)})),va(),ua(8,nft,1,2,"app-symbols-menu",7)),2&t&&(pa("ngClass",Ic(6,ift,e.isConfiguratorOpened||e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.qemuTemplate),Qi(1),pa("hidden",!(e.isConfiguratorOpened&&e.qemuTemplate))("networkTypes",e.networkTypes)("displayedColumns",e.displayedColumns),Qi(2),pa("ngIf",e.isSymbolSelectionOpened&&e.qemuTemplate))},directives:[Oh,Ah,Hdt,Sdt,ydt,wdt,Cdt,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2,O5,Sp,Eh,Ef,q3,F5,f3,i3,r3,n3,EJ,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),oft=function(){function t(){}return t.prototype.getTracengTemplate=function(){return{builtin:!1,category:"guest",compute_id:"local",console_type:"none",default_name_format:"TraceNG{0}",ip_address:"",name:"",symbol:":/symbols/classic/traceng.svg",template_id:"",template_type:"traceng"}},t.prototype.getQemuTemplate=function(){return Object(lm.a)({adapter_type:"e1000",adapters:4,bios_image:"",boot_priority:"c",builtin:!1,category:"guest",cdrom_image:"",compute_id:"local",console_auto_start:!1,console_type:"telnet",cpu_throttling:0,cpus:1,custom_adapters:[],default_name_format:"{name}-{0}",first_port_name:"",hda_disk_image:"",hda_disk_interface:"ide",hdb_disk_image:"",hdb_disk_interface:"ide",hdc_disk_image:"",hdc_disk_interface:"ide",hdd_disk_image:"",hdd_disk_interface:"ide",initrd:"",kernel_command_line:"",kernel_image:"",legacy_networking:!1,linked_clone:!0,mac_address:"",name:"",on_close:"power_off",options:"-nographic",platform:"",port_name_format:"Ethernet{0}",port_segment_size:0,process_priority:"normal",qemu_path:"",ram:256,symbol:":/symbols/qemu_guest.svg",template_id:"",template_type:"qemu",usage:""})},t.prototype.getVpcsTemplate=function(){return Object(lm.a)({base_script_file:"vpcs_base_config.txt",builtin:!1,category:"guest",compute_id:"local",console_auto_start:!1,console_type:"telnet",default_name_format:"PC{0}",name:"",symbol:":/symbols/vpcs_guest.svg",template_id:"",template_type:"vpcs"})},t.prototype.getVirtualBoxTemplate=function(){return Object(lm.a)({adapter_type:"Intel PRO/1000 MT Desktop (82540EM)",adapters:1,builtin:!1,category:"guest",compute_id:"local",console_auto_start:!1,console_type:"none",custom_adapters:[],default_name_format:"{name}-{0}",first_port_name:"",headless:!1,linked_clone:!1,name:"",on_close:"power_off",port_name_format:"Ethernet{0}",port_segment_size:0,ram:0,symbol:":/symbols/vbox_guest.svg",template_id:"",template_type:"virtualbox",usage:"",use_any_adapter:!1,vmname:""})},t.prototype.getCloudNodeTemplate=function(){return Object(lm.a)({builtin:!1,category:"guest",compute_id:"local",default_name_format:"Cloud{0}",name:"",ports_mapping:[],remote_console_type:"none",symbol:":/symbols/cloud.svg",template_id:"",template_type:"cloud"})},t.prototype.getEthernetHubTemplate=function(){return Object(lm.a)({builtin:!1,category:"switch",compute_id:"local",default_name_format:"Hub{0}",name:"",ports_mapping:[],symbol:":/symbols/hub.svg",template_id:"",template_type:"ethernet_hub"})},t.prototype.getEthernetSwitchTemplate=function(){return Object(lm.a)({builtin:!1,category:"switch",compute_id:"local",console_type:"telnet",default_name_format:"Switch{0}",name:"",ports_mapping:[],symbol:":/symbols/ethernet_switch.svg",template_id:"",template_type:"ethernet_switch"})},t.prototype.getIosTemplate=function(){return Object(lm.a)({auto_delete_disks:!0,builtin:!1,category:"router",compute_id:"local",console_auto_start:!1,console_type:"telnet",default_name_format:"R{0}",disk0:0,disk1:0,exec_area:64,idlemax:500,idlepc:"",idlesleep:30,image:"",mac_addr:"",mmap:!0,name:"",nvram:128,platform:"",private_config:"",ram:128,sparsemem:!0,startup_config:"",symbol:":/symbols/router.svg",system_id:"FTX0945W0MY",template_id:"",template_type:"dynamips",usage:""})},t.prototype.getVmwareTemplate=function(){return Object(lm.a)({adapter_type:"e1000",adapters:1,builtin:!1,category:"guest",compute_id:"local",console_auto_start:!1,console_type:"none",custom_adapters:[],default_name_format:"{name}-{0}",first_port_name:"",headless:!1,linked_clone:!1,name:"",on_close:"power_off",port_name_format:"Ethernet{0}",port_segment_size:0,symbol:":/symbols/vmware_guest.svg",template_id:"",template_type:"vmware",usage:"",use_any_adapter:!1,vmx_path:""})},t.prototype.getDockerTemplate=function(){return Object(lm.a)({adapters:1,builtin:!1,category:"guest",compute_id:"vm",console_auto_start:!1,console_http_path:"/",console_http_port:80,console_resolution:"1024x768",console_type:"telnet",custom_adapters:[],default_name_format:"{name}-{0}",environment:"",extra_hosts:"",image:"",name:"",start_command:"",symbol:":/symbols/docker_guest.svg",template_id:"",template_type:"docker",usage:""})},t.prototype.getIouTemplate=function(){return Object(lm.a)({builtin:!1,category:"switch",compute_id:"vm",console_auto_start:!1,console_type:"telnet",default_name_format:"IOU{0}",ethernet_adapters:1,l1_keepalives:!1,name:"",nvram:128,path:"",private_config:"",ram:256,serial_adapters:0,startup_config:"iou_l2_base_startup-config.txt",symbol:":/symbols/multilayer_switch.svg",template_id:"",template_type:"iou",usage:"",use_default_iou_values:!0})},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}();function aft(t,e){if(1&t&&(ga(0,"mat-option",29),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n.path," ")}}function sft(t,e){if(1&t&&(ga(0,"mat-option",29),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function cft(t,e){if(1&t&&(ga(0,"mat-option",29),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n.filename," ")}}var lft=function(){return{standalone:!0}};function uft(t,e){if(1&t){var n=ka();ga(0,"mat-select",30),xa("ngModelChange",(function(t){return Se(n),Aa().selectedImage=t})),ua(1,cft,2,2,"mat-option",17),va()}if(2&t){var i=Aa();pa("ngModelOptions",jc(3,lft))("ngModel",i.selectedImage),Qi(1),pa("ngForOf",i.qemuImages)}}function hft(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"input",31,32),xa("change",(function(t){return Se(n),Aa().uploadImageFile(t)})),va(),ga(3,"button",33),xa("click",(function(){return Se(n),ha(2).click()})),ds(4,"Browse"),va(),ga(5,"mat-form-field",34),ga(6,"input",35),xa("ngModelChange",(function(t){return Se(n),Aa().chosenImage=t})),va(),va(),va()}if(2&t){var i=Aa();Qi(1),pa("uploader",i.uploader),Qi(5),pa("ngModel",i.chosenImage)}}var dft=function(){function t(t,e,n,i,r,o,a,s,c){this.route=t,this.serverService=e,this.qemuService=n,this.toasterService=i,this.router=r,this.formBuilder=o,this.templateMocksService=a,this.configurationService=s,this.computeService=c,this.qemuBinaries=[],this.consoleTypes=[],this.newImageSelected=!1,this.qemuImages=[],this.chosenImage="",this.isGns3VmAvailable=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0,this.qemuTemplate=new dot,this.nameForm=this.formBuilder.group({templateName:new hp(null,kf.required)}),this.memoryForm=this.formBuilder.group({ramMemory:new hp("256",kf.required)}),this.diskForm=this.formBuilder.group({fileName:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.uploader=new wX({}),this.uploader.onAfterAddingFile=function(t){t.withCredentials=!1},this.uploader.onErrorItem=function(e,n,i,r){t.toasterService.error("An error occured: "+n)},this.uploader.onSuccessItem=function(e,n,i,r){t.qemuService.getImages(t.server).subscribe((function(e){t.qemuImages=e})),t.toasterService.success("Image uploaded")};var e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.templateMocksService.getQemuTemplate().subscribe((function(e){t.qemuTemplate=e})),t.qemuService.getBinaries(e).subscribe((function(e){t.qemuBinaries=e,t.qemuBinaries[0]&&(t.selectedBinary=t.qemuBinaries[0])})),t.qemuService.getImages(e).subscribe((function(e){t.qemuImages=e})),t.consoleTypes=t.configurationService.getConsoleTypes(),t.computeService.getComputes(e).subscribe((function(e){e.filter((function(t){return"vm"===t.compute_id})).length>0&&(t.isGns3VmAvailable=!0)}))}))},t.prototype.setServerType=function(t){"gns3 vm"===t&&this.isGns3VmAvailable?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.setDiskImage=function(t){this.newImageSelected="newImage"===t},t.prototype.uploadImageFile=function(t){var e=t.target.files[0].name;this.diskForm.controls.fileName.setValue(e);var n=this.qemuService.getImagePath(this.server,e);this.uploader.queue.forEach((function(t){return t.url=n}));var i=this.uploader.queue[0];i.options&&(i.options.disableMultipart=!0),this.uploader.uploadItem(i)},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","qemu","templates"])},t.prototype.addTemplate=function(){var t=this;this.nameForm.invalid||this.memoryForm.invalid||!this.selectedImage&&!this.chosenImage?this.toasterService.error("Fill all required fields"):(this.qemuTemplate.ram=+this.memoryForm.get("ramMemory").value,this.qemuTemplate.qemu_path=this.selectedBinary.path,this.qemuTemplate.hda_disk_image=this.newImageSelected?this.diskForm.get("fileName").value:this.selectedImage.path,this.qemuTemplate.template_id=Object(art.v4)(),this.qemuTemplate.name=this.nameForm.get("templateName").value,this.qemuTemplate.compute_id=this.isGns3VmChosen?"vm":"local",this.qemuService.addTemplate(this.server,this.qemuTemplate).subscribe((function(e){t.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(w6),da(Y2),da(lQ),da(Jp),da(oft),da(k6),da(_ot))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-qemu-virtual-machine-template"]],decls:49,vars:19,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"linear"],["label","Server type",3,"completed"],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"disabled","click"],["label","QEMU VM Name",3,"completed"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Please choose a descriptive name for your new QEMU virtual machine","ngDefaultContro",""],["label","QEMU binary and memory",3,"completed"],["placeholder","Qemu binary",3,"ngModel","ngModelOptions","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["matInput","","type","number","placeholder","RAM","formControlName","ramMemory","ngDefaultControl",""],["matSuffix",""],["label","Console type",3,"completed"],["placeholder","Console type",3,"ngModel","ngModelOptions","ngModelChange"],["label","Disk image"],["value","2",1,"radio-button",3,"click"],["placeholder","Disk image (hda)",3,"ngModelOptions","ngModel","ngModelChange",4,"ngIf"],[4,"ngIf"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],["placeholder","Disk image (hda)",3,"ngModelOptions","ngModel","ngModelChange"],["type","file","accept",".qcow2","ng2FileSelect","",1,"nonvisible",3,"uploader","change"],["file",""],["mat-raised-button","","color","primary",1,"file-button",3,"click"],[1,"file-name-form-field"],["matInput","","type","text","formControlName","fileName","placeholder","Please enter name",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New QEMU VM template"),va(),va(),va(),ga(5,"div",4),ga(6,"div",5),ga(7,"mat-vertical-stepper",6),ga(8,"mat-step",7),ga(9,"mat-radio-group",8),ga(10,"mat-radio-button",9),xa("click",(function(){return e.setServerType("local")})),ds(11,"Run this QEMU VM locally"),va(),ga(12,"mat-radio-button",10),xa("click",(function(){return e.setServerType("gns3 vm")})),ds(13,"Run this QEMU VM on the GNS3 VM"),va(),va(),va(),ga(14,"mat-step",11),ga(15,"form",12),ga(16,"mat-form-field",13),ba(17,"input",14),va(),ba(18,"br"),va(),va(),ga(19,"mat-step",15),ga(20,"form",12),ga(21,"mat-form-field",13),ga(22,"mat-select",16),xa("ngModelChange",(function(t){return e.selectedBinary=t})),ua(23,aft,2,2,"mat-option",17),va(),va(),ba(24,"br"),ga(25,"mat-form-field",13),ba(26,"input",18),ga(27,"span",19),ds(28,"MB"),va(),va(),va(),va(),ga(29,"mat-step",20),ga(30,"mat-form-field",13),ga(31,"mat-select",21),xa("ngModelChange",(function(t){return e.qemuTemplate.console_type=t})),ua(32,sft,2,2,"mat-option",17),va(),va(),va(),ga(33,"mat-step",22),ga(34,"form",12),ga(35,"mat-radio-group",8),ga(36,"mat-radio-button",9),xa("click",(function(){return e.setDiskImage("existingImage")})),ds(37,"Existing image"),va(),ga(38,"mat-radio-button",23),xa("click",(function(){return e.setDiskImage("newImage")})),ds(39,"New image"),va(),va(),ba(40,"br"),ba(41,"br"),ua(42,uft,2,4,"mat-select",24),ua(43,hft,7,2,"div",25),va(),va(),va(),va(),ga(44,"div",26),ga(45,"button",27),xa("click",(function(){return e.goBack()})),ds(46,"Cancel"),va(),ga(47,"button",28),xa("click",(function(){return e.addTemplate()})),ds(48,"Add template"),va(),va(),va(),va()),2&t&&(Qi(7),pa("linear",!0),Qi(1),pa("completed",e.isGns3VmChosen||e.isLocalComputerChosen),Qi(4),pa("disabled",!e.isGns3VmAvailable),Qi(2),pa("completed",e.nameForm.get("templateName").value),Qi(1),pa("formGroup",e.nameForm),Qi(4),pa("completed",e.memoryForm.get("ramMemory").value&&e.selectedBinary),Qi(1),pa("formGroup",e.memoryForm),Qi(2),pa("ngModel",e.selectedBinary)("ngModelOptions",jc(17,lft)),Qi(1),pa("ngForOf",e.qemuBinaries),Qi(6),pa("completed",e.qemuTemplate.console_type),Qi(2),pa("ngModel",e.qemuTemplate.console_type)("ngModelOptions",jc(18,lft)),Qi(1),pa("ngForOf",e.consoleTypes),Qi(2),pa("formGroup",e.diskForm),Qi(8),pa("ngIf",!e.newImageSelected),Qi(1),pa("ngIf",e.newImageSelected))},directives:[sat,rat,A6,D6,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,Ef,q3,Ah,a2,EJ,kX],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),fft=function(){function t(t){this.httpServer=t}return t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function pft(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences")}function mft(t,e){1&t&&(ga(0,"button",11),ds(1,"Add VPCS template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/vpcs/addtemplate")}function gft(t,e){1&t&&ba(0,"app-empty-templates-list")}function vft(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function bft(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,vft,13,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.vpcsTemplates)}}function yft(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,bft,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var _ft=function(){function t(t,e,n){this.route=t,this.serverService=e,this.vpcsService=n,this.vpcsTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.vpcsService.getTemplates(this.server).subscribe((function(e){t.vpcsTemplates=e.filter((function(t){return"vpcs"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(fft))},t.\u0275cmp=Ht({type:t,selectors:[["app-vpcs-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VPCS node templates"),va(),ua(5,pft,2,1,"button",4),ua(6,mft,2,1,"button",5),va(),va(),ua(7,gft,1,0,"app-empty-templates-list",6),ua(8,yft,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.vpcsTemplates.length),Qi(1),pa("ngIf",e.vpcsTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),wft=function(){function t(t,e,n,i,r,o,a,s){this.route=t,this.serverService=e,this.vpcsService=n,this.router=i,this.toasterService=r,this.templateMocksService=o,this.formBuilder=a,this.computeService=s,this.templateName="",this.isGns3VmAvailable=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0,this.templateNameForm=this.formBuilder.group({templateName:new hp(null,[kf.required])})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.computeService.getComputes(e).subscribe((function(e){e.filter((function(t){return"vm"===t.compute_id})).length>0&&(t.isGns3VmAvailable=!0)}))}))},t.prototype.setServerType=function(t){"gns3 vm"===t&&this.isGns3VmAvailable?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","vpcs","templates"])},t.prototype.addTemplate=function(){var t,e=this;this.templateNameForm.invalid?this.toasterService.error("Fill all required fields"):(this.templateName=this.templateNameForm.get("templateName").value,this.templateMocksService.getVpcsTemplate().subscribe((function(e){t=e})),t.template_id=Object(art.v4)(),t.name=this.templateName,t.compute_id=this.isGns3VmChosen?"vm":"local",this.vpcsService.addTemplate(this.server,t).subscribe((function(){e.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(fft),da(lQ),da(Y2),da(oft),da(Jp),da(_ot))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-vpcs-template"]],decls:20,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"matCard"],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"disabled","click"],[3,"formGroup"],[1,"form-field"],["matInput","","formControlName","templateName","type","text","placeholder","Template name"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New VPCS node template"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card",5),ga(7,"mat-radio-group",6),ga(8,"mat-radio-button",7),xa("click",(function(){return e.setServerType("local")})),ds(9,"Run the VPCS node locally"),va(),ga(10,"mat-radio-button",8),xa("click",(function(){return e.setServerType("gns3 vm")})),ds(11,"Run the VPCS node on the GNS3 VM"),va(),va(),ga(12,"form",9),ga(13,"mat-form-field",10),ba(14,"input",11),va(),va(),va(),ga(15,"div",12),ga(16,"button",13),xa("click",(function(){return e.goBack()})),ds(17,"Cancel"),va(),ga(18,"button",14),xa("click",(function(){return e.addTemplate()})),ds(19,"Add template"),va(),va(),va(),va()),2&t&&(Qi(10),pa("disabled",!e.isGns3VmAvailable),Qi(2),pa("formGroup",e.templateNameForm))},directives:[f3,A6,D6,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function kft(t,e){if(1&t&&(ga(0,"mat-option",23),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Cft(t,e){if(1&t&&(ga(0,"mat-option",23),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var Sft=function(){return{standalone:!0}};function xft(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"mat-card",7),ga(2,"form",8),ga(3,"mat-form-field",9),ga(4,"input",10),xa("ngModelChange",(function(t){return Se(n),Aa().vpcsTemplate.name=t})),va(),va(),ga(5,"mat-form-field",9),ga(6,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().vpcsTemplate.default_name_format=t})),va(),va(),ga(7,"mat-form-field",9),ga(8,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().vpcsTemplate.base_script_file=t})),va(),va(),ga(9,"mat-form-field",9),ga(10,"input",13),xa("ngModelChange",(function(t){return Se(n),Aa().vpcsTemplate.symbol=t})),va(),va(),ga(11,"button",14),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(12,"Choose symbol"),va(),ba(13,"br"),ba(14,"br"),ga(15,"mat-form-field",9),ga(16,"mat-select",15),xa("ngModelChange",(function(t){return Se(n),Aa().vpcsTemplate.category=t})),ua(17,kft,2,2,"mat-option",16),va(),va(),ga(18,"mat-form-field",17),ga(19,"mat-select",18),xa("ngModelChange",(function(t){return Se(n),Aa().vpcsTemplate.console_type=t})),ua(20,Cft,2,2,"mat-option",16),va(),va(),ga(21,"mat-checkbox",19),xa("ngModelChange",(function(t){return Se(n),Aa().vpcsTemplate.console_auto_start=t})),ds(22," Auto start console "),va(),va(),va(),ga(23,"div",20),ga(24,"button",21),xa("click",(function(){return Se(n),Aa().goBack()})),ds(25,"Cancel"),va(),ga(26,"button",22),xa("click",(function(){return Se(n),Aa().onSave()})),ds(27,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(2),pa("formGroup",i.inputForm),Qi(2),pa("ngModel",i.vpcsTemplate.name),Qi(2),pa("ngModel",i.vpcsTemplate.default_name_format),Qi(2),pa("ngModel",i.vpcsTemplate.base_script_file),Qi(2),pa("ngModel",i.vpcsTemplate.symbol),Qi(6),pa("ngModelOptions",jc(13,Sft))("ngModel",i.vpcsTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModelOptions",jc(14,Sft))("ngModel",i.vpcsTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModelOptions",jc(15,Sft))("ngModel",i.vpcsTemplate.console_auto_start)}}function Oft(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",24),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.vpcsTemplate.symbol)}}var Mft=function(t){return{shadowed:t}},Tft=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.vpcsService=n,this.toasterService=i,this.formBuilder=r,this.vpcsConfigurationService=o,this.router=a,this.isSymbolSelectionOpened=!1,this.consoleTypes=[],this.categories=[],this.inputForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),scriptFile:new hp("",kf.required),symbol:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.vpcsService.getTemplate(t.server,n).subscribe((function(e){t.vpcsTemplate=e}))}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.vpcsConfigurationService.getConsoleTypes(),this.categories=this.vpcsConfigurationService.getCategories()},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","vpcs","templates"])},t.prototype.onSave=function(){var t=this;this.inputForm.invalid?this.toasterService.error("Fill all required fields"):this.vpcsService.saveTemplate(this.server,this.vpcsTemplate).subscribe((function(e){t.toasterService.success("Changes saved")}))},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.vpcsTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(fft),da(Y2),da(Jp),da(T2),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-vpcs-template-details"]],decls:7,vars:5,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","defaultName","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","scriptFile","placeholder","Base script file",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","symbol","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ngModelOptions","ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VPCS device configuration"),va(),va(),va(),ua(5,xft,28,16,"div",4),va(),ua(6,Oft,1,2,"app-symbols-menu",5)),2&t&&(pa("ngClass",Ic(3,Mft,e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.vpcsTemplate),Qi(1),pa("ngIf",e.isSymbolSelectionOpened&&e.vpcsTemplate))},directives:[Oh,Ah,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2,O5,Sp,Eh,F5,EJ,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Eft=function(){function t(t){this.httpServer=t}return t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.prototype.getVirtualMachines=function(t){return this.httpServer.get(t,"/compute/virtualbox/vms")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function Pft(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences")}function Aft(t,e){1&t&&(ga(0,"button",11),ds(1,"Add Virtual Box VM template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/virtualbox/addtemplate")}function jft(t,e){1&t&&ba(0,"app-empty-templates-list")}function Ift(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function Dft(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,Ift,13,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.virtualBoxTemplates)}}function Rft(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,Dft,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var Lft=function(){function t(t,e,n){this.route=t,this.serverService=e,this.virtualBoxService=n,this.virtualBoxTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.virtualBoxService.getTemplates(this.server).subscribe((function(e){t.virtualBoxTemplates=e.filter((function(t){return"virtualbox"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Eft))},t.\u0275cmp=Ht({type:t,selectors:[["app-virtual-box-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VirtualBox VM templates"),va(),ua(5,Pft,2,1,"button",4),ua(6,Aft,2,1,"button",5),va(),va(),ua(7,jft,1,0,"app-empty-templates-list",6),ua(8,Rft,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.virtualBoxTemplates.length),Qi(1),pa("ngIf",e.virtualBoxTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Fft=["customAdaptersConfigurator"];function Nft(t,e){if(1&t&&(ga(0,"mat-option",34),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Bft(t,e){if(1&t&&(ga(0,"mat-option",34),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Hft(t,e){if(1&t&&(ga(0,"mat-option",34),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function zft(t,e){if(1&t&&(ga(0,"mat-option",34),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var Vft=function(){return{standalone:!0}};function Uft(t,e){if(1&t){var n=ka();ga(0,"div",8),ga(1,"mat-accordion"),ga(2,"mat-expansion-panel"),ga(3,"mat-expansion-panel-header"),ga(4,"mat-panel-title"),ds(5," General settings "),va(),va(),ga(6,"form",9),ga(7,"mat-form-field",10),ga(8,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.name=t})),va(),va(),ga(9,"mat-form-field",10),ga(10,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.default_name_format=t})),va(),va(),ga(11,"mat-form-field",10),ga(12,"input",13),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.symbol=t})),va(),va(),ga(13,"button",14),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(14,"Choose symbol"),va(),ba(15,"br"),ba(16,"br"),ga(17,"mat-form-field",10),ga(18,"mat-select",15),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.category=t})),ua(19,Nft,2,2,"mat-option",16),va(),va(),ga(20,"mat-form-field",17),ga(21,"mat-select",18),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.console_type=t})),ua(22,Bft,2,2,"mat-option",16),va(),va(),ga(23,"mat-checkbox",19),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.console_auto_start=t})),ds(24," Auto start console "),va(),ga(25,"mat-form-field",10),ga(26,"input",20),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.ram=t})),va(),ga(27,"span",21),ds(28,"MB"),va(),va(),ga(29,"mat-form-field",10),ga(30,"mat-select",22),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.on_close=t})),ua(31,Hft,2,2,"mat-option",16),va(),va(),va(),ga(32,"mat-checkbox",23),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.headless=t})),ds(33," Start VM in headless mode "),va(),ba(34,"br"),ga(35,"mat-checkbox",23),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.linked_clone=t})),ds(36," Use as a linked base VM (experimental) "),va(),va(),ga(37,"mat-expansion-panel"),ga(38,"mat-expansion-panel-header"),ga(39,"mat-panel-title"),ds(40," Network "),va(),va(),ga(41,"form",9),ga(42,"mat-form-field",10),ga(43,"input",24),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.adapters=t})),va(),va(),ga(44,"mat-form-field",10),ga(45,"input",25),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.first_port_name=t})),va(),va(),ga(46,"mat-form-field",10),ga(47,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.port_name_format=t})),va(),va(),ga(48,"mat-form-field",10),ga(49,"input",27),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.port_segment_size=t})),va(),va(),ga(50,"mat-form-field",10),ga(51,"mat-select",28),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.adapter_type=t})),ua(52,zft,2,2,"mat-option",16),va(),va(),va(),ga(53,"button",29),xa("click",(function(){return Se(n),Aa().setCustomAdaptersConfiguratorState(!0)})),ds(54,"Configure custom adapters"),va(),ba(55,"br"),ga(56,"mat-checkbox",23),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.use_any_adapter=t})),ds(57," Allow GNS3 to use any configured VirtualBox adapter "),va(),va(),ga(58,"mat-expansion-panel"),ga(59,"mat-expansion-panel-header"),ga(60,"mat-panel-title"),ds(61," Usage "),va(),va(),ga(62,"mat-form-field",10),ga(63,"textarea",30),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.usage=t})),va(),va(),va(),va(),ga(64,"div",31),ga(65,"button",32),xa("click",(function(){return Se(n),Aa().goBack()})),ds(66,"Cancel"),va(),ga(67,"button",33),xa("click",(function(){return Se(n),Aa().onSave()})),ds(68,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(6),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.virtualBoxTemplate.name),Qi(2),pa("ngModel",i.virtualBoxTemplate.default_name_format),Qi(2),pa("ngModel",i.virtualBoxTemplate.symbol),Qi(6),pa("ngModelOptions",jc(29,Vft))("ngModel",i.virtualBoxTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModelOptions",jc(30,Vft))("ngModel",i.virtualBoxTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModelOptions",jc(31,Vft))("ngModel",i.virtualBoxTemplate.console_auto_start),Qi(3),pa("ngModel",i.virtualBoxTemplate.ram),Qi(4),pa("ngModelOptions",jc(32,Vft))("ngModel",i.virtualBoxTemplate.on_close),Qi(1),pa("ngForOf",i.onCloseOptions),Qi(1),pa("ngModel",i.virtualBoxTemplate.headless),Qi(3),pa("ngModel",i.virtualBoxTemplate.linked_clone),Qi(6),pa("formGroup",i.networkForm),Qi(2),pa("ngModel",i.virtualBoxTemplate.adapters),Qi(2),pa("ngModelOptions",jc(33,Vft))("ngModel",i.virtualBoxTemplate.first_port_name),Qi(2),pa("ngModel",i.virtualBoxTemplate.port_name_format),Qi(2),pa("ngModel",i.virtualBoxTemplate.port_segment_size),Qi(2),pa("ngModelOptions",jc(34,Vft))("ngModel",i.virtualBoxTemplate.adapter_type),Qi(1),pa("ngForOf",i.networkTypes),Qi(4),pa("ngModel",i.virtualBoxTemplate.use_any_adapter),Qi(7),pa("ngModel",i.virtualBoxTemplate.usage)}}function qft(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",35),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.virtualBoxTemplate.symbol)}}var Gft=function(t){return{shadowed:t}},Wft=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.virtualBoxService=n,this.toasterService=i,this.formBuilder=r,this.virtualBoxConfigurationService=o,this.router=a,this.isSymbolSelectionOpened=!1,this.consoleTypes=[],this.onCloseOptions=[],this.categories=[],this.networkTypes=[],this.displayedColumns=["adapter_number","port_name","adapter_type","actions"],this.isConfiguratorOpened=!1,this.generalSettingsForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),symbol:new hp("",kf.required),ram:new hp("",kf.required)}),this.networkForm=this.formBuilder.group({adapters:new hp("",kf.required),nameFormat:new hp("",kf.required),size:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.virtualBoxService.getTemplate(t.server,n).subscribe((function(e){t.virtualBoxTemplate=e,t.fillCustomAdapters()}))}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.virtualBoxConfigurationService.getConsoleTypes(),this.onCloseOptions=this.virtualBoxConfigurationService.getOnCloseoptions(),this.categories=this.virtualBoxConfigurationService.getCategories(),this.networkTypes=this.virtualBoxConfigurationService.getNetworkTypes()},t.prototype.setCustomAdaptersConfiguratorState=function(t){var e=this;this.isConfiguratorOpened=t,t&&(this.fillCustomAdapters(),this.customAdaptersConfigurator.numberOfAdapters=this.virtualBoxTemplate.adapters,this.customAdaptersConfigurator.adapters=[],this.virtualBoxTemplate.custom_adapters.forEach((function(t){e.customAdaptersConfigurator.adapters.push({adapter_number:t.adapter_number,adapter_type:t.adapter_type})})))},t.prototype.saveCustomAdapters=function(t){this.setCustomAdaptersConfiguratorState(!1),this.virtualBoxTemplate.custom_adapters=t},t.prototype.fillCustomAdapters=function(){var t=this.virtualBoxTemplate.custom_adapters?this.virtualBoxTemplate.custom_adapters:[];this.virtualBoxTemplate.custom_adapters=[];for(var e=0;e<this.virtualBoxTemplate.adapters;e++)this.virtualBoxTemplate.custom_adapters.push(t[e]?t[e]:{adapter_number:e,adapter_type:"e1000"})},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","virtualbox","templates"])},t.prototype.onSave=function(){var t=this;this.generalSettingsForm.invalid||this.networkForm.invalid?this.toasterService.error("Fill all required fields"):(this.fillCustomAdapters(),this.virtualBoxService.saveTemplate(this.server,this.virtualBoxTemplate).subscribe((function(e){t.toasterService.success("Changes saved")})))},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.virtualBoxTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Eft),da(Y2),da(Jp),da(n6),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-virtual-box-template-details"]],viewQuery:function(t,e){var n;1&t&&nl(Fft,!0),2&t&&tl(n=sl())&&(e.customAdaptersConfigurator=n.first)},decls:9,vars:8,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"hidden","networkTypes","displayedColumns","closeConfiguratorEmitter","saveConfigurationEmitter"],["customAdaptersConfigurator",""],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[3,"formGroup"],[1,"form-field"],["matInput","","formControlName","templateName","type","text","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","formControlName","defaultName","type","text","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","formControlName","symbol","type","text","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","formControlName","ram","type","number","placeholder","RAM",3,"ngModel","ngModelChange"],["matSuffix",""],["placeholder","On close",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ngModel","ngModelChange"],["formControlName","adapters","matInput","","type","number","placeholder","Adapters",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","First port name",3,"ngModelOptions","ngModel","ngModelChange"],["formControlName","nameFormat","matInput","","type","text","placeholder","Name format",3,"ngModel","ngModelChange"],["formControlName","size","matInput","","type","number","placeholder","Segment size",3,"ngModel","ngModelChange"],["placeholder","Type",3,"ngModelOptions","ngModel","ngModelChange"],["mat-button","",1,"configButton",3,"click"],["matInput","","type","text",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VirtualBox VM configuration"),va(),va(),va(),ua(5,Uft,69,35,"div",4),va(),ga(6,"app-custom-adapters",5,6),xa("closeConfiguratorEmitter",(function(t){return e.setCustomAdaptersConfiguratorState(t)}))("saveConfigurationEmitter",(function(t){return e.saveCustomAdapters(t)})),va(),ua(8,qft,1,2,"app-symbols-menu",7)),2&t&&(pa("ngClass",Ic(6,Gft,e.isConfiguratorOpened||e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.virtualBoxTemplate),Qi(1),pa("hidden",!(e.isConfiguratorOpened&&e.virtualBoxTemplate))("networkTypes",e.networkTypes)("displayedColumns",e.displayedColumns),Qi(2),pa("ngIf",e.isSymbolSelectionOpened&&e.virtualBoxTemplate))},directives:[Oh,Ah,Hdt,Sdt,ydt,wdt,Cdt,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2,O5,Sp,Eh,F5,Ef,q3,EJ,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function Kft(t,e){if(1&t&&(ga(0,"mat-option",15),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n.vmname," ")}}function Xft(t,e){if(1&t){var n=ka();ga(0,"div",5),ga(1,"mat-card",6),ga(2,"form",7),ga(3,"mat-form-field",8),ga(4,"mat-select",9),xa("ngModelChange",(function(t){return Se(n),Aa().selectedVM=t})),ua(5,Kft,2,2,"mat-option",10),va(),va(),va(),ga(6,"mat-checkbox",11),xa("ngModelChange",(function(t){return Se(n),Aa().virtualBoxTemplate.linked_clone=t})),ds(7," Use as a linked base VM (experimental) "),va(),va(),ga(8,"div",12),ga(9,"button",13),xa("click",(function(){return Se(n),Aa().goBack()})),ds(10,"Cancel"),va(),ga(11,"button",14),xa("click",(function(){return Se(n),Aa().addTemplate()})),ds(12,"Add template"),va(),va(),va()}if(2&t){var i=Aa();Qi(2),pa("formGroup",i.vmForm),Qi(2),pa("ngModel",i.selectedVM),Qi(1),pa("ngForOf",i.virtualMachines),Qi(1),pa("ngModel",i.virtualBoxTemplate.linked_clone)}}var Yft=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.virtualBoxService=n,this.toasterService=i,this.templateMocksService=r,this.router=o,this.formBuilder=a,this.vmForm=this.formBuilder.group({vm:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.virtualBoxService.getVirtualMachines(t.server).subscribe((function(e){t.virtualMachines=e,t.templateMocksService.getVirtualBoxTemplate().subscribe((function(e){t.virtualBoxTemplate=e}))}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","virtualbox","templates"])},t.prototype.addTemplate=function(){var t=this;this.vmForm.invalid?this.toasterService.error("Fill all required fields"):(this.virtualBoxTemplate.name=this.selectedVM.vmname,this.virtualBoxTemplate.vmname=this.selectedVM.vmname,this.virtualBoxTemplate.ram=this.selectedVM.ram,this.virtualBoxTemplate.template_id=Object(art.v4)(),this.virtualBoxService.addTemplate(this.server,this.virtualBoxTemplate).subscribe((function(){t.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Eft),da(Y2),da(oft),da(lQ),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-virtual-box-template"]],decls:6,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["placeholder","VM list","formControlName","vm",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New VirtualBox VM template"),va(),va(),va(),ua(5,Xft,13,4,"div",4),va()),2&t&&(Qi(5),pa("ngIf",e.virtualBoxTemplate))},directives:[Ah,f3,xp,gf,Pp,Y3,O5,mf,Fp,Eh,F5,Sp,a2,EJ],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Zft=function(){function t(t){this.route=t,this.serverId=""}return t.prototype.ngOnInit=function(){this.serverId=this.route.snapshot.paramMap.get("server_id")},t.\u0275fac=function(e){return new(e||t)(da(ZY))},t.\u0275cmp=Ht({type:t,selectors:[["app-built-in-preferences"]],decls:16,vars:4,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["mat-button","",1,"cancel-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],[3,"routerLink"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Built-in preferences"),va(),ga(5,"button",4),ds(6,"Back"),va(),va(),va(),ga(7,"div",5),ga(8,"div",6),ga(9,"mat-nav-list"),ga(10,"mat-list-item",7),ds(11," Ethernet hubs "),va(),ga(12,"mat-list-item",7),ds(13," Ethernet switches "),va(),ga(14,"mat-list-item",7),ds(15," Cloud nodes "),va(),va(),va(),va(),va()),2&t&&(Qi(5),La("routerLink","/server/",e.serverId,"/preferences"),Qi(5),La("routerLink","/server/",e.serverId,"/preferences/builtin/ethernet-hubs"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/builtin/ethernet-switches"),Qi(2),La("routerLink","/server/",e.serverId,"/preferences/builtin/cloud-nodes"))},directives:[a2,hQ,y8,S8],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Qft=function(){function t(t){this.httpServer=t}return t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function $ft(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/builtin")}function Jft(t,e){1&t&&(ga(0,"button",11),ds(1,"Add Ethernet hub template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/builtin/ethernet-hubs/addtemplate")}function tpt(t,e){1&t&&ba(0,"app-empty-templates-list")}function ept(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function npt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,ept,13,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.ethernetHubsTemplates)}}function ipt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,npt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var rpt=function(){function t(t,e,n){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.ethernetHubsTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.builtInTemplatesService.getTemplates(this.server).subscribe((function(e){t.ethernetHubsTemplates=e.filter((function(t){return"ethernet_hub"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft))},t.\u0275cmp=Ht({type:t,selectors:[["app-ethernet-hubs-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Ethernet hubs templates"),va(),ua(5,$ft,2,1,"button",4),ua(6,Jft,2,1,"button",5),va(),va(),ua(7,tpt,1,0,"app-empty-templates-list",6),ua(8,ipt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.ethernetHubsTemplates.length),Qi(1),pa("ngIf",e.ethernetHubsTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),opt=function(){function t(t,e,n,i,r,o,a,s){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.router=i,this.toasterService=r,this.templateMocksService=o,this.formBuilder=a,this.computeService=s,this.templateName="",this.isGns3VmAvailable=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0,this.formGroup=this.formBuilder.group({templateName:new hp("",kf.required),numberOfPorts:new hp(8,kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.computeService.getComputes(e).subscribe((function(e){e.filter((function(t){return"vm"===t.compute_id})).length>0&&(t.isGns3VmAvailable=!0)}))}))},t.prototype.setServerType=function(t){"gns3 vm"===t&&this.isGns3VmAvailable?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","builtin","ethernet-hubs"])},t.prototype.addTemplate=function(){var t=this;if(this.formGroup.invalid)this.toasterService.error("Fill all required fields");else{var e;this.templateMocksService.getEthernetHubTemplate().subscribe((function(t){e=t})),e.template_id=Object(art.v4)(),e.name=this.formGroup.get("templateName").value,e.compute_id=this.isGns3VmChosen?"vm":"local";for(var n=0;n<this.formGroup.get("numberOfPorts").value;n++)e.ports_mapping.push({name:"Ethernet"+n,port_number:n});this.builtInTemplatesService.addTemplate(this.server,e).subscribe((function(){t.goBack()}))}},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft),da(lQ),da(Y2),da(oft),da(Jp),da(_ot))},t.\u0275cmp=Ht({type:t,selectors:[["app-ethernet-hubs-add-template"]],decls:22,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"matCard"],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"disabled","click"],[3,"formGroup"],[1,"form-field"],["formControlName","templateName","matInput","","type","text","placeholder","Template name"],["formControlName","numberOfPorts","matInput","","type","number","placeholder","Number of ports"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New Ethernet hub template"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card",5),ga(7,"mat-radio-group",6),ga(8,"mat-radio-button",7),xa("click",(function(){return e.setServerType("local")})),ds(9,"Run the Ethernet Hub locally"),va(),ga(10,"mat-radio-button",8),xa("click",(function(){return e.setServerType("gns3 vm")})),ds(11,"Run the Ethernet Hub on the GNS3 VM"),va(),va(),ga(12,"form",9),ga(13,"mat-form-field",10),ba(14,"input",11),va(),ga(15,"mat-form-field",10),ba(16,"input",12),va(),va(),va(),ga(17,"div",13),ga(18,"button",14),xa("click",(function(){return e.goBack()})),ds(19,"Cancel"),va(),ga(20,"button",15),xa("click",(function(){return e.addTemplate()})),ds(21,"Add template"),va(),va(),va(),va()),2&t&&(Qi(10),pa("disabled",!e.isGns3VmAvailable),Qi(2),pa("formGroup",e.formGroup))},directives:[f3,A6,D6,xp,gf,Pp,Y3,cf,s5,mf,Fp,Ef,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function apt(t,e){if(1&t&&(ga(0,"mat-option",19),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}var spt=function(){return{standalone:!0}};function cpt(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"mat-card"),ga(2,"form",7),ga(3,"mat-form-field",8),ga(4,"input",9),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetHubTemplate.name=t})),va(),va(),ga(5,"mat-form-field",8),ga(6,"input",10),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetHubTemplate.default_name_format=t})),va(),va(),ga(7,"mat-form-field",8),ga(8,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetHubTemplate.symbol=t})),va(),va(),ga(9,"button",12),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(10,"Choose symbol"),va(),ba(11,"br"),ba(12,"br"),ga(13,"mat-form-field",8),ga(14,"mat-select",13),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetHubTemplate.category=t})),ua(15,apt,2,2,"mat-option",14),va(),va(),ga(16,"mat-form-field",8),ga(17,"input",15),xa("ngModelChange",(function(t){return Se(n),Aa().numberOfPorts=t})),va(),va(),va(),va(),ga(18,"div",16),ga(19,"button",17),xa("click",(function(){return Se(n),Aa().goBack()})),ds(20,"Cancel"),va(),ga(21,"button",18),xa("click",(function(){return Se(n),Aa().onSave()})),ds(22,"Save"),va(),ba(23,"br"),va(),va()}if(2&t){var i=Aa();Qi(2),pa("formGroup",i.inputForm),Qi(2),pa("ngModel",i.ethernetHubTemplate.name),Qi(2),pa("ngModel",i.ethernetHubTemplate.default_name_format),Qi(2),pa("ngModel",i.ethernetHubTemplate.symbol),Qi(6),pa("ngModelOptions",jc(9,spt))("ngModel",i.ethernetHubTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModel",i.numberOfPorts)("ngModelOptions",jc(10,spt))}}function lpt(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",20),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.ethernetHubTemplate.symbol)}}var upt=function(t){return{shadowed:t}},hpt=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.toasterService=i,this.formBuilder=r,this.builtInTemplatesConfigurationService=o,this.router=a,this.isSymbolSelectionOpened=!1,this.categories=[],this.inputForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),symbol:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.categories=t.builtInTemplatesConfigurationService.getCategoriesForEthernetHubs(),t.builtInTemplatesService.getTemplate(t.server,n).subscribe((function(e){t.ethernetHubTemplate=e,t.numberOfPorts=t.ethernetHubTemplate.ports_mapping.length}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","builtin","ethernet-hubs"])},t.prototype.onSave=function(){var t=this;if(this.inputForm.invalid||!this.numberOfPorts)this.toasterService.error("Fill all required fields");else{this.ethernetHubTemplate.ports_mapping=[];for(var e=0;e<this.numberOfPorts;e++)this.ethernetHubTemplate.ports_mapping.push({name:"Ethernet"+e,port_number:e});this.builtInTemplatesService.saveTemplate(this.server,this.ethernetHubTemplate).subscribe((function(e){t.toasterService.success("Changes saved")}))}},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.ethernetHubTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft),da(Y2),da(Jp),da(K5),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-ethernet-hubs-template-details"]],decls:7,vars:5,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","defaultName","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","symbol","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["matInput","","type","number","placeholder","Number of ports",3,"ngModel","ngModelOptions","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Ethernet hub settings"),va(),va(),va(),ua(5,cpt,24,11,"div",4),va(),ua(6,lpt,1,2,"app-symbols-menu",5)),2&t&&(pa("ngClass",Ic(3,upt,e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.ethernetHubTemplate),Qi(1),pa("ngIf",e.isSymbolSelectionOpened&&e.ethernetHubTemplate))},directives:[Oh,Ah,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2,O5,Sp,Eh,Ef,EJ,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function dpt(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/builtin")}function fpt(t,e){1&t&&(ga(0,"button",11),ds(1,"Add cloud node template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/builtin/cloud-nodes/addtemplate")}function ppt(t,e){1&t&&ba(0,"app-empty-templates-list")}function mpt(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function gpt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,mpt,13,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.cloudNodesTemplates)}}function vpt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,gpt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var bpt=function(){function t(t,e,n){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.cloudNodesTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.builtInTemplatesService.getTemplates(this.server).subscribe((function(e){t.cloudNodesTemplates=e.filter((function(t){return"cloud"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft))},t.\u0275cmp=Ht({type:t,selectors:[["app-cloud-nodes-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Cloud nodes templates"),va(),ua(5,dpt,2,1,"button",4),ua(6,fpt,2,1,"button",5),va(),va(),ua(7,ppt,1,0,"app-empty-templates-list",6),ua(8,vpt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.cloudNodesTemplates.length),Qi(1),pa("ngIf",e.cloudNodesTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),ypt=function(){function t(t,e,n,i,r,o,a,s){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.router=i,this.toasterService=r,this.templateMocksService=o,this.formBuilder=a,this.computeService=s,this.templateName="",this.isGns3VmAvailable=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0,this.formGroup=this.formBuilder.group({templateName:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.computeService.getComputes(e).subscribe((function(e){e.filter((function(t){return"vm"===t.compute_id})).length>0&&(t.isGns3VmAvailable=!0)}))}))},t.prototype.setServerType=function(t){"gns3 vm"===t&&this.isGns3VmAvailable?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","builtin","cloud-nodes"])},t.prototype.addTemplate=function(){var t,e=this;this.formGroup.invalid?this.toasterService.error("Fill all required fields"):(this.templateMocksService.getCloudNodeTemplate().subscribe((function(e){t=e})),t.template_id=Object(art.v4)(),t.name=this.formGroup.get("templateName").value,t.compute_id=this.isGns3VmChosen?"vm":"local",this.builtInTemplatesService.addTemplate(this.server,t).subscribe((function(t){e.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft),da(lQ),da(Y2),da(oft),da(Jp),da(_ot))},t.\u0275cmp=Ht({type:t,selectors:[["app-cloud-nodes-add-template"]],decls:20,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"matCard"],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"disabled","click"],[3,"formGroup"],[1,"form-field"],["formControlName","templateName","matInput","","type","text","placeholder","Template name"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New cloud node template"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card",5),ga(7,"mat-radio-group",6),ga(8,"mat-radio-button",7),xa("click",(function(){return e.setServerType("local")})),ds(9,"Run the cloud node locally"),va(),ga(10,"mat-radio-button",8),xa("click",(function(){return e.setServerType("gns3 vm")})),ds(11,"Run the cloud node on the GNS3 VM"),va(),va(),ga(12,"form",9),ga(13,"mat-form-field",10),ba(14,"input",11),va(),va(),va(),ga(15,"div",12),ga(16,"button",13),xa("click",(function(){return e.goBack()})),ds(17,"Cancel"),va(),ga(18,"button",14),xa("click",(function(){return e.addTemplate()})),ds(19,"Add template"),va(),va(),va(),va()),2&t&&(Qi(10),pa("disabled",!e.isGns3VmAvailable),Qi(2),pa("formGroup",e.formGroup))},directives:[f3,A6,D6,xp,gf,Pp,Y3,cf,s5,mf,Fp,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function _pt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function wpt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function kpt(t,e){if(1&t&&(ga(0,"div",7),ga(1,"div",7),ds(2),va(),ba(3,"br"),ba(4,"br"),va()),2&t){var n=e.$implicit;Qi(2),fs(n.name)}}function Cpt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Spt(t,e){if(1&t&&(ga(0,"div",7),ga(1,"div",7),ds(2),va(),ba(3,"br"),ba(4,"br"),va()),2&t){var n=e.$implicit;Qi(2),fs(n.name)}}function xpt(t,e){1&t&&(ga(0,"th",42),ds(1," Name "),va())}function Opt(t,e){if(1&t&&(ga(0,"td",43),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.name," ")}}function Mpt(t,e){1&t&&(ga(0,"th",42),ds(1," Local port "),va())}function Tpt(t,e){if(1&t&&(ga(0,"td",43),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.rport," ")}}function Ept(t,e){1&t&&(ga(0,"th",42),ds(1," Type "),va())}function Ppt(t,e){if(1&t&&(ga(0,"td",43),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.rhost," ")}}function Apt(t,e){1&t&&(ga(0,"th",42),ds(1," Remote port "),va())}function jpt(t,e){if(1&t&&(ga(0,"td",43),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.lport," ")}}function Ipt(t,e){1&t&&ba(0,"tr",44)}function Dpt(t,e){1&t&&ba(0,"tr",45)}function Rpt(t,e){if(1&t&&(ga(0,"table",33),ya(1,34),ua(2,xpt,2,0,"th",35),ua(3,Opt,2,1,"td",36),_a(),ya(4,37),ua(5,Mpt,2,0,"th",35),ua(6,Tpt,2,1,"td",36),_a(),ya(7,38),ua(8,Ept,2,0,"th",35),ua(9,Ppt,2,1,"td",36),_a(),ya(10,39),ua(11,Apt,2,0,"th",35),ua(12,jpt,2,1,"td",36),_a(),ua(13,Ipt,1,0,"tr",40),ua(14,Dpt,1,0,"tr",41),va()),2&t){var n=Aa(2);pa("dataSource",n.dataSourceUdp),Qi(13),pa("matHeaderRowDef",n.displayedColumns),Qi(1),pa("matRowDefColumns",n.displayedColumns)}}function Lpt(t,e){1&t&&ba(0,"br")}var Fpt=function(){return{standalone:!0}};function Npt(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"mat-accordion"),ga(2,"mat-expansion-panel"),ga(3,"mat-expansion-panel-header"),ga(4,"mat-panel-title"),ds(5," General "),va(),va(),ga(6,"mat-form-field",7),ga(7,"input",8),xa("ngModelChange",(function(t){return Se(n),Aa().cloudNodeTemplate.name=t})),va(),va(),ga(8,"mat-form-field",7),ga(9,"input",9),xa("ngModelChange",(function(t){return Se(n),Aa().cloudNodeTemplate.default_name_format=t})),va(),va(),ga(10,"mat-form-field",7),ga(11,"input",10),xa("ngModelChange",(function(t){return Se(n),Aa().cloudNodeTemplate.symbol=t})),va(),va(),ga(12,"button",11),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(13,"Choose symbol"),va(),ba(14,"br"),ba(15,"br"),ga(16,"mat-form-field",7),ga(17,"mat-select",12),xa("ngModelChange",(function(t){return Se(n),Aa().cloudNodeTemplate.category=t})),ua(18,_pt,2,2,"mat-option",13),va(),va(),ga(19,"mat-form-field",14),ga(20,"mat-select",15),xa("ngModelChange",(function(t){return Se(n),Aa().cloudNodeTemplate.console_type=t})),ua(21,wpt,2,2,"mat-option",13),va(),va(),ga(22,"mat-form-field",7),ga(23,"input",16),xa("ngModelChange",(function(t){return Se(n),Aa().cloudNodeTemplate.remote_console_host=t})),va(),va(),ga(24,"mat-form-field",7),ga(25,"input",17),xa("ngModelChange",(function(t){return Se(n),Aa().cloudNodeTemplate.remote_console_port=t})),va(),va(),ga(26,"mat-form-field",7),ga(27,"input",18),xa("ngModelChange",(function(t){return Se(n),Aa().cloudNodeTemplate.remote_console_http_path=t})),va(),va(),va(),ga(28,"mat-expansion-panel"),ga(29,"mat-expansion-panel-header"),ga(30,"mat-panel-title"),ds(31," Ethernet interfaces "),va(),va(),ua(32,kpt,5,1,"div",19),ga(33,"mat-form-field",14),ga(34,"mat-select",20),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetInterface=t})),ua(35,Cpt,2,2,"mat-option",13),va(),va(),ga(36,"button",21),xa("click",(function(){return Se(n),Aa().onAddEthernetInterface()})),ds(37,"Add"),va(),va(),ga(38,"mat-expansion-panel"),ga(39,"mat-expansion-panel-header"),ga(40,"mat-panel-title"),ds(41," TAP interfaces "),va(),va(),ua(42,Spt,5,1,"div",19),ga(43,"mat-form-field",7),ga(44,"input",22),xa("ngModelChange",(function(t){return Se(n),Aa().tapInterface=t})),va(),va(),ga(45,"button",21),xa("click",(function(){return Se(n),Aa().onAddTapInterface()})),ds(46,"Add"),va(),va(),ga(47,"mat-expansion-panel"),ga(48,"mat-expansion-panel-header"),ga(49,"mat-panel-title"),ds(50," UDP tunnels "),va(),va(),ua(51,Rpt,15,3,"table",23),ua(52,Lpt,1,0,"br",24),ga(53,"mat-form-field",7),ga(54,"input",25),xa("ngModelChange",(function(t){return Se(n),Aa().newPort.name=t})),va(),va(),ga(55,"mat-form-field",7),ga(56,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().newPort.lport=t})),va(),va(),ga(57,"mat-form-field",7),ga(58,"input",27),xa("ngModelChange",(function(t){return Se(n),Aa().newPort.rhost=t})),va(),va(),ga(59,"mat-form-field",7),ga(60,"input",28),xa("ngModelChange",(function(t){return Se(n),Aa().newPort.rport=t})),va(),va(),ga(61,"button",21),xa("click",(function(){return Se(n),Aa().onAddUdpInterface()})),ds(62,"Add"),va(),va(),va(),ga(63,"div",29),ga(64,"button",30),xa("click",(function(){return Se(n),Aa().goBack()})),ds(65,"Cancel"),va(),ga(66,"button",31),xa("click",(function(){return Se(n),Aa().onSave()})),ds(67,"Save"),va(),ba(68,"br"),va(),va()}if(2&t){var i=Aa();Qi(7),pa("ngModel",i.cloudNodeTemplate.name),Qi(2),pa("ngModel",i.cloudNodeTemplate.default_name_format),Qi(2),pa("ngModel",i.cloudNodeTemplate.symbol),Qi(6),pa("ngModel",i.cloudNodeTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModel",i.cloudNodeTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(2),pa("ngModel",i.cloudNodeTemplate.remote_console_host),Qi(2),pa("ngModel",i.cloudNodeTemplate.remote_console_port),Qi(2),pa("ngModel",i.cloudNodeTemplate.remote_console_http_path),Qi(5),pa("ngForOf",i.portsMappingEthernet),Qi(2),pa("ngModelOptions",jc(22,Fpt))("ngModel",i.ethernetInterface),Qi(1),pa("ngForOf",i.ethernetInterfaces),Qi(7),pa("ngForOf",i.portsMappingTap),Qi(2),pa("ngModel",i.tapInterface),Qi(7),pa("ngIf",i.dataSourceUdp.length),Qi(1),pa("ngIf",i.dataSourceUdp.length),Qi(2),pa("ngModel",i.newPort.name),Qi(2),pa("ngModel",i.newPort.lport),Qi(2),pa("ngModel",i.newPort.rhost),Qi(2),pa("ngModel",i.newPort.rport)}}function Bpt(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",46),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.cloudNodeTemplate.symbol)}}var Hpt=function(t){return{shadowed:t}},zpt=function(){function t(t,e,n,i,r,o){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.toasterService=i,this.builtInTemplatesConfigurationService=r,this.router=o,this.isSymbolSelectionOpened=!1,this.categories=[],this.consoleTypes=[],this.tapInterface="",this.ethernetInterface="",this.ethernetInterfaces=["Ethernet 2","Ethernet 3"],this.portsMappingEthernet=[],this.portsMappingTap=[],this.portsMappingUdp=[],this.displayedColumns=["name","lport","rhost","rport"],this.dataSourceUdp=[],this.newPort={name:"",port_number:0}}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.builtInTemplatesService.getTemplate(t.server,n).subscribe((function(e){t.cloudNodeTemplate=e,t.portsMappingEthernet=t.cloudNodeTemplate.ports_mapping.filter((function(t){return"ethernet"===t.type})),t.portsMappingTap=t.cloudNodeTemplate.ports_mapping.filter((function(t){return"tap"===t.type})),t.portsMappingUdp=t.cloudNodeTemplate.ports_mapping.filter((function(t){return"udp"===t.type})),t.dataSourceUdp=t.portsMappingUdp}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","builtin","cloud-nodes"])},t.prototype.getConfiguration=function(){this.categories=this.builtInTemplatesConfigurationService.getCategoriesForCloudNodes(),this.consoleTypes=this.builtInTemplatesConfigurationService.getConsoleTypesForCloudNodes()},t.prototype.onAddEthernetInterface=function(){this.ethernetInterface&&this.portsMappingEthernet.push({interface:this.ethernetInterface,name:this.ethernetInterface,port_number:0,type:"ethernet"})},t.prototype.onAddTapInterface=function(){this.tapInterface&&this.portsMappingTap.push({interface:this.tapInterface,name:this.tapInterface,port_number:0,type:"tap"})},t.prototype.onAddUdpInterface=function(){this.portsMappingUdp.push(this.newPort),this.dataSourceUdp=GQ(this.portsMappingUdp),this.newPort={name:"",port_number:0}},t.prototype.onSave=function(){var t=this;this.cloudNodeTemplate.ports_mapping=GQ(this.portsMappingEthernet,this.portsMappingTap),this.builtInTemplatesService.saveTemplate(this.server,this.cloudNodeTemplate).subscribe((function(e){t.toasterService.success("Changes saved")}))},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.cloudNodeTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft),da(Y2),da(K5),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-cloud-nodes-template-details"]],decls:7,vars:5,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[1,"form-field"],["matInput","","type","text","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"select"],["placeholder","Console type",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Console host",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Console port",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Console HTTP path",3,"ngModel","ngModelChange"],["class","form-field",4,"ngFor","ngForOf"],["placeholder","Ethernet interface",3,"ngModelOptions","ngModel","ngModelChange"],["mat-button","",1,"form-field",3,"click"],["matInput","","type","text","placeholder","TAP interface",3,"ngModel","ngModelChange"],["class","table","mat-table","",3,"dataSource",4,"ngIf"],[4,"ngIf"],["matInput","","type","text","placeholder","Name",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","Local port",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Remote host",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","Remote port",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],["mat-table","",1,"table",3,"dataSource"],["matColumnDef","name"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","rport"],["matColumnDef","rhost"],["matColumnDef","lport"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-header-cell",""],["mat-cell",""],["mat-header-row",""],["mat-row",""],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Cloud configuration"),va(),va(),va(),ua(5,Npt,69,23,"div",4),va(),ua(6,Bpt,1,2,"app-symbols-menu",5)),2&t&&(pa("ngClass",Ic(3,Hpt,e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.cloudNodeTemplate),Qi(1),pa("ngIf",e.isSymbolSelectionOpened&&e.cloudNodeTemplate))},directives:[Oh,Ah,Sdt,ydt,wdt,Cdt,Y3,s5,cf,mf,Sp,a2,O5,Eh,Ef,EJ,$5,n4,t4,J5,a4,c4,i4,o4,l4,h4,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function Vpt(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/builtin")}function Upt(t,e){1&t&&(ga(0,"button",11),ds(1,"Add Ethernet switch template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/builtin/ethernet-switches/addtemplate")}function qpt(t,e){1&t&&ba(0,"app-empty-templates-list")}function Gpt(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function Wpt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,Gpt,13,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.ethernetSwitchesTemplates)}}function Kpt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,Wpt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var Xpt=function(){function t(t,e,n){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.ethernetSwitchesTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.builtInTemplatesService.getTemplates(this.server).subscribe((function(e){t.ethernetSwitchesTemplates=e.filter((function(t){return"ethernet_switch"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft))},t.\u0275cmp=Ht({type:t,selectors:[["app-ethernet-switches-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Ethernet switches templates"),va(),ua(5,Vpt,2,1,"button",4),ua(6,Upt,2,1,"button",5),va(),va(),ua(7,qpt,1,0,"app-empty-templates-list",6),ua(8,Kpt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.ethernetSwitchesTemplates.length),Qi(1),pa("ngIf",e.ethernetSwitchesTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Ypt=function(){function t(t,e,n,i,r,o,a,s){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.router=i,this.toasterService=r,this.templateMocksService=o,this.formBuilder=a,this.computeService=s,this.templateName="",this.isGns3VmAvailable=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0,this.formGroup=this.formBuilder.group({templateName:new hp("",kf.required),numberOfPorts:new hp(8,kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.computeService.getComputes(e).subscribe((function(e){e.filter((function(t){return"vm"===t.compute_id})).length>0&&(t.isGns3VmAvailable=!0)}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","builtin","ethernet-switches"])},t.prototype.setServerType=function(t){"gns3 vm"===t&&this.isGns3VmAvailable?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.addTemplate=function(){var t=this;if(this.formGroup.invalid)this.toasterService.error("Fill all required fields");else{var e;this.templateMocksService.getEthernetSwitchTemplate().subscribe((function(t){e=t})),e.template_id=Object(art.v4)(),e.name=this.formGroup.get("templateName").value,e.compute_id=this.isGns3VmChosen?"vm":"local";for(var n=0;n<this.formGroup.get("numberOfPorts").value;n++)e.ports_mapping.push({ethertype:"",name:"Ethernet"+n,port_number:n,type:"access",vlan:1});this.builtInTemplatesService.addTemplate(this.server,e).subscribe((function(e){t.goBack()}))}},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft),da(lQ),da(Y2),da(oft),da(Jp),da(_ot))},t.\u0275cmp=Ht({type:t,selectors:[["app-ethernet-switches-add-template"]],decls:22,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"matCard"],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"disabled","click"],[3,"formGroup"],[1,"form-field"],["formControlName","templateName","matInput","","type","text","placeholder","Template name"],["formControlName","numberOfPorts","matInput","","type","number","placeholder","Number of ports"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New Ethernet switch template"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card",5),ga(7,"mat-radio-group",6),ga(8,"mat-radio-button",7),xa("click",(function(){return e.setServerType("local")})),ds(9,"Run the Ethernet switch locally"),va(),ga(10,"mat-radio-button",8),xa("click",(function(){return e.setServerType("gns3 vm")})),ds(11,"Run the Ethernet switch on the GNS3 VM"),va(),va(),ga(12,"form",9),ga(13,"mat-form-field",10),ba(14,"input",11),va(),ga(15,"mat-form-field",10),ba(16,"input",12),va(),va(),va(),ga(17,"div",13),ga(18,"button",14),xa("click",(function(){return e.goBack()})),ds(19,"Cancel"),va(),ga(20,"button",15),xa("click",(function(){return e.addTemplate()})),ds(21,"Add template"),va(),va(),va(),va()),2&t&&(Qi(10),pa("disabled",!e.isGns3VmAvailable),Qi(2),pa("formGroup",e.formGroup))},directives:[f3,A6,D6,xp,gf,Pp,Y3,cf,s5,mf,Fp,Ef,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function Zpt(t,e){if(1&t&&(ga(0,"mat-option",22),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Qpt(t,e){if(1&t&&(ga(0,"mat-option",22),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var $pt=function(){return{standalone:!0}};function Jpt(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"mat-accordion"),ga(2,"mat-expansion-panel"),ga(3,"mat-expansion-panel-header"),ga(4,"mat-panel-title"),ds(5," General settings "),va(),va(),ga(6,"form",7),ga(7,"mat-form-field",8),ga(8,"input",9),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetSwitchTemplate.name=t})),va(),va(),ga(9,"mat-form-field",8),ga(10,"input",10),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetSwitchTemplate.default_name_format=t})),va(),va(),ga(11,"mat-form-field",8),ga(12,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetSwitchTemplate.symbol=t})),va(),va(),ga(13,"button",12),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(14,"Choose symbol"),va(),ba(15,"br"),ba(16,"br"),ga(17,"mat-form-field",8),ga(18,"mat-select",13),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetSwitchTemplate.category=t})),ua(19,Zpt,2,2,"mat-option",14),va(),va(),ga(20,"mat-form-field",15),ga(21,"mat-select",16),xa("ngModelChange",(function(t){return Se(n),Aa().ethernetSwitchTemplate.console_type=t})),ua(22,Qpt,2,2,"mat-option",14),va(),va(),va(),va(),ga(23,"mat-expansion-panel"),ga(24,"mat-expansion-panel-header"),ga(25,"mat-panel-title"),ds(26," Port settings "),va(),va(),ba(27,"app-ports",17,18),va(),va(),ga(29,"div",19),ga(30,"button",20),xa("click",(function(){return Se(n),Aa().goBack()})),ds(31,"Cancel"),va(),ga(32,"button",21),xa("click",(function(){return Se(n),Aa().onSave()})),ds(33,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(6),pa("formGroup",i.inputForm),Qi(2),pa("ngModel",i.ethernetSwitchTemplate.name),Qi(2),pa("ngModel",i.ethernetSwitchTemplate.default_name_format),Qi(2),pa("ngModel",i.ethernetSwitchTemplate.symbol),Qi(6),pa("ngModelOptions",jc(11,$pt))("ngModel",i.ethernetSwitchTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModelOptions",jc(12,$pt))("ngModel",i.ethernetSwitchTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(5),pa("ethernetPorts",i.ethernetSwitchTemplate.ports_mapping)}}function tmt(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",23),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.ethernetSwitchTemplate.symbol)}}var emt=function(t){return{shadowed:t}},nmt=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.builtInTemplatesService=n,this.toasterService=i,this.formBuilder=r,this.builtInTemplatesConfigurationService=o,this.router=a,this.isSymbolSelectionOpened=!1,this.categories=[],this.consoleTypes=[],this.inputForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),symbol:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.builtInTemplatesService.getTemplate(t.server,n).subscribe((function(e){t.ethernetSwitchTemplate=e}))}))},t.prototype.getConfiguration=function(){this.categories=this.builtInTemplatesConfigurationService.getCategoriesForEthernetSwitches(),this.consoleTypes=this.builtInTemplatesConfigurationService.getConsoleTypesForEthernetSwitches()},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","builtin","ethernet-switches"])},t.prototype.onSave=function(){var t=this;this.inputForm.invalid?this.toasterService.error("Fill all required fields"):(this.ethernetSwitchTemplate.ports_mapping=this.portsComponent.ethernetPorts,this.builtInTemplatesService.saveTemplate(this.server,this.ethernetSwitchTemplate).subscribe((function(e){t.toasterService.success("Changes saved")})))},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.ethernetSwitchTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Qft),da(Y2),da(Jp),da(K5),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-ethernet-switches-template-details"]],viewQuery:function(t,e){var n;1&t&&nl(H4,!0),2&t&&tl(n=sl())&&(e.portsComponent=n.first)},decls:7,vars:5,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","defaultName","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","symbol","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ethernetPorts"],["ports",""],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Ethernet switch configuration"),va(),va(),va(),ua(5,Jpt,34,13,"div",4),va(),ua(6,tmt,1,2,"app-symbols-menu",5)),2&t&&(pa("ngClass",Ic(3,emt,e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.ethernetSwitchTemplate),Qi(1),pa("ngIf",e.isSymbolSelectionOpened&&e.ethernetSwitchTemplate))},directives:[Oh,Ah,Sdt,ydt,wdt,Cdt,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2,O5,Sp,Eh,H4,EJ,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function imt(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences")}function rmt(t,e){1&t&&(ga(0,"button",11),ds(1,"Add IOS router template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/dynamips/templates/addtemplate")}function omt(t,e){1&t&&ba(0,"app-empty-templates-list")}function amt(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),ga(13,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).copyTemplate(t)})),ga(14,"mat-icon"),ds(15,"content_copy"),va(),ga(16,"span"),ds(17,"Copy"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function smt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,amt,18,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.iosTemplates)}}function cmt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,smt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var lmt=function(){function t(t,e,n,i){this.route=t,this.serverService=e,this.iosService=n,this.router=i,this.iosTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.iosService.getTemplates(this.server).subscribe((function(e){t.iosTemplates=e.filter((function(t){return"dynamips"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.prototype.copyTemplate=function(t){this.router.navigate(["/server",this.server.id,"preferences","dynamips","templates",t.template_id,"copy"])},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(got),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-ios-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"IOS router templates"),va(),ua(5,imt,2,1,"button",4),ua(6,rmt,2,1,"button",5),va(),va(),ua(7,omt,1,0,"app-empty-templates-list",6),ua(8,cmt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.iosTemplates.length),Qi(1),pa("ngIf",e.iosTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),umt=function(){function t(t){this.electronService=t}return t.prototype.isWindows=function(){return"win32"===this.electronService.process.platform},t.prototype.isLinux=function(){return"linux"===this.electronService.process.platform},t.prototype.isDarwin=function(){return"darwin"===this.electronService.process.platform},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(mX))}}),t}(),hmt=function(){function t(t){this.platformService=t}return t.prototype.get=function(){return this.platformService.isWindows()?this.getForWindows():this.platformService.isDarwin()?this.getForDarwin():this.getForLinux()},t.prototype.getForWindows=function(){return[{name:"Wireshark",locations:["C:\\Program Files\\Wireshark\\Wireshark.exe"],type:"web",resource:"https://1.na.dl.wireshark.org/win64/all-versions/Wireshark-win64-2.6.3.exe",binary:"Wireshark.exe",sudo:!0,installation_arguments:[],installed:!1,installer:!0}]},t.prototype.getForLinux=function(){return[]},t.prototype.getForDarwin=function(){return[]},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(umt))}}),t}(),dmt=function(){function t(t,e){this.electronService=t,this.externalSoftwareDefinition=e}return t.prototype.list=function(){var t=this.externalSoftwareDefinition.get(),e=this.electronService.remote.require("./installed-software.js").getInstalledSoftware(t);return t.map((function(t){return t.installed=e[t.name].length>0,t}))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(mX),_t(hmt))}}),t}(),fmt=["ad"],pmt=function(){function t(t){this.httpClient=t,this.onLoad=new Uc,this.staticCode='<a href="https://try.solarwinds.com/gns3-free-toolset-giveaway?CMP=LEC-HAD-GNS3-SW_NA_X_NP_X_X_EN_STSGA_SW-ST-20200901_ST_OF1_TRY-NWSLTR">\n Access Our Favorite Network Free Tools!\n </a><br/>\n Access 20+ network performance management, monitoring, and troubleshooting tools for FREE ($200 Value).<br/>\n <button>\n <a target="_blank" href="https://try.solarwinds.com/gns3-free-toolset-giveaway?CMP=LEC-HAD-GNS3-SW_NA_X_NP_X_X_EN_STSGA_SW-ST-20200901_ST_OF1_TRY-NWSLTR">\n Check it out!\n </a>\n </button>'}return t.prototype.ngOnInit=function(){var t=this;this.httpClient.get("https://servedbyadbutler.com/adserve/;ID=165803;size=0x0;setID=371476;type=json;").subscribe((function(e){e&&e.placements&&e.placements.placement_1&&e.placements.placement_1.body?(t.onLoad.emit(!0),t.htmlCode=e.placements.placement_1.body,t.ad.nativeElement.insertAdjacentHTML("beforeend",t.htmlCode)):(t.onLoad.emit(!0),t.htmlCode=t.staticCode)}),(function(t){}))},t.\u0275fac=function(e){return new(e||t)(da(Rg))},t.\u0275cmp=Ht({type:t,selectors:[["app-adbutler"]],viewQuery:function(t,e){var n;1&t&&nl(fmt,!0),2&t&&tl(n=sl())&&(e.ad=n.first)},decls:2,vars:0,consts:[[1,"ad"],["ad",""]],template:function(t,e){1&t&&ba(0,"div",0,1)},styles:[".ad{background-color:transparent;width:400px;padding-top:10px;padding-bottom:10px;font-size:12px}button{background-color:#0097a7;margin-top:2px;border:none;outline:none;color:#fff;font-weight:700;padding:5px 15px;border-radius:4px}a{color:#0097a7}button a{color:#fff}"],encapsulation:2}),t}();function mmt(t,e){if(1&t&&(ya(0),ds(1),_a()),2&t){var n=Aa();Qi(1),fs(n.buttonText)}}var gmt=function(){function t(t){this.electronService=t,this.installedChanged=new Uc,this.disabled=!1,this.readyToInstall=!0}return t.prototype.ngOnInit=function(){var t=this;this.electronService.ipcRenderer.on(this.responseChannel,(function(e,n){t.updateButton(),t.installedChanged.emit(n)}))},t.prototype.ngOnDestroy=function(){this.electronService.ipcRenderer.removeAllListeners(this.responseChannel)},t.prototype.ngOnChanges=function(){this.updateButton()},t.prototype.install=function(){this.disabled=!0,this.buttonText="Installing",this.electronService.ipcRenderer.send("installed-software-install",this.software)},Object.defineProperty(t.prototype,"responseChannel",{get:function(){return"installed-software-installed-"+this.software.name},enumerable:!1,configurable:!0}),t.prototype.updateButton=function(){this.disabled=this.software.installed,this.buttonText=this.software.installed?"Installed":"Install"},t.\u0275fac=function(e){return new(e||t)(da(mX))},t.\u0275cmp=Ht({type:t,selectors:[["app-install-software"]],inputs:{software:"software"},outputs:{installedChanged:"installedChanged"},features:[Ms],decls:2,vars:2,consts:[["mat-button","","color","primary",3,"disabled","click"],[4,"ngIf"]],template:function(t,e){1&t&&(ga(0,"button",0),xa("click",(function(){return e.install()})),ua(1,mmt,2,1,"ng-container",1),va()),2&t&&(pa("disabled",e.disabled),Qi(1),pa("ngIf",e.readyToInstall))},directives:[a2,Ah],styles:[""]}),t}();function vmt(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Name "),va())}function bmt(t,e){if(1&t&&(ya(0),ds(1),_a()),2&t){var n=Aa().$implicit;Qi(1),ps(" ",n.name," ")}}function ymt(t,e){1&t&&(ya(0),ba(1,"app-adbutler",14),_a())}function _mt(t,e){if(1&t&&(ga(0,"mat-cell"),ua(1,bmt,2,1,"ng-container",13),ua(2,ymt,2,0,"ng-container",13),va()),2&t){var n=e.$implicit;Qi(1),pa("ngIf","adbutler"!==n.type),Qi(1),pa("ngIf","adbutler"===n.type)}}function wmt(t,e){1&t&&ba(0,"mat-header-cell")}function kmt(t,e){if(1&t){var n=ka();ga(0,"app-install-software",17),xa("installedChanged",(function(t){return Se(n),Aa(2).onInstalled(t)})),va()}2&t&&pa("software",Aa().$implicit)}function Cmt(t,e){if(1&t&&(ga(0,"mat-cell",15),ua(1,kmt,1,1,"app-install-software",16),va()),2&t){var n=e.$implicit;Qi(1),pa("ngIf","adbutler"!==n.type)}}function Smt(t,e){1&t&&ba(0,"mat-header-row")}function xmt(t,e){1&t&&ba(0,"mat-row")}var Omt=function(){function t(t,e){this.installedSoftwareService=t,this.changeDetectorRef=e,this.displayedColumns=["name","actions"]}return t.prototype.ngOnInit=function(){this.dataSource=new Mmt(this.installedSoftwareService)},t.prototype.onInstalled=function(t){this.dataSource.refresh(),this.changeDetectorRef.detectChanges()},t.\u0275fac=function(e){return new(e||t)(da(dmt),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["app-installed-software"]],decls:16,vars:3,consts:[[1,"content"],[1,"default-header"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"dataSource"],["table",""],["matColumnDef","name"],[4,"matHeaderCellDef"],[4,"matCellDef"],["matColumnDef","actions"],["style","text-align: right",4,"matCellDef"],[4,"matHeaderRowDef"],[4,"matRowDef","matRowDefColumns"],[4,"ngIf"],["theme","dark"],[2,"text-align","right"],[3,"software","installedChanged",4,"ngIf"],[3,"software","installedChanged"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"h1"),ds(3,"Installed software"),va(),va(),ga(4,"div",2),ga(5,"div",3),ga(6,"mat-table",4,5),ya(8,6),ua(9,vmt,2,0,"mat-header-cell",7),ua(10,_mt,3,2,"mat-cell",8),_a(),ya(11,9),ua(12,wmt,1,0,"mat-header-cell",7),ua(13,Cmt,2,1,"mat-cell",10),_a(),ua(14,Smt,1,0,"mat-header-row",11),ua(15,xmt,1,0,"mat-row",12),va(),va(),va(),va()),2&t&&(Qi(6),pa("dataSource",e.dataSource),Qi(8),pa("matHeaderRowDef",e.displayedColumns),Qi(1),pa("matRowDefColumns",e.displayedColumns))},directives:[$5,n4,t4,J5,a4,c4,i4,o4,Ah,pmt,gmt,l4,h4],styles:[""]}),t}(),Mmt=function(t){function e(e){var n=t.call(this)||this;return n.installedSoftwareService=e,n.installed=new Pm.a([]),n}return zQ(e,t),e.prototype.connect=function(){return this.refresh(),this.installed},e.prototype.disconnect=function(){},e.prototype.refresh=function(){var t=this.installedSoftwareService.list();t.push({type:"adbutler"}),this.installed.next(t)},e}(um);function Tmt(t,e){if(1&t&&(ga(0,"mat-option",38),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Emt(t,e){if(1&t&&(ga(0,"mat-option",38),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Pmt(t,e){if(1&t&&(ga(0,"mat-option",38),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var Amt=function(){return{standalone:!0}};function jmt(t,e){if(1&t){var n=ka();ga(0,"mat-select",41),xa("ngModelChange",(function(t){Se(n);var e=Aa().$implicit;return Aa(3).networkAdaptersForTemplate[e]=t})),ua(1,Pmt,2,2,"mat-option",14),va()}if(2&t){var i=Aa().$implicit,r=Aa(3);La("placeholder","Slot ",i,""),pa("ngModel",r.networkAdaptersForTemplate[i])("ngModelOptions",jc(4,Amt)),Qi(1),pa("ngForOf",r.networkAdapters[r.iosTemplate.chassis][i])}}function Imt(t,e){if(1&t&&(ga(0,"div"),ua(1,jmt,2,5,"mat-select",40),va()),2&t){var n=e.$implicit,i=Aa(3);Qi(1),pa("ngIf",i.networkAdapters[i.iosTemplate.chassis][n])}}var Dmt=function(){return[0,1,2,3,4,5,6,7]};function Rmt(t,e){1&t&&(ga(0,"div"),ua(1,Imt,2,1,"div",39),va()),2&t&&(Qi(1),pa("ngForOf",jc(1,Dmt)))}function Lmt(t,e){if(1&t&&(ga(0,"mat-option",38),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Fmt(t,e){if(1&t){var n=ka();ga(0,"mat-select",41),xa("ngModelChange",(function(t){Se(n);var e=Aa().$implicit;return Aa(3).networkAdaptersForTemplate[e]=t})),ua(1,Lmt,2,2,"mat-option",14),va()}if(2&t){var i=Aa().$implicit,r=Aa(3);La("placeholder","Slot ",i,""),pa("ngModel",r.networkAdaptersForTemplate[i])("ngModelOptions",jc(4,Amt)),Qi(1),pa("ngForOf",r.networkAdaptersForPlatform[r.iosTemplate.platform][i])}}function Nmt(t,e){if(1&t&&(ga(0,"div"),ua(1,Fmt,2,5,"mat-select",40),va()),2&t){var n=e.$implicit,i=Aa(3);Qi(1),pa("ngIf",i.networkAdaptersForPlatform[i.iosTemplate.platform][n])}}function Bmt(t,e){1&t&&(ga(0,"div"),ua(1,Nmt,2,1,"div",39),va()),2&t&&(Qi(1),pa("ngForOf",jc(1,Dmt)))}function Hmt(t,e){if(1&t&&(ga(0,"mat-option",38),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function zmt(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"mat-select",42),xa("ngModelChange",(function(t){return Se(n),Aa(2).iosTemplate.wic0=t})),ua(2,Hmt,2,2,"mat-option",14),va(),va()}if(2&t){var i=Aa(2);Qi(1),pa("ngModel",i.iosTemplate.wic0)("ngModelOptions",jc(3,Amt)),Qi(1),pa("ngForOf",i.networkModules[i.iosTemplate.platform][0])}}function Vmt(t,e){if(1&t&&(ga(0,"mat-option",38),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Umt(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"mat-select",43),xa("ngModelChange",(function(t){return Se(n),Aa(2).iosTemplate.wic1=t})),ua(2,Vmt,2,2,"mat-option",14),va(),va()}if(2&t){var i=Aa(2);Qi(1),pa("ngModel",i.iosTemplate.wic1)("ngModelOptions",jc(3,Amt)),Qi(1),pa("ngForOf",i.networkModules[i.iosTemplate.platform][1])}}function qmt(t,e){if(1&t&&(ga(0,"mat-option",38),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Gmt(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"mat-select",44),xa("ngModelChange",(function(t){return Se(n),Aa(2).iosTemplate.wic2=t})),ua(2,qmt,2,2,"mat-option",14),va(),va()}if(2&t){var i=Aa(2);Qi(1),pa("ngModel",i.iosTemplate.wic2)("ngModelOptions",jc(3,Amt)),Qi(1),pa("ngForOf",i.networkModules[i.iosTemplate.platform][2])}}function Wmt(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"mat-accordion"),ga(2,"mat-expansion-panel"),ga(3,"mat-expansion-panel-header"),ga(4,"mat-panel-title"),ds(5," General settings "),va(),va(),ga(6,"form",7),ga(7,"mat-form-field",8),ga(8,"input",9),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.name=t})),va(),va(),ga(9,"mat-form-field",8),ga(10,"input",10),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.default_name_format=t})),va(),va(),ga(11,"mat-label"),ds(12),va(),ba(13,"br"),ba(14,"br"),ga(15,"mat-label"),ds(16),va(),ba(17,"br"),ba(18,"br"),ga(19,"mat-form-field",8),ga(20,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.symbol=t})),va(),va(),ga(21,"button",12),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(22,"Choose symbol"),va(),ba(23,"br"),ba(24,"br"),ga(25,"mat-form-field",8),ga(26,"mat-select",13),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.category=t})),ua(27,Tmt,2,2,"mat-option",14),va(),va(),ga(28,"mat-form-field",8),ga(29,"input",15),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.image=t})),va(),va(),ga(30,"mat-form-field",8),ga(31,"input",16),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.startup_config=t})),va(),va(),ga(32,"mat-form-field",8),ga(33,"input",17),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.private_config=t})),va(),va(),va(),ga(34,"mat-form-field",18),ga(35,"mat-select",19),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.console_type=t})),ua(36,Emt,2,2,"mat-option",14),va(),va(),ga(37,"mat-checkbox",20),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.console_auto_start=t})),ds(38," Auto start console "),va(),va(),ga(39,"mat-expansion-panel"),ga(40,"mat-expansion-panel-header"),ga(41,"mat-panel-title"),ds(42," Memories and disks "),va(),va(),ga(43,"form",7),ga(44,"mat-form-field",8),ga(45,"input",21),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.ram=t})),va(),ga(46,"span",22),ds(47,"MB"),va(),va(),ga(48,"mat-form-field",8),ga(49,"input",23),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.nvram=t})),va(),ga(50,"span",22),ds(51,"MB"),va(),va(),ga(52,"mat-form-field",8),ga(53,"input",24),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.iomem=t})),va(),va(),ga(54,"mat-form-field",8),ga(55,"input",25),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.disk0=t})),va(),va(),ga(56,"mat-form-field",8),ga(57,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.disk1=t})),va(),va(),va(),ga(58,"mat-checkbox",20),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.auto_delete_disks=t})),ds(59," Automatically delete NVRAM and disk files "),va(),va(),ga(60,"mat-expansion-panel"),ga(61,"mat-expansion-panel-header"),ga(62,"mat-panel-title"),ds(63," Slots "),va(),va(),ga(64,"h6"),ds(65,"Adapters"),va(),ua(66,Rmt,2,2,"div",27),ua(67,Bmt,2,2,"div",27),ba(68,"br"),ba(69,"br"),ga(70,"h6"),ds(71,"WICs"),va(),ua(72,zmt,3,4,"div",27),ua(73,Umt,3,4,"div",27),ua(74,Gmt,3,4,"div",27),va(),ga(75,"mat-expansion-panel"),ga(76,"mat-expansion-panel-header"),ga(77,"mat-panel-title"),ds(78," Advanced "),va(),va(),ga(79,"form",7),ga(80,"mat-form-field",8),ga(81,"input",28),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.system_id=t})),va(),va(),ga(82,"mat-form-field",8),ga(83,"input",29),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.mac_addr=t})),va(),va(),ga(84,"mat-form-field",8),ga(85,"input",30),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.idlepc=t})),va(),va(),ga(86,"mat-form-field",8),ga(87,"input",31),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.idlemax=t})),va(),va(),ga(88,"mat-form-field",8),ga(89,"input",32),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.idlesleep=t})),va(),va(),ga(90,"mat-form-field",8),ga(91,"input",33),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.exec_area=t})),va(),va(),va(),ga(92,"mat-checkbox",20),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.mmap=t})),ds(93," Enable mmap support "),va(),ba(94,"br"),ba(95,"br"),ga(96,"mat-checkbox",20),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.sparsemem=t})),ds(97," Enable sparse memory supoport "),va(),va(),ga(98,"mat-expansion-panel"),ga(99,"mat-expansion-panel-header"),ga(100,"mat-panel-title"),ds(101," Usage "),va(),va(),ga(102,"mat-form-field",8),ga(103,"textarea",34),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.usage=t})),va(),va(),va(),va(),ga(104,"div",35),ga(105,"button",36),xa("click",(function(){return Se(n),Aa().goBack()})),ds(106,"Cancel"),va(),ga(107,"button",37),xa("click",(function(){return Se(n),Aa().onSave()})),ds(108,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(6),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.iosTemplate.name),Qi(2),pa("ngModel",i.iosTemplate.default_name_format),Qi(2),ps("Platform - ",i.iosTemplate.platform,""),Qi(4),ps("Chassis - ",i.iosTemplate.chassis,""),Qi(4),pa("ngModel",i.iosTemplate.symbol),Qi(6),pa("ngModelOptions",jc(40,Amt))("ngModel",i.iosTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModel",i.iosTemplate.image),Qi(2),pa("ngModel",i.iosTemplate.startup_config),Qi(2),pa("ngModelOptions",jc(41,Amt))("ngModel",i.iosTemplate.private_config),Qi(2),pa("ngModel",i.iosTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModel",i.iosTemplate.console_auto_start),Qi(6),pa("formGroup",i.memoryForm),Qi(2),pa("ngModel",i.iosTemplate.ram),Qi(4),pa("ngModel",i.iosTemplate.nvram),Qi(4),pa("ngModel",i.iosTemplate.iomem),Qi(2),pa("ngModel",i.iosTemplate.disk0),Qi(2),pa("ngModel",i.iosTemplate.disk1),Qi(1),pa("ngModel",i.iosTemplate.auto_delete_disks),Qi(8),pa("ngIf",i.iosTemplate.chassis&&i.chassis[i.iosTemplate.platform]),Qi(1),pa("ngIf",i.iosTemplate.platform&&!i.chassis[i.iosTemplate.platform]),Qi(5),pa("ngIf",i.iosTemplate.wic0||""===i.iosTemplate.wic0),Qi(1),pa("ngIf",i.iosTemplate.wic1||""===i.iosTemplate.wic1),Qi(1),pa("ngIf",i.iosTemplate.wic2||""===i.iosTemplate.wic2),Qi(5),pa("formGroup",i.advancedForm),Qi(2),pa("ngModel",i.iosTemplate.system_id),Qi(2),pa("ngModelOptions",jc(42,Amt))("ngModel",i.iosTemplate.mac_addr),Qi(2),pa("ngModelOptions",jc(43,Amt))("ngModel",i.iosTemplate.idlepc),Qi(2),pa("ngModel",i.iosTemplate.idlemax),Qi(2),pa("ngModel",i.iosTemplate.idlesleep),Qi(2),pa("ngModel",i.iosTemplate.exec_area),Qi(1),pa("ngModel",i.iosTemplate.mmap),Qi(4),pa("ngModel",i.iosTemplate.sparsemem),Qi(7),pa("ngModel",i.iosTemplate.usage)}}function Kmt(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",45),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.iosTemplate.symbol)}}var Xmt=function(t){return{shadowed:t}},Ymt=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.iosService=n,this.toasterService=i,this.formBuilder=r,this.iosConfigurationService=o,this.router=a,this.isSymbolSelectionOpened=!1,this.networkAdaptersForTemplate=[],this.platforms=[],this.consoleTypes=[],this.platformsWithEtherSwitchRouterOption={},this.platformsWithChassis={},this.chassis={},this.defaultRam={},this.defaultNvram={},this.networkAdapters={},this.networkAdaptersForPlatform={},this.networkModules={},this.generalSettingsForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),symbol:new hp("",kf.required),path:new hp("",kf.required),initialConfig:new hp("",kf.required)}),this.memoryForm=this.formBuilder.group({ram:new hp("",kf.required),nvram:new hp("",kf.required),iomemory:new hp("",kf.required),disk0:new hp("",kf.required),disk1:new hp("",kf.required)}),this.advancedForm=this.formBuilder.group({systemId:new hp("",kf.required),idlemax:new hp("",kf.required),idlesleep:new hp("",kf.required),execarea:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.iosService.getTemplate(t.server,n).subscribe((function(e){t.iosTemplate=e,t.fillAdaptersData()}))}))},t.prototype.getConfiguration=function(){this.networkModules=this.iosConfigurationService.getNetworkModules(),this.networkAdaptersForPlatform=this.iosConfigurationService.getNetworkAdaptersForPlatform(),this.networkAdapters=this.iosConfigurationService.getNetworkAdapters(),this.platforms=this.iosConfigurationService.getAvailablePlatforms(),this.platformsWithEtherSwitchRouterOption=this.iosConfigurationService.getPlatformsWithEtherSwitchRouterOption(),this.platformsWithChassis=this.iosConfigurationService.getPlatformsWithChassis(),this.chassis=this.iosConfigurationService.getChassis(),this.defaultRam=this.iosConfigurationService.getDefaultRamSettings(),this.consoleTypes=this.iosConfigurationService.getConsoleTypes()},t.prototype.fillAdaptersData=function(){this.iosTemplate.slot0&&(this.networkAdaptersForTemplate[0]=this.iosTemplate.slot0),this.iosTemplate.slot1&&(this.networkAdaptersForTemplate[1]=this.iosTemplate.slot1),this.iosTemplate.slot2&&(this.networkAdaptersForTemplate[2]=this.iosTemplate.slot2),this.iosTemplate.slot3&&(this.networkAdaptersForTemplate[3]=this.iosTemplate.slot3),this.iosTemplate.slot4&&(this.networkAdaptersForTemplate[4]=this.iosTemplate.slot4),this.iosTemplate.slot5&&(this.networkAdaptersForTemplate[5]=this.iosTemplate.slot5),this.iosTemplate.slot6&&(this.networkAdaptersForTemplate[6]=this.iosTemplate.slot6),this.iosTemplate.slot7&&(this.networkAdaptersForTemplate[7]=this.iosTemplate.slot7)},t.prototype.completeAdaptersData=function(){this.networkAdaptersForTemplate[0]&&(this.iosTemplate.slot0=this.networkAdaptersForTemplate[0]),this.networkAdaptersForTemplate[1]&&(this.iosTemplate.slot1=this.networkAdaptersForTemplate[1]),this.networkAdaptersForTemplate[2]&&(this.iosTemplate.slot2=this.networkAdaptersForTemplate[2]),this.networkAdaptersForTemplate[3]&&(this.iosTemplate.slot3=this.networkAdaptersForTemplate[3]),this.networkAdaptersForTemplate[4]&&(this.iosTemplate.slot4=this.networkAdaptersForTemplate[4]),this.networkAdaptersForTemplate[5]&&(this.iosTemplate.slot5=this.networkAdaptersForTemplate[5]),this.networkAdaptersForTemplate[6]&&(this.iosTemplate.slot6=this.networkAdaptersForTemplate[6]),this.networkAdaptersForTemplate[7]&&(this.iosTemplate.slot7=this.networkAdaptersForTemplate[7])},t.prototype.onSave=function(){var t=this;this.generalSettingsForm.invalid||this.memoryForm.invalid||this.advancedForm.invalid?this.toasterService.error("Fill all required fields"):(this.completeAdaptersData(),this.iosService.saveTemplate(this.server,this.iosTemplate).subscribe((function(e){t.toasterService.success("Changes saved")})))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","dynamips","templates"])},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.iosTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(got),da(Y2),da(Jp),da(J7),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-ios-template-details"]],decls:7,vars:5,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","defaultName","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","symbol","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["matInput","","type","text","formControlName","path","placeholder","IOS image path",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","initialConfig","placeholder","Initial startup-config",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Initial private-config",3,"ngModelOptions","ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModel","ngModelChange"],[3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","ram","placeholder","RAM size",3,"ngModel","ngModelChange"],["matSuffix",""],["matInput","","type","number","formControlName","nvram","placeholder","NVRAM size",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","iomemory","placeholder","I/O memory",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","disk0","placeholder","PCMCIA disk0",3,"ngModel","ngModelChange"],["matInput","","type","number","formControlName","disk1","placeholder","PCMCIA disk1",3,"ngModel","ngModelChange"],[4,"ngIf"],["matInput","","formControlName","systemId","type","text","placeholder","System ID",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Base MAC",3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","type","text","placeholder","Idle-PC",3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","formControlName","idlemax","type","number","placeholder","Idlemax",3,"ngModel","ngModelChange"],["matInput","","formControlName","idlesleep","type","number","placeholder","Idlesleep",3,"ngModel","ngModelChange"],["matInput","","formControlName","execarea","type","number","placeholder","Exec area",3,"ngModel","ngModelChange"],["matInput","","type","text",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],[4,"ngFor","ngForOf"],[3,"placeholder","ngModel","ngModelOptions","ngModelChange",4,"ngIf"],[3,"placeholder","ngModel","ngModelOptions","ngModelChange"],["placeholder","WIC 0",3,"ngModel","ngModelOptions","ngModelChange"],["placeholder","WIC 1",3,"ngModel","ngModelOptions","ngModelChange"],["placeholder","WIC 2",3,"ngModel","ngModelOptions","ngModelChange"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Dynamips IOS Router configuration"),va(),va(),va(),ua(5,Wmt,109,44,"div",4),va(),ua(6,Kmt,1,2,"app-symbols-menu",5)),2&t&&(pa("ngClass",Ic(3,Xmt,e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.iosTemplate),Qi(1),pa("ngIf",e.isSymbolSelectionOpened&&e.iosTemplate))},directives:[Oh,Ah,Sdt,ydt,wdt,Cdt,xp,gf,Pp,Y3,s5,cf,mf,Fp,z3,a2,O5,Sp,Eh,F5,Ef,q3,EJ,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function Zmt(t,e){if(1&t&&(ga(0,"mat-option",36),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.filename),Qi(1),ps(" ",n.filename," ")}}function Qmt(t,e){if(1&t&&(ga(0,"mat-option",36),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function $mt(t,e){if(1&t&&(ga(0,"mat-option",36),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Jmt(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",17),ga(1,"mat-select",37),xa("selectionChange",(function(t){return Se(n),Aa(2).onChassisChosen(t)})),ua(2,$mt,2,2,"mat-option",19),va(),va()}if(2&t){var i=Aa(2);Qi(2),pa("ngForOf",i.chassis[i.iosNameForm.get("platform").value])}}function tgt(t,e){if(1&t){var n=ka();ga(0,"mat-checkbox",38),xa("ngModelChange",(function(t){return Se(n),Aa(2).isEtherSwitchRouter=t})),ds(1," This is an EtherSwitch router "),va()}2&t&&pa("ngModel",Aa(2).isEtherSwitchRouter)}function egt(t,e){if(1&t&&(ga(0,"mat-option",36),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var ngt=function(){return{standalone:!0}};function igt(t,e){if(1&t){var n=ka();ga(0,"mat-select",41),xa("ngModelChange",(function(t){Se(n);var e=Aa().$implicit;return Aa(3).networkAdaptersForTemplate[e]=t})),ua(1,egt,2,2,"mat-option",19),va()}if(2&t){var i=Aa().$implicit,r=Aa(3);La("placeholder","Slot ",i,""),pa("ngModel",r.networkAdaptersForTemplate[i])("ngModelOptions",jc(4,ngt)),Qi(1),pa("ngForOf",r.networkAdaptersForPlatform[r.iosNameForm.get("platform").value][i])}}function rgt(t,e){if(1&t&&(ga(0,"div"),ua(1,igt,2,5,"mat-select",40),va()),2&t){var n=e.$implicit,i=Aa(3);Qi(1),pa("ngIf",i.networkAdaptersForPlatform[i.iosNameForm.get("platform").value]&&i.networkAdaptersForPlatform[i.iosNameForm.get("platform").value][n])}}var ogt=function(){return[0,1,2,3,4,5,6,7]};function agt(t,e){1&t&&(ga(0,"div"),ua(1,rgt,2,1,"div",39),va()),2&t&&(Qi(1),pa("ngForOf",jc(1,ogt)))}function sgt(t,e){if(1&t&&(ga(0,"mat-option",36),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function cgt(t,e){if(1&t){var n=ka();ga(0,"mat-select",41),xa("ngModelChange",(function(t){Se(n);var e=Aa().$implicit;return Aa(3).networkModulesForTemplate[e]=t})),ua(1,sgt,2,2,"mat-option",19),va()}if(2&t){var i=Aa().$implicit,r=Aa(3);La("placeholder","WIC ",i,""),pa("ngModel",r.networkModulesForTemplate[i])("ngModelOptions",jc(4,ngt)),Qi(1),pa("ngForOf",r.networkModules[r.iosNameForm.get("platform").value][i])}}function lgt(t,e){if(1&t&&(ga(0,"div"),ua(1,cgt,2,5,"mat-select",40),va()),2&t){var n=e.$implicit,i=Aa(3);Qi(1),pa("ngIf",i.networkModules[i.iosNameForm.get("platform").value]&&i.networkModules[i.iosNameForm.get("platform").value][n])}}var ugt=function(){return[0,1,2,3]};function hgt(t,e){1&t&&(ga(0,"div"),ua(1,lgt,2,1,"div",39),va()),2&t&&(Qi(1),pa("ngForOf",jc(1,ugt)))}function dgt(t,e){if(1&t){var n=ka();ga(0,"div",5),ga(1,"div",6),ga(2,"mat-vertical-stepper",7),ga(3,"mat-step",8),ga(4,"mat-radio-group",9),ga(5,"mat-radio-button",10),xa("click",(function(){return Se(n),Aa().setServerType("local")})),ds(6,"Run this IOS router locally"),va(),ga(7,"mat-radio-button",11),xa("click",(function(){return Se(n),Aa().setServerType("gns3 vm")})),ds(8,"Run this IOS router on the GNS3 VM"),va(),va(),va(),ga(9,"mat-step",12),ga(10,"input",13,14),xa("change",(function(t){return Se(n),Aa().addImage(t)})),va(),ga(12,"button",15),xa("click",(function(){return Se(n),ha(11).click()})),ds(13,"Click to add image"),va(),ds(14," or create from existing one "),ga(15,"form",16),ga(16,"mat-form-field",17),ga(17,"mat-select",18),xa("selectionChange",(function(t){return Se(n),Aa().onImageChosen(t)})),ua(18,Zmt,2,2,"mat-option",19),va(),va(),va(),va(),ga(19,"mat-step",20),ga(20,"form",16),ga(21,"mat-form-field",17),ba(22,"input",21),va(),ga(23,"mat-form-field",17),ga(24,"mat-select",22),xa("selectionChange",(function(t){return Se(n),Aa().onPlatformChosen(t)})),ua(25,Qmt,2,2,"mat-option",19),va(),va(),ua(26,Jmt,3,1,"mat-form-field",23),va(),ua(27,tgt,2,1,"mat-checkbox",24),va(),ga(28,"mat-step",25),ga(29,"form",16),ga(30,"mat-form-field",17),ba(31,"input",26),ga(32,"span",27),ds(33,"MB"),va(),va(),ga(34,"mat-label"),ga(35,"a",28),ds(36,"Check for minimum and maximum RAM requirement"),va(),va(),va(),va(),ga(37,"mat-step",29),ua(38,agt,2,2,"div",30),va(),ga(39,"mat-step",31),ua(40,hgt,2,2,"div",30),va(),ga(41,"mat-step",32),ga(42,"mat-form-field",17),ga(43,"input",33),xa("ngModelChange",(function(t){return Se(n),Aa().iosTemplate.idlepc=t})),va(),va(),va(),va(),va(),ga(44,"div",34),ga(45,"button",35),xa("click",(function(){return Se(n),Aa().goBack()})),ds(46,"Cancel"),va(),ga(47,"button",15),xa("click",(function(){return Se(n),Aa().addTemplate()})),ds(48,"Add template"),va(),va(),va()}if(2&t){var i=Aa();Qi(2),pa("linear",!0),Qi(1),pa("completed",i.isGns3VmChosen||i.isLocalComputerChosen),Qi(4),pa("disabled",!i.isGns3VmAvailable),Qi(2),pa("completed",i.iosImageForm.get("imageName").value),Qi(1),pa("uploader",i.uploader),Qi(5),pa("formGroup",i.iosImageForm),Qi(3),pa("ngForOf",i.iosImages),Qi(1),pa("completed",i.iosNameForm.get("templateName").value&&i.iosNameForm.get("platform").value&&i.iosNameForm.get("chassis").value),Qi(1),pa("formGroup",i.iosNameForm),Qi(5),pa("ngForOf",i.platforms),Qi(1),pa("ngIf",i.chassis[i.iosNameForm.get("platform").value]),Qi(1),pa("ngIf",i.platformsWithEtherSwitchRouterOption[i.iosTemplate.platform]),Qi(1),pa("completed",i.iosMemoryForm.get("memory").value),Qi(1),pa("formGroup",i.iosMemoryForm),Qi(6),Ra("href",i.ciscoUrl,Pi),Qi(3),pa("ngIf",i.selectedPlatform),Qi(2),pa("ngIf",i.iosNameForm.get("platform").value),Qi(3),pa("ngModel",i.iosTemplate.idlepc)}}var fgt=function(){function t(t,e,n,i,r,o,a,s,c){this.route=t,this.serverService=e,this.iosService=n,this.toasterService=i,this.formBuilder=r,this.router=o,this.templateMocksService=a,this.iosConfigurationService=s,this.computeService=c,this.isEtherSwitchRouter=!1,this.networkAdaptersForTemplate=[],this.networkModulesForTemplate=[],this.iosImages=[],this.platforms=[],this.platformsWithEtherSwitchRouterOption={},this.platformsWithChassis={},this.chassis={},this.defaultRam={},this.defaultNvram={},this.networkAdapters={},this.networkAdaptersForPlatform={},this.networkModules={},this.ciscoUrl="https://cfn.cloudapps.cisco.com/ITDIT/CFN/jsp/SearchBySoftware.jsp",this.isGns3VmAvailable=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0,this.iosTemplate=new mot,this.iosImageForm=this.formBuilder.group({imageName:new hp(null,[kf.required])}),this.iosNameForm=this.formBuilder.group({templateName:new hp(null,[kf.required]),platform:new hp(null,[kf.required]),chassis:new hp(null,[kf.required])}),this.iosMemoryForm=this.formBuilder.group({memory:new hp(null,[kf.required])})}return t.prototype.ngOnInit=function(){var t=this;this.uploader=new wX({}),this.uploader.onAfterAddingFile=function(t){t.withCredentials=!1},this.uploader.onErrorItem=function(e,n,i,r){t.toasterService.error("An error occured: "+n)},this.uploader.onSuccessItem=function(e,n,i,r){t.getImages(),t.toasterService.success("Image uploaded")};var e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getImages(),t.templateMocksService.getIosTemplate().subscribe((function(e){t.iosTemplate=e,t.networkModules=t.iosConfigurationService.getNetworkModules(),t.networkAdaptersForPlatform=t.iosConfigurationService.getNetworkAdaptersForPlatform(),t.networkAdapters=t.iosConfigurationService.getNetworkAdapters(),t.platforms=t.iosConfigurationService.getAvailablePlatforms(),t.platformsWithEtherSwitchRouterOption=t.iosConfigurationService.getPlatformsWithEtherSwitchRouterOption(),t.platformsWithChassis=t.iosConfigurationService.getPlatformsWithChassis(),t.chassis=t.iosConfigurationService.getChassis(),t.defaultRam=t.iosConfigurationService.getDefaultRamSettings()})),t.computeService.getComputes(e).subscribe((function(e){e.filter((function(t){return"vm"===t.compute_id})).length>0&&(t.isGns3VmAvailable=!0)}))}))},t.prototype.setServerType=function(t){"gns3 vm"===t&&this.isGns3VmAvailable?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.getImages=function(){var t=this;this.iosService.getImages(this.server).subscribe((function(e){t.iosImages=e}))},t.prototype.addImage=function(t){var e=t.target.files[0].name.split("-")[0];this.iosNameForm.controls.templateName.setValue(e);var n=this.iosService.getImagePath(this.server,t.target.files[0].name);this.uploader.queue.forEach((function(t){return t.url=n}));var i=this.uploader.queue[0];i.options.disableMultipart=!0,this.uploader.uploadItem(i)},t.prototype.addTemplate=function(){var t=this;!this.iosImageForm.invalid&&!this.iosMemoryForm.invalid&&this.iosNameForm.get("templateName").value&&this.iosNameForm.get("platform").value?(this.iosTemplate.template_id=Object(art.v4)(),this.iosTemplate.image=this.iosImageForm.get("imageName").value,this.iosTemplate.name=this.iosNameForm.get("templateName").value,this.iosTemplate.platform=this.iosNameForm.get("platform").value,this.chassis[this.iosNameForm.get("platform").value]&&(this.iosTemplate.chassis=this.iosNameForm.get("chassis").value),this.iosTemplate.ram=this.iosMemoryForm.get("memory").value,this.isEtherSwitchRouter&&(this.iosTemplate.symbol=":/symbols/multilayer_switch.svg",this.iosTemplate.category="switch"),this.networkAdaptersForTemplate.length>0&&this.completeAdaptersData(),this.networkModulesForTemplate.length>0&&this.completeModulesData(),this.iosTemplate.compute_id=this.isGns3VmChosen?"vm":"local",this.iosService.addTemplate(this.server,this.iosTemplate).subscribe((function(e){t.goBack()}))):this.toasterService.error("Fill all required fields")},t.prototype.completeAdaptersData=function(){if(this.chassis[this.iosTemplate.platform]){if(Object.keys(this.networkAdapters[this.iosTemplate.chassis]))for(var t=0;t<Object.keys(this.networkAdapters[this.iosTemplate.chassis]).length;t++)this.networkAdaptersForTemplate[t]||(this.networkAdaptersForTemplate[t]="")}else if(this.networkAdaptersForPlatform[this.iosNameForm.get("platform").value])for(t=0;t<Object.keys(this.networkAdaptersForPlatform[this.iosNameForm.get("platform").value]).length;t++)this.networkAdaptersForTemplate[t]||(this.networkAdaptersForTemplate[t]="");this.networkAdaptersForTemplate[0]&&(this.iosTemplate.slot0=this.networkAdaptersForTemplate[0]),this.networkAdaptersForTemplate[1]&&(this.iosTemplate.slot1=this.networkAdaptersForTemplate[1]),this.networkAdaptersForTemplate[2]&&(this.iosTemplate.slot2=this.networkAdaptersForTemplate[2]),this.networkAdaptersForTemplate[3]&&(this.iosTemplate.slot3=this.networkAdaptersForTemplate[3]),this.networkAdaptersForTemplate[4]&&(this.iosTemplate.slot4=this.networkAdaptersForTemplate[4]),this.networkAdaptersForTemplate[5]&&(this.iosTemplate.slot5=this.networkAdaptersForTemplate[5]),this.networkAdaptersForTemplate[6]&&(this.iosTemplate.slot6=this.networkAdaptersForTemplate[6]),this.networkAdaptersForTemplate[7]&&(this.iosTemplate.slot7=this.networkAdaptersForTemplate[7])},t.prototype.completeModulesData=function(){if(Object.keys(this.networkModules[this.iosTemplate.platform]))for(var t=0;t<Object.keys(this.networkModules[this.iosTemplate.platform]).length;t++)this.networkModulesForTemplate[t]||(this.networkModulesForTemplate[t]="");this.networkModulesForTemplate[0]&&(this.iosTemplate.wic0=this.networkModulesForTemplate[0]),this.networkModulesForTemplate[1]&&(this.iosTemplate.wic1=this.networkModulesForTemplate[1]),this.networkModulesForTemplate[2]&&(this.iosTemplate.wic2=this.networkModulesForTemplate[2])},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","dynamips","templates"])},t.prototype.onImageChosen=function(){var t=this.iosImageForm.get("imageName").value.split("-")[0];this.iosNameForm.controls.templateName.setValue(t),"c3620"===t||"c3640"===t||"c3660"===t?(this.iosNameForm.controls.platform.setValue("c3600"),this.selectedPlatform="c3600"):(this.iosNameForm.controls.platform.setValue(t),this.selectedPlatform=t),this.iosNameForm.controls.chassis.setValue("c1700"===t?"1720":"c2600"===t?"2610":""),this.iosMemoryForm.controls.memory.setValue(this.defaultRam[t])},t.prototype.onPlatformChosen=function(){this.iosTemplate.chassis="",this.networkAdaptersForTemplate=[],this.networkModulesForTemplate=[]},t.prototype.onChassisChosen=function(){this.networkAdaptersForTemplate=[]},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(got),da(Y2),da(Jp),da(lQ),da(oft),da(J7),da(_ot))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-ios-template"]],decls:6,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"linear"],["label","Server type",3,"completed"],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"disabled","click"],["label","IOS image",3,"completed"],["type","file","accept",".bin, .image","ng2FileSelect","",1,"non-visible",3,"uploader","change"],["file",""],["mat-raised-button","","color","primary",3,"click"],[3,"formGroup"],[1,"form-field"],["placeholder","Image","formControlName","imageName",3,"selectionChange"],[3,"value",4,"ngFor","ngForOf"],["label","Name and platform",3,"completed"],["matInput","","type","text","formControlName","templateName","placeholder","Name"],["placeholder","Platform","formControlName","platform",3,"selectionChange"],["class","form-field",4,"ngIf"],[3,"ngModel","ngModelChange",4,"ngIf"],["label","Memory",3,"completed"],["matInput","","type","number","formControlName","memory","value","defaultRam[iosNameForm.get('platform').value]","placeholder","Default RAM"],["matSuffix",""],[3,"href"],["label","Network adapters"],[4,"ngIf"],["label","WIC modules"],["label","Idle-PC"],["matInput","","type","text","placeholder","Idle-PC",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],[3,"value"],["placeholder","Chassis","formControlName","chassis",3,"selectionChange"],[3,"ngModel","ngModelChange"],[4,"ngFor","ngForOf"],[3,"placeholder","ngModel","ngModelOptions","ngModelChange",4,"ngIf"],[3,"placeholder","ngModel","ngModelOptions","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New IOS router template"),va(),va(),va(),ua(5,dgt,49,18,"div",4),va()),2&t&&(Qi(5),pa("ngIf",e.iosTemplate))},directives:[Ah,sat,rat,A6,D6,kX,a2,xp,gf,Pp,Y3,O5,mf,Fp,Eh,s5,cf,Ef,q3,z3,Sp,EJ,F5],styles:[".non-visible[_ngcontent-%COMP%]{display:none}",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),pgt=function(){function t(t){this.httpServer=t}return t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.prototype.getVirtualMachines=function(t){return this.httpServer.get(t,"/compute/vmware/vms")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function mgt(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences")}function ggt(t,e){1&t&&(ga(0,"button",11),ds(1,"Add VMware template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/vmware/addtemplate")}function vgt(t,e){1&t&&ba(0,"app-empty-templates-list")}function bgt(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function ygt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,bgt,13,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.vmwareTemplates)}}function _gt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,ygt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var wgt=function(){function t(t,e,n){this.route=t,this.serverService=e,this.vmwareService=n,this.vmwareTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.vmwareService.getTemplates(this.server).subscribe((function(e){t.vmwareTemplates=e.filter((function(t){return"vmware"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(pgt))},t.\u0275cmp=Ht({type:t,selectors:[["app-vmware-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VMware VM templates"),va(),ua(5,mgt,2,1,"button",4),ua(6,ggt,2,1,"button",5),va(),va(),ua(7,vgt,1,0,"app-empty-templates-list",6),ua(8,_gt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.vmwareTemplates.length),Qi(1),pa("ngIf",e.vmwareTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),kgt=["customAdaptersConfigurator"];function Cgt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Sgt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function xgt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Ogt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var Mgt=function(){return{standalone:!0}};function Tgt(t,e){if(1&t){var n=ka();ga(0,"div",8),ga(1,"mat-accordion"),ga(2,"mat-expansion-panel"),ga(3,"mat-expansion-panel-header"),ga(4,"mat-panel-title"),ds(5," General settings "),va(),va(),ga(6,"form",9),ga(7,"mat-form-field",10),ga(8,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.name=t})),va(),va(),ga(9,"mat-form-field",10),ga(10,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.default_name_format=t})),va(),va(),ga(11,"mat-form-field",10),ga(12,"input",13),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.symbol=t})),va(),va(),ga(13,"button",14),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(14,"Choose symbol"),va(),ba(15,"br"),ba(16,"br"),ga(17,"mat-form-field",10),ga(18,"mat-select",15),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.category=t})),ua(19,Cgt,2,2,"mat-option",16),va(),va(),ga(20,"mat-form-field",17),ga(21,"mat-select",18),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.console_type=t})),ua(22,Sgt,2,2,"mat-option",16),va(),va(),ga(23,"mat-checkbox",19),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.console_auto_start=t})),ds(24," Auto start console "),va(),ga(25,"mat-form-field",10),ga(26,"mat-select",20),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.on_close=t})),ua(27,xgt,2,2,"mat-option",16),va(),va(),ga(28,"mat-checkbox",19),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.headless=t})),ds(29," Start VM in headless mode "),va(),ba(30,"br"),ba(31,"br"),ga(32,"mat-checkbox",19),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.linked_clone=t})),ds(33," Use as a linked base VM (experimental) "),va(),va(),va(),ga(34,"mat-expansion-panel"),ga(35,"mat-expansion-panel-header"),ga(36,"mat-panel-title"),ds(37," Network "),va(),va(),ga(38,"mat-form-field",10),ga(39,"input",21),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.adapters=t})),va(),va(),ga(40,"mat-form-field",10),ga(41,"input",22),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.first_port_name=t})),va(),va(),ga(42,"mat-form-field",10),ga(43,"input",23),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.port_name_format=t})),va(),va(),ga(44,"mat-form-field",10),ga(45,"input",24),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.port_segment_size=t})),va(),va(),ga(46,"mat-form-field",10),ga(47,"mat-select",25),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.adapter_type=t})),ua(48,Ogt,2,2,"mat-option",16),va(),va(),ga(49,"button",26),xa("click",(function(){return Se(n),Aa().setCustomAdaptersConfiguratorState(!0)})),ds(50,"Configure custom adapters"),va(),ba(51,"br"),ga(52,"mat-checkbox",27),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.use_any_adapter=t})),ds(53," Allow GNS3 to override non custom VMware adapter "),va(),va(),ga(54,"mat-expansion-panel"),ga(55,"mat-expansion-panel-header"),ga(56,"mat-panel-title"),ds(57," Usage "),va(),va(),ga(58,"mat-form-field",10),ga(59,"textarea",28),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.usage=t})),va(),va(),va(),va(),ga(60,"div",29),ga(61,"button",30),xa("click",(function(){return Se(n),Aa().goBack()})),ds(62,"Cancel"),va(),ga(63,"button",31),xa("click",(function(){return Se(n),Aa().onSave()})),ds(64,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(6),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.vmwareTemplate.name),Qi(2),pa("ngModel",i.vmwareTemplate.default_name_format),Qi(2),pa("ngModel",i.vmwareTemplate.symbol),Qi(6),pa("ngModelOptions",jc(27,Mgt))("ngModel",i.vmwareTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModelOptions",jc(28,Mgt))("ngModel",i.vmwareTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModelOptions",jc(29,Mgt))("ngModel",i.vmwareTemplate.console_auto_start),Qi(3),pa("ngModelOptions",jc(30,Mgt))("ngModel",i.vmwareTemplate.on_close),Qi(1),pa("ngForOf",i.onCloseOptions),Qi(1),pa("ngModelOptions",jc(31,Mgt))("ngModel",i.vmwareTemplate.headless),Qi(4),pa("ngModelOptions",jc(32,Mgt))("ngModel",i.vmwareTemplate.linked_clone),Qi(7),pa("ngModel",i.vmwareTemplate.adapters),Qi(2),pa("ngModel",i.vmwareTemplate.first_port_name),Qi(2),pa("ngModel",i.vmwareTemplate.port_name_format),Qi(2),pa("ngModel",i.vmwareTemplate.port_segment_size),Qi(2),pa("ngModel",i.vmwareTemplate.adapter_type),Qi(1),pa("ngForOf",i.networkTypes),Qi(4),pa("ngModel",i.vmwareTemplate.use_any_adapter),Qi(7),pa("ngModel",i.vmwareTemplate.usage)}}function Egt(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",33),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.vmwareTemplate.symbol)}}var Pgt=function(t){return{shadowed:t}},Agt=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.vmwareService=n,this.toasterService=i,this.formBuilder=r,this.vmwareConfigurationService=o,this.router=a,this.displayedColumns=["adapter_number","port_name","adapter_type","actions"],this.isConfiguratorOpened=!1,this.isSymbolSelectionOpened=!1,this.consoleTypes=[],this.categories=[],this.onCloseOptions=[],this.networkTypes=[],this.generalSettingsForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),symbol:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.vmwareService.getTemplate(t.server,n).subscribe((function(e){t.vmwareTemplate=e,t.fillCustomAdapters()}))}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.vmwareConfigurationService.getConsoleTypes(),this.categories=this.vmwareConfigurationService.getCategories(),this.onCloseOptions=this.vmwareConfigurationService.getOnCloseoptions(),this.networkTypes=this.vmwareConfigurationService.getNetworkTypes()},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","vmware","templates"])},t.prototype.onSave=function(){var t=this;this.generalSettingsForm.invalid?this.toasterService.error("Fill all required fields"):(this.fillCustomAdapters(),this.vmwareService.saveTemplate(this.server,this.vmwareTemplate).subscribe((function(e){t.toasterService.success("Changes saved")})))},t.prototype.setCustomAdaptersConfiguratorState=function(t){var e=this;this.isConfiguratorOpened=t,t&&(this.fillCustomAdapters(),this.customAdaptersConfigurator.numberOfAdapters=this.vmwareTemplate.adapters,this.customAdaptersConfigurator.adapters=[],this.vmwareTemplate.custom_adapters.forEach((function(t){e.customAdaptersConfigurator.adapters.push({adapter_number:t.adapter_number,adapter_type:t.adapter_type})})))},t.prototype.saveCustomAdapters=function(t){this.setCustomAdaptersConfiguratorState(!1),this.vmwareTemplate.custom_adapters=t},t.prototype.fillCustomAdapters=function(){var t=this.vmwareTemplate.custom_adapters?this.vmwareTemplate.custom_adapters:[];this.vmwareTemplate.custom_adapters=[];for(var e=0;e<this.vmwareTemplate.adapters;e++)this.vmwareTemplate.custom_adapters.push(t[e]?t[e]:{adapter_number:e,adapter_type:"e1000"})},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.vmwareTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(pgt),da(Y2),da(Jp),da(V7),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-vmware-template-details"]],viewQuery:function(t,e){var n;1&t&&nl(kgt,!0),2&t&&tl(n=sl())&&(e.customAdaptersConfigurator=n.first)},decls:9,vars:8,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"hidden","networkTypes","displayedColumns","closeConfiguratorEmitter","saveConfigurationEmitter"],["customAdaptersConfigurator",""],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","defaultName","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","symbol","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ngModelOptions","ngModel","ngModelChange"],["placeholder","On close",3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","type","number","placeholder","Adapters",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","First port name",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Name format",3,"ngModel","ngModelChange"],["matInput","","type","number","placeholder","Segment size",3,"ngModel","ngModelChange"],["placeholder","Type",3,"ngModel","ngModelChange"],["mat-button","",1,"configButton",3,"click"],[3,"ngModel","ngModelChange"],["matInput","","type","text",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VMware VM configuration"),va(),va(),va(),ua(5,Tgt,65,33,"div",4),va(),ga(6,"app-custom-adapters",5,6),xa("closeConfiguratorEmitter",(function(t){return e.setCustomAdaptersConfiguratorState(t)}))("saveConfigurationEmitter",(function(t){return e.saveCustomAdapters(t)})),va(),ua(8,Egt,1,2,"app-symbols-menu",7)),2&t&&(pa("ngClass",Ic(6,Pgt,e.isSymbolSelectionOpened||e.isConfiguratorOpened)),Qi(5),pa("ngIf",e.vmwareTemplate),Qi(1),pa("hidden",!(e.isConfiguratorOpened&&e.vmwareTemplate))("networkTypes",e.networkTypes)("displayedColumns",e.displayedColumns),Qi(2),pa("ngIf",e.isSymbolSelectionOpened&&e.vmwareTemplate))},directives:[Oh,Ah,Hdt,Sdt,ydt,wdt,Cdt,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2,O5,Sp,Eh,F5,Ef,EJ,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function jgt(t,e){if(1&t&&(ga(0,"mat-option",15),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n.vmname," ")}}var Igt=function(){return{standalone:!0}};function Dgt(t,e){if(1&t){var n=ka();ga(0,"div",5),ga(1,"mat-card",6),ga(2,"form",7),ga(3,"mat-form-field",8),ga(4,"mat-select",9),xa("ngModelChange",(function(t){return Se(n),Aa().selectedVM=t})),ua(5,jgt,2,2,"mat-option",10),va(),va(),ba(6,"br"),ga(7,"mat-checkbox",11),xa("ngModelChange",(function(t){return Se(n),Aa().vmwareTemplate.linked_clone=t})),ds(8," Use as a linked base VM (experimental) "),va(),va(),va(),ga(9,"div",12),ga(10,"button",13),xa("click",(function(){return Se(n),Aa().goBack()})),ds(11,"Cancel"),va(),ga(12,"button",14),xa("click",(function(){return Se(n),Aa().addTemplate()})),ds(13,"Add template"),va(),va(),va()}if(2&t){var i=Aa();Qi(2),pa("formGroup",i.templateNameForm),Qi(2),pa("ngModel",i.selectedVM),Qi(1),pa("ngForOf",i.virtualMachines),Qi(2),pa("ngModelOptions",jc(5,Igt))("ngModel",i.vmwareTemplate.linked_clone)}}var Rgt=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.vmwareService=n,this.toasterService=i,this.templateMocksService=r,this.router=o,this.formBuilder=a,this.templateNameForm=this.formBuilder.group({templateName:new hp(null,[kf.required])})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.vmwareService.getVirtualMachines(t.server).subscribe((function(e){t.virtualMachines=e,t.templateMocksService.getVmwareTemplate().subscribe((function(e){t.vmwareTemplate=e}))}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","vmware","templates"])},t.prototype.addTemplate=function(){var t=this;this.templateNameForm.invalid?this.toasterService.error("Fill all required fields"):(this.vmwareTemplate.name=this.selectedVM.vmname,this.vmwareTemplate.vmx_path=this.selectedVM.vmx_path,this.vmwareTemplate.template_id=Object(art.v4)(),this.vmwareService.addTemplate(this.server,this.vmwareTemplate).subscribe((function(){t.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(pgt),da(Y2),da(oft),da(lQ),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-vmware-template"]],decls:6,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["placeholder","VM list","formControlName","templateName",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[3,"ngModelOptions","ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New VMware VM template"),va(),va(),va(),ua(5,Dgt,14,6,"div",4),va()),2&t&&(Qi(5),pa("ngIf",e.vmwareTemplate))},directives:[Ah,f3,xp,gf,Pp,Y3,O5,mf,Fp,Eh,F5,Sp,a2,EJ],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function Lgt(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences")}function Fgt(t,e){1&t&&(ga(0,"button",11),ds(1,"Add Docker container template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/docker/addtemplate")}function Ngt(t,e){1&t&&ba(0,"app-empty-templates-list")}function Bgt(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),ga(13,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).copyTemplate(t)})),ga(14,"mat-icon"),ds(15,"content_copy"),va(),ga(16,"span"),ds(17,"Copy"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function Hgt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,Bgt,18,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.dockerTemplates)}}function zgt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,Hgt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var Vgt=function(){function t(t,e,n,i){this.route=t,this.serverService=e,this.dockerService=n,this.router=i,this.dockerTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.dockerService.getTemplates(this.server).subscribe((function(e){t.dockerTemplates=e.filter((function(t){return"docker"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.prototype.copyTemplate=function(t){this.router.navigate(["/server",this.server.id,"preferences","docker","templates",t.template_id,"copy"])},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(pot),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-docker-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Docker container templates"),va(),ua(5,Lgt,2,1,"button",4),ua(6,Fgt,2,1,"button",5),va(),va(),ua(7,Ngt,1,0,"app-empty-templates-list",6),ua(8,zgt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.dockerTemplates.length),Qi(1),pa("ngIf",e.dockerTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function Ugt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n.image," ")}}var qgt=function(){return{standalone:!0}};function Ggt(t,e){if(1&t){var n=ka();ga(0,"mat-select",31),xa("ngModelChange",(function(t){return Se(n),Aa().selectedImage=t})),ua(1,Ugt,2,2,"mat-option",25),va()}if(2&t){var i=Aa();pa("ngModelOptions",jc(3,qgt))("ngModel",i.selectedImage),Qi(1),pa("ngForOf",i.dockerImages)}}function Wgt(t,e){1&t&&(ga(0,"div"),ga(1,"mat-form-field",17),ba(2,"input",33),va(),va())}function Kgt(t,e){if(1&t&&(ga(0,"mat-option",32),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var Xgt=function(){function t(t,e,n,i,r,o,a,s,c){this.route=t,this.serverService=e,this.dockerService=n,this.toasterService=i,this.router=r,this.formBuilder=o,this.templateMocksService=a,this.configurationService=s,this.computeService=c,this.consoleTypes=[],this.isRemoteComputerChosen=!1,this.dockerImages=[],this.newImageSelected=!1,this.isGns3VmAvailable=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0,this.dockerTemplate=new fot,this.virtualMachineForm=this.formBuilder.group({filename:new hp(null,kf.required)}),this.containerNameForm=this.formBuilder.group({templateName:new hp(null,kf.required)}),this.networkAdaptersForm=this.formBuilder.group({adapters:new hp("1",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.consoleTypes=t.configurationService.getConsoleTypes(),t.templateMocksService.getDockerTemplate().subscribe((function(e){t.dockerTemplate=e})),t.computeService.getComputes(e).subscribe((function(e){e.filter((function(t){return"vm"===t.compute_id})).length>0&&(t.isGns3VmAvailable=!0)})),t.dockerService.getImages(e).subscribe((function(e){t.dockerImages=e}))}))},t.prototype.setServerType=function(t){"gns3 vm"===t&&this.isGns3VmAvailable?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.setDiskImage=function(t){this.newImageSelected="newImage"===t},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","docker","templates"])},t.prototype.addTemplate=function(){var t=this;this.virtualMachineForm.invalid&&(this.newImageSelected||!this.selectedImage)||this.containerNameForm.invalid||this.networkAdaptersForm.invalid?this.toasterService.error("Fill all required fields"):(this.dockerTemplate.template_id=Object(art.v4)(),this.dockerTemplate.image=this.newImageSelected?this.virtualMachineForm.get("filename").value:this.selectedImage.image,this.dockerTemplate.name=this.containerNameForm.get("templateName").value,this.dockerTemplate.adapters=+this.networkAdaptersForm.get("adapters").value,this.dockerTemplate.compute_id=this.isGns3VmChosen?"vm":"local",this.dockerService.addTemplate(this.server,this.dockerTemplate).subscribe((function(e){t.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(pot),da(Y2),da(lQ),da(Jp),da(oft),da(i8),da(_ot))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-docker-template"]],decls:45,vars:19,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"linear"],["label","Server type",3,"completed"],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"disabled","click"],["label","Docker Virtual Machine",3,"completed"],[3,"formGroup"],["value","2",1,"radio-button",3,"click"],["placeholder","Image list",3,"ngModelOptions","ngModel","ngModelChange",4,"ngIf"],[4,"ngIf"],["label","Container name",3,"completed"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Container name",1,"templatename"],["label","Network adapters",3,"completed"],["matInput","","type","number","formControlName","adapters","placeholder","Adapters",1,"networkadapter"],["label","Start command",3,"completed"],["matInput","","type","text","placeholder","Start command",3,"ngModel","ngModelChange"],["label","Console type",3,"completed"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["label","Environment"],["matInput","","type","text",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",1,"add-button",3,"click"],["placeholder","Image list",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value"],["matInput","","type","text","formControlName","filename","placeholder","Image name",1,"filename"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New Docker container template"),va(),va(),va(),ga(5,"div",4),ga(6,"div",5),ga(7,"mat-vertical-stepper",6),ga(8,"mat-step",7),ga(9,"mat-radio-group",8),ga(10,"mat-radio-button",9),xa("click",(function(){return e.setServerType("local")})),ds(11,"Run this Docker container locally"),va(),ga(12,"mat-radio-button",10),xa("click",(function(){return e.setServerType("gns3 vm")})),ds(13,"Run this Docker container on the GNS3 VM"),va(),va(),va(),ga(14,"mat-step",11),ga(15,"form",12),ga(16,"mat-radio-group",8),ga(17,"mat-radio-button",9),xa("click",(function(){return e.setDiskImage("existingImage")})),ds(18,"Existing image"),va(),ga(19,"mat-radio-button",13),xa("click",(function(){return e.setDiskImage("newImage")})),ds(20,"New image"),va(),va(),ua(21,Ggt,2,4,"mat-select",14),ua(22,Wgt,3,0,"div",15),va(),va(),ga(23,"mat-step",16),ga(24,"form",12),ga(25,"mat-form-field",17),ba(26,"input",18),va(),va(),va(),ga(27,"mat-step",19),ga(28,"form",12),ga(29,"mat-form-field",17),ba(30,"input",20),va(),va(),va(),ga(31,"mat-step",21),ga(32,"mat-form-field",17),ga(33,"input",22),xa("ngModelChange",(function(t){return e.dockerTemplate.start_command=t})),va(),va(),va(),ga(34,"mat-step",23),ga(35,"mat-select",24),xa("ngModelChange",(function(t){return e.dockerTemplate.console_type=t})),ua(36,Kgt,2,2,"mat-option",25),va(),va(),ga(37,"mat-step",26),ga(38,"mat-form-field",17),ga(39,"textarea",27),xa("ngModelChange",(function(t){return e.dockerTemplate.environment=t})),va(),va(),va(),va(),va(),ga(40,"div",28),ga(41,"button",29),xa("click",(function(){return e.goBack()})),ds(42,"Cancel"),va(),ga(43,"button",30),xa("click",(function(){return e.addTemplate()})),ds(44,"Add template"),va(),va(),va(),va()),2&t&&(Qi(7),pa("linear",!0),Qi(1),pa("completed",e.isGns3VmChosen||e.isLocalComputerChosen),Qi(4),pa("disabled",!e.isGns3VmAvailable),Qi(2),pa("completed",e.selectedImage||e.virtualMachineForm.get("filename").value),Qi(1),pa("formGroup",e.virtualMachineForm),Qi(6),pa("ngIf",!e.newImageSelected),Qi(1),pa("ngIf",e.newImageSelected),Qi(1),pa("completed",e.containerNameForm.get("templateName").value),Qi(1),pa("formGroup",e.containerNameForm),Qi(3),pa("completed",e.networkAdaptersForm.get("adapters").value),Qi(1),pa("formGroup",e.networkAdaptersForm),Qi(3),pa("completed",e.dockerTemplate.start_command),Qi(2),pa("ngModel",e.dockerTemplate.start_command),Qi(1),pa("completed",e.dockerTemplate.console_type),Qi(1),pa("ngModelOptions",jc(18,qgt))("ngModel",e.dockerTemplate.console_type),Qi(1),pa("ngForOf",e.consoleTypes),Qi(3),pa("ngModel",e.dockerTemplate.environment))},directives:[sat,rat,A6,D6,xp,gf,Pp,Ah,Y3,s5,cf,mf,Fp,Ef,Sp,O5,Eh,a2,EJ],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function Ygt(t,e){if(1&t&&(ga(0,"mat-option",27),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function Zgt(t,e){if(1&t&&(ga(0,"mat-option",27),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function Qgt(t,e){if(1&t&&(ga(0,"mat-option",27),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}var $gt=function(){return{standalone:!0}};function Jgt(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"mat-accordion"),ga(2,"mat-expansion-panel"),ga(3,"mat-expansion-panel-header"),ga(4,"mat-panel-title"),ds(5," General settings "),va(),va(),ga(6,"form",7),ga(7,"mat-form-field",8),ga(8,"input",9),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.name=t})),va(),va(),ga(9,"mat-form-field",8),ga(10,"input",10),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.default_name_format=t})),va(),va(),ga(11,"mat-form-field",8),ga(12,"mat-select",11),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.category=t})),ua(13,Ygt,2,2,"mat-option",12),va(),va(),ga(14,"mat-form-field",8),ga(15,"input",13),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.symbol=t})),va(),va(),ga(16,"button",14),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(17,"Choose symbol"),va(),ba(18,"br"),ba(19,"br"),ga(20,"mat-form-field",8),ga(21,"input",15),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.start_command=t})),va(),va(),ga(22,"mat-form-field",8),ga(23,"input",16),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.adapters=t})),va(),va(),ga(24,"mat-form-field",17),ga(25,"mat-select",18),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.console_type=t})),ua(26,Zgt,2,2,"mat-option",12),va(),va(),ga(27,"mat-checkbox",19),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.console_auto_start=t})),ds(28," Auto start console "),va(),ga(29,"mat-form-field",17),ga(30,"mat-select",20),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.console_resolution=t})),ua(31,Qgt,2,2,"mat-option",12),va(),va(),ga(32,"mat-form-field",8),ga(33,"input",21),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.console_http_port=t})),va(),va(),ga(34,"mat-form-field",8),ga(35,"input",22),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.console_http_path=t})),va(),va(),va(),ga(36,"h6"),ds(37,"Environment"),va(),ga(38,"mat-form-field",8),ga(39,"textarea",23),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.environment=t})),va(),va(),va(),ga(40,"mat-expansion-panel"),ga(41,"mat-expansion-panel-header"),ga(42,"mat-panel-title"),ds(43," Advanced "),va(),va(),ga(44,"h6"),ds(45,"Extra hosts"),va(),ga(46,"mat-form-field",8),ga(47,"textarea",23),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.extra_hosts=t})),va(),va(),va(),ga(48,"mat-expansion-panel"),ga(49,"mat-expansion-panel-header"),ga(50,"mat-panel-title"),ds(51," Usage "),va(),va(),ga(52,"mat-form-field",8),ga(53,"textarea",23),xa("ngModelChange",(function(t){return Se(n),Aa().dockerTemplate.usage=t})),va(),va(),va(),va(),ga(54,"div",24),ga(55,"button",25),xa("click",(function(){return Se(n),Aa().goBack()})),ds(56,"Cancel"),va(),ga(57,"button",26),xa("click",(function(){return Se(n),Aa().onSave()})),ds(58,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(6),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.dockerTemplate.name),Qi(2),pa("ngModel",i.dockerTemplate.default_name_format),Qi(2),pa("ngModelOptions",jc(25,$gt))("ngModel",i.dockerTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(2),pa("ngModel",i.dockerTemplate.symbol),Qi(6),pa("ngModelOptions",jc(26,$gt))("ngModel",i.dockerTemplate.start_command),Qi(2),pa("ngModel",i.dockerTemplate.adapters),Qi(2),pa("ngModelOptions",jc(27,$gt))("ngModel",i.dockerTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModelOptions",jc(28,$gt))("ngModel",i.dockerTemplate.console_auto_start),Qi(3),pa("ngModelOptions",jc(29,$gt))("ngModel",i.dockerTemplate.console_resolution),Qi(1),pa("ngForOf",i.consoleResolutions),Qi(2),pa("ngModelOptions",jc(30,$gt))("ngModel",i.dockerTemplate.console_http_port),Qi(2),pa("ngModelOptions",jc(31,$gt))("ngModel",i.dockerTemplate.console_http_path),Qi(4),pa("ngModel",i.dockerTemplate.environment),Qi(8),pa("ngModel",i.dockerTemplate.extra_hosts),Qi(6),pa("ngModel",i.dockerTemplate.usage)}}function tvt(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",28),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.dockerTemplate.symbol)}}var evt=function(t){return{shadowed:t}},nvt=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.dockerService=n,this.toasterService=i,this.configurationService=r,this.formBuilder=o,this.router=a,this.isSymbolSelectionOpened=!1,this.consoleTypes=[],this.consoleResolutions=[],this.categories=[],this.adapters=[],this.displayedColumns=["adapter_number","port_name"],this.generalSettingsForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),adapter:new hp("",kf.required),symbol:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.dockerService.getTemplate(t.server,n).subscribe((function(e){t.dockerTemplate=e}))}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.configurationService.getConsoleTypes(),this.categories=this.configurationService.getCategories(),this.consoleResolutions=this.configurationService.getConsoleResolutions()},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","docker","templates"])},t.prototype.onSave=function(){var t=this;this.generalSettingsForm.invalid?this.toasterService.error("Fill all required fields"):this.dockerService.saveTemplate(this.server,this.dockerTemplate).subscribe((function(e){t.toasterService.success("Changes saved")}))},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.dockerTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(pot),da(Y2),da(i8),da(Jp),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-docker-template-details"]],decls:7,vars:5,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[3,"formGroup"],[1,"form-field"],["formControlName","templateName","matInput","","type","text","placeholder","Template name",3,"ngModel","ngModelChange"],["formControlName","defaultName","matInput","","type","text","placeholder","Default name format",3,"ngModel","ngModelChange"],["placeholder","Category",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["formControlName","symbol","matInput","","type","text","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["matInput","","type","text","placeholder","Start command",3,"ngModelOptions","ngModel","ngModelChange"],["formControlName","adapter","matInput","","type","number","placeholder","Adapters",3,"ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ngModelOptions","ngModel","ngModelChange"],["placeholder","VNC console resolution",3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","type","number","placeholder","HTTP port in the container",3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","type","text","placeholder","HTTP path",3,"ngModelOptions","ngModel","ngModelChange"],["matInput","","type","text",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Docker image configuration"),va(),va(),va(),ua(5,Jgt,59,32,"div",4),va(),ua(6,tvt,1,2,"app-symbols-menu",5)),2&t&&(pa("ngClass",Ic(3,evt,e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.dockerTemplate),Qi(1),pa("ngIf",e.isSymbolSelectionOpened&&e.dockerTemplate))},directives:[Oh,Ah,Sdt,ydt,wdt,Cdt,xp,gf,Pp,Y3,cf,s5,mf,Fp,O5,Sp,Eh,a2,Ef,F5,EJ,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function ivt(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences")}function rvt(t,e){1&t&&(ga(0,"button",11),ds(1,"Add IOU device template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/iou/addtemplate")}function ovt(t,e){1&t&&ba(0,"app-empty-templates-list")}function avt(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),ga(13,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).copyTemplate(t)})),ga(14,"mat-icon"),ds(15,"content_copy"),va(),ga(16,"span"),ds(17,"Copy"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function svt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,avt,18,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.iouTemplates)}}function cvt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,svt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var lvt=function(){function t(t,e,n,i){this.route=t,this.serverService=e,this.iouService=n,this.router=i,this.iouTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.iouService.getTemplates(this.server).subscribe((function(e){t.iouTemplates=e.filter((function(t){return"iou"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.prototype.copyTemplate=function(t){this.router.navigate(["/server",this.server.id,"preferences","iou","templates",t.template_id,"copy"])},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(vot),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-iou-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"IOU device templates"),va(),ua(5,ivt,2,1,"button",4),ua(6,rvt,2,1,"button",5),va(),va(),ua(7,ovt,1,0,"app-empty-templates-list",6),ua(8,cvt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.iouTemplates.length),Qi(1),pa("ngIf",e.iouTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function uvt(t,e){if(1&t&&(ga(0,"mat-option",24),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function hvt(t,e){if(1&t&&(ga(0,"mat-option",24),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.path),Qi(1),ps(" ",n.path," ")}}var dvt=function(){return{standalone:!0}};function fvt(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",13),ga(1,"mat-select",25),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.path=t})),ua(2,hvt,2,2,"mat-option",18),va(),va()}if(2&t){var i=Aa();Qi(1),pa("ngModel",i.iouTemplate.path)("ngModelOptions",jc(3,dvt)),Qi(1),pa("ngForOf",i.iouImages)}}function pvt(t,e){if(1&t){var n=ka();ga(0,"div"),ga(1,"input",26,27),xa("change",(function(t){return Se(n),Aa().uploadImageFile(t)})),va(),ga(3,"button",28),xa("click",(function(){return Se(n),ha(2).click()})),ds(4,"Browse"),va(),ga(5,"mat-form-field",29),ba(6,"input",30),va(),va()}if(2&t){var i=Aa();Qi(1),pa("uploader",i.uploader)}}var mvt=function(){function t(t,e,n,i,r,o,a,s){this.route=t,this.serverService=e,this.iouService=n,this.toasterService=i,this.router=r,this.formBuilder=o,this.templateMocksService=a,this.computeService=s,this.isRemoteComputerChosen=!1,this.newImageSelected=!1,this.types=["L2 image","L3 image"],this.iouImages=[],this.isGns3VmAvailable=!1,this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0,this.iouTemplate=new bot,this.templateNameForm=this.formBuilder.group({templateName:new hp(null,kf.required)}),this.imageForm=this.formBuilder.group({imageName:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this;this.uploader=new wX({}),this.uploader.onAfterAddingFile=function(t){t.withCredentials=!1},this.uploader.onErrorItem=function(e,n,i,r){t.toasterService.error("An error occured: "+n)},this.uploader.onSuccessItem=function(e,n,i,r){t.getImages(),t.toasterService.success("Image uploaded")};var e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getImages(),t.templateMocksService.getIouTemplate().subscribe((function(e){t.iouTemplate=e})),t.computeService.getComputes(e).subscribe((function(e){e.filter((function(t){return"vm"===t.compute_id})).length>0&&(t.isGns3VmAvailable=!0)}))}))},t.prototype.getImages=function(){var t=this;this.iouService.getImages(this.server).subscribe((function(e){t.iouImages=e}))},t.prototype.setServerType=function(t){"gns3 vm"===t&&this.isGns3VmAvailable?(this.isGns3VmChosen=!0,this.isLocalComputerChosen=!1):(this.isGns3VmChosen=!1,this.isLocalComputerChosen=!0)},t.prototype.setDiskImage=function(t){this.newImageSelected="newImage"===t},t.prototype.uploadImageFile=function(t){var e=t.target.files[0].name;this.imageForm.controls.imageName.setValue(e);var n=this.iouService.getImagePath(this.server,e);this.uploader.queue.forEach((function(t){return t.url=n}));var i=this.uploader.queue[0];i.options.disableMultipart=!0,this.uploader.uploadItem(i)},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","iou","templates"])},t.prototype.addTemplate=function(){var t=this;!this.templateNameForm.invalid&&(this.newImageSelected&&!this.imageForm.invalid||!this.newImageSelected&&this.iouTemplate.path)?(this.iouTemplate.template_id=Object(art.v4)(),this.iouTemplate.name=this.templateNameForm.get("templateName").value,this.newImageSelected&&(this.iouTemplate.path=this.imageForm.get("imageName").value),this.iouTemplate.compute_id=this.isGns3VmChosen?"vm":"local","L2 image"===this.selectedType?(this.iouTemplate.ethernet_adapters=4,this.iouTemplate.serial_adapters=0):"L3 image"===this.selectedType&&(this.iouTemplate.ethernet_adapters=2,this.iouTemplate.serial_adapters=2),this.iouService.addTemplate(this.server,this.iouTemplate).subscribe((function(e){t.goBack()}))):this.toasterService.error("Fill all required fields")},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(vot),da(Y2),da(lQ),da(Jp),da(oft),da(_ot))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-iou-template"]],decls:35,vars:12,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"linear"],["label","Server type",3,"completed"],[1,"radio-group"],["value","1","checked","",1,"radio-button",3,"click"],["value","2",1,"radio-button",3,"disabled","click"],["label","Name",3,"completed"],[3,"formGroup"],[1,"form-field"],["matInput","","placeholder","Name","type","text","formControlName","templateName"],["label","Image"],["value","2",1,"radio-button",3,"click"],["placeholder","Type",3,"ngModel","ngModelOptions","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["class","form-field",4,"ngIf"],[4,"ngIf"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],["placeholder","IOU image",3,"ngModel","ngModelOptions","ngModelChange"],["type","file","accept",".bin","ng2FileSelect","",1,"nonvisible",3,"uploader","change"],["file",""],["mat-raised-button","","color","primary",1,"file-button",3,"click"],[1,"file-name-form-field"],["matInput","","type","text","formControlName","imageName","placeholder","IOU image"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New IOU device template"),va(),va(),va(),ga(5,"div",4),ga(6,"div",5),ga(7,"mat-vertical-stepper",6),ga(8,"mat-step",7),ga(9,"mat-radio-group",8),ga(10,"mat-radio-button",9),xa("click",(function(){return e.setServerType("local")})),ds(11,"Run this IOU device locally"),va(),ga(12,"mat-radio-button",10),xa("click",(function(){return e.setServerType("gns3 vm")})),ds(13,"Run this IOU device on the GNS3 VM"),va(),va(),va(),ga(14,"mat-step",11),ga(15,"form",12),ga(16,"mat-form-field",13),ba(17,"input",14),va(),va(),va(),ga(18,"mat-step",15),ga(19,"form",12),ga(20,"mat-radio-group",8),ga(21,"mat-radio-button",9),xa("click",(function(){return e.setDiskImage("existingImage")})),ds(22,"Existing image"),va(),ga(23,"mat-radio-button",16),xa("click",(function(){return e.setDiskImage("newImage")})),ds(24,"New image"),va(),va(),ga(25,"mat-form-field",13),ga(26,"mat-select",17),xa("ngModelChange",(function(t){return e.selectedType=t})),ua(27,uvt,2,2,"mat-option",18),va(),va(),ua(28,fvt,3,4,"mat-form-field",19),ua(29,pvt,7,1,"div",20),va(),va(),va(),va(),ga(30,"div",21),ga(31,"button",22),xa("click",(function(){return e.goBack()})),ds(32,"Cancel"),va(),ga(33,"button",23),xa("click",(function(){return e.addTemplate()})),ds(34,"Add template"),va(),va(),va(),va()),2&t&&(Qi(7),pa("linear",!0),Qi(1),pa("completed",e.isGns3VmChosen||e.isLocalComputerChosen),Qi(4),pa("disabled",!e.isGns3VmAvailable),Qi(2),pa("completed",e.templateNameForm.get("templateName").value),Qi(1),pa("formGroup",e.templateNameForm),Qi(4),pa("formGroup",e.imageForm),Qi(7),pa("ngModel",e.selectedType)("ngModelOptions",jc(11,dvt)),Qi(1),pa("ngForOf",e.types),Qi(1),pa("ngIf",!e.newImageSelected),Qi(1),pa("ngIf",e.newImageSelected))},directives:[sat,rat,A6,D6,xp,gf,Pp,Y3,s5,cf,mf,Fp,O5,Sp,Eh,Ah,a2,EJ,kX],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function gvt(t,e){if(1&t&&(ga(0,"mat-option",31),ds(1),va()),2&t){var n=e.$implicit;pa("value",n[1]),Qi(1),ps(" ",n[0]," ")}}function vvt(t,e){if(1&t&&(ga(0,"mat-option",31),ds(1),va()),2&t){var n=e.$implicit;pa("value",n),Qi(1),ps(" ",n," ")}}function bvt(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",2),ga(1,"input",32),xa("ngModelChange",(function(t){return Se(n),Aa(2).iouTemplate.ram=t})),va(),ga(2,"span",33),ds(3,"MB"),va(),va()}if(2&t){var i=Aa(2);Qi(1),pa("ngModel",i.iouTemplate.ram)}}function yvt(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",2),ga(1,"input",34),xa("ngModelChange",(function(t){return Se(n),Aa(2).iouTemplate.nvram=t})),va(),ga(2,"span",33),ds(3,"MB"),va(),va()}if(2&t){var i=Aa(2);Qi(1),pa("ngModel",i.iouTemplate.nvram)}}var _vt=function(){return{standalone:!0}};function wvt(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"mat-accordion"),ga(2,"mat-expansion-panel"),ga(3,"mat-expansion-panel-header"),ga(4,"mat-panel-title"),ds(5," General settings "),va(),va(),ga(6,"form",7),ga(7,"mat-form-field",2),ga(8,"input",8),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.name=t})),va(),va(),ga(9,"mat-form-field",2),ga(10,"input",9),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.default_name_format=t})),va(),va(),ga(11,"mat-form-field",2),ga(12,"input",10),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.symbol=t})),va(),va(),ga(13,"button",11),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(14,"Choose symbol"),va(),ba(15,"br"),ba(16,"br"),ga(17,"mat-form-field",2),ga(18,"mat-select",12),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.category=t})),ua(19,gvt,2,2,"mat-option",13),va(),va(),ga(20,"input",14,15),xa("change",(function(t){return Se(n),Aa().uploadImageFile(t)})),va(),ga(22,"button",16),xa("click",(function(){return Se(n),ha(21).click()})),ds(23,"Browse"),va(),ga(24,"mat-form-field",17),ga(25,"input",18),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.path=t})),va(),va(),ga(26,"mat-form-field",2),ga(27,"input",19),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.startup_config=t})),va(),va(),ga(28,"mat-form-field",2),ga(29,"input",20),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.private_config=t})),va(),va(),va(),ga(30,"mat-form-field",21),ga(31,"mat-select",22),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.console_type=t})),ua(32,vvt,2,2,"mat-option",13),va(),va(),ga(33,"mat-checkbox",23),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.console_auto_start=t})),ds(34," Auto start console "),va(),ba(35,"br"),ga(36,"mat-checkbox",23),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.l1_keepalives=t})),ds(37," Enable layer 1 keepalive messages (non-functional) "),va(),ba(38,"br"),ga(39,"mat-checkbox",23),xa("ngModelChange",(function(t){return Se(n),Aa().defaultSettings=t})),ds(40," Use default IOU values for memories "),va(),ua(41,bvt,4,1,"mat-form-field",24),ua(42,yvt,4,1,"mat-form-field",24),va(),ga(43,"mat-expansion-panel"),ga(44,"mat-expansion-panel-header"),ga(45,"mat-panel-title"),ds(46," Network "),va(),va(),ga(47,"form",7),ga(48,"mat-form-field",2),ga(49,"input",25),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.ethernet_adapters=t})),va(),va(),ga(50,"mat-form-field",2),ga(51,"input",26),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.serial_adapters=t})),va(),va(),va(),va(),ga(52,"mat-expansion-panel"),ga(53,"mat-expansion-panel-header"),ga(54,"mat-panel-title"),ds(55," Usage "),va(),va(),ga(56,"mat-form-field",2),ga(57,"textarea",27),xa("ngModelChange",(function(t){return Se(n),Aa().iouTemplate.usage=t})),va(),va(),va(),va(),ga(58,"div",28),ga(59,"button",29),xa("click",(function(){return Se(n),Aa().goBack()})),ds(60,"Cancel"),va(),ga(61,"button",30),xa("click",(function(){return Se(n),Aa().onSave()})),ds(62,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(6),pa("formGroup",i.generalSettingsForm),Qi(2),pa("ngModel",i.iouTemplate.name),Qi(2),pa("ngModel",i.iouTemplate.default_name_format),Qi(2),pa("ngModel",i.iouTemplate.symbol),Qi(6),pa("ngModelOptions",jc(22,_vt))("ngModel",i.iouTemplate.category),Qi(1),pa("ngForOf",i.categories),Qi(6),pa("ngModel",i.iouTemplate.path),Qi(2),pa("ngModel",i.iouTemplate.startup_config),Qi(2),pa("ngModelOptions",jc(23,_vt))("ngModel",i.iouTemplate.private_config),Qi(2),pa("ngModel",i.iouTemplate.console_type),Qi(1),pa("ngForOf",i.consoleTypes),Qi(1),pa("ngModel",i.iouTemplate.console_auto_start),Qi(3),pa("ngModel",i.iouTemplate.l1_keepalives),Qi(3),pa("ngModel",i.defaultSettings),Qi(2),pa("ngIf",!i.defaultSettings),Qi(1),pa("ngIf",!i.defaultSettings),Qi(5),pa("formGroup",i.networkForm),Qi(2),pa("ngModel",i.iouTemplate.ethernet_adapters),Qi(2),pa("ngModel",i.iouTemplate.serial_adapters),Qi(6),pa("ngModel",i.iouTemplate.usage)}}function kvt(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",35),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.iouTemplate.symbol)}}var Cvt=function(t){return{shadowed:t}},Svt=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.iouService=n,this.toasterService=i,this.configurationService=r,this.router=o,this.formBuilder=a,this.isSymbolSelectionOpened=!1,this.defaultSettings=!0,this.consoleTypes=[],this.consoleResolutions=[],this.categories=[],this.generalSettingsForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),symbol:new hp("",kf.required),path:new hp("",kf.required),initialConfig:new hp("",kf.required)}),this.networkForm=this.formBuilder.group({ethernetAdapters:new hp("",kf.required),serialAdapters:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getConfiguration(),t.iouService.getTemplate(t.server,n).subscribe((function(e){t.iouTemplate=e}))}))},t.prototype.getConfiguration=function(){this.consoleTypes=this.configurationService.getConsoleTypes(),this.categories=this.configurationService.getCategories()},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","iou","templates"])},t.prototype.onSave=function(){var t=this;this.generalSettingsForm.invalid||this.networkForm.invalid?this.toasterService.error("Fill all required fields"):this.iouService.saveTemplate(this.server,this.iouTemplate).subscribe((function(){t.toasterService.success("Changes saved")}))},t.prototype.uploadImageFile=function(t){this.iouTemplate.path=t.target.files[0].name},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.iouTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(vot),da(Y2),da(Y7),da(lQ),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-iou-template-details"]],decls:7,vars:5,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"form-field"],[1,"col"],["class","default-content",4,"ngIf"],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[3,"formGroup"],["matInput","","formControlName","templateName","type","text","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","formControlName","defaultName","type","text","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","formControlName","symbol","type","text","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],["placeholder","Category",3,"ngModelOptions","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["type","file","accept",".bin","ngDefaultControl","",1,"nonvisible",3,"change"],["file",""],["mat-raised-button","","color","primary",1,"file-button",3,"click"],[1,"file-name-form-field"],["matInput","","formControlName","path","type","text","placeholder","IOU image path",3,"ngModel","ngModelChange"],["matInput","","formControlName","initialConfig","type","text","placeholder","Startup config",3,"ngModel","ngModelChange"],["matInput","","type","text","placeholder","Private config",3,"ngModelOptions","ngModel","ngModelChange"],[1,"select"],["placeholder","Console type",3,"ngModel","ngModelChange"],[3,"ngModel","ngModelChange"],["class","form-field",4,"ngIf"],["matInput","","formControlName","ethernetAdapters","type","number","placeholder","Ethernet adapters",3,"ngModel","ngModelChange"],["matInput","","formControlName","serialAdapters","type","number","placeholder","Serial adapters",3,"ngModel","ngModelChange"],["matInput","","type","text",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"value"],["matInput","","type","number","placeholder","RAM size",3,"ngModel","ngModelChange"],["matSuffix",""],["matInput","","type","number","placeholder","NVRAM size",3,"ngModel","ngModelChange"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"IOU device configuration"),va(),va(),va(),ua(5,wvt,63,24,"div",4),va(),ua(6,kvt,1,2,"app-symbols-menu",5)),2&t&&(pa("ngClass",Ic(3,Cvt,e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.iouTemplate),Qi(1),pa("ngIf",e.isSymbolSelectionOpened&&e.iouTemplate))},directives:[Oh,Ah,Sdt,ydt,wdt,Cdt,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2,O5,Sp,Eh,F5,Ef,EJ,q3,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),xvt=function(){function t(t,e,n,i,r,o){this.route=t,this.serverService=e,this.qemuService=n,this.toasterService=i,this.router=r,this.formBuilder=o,this.qemuBinaries=[],this.templateName="",this.nameForm=this.formBuilder.group({templateName:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.qemuService.getTemplate(t.server,n).subscribe((function(e){t.qemuTemplate=e,t.templateName="Copy of "+t.qemuTemplate.name}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","qemu","templates"])},t.prototype.addTemplate=function(){var t=this;this.nameForm.invalid?this.toasterService.error("Fill all required fields"):(this.qemuTemplate.template_id=Object(art.v4)(),this.qemuTemplate.name=this.templateName,this.qemuService.addTemplate(this.server,this.qemuTemplate).subscribe((function(e){t.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(w6),da(Y2),da(lQ),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-copy-qemu-virtual-machine-template"]],decls:15,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","placeholder","Name","formControlName","templateName",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Copy QEMU VM template"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card",5),ga(7,"form",6),ga(8,"mat-form-field",7),ga(9,"input",8),xa("ngModelChange",(function(t){return e.templateName=t})),va(),va(),va(),va(),ga(10,"div",9),ga(11,"button",10),xa("click",(function(){return e.goBack()})),ds(12,"Cancel"),va(),ga(13,"button",11),xa("click",(function(){return e.addTemplate()})),ds(14,"Copy template"),va(),va(),va(),va()),2&t&&(Qi(7),pa("formGroup",e.nameForm),Qi(2),pa("ngModel",e.templateName))},directives:[f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Ovt=function(){function t(t,e,n,i,r,o){this.route=t,this.serverService=e,this.iosService=n,this.toasterService=i,this.router=r,this.formBuilder=o,this.templateName="",this.formGroup=this.formBuilder.group({templateName:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.iosService.getTemplate(t.server,n).subscribe((function(e){t.iosTemplate=e,t.templateName="Copy of "+t.iosTemplate.name}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","dynamips","templates"])},t.prototype.addTemplate=function(){var t=this;this.formGroup.invalid?this.toasterService.error("Fill all required fields"):(this.iosTemplate.template_id=Object(art.v4)(),this.iosTemplate.name=this.templateName,this.iosService.addTemplate(this.server,this.iosTemplate).subscribe((function(e){t.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(got),da(Y2),da(lQ),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-copy-ios-template"]],decls:15,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","placeholder","Name","formControlName","templateName",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Copy IOS router template"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card",5),ga(7,"form",6),ga(8,"mat-form-field",7),ga(9,"input",8),xa("ngModelChange",(function(t){return e.templateName=t})),va(),va(),va(),va(),ga(10,"div",9),ga(11,"button",10),xa("click",(function(){return e.goBack()})),ds(12,"Cancel"),va(),ga(13,"button",11),xa("click",(function(){return e.addTemplate()})),ds(14,"Copy template"),va(),va(),va(),va()),2&t&&(Qi(7),pa("formGroup",e.formGroup),Qi(2),pa("ngModel",e.templateName))},directives:[f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Mvt=function(){function t(t,e,n,i,r,o){this.route=t,this.serverService=e,this.dockerService=n,this.toasterService=i,this.router=r,this.formBuilder=o,this.templateName="",this.templateNameForm=this.formBuilder.group({templateName:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.dockerService.getTemplate(t.server,n).subscribe((function(e){t.dockerTemplate=e,t.templateName="Copy of "+t.dockerTemplate.name}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","docker","templates"])},t.prototype.addTemplate=function(){var t=this;this.templateNameForm.invalid?this.toasterService.error("Fill all required fields"):(this.dockerTemplate.template_id=Object(art.v4)(),this.dockerTemplate.name=this.templateName,this.dockerService.addTemplate(this.server,this.dockerTemplate).subscribe((function(e){t.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(pot),da(Y2),da(lQ),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-copy-docker-template"]],decls:15,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","placeholder","Name","formControlName","templateName",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Copy Docker container template"),va(),va(),va(),ga(5,"div",4),ga(6,"div",5),ga(7,"form",6),ga(8,"mat-form-field",7),ga(9,"input",8),xa("ngModelChange",(function(t){return e.templateName=t})),va(),va(),va(),va(),ga(10,"div",9),ga(11,"button",10),xa("click",(function(){return e.goBack()})),ds(12,"Cancel"),va(),ga(13,"button",11),xa("click",(function(){return e.addTemplate()})),ds(14,"Copy template"),va(),va(),va(),va()),2&t&&(Qi(7),pa("formGroup",e.templateNameForm),Qi(2),pa("ngModel",e.templateName))},directives:[xp,gf,Pp,Y3,s5,cf,mf,Fp,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Tvt=function(){function t(t,e,n,i,r,o){this.route=t,this.serverService=e,this.qemuService=n,this.toasterService=i,this.router=r,this.formBuilder=o,this.templateName="",this.templateNameForm=this.formBuilder.group({templateName:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.qemuService.getTemplate(t.server,n).subscribe((function(e){t.iouTemplate=e,t.templateName="Copy of "+t.iouTemplate.name}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","iou","templates"])},t.prototype.addTemplate=function(){var t=this;this.templateNameForm.invalid?this.toasterService.error("Fill all required fields"):(this.iouTemplate.template_id=Object(art.v4)(),this.iouTemplate.name=this.templateName,this.qemuService.addTemplate(this.server,this.iouTemplate).subscribe((function(e){t.goBack()})))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(vot),da(Y2),da(lQ),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-copy-iou-template"]],decls:15,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","placeholder","Name","formControlName","templateName",3,"ngModel","ngModelChange"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Copy IOU device template"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card",5),ga(7,"form",6),ga(8,"mat-form-field",7),ga(9,"input",8),xa("ngModelChange",(function(t){return e.templateName=t})),va(),va(),va(),va(),ga(10,"div",9),ga(11,"button",10),xa("click",(function(){return e.goBack()})),ds(12,"Cancel"),va(),ga(13,"button",11),xa("click",(function(){return e.addTemplate()})),ds(14,"Copy template"),va(),va(),va(),va()),2&t&&(Qi(7),pa("formGroup",e.templateNameForm),Qi(2),pa("ngModel",e.templateName))},directives:[f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Evt=function(){function t(){}return t.prototype.transform=function(t,e){return t?e?(e=e.toLowerCase(),t.filter((function(t){return t.name.toLowerCase().includes(e)}))):t:[]},t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"namefilter",type:t,pure:!0}),t}(),Pvt=function(){function t(){}return t.prototype.transform=function(t){var e=new Date(1e3*+t),n=e.getHours(),i="0"+e.getMinutes(),r="0"+e.getSeconds(),o=e.getFullYear(),a=e.getMonth()+1,s=e.getDate();return n+":"+i.substr(-2)+":"+r.substr(-2)+" "+s+"/"+a+"/"+o},t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"datefilter",type:t,pure:!0}),t}();function Avt(t,e){1&t&&(ga(0,"mat-header-cell",18),ds(1," Name "),va())}function jvt(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.name," ")}}function Ivt(t,e){1&t&&(ga(0,"mat-header-cell",18),ds(1," Date "),va())}function Dvt(t,e){if(1&t&&(ga(0,"mat-cell"),ds(1),Nc(2,"datefilter"),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",Bc(2,1,n.created_at)," ")}}function Rvt(t,e){1&t&&(ga(0,"mat-header-cell"),ds(1," Actions "),va())}function Lvt(t,e){if(1&t){var n=ka();ga(0,"mat-cell",19),ga(1,"button",20),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().restoreSnapshot(t)})),ga(2,"mat-icon",21),ds(3,"restore"),va(),va(),ga(4,"button",22),xa("click",(function(){Se(n);var t=e.$implicit;return Aa().deleteSnapshot(t)})),ga(5,"mat-icon",23),ds(6,"delete"),va(),va(),va()}}function Fvt(t,e){1&t&&ba(0,"mat-header-row")}function Nvt(t,e){1&t&&ba(0,"mat-row")}var Bvt=function(){function t(t,e,n,i){this.route=t,this.snapshotService=e,this.progressDialogService=n,this.toaster=i,this.displayedColumns=["name","creationDate","actions"]}return t.prototype.ngOnInit=function(){this.projectId=this.route.snapshot.paramMap.get("project_id"),this.server=this.route.snapshot.data.server,this.getSnapshots()},t.prototype.getSnapshots=function(){var t=this;this.snapshotService.list(this.server,this.projectId).subscribe((function(e){t.snapshots=e}))},t.prototype.restoreSnapshot=function(t){var e=this,n=this.snapshotService.restore(this.server,this.projectId,t.snapshot_id.toString()),i=this.progressDialogService.open(),r=n.subscribe((function(n){e.toaster.success("Snapshot "+t.name+" has been restored."),i.close()}));i.afterClosed().subscribe((function(t){t===plt.CANCELLED&&r.unsubscribe()}))},t.prototype.deleteSnapshot=function(t){var e=this;this.snapshotService.delete(this.server,this.projectId,t.snapshot_id.toString()).subscribe((function(){e.getSnapshots(),e.toaster.success("Snapshot "+t.name+" has been deleted.")}))},t.prototype.sortData=function(t){if(t.active&&""!==t.direction){var e=this.snapshots.slice();this.snapshots=e.sort((function(e,n){var i="asc"===t.direction;return"name"===t.active?function(t,e,n){return((t=t.toLowerCase())<(e=e.toLowerCase())?-1:1)*(n?1:-1)}(e.name,n.name,i):"creationDate"===t.active?function(t,e,n){return(t<e?-1:1)*(n?1:-1)}(+e.created_at,+n.created_at,!i):0}))}},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(olt),da(mlt),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-list-of-snapshots"]],decls:23,vars:7,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"filter-field"],["matInput","","placeholder","Filter",3,"ngModel","ngModelChange"],["matSort","",1,"mat-table",3,"dataSource","matSortChange"],["table",""],["matColumnDef","name"],["mat-sort-header","",4,"matHeaderCellDef"],[4,"matCellDef"],["matColumnDef","creationDate"],["matColumnDef","actions"],[4,"matHeaderCellDef"],["style","text-align: right",4,"matCellDef"],[4,"matHeaderRowDef"],[4,"matRowDef","matRowDefColumns"],["mat-sort-header",""],[2,"text-align","right"],["mat-icon-button","","matTooltip","Restore snapshot","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Restore snapshot"],["mat-icon-button","","matTooltip","Delete snapshot","matTooltipClass","custom-tooltip",3,"click"],["aria-label","Delete snapshot"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Snapshots"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card"),ga(7,"mat-form-field",5),ga(8,"input",6),xa("ngModelChange",(function(t){return e.searchText=t})),va(),va(),ga(9,"mat-table",7,8),xa("matSortChange",(function(t){return e.sortData(t)})),Nc(11,"namefilter"),ya(12,9),ua(13,Avt,2,0,"mat-header-cell",10),ua(14,jvt,2,1,"mat-cell",11),_a(),ya(15,12),ua(16,Ivt,2,0,"mat-header-cell",10),ua(17,Dvt,3,3,"mat-cell",11),_a(),ya(18,13),ua(19,Rvt,2,0,"mat-header-cell",14),ua(20,Lvt,7,0,"mat-cell",15),_a(),ua(21,Fvt,1,0,"mat-header-row",16),ua(22,Nvt,1,0,"mat-row",17),va(),va(),va(),va()),2&t&&(Qi(8),pa("ngModel",e.searchText),Qi(1),pa("dataSource",Hc(11,4,e.snapshots,e.searchText)),Qi(12),pa("matHeaderRowDef",e.displayedColumns),Qi(1),pa("matRowDefColumns",e.displayedColumns))},directives:[f3,Y3,s5,cf,mf,Sp,$5,mat,n4,t4,J5,a4,c4,i4,wat,o4,a2,k4,x2,l4,h4],pipes:[Evt,Pvt],styles:[".filter-field[_ngcontent-%COMP%]{width:100%}.mat-table[_ngcontent-%COMP%]{margin:-16px!important}"]}),t}(),Hvt=function(){function t(t,e,n){this.router=t,this.consoleService=e,this.toasterService=n,this.consoleForm=new dp({command:new hp("")})}return t.prototype.ngOnInit=function(){this.consoleForm.get("command").setValue(this.consoleService.command)},t.prototype.goBack=function(){this.router.navigate(["/settings"])},t.prototype.save=function(){this.consoleService.command=this.consoleForm.value.command,this.toasterService.success("Console command has been updated."),this.goBack()},t.\u0275fac=function(e){return new(e||t)(da(lQ),da(edt),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-console"]],decls:30,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[3,"formGroup"],[1,"form-field","full-width-field"],["matInput","","formControlName","command","placeholder","Command"],[1,"help"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Console settings"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card"),ga(7,"form",5),ga(8,"mat-form-field",6),ba(9,"textarea",7),va(),ga(10,"div",8),ds(11,"The following variables are replaced by GNS3:"),ba(12,"br"),ds(13," %h: console IP or hostname"),ba(14,"br"),ds(15," %p: console port"),ba(16,"br"),ds(17," %s: path of the serial connection"),ba(18,"br"),ds(19," %d: title of the console"),ba(20,"br"),ds(21," %i: Project UUID"),ba(22,"br"),ds(23," %c: server URL (http://user:password@server:port) "),va(),va(),va(),ga(24,"div",9),ga(25,"button",10),xa("click",(function(){return e.goBack()})),ds(26,"Cancel"),va(),ga(27,"button",11),xa("click",(function(){return e.save()})),ds(28,"Save"),va(),ba(29,"br"),va(),va(),va()),2&t&&(Qi(7),pa("formGroup",e.consoleForm))},directives:[f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2],styles:[".help[_ngcontent-%COMP%]{font-size:14px}"]}),t}(),zvt=function(){function t(t){this.httpClient=t,this.thirdpartylicenses="",this.releasenotes=""}return t.prototype.ngOnInit=function(){var t=this;this.httpClient.get(window.location.href+"/3rdpartylicenses.txt",{responseType:"text"}).subscribe((function(e){t.thirdpartylicenses=e.replace(new RegExp("\n","g"),"<br />")}),(function(e){404===e.status&&(t.thirdpartylicenses="File not found")})),this.httpClient.get("ReleaseNotes.txt",{responseType:"text"}).subscribe((function(e){t.releasenotes=e.replace(new RegExp("\n","g"),"<br />")}))},t.\u0275fac=function(e){return new(e||t)(da(Rg))},t.\u0275cmp=Ht({type:t,selectors:[["app-help"]],decls:36,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"default-content"],[1,"container","mat-elevation-z8"],[3,"innerHTML"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"h1"),ds(3,"Help"),va(),va(),ga(4,"div",2),ga(5,"div",3),ga(6,"mat-accordion"),ga(7,"mat-expansion-panel"),ga(8,"mat-expansion-panel-header"),ga(9,"mat-panel-title"),ds(10," Useful shortcuts "),va(),va(),ga(11,"mat-list"),ga(12,"mat-list-item"),ds(13," ctrl + + to zoom in "),va(),ga(14,"mat-list-item"),ds(15," ctrl + - to zoom out "),va(),ga(16,"mat-list-item"),ds(17," ctrl + 0 to reset zoom "),va(),ga(18,"mat-list-item"),ds(19," ctrl + h to hide toolbar "),va(),ga(20,"mat-list-item"),ds(21," ctrl + a to select all items on map "),va(),ga(22,"mat-list-item"),ds(23," ctrl + shift + a to deselect all items on map "),va(),ga(24,"mat-list-item"),ds(25," ctrl + shift + s to go to preferences "),va(),va(),va(),ga(26,"mat-expansion-panel"),ga(27,"mat-expansion-panel-header"),ga(28,"mat-panel-title"),ds(29," Third party components "),va(),va(),ba(30,"div",4),va(),ga(31,"mat-expansion-panel"),ga(32,"mat-expansion-panel-header"),ga(33,"mat-panel-title"),ds(34," Release notes "),va(),va(),ba(35,"div",4),va(),va(),va(),va(),va()),2&t&&(Qi(30),pa("innerHTML",e.thirdpartylicenses,Ti),Qi(5),pa("innerHTML",e.releasenotes,Ti))},directives:[Sdt,ydt,wdt,Cdt,_8,S8],styles:[""]}),t}(),Vvt=function(){function t(){}return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["app-page-not-found"]],decls:7,vars:0,consts:[[1,"content"],[1,"default-header"],["mat-button","","routerLink","/servers"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ba(2,"br"),ga(3,"h1"),ds(4,"404 Page not found"),va(),ga(5,"button",2),ds(6,"Navigate to homepage"),va(),va(),va())},directives:[a2,hQ],styles:["div[_ngcontent-%COMP%]{text-align:center}"]}),t}(),Uvt=function(){function t(t){this.httpServer=t}return t.prototype.getGns3vm=function(t){return this.httpServer.get(t,"/gns3vm")},t.prototype.updateGns3vm=function(t,e){return this.httpServer.put(t,"/gns3vm",e)},t.prototype.getGns3vmEngines=function(t){return this.httpServer.get(t,"/gns3vm/engines")},t.prototype.getVms=function(t,e){return this.httpServer.get(t,"/gns3vm/engines/"+e+"/vms")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function qvt(t,e){if(1&t&&(ga(0,"mat-option",18),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.engine_id),Qi(1),ps(" ",n.name," ")}}function Gvt(t,e){if(1&t&&(ga(0,"mat-option",18),ds(1),va()),2&t){var n=e.$implicit;pa("value",n.vmname),Qi(1),ps(" ",n.vmname," ")}}var Wvt=function(){return{standalone:!0}};function Kvt(t,e){if(1&t){var n=ka();ga(0,"mat-checkbox",10),xa("ngModelChange",(function(t){return Se(n),Aa(2).gns3vm.headless=t})),ds(1," Run the VM in headless mode "),va()}if(2&t){var i=Aa(2);pa("ngModelOptions",jc(2,Wvt))("ngModel",i.gns3vm.headless)}}function Xvt(t,e){if(1&t){var n=ka();ga(0,"mat-form-field",21),ga(1,"input",25),xa("ngModelChange",(function(t){return Se(n),Aa(3).port=t})),va(),va()}if(2&t){var i=Aa(3);Qi(1),pa("ngModelOptions",jc(2,Wvt))("ngModel",i.port)}}function Yvt(t,e){if(1&t&&(ga(0,"form",19),ua(1,Xvt,2,3,"mat-form-field",20),ga(2,"mat-form-field",21),ba(3,"input",22),ga(4,"span",23),ds(5,"MB"),va(),va(),ga(6,"mat-form-field",21),ba(7,"input",24),va(),va()),2&t){var n=Aa(2);pa("formGroup",n.vmForm),Qi(1),pa("ngIf","virtualbox"===n.gns3vm.engine||"vmware"===n.gns3vm.engine)}}function Zvt(t,e){if(1&t){var n=ka();ga(0,"mat-radio-group",26),xa("ngModelChange",(function(t){return Se(n),Aa(2).gns3vm.when_exit=t})),ga(1,"mat-radio-button",27),xa("click",(function(){return Se(n),Aa(2).setCloseAction("keep")})),ds(2,"keep the GNS3 VM running"),va(),ga(3,"mat-radio-button",28),xa("click",(function(){return Se(n),Aa(2).setCloseAction("suspend")})),ds(4,"suspend the GNS3 VM"),va(),ga(5,"mat-radio-button",29),xa("click",(function(){return Se(n),Aa(2).setCloseAction("stop")})),ds(6,"stop the GNS3 VM"),va(),va()}2&t&&pa("ngModel",Aa(2).gns3vm.when_exit)}function Qvt(t,e){if(1&t){var n=ka();ga(0,"mat-card",9),ga(1,"mat-checkbox",10),xa("ngModelChange",(function(t){return Se(n),Aa().gns3vm.enable=t})),ds(2," Enable the GNS3 VM "),va(),ga(3,"mat-form-field",11),ga(4,"mat-select",12),xa("selectionChange",(function(t){return Se(n),Aa().changeVmEngine(t)}))("ngModelChange",(function(t){return Se(n),Aa().gns3vm.engine=t})),ua(5,qvt,2,2,"mat-option",13),va(),va(),ga(6,"mat-form-field",11),ga(7,"mat-select",14),xa("ngModelChange",(function(t){return Se(n),Aa().gns3vm.vmname=t})),ua(8,Gvt,2,2,"mat-option",13),va(),va(),ua(9,Kvt,2,3,"mat-checkbox",15),ua(10,Yvt,8,2,"form",16),ua(11,Zvt,7,1,"mat-radio-group",17),va()}if(2&t){var i=Aa();Qi(1),pa("ngModelOptions",jc(11,Wvt))("ngModel",i.gns3vm.enable),Qi(3),pa("ngModelOptions",jc(12,Wvt))("ngModel",i.gns3vm.engine),Qi(1),pa("ngForOf",i.vmEngines),Qi(2),pa("ngModelOptions",jc(13,Wvt))("ngModel",i.gns3vm.vmname),Qi(1),pa("ngForOf",i.vms),Qi(1),pa("ngIf","virtualbox"===i.gns3vm.engine||"vmware"===i.gns3vm.engine),Qi(1),pa("ngIf","remote"!==i.gns3vm.engine),Qi(1),pa("ngIf","remote"!==i.gns3vm.engine)}}var $vt=function(){function t(t,e,n,i,r,o){this.route=t,this.serverService=e,this.gns3vmService=n,this.router=i,this.formBuilder=r,this.toasterService=o,this.vms=[],this.vmForm=this.formBuilder.group({ram:new hp(null,[kf.required]),vcpus:new hp(null,[kf.required])})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.gns3vmService.getGns3vm(t.server).subscribe((function(e){t.gns3vm=e,t.vmForm.controls.ram.setValue(t.gns3vm.ram),t.vmForm.controls.vcpus.setValue(t.gns3vm.vcpus),t.gns3vm.port&&(t.port=t.gns3vm.port),t.gns3vmService.getGns3vmEngines(t.server).subscribe((function(e){t.vmEngines=e})),t.gns3vmService.getVms(t.server,t.gns3vm.engine).subscribe((function(e){t.vms=e}))}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences"])},t.prototype.setCloseAction=function(t){this.gns3vm.when_exit=t},t.prototype.changeVmEngine=function(t){var e=this;this.gns3vmService.getVms(this.server,t.value).subscribe((function(t){e.vms=t}),(function(t){}))},t.prototype.save=function(){var t=this;this.vmForm.valid&&this.gns3vm.vmname||"remote"===this.gns3vm.engine&&this.gns3vm.vmname?(this.gns3vm.ram=this.vmForm.get("ram").value,this.gns3vm.vcpus=this.vmForm.get("vcpus").value,this.port&&(this.gns3vm.port=this.port),this.gns3vmService.updateGns3vm(this.server,this.gns3vm).subscribe((function(){t.toasterService.success("GNS3 VM updated.")})),this.goBack()):this.toasterService.error("Fill all required fields with correct values.")},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(Uvt),da(lQ),da(Jp),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-gns3vm"]],decls:12,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],["class","matCard",4,"ngIf"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[1,"matCard"],[3,"ngModelOptions","ngModel","ngModelChange"],[1,"select"],["placeholder","Virtualization engine",3,"ngModelOptions","ngModel","selectionChange","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["placeholder","VM name",3,"ngModelOptions","ngModel","ngModelChange"],[3,"ngModelOptions","ngModel","ngModelChange",4,"ngIf"],[3,"formGroup",4,"ngIf"],["aria-label","Actions when closing GNS3","class","radio-selection",3,"ngModel","ngModelChange",4,"ngIf"],[3,"value"],[3,"formGroup"],["class","form-field",4,"ngIf"],[1,"form-field"],["matInput","","formControlName","ram","type","number","placeholder","RAM"],["matSuffix",""],["matInput","","formControlName","vcpus","type","number","placeholder","vCPUs"],["matInput","","type","number","placeholder","Port",3,"ngModelOptions","ngModel","ngModelChange"],["aria-label","Actions when closing GNS3",1,"radio-selection",3,"ngModel","ngModelChange"],["value","keep",3,"click"],["value","suspend",3,"click"],["value","stop",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"GNS3 VM preferences"),va(),va(),va(),ga(5,"div",4),ua(6,Qvt,12,14,"mat-card",5),ga(7,"div",6),ga(8,"button",7),xa("click",(function(){return e.goBack()})),ds(9,"Cancel"),va(),ga(10,"button",8),xa("click",(function(){return e.save()})),ds(11,"Save"),va(),va(),va(),va()),2&t&&(Qi(6),pa("ngIf",e.gns3vm))},directives:[Ah,a2,f3,F5,mf,Sp,Y3,O5,Eh,EJ,xp,gf,Pp,s5,cf,Ef,Fp,q3,A6,D6],styles:[".form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.radio-selection[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"]}),t}(),Jvt=function(){function t(t,e,n,i,r){this.serverService=t,this.serverDatabase=e,this.route=n,this.router=i,this.toasterService=r}return t.prototype.ngOnInit=function(){return UQ(this,void 0,void 0,(function(){var t=this;return qQ(this,(function(e){return this.serverService.isServiceInitialized&&this.getServers(),this.serverService.serviceInitialized.subscribe((function(e){return UQ(t,void 0,void 0,(function(){return qQ(this,(function(t){return e&&this.getServers(),[2]}))}))})),[2]}))}))},t.prototype.getServers=function(){return UQ(this,void 0,void 0,(function(){var t,e,n,i,r,o,a=this;return qQ(this,(function(s){switch(s.label){case 0:return t=this.route.snapshot.paramMap.get("server_ip"),e=+this.route.snapshot.paramMap.get("server_port"),n=this.route.snapshot.paramMap.get("project_id"),[4,this.serverService.findAll()];case 1:return i=s.sent(),(r=i.filter((function(n){return n.host===t&&n.port===e}))[0])?this.router.navigate(["/server",r.id,"project",n]):((o=new BQ).host=t,o.port=e,o.location="bundled",o.name=t,this.serverService.create(o).then((function(t){a.router.navigate(["/server",t.id,"project",n])}))),[2]}}))}))},t.\u0275fac=function(e){return new(e||t)(da(ZQ),da(Wut),da(ZY),da(lQ),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-direct-link"]],decls:0,vars:0,template:function(t,e){},styles:[""],encapsulation:2}),t}();function tbt(t,e){if(1&t&&(Qe(),ga(0,"linearGradient"),ba(1,"stop",5),ba(2,"stop",6),va()),2&t){var n=Aa(2);oa("id",n.svg.outerLinearGradient.id),Qi(1),oa("stop-color",n.svg.outerLinearGradient.colorStop1)("stop-opacity",1),Qi(1),oa("stop-color",n.svg.outerLinearGradient.colorStop2)("stop-opacity",1)}}function ebt(t,e){if(1&t&&(Qe(),ga(0,"radialGradient"),ba(1,"stop",5),ba(2,"stop",6),va()),2&t){var n=Aa(2);oa("id",n.svg.radialGradient.id),Qi(1),oa("stop-color",n.svg.radialGradient.colorStop1)("stop-opacity",1),Qi(1),oa("stop-color",n.svg.radialGradient.colorStop2)("stop-opacity",1)}}function nbt(t,e){if(1&t&&(Qe(),ba(0,"circle")),2&t){var n=Aa(3);oa("cx",n.svg.backgroundCircle.cx)("cy",n.svg.backgroundCircle.cy)("r",n.svg.backgroundCircle.r)("fill",n.svg.backgroundCircle.fill)("fill-opacity",n.svg.backgroundCircle.fillOpacity)("stroke",n.svg.backgroundCircle.stroke)("stroke-width",n.svg.backgroundCircle.strokeWidth)}}function ibt(t,e){if(1&t&&(Qe(),ba(0,"circle")),2&t){var n=Aa(3);ca("fill","url(#",n.svg.radialGradient.id,")"),oa("cx",n.svg.backgroundCircle.cx)("cy",n.svg.backgroundCircle.cy)("r",n.svg.backgroundCircle.r)("fill-opacity",n.svg.backgroundCircle.fillOpacity)("stroke",n.svg.backgroundCircle.stroke)("stroke-width",n.svg.backgroundCircle.strokeWidth)}}function rbt(t,e){if(1&t&&(Qe(),ya(0),ua(1,nbt,1,7,"circle",2),ua(2,ibt,1,7,"circle",2),_a()),2&t){var n=Aa(2);Qi(1),pa("ngIf",!n.options.backgroundGradient),Qi(1),pa("ngIf",n.options.backgroundGradient)}}function obt(t,e){if(1&t&&(Qe(),ba(0,"circle")),2&t){var n=Aa(2);oa("cx",n.svg.circle.cx)("cy",n.svg.circle.cy)("r",n.svg.circle.r)("fill",n.svg.circle.fill)("stroke",n.svg.circle.stroke)("stroke-width",n.svg.circle.strokeWidth)}}function abt(t,e){if(1&t&&(Qe(),ba(0,"path")),2&t){var n=Aa(3);oa("d",n.svg.path.d)("stroke",n.svg.path.stroke)("stroke-width",n.svg.path.strokeWidth)("stroke-linecap",n.svg.path.strokeLinecap)("fill",n.svg.path.fill)}}function sbt(t,e){if(1&t&&(Qe(),ba(0,"path")),2&t){var n=Aa(3);ca("stroke","url(#",n.svg.outerLinearGradient.id,")"),oa("d",n.svg.path.d)("stroke-width",n.svg.path.strokeWidth)("stroke-linecap",n.svg.path.strokeLinecap)("fill",n.svg.path.fill)}}function cbt(t,e){if(1&t&&(Qe(),ya(0),ua(1,abt,1,5,"path",2),ua(2,sbt,1,5,"path",2),_a()),2&t){var n=Aa(2);Qi(1),pa("ngIf",!n.options.outerStrokeGradient),Qi(1),pa("ngIf",n.options.outerStrokeGradient)}}function lbt(t,e){if(1&t&&(Qe(),ga(0,"tspan"),ds(1),va()),2&t){var n=e.$implicit,i=Aa(4);oa("x",i.svg.title.x)("y",i.svg.title.y)("dy",n.dy)("font-size",i.svg.title.fontSize)("font-weight",i.svg.title.fontWeight)("fill",i.svg.title.color),Qi(1),fs(n.span)}}function ubt(t,e){if(1&t&&(Qe(),ya(0),ua(1,lbt,2,7,"tspan",8),_a()),2&t){var n=Aa(3);Qi(1),pa("ngForOf",n.svg.title.tspans)}}function hbt(t,e){if(1&t&&(Qe(),ga(0,"tspan"),ds(1),va()),2&t){var n=Aa(3);oa("font-size",n.svg.units.fontSize)("font-weight",n.svg.units.fontWeight)("fill",n.svg.units.color),Qi(1),fs(n.svg.units.text)}}function dbt(t,e){if(1&t&&(Qe(),ga(0,"tspan"),ds(1),va()),2&t){var n=e.$implicit,i=Aa(4);oa("x",i.svg.subtitle.x)("y",i.svg.subtitle.y)("dy",n.dy)("font-size",i.svg.subtitle.fontSize)("font-weight",i.svg.subtitle.fontWeight)("fill",i.svg.subtitle.color),Qi(1),fs(n.span)}}function fbt(t,e){if(1&t&&(Qe(),ya(0),ua(1,dbt,2,7,"tspan",8),_a()),2&t){var n=Aa(3);Qi(1),pa("ngForOf",n.svg.subtitle.tspans)}}function pbt(t,e){if(1&t&&(Qe(),ga(0,"text",7),ua(1,ubt,2,1,"ng-container",2),ua(2,hbt,2,4,"tspan",2),ua(3,fbt,2,1,"ng-container",2),va()),2&t){var n=Aa(2);oa("x",n.svg.circle.cx)("y",n.svg.circle.cy)("text-anchor",n.svg.title.textAnchor),Qi(1),pa("ngIf",n.options.showTitle),Qi(1),pa("ngIf",n.options.showUnits),Qi(1),pa("ngIf",n.options.showSubtitle)}}function mbt(t,e){if(1&t&&(Qe(),ba(0,"image",9)),2&t){var n=Aa(2);oa("height",n.svg.image.height)("width",n.svg.image.width)("href",n.svg.image.src,null,"xlink")("x",n.svg.image.x)("y",n.svg.image.y)}}function gbt(t,e){if(1&t){var n=ka();Qe(),ga(0,"svg",1),xa("click",(function(t){return Se(n),Aa().emitClickEvent(t)})),ga(1,"defs"),ua(2,tbt,3,5,"linearGradient",2),ua(3,ebt,3,5,"radialGradient",2),va(),ua(4,rbt,3,2,"ng-container",2),ua(5,obt,1,6,"circle",2),ua(6,cbt,3,2,"ng-container",2),ua(7,pbt,4,6,"text",3),ua(8,mbt,1,5,"image",4),va()}if(2&t){var i=Aa();oa("viewBox",i.svg.viewBox)("height",i.svg.height)("width",i.svg.width)("class",i.options.class),Qi(2),pa("ngIf",i.options.outerStrokeGradient),Qi(1),pa("ngIf",i.options.backgroundGradient),Qi(1),pa("ngIf",i.options.showBackground),Qi(1),pa("ngIf",i.options.showInnerStroke),Qi(1),pa("ngIf",i.options.percent-0!=0||i.options.showZeroOuterStroke),Qi(1),pa("ngIf",!i.options.showImage&&(i.options.showTitle||i.options.showUnits||i.options.showSubtitle)),Qi(1),pa("ngIf",i.options.showImage)}}var vbt,bbt=function t(){Object(m.a)(this,t),this.class="",this.backgroundGradient=!1,this.backgroundColor="transparent",this.backgroundGradientStopColor="transparent",this.backgroundOpacity=1,this.backgroundStroke="transparent",this.backgroundStrokeWidth=0,this.backgroundPadding=5,this.percent=0,this.radius=90,this.space=4,this.toFixed=0,this.maxPercent=1e3,this.renderOnClick=!0,this.units="%",this.unitsFontSize="10",this.unitsFontWeight="normal",this.unitsColor="#444444",this.outerStrokeGradient=!1,this.outerStrokeWidth=8,this.outerStrokeColor="#78C000",this.outerStrokeGradientStopColor="transparent",this.outerStrokeLinecap="round",this.innerStrokeColor="#C7E596",this.innerStrokeWidth=4,this.titleFormat=void 0,this.title="auto",this.titleColor="#444444",this.titleFontSize="20",this.titleFontWeight="normal",this.subtitleFormat=void 0,this.subtitle="progress",this.subtitleColor="#A9A9A9",this.subtitleFontSize="10",this.subtitleFontWeight="normal",this.imageSrc=void 0,this.imageHeight=void 0,this.imageWidth=void 0,this.animation=!0,this.animateTitle=!0,this.animateSubtitle=!1,this.animationDuration=500,this.showTitle=!0,this.showSubtitle=!0,this.showUnits=!0,this.showImage=!1,this.showBackground=!0,this.showInnerStroke=!0,this.clockwise=!0,this.responsive=!1,this.startFromZero=!0,this.showZeroOuterStroke=!0,this.lazy=!1},ybt=function(){var t=function(){function t(e,n,i){var r=this;Object(m.a)(this,t),this.elRef=n,this.document=i,this.onClick=new Uc,this.svgElement=null,this.isInViewport=!1,this.onViewportChanged=new Uc,this._viewportChangedSubscriber=null,this.options=new bbt,this.defaultOptions=new bbt,this._lastPercent=0,this._gradientUUID=null,this.render=function(){r.applyOptions(),r.options.lazy?(null===r.svgElement&&r.draw(r._lastPercent),r.isInViewport&&(r.options.animation&&r.options.animationDuration>0?r.animate(r._lastPercent,r.options.percent):r.draw(r.options.percent),r._lastPercent=r.options.percent)):(r.options.animation&&r.options.animationDuration>0?r.animate(r._lastPercent,r.options.percent):r.draw(r.options.percent),r._lastPercent=r.options.percent)},this.polarToCartesian=function(t,e,n,i){var r=i*Math.PI/180;return{x:t+Math.sin(r)*n,y:e-Math.cos(r)*n}},this.draw=function(t){var e=(t=void 0===t?r.options.percent:Math.abs(t))>100?100:t,n=2*r.options.radius+2*r.options.outerStrokeWidth;r.options.showBackground&&(n+=2*r.options.backgroundStrokeWidth+r.max(0,2*r.options.backgroundPadding));var i,o,a={x:n/2,y:n/2},s={x:a.x,y:a.y-r.options.radius},c=r.polarToCartesian(a.x,a.y,r.options.radius,360*(r.options.clockwise?e:100-e)/100);if(100===e&&(c.x=c.x+(r.options.clockwise?-.01:.01)),e>50){var h=l(r.options.clockwise?[1,1]:[1,0],2);i=h[0],o=h[1]}else{var f=l(r.options.clockwise?[0,1]:[0,0],2);i=f[0],o=f[1]}var p=r.options.animateTitle?t:r.options.percent,m=p>r.options.maxPercent?"".concat(r.options.maxPercent.toFixed(r.options.toFixed),"+"):p.toFixed(r.options.toFixed),g=r.options.animateSubtitle?t:r.options.percent,v={x:a.x,y:a.y,textAnchor:"middle",color:r.options.titleColor,fontSize:r.options.titleFontSize,fontWeight:r.options.titleFontWeight,texts:[],tspans:[]};if(void 0!==r.options.titleFormat&&"Function"===r.options.titleFormat.constructor.name){var b=r.options.titleFormat(p);b instanceof Array?v.texts=Object(u.a)(b):v.texts.push(b.toString())}else"auto"===r.options.title?v.texts.push(m):r.options.title instanceof Array?v.texts=Object(u.a)(r.options.title):v.texts.push(r.options.title.toString());var y={x:a.x,y:a.y,textAnchor:"middle",color:r.options.subtitleColor,fontSize:r.options.subtitleFontSize,fontWeight:r.options.subtitleFontWeight,texts:[],tspans:[]};if(void 0!==r.options.subtitleFormat&&"Function"===r.options.subtitleFormat.constructor.name){var _=r.options.subtitleFormat(g);_ instanceof Array?y.texts=Object(u.a)(_):y.texts.push(_.toString())}else r.options.subtitle instanceof Array?y.texts=Object(u.a)(r.options.subtitle):y.texts.push(r.options.subtitle.toString());var w={text:"".concat(r.options.units),fontSize:r.options.unitsFontSize,fontWeight:r.options.unitsFontWeight,color:r.options.unitsColor},k=0,C=1;if(r.options.showTitle&&(k+=v.texts.length),r.options.showSubtitle&&(k+=y.texts.length),r.options.showTitle){var S,x=d(v.texts);try{for(x.s();!(S=x.n()).done;)v.tspans.push({span:S.value,dy:r.getRelativeY(C,k)}),C++}catch(T){x.e(T)}finally{x.f()}}if(r.options.showSubtitle){var O,M=d(y.texts);try{for(M.s();!(O=M.n()).done;)y.tspans.push({span:O.value,dy:r.getRelativeY(C,k)}),C++}catch(T){M.e(T)}finally{M.f()}}null===r._gradientUUID&&(r._gradientUUID=r.uuid()),r.svg={viewBox:"0 0 ".concat(n," ").concat(n),width:r.options.responsive?"100%":n,height:r.options.responsive?"100%":n,backgroundCircle:{cx:a.x,cy:a.y,r:r.options.radius+r.options.outerStrokeWidth/2+r.options.backgroundPadding,fill:r.options.backgroundColor,fillOpacity:r.options.backgroundOpacity,stroke:r.options.backgroundStroke,strokeWidth:r.options.backgroundStrokeWidth},path:{d:"M ".concat(s.x," ").concat(s.y,"\n A ").concat(r.options.radius," ").concat(r.options.radius," 0 ").concat(i," ").concat(o," ").concat(c.x," ").concat(c.y),stroke:r.options.outerStrokeColor,strokeWidth:r.options.outerStrokeWidth,strokeLinecap:r.options.outerStrokeLinecap,fill:"none"},circle:{cx:a.x,cy:a.y,r:r.options.radius-r.options.space-r.options.outerStrokeWidth/2-r.options.innerStrokeWidth/2,fill:"none",stroke:r.options.innerStrokeColor,strokeWidth:r.options.innerStrokeWidth},title:v,units:w,subtitle:y,image:{x:a.x-r.options.imageWidth/2,y:a.y-r.options.imageHeight/2,src:r.options.imageSrc,width:r.options.imageWidth,height:r.options.imageHeight},outerLinearGradient:{id:"outer-linear-"+r._gradientUUID,colorStop1:r.options.outerStrokeColor,colorStop2:"transparent"===r.options.outerStrokeGradientStopColor?"#FFF":r.options.outerStrokeGradientStopColor},radialGradient:{id:"radial-"+r._gradientUUID,colorStop1:r.options.backgroundColor,colorStop2:"transparent"===r.options.backgroundGradientStopColor?"#FFF":r.options.backgroundGradientStopColor}}},this.getAnimationParameters=function(t,e){var n,i,o,a=r.options.startFromZero||t<0?0:t,s=e<0?0:r.min(e,r.options.maxPercent),c=Math.abs(Math.round(s-a));return c>=100?(n=100,i=r.options.animateTitle||r.options.animateSubtitle?Math.round(c/n):1):(n=c,i=1),(o=Math.round(r.options.animationDuration/n))<10&&(n=r.options.animationDuration/(o=10),i=!r.options.animateTitle&&!r.options.animateSubtitle&&c>100?Math.round(100/n):Math.round(c/n)),i<1&&(i=1),{times:n,step:i,interval:o}},this.animate=function(t,e){r._timerSubscription&&!r._timerSubscription.closed&&r._timerSubscription.unsubscribe();var n=r.options.startFromZero?0:t,i=e,o=r.getAnimationParameters(n,i),a=o.step,s=o.interval,c=n;r._timerSubscription=n<i?Object(l1.a)(0,s).subscribe((function(){(c+=a)<=i?!r.options.animateTitle&&!r.options.animateSubtitle&&c>=100?(r.draw(i),r._timerSubscription.unsubscribe()):r.draw(c):(r.draw(i),r._timerSubscription.unsubscribe())})):Object(l1.a)(0,s).subscribe((function(){(c-=a)>=i?!r.options.animateTitle&&!r.options.animateSubtitle&&i>=100?(r.draw(i),r._timerSubscription.unsubscribe()):r.draw(c):(r.draw(i),r._timerSubscription.unsubscribe())}))},this.emitClickEvent=function(t){r.options.renderOnClick&&r.animate(0,r.options.percent),r.onClick.emit(t)},this.applyOptions=function(){for(var t=0,e=Object.keys(r.options);t<e.length;t++){var n=e[t];r.hasOwnProperty(n)&&void 0!==r[n]?r.options[n]=r[n]:r.templateOptions&&void 0!==r.templateOptions[n]&&(r.options[n]=r.templateOptions[n])}r.options.radius=Math.abs(+r.options.radius),r.options.space=+r.options.space,r.options.percent=+r.options.percent>0?+r.options.percent:0,r.options.maxPercent=Math.abs(+r.options.maxPercent),r.options.animationDuration=Math.abs(r.options.animationDuration),r.options.outerStrokeWidth=Math.abs(+r.options.outerStrokeWidth),r.options.innerStrokeWidth=Math.abs(+r.options.innerStrokeWidth),r.options.backgroundPadding=+r.options.backgroundPadding},this.getRelativeY=function(t,e){return(1*(t-e/2)-.18).toFixed(2)+"em"},this.min=function(t,e){return t<e?t:e},this.max=function(t,e){return t>e?t:e},this.uuid=function(){var t=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var n=(t+16*Math.random())%16|0;return t=Math.floor(t/16),("x"==e?n:3&n|8).toString(16)}))},this.findSvgElement=function(){if(null===this.svgElement){var t=this.elRef.nativeElement.getElementsByTagName("svg");t.length>0&&(this.svgElement=t[0])}},this.checkViewport=function(){r.findSvgElement();var t=r.isInViewport;r.isInViewport=r.isElementInViewport(r.svgElement),t!==r.isInViewport&&r.onViewportChanged.emit({oldValue:t,newValue:r.isInViewport})},this.onScroll=function(t){r.checkViewport()},this.loadEventsForLazyMode=function(){if(r.options.lazy){r.document.addEventListener("scroll",r.onScroll,!0),r.window.addEventListener("resize",r.onScroll,!0),null===r._viewportChangedSubscriber&&(r._viewportChangedSubscriber=r.onViewportChanged.subscribe((function(t){t.newValue&&r.render()})));var t=Object(l1.a)(0,50).subscribe((function(){null===r.svgElement?r.checkViewport():t.unsubscribe()}))}},this.unloadEventsForLazyMode=function(){r.document.removeEventListener("scroll",r.onScroll,!0),r.window.removeEventListener("resize",r.onScroll,!0),null!==r._viewportChangedSubscriber&&(r._viewportChangedSubscriber.unsubscribe(),r._viewportChangedSubscriber=null)},this.document=i,this.window=this.document.defaultView,Object.assign(this.options,e),Object.assign(this.defaultOptions,e)}return Object(g.a)(t,[{key:"isDrawing",value:function(){return this._timerSubscription&&!this._timerSubscription.closed}},{key:"isElementInViewport",value:function(t){if(null==t)return!1;var e,n=t.getBoundingClientRect(),i=t.parentNode;do{if(e=i.getBoundingClientRect(),n.top>=e.bottom)return!1;if(n.bottom<=e.top)return!1;if(n.left>=e.right)return!1;if(n.right<=e.left)return!1;i=i.parentNode}while(i!=this.document.body);return!(n.top>=(this.window.innerHeight||this.document.documentElement.clientHeight)||n.bottom<=0||n.left>=(this.window.innerWidth||this.document.documentElement.clientWidth)||n.right<=0)}},{key:"ngOnInit",value:function(){this.loadEventsForLazyMode()}},{key:"ngOnDestroy",value:function(){this.unloadEventsForLazyMode()}},{key:"ngOnChanges",value:function(t){this.render(),"lazy"in t&&(t.lazy.currentValue?this.loadEventsForLazyMode():this.unloadEventsForLazyMode())}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(bbt),da(Us),da(du))},t.\u0275cmp=Ht({type:t,selectors:[["circle-progress"]],inputs:{name:"name",class:"class",backgroundGradient:"backgroundGradient",backgroundColor:"backgroundColor",backgroundGradientStopColor:"backgroundGradientStopColor",backgroundOpacity:"backgroundOpacity",backgroundStroke:"backgroundStroke",backgroundStrokeWidth:"backgroundStrokeWidth",backgroundPadding:"backgroundPadding",radius:"radius",space:"space",percent:"percent",toFixed:"toFixed",maxPercent:"maxPercent",renderOnClick:"renderOnClick",units:"units",unitsFontSize:"unitsFontSize",unitsFontWeight:"unitsFontWeight",unitsColor:"unitsColor",outerStrokeGradient:"outerStrokeGradient",outerStrokeWidth:"outerStrokeWidth",outerStrokeColor:"outerStrokeColor",outerStrokeGradientStopColor:"outerStrokeGradientStopColor",outerStrokeLinecap:"outerStrokeLinecap",innerStrokeColor:"innerStrokeColor",innerStrokeWidth:"innerStrokeWidth",titleFormat:"titleFormat",title:"title",titleColor:"titleColor",titleFontSize:"titleFontSize",titleFontWeight:"titleFontWeight",subtitleFormat:"subtitleFormat",subtitle:"subtitle",subtitleColor:"subtitleColor",subtitleFontSize:"subtitleFontSize",subtitleFontWeight:"subtitleFontWeight",imageSrc:"imageSrc",imageHeight:"imageHeight",imageWidth:"imageWidth",animation:"animation",animateTitle:"animateTitle",animateSubtitle:"animateSubtitle",animationDuration:"animationDuration",showTitle:"showTitle",showSubtitle:"showSubtitle",showUnits:"showUnits",showImage:"showImage",showBackground:"showBackground",showInnerStroke:"showInnerStroke",clockwise:"clockwise",responsive:"responsive",startFromZero:"startFromZero",showZeroOuterStroke:"showZeroOuterStroke",lazy:"lazy",templateOptions:["options","templateOptions"]},outputs:{onClick:"onClick"},features:[Ms],decls:1,vars:1,consts:[["xmlns","http://www.w3.org/2000/svg","preserveAspectRatio","xMidYMid meet",3,"click",4,"ngIf"],["xmlns","http://www.w3.org/2000/svg","preserveAspectRatio","xMidYMid meet",3,"click"],[4,"ngIf"],["alignment-baseline","baseline",4,"ngIf"],["preserveAspectRatio","none",4,"ngIf"],["offset","5%"],["offset","95%"],["alignment-baseline","baseline"],[4,"ngFor","ngForOf"],["preserveAspectRatio","none"]],template:function(t,e){1&t&&ua(0,gbt,9,11,"svg",0),2&t&&pa("ngIf",e.svg)},directives:[Ah,Eh],encapsulation:2}),t}(),_bt=function(){var t=vbt=function(){function t(){Object(m.a)(this,t)}return Object(g.a)(t,null,[{key:"forRoot",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return{ngModule:vbt,providers:[{provide:bbt,useValue:t}]}}}]),t}();return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd]]}),t}(),wbt=["*"],kbt=nJ(tJ(eJ((function t(e){Object(m.a)(this,t),this._elementRef=e})),"primary"),-1),Cbt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-chip-avatar"],["","matChipAvatar",""]],hostAttrs:[1,"mat-chip-avatar"]}),t}(),Sbt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-chip-trailing-icon"],["","matChipTrailingIcon",""]],hostAttrs:[1,"mat-chip-trailing-icon"]}),t}(),xbt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,c,l,u){var h;return Object(m.a)(this,n),(h=e.call(this,t))._elementRef=t,h._ngZone=i,h._changeDetectorRef=c,h._hasFocus=!1,h.chipListSelectable=!0,h._chipListMultiple=!1,h._chipListDisabled=!1,h._selected=!1,h._selectable=!0,h._disabled=!1,h._removable=!0,h._onFocus=new w.b,h._onBlur=new w.b,h.selectionChange=new Uc,h.destroyed=new Uc,h.removed=new Uc,h._addHostClassName(),h._chipRippleTarget=(u||document).createElement("div"),h._chipRippleTarget.classList.add("mat-chip-ripple"),h._elementRef.nativeElement.appendChild(h._chipRippleTarget),h._chipRipple=new mJ(Object(s.a)(h),i,h._chipRippleTarget,r),h._chipRipple.setupTriggerEvents(t),h.rippleConfig=o||{},h._animationsDisabled="NoopAnimations"===a,h.tabIndex=null!=l&&parseInt(l)||-1,h}return Object(g.a)(n,[{key:"_addHostClassName",value:function(){var t=this._elementRef.nativeElement;t.hasAttribute("mat-basic-chip")||"mat-basic-chip"===t.tagName.toLowerCase()?t.classList.add("mat-basic-chip"):t.classList.add("mat-standard-chip")}},{key:"ngOnDestroy",value:function(){this.destroyed.emit({chip:this}),this._chipRipple._removeTriggerEvents()}},{key:"select",value:function(){this._selected||(this._selected=!0,this._dispatchSelectionChange(),this._markForCheck())}},{key:"deselect",value:function(){this._selected&&(this._selected=!1,this._dispatchSelectionChange(),this._markForCheck())}},{key:"selectViaInteraction",value:function(){this._selected||(this._selected=!0,this._dispatchSelectionChange(!0),this._markForCheck())}},{key:"toggleSelected",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this._selected=!this.selected,this._dispatchSelectionChange(t),this._markForCheck(),this.selected}},{key:"focus",value:function(){this._hasFocus||(this._elementRef.nativeElement.focus(),this._onFocus.next({chip:this})),this._hasFocus=!0}},{key:"remove",value:function(){this.removable&&this.removed.emit({chip:this})}},{key:"_handleClick",value:function(t){this.disabled?t.preventDefault():t.stopPropagation()}},{key:"_handleKeydown",value:function(t){if(!this.disabled)switch(t.keyCode){case 46:case 8:this.remove(),t.preventDefault();break;case 32:this.selectable&&this.toggleSelected(!0),t.preventDefault()}}},{key:"_blur",value:function(){var t=this;this._ngZone.onStable.asObservable().pipe(Object(FX.a)(1)).subscribe((function(){t._ngZone.run((function(){t._hasFocus=!1,t._onBlur.next({chip:t})}))}))}},{key:"_dispatchSelectionChange",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.selectionChange.emit({source:this,isUserInput:t,selected:this._selected})}},{key:"_markForCheck",value:function(){this._changeDetectorRef&&this._changeDetectorRef.markForCheck()}},{key:"rippleDisabled",get:function(){return this.disabled||this.disableRipple||!!this.rippleConfig.disabled}},{key:"selected",get:function(){return this._selected},set:function(t){var e=nm(t);e!==this._selected&&(this._selected=e,this._dispatchSelectionChange())}},{key:"value",get:function(){return void 0!==this._value?this._value:this._elementRef.nativeElement.textContent},set:function(t){this._value=t}},{key:"selectable",get:function(){return this._selectable&&this.chipListSelectable},set:function(t){this._selectable=nm(t)}},{key:"disabled",get:function(){return this._chipListDisabled||this._disabled},set:function(t){this._disabled=nm(t)}},{key:"removable",get:function(){return this._removable},set:function(t){this._removable=nm(t)}},{key:"ariaSelected",get:function(){return this.selectable&&(this._chipListMultiple||this.selected)?this.selected.toString():null}}]),n}(kbt);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(jl),da(Cm),da(bJ,8),da(Cy,8),da(Po),fa("tabindex"),da(du,8))},t.\u0275dir=Wt({type:t,selectors:[["mat-basic-chip"],["","mat-basic-chip",""],["mat-chip"],["","mat-chip",""]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,Cbt,!0),rl(n,Sbt,!0),rl(n,Obt,!0)),2&t&&(tl(i=sl())&&(e.avatar=i.first),tl(i=sl())&&(e.trailingIcon=i.first),tl(i=sl())&&(e.removeIcon=i.first))},hostAttrs:["role","option",1,"mat-chip","mat-focus-indicator"],hostVars:14,hostBindings:function(t,e){1&t&&xa("click",(function(t){return e._handleClick(t)}))("keydown",(function(t){return e._handleKeydown(t)}))("focus",(function(){return e.focus()}))("blur",(function(){return e._blur()})),2&t&&(oa("tabindex",e.disabled?null:e.tabIndex)("disabled",e.disabled||null)("aria-disabled",e.disabled.toString())("aria-selected",e.ariaSelected),Qa("mat-chip-selected",e.selected)("mat-chip-with-avatar",e.avatar)("mat-chip-with-trailing-icon",e.trailingIcon||e.removeIcon)("mat-chip-disabled",e.disabled)("_mat-animation-noopable",e._animationsDisabled))},inputs:{color:"color",disableRipple:"disableRipple",tabIndex:"tabIndex",selected:"selected",value:"value",selectable:"selectable",disabled:"disabled",removable:"removable"},outputs:{selectionChange:"selectionChange",destroyed:"destroyed",removed:"removed"},exportAs:["matChip"],features:[ws]}),t}(),Obt=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._parentChip=e,n&&"BUTTON"===n.nativeElement.nodeName&&n.nativeElement.setAttribute("type","button")}return Object(g.a)(t,[{key:"_handleClick",value:function(t){var e=this._parentChip;e.removable&&!e.disabled&&e.remove(),t.stopPropagation()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(xbt),da(Us))},t.\u0275dir=Wt({type:t,selectors:[["","matChipRemove",""]],hostAttrs:[1,"mat-chip-remove","mat-chip-trailing-icon"],hostBindings:function(t,e){1&t&&xa("click",(function(t){return e._handleClick(t)}))}}),t}(),Mbt=new ht("mat-chips-default-options"),Tbt=iJ((function t(e,n,i,r){Object(m.a)(this,t),this._defaultErrorStateMatcher=e,this._parentForm=n,this._parentFormGroup=i,this.ngControl=r})),Ebt=0,Pbt=function t(e,n){Object(m.a)(this,t),this.source=e,this.value=n},Abt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a,c,l){var u;return Object(m.a)(this,n),(u=e.call(this,c,o,a,l))._elementRef=t,u._changeDetectorRef=i,u._dir=r,u.ngControl=l,u.controlType="mat-chip-list",u._lastDestroyedChipIndex=null,u._destroyed=new w.b,u._uid="mat-chip-list-".concat(Ebt++),u._tabIndex=0,u._userTabIndex=null,u._onTouched=function(){},u._onChange=function(){},u._multiple=!1,u._compareWith=function(t,e){return t===e},u._required=!1,u._disabled=!1,u.ariaOrientation="horizontal",u._selectable=!0,u.change=new Uc,u.valueChange=new Uc,u.ngControl&&(u.ngControl.valueAccessor=Object(s.a)(u)),u}return Object(g.a)(n,[{key:"ngAfterContentInit",value:function(){var t=this;this._keyManager=new d$(this.chips).withWrap().withVerticalOrientation().withHorizontalOrientation(this._dir?this._dir.value:"ltr"),this._dir&&this._dir.change.pipe(Object(Am.a)(this._destroyed)).subscribe((function(e){return t._keyManager.withHorizontalOrientation(e)})),this._keyManager.tabOut.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){t._allowFocusEscape()})),this.chips.changes.pipe(Object(NX.a)(null),Object(Am.a)(this._destroyed)).subscribe((function(){t.disabled&&Promise.resolve().then((function(){t._syncChipsState()})),t._resetChips(),t._initializeSelection(),t._updateTabIndex(),t._updateFocusForDestroyedChips(),t.stateChanges.next()}))}},{key:"ngOnInit",value:function(){this._selectionModel=new fm(this.multiple,void 0,!1),this.stateChanges.next()}},{key:"ngDoCheck",value:function(){this.ngControl&&(this.updateErrorState(),this.ngControl.disabled!==this._disabled&&(this.disabled=!!this.ngControl.disabled))}},{key:"ngOnDestroy",value:function(){this._destroyed.next(),this._destroyed.complete(),this.stateChanges.complete(),this._dropSubscriptions()}},{key:"registerInput",value:function(t){this._chipInput=t}},{key:"setDescribedByIds",value:function(t){this._ariaDescribedby=t.join(" ")}},{key:"writeValue",value:function(t){this.chips&&this._setSelectionByValue(t,!1)}},{key:"registerOnChange",value:function(t){this._onChange=t}},{key:"registerOnTouched",value:function(t){this._onTouched=t}},{key:"setDisabledState",value:function(t){this.disabled=t,this.stateChanges.next()}},{key:"onContainerClick",value:function(t){this._originatesFromChip(t)||this.focus()}},{key:"focus",value:function(t){this.disabled||this._chipInput&&this._chipInput.focused||(this.chips.length>0?(this._keyManager.setFirstItemActive(),this.stateChanges.next()):(this._focusInput(t),this.stateChanges.next()))}},{key:"_focusInput",value:function(t){this._chipInput&&this._chipInput.focus(t)}},{key:"_keydown",value:function(t){var e=t.target;8===t.keyCode&&this._isInputEmpty(e)?(this._keyManager.setLastItemActive(),t.preventDefault()):e&&e.classList.contains("mat-chip")&&(36===t.keyCode?(this._keyManager.setFirstItemActive(),t.preventDefault()):35===t.keyCode?(this._keyManager.setLastItemActive(),t.preventDefault()):this._keyManager.onKeydown(t),this.stateChanges.next())}},{key:"_updateTabIndex",value:function(){this._tabIndex=this._userTabIndex||(0===this.chips.length?-1:0)}},{key:"_updateFocusForDestroyedChips",value:function(){if(null!=this._lastDestroyedChipIndex)if(this.chips.length){var t=Math.min(this._lastDestroyedChipIndex,this.chips.length-1);this._keyManager.setActiveItem(t)}else this.focus();this._lastDestroyedChipIndex=null}},{key:"_isValidIndex",value:function(t){return t>=0&&t<this.chips.length}},{key:"_isInputEmpty",value:function(t){return!(!t||"input"!==t.nodeName.toLowerCase()||t.value)}},{key:"_setSelectionByValue",value:function(t){var e=this,n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(this._clearSelection(),this.chips.forEach((function(t){return t.deselect()})),Array.isArray(t))t.forEach((function(t){return e._selectValue(t,n)})),this._sortValues();else{var i=this._selectValue(t,n);i&&n&&this._keyManager.setActiveItem(i)}}},{key:"_selectValue",value:function(t){var e=this,n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this.chips.find((function(n){return null!=n.value&&e._compareWith(n.value,t)}));return i&&(n?i.selectViaInteraction():i.select(),this._selectionModel.select(i)),i}},{key:"_initializeSelection",value:function(){var t=this;Promise.resolve().then((function(){(t.ngControl||t._value)&&(t._setSelectionByValue(t.ngControl?t.ngControl.value:t._value,!1),t.stateChanges.next())}))}},{key:"_clearSelection",value:function(t){this._selectionModel.clear(),this.chips.forEach((function(e){e!==t&&e.deselect()})),this.stateChanges.next()}},{key:"_sortValues",value:function(){var t=this;this._multiple&&(this._selectionModel.clear(),this.chips.forEach((function(e){e.selected&&t._selectionModel.select(e)})),this.stateChanges.next())}},{key:"_propagateChanges",value:function(t){var e;e=Array.isArray(this.selected)?this.selected.map((function(t){return t.value})):this.selected?this.selected.value:t,this._value=e,this.change.emit(new Pbt(this,e)),this.valueChange.emit(e),this._onChange(e),this._changeDetectorRef.markForCheck()}},{key:"_blur",value:function(){var t=this;this._hasFocusedChip()||this._keyManager.setActiveItem(-1),this.disabled||(this._chipInput?setTimeout((function(){t.focused||t._markAsTouched()})):this._markAsTouched())}},{key:"_markAsTouched",value:function(){this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next()}},{key:"_allowFocusEscape",value:function(){var t=this;-1!==this._tabIndex&&(this._tabIndex=-1,setTimeout((function(){t._tabIndex=t._userTabIndex||0,t._changeDetectorRef.markForCheck()})))}},{key:"_resetChips",value:function(){this._dropSubscriptions(),this._listenToChipsFocus(),this._listenToChipsSelection(),this._listenToChipsRemoved()}},{key:"_dropSubscriptions",value:function(){this._chipFocusSubscription&&(this._chipFocusSubscription.unsubscribe(),this._chipFocusSubscription=null),this._chipBlurSubscription&&(this._chipBlurSubscription.unsubscribe(),this._chipBlurSubscription=null),this._chipSelectionSubscription&&(this._chipSelectionSubscription.unsubscribe(),this._chipSelectionSubscription=null),this._chipRemoveSubscription&&(this._chipRemoveSubscription.unsubscribe(),this._chipRemoveSubscription=null)}},{key:"_listenToChipsSelection",value:function(){var t=this;this._chipSelectionSubscription=this.chipSelectionChanges.subscribe((function(e){e.source.selected?t._selectionModel.select(e.source):t._selectionModel.deselect(e.source),t.multiple||t.chips.forEach((function(e){!t._selectionModel.isSelected(e)&&e.selected&&e.deselect()})),e.isUserInput&&t._propagateChanges()}))}},{key:"_listenToChipsFocus",value:function(){var t=this;this._chipFocusSubscription=this.chipFocusChanges.subscribe((function(e){var n=t.chips.toArray().indexOf(e.chip);t._isValidIndex(n)&&t._keyManager.updateActiveItem(n),t.stateChanges.next()})),this._chipBlurSubscription=this.chipBlurChanges.subscribe((function(){t._blur(),t.stateChanges.next()}))}},{key:"_listenToChipsRemoved",value:function(){var t=this;this._chipRemoveSubscription=this.chipRemoveChanges.subscribe((function(e){var n=e.chip,i=t.chips.toArray().indexOf(e.chip);t._isValidIndex(i)&&n._hasFocus&&(t._lastDestroyedChipIndex=i)}))}},{key:"_originatesFromChip",value:function(t){for(var e=t.target;e&&e!==this._elementRef.nativeElement;){if(e.classList.contains("mat-chip"))return!0;e=e.parentElement}return!1}},{key:"_hasFocusedChip",value:function(){return this.chips.some((function(t){return t._hasFocus}))}},{key:"_syncChipsState",value:function(){var t=this;this.chips&&this.chips.forEach((function(e){e._chipListDisabled=t._disabled,e._chipListMultiple=t.multiple}))}},{key:"selected",get:function(){return this.multiple?this._selectionModel.selected:this._selectionModel.selected[0]}},{key:"role",get:function(){return this.empty?null:"listbox"}},{key:"multiple",get:function(){return this._multiple},set:function(t){this._multiple=nm(t),this._syncChipsState()}},{key:"compareWith",get:function(){return this._compareWith},set:function(t){this._compareWith=t,this._selectionModel&&this._initializeSelection()}},{key:"value",get:function(){return this._value},set:function(t){this.writeValue(t),this._value=t}},{key:"id",get:function(){return this._chipInput?this._chipInput.id:this._uid}},{key:"required",get:function(){return this._required},set:function(t){this._required=nm(t),this.stateChanges.next()}},{key:"placeholder",get:function(){return this._chipInput?this._chipInput.placeholder:this._placeholder},set:function(t){this._placeholder=t,this.stateChanges.next()}},{key:"focused",get:function(){return this._chipInput&&this._chipInput.focused||this._hasFocusedChip()}},{key:"empty",get:function(){return(!this._chipInput||this._chipInput.empty)&&0===this.chips.length}},{key:"shouldLabelFloat",get:function(){return!this.empty||this.focused}},{key:"disabled",get:function(){return this.ngControl?!!this.ngControl.disabled:this._disabled},set:function(t){this._disabled=nm(t),this._syncChipsState()}},{key:"selectable",get:function(){return this._selectable},set:function(t){var e=this;this._selectable=nm(t),this.chips&&this.chips.forEach((function(t){return t.chipListSelectable=e._selectable}))}},{key:"tabIndex",set:function(t){this._userTabIndex=t,this._tabIndex=t}},{key:"chipSelectionChanges",get:function(){return C.a.apply(void 0,Object(u.a)(this.chips.map((function(t){return t.selectionChange}))))}},{key:"chipFocusChanges",get:function(){return C.a.apply(void 0,Object(u.a)(this.chips.map((function(t){return t._onFocus}))))}},{key:"chipBlurChanges",get:function(){return C.a.apply(void 0,Object(u.a)(this.chips.map((function(t){return t._onBlur}))))}},{key:"chipRemoveChanges",get:function(){return C.a.apply(void 0,Object(u.a)(this.chips.map((function(t){return t.destroyed}))))}}]),n}(Tbt);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Po),da(gm,8),da(gp,8),da(Pp,8),da(oJ),da(ff,10))},t.\u0275cmp=Ht({type:t,selectors:[["mat-chip-list"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,xbt,!0),2&t&&tl(i=sl())&&(e.chips=i)},hostAttrs:[1,"mat-chip-list"],hostVars:15,hostBindings:function(t,e){1&t&&xa("focus",(function(){return e.focus()}))("blur",(function(){return e._blur()}))("keydown",(function(t){return e._keydown(t)})),2&t&&(bs("id",e._uid),oa("tabindex",e.disabled?null:e._tabIndex)("aria-describedby",e._ariaDescribedby||null)("aria-required",e.role?e.required:null)("aria-disabled",e.disabled.toString())("aria-invalid",e.errorState)("aria-multiselectable",e.multiple)("role",e.role)("aria-orientation",e.ariaOrientation),Qa("mat-chip-list-disabled",e.disabled)("mat-chip-list-invalid",e.errorState)("mat-chip-list-required",e.required))},inputs:{ariaOrientation:["aria-orientation","ariaOrientation"],multiple:"multiple",compareWith:"compareWith",value:"value",required:"required",placeholder:"placeholder",disabled:"disabled",selectable:"selectable",tabIndex:"tabIndex",errorStateMatcher:"errorStateMatcher"},outputs:{change:"change",valueChange:"valueChange"},exportAs:["matChipList"],features:[Ns([{provide:F3,useExisting:t}]),ws],ngContentSelectors:wbt,decls:2,vars:0,consts:[[1,"mat-chip-list-wrapper"]],template:function(t,e){1&t&&(Ia(),ga(0,"div",0),Da(1),va())},styles:['.mat-chip{position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;transform:translateZ(0);border:none;-webkit-appearance:none;-moz-appearance:none}.mat-standard-chip{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);display:inline-flex;padding:7px 12px;border-radius:16px;align-items:center;cursor:default;min-height:32px;height:1px}._mat-animation-noopable.mat-standard-chip{transition:none;animation:none}.mat-standard-chip .mat-chip-remove.mat-icon{width:18px;height:18px}.mat-standard-chip::after{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:inherit;opacity:0;content:"";pointer-events:none;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-standard-chip:hover::after{opacity:.12}.mat-standard-chip:focus{outline:none}.mat-standard-chip:focus::after{opacity:.16}.cdk-high-contrast-active .mat-standard-chip{outline:solid 1px}.cdk-high-contrast-active .mat-standard-chip:focus{outline:dotted 2px}.mat-standard-chip.mat-chip-disabled::after{opacity:0}.mat-standard-chip.mat-chip-disabled .mat-chip-remove,.mat-standard-chip.mat-chip-disabled .mat-chip-trailing-icon{cursor:default}.mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar,.mat-standard-chip.mat-chip-with-avatar{padding-top:0;padding-bottom:0}.mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar{padding-right:8px;padding-left:0}[dir=rtl] .mat-standard-chip.mat-chip-with-trailing-icon.mat-chip-with-avatar{padding-left:8px;padding-right:0}.mat-standard-chip.mat-chip-with-trailing-icon{padding-top:7px;padding-bottom:7px;padding-right:8px;padding-left:12px}[dir=rtl] .mat-standard-chip.mat-chip-with-trailing-icon{padding-left:8px;padding-right:12px}.mat-standard-chip.mat-chip-with-avatar{padding-left:0;padding-right:12px}[dir=rtl] .mat-standard-chip.mat-chip-with-avatar{padding-right:0;padding-left:12px}.mat-standard-chip .mat-chip-avatar{width:24px;height:24px;margin-right:8px;margin-left:4px}[dir=rtl] .mat-standard-chip .mat-chip-avatar{margin-left:8px;margin-right:4px}.mat-standard-chip .mat-chip-remove,.mat-standard-chip .mat-chip-trailing-icon{width:18px;height:18px;cursor:pointer}.mat-standard-chip .mat-chip-remove,.mat-standard-chip .mat-chip-trailing-icon{margin-left:8px;margin-right:0}[dir=rtl] .mat-standard-chip .mat-chip-remove,[dir=rtl] .mat-standard-chip .mat-chip-trailing-icon{margin-right:8px;margin-left:0}.mat-chip-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit;overflow:hidden}.mat-chip-list-wrapper{display:flex;flex-direction:row;flex-wrap:wrap;align-items:center;margin:-4px}.mat-chip-list-wrapper input.mat-input-element,.mat-chip-list-wrapper .mat-standard-chip{margin:4px}.mat-chip-list-stacked .mat-chip-list-wrapper{flex-direction:column;align-items:flex-start}.mat-chip-list-stacked .mat-chip-list-wrapper .mat-standard-chip{width:100%}.mat-chip-avatar{border-radius:50%;justify-content:center;align-items:center;display:flex;overflow:hidden;object-fit:cover}input.mat-chip-input{width:150px;margin:4px;flex:1 0 150px}\n'],encapsulation:2,changeDetection:0}),t}(),jbt=0,Ibt=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._elementRef=e,this._defaultOptions=n,this.focused=!1,this._addOnBlur=!1,this.separatorKeyCodes=this._defaultOptions.separatorKeyCodes,this.chipEnd=new Uc,this.placeholder="",this.id="mat-chip-list-input-".concat(jbt++),this._disabled=!1,this._inputElement=this._elementRef.nativeElement}return Object(g.a)(t,[{key:"ngOnChanges",value:function(){this._chipList.stateChanges.next()}},{key:"_keydown",value:function(t){t&&9===t.keyCode&&!JQ(t,"shiftKey")&&this._chipList._allowFocusEscape(),this._emitChipEnd(t)}},{key:"_blur",value:function(){this.addOnBlur&&this._emitChipEnd(),this.focused=!1,this._chipList.focused||this._chipList._blur(),this._chipList.stateChanges.next()}},{key:"_focus",value:function(){this.focused=!0,this._chipList.stateChanges.next()}},{key:"_emitChipEnd",value:function(t){!this._inputElement.value&&t&&this._chipList._keydown(t),t&&!this._isSeparatorKey(t)||(this.chipEnd.emit({input:this._inputElement,value:this._inputElement.value}),t&&t.preventDefault())}},{key:"_onInput",value:function(){this._chipList.stateChanges.next()}},{key:"focus",value:function(t){this._inputElement.focus(t)}},{key:"_isSeparatorKey",value:function(t){if(JQ(t))return!1;var e=this.separatorKeyCodes,n=t.keyCode;return Array.isArray(e)?e.indexOf(n)>-1:e.has(n)}},{key:"chipList",set:function(t){t&&(this._chipList=t,this._chipList.registerInput(this))}},{key:"addOnBlur",get:function(){return this._addOnBlur},set:function(t){this._addOnBlur=nm(t)}},{key:"disabled",get:function(){return this._disabled||this._chipList&&this._chipList.disabled},set:function(t){this._disabled=nm(t)}},{key:"empty",get:function(){return!this._inputElement.value}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Mbt))},t.\u0275dir=Wt({type:t,selectors:[["input","matChipInputFor",""]],hostAttrs:[1,"mat-chip-input","mat-input-element"],hostVars:5,hostBindings:function(t,e){1&t&&xa("keydown",(function(t){return e._keydown(t)}))("blur",(function(){return e._blur()}))("focus",(function(){return e._focus()}))("input",(function(){return e._onInput()})),2&t&&(bs("id",e.id),oa("disabled",e.disabled||null)("placeholder",e.placeholder||null)("aria-invalid",e._chipList&&e._chipList.ngControl?e._chipList.ngControl.invalid:null)("aria-required",e._chipList&&e._chipList.required||null))},inputs:{separatorKeyCodes:["matChipInputSeparatorKeyCodes","separatorKeyCodes"],placeholder:"placeholder",id:"id",chipList:["matChipInputFor","chipList"],addOnBlur:["matChipInputAddOnBlur","addOnBlur"],disabled:"disabled"},outputs:{chipEnd:"matChipInputTokenEnd"},exportAs:["matChipInput","matChipInputFor"],features:[Ms]}),t}(),Dbt={separatorKeyCodes:[13]},Rbt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[oJ,{provide:Mbt,useValue:Dbt}]}),t}(),Lbt=function(){return["Load average","(last 1 minute)"]},Fbt=function(){return["Load average","(last 5 minutes)"]},Nbt=function(){return["Load average","(last 15 minutes)"]},Bbt=function(){function t(){}return t.prototype.ngOnInit=function(){},t.prototype.formatBytes=function(t,e){if(void 0===e&&(e=2),0===t)return"0 Bytes";var n=e<0?0:e,i=Math.floor(Math.log(t)/Math.log(1024));return parseFloat((t/Math.pow(1024,i)).toFixed(n))+" "+["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"][i]},t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=Ht({type:t,selectors:[["app-status-chart"]],inputs:{computeStatistics:"computeStatistics"},decls:30,vars:114,consts:[[1,"wrapper"],[3,"percent","radius","outerStrokeWidth","innerStrokeWidth","outerStrokeColor","innerStrokeColor","animation","animationDuration","unitsColor","unitsFontSize","titleColor","titleFontSize","subtitle","subtitleColor","subtitleFontSize"],[1,"chips-wrapper"],["color","primary","selected",""]],template:function(t,e){1&t&&(ga(0,"mat-card"),ga(1,"div",0),ba(2,"circle-progress",1),ba(3,"circle-progress",1),ba(4,"circle-progress",1),ba(5,"circle-progress",1),va(),ga(6,"div",0),ba(7,"circle-progress",1),ba(8,"circle-progress",1),ba(9,"circle-progress",1),va(),ga(10,"div",2),ga(11,"mat-chip-list"),ga(12,"mat-chip",3),ds(13),va(),va(),ga(14,"mat-chip-list"),ga(15,"mat-chip",3),ds(16),va(),va(),ga(17,"mat-chip-list"),ga(18,"mat-chip",3),ds(19),va(),va(),va(),ga(20,"div",2),ga(21,"mat-chip-list"),ga(22,"mat-chip",3),ds(23),va(),va(),ga(24,"mat-chip-list"),ga(25,"mat-chip",3),ds(26),va(),va(),ga(27,"mat-chip-list"),ga(28,"mat-chip",3),ds(29),va(),va(),va(),va()),2&t&&(Qi(2),pa("percent",e.computeStatistics.statistics.cpu_usage_percent)("radius",100)("outerStrokeWidth",8)("innerStrokeWidth",6)("outerStrokeColor","#0097a7")("innerStrokeColor","#007380")("animation",!0)("animationDuration",300)("unitsColor","#C0C0C0")("unitsFontSize",20)("titleColor","#C0C0C0")("titleFontSize",30)("subtitle","CPU usage")("subtitleColor","#C0C0C0")("subtitleFontSize",15),Qi(1),pa("percent",e.computeStatistics.statistics.disk_usage_percent)("radius",100)("outerStrokeWidth",8)("innerStrokeWidth",6)("outerStrokeColor","#0097a7")("innerStrokeColor","#007380")("animation",!0)("animationDuration",300)("unitsColor","#C0C0C0")("unitsFontSize",20)("titleColor","#C0C0C0")("titleFontSize",30)("subtitle","Disk usage")("subtitleColor","#C0C0C0")("subtitleFontSize",15),Qi(1),pa("percent",e.computeStatistics.statistics.memory_usage_percent)("radius",100)("outerStrokeWidth",8)("innerStrokeWidth",6)("outerStrokeColor","#0097a7")("innerStrokeColor","#007380")("animation",!0)("animationDuration",300)("unitsColor","#C0C0C0")("unitsFontSize",20)("titleColor","#C0C0C0")("titleFontSize",30)("subtitle","Memory usage")("subtitleColor","#C0C0C0")("subtitleFontSize",15),Qi(1),pa("percent",e.computeStatistics.statistics.swap_usage_percent)("radius",100)("outerStrokeWidth",8)("innerStrokeWidth",6)("outerStrokeColor","#0097a7")("innerStrokeColor","#007380")("animation",!0)("animationDuration",300)("unitsColor","#C0C0C0")("unitsFontSize",20)("titleColor","#C0C0C0")("titleFontSize",30)("subtitle","SWAP usage")("subtitleColor","#C0C0C0")("subtitleFontSize",15),Qi(2),pa("percent",e.computeStatistics.statistics.load_average_percent[0])("radius",100)("outerStrokeWidth",8)("innerStrokeWidth",6)("outerStrokeColor","#0097a7")("innerStrokeColor","#007380")("animation",!0)("animationDuration",300)("unitsColor","#C0C0C0")("unitsFontSize",20)("titleColor","#C0C0C0")("titleFontSize",30)("subtitle",jc(111,Lbt))("subtitleColor","#C0C0C0")("subtitleFontSize",15),Qi(1),pa("percent",e.computeStatistics.statistics.load_average_percent[1])("radius",100)("outerStrokeWidth",8)("innerStrokeWidth",6)("outerStrokeColor","#0097a7")("innerStrokeColor","#007380")("animation",!0)("animationDuration",300)("unitsColor","#C0C0C0")("unitsFontSize",20)("titleColor","#C0C0C0")("titleFontSize",30)("subtitle",jc(112,Fbt))("subtitleColor","#C0C0C0")("subtitleFontSize",15),Qi(1),pa("percent",e.computeStatistics.statistics.load_average_percent[2])("radius",100)("outerStrokeWidth",8)("innerStrokeWidth",6)("outerStrokeColor","#0097a7")("innerStrokeColor","#007380")("animation",!0)("animationDuration",300)("unitsColor","#C0C0C0")("unitsFontSize",20)("titleColor","#C0C0C0")("titleFontSize",30)("subtitle",jc(113,Nbt))("subtitleColor","#C0C0C0")("subtitleFontSize",15),Qi(4),ps("Memory total: ",e.formatBytes(e.computeStatistics.statistics.memory_total),""),Qi(3),ps("Memory used: ",e.formatBytes(e.computeStatistics.statistics.memory_used),""),Qi(3),ps("Memory free: ",e.formatBytes(e.computeStatistics.statistics.memory_free),""),Qi(4),ps("Swap total: ",e.formatBytes(e.computeStatistics.statistics.swap_total),""),Qi(3),ps("Swap used: ",e.formatBytes(e.computeStatistics.statistics.swap_used),""),Qi(3),ps("Swap free: ",e.formatBytes(e.computeStatistics.statistics.swap_free),""))},directives:[f3,ybt,Abt,xbt],styles:[".wrapper[_ngcontent-%COMP%]{max-height:250px!important}.chips-wrapper[_ngcontent-%COMP%], .wrapper[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:space-between}.chips-wrapper[_ngcontent-%COMP%]{margin-bottom:10px}"]}),t}();function Hbt(t,e){1&t&&(ga(0,"div"),ds(1," Statistics not loaded\n"),va())}function zbt(t,e){if(1&t&&(ga(0,"div"),ds(1),ba(2,"app-status-chart",2),va()),2&t){var n=e.$implicit;Qi(1),ps(" ",n.compute_name," "),Qi(1),pa("computeStatistics",n)}}var Vbt=function(){function t(t,e,n,i){this.route=t,this.computeService=e,this.serverService=n,this.toasterService=i,this.serverId="",this.computeStatistics=[]}return t.prototype.ngOnInit=function(){this.serverId=this.route.snapshot.paramMap.get("server_id"),this.getStatistics()},t.prototype.getStatistics=function(){var t=this;this.serverService.get(Number(this.serverId)).then((function(e){t.computeService.getStatistics(e).subscribe((function(e){t.computeStatistics=e,setTimeout((function(){t.getStatistics()}),2e4)}))}))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(_ot),da(ZQ),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-status-info"]],decls:2,vars:2,consts:[[4,"ngIf"],[4,"ngFor","ngForOf"],[3,"computeStatistics"]],template:function(t,e){1&t&&(ua(0,Hbt,2,0,"div",0),ua(1,zbt,3,2,"div",1)),2&t&&(pa("ngIf",!e.computeStatistics.length),Qi(1),pa("ngForOf",e.computeStatistics))},directives:[Ah,Eh,Bbt],styles:[""]}),t}(),Ubt=function(){function t(t){this.route=t,this.serverId=""}return t.prototype.ngOnInit=function(){this.serverId=this.route.snapshot.paramMap.get("server_id")},t.\u0275fac=function(e){return new(e||t)(da(ZY))},t.\u0275cmp=Ht({type:t,selectors:[["app-system-status"]],decls:7,vars:0,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"System status"),va(),va(),va(),ga(5,"div",4),ba(6,"app-status-info"),va(),va())},directives:[Vbt],styles:[""]}),t}(),qbt=function(){function t(t){this.serverService=t}return t.prototype.resolve=function(t){return this.serverService.get(parseInt(t.params.server_id))},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(ZQ))}}),t}(),Gbt=["terminal"],Wbt=function(){function t(t,e,n,i,r){this.consoleService=t,this.serverService=e,this.route=n,this.title=i,this.nodeService=r,this.subscriptions=new _.a,this.term=new Glt.Terminal,this.fitAddon=new Klt.FitAddon}return t.prototype.ngOnInit=function(){var t=this;this.serverService.isServiceInitialized?this.getData():this.subscriptions.add(this.serverService.serviceInitialized.subscribe((function(e){e&&t.getData()})))},t.prototype.getData=function(){var t=this;this.serverId=this.route.snapshot.paramMap.get("server_id"),this.projectId=this.route.snapshot.paramMap.get("project_id"),this.nodeId=this.route.snapshot.paramMap.get("node_id"),this.consoleService.consoleResized.subscribe((function(e){t.fitAddon.fit()})),this.serverService.get(+this.serverId).then((function(e){t.server=e,t.nodeService.getNodeById(t.server,t.projectId,t.nodeId).subscribe((function(e){t.node=e,t.title.setTitle(t.node.name),t.openTerminal()}))}))},t.prototype.openTerminal=function(){var t=this;setTimeout((function(){t.term.open(t.terminal.nativeElement);var e=new WebSocket(t.getUrl());e.onerror=function(e){t.term.write("Connection lost\r\n")},e.onclose=function(e){t.term.write("Connection closed\r\n")};var n=new Wlt.AttachAddon(e);t.term.loadAddon(n),t.term.setOption("cursorBlink",!0),t.term.loadAddon(t.fitAddon),t.fitAddon.activate(t.term),t.fitAddon.fit(),t.term.focus(),t.term.attachCustomKeyEventHandler((function(t){return"KeyC"!==t.code&&"KeyV"!==t.code||!t.ctrlKey}));var i=Math.round(window.innerWidth/t.consoleService.getLineWidth()),r=Math.round(window.innerHeight/t.consoleService.getLineHeight());t.term.resize(i,r)}),0)},t.prototype.getUrl=function(){return"ws://"+this.server.host+":"+this.server.port+"/v2/projects/"+this.projectId+"/nodes/"+this.nodeId+"/console/ws"},t.\u0275fac=function(e){return new(e||t)(da(Q8),da(ZQ),da(ZY),da(Yd),da(E2))},t.\u0275cmp=Ht({type:t,selectors:[["app-web-console-full-window"]],viewQuery:function(t,e){var n;1&t&&nl(Gbt,!0),2&t&&tl(n=sl())&&(e.terminal=n.first)},decls:2,vars:0,consts:[["id","terminal",2,"width","100%","height","100%"],["terminal",""]],template:function(t,e){1&t&&ba(0,"div",0,1)},styles:['.xterm{font-feature-settings:"liga" 0;position:relative;-moz-user-select:none;user-select:none;-ms-user-select:none;-webkit-user-select:none}.xterm.focus,.xterm:focus{outline:none}.xterm .xterm-helpers{position:absolute;top:0;z-index:5}.xterm .xterm-helper-textarea{padding:0;border:0;margin:0;position:absolute;opacity:0;left:-9999em;top:0;width:0;height:0;z-index:-5;white-space:nowrap;overflow:hidden;resize:none}.xterm .composition-view{background:#000;color:#fff;display:none;position:absolute;white-space:nowrap;z-index:1}.xterm .composition-view.active{display:block}.xterm .xterm-viewport{background-color:#000;overflow-y:scroll;cursor:default;position:absolute;right:0;left:0;top:0;bottom:0}.xterm .xterm-screen{position:relative}.xterm .xterm-screen canvas{position:absolute;left:0;top:0}.xterm .xterm-scroll-area{visibility:hidden}.xterm-char-measure-element{display:inline-block;visibility:hidden;position:absolute;top:0;left:-9999em;line-height:normal}.xterm{cursor:text}.xterm.enable-mouse-events{cursor:default}.xterm.xterm-cursor-pointer{cursor:pointer}.xterm.column-select.focus{cursor:crosshair}.xterm .xterm-accessibility,.xterm .xterm-message{position:absolute;left:0;top:0;bottom:0;right:0;z-index:10;color:transparent}.xterm .live-region{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}.xterm-dim{opacity:.5}.xterm-underline{text-decoration:underline}'],encapsulation:2}),t}(),Kbt=function(){function t(t,e){this.consoleService=t,this.bottomSheet=e}return t.prototype.canDeactivate=function(){if(this.consoleService.openConsoles>0){this.bottomSheet.open(Xrt);var t=this.bottomSheet._openedBottomSheetRef;return t.instance.message="Exiting the project will close open consoles, do you want to continue?",t.afterDismissed()}return!0},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Q8),_t(qrt))}}),t}(),Xbt=[{path:"",component:Jht,children:[{path:"",redirectTo:"servers",pathMatch:"full"},{path:"servers",component:Iht},{path:"bundled",component:Mdt},{path:"server/:server_id/projects",component:Yht,resolve:{server:qbt}},{path:"help",component:zvt},{path:"settings",component:Odt},{path:"settings/console",component:Hvt},{path:"installed-software",component:Omt},{path:"server/:server_id/systemstatus",component:Ubt},{path:"server/:server_ip/:server_port/project/:project_id",component:Jvt},{path:"server/:server_id/project/:project_id/snapshots",component:Bvt,resolve:{server:qbt}},{path:"server/:server_id/preferences",component:Tdt},{path:"server/:server_id/preferences/gns3vm",component:$vt},{path:"server/:server_id/preferences/builtin",component:Zft},{path:"server/:server_id/preferences/builtin/ethernet-hubs",component:rpt},{path:"server/:server_id/preferences/builtin/ethernet-hubs/addtemplate",component:opt},{path:"server/:server_id/preferences/builtin/ethernet-hubs/:template_id",component:hpt},{path:"server/:server_id/preferences/builtin/ethernet-switches",component:Xpt},{path:"server/:server_id/preferences/builtin/ethernet-switches/addtemplate",component:Ypt},{path:"server/:server_id/preferences/builtin/ethernet-switches/:template_id",component:nmt},{path:"server/:server_id/preferences/builtin/cloud-nodes",component:bpt},{path:"server/:server_id/preferences/builtin/cloud-nodes/addtemplate",component:ypt},{path:"server/:server_id/preferences/builtin/cloud-nodes/:template_id",component:zpt},{path:"server/:server_id/preferences/dynamips/templates",component:lmt},{path:"server/:server_id/preferences/dynamips/templates/addtemplate",component:fgt},{path:"server/:server_id/preferences/dynamips/templates/:template_id",component:Ymt},{path:"server/:server_id/preferences/dynamips/templates/:template_id/copy",component:Ovt},{path:"server/:server_id/preferences/qemu/templates",component:Ndt},{path:"server/:server_id/preferences/qemu/templates/:template_id/copy",component:xvt},{path:"server/:server_id/preferences/qemu/templates/:template_id",component:rft},{path:"server/:server_id/preferences/qemu/addtemplate",component:dft},{path:"server/:server_id/preferences/vpcs/templates",component:_ft},{path:"server/:server_id/preferences/vpcs/templates/:template_id",component:Tft},{path:"server/:server_id/preferences/vpcs/addtemplate",component:wft},{path:"server/:server_id/preferences/virtualbox/templates",component:Lft},{path:"server/:server_id/preferences/virtualbox/templates/:template_id",component:Wft},{path:"server/:server_id/preferences/virtualbox/addtemplate",component:Yft},{path:"server/:server_id/preferences/vmware/templates",component:wgt},{path:"server/:server_id/preferences/vmware/templates/:template_id",component:Agt},{path:"server/:server_id/preferences/vmware/addtemplate",component:Rgt},{path:"server/:server_id/preferences/docker/templates",component:Vgt},{path:"server/:server_id/preferences/docker/templates/:template_id",component:nvt},{path:"server/:server_id/preferences/docker/templates/:template_id/copy",component:Mvt},{path:"server/:server_id/preferences/docker/addtemplate",component:Xgt},{path:"server/:server_id/preferences/iou/templates",component:lvt},{path:"server/:server_id/preferences/iou/templates/:template_id",component:Svt},{path:"server/:server_id/preferences/iou/templates/:template_id/copy",component:Tvt},{path:"server/:server_id/preferences/iou/addtemplate",component:mvt}]},{path:"server/:server_id/project/:project_id",component:Uut,canDeactivate:[Kbt]},{path:"server/:server_id/project/:project_id/nodes/:node_id",component:Wbt},{path:"static/web-ui/server/:server_id/project/:project_id/nodes/:node_id",component:Wbt},{path:"**",component:Vvt}],Ybt=function(){function t(){}return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[OQ.forRoot(Xbt,{anchorScrolling:"enabled",enableTracing:!1,scrollPositionRestoration:"enabled"})],OQ]}),t}(),Zbt=["dynamicComponentContainer"],Qbt=function(t){return{hidden:t}},$bt=function(t){return{lightTheme:t}},Jbt=function(){function t(t,e,n,i){this.themeService=t,this.componentFactoryResolver=e,this.viewContainerRef=n,this.location=i,this.viewsCounter=0,this.ticks=1e3,this.progress=0,this.isAdLoaded=!1,this.isVisible=!1,this.interval=10,this.delayTime=5e3,this.breakTime=1200,this.isEndless=!0,this.numberOfViews=1,this.isLightThemeEnabled=!1}return t.prototype.ngOnInit=function(){localStorage.getItem("adbutler"),(new Date).toISOString().substring(0,10),this.location.path().includes("nodes")||this.startTimer(),this.isLightThemeEnabled="light"===this.themeService.getActualTheme()},t.prototype.ngAfterViewInit=function(){this.createDynamicAdComponent()},t.prototype.createDynamicAdComponent=function(){var t=this,e=this.componentFactoryResolver.resolveComponentFactory(pmt),n=this.dynamicComponentContainer.createComponent(e);n.instance.theme="light"===this.themeService.getActualTheme(),n.instance.onLoad.subscribe((function(e){t.onLoadingAdbutler(e)})),n.changeDetectorRef.detectChanges()},t.prototype.startTimer=function(){var t=this;this.timer=Object(l1.a)(this.delayTime,1e3),setTimeout((function(){t.showNotification()}),5e3),this.timerSubscription=this.timer.subscribe((function(){t.ticks++,t.ticks>t.breakTime&&!t.isVisible&&navigator.onLine&&t.isAdLoaded&&(t.ticks=0,t.showNotification(),t.viewsCounter++,t.isEndless||t.viewsCounter===t.numberOfViews&&t.timerSubscription.unsubscribe())}))},t.prototype.onLoadingAdbutler=function(t){this.isAdLoaded=t},t.prototype.showNotification=function(){var t=this;this.viewTimer=Object(l1.a)(0,100),this.progress=0,this.isVisible=!0,this.viewTimerSubscription=this.viewTimer.subscribe((function(){t.progress+=1,t.progress>100&&(t.isVisible=!1,t.viewTimerSubscription.unsubscribe())}))},t.prototype.closeNotification=function(){this.isVisible=!1},t.prototype.ngOnDestroy=function(){this.timerSubscription.unsubscribe(),this.viewTimerSubscription.unsubscribe()},t.\u0275fac=function(e){return new(e||t)(da(Kit),da(Vs),da(mc),da(Mu))},t.\u0275cmp=Ht({type:t,selectors:[["app-notification-box"]],viewQuery:function(t,e){var n;1&t&&nl(Zbt,!0,mc),2&t&&tl(n=sl())&&(e.dynamicComponentContainer=n.first)},decls:8,vars:7,consts:[[1,"notification-box",3,"ngClass"],["mode","determinate",3,"value"],[2,"display","flex","height","102px"],[1,"content",3,"ngClass"],["dynamicComponentContainer",""],[1,"close-button",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ba(1,"mat-progress-bar",1),ga(2,"div",2),ga(3,"div",3),ba(4,"template",null,4),ga(6,"mat-icon",5),xa("click",(function(){return e.closeNotification()})),ds(7,"close"),va(),va(),va(),va()),2&t&&(pa("ngClass",Ic(3,Qbt,!e.isVisible)),Qi(1),pa("value",e.progress),Qi(2),pa("ngClass",Ic(5,$bt,e.isLightThemeEnabled)))},directives:[Oh,hlt,x2],styles:[".notification-box[_ngcontent-%COMP%]{position:fixed;bottom:20px;right:20px;width:412px;height:108px}.content[_ngcontent-%COMP%]{background-color:#263238;padding-left:8px;border-left:2px solid #0097a7;border-right:2px solid #0097a7;border-bottom:2px solid #0097a7}.lightTheme[_ngcontent-%COMP%]{background-color:#fff!important}.close-button[_ngcontent-%COMP%]{position:fixed;bottom:90px;right:30px;cursor:pointer}.mat-icon[_ngcontent-%COMP%]:hover{color:#0097a7}.check-button[_ngcontent-%COMP%]{background-color:#0097a7;margin-top:-10px}.hidden[_ngcontent-%COMP%]{visibility:hidden}"]}),t}(),tyt=function(){function t(t,e,n,i,r,o,a){var s=this;this.settingsService=n,this.electronService=i,this.themeService=r,this.router=o,this.progressService=a,t.addSvgIcon("gns3",e.bypassSecurityTrustResourceUrl("./assets/gns3_icon.svg")),t.addSvgIcon("gns3black",e.bypassSecurityTrustResourceUrl("./assets/gns3_icon_black.svg")),o.events.subscribe((function(t){s.checkEvent(t)}))}return t.prototype.ngOnInit=function(){var t=this;this.electronService.isElectronApp&&this.settingsService.subscribe((function(e){t.electronService.ipcRenderer.send("settings.changed",e)}));var e=localStorage.getItem("theme");this.themeService.setDarkMode("light"!==e)},t.prototype.checkEvent=function(t){t instanceof qX?this.progressService.activate():(t instanceof GX||t instanceof WX||t instanceof KX)&&this.progressService.deactivate()},t.\u0275fac=function(e){return new(e||t)(da(g2),da(Vd),da(QQ),da(mX),da(Kit),da(lQ),da(yet))},t.\u0275cmp=Ht({type:t,selectors:[["app-root"]],decls:2,vars:0,template:function(t,e){1&t&&(ba(0,"router-outlet"),ba(1,"app-notification-box"))},directives:[mQ,Jbt],styles:["mat-menu-panel[_ngcontent-%COMP%]{min-height:0}"]}),t}(),eyt=[Znt,Xnt,Int,mnt,fnt,Tnt,Rnt,Nnt,Bnt,Ynt,Knt,Wnt,qnt,wnt,vnt,_nt,ynt,gnt,knt],nyt=function(){return function(){}}(),iyt=function(){function t(){}return t.prototype.convert=function(t){var e=new nyt;return e.symbol_id=t.id,e.builtin=t.builtin,e.filename=t.filename,e.raw=t.raw,e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),ryt=function(){function t(){}return t.prototype.convert=function(t){var e={font_family:void 0,font_size:void 0,font_weight:void 0};return K9.parse(t,{context:"declarationList"}).children.forEach((function(t){"font-size"===t.property&&t.value&&t.value.children&&t.value.children.forEach((function(t){"Dimension"===t.type&&(e.font_size=parseInt(t.value))})),"font-family"===t.property&&t.value&&t.value.children&&t.value.children.forEach((function(t){"Identifier"===t.type&&(e.font_family=t.name)})),"font-weight"===t.property&&t.value&&t.value.children&&t.value.children.forEach((function(t){"Identifier"===t.type&&(e.font_weight=t.name)}))})),e},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)}}),t}(),oyt=function(){function t(){}return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:GQ([Oet,X9,$it,Xit,Yit,Zit,Qit,Xet,S9,bnt,Net,_et,Qnt,Ont,Jnt,pnt,dit,iit,R9,D9,Met,Det,jet,vit,Ent,yit,_it,jnt,Ant,iyt,Pet,Eet,Let,Yet,Het,Vet,qet,Wet,Fnt,nnt,xet,ryt,Unt,znt],eyt),imports:[[hd,H0,O2]]}),t}(),ayt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.prototype.getItemKey=function(t){return t.symbol_id},e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return syt(t||e)}}),e}(O9),syt=zn(ayt),cyt=function(t,e){return(cyt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)};function lyt(t,e){function n(){this.constructor=t}cyt(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var uyt=function(){return(uyt=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)};function hyt(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var i,r,o=n.call(t),a=[];try{for(;(void 0===e||e-- >0)&&!(i=o.next()).done;)a.push(i.value)}catch(s){r={error:s}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}return a}function dyt(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(hyt(arguments[e]));return t}var fyt=n("zNuj"),pyt=Object(fyt.f)(),myt=function(){function t(){this._enabled=!1}return t.prototype.disable=function(){this._enabled=!1},t.prototype.enable=function(){this._enabled=!0},t.prototype.log=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._enabled&&Object(fyt.c)((function(){pyt.console.log("Sentry Logger [Log]: "+t.join(" "))}))},t.prototype.warn=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._enabled&&Object(fyt.c)((function(){pyt.console.warn("Sentry Logger [Warn]: "+t.join(" "))}))},t.prototype.error=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._enabled&&Object(fyt.c)((function(){pyt.console.error("Sentry Logger [Error]: "+t.join(" "))}))},t}();pyt.__SENTRY__=pyt.__SENTRY__||{};var gyt,vyt=pyt.__SENTRY__.logger||(pyt.__SENTRY__.logger=new myt),byt=n("Gqt4");!function(t){t.PENDING="PENDING",t.RESOLVED="RESOLVED",t.REJECTED="REJECTED"}(gyt||(gyt={}));var yyt=function(){function t(t){var e=this;this._state=gyt.PENDING,this._handlers=[],this._resolve=function(t){e._setResult(gyt.RESOLVED,t)},this._reject=function(t){e._setResult(gyt.REJECTED,t)},this._setResult=function(t,n){e._state===gyt.PENDING&&(Object(byt.m)(n)?n.then(e._resolve,e._reject):(e._state=t,e._value=n,e._executeHandlers()))},this._attachHandler=function(t){e._handlers=e._handlers.concat(t),e._executeHandlers()},this._executeHandlers=function(){if(e._state!==gyt.PENDING){var t=e._handlers.slice();e._handlers=[],t.forEach((function(t){t.done||(e._state===gyt.RESOLVED&&t.onfulfilled&&t.onfulfilled(e._value),e._state===gyt.REJECTED&&t.onrejected&&t.onrejected(e._value),t.done=!0)}))}};try{t(this._resolve,this._reject)}catch(n){this._reject(n)}}return t.prototype.toString=function(){return"[object SyncPromise]"},t.resolve=function(e){return new t((function(t){t(e)}))},t.reject=function(e){return new t((function(t,n){n(e)}))},t.all=function(e){return new t((function(n,i){if(Array.isArray(e))if(0!==e.length){var r=e.length,o=[];e.forEach((function(e,a){t.resolve(e).then((function(t){o[a]=t,0==(r-=1)&&n(o)})).then(null,i)}))}else n([]);else i(new TypeError("Promise.all requires an array as input."))}))},t.prototype.then=function(e,n){var i=this;return new t((function(t,r){i._attachHandler({done:!1,onfulfilled:function(n){if(e)try{return void t(e(n))}catch(i){return void r(i)}else t(n)},onrejected:function(e){if(n)try{return void t(n(e))}catch(i){return void r(i)}else r(e)}})}))},t.prototype.catch=function(t){return this.then((function(t){return t}),t)},t.prototype.finally=function(e){var n=this;return new t((function(t,i){var r,o;return n.then((function(t){o=!1,r=t,e&&e()}),(function(t){o=!0,r=t,e&&e()})).then((function(){o?i(r):t(r)}))}))},t}(),_yt=function(){function t(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._user={},this._tags={},this._extra={},this._contexts={}}return t.prototype.addScopeListener=function(t){this._scopeListeners.push(t)},t.prototype.addEventProcessor=function(t){return this._eventProcessors.push(t),this},t.prototype._notifyScopeListeners=function(){var t=this;this._notifyingListeners||(this._notifyingListeners=!0,setTimeout((function(){t._scopeListeners.forEach((function(e){e(t)})),t._notifyingListeners=!1})))},t.prototype._notifyEventProcessors=function(t,e,n,i){var r=this;return void 0===i&&(i=0),new yyt((function(o,a){var s=t[i];if(null===e||"function"!=typeof s)o(e);else{var c=s(uyt({},e),n);Object(byt.m)(c)?c.then((function(e){return r._notifyEventProcessors(t,e,n,i+1).then(o)})).then(null,a):r._notifyEventProcessors(t,c,n,i+1).then(o).then(null,a)}}))},t.prototype.setUser=function(t){return this._user=t||{},this._notifyScopeListeners(),this},t.prototype.setTags=function(t){return this._tags=uyt({},this._tags,t),this._notifyScopeListeners(),this},t.prototype.setTag=function(t,e){var n;return this._tags=uyt({},this._tags,((n={})[t]=e,n)),this._notifyScopeListeners(),this},t.prototype.setExtras=function(t){return this._extra=uyt({},this._extra,t),this._notifyScopeListeners(),this},t.prototype.setExtra=function(t,e){var n;return this._extra=uyt({},this._extra,((n={})[t]=e,n)),this._notifyScopeListeners(),this},t.prototype.setFingerprint=function(t){return this._fingerprint=t,this._notifyScopeListeners(),this},t.prototype.setLevel=function(t){return this._level=t,this._notifyScopeListeners(),this},t.prototype.setTransactionName=function(t){return this._transactionName=t,this._notifyScopeListeners(),this},t.prototype.setTransaction=function(t){return this.setTransactionName(t)},t.prototype.setContext=function(t,e){var n;return this._contexts=uyt({},this._contexts,((n={})[t]=e,n)),this._notifyScopeListeners(),this},t.prototype.setSpan=function(t){return this._span=t,this._notifyScopeListeners(),this},t.prototype.getSpan=function(){return this._span},t.prototype.getTransaction=function(){var t=this.getSpan();if(t&&t.spanRecorder&&t.spanRecorder.spans[0])return t.spanRecorder.spans[0]},t.clone=function(e){var n=new t;return e&&(n._breadcrumbs=dyt(e._breadcrumbs),n._tags=uyt({},e._tags),n._extra=uyt({},e._extra),n._contexts=uyt({},e._contexts),n._user=e._user,n._level=e._level,n._span=e._span,n._transactionName=e._transactionName,n._fingerprint=e._fingerprint,n._eventProcessors=dyt(e._eventProcessors)),n},t.prototype.update=function(e){if(!e)return this;if("function"==typeof e){var n=e(this);return n instanceof t?n:this}return e instanceof t?(this._tags=uyt({},this._tags,e._tags),this._extra=uyt({},this._extra,e._extra),this._contexts=uyt({},this._contexts,e._contexts),e._user&&(this._user=e._user),e._level&&(this._level=e._level),e._fingerprint&&(this._fingerprint=e._fingerprint)):Object(byt.h)(e)&&(this._tags=uyt({},this._tags,(e=e).tags),this._extra=uyt({},this._extra,e.extra),this._contexts=uyt({},this._contexts,e.contexts),e.user&&(this._user=e.user),e.level&&(this._level=e.level),e.fingerprint&&(this._fingerprint=e.fingerprint)),this},t.prototype.clear=function(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._span=void 0,this._notifyScopeListeners(),this},t.prototype.addBreadcrumb=function(t,e){var n=uyt({timestamp:Object(fyt.l)()},t);return this._breadcrumbs=void 0!==e&&e>=0?dyt(this._breadcrumbs,[n]).slice(-e):dyt(this._breadcrumbs,[n]),this._notifyScopeListeners(),this},t.prototype.clearBreadcrumbs=function(){return this._breadcrumbs=[],this._notifyScopeListeners(),this},t.prototype._applyFingerprint=function(t){t.fingerprint=t.fingerprint?Array.isArray(t.fingerprint)?t.fingerprint:[t.fingerprint]:[],this._fingerprint&&(t.fingerprint=t.fingerprint.concat(this._fingerprint)),t.fingerprint&&!t.fingerprint.length&&delete t.fingerprint},t.prototype.applyToEvent=function(t,e){return this._extra&&Object.keys(this._extra).length&&(t.extra=uyt({},this._extra,t.extra)),this._tags&&Object.keys(this._tags).length&&(t.tags=uyt({},this._tags,t.tags)),this._user&&Object.keys(this._user).length&&(t.user=uyt({},this._user,t.user)),this._contexts&&Object.keys(this._contexts).length&&(t.contexts=uyt({},this._contexts,t.contexts)),this._level&&(t.level=this._level),this._transactionName&&(t.transaction=this._transactionName),this._span&&(t.contexts=uyt({trace:this._span.getTraceContext()},t.contexts)),this._applyFingerprint(t),t.breadcrumbs=dyt(t.breadcrumbs||[],this._breadcrumbs),t.breadcrumbs=t.breadcrumbs.length>0?t.breadcrumbs:void 0,this._notifyEventProcessors(dyt(wyt(),this._eventProcessors),t,e)},t}();function wyt(){var t=Object(fyt.f)();return t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.globalEventProcessors=t.__SENTRY__.globalEventProcessors||[],t.__SENTRY__.globalEventProcessors}function kyt(t){wyt().push(t)}var Cyt,Syt=function(){function t(t,e,n){void 0===e&&(e=new _yt),void 0===n&&(n=3),this._version=n,this._stack=[],this._stack.push({client:t,scope:e}),this.bindClient(t)}return t.prototype._invokeClient=function(t){for(var e,n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];var r=this.getStackTop();r&&r.client&&r.client[t]&&(e=r.client)[t].apply(e,dyt(n,[r.scope]))},t.prototype.isOlderThan=function(t){return this._version<t},t.prototype.bindClient=function(t){this.getStackTop().client=t,t&&t.setupIntegrations&&t.setupIntegrations()},t.prototype.pushScope=function(){var t=this.getStack(),e=_yt.clone(t.length>0?t[t.length-1].scope:void 0);return this.getStack().push({client:this.getClient(),scope:e}),e},t.prototype.popScope=function(){return void 0!==this.getStack().pop()},t.prototype.withScope=function(t){var e=this.pushScope();try{t(e)}finally{this.popScope()}},t.prototype.getClient=function(){return this.getStackTop().client},t.prototype.getScope=function(){return this.getStackTop().scope},t.prototype.getStack=function(){return this._stack},t.prototype.getStackTop=function(){return this._stack[this._stack.length-1]},t.prototype.captureException=function(t,e){var n=this._lastEventId=Object(fyt.m)(),i=e;if(!e){var r=void 0;try{throw new Error("Sentry syntheticException")}catch(t){r=t}i={originalException:t,syntheticException:r}}return this._invokeClient("captureException",t,uyt({},i,{event_id:n})),n},t.prototype.captureMessage=function(t,e,n){var i=this._lastEventId=Object(fyt.m)(),r=n;if(!n){var o=void 0;try{throw new Error(t)}catch(a){o=a}r={originalException:t,syntheticException:o}}return this._invokeClient("captureMessage",t,e,uyt({},r,{event_id:i})),i},t.prototype.captureEvent=function(t,e){var n=this._lastEventId=Object(fyt.m)();return this._invokeClient("captureEvent",t,uyt({},e,{event_id:n})),n},t.prototype.lastEventId=function(){return this._lastEventId},t.prototype.addBreadcrumb=function(t,e){var n=this.getStackTop();if(n.scope&&n.client){var i=n.client.getOptions&&n.client.getOptions()||{},r=i.beforeBreadcrumb,o=void 0===r?null:r,a=i.maxBreadcrumbs,s=void 0===a?100:a;if(!(s<=0)){var c=Object(fyt.l)(),l=uyt({timestamp:c},t),u=o?Object(fyt.c)((function(){return o(l,e)})):l;null!==u&&n.scope.addBreadcrumb(u,Math.min(s,100))}}},t.prototype.setUser=function(t){var e=this.getStackTop();e.scope&&e.scope.setUser(t)},t.prototype.setTags=function(t){var e=this.getStackTop();e.scope&&e.scope.setTags(t)},t.prototype.setExtras=function(t){var e=this.getStackTop();e.scope&&e.scope.setExtras(t)},t.prototype.setTag=function(t,e){var n=this.getStackTop();n.scope&&n.scope.setTag(t,e)},t.prototype.setExtra=function(t,e){var n=this.getStackTop();n.scope&&n.scope.setExtra(t,e)},t.prototype.setContext=function(t,e){var n=this.getStackTop();n.scope&&n.scope.setContext(t,e)},t.prototype.configureScope=function(t){var e=this.getStackTop();e.scope&&e.client&&t(e.scope)},t.prototype.run=function(t){var e=Oyt(this);try{t(this)}finally{Oyt(e)}},t.prototype.getIntegration=function(t){var e=this.getClient();if(!e)return null;try{return e.getIntegration(t)}catch(n){return vyt.warn("Cannot retrieve integration "+t.id+" from the current Hub"),null}},t.prototype.startSpan=function(t){return this._callExtensionMethod("startSpan",t)},t.prototype.startTransaction=function(t){return this._callExtensionMethod("startTransaction",t)},t.prototype.traceHeaders=function(){return this._callExtensionMethod("traceHeaders")},t.prototype._callExtensionMethod=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];var i=xyt(),r=i.__SENTRY__;if(r&&r.extensions&&"function"==typeof r.extensions[t])return r.extensions[t].apply(this,e);vyt.warn("Extension method "+t+" couldn't be found, doing nothing.")},t}();function xyt(){var t=Object(fyt.f)();return t.__SENTRY__=t.__SENTRY__||{extensions:{},hub:void 0},t}function Oyt(t){var e=xyt(),n=Eyt(e);return Pyt(e,t),n}function Myt(){var t=xyt();return Tyt(t)&&!Eyt(t).isOlderThan(3)||Pyt(t,new Syt),Object(fyt.i)()?function(t){try{var e=xyt().__SENTRY__;if(!e||!e.extensions||!e.extensions.domain)return Eyt(t);var n=e.extensions.domain.active;if(!n)return Eyt(t);if(!Tyt(n)||Eyt(n).isOlderThan(3)){var i=Eyt(t).getStackTop();Pyt(n,new Syt(i.client,_yt.clone(i.scope)))}return Eyt(n)}catch(r){return Eyt(t)}}(t):Eyt(t)}function Tyt(t){return!!(t&&t.__SENTRY__&&t.__SENTRY__.hub)}function Eyt(t){return t&&t.__SENTRY__&&t.__SENTRY__.hub||(t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.hub=new Syt),t.__SENTRY__.hub}function Pyt(t,e){return!!t&&(t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.hub=e,!0)}function Ayt(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];var i=Myt();if(i&&i[t])return i[t].apply(i,dyt(e));throw new Error("No hub defined or "+t+" was not found on the hub, please open a bug report.")}function jyt(t,e){var n;try{throw new Error("Sentry syntheticException")}catch(t){n=t}return Ayt("captureException",t,{captureContext:e,originalException:t,syntheticException:n})}function Iyt(t){Ayt("withScope",t)}var Dyt=function(){function t(){this.name=t.id}return t.prototype.setupOnce=function(){Cyt=Function.prototype.toString,Function.prototype.toString=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var n=this.__sentry_original__||this;return Cyt.apply(n,t)}},t.id="FunctionToString",t}(),Ryt=n("7Ki+"),Lyt=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/],Fyt=function(){function t(e){void 0===e&&(e={}),this._options=e,this.name=t.id}return t.prototype.setupOnce=function(){kyt((function(e){var n=Myt();if(!n)return e;var i=n.getIntegration(t);if(i){var r=n.getClient(),o=r?r.getOptions():{},a=i._mergeOptions(o);if(i._shouldDropEvent(e,a))return null}return e}))},t.prototype._shouldDropEvent=function(t,e){return this._isSentryError(t,e)?(vyt.warn("Event dropped due to being internal Sentry Error.\nEvent: "+Object(fyt.d)(t)),!0):this._isIgnoredError(t,e)?(vyt.warn("Event dropped due to being matched by `ignoreErrors` option.\nEvent: "+Object(fyt.d)(t)),!0):this._isDeniedUrl(t,e)?(vyt.warn("Event dropped due to being matched by `denyUrls` option.\nEvent: "+Object(fyt.d)(t)+".\nUrl: "+this._getEventFilterUrl(t)),!0):!this._isAllowedUrl(t,e)&&(vyt.warn("Event dropped due to not being matched by `allowUrls` option.\nEvent: "+Object(fyt.d)(t)+".\nUrl: "+this._getEventFilterUrl(t)),!0)},t.prototype._isSentryError=function(t,e){if(!e.ignoreInternal)return!1;try{return t&&t.exception&&t.exception.values&&t.exception.values[0]&&"SentryError"===t.exception.values[0].type||!1}catch(n){return!1}},t.prototype._isIgnoredError=function(t,e){return!(!e.ignoreErrors||!e.ignoreErrors.length)&&this._getPossibleEventMessages(t).some((function(t){return e.ignoreErrors.some((function(e){return Object(Ryt.a)(t,e)}))}))},t.prototype._isDeniedUrl=function(t,e){if(!e.denyUrls||!e.denyUrls.length)return!1;var n=this._getEventFilterUrl(t);return!!n&&e.denyUrls.some((function(t){return Object(Ryt.a)(n,t)}))},t.prototype._isAllowedUrl=function(t,e){if(!e.allowUrls||!e.allowUrls.length)return!0;var n=this._getEventFilterUrl(t);return!n||e.allowUrls.some((function(t){return Object(Ryt.a)(n,t)}))},t.prototype._mergeOptions=function(t){return void 0===t&&(t={}),{allowUrls:dyt(this._options.whitelistUrls||[],this._options.allowUrls||[],t.whitelistUrls||[],t.allowUrls||[]),denyUrls:dyt(this._options.blacklistUrls||[],this._options.denyUrls||[],t.blacklistUrls||[],t.denyUrls||[]),ignoreErrors:dyt(this._options.ignoreErrors||[],t.ignoreErrors||[],Lyt),ignoreInternal:void 0===this._options.ignoreInternal||this._options.ignoreInternal}},t.prototype._getPossibleEventMessages=function(t){if(t.message)return[t.message];if(t.exception)try{var e=t.exception.values&&t.exception.values[0]||{},n=e.type,i=e.value,r=void 0===i?"":i;return[""+r,(void 0===n?"":n)+": "+r]}catch(o){return vyt.error("Cannot extract message for event "+Object(fyt.d)(t)),[]}return[]},t.prototype._getEventFilterUrl=function(t){try{if(t.stacktrace){var e=t.stacktrace.frames;return e&&e[e.length-1].filename||null}if(t.exception){var n=t.exception.values&&t.exception.values[0].stacktrace&&t.exception.values[0].stacktrace.frames;return n&&n[n.length-1].filename||null}return null}catch(i){return vyt.error("Cannot extract url for event "+Object(fyt.d)(t)),null}},t.id="InboundFilters",t}(),Nyt=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){return t.__proto__=e,t}:function(t,e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n]);return t}),Byt=function(t){function e(e){var n=this.constructor,i=t.call(this,e)||this;return i.message=e,i.name=n.prototype.constructor.name,Nyt(i,n.prototype),i}return lyt(e,t),e}(Error),Hyt=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w\.-]+)(?::(\d+))?\/(.+)/,zyt=function(){function t(t){"string"==typeof t?this._fromString(t):this._fromComponents(t),this._validate()}return t.prototype.toString=function(t){void 0===t&&(t=!1);var e=this,n=e.path,i=e.pass,r=e.port;return e.protocol+"://"+e.user+(t&&i?":"+i:"")+"@"+e.host+(r?":"+r:"")+"/"+(n?n+"/":n)+e.projectId},t.prototype._fromString=function(t){var e=Hyt.exec(t);if(!e)throw new Byt("Invalid Dsn");var n=hyt(e.slice(1),6),i=n[0],r=n[1],o=n[2],a=void 0===o?"":o,s=n[3],c=n[4],l=void 0===c?"":c,u="",h=n[5],d=h.split("/");if(d.length>1&&(u=d.slice(0,-1).join("/"),h=d.pop()),h){var f=h.match(/^\d+/);f&&(h=f[0])}this._fromComponents({host:s,pass:a,path:u,projectId:h,port:l,protocol:i,user:r})},t.prototype._fromComponents=function(t){this.protocol=t.protocol,this.user=t.user,this.pass=t.pass||"",this.host=t.host,this.port=t.port||"",this.path=t.path||"",this.projectId=t.projectId},t.prototype._validate=function(){var t=this;if(["protocol","user","host","projectId"].forEach((function(e){if(!t[e])throw new Byt("Invalid Dsn: "+e+" missing")})),!this.projectId.match(/^\d+$/))throw new Byt("Invalid Dsn: Invalid projectId "+this.projectId);if("http"!==this.protocol&&"https"!==this.protocol)throw new Byt("Invalid Dsn: Invalid protocol "+this.protocol);if(this.port&&isNaN(parseInt(this.port,10)))throw new Byt("Invalid Dsn: Invalid port "+this.port)},t}(),Vyt=function(){function t(){this._hasWeakSet="function"==typeof WeakSet,this._inner=this._hasWeakSet?new WeakSet:[]}return t.prototype.memoize=function(t){if(this._hasWeakSet)return!!this._inner.has(t)||(this._inner.add(t),!1);for(var e=0;e<this._inner.length;e++)if(this._inner[e]===t)return!0;return this._inner.push(t),!1},t.prototype.unmemoize=function(t){if(this._hasWeakSet)this._inner.delete(t);else for(var e=0;e<this._inner.length;e++)if(this._inner[e]===t){this._inner.splice(e,1);break}},t}();function Uyt(t,e,n){if(e in t){var i=t[e],r=n(i);if("function"==typeof r)try{r.prototype=r.prototype||{},Object.defineProperties(r,{__sentry_original__:{enumerable:!1,value:i}})}catch(o){}t[e]=r}}function qyt(t){if(Object(byt.d)(t)){var e=t,n={message:e.message,name:e.name,stack:e.stack};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i]);return n}if(Object(byt.f)(t)){var r=t,o={};o.type=r.type;try{o.target=Object(byt.c)(r.target)?Object(fyt.h)(r.target):Object.prototype.toString.call(r.target)}catch(a){o.target="<unknown>"}try{o.currentTarget=Object(byt.c)(r.currentTarget)?Object(fyt.h)(r.currentTarget):Object.prototype.toString.call(r.currentTarget)}catch(a){o.currentTarget="<unknown>"}for(var i in"undefined"!=typeof CustomEvent&&Object(byt.g)(t,CustomEvent)&&(o.detail=r.detail),r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r);return o}return t}function Gyt(t,e,n){void 0===e&&(e=3),void 0===n&&(n=102400);var i=Kyt(t,e);return function(t){return~-encodeURI(t).split(/%..|./).length}(JSON.stringify(i))>n?Gyt(t,e-1,n):i}function Wyt(t,e){return"domain"===e&&t&&"object"==typeof t&&t._events?"[Domain]":"domainEmitter"===e?"[DomainEmitter]":"undefined"!=typeof global&&t===global?"[Global]":"undefined"!=typeof window&&t===window?"[Window]":"undefined"!=typeof document&&t===document?"[Document]":Object(byt.l)(t)?"[SyntheticEvent]":"number"==typeof t&&t!=t?"[NaN]":void 0===t?"[undefined]":"function"==typeof t?"[Function: "+Object(fyt.e)(t)+"]":t}function Kyt(t,e){try{return JSON.parse(JSON.stringify(t,(function(t,n){return function t(e,n,i,r){if(void 0===i&&(i=1/0),void 0===r&&(r=new Vyt),0===i)return function(t){var e=Object.prototype.toString.call(t);if("string"==typeof t)return t;if("[object Object]"===e)return"[Object]";if("[object Array]"===e)return"[Array]";var n=Wyt(t);return Object(byt.i)(n)?n:e}(n);if(null!=n&&"function"==typeof n.toJSON)return n.toJSON();var o=Wyt(n,e);if(Object(byt.i)(o))return o;var a=qyt(n),s=Array.isArray(n)?[]:{};if(r.memoize(n))return"[Circular ~]";for(var c in a)Object.prototype.hasOwnProperty.call(a,c)&&(s[c]=t(c,a[c],i-1,r));return r.unmemoize(n),s}(t,n,e)})))}catch(n){return"**non-serializable**"}}function Xyt(t,e){void 0===e&&(e=40);var n=Object.keys(qyt(t));if(n.sort(),!n.length)return"[object has no keys]";if(n[0].length>=e)return Object(Ryt.d)(n[0],e);for(var i=n.length;i>0;i--){var r=n.slice(0,i).join(", ");if(!(r.length>e))return i===n.length?r:Object(Ryt.d)(r,e)}return""}var Yyt,Zyt=function(){function t(t){this.dsn=t,this._dsnObject=new zyt(t)}return t.prototype.getDsn=function(){return this._dsnObject},t.prototype.getBaseApiEndpoint=function(){var t=this._dsnObject;return(t.protocol?t.protocol+":":"")+"//"+t.host+(t.port?":"+t.port:"")+(t.path?"/"+t.path:"")+"/api/"},t.prototype.getStoreEndpoint=function(){return this._getIngestEndpoint("store")},t.prototype._getEnvelopeEndpoint=function(){return this._getIngestEndpoint("envelope")},t.prototype._getIngestEndpoint=function(t){return""+this.getBaseApiEndpoint()+this._dsnObject.projectId+"/"+t+"/"},t.prototype.getStoreEndpointWithUrlEncodedAuth=function(){return this.getStoreEndpoint()+"?"+this._encodedAuth()},t.prototype.getEnvelopeEndpointWithUrlEncodedAuth=function(){return this._getEnvelopeEndpoint()+"?"+this._encodedAuth()},t.prototype._encodedAuth=function(){var t;return t={sentry_key:this._dsnObject.user,sentry_version:"7"},Object.keys(t).map((function(e){return encodeURIComponent(e)+"="+encodeURIComponent(t[e])})).join("&")},t.prototype.getStoreEndpointPath=function(){var t=this._dsnObject;return(t.path?"/"+t.path:"")+"/api/"+t.projectId+"/store/"},t.prototype.getRequestHeaders=function(t,e){var n=this._dsnObject,i=["Sentry sentry_version=7"];return i.push("sentry_client="+t+"/"+e),i.push("sentry_key="+n.user),n.pass&&i.push("sentry_secret="+n.pass),{"Content-Type":"application/json","X-Sentry-Auth":i.join(", ")}},t.prototype.getReportDialogEndpoint=function(t){void 0===t&&(t={});var e=this._dsnObject,n=this.getBaseApiEndpoint()+"embed/error-page/",i=[];for(var r in i.push("dsn="+e.toString()),t)if("user"===r){if(!t.user)continue;t.user.name&&i.push("name="+encodeURIComponent(t.user.name)),t.user.email&&i.push("email="+encodeURIComponent(t.user.email))}else i.push(encodeURIComponent(r)+"="+encodeURIComponent(t[r]));return i.length?n+"?"+i.join("&"):n},t}(),Qyt=[],$yt=function(){function t(t,e){this._integrations={},this._processing=!1,this._backend=new t(e),this._options=e,e.dsn&&(this._dsn=new zyt(e.dsn))}return t.prototype.captureException=function(t,e,n){var i=this,r=e&&e.event_id;return this._processing=!0,this._getBackend().eventFromException(t,e).then((function(t){r=i.captureEvent(t,e,n)})),r},t.prototype.captureMessage=function(t,e,n,i){var r=this,o=n&&n.event_id;return this._processing=!0,(Object(byt.i)(t)?this._getBackend().eventFromMessage(""+t,e,n):this._getBackend().eventFromException(t,n)).then((function(t){o=r.captureEvent(t,n,i)})),o},t.prototype.captureEvent=function(t,e,n){var i=this,r=e&&e.event_id;return this._processing=!0,this._processEvent(t,e,n).then((function(t){r=t&&t.event_id,i._processing=!1})).then(null,(function(t){vyt.error(t),i._processing=!1})),r},t.prototype.getDsn=function(){return this._dsn},t.prototype.getOptions=function(){return this._options},t.prototype.flush=function(t){var e=this;return this._isClientProcessing(t).then((function(n){return clearInterval(n.interval),e._getBackend().getTransport().close(t).then((function(t){return n.ready&&t}))}))},t.prototype.close=function(t){var e=this;return this.flush(t).then((function(t){return e.getOptions().enabled=!1,t}))},t.prototype.setupIntegrations=function(){var t;this._isEnabled()&&(this._integrations=(t={},function(t){var e=t.defaultIntegrations&&dyt(t.defaultIntegrations)||[],n=t.integrations,i=[];if(Array.isArray(n)){var r=n.map((function(t){return t.name})),o=[];e.forEach((function(t){-1===r.indexOf(t.name)&&-1===o.indexOf(t.name)&&(i.push(t),o.push(t.name))})),n.forEach((function(t){-1===o.indexOf(t.name)&&(i.push(t),o.push(t.name))}))}else"function"==typeof n?(i=n(e),i=Array.isArray(i)?i:[i]):i=dyt(e);var a=i.map((function(t){return t.name}));return-1!==a.indexOf("Debug")&&i.push.apply(i,dyt(i.splice(a.indexOf("Debug"),1))),i}(this._options).forEach((function(e){t[e.name]=e,function(t){-1===Qyt.indexOf(t.name)&&(t.setupOnce(kyt,Myt),Qyt.push(t.name),vyt.log("Integration installed: "+t.name))}(e)})),t))},t.prototype.getIntegration=function(t){try{return this._integrations[t.id]||null}catch(e){return vyt.warn("Cannot retrieve integration "+t.id+" from the current Client"),null}},t.prototype._isClientProcessing=function(t){var e=this;return new yyt((function(n){var i=0,r=0;clearInterval(r),r=setInterval((function(){e._processing?(i+=1,t&&i>=t&&n({interval:r,ready:!1})):n({interval:r,ready:!0})}),1)}))},t.prototype._getBackend=function(){return this._backend},t.prototype._isEnabled=function(){return!1!==this.getOptions().enabled&&void 0!==this._dsn},t.prototype._prepareEvent=function(t,e,n){var i=this,r=this.getOptions().normalizeDepth,o=void 0===r?3:r,a=uyt({},t,{event_id:t.event_id||(n&&n.event_id?n.event_id:Object(fyt.m)()),timestamp:t.timestamp||Object(fyt.l)()});this._applyClientOptions(a),this._applyIntegrationsMetadata(a);var s=e;n&&n.captureContext&&(s=_yt.clone(s).update(n.captureContext));var c=yyt.resolve(a);return s&&(c=s.applyToEvent(a,n)),c.then((function(t){return"number"==typeof o&&o>0?i._normalizeEvent(t,o):t}))},t.prototype._normalizeEvent=function(t,e){if(!t)return null;var n=uyt({},t,t.breadcrumbs&&{breadcrumbs:t.breadcrumbs.map((function(t){return uyt({},t,t.data&&{data:Kyt(t.data,e)})}))},t.user&&{user:Kyt(t.user,e)},t.contexts&&{contexts:Kyt(t.contexts,e)},t.extra&&{extra:Kyt(t.extra,e)});return t.contexts&&t.contexts.trace&&(n.contexts.trace=t.contexts.trace),n},t.prototype._applyClientOptions=function(t){var e=this.getOptions(),n=e.environment,i=e.release,r=e.dist,o=e.maxValueLength,a=void 0===o?250:o;void 0===t.environment&&void 0!==n&&(t.environment=n),void 0===t.release&&void 0!==i&&(t.release=i),void 0===t.dist&&void 0!==r&&(t.dist=r),t.message&&(t.message=Object(Ryt.d)(t.message,a));var s=t.exception&&t.exception.values&&t.exception.values[0];s&&s.value&&(s.value=Object(Ryt.d)(s.value,a));var c=t.request;c&&c.url&&(c.url=Object(Ryt.d)(c.url,a))},t.prototype._applyIntegrationsMetadata=function(t){var e=t.sdk,n=Object.keys(this._integrations);e&&n.length>0&&(e.integrations=n)},t.prototype._sendEvent=function(t){this._getBackend().sendEvent(t)},t.prototype._processEvent=function(t,e,n){var i=this,r=this.getOptions(),o=r.beforeSend,a=r.sampleRate;if(!this._isEnabled())return yyt.reject("SDK not enabled, will not send event.");var s="transaction"===t.type;return!s&&"number"==typeof a&&Math.random()>a?yyt.reject("This event has been sampled, will not send event."):new yyt((function(r,a){i._prepareEvent(t,n,e).then((function(t){if(null!==t){var n=t;if(e&&e.data&&!0===e.data.__sentry__||!o||s)return i._sendEvent(n),void r(n);var c=o(t,e);if(void 0===c)vyt.error("`beforeSend` method has to return `null` or a valid event.");else if(Object(byt.m)(c))i._handleAsyncBeforeSend(c,r,a);else{if(null===(n=c))return vyt.log("`beforeSend` returned `null`, will not send event."),void r(null);i._sendEvent(n),r(n)}}else a("An event processor returned null, will not send event.")})).then(null,(function(t){i.captureException(t,{data:{__sentry__:!0},originalException:t}),a("Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: "+t)}))}))},t.prototype._handleAsyncBeforeSend=function(t,e,n){var i=this;t.then((function(t){null!==t?(i._sendEvent(t),e(t)):n("`beforeSend` returned `null`, will not send event.")})).then(null,(function(t){n("beforeSend rejected with "+t)}))},t}();!function(t){t.Unknown="unknown",t.Skipped="skipped",t.Success="success",t.RateLimit="rate_limit",t.Invalid="invalid",t.Failed="failed"}(Yyt||(Yyt={})),function(t){t.fromHttpCode=function(e){return e>=200&&e<300?t.Success:429===e?t.RateLimit:e>=400&&e<500?t.Invalid:e>=500?t.Failed:t.Unknown}}(Yyt||(Yyt={}));var Jyt,t_t=function(){function t(){}return t.prototype.sendEvent=function(t){return yyt.resolve({reason:"NoopTransport: Event has been skipped because no Dsn is configured.",status:Yyt.Skipped})},t.prototype.close=function(t){return yyt.resolve(!0)},t}(),e_t=function(){function t(t){this._options=t,this._options.dsn||vyt.warn("No DSN provided, backend will not do anything."),this._transport=this._setupTransport()}return t.prototype._setupTransport=function(){return new t_t},t.prototype.eventFromException=function(t,e){throw new Byt("Backend has to implement `eventFromException` method")},t.prototype.eventFromMessage=function(t,e,n){throw new Byt("Backend has to implement `eventFromMessage` method")},t.prototype.sendEvent=function(t){this._transport.sendEvent(t).then(null,(function(t){vyt.error("Error while sending event: "+t)}))},t.prototype.getTransport=function(){return this._transport},t}();function n_t(){if(!("fetch"in Object(fyt.f)()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(t){return!1}}function i_t(t){return t&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(t.toString())}function r_t(){if(!n_t())return!1;try{return new Request("_",{referrerPolicy:"origin"}),!0}catch(t){return!1}}!function(t){t.Fatal="fatal",t.Error="error",t.Warning="warning",t.Log="log",t.Info="info",t.Debug="debug",t.Critical="critical"}(Jyt||(Jyt={})),function(t){t.fromString=function(e){switch(e){case"debug":return t.Debug;case"info":return t.Info;case"warn":case"warning":return t.Warning;case"error":return t.Error;case"fatal":return t.Fatal;case"critical":return t.Critical;case"log":default:return t.Log}}}(Jyt||(Jyt={}));var o_t=/^\s*at (?:(.*?) ?\()?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,a_t=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js))(?::(\d+))?(?::(\d+))?\s*$/i,s_t=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,c_t=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,l_t=/\((\S*)(?::(\d+))(?::(\d+))\)/;function u_t(t){var e=null,n=t&&t.framesToPop;try{if(e=function(t){if(!t||!t.stacktrace)return null;for(var e,n=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,i=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^\)]+))\((.*)\))? in (.*):\s*$/i,r=t.stacktrace.split("\n"),o=[],a=0;a<r.length;a+=2){var s=null;(e=n.exec(r[a]))?s={url:e[2],func:e[3],args:[],line:+e[1],column:null}:(e=i.exec(r[a]))&&(s={url:e[6],func:e[3]||e[4],args:e[5]?e[5].split(","):[],line:+e[1],column:+e[2]}),s&&(!s.func&&s.line&&(s.func="?"),o.push(s))}return o.length?{message:d_t(t),name:t.name,stack:o}:null}(t))return h_t(e,n)}catch(i){}try{if(e=function(t){if(!t||!t.stack)return null;for(var e,n,i,r=[],o=t.stack.split("\n"),a=0;a<o.length;++a){if(n=o_t.exec(o[a])){var s=n[2]&&0===n[2].indexOf("native");n[2]&&0===n[2].indexOf("eval")&&(e=l_t.exec(n[2]))&&(n[2]=e[1],n[3]=e[2],n[4]=e[3]),i={url:n[2]&&0===n[2].indexOf("address at ")?n[2].substr("address at ".length):n[2],func:n[1]||"?",args:s?[n[2]]:[],line:n[3]?+n[3]:null,column:n[4]?+n[4]:null}}else if(n=s_t.exec(o[a]))i={url:n[2],func:n[1]||"?",args:[],line:+n[3],column:n[4]?+n[4]:null};else{if(!(n=a_t.exec(o[a])))continue;n[3]&&n[3].indexOf(" > eval")>-1&&(e=c_t.exec(n[3]))?(n[1]=n[1]||"eval",n[3]=e[1],n[4]=e[2],n[5]=""):0!==a||n[5]||void 0===t.columnNumber||(r[0].column=t.columnNumber+1),i={url:n[3],func:n[1]||"?",args:n[2]?n[2].split(","):[],line:n[4]?+n[4]:null,column:n[5]?+n[5]:null}}!i.func&&i.line&&(i.func="?"),r.push(i)}return r.length?{message:d_t(t),name:t.name,stack:r}:null}(t))return h_t(e,n)}catch(i){}return{message:d_t(t),name:t&&t.name,stack:[],failed:!0}}function h_t(t,e){try{return uyt({},t,{stack:t.stack.slice(e)})}catch(n){return t}}function d_t(t){var e=t&&t.message;return e?e.error&&"string"==typeof e.error.message?e.error.message:e:"No error message"}function f_t(t){var e=m_t(t.stack),n={type:t.name,value:t.message};return e&&e.length&&(n.stacktrace={frames:e}),void 0===n.type&&""===n.value&&(n.value="Unrecoverable error caught"),n}function p_t(t){return{exception:{values:[f_t(t)]}}}function m_t(t){if(!t||!t.length)return[];var e=t,n=e[0].func||"",i=e[e.length-1].func||"";return-1===n.indexOf("captureMessage")&&-1===n.indexOf("captureException")||(e=e.slice(1)),-1!==i.indexOf("sentryWrapped")&&(e=e.slice(0,-1)),e.slice(0,50).map((function(t){return{colno:null===t.column?void 0:t.column,filename:t.url||e[0].url,function:t.func||"?",in_app:!0,lineno:null===t.line?void 0:t.line}})).reverse()}function g_t(t,e,n){var i;if(void 0===n&&(n={}),Object(byt.e)(t)&&t.error)return p_t(u_t(t=t.error));if(Object(byt.a)(t)||Object(byt.b)(t)){var r=t,o=r.name||(Object(byt.a)(r)?"DOMError":"DOMException"),a=r.message?o+": "+r.message:o;return i=v_t(a,e,n),Object(fyt.b)(i,a),i}return Object(byt.d)(t)?i=p_t(u_t(t)):Object(byt.h)(t)||Object(byt.f)(t)?(i=function(t,e,n){var i={exception:{values:[{type:Object(byt.f)(t)?t.constructor.name:n?"UnhandledRejection":"Error",value:"Non-Error "+(n?"promise rejection":"exception")+" captured with keys: "+Xyt(t)}]},extra:{__serialized__:Gyt(t)}};if(e){var r=m_t(u_t(e).stack);i.stacktrace={frames:r}}return i}(t,e,n.rejection),Object(fyt.a)(i,{synthetic:!0}),i):(i=v_t(t,e,n),Object(fyt.b)(i,""+t,void 0),Object(fyt.a)(i,{synthetic:!0}),i)}function v_t(t,e,n){void 0===n&&(n={});var i={message:t};if(n.attachStacktrace&&e){var r=m_t(u_t(e).stack);i.stacktrace={frames:r}}return i}function b_t(t,e){var n="transaction"===t.type,i={body:JSON.stringify(t),url:n?e.getEnvelopeEndpointWithUrlEncodedAuth():e.getStoreEndpointWithUrlEncodedAuth()};if(n){var r=JSON.stringify({event_id:t.event_id,sent_at:new Date(1e3*Object(fyt.l)()).toISOString()}),o=JSON.stringify({type:t.type});i.body=r+"\n"+o+"\n"+i.body}return i}var y_t,__t=function(){function t(t){this._limit=t,this._buffer=[]}return t.prototype.isReady=function(){return void 0===this._limit||this.length()<this._limit},t.prototype.add=function(t){var e=this;return this.isReady()?(-1===this._buffer.indexOf(t)&&this._buffer.push(t),t.then((function(){return e.remove(t)})).then(null,(function(){return e.remove(t).then(null,(function(){}))})),t):yyt.reject(new Byt("Not adding Promise due to buffer limit reached."))},t.prototype.remove=function(t){return this._buffer.splice(this._buffer.indexOf(t),1)[0]},t.prototype.length=function(){return this._buffer.length},t.prototype.drain=function(t){var e=this;return new yyt((function(n){var i=setTimeout((function(){t&&t>0&&n(!1)}),t);yyt.all(e._buffer).then((function(){clearTimeout(i),n(!0)})).then(null,(function(){n(!0)}))}))},t}(),w_t=function(){function t(t){this.options=t,this._buffer=new __t(30),this._api=new Zyt(this.options.dsn),this.url=this._api.getStoreEndpointWithUrlEncodedAuth()}return t.prototype.sendEvent=function(t){throw new Byt("Transport Class has to implement `sendEvent` method")},t.prototype.close=function(t){return this._buffer.drain(t)},t}(),k_t=Object(fyt.f)(),C_t=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._disabledUntil=new Date(Date.now()),e}return lyt(e,t),e.prototype.sendEvent=function(t){var e=this;if(new Date(Date.now())<this._disabledUntil)return Promise.reject({event:t,reason:"Transport locked till "+this._disabledUntil+" due to too many requests.",status:429});var n=b_t(t,this._api),i={body:n.body,method:"POST",referrerPolicy:r_t()?"origin":""};return void 0!==this.options.fetchParameters&&Object.assign(i,this.options.fetchParameters),void 0!==this.options.headers&&(i.headers=this.options.headers),this._buffer.add(new yyt((function(t,r){k_t.fetch(n.url,i).then((function(n){var i=Yyt.fromHttpCode(n.status);if(i!==Yyt.Success){if(i===Yyt.RateLimit){var o=Date.now();e._disabledUntil=new Date(o+Object(fyt.j)(o,n.headers.get("Retry-After"))),vyt.warn("Too many requests, backing off till: "+e._disabledUntil)}r(n)}else t({status:i})})).catch(r)})))},e}(w_t),S_t=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._disabledUntil=new Date(Date.now()),e}return lyt(e,t),e.prototype.sendEvent=function(t){var e=this;if(new Date(Date.now())<this._disabledUntil)return Promise.reject({event:t,reason:"Transport locked till "+this._disabledUntil+" due to too many requests.",status:429});var n=b_t(t,this._api);return this._buffer.add(new yyt((function(t,i){var r=new XMLHttpRequest;for(var o in r.onreadystatechange=function(){if(4===r.readyState){var n=Yyt.fromHttpCode(r.status);if(n!==Yyt.Success){if(n===Yyt.RateLimit){var o=Date.now();e._disabledUntil=new Date(o+Object(fyt.j)(o,r.getResponseHeader("Retry-After"))),vyt.warn("Too many requests, backing off till: "+e._disabledUntil)}i(r)}else t({status:n})}},r.open("POST",n.url),e.options.headers)e.options.headers.hasOwnProperty(o)&&r.setRequestHeader(o,e.options.headers[o]);r.send(n.body)})))},e}(w_t),x_t=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return lyt(e,t),e.prototype._setupTransport=function(){if(!this._options.dsn)return t.prototype._setupTransport.call(this);var e=uyt({},this._options.transportOptions,{dsn:this._options.dsn});return this._options.transport?new this._options.transport(e):n_t()?new C_t(e):new S_t(e)},e.prototype.eventFromException=function(t,e){var n=g_t(t,e&&e.syntheticException||void 0,{attachStacktrace:this._options.attachStacktrace});return Object(fyt.a)(n,{handled:!0,type:"generic"}),n.level=Jyt.Error,e&&e.event_id&&(n.event_id=e.event_id),yyt.resolve(n)},e.prototype.eventFromMessage=function(t,e,n){void 0===e&&(e=Jyt.Info);var i=v_t(t,n&&n.syntheticException||void 0,{attachStacktrace:this._options.attachStacktrace});return i.level=e,n&&n.event_id&&(i.event_id=n.event_id),yyt.resolve(i)},e}(e_t),O_t=Object(fyt.f)(),M_t={},T_t={};function E_t(t){t&&"string"==typeof t.type&&"function"==typeof t.callback&&(M_t[t.type]=M_t[t.type]||[],M_t[t.type].push(t.callback),function(t){if(!T_t[t])switch(T_t[t]=!0,t){case"console":"console"in O_t&&["debug","info","warn","error","log","assert"].forEach((function(t){t in O_t.console&&Uyt(O_t.console,t,(function(e){return function(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];P_t("console",{args:n,level:t}),e&&Function.prototype.apply.call(e,O_t.console,n)}}))}));break;case"dom":"document"in O_t&&(O_t.document.addEventListener("click",L_t("click",P_t.bind(null,"dom")),!1),O_t.document.addEventListener("keypress",F_t(P_t.bind(null,"dom")),!1),["EventTarget","Node"].forEach((function(t){var e=O_t[t]&&O_t[t].prototype;e&&e.hasOwnProperty&&e.hasOwnProperty("addEventListener")&&(Uyt(e,"addEventListener",(function(t){return function(e,n,i){return n&&n.handleEvent?("click"===e&&Uyt(n,"handleEvent",(function(t){return function(e){return L_t("click",P_t.bind(null,"dom"))(e),t.call(this,e)}})),"keypress"===e&&Uyt(n,"handleEvent",(function(t){return function(e){return F_t(P_t.bind(null,"dom"))(e),t.call(this,e)}}))):("click"===e&&L_t("click",P_t.bind(null,"dom"),!0)(this),"keypress"===e&&F_t(P_t.bind(null,"dom"))(this)),t.call(this,e,n,i)}})),Uyt(e,"removeEventListener",(function(t){return function(e,n,i){var r=n;try{r=r&&(r.__sentry_wrapped__||r)}catch(o){}return t.call(this,e,r,i)}})))})));break;case"xhr":!function(){if("XMLHttpRequest"in O_t){var t=XMLHttpRequest.prototype;Uyt(t,"open",(function(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var i=this,r=e[1];i.__sentry_xhr__={method:Object(byt.k)(e[0])?e[0].toUpperCase():e[0],url:e[1]},Object(byt.k)(r)&&"POST"===i.__sentry_xhr__.method&&r.match(/sentry_key/)&&(i.__sentry_own_request__=!0);var o=function(){if(4===i.readyState){try{i.__sentry_xhr__&&(i.__sentry_xhr__.status_code=i.status)}catch(t){}P_t("xhr",{args:e,endTimestamp:Date.now(),startTimestamp:Date.now(),xhr:i})}};return"onreadystatechange"in i&&"function"==typeof i.onreadystatechange?Uyt(i,"onreadystatechange",(function(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return o(),t.apply(i,e)}})):i.addEventListener("readystatechange",o),t.apply(i,e)}})),Uyt(t,"send",(function(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return P_t("xhr",{args:e,startTimestamp:Date.now(),xhr:this}),t.apply(this,e)}}))}}();break;case"fetch":(function(){if(!n_t())return!1;var t=Object(fyt.f)();if(i_t(t.fetch))return!0;var e=!1,n=t.document;if(n&&"function"==typeof n.createElement)try{var i=n.createElement("iframe");i.hidden=!0,n.head.appendChild(i),i.contentWindow&&i.contentWindow.fetch&&(e=i_t(i.contentWindow.fetch)),n.head.removeChild(i)}catch(r){vyt.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return e})()&&Uyt(O_t,"fetch",(function(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var i={args:e,fetchData:{method:A_t(e),url:j_t(e)},startTimestamp:Date.now()};return P_t("fetch",uyt({},i)),t.apply(O_t,e).then((function(t){return P_t("fetch",uyt({},i,{endTimestamp:Date.now(),response:t})),t}),(function(t){throw P_t("fetch",uyt({},i,{endTimestamp:Date.now(),error:t})),t}))}}));break;case"history":!function(){if(function(){var t=Object(fyt.f)(),e=t.chrome;return!(e&&e.app&&e.app.runtime||!("history"in t)||!t.history.pushState||!t.history.replaceState)}()){var t=O_t.onpopstate;O_t.onpopstate=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var i=O_t.location.href,r=y_t;if(y_t=i,P_t("history",{from:r,to:i}),t)return t.apply(this,e)},Uyt(O_t.history,"pushState",e),Uyt(O_t.history,"replaceState",e)}function e(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var i=e.length>2?e[2]:void 0;if(i){var r=y_t,o=String(i);y_t=o,P_t("history",{from:r,to:o})}return t.apply(this,e)}}}();break;case"error":N_t=O_t.onerror,O_t.onerror=function(t,e,n,i,r){return P_t("error",{column:i,error:r,line:n,msg:t,url:e}),!!N_t&&N_t.apply(this,arguments)};break;case"unhandledrejection":B_t=O_t.onunhandledrejection,O_t.onunhandledrejection=function(t){return P_t("unhandledrejection",t),!B_t||B_t.apply(this,arguments)};break;default:vyt.warn("unknown instrumentation type:",t)}}(t.type))}function P_t(t,e){var n,i;if(t&&M_t[t])try{for(var r=function(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],i=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}(M_t[t]||[]),o=r.next();!o.done;o=r.next()){var a=o.value;try{a(e)}catch(s){vyt.error("Error while triggering instrumentation handler.\nType: "+t+"\nName: "+Object(fyt.e)(a)+"\nError: "+s)}}}catch(c){n={error:c}}finally{try{o&&!o.done&&(i=r.return)&&i.call(r)}finally{if(n)throw n.error}}}function A_t(t){return void 0===t&&(t=[]),"Request"in O_t&&Object(byt.g)(t[0],Request)&&t[0].method?String(t[0].method).toUpperCase():t[1]&&t[1].method?String(t[1].method).toUpperCase():"GET"}function j_t(t){return void 0===t&&(t=[]),"string"==typeof t[0]?t[0]:"Request"in O_t&&Object(byt.g)(t[0],Request)?t[0].url:String(t[0])}var I_t,D_t,R_t=0;function L_t(t,e,n){return void 0===n&&(n=!1),function(i){I_t=void 0,i&&D_t!==i&&(D_t=i,R_t&&clearTimeout(R_t),n?R_t=setTimeout((function(){e({event:i,name:t})})):e({event:i,name:t}))}}function F_t(t){return function(e){var n;try{n=e.target}catch(r){return}var i=n&&n.tagName;i&&("INPUT"===i||"TEXTAREA"===i||n.isContentEditable)&&(I_t||L_t("input",t)(e),clearTimeout(I_t),I_t=setTimeout((function(){I_t=void 0}),1e3))}}var N_t=null,B_t=null,H_t=function(){function t(e){this.name=t.id,this._options=uyt({console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0},e)}return t.prototype.addSentryBreadcrumb=function(t){this._options.sentry&&Myt().addBreadcrumb({category:"sentry."+("transaction"===t.type?"transaction":"event"),event_id:t.event_id,level:t.level,message:Object(fyt.d)(t)},{event:t})},t.prototype._consoleBreadcrumb=function(t){var e={category:"console",data:{arguments:t.args,logger:"console"},level:Jyt.fromString(t.level),message:Object(Ryt.b)(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;e.message="Assertion failed: "+(Object(Ryt.b)(t.args.slice(1)," ")||"console.assert"),e.data.arguments=t.args.slice(1)}Myt().addBreadcrumb(e,{input:t.args,level:t.level})},t.prototype._domBreadcrumb=function(t){var e;try{e=t.event.target?Object(fyt.h)(t.event.target):Object(fyt.h)(t.event)}catch(n){e="<unknown>"}0!==e.length&&Myt().addBreadcrumb({category:"ui."+t.name,message:e},{event:t.event,name:t.name})},t.prototype._xhrBreadcrumb=function(t){if(t.endTimestamp){if(t.xhr.__sentry_own_request__)return;Myt().addBreadcrumb({category:"xhr",data:t.xhr.__sentry_xhr__,type:"http"},{xhr:t.xhr})}},t.prototype._fetchBreadcrumb=function(t){t.endTimestamp&&(t.fetchData.url.match(/sentry_key/)&&"POST"===t.fetchData.method||(t.error?Myt().addBreadcrumb({category:"fetch",data:t.fetchData,level:Jyt.Error,type:"http"},{data:t.error,input:t.args}):Myt().addBreadcrumb({category:"fetch",data:uyt({},t.fetchData,{status_code:t.response.status}),type:"http"},{input:t.args,response:t.response})))},t.prototype._historyBreadcrumb=function(t){var e=Object(fyt.f)(),n=t.from,i=t.to,r=Object(fyt.k)(e.location.href),o=Object(fyt.k)(n),a=Object(fyt.k)(i);o.path||(o=r),r.protocol===a.protocol&&r.host===a.host&&(i=a.relative),r.protocol===o.protocol&&r.host===o.host&&(n=o.relative),Myt().addBreadcrumb({category:"navigation",data:{from:n,to:i}})},t.prototype.setupOnce=function(){var t=this;this._options.console&&E_t({callback:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];t._consoleBreadcrumb.apply(t,dyt(e))},type:"console"}),this._options.dom&&E_t({callback:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];t._domBreadcrumb.apply(t,dyt(e))},type:"dom"}),this._options.xhr&&E_t({callback:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];t._xhrBreadcrumb.apply(t,dyt(e))},type:"xhr"}),this._options.fetch&&E_t({callback:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];t._fetchBreadcrumb.apply(t,dyt(e))},type:"fetch"}),this._options.history&&E_t({callback:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];t._historyBreadcrumb.apply(t,dyt(e))},type:"history"})},t.id="Breadcrumbs",t}(),z_t=function(t){function e(e){return void 0===e&&(e={}),t.call(this,x_t,e)||this}return lyt(e,t),e.prototype._prepareEvent=function(e,n,i){return e.platform=e.platform||"javascript",e.sdk=uyt({},e.sdk,{name:"sentry.javascript.browser",packages:dyt(e.sdk&&e.sdk.packages||[],[{name:"npm:@sentry/browser",version:"5.19.0"}]),version:"5.19.0"}),t.prototype._prepareEvent.call(this,e,n,i)},e.prototype._sendEvent=function(e){var n=this.getIntegration(H_t);n&&n.addSentryBreadcrumb(e),t.prototype._sendEvent.call(this,e)},e.prototype.showReportDialog=function(t){void 0===t&&(t={});var e=Object(fyt.f)().document;if(e)if(this._isEnabled()){var n=t.dsn||this.getDsn();if(t.eventId)if(n){var i=e.createElement("script");i.async=!0,i.src=new Zyt(n).getReportDialogEndpoint(t),t.onLoad&&(i.onload=t.onLoad),(e.head||e.body).appendChild(i)}else vyt.error("Missing `Dsn` option in showReportDialog call");else vyt.error("Missing `eventId` option in showReportDialog call")}else vyt.error("Trying to call showReportDialog with Sentry Client is disabled")},e}($yt),V_t=0;function U_t(){return V_t>0}function q_t(){V_t+=1,setTimeout((function(){V_t-=1}))}function G_t(t,e,n){if(void 0===e&&(e={}),"function"!=typeof t)return t;try{if(t.__sentry__)return t;if(t.__sentry_wrapped__)return t.__sentry_wrapped__}catch(o){return t}var i=function(){var i=Array.prototype.slice.call(arguments);try{n&&"function"==typeof n&&n.apply(this,arguments);var r=i.map((function(t){return G_t(t,e)}));return t.handleEvent?t.handleEvent.apply(this,r):t.apply(this,r)}catch(o){throw q_t(),Iyt((function(t){t.addEventProcessor((function(t){var n=uyt({},t);return e.mechanism&&(Object(fyt.b)(n,void 0,void 0),Object(fyt.a)(n,e.mechanism)),n.extra=uyt({},n.extra,{arguments:i}),n})),jyt(o)})),o}};try{for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(i[r]=t[r])}catch(a){}t.prototype=t.prototype||{},i.prototype=t.prototype,Object.defineProperty(t,"__sentry_wrapped__",{enumerable:!1,value:i}),Object.defineProperties(i,{__sentry__:{enumerable:!1,value:!0},__sentry_original__:{enumerable:!1,value:t}});try{Object.getOwnPropertyDescriptor(i,"name").configurable&&Object.defineProperty(i,"name",{get:function(){return t.name}})}catch(a){}return i}var W_t=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],K_t=function(){function t(e){this.name=t.id,this._options=uyt({XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0},e)}return t.prototype._wrapTimeFunction=function(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var i=e[0];return e[0]=G_t(i,{mechanism:{data:{function:Object(fyt.e)(t)},handled:!0,type:"instrument"}}),t.apply(this,e)}},t.prototype._wrapRAF=function(t){return function(e){return t.call(this,G_t(e,{mechanism:{data:{function:"requestAnimationFrame",handler:Object(fyt.e)(t)},handled:!0,type:"instrument"}}))}},t.prototype._wrapEventTarget=function(t){var e=Object(fyt.f)(),n=e[t]&&e[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(Uyt(n,"addEventListener",(function(e){return function(n,i,r){try{"function"==typeof i.handleEvent&&(i.handleEvent=G_t(i.handleEvent.bind(i),{mechanism:{data:{function:"handleEvent",handler:Object(fyt.e)(i),target:t},handled:!0,type:"instrument"}}))}catch(o){}return e.call(this,n,G_t(i,{mechanism:{data:{function:"addEventListener",handler:Object(fyt.e)(i),target:t},handled:!0,type:"instrument"}}),r)}})),Uyt(n,"removeEventListener",(function(t){return function(e,n,i){var r=n;try{r=r&&(r.__sentry_wrapped__||r)}catch(o){}return t.call(this,e,r,i)}})))},t.prototype._wrapXHR=function(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var i=this,r=["onload","onerror","onprogress","onreadystatechange"];return r.forEach((function(t){t in i&&"function"==typeof i[t]&&Uyt(i,t,(function(e){var n={mechanism:{data:{function:t,handler:Object(fyt.e)(e)},handled:!0,type:"instrument"}};return e.__sentry_original__&&(n.mechanism.data.handler=Object(fyt.e)(e.__sentry_original__)),G_t(e,n)}))})),t.apply(this,e)}},t.prototype.setupOnce=function(){var t=Object(fyt.f)();this._options.setTimeout&&Uyt(t,"setTimeout",this._wrapTimeFunction.bind(this)),this._options.setInterval&&Uyt(t,"setInterval",this._wrapTimeFunction.bind(this)),this._options.requestAnimationFrame&&Uyt(t,"requestAnimationFrame",this._wrapRAF.bind(this)),this._options.XMLHttpRequest&&"XMLHttpRequest"in t&&Uyt(XMLHttpRequest.prototype,"send",this._wrapXHR.bind(this)),this._options.eventTarget&&(Array.isArray(this._options.eventTarget)?this._options.eventTarget:W_t).forEach(this._wrapEventTarget.bind(this))},t.id="TryCatch",t}(),X_t=function(){function t(e){this.name=t.id,this._onErrorHandlerInstalled=!1,this._onUnhandledRejectionHandlerInstalled=!1,this._options=uyt({onerror:!0,onunhandledrejection:!0},e)}return t.prototype.setupOnce=function(){Error.stackTraceLimit=50,this._options.onerror&&(vyt.log("Global Handler attached: onerror"),this._installGlobalOnErrorHandler()),this._options.onunhandledrejection&&(vyt.log("Global Handler attached: onunhandledrejection"),this._installGlobalOnUnhandledRejectionHandler())},t.prototype._installGlobalOnErrorHandler=function(){var e=this;this._onErrorHandlerInstalled||(E_t({callback:function(n){var i=n.error,r=Myt(),o=r.getIntegration(t),a=i&&!0===i.__sentry_own_request__;if(o&&!U_t()&&!a){var s=r.getClient(),c=Object(byt.i)(i)?e._eventFromIncompleteOnError(n.msg,n.url,n.line,n.column):e._enhanceEventWithInitialFrame(g_t(i,void 0,{attachStacktrace:s&&s.getOptions().attachStacktrace,rejection:!1}),n.url,n.line,n.column);Object(fyt.a)(c,{handled:!1,type:"onerror"}),r.captureEvent(c,{originalException:i})}},type:"error"}),this._onErrorHandlerInstalled=!0)},t.prototype._installGlobalOnUnhandledRejectionHandler=function(){var e=this;this._onUnhandledRejectionHandlerInstalled||(E_t({callback:function(n){var i=n;try{"reason"in n?i=n.reason:"detail"in n&&"reason"in n.detail&&(i=n.detail.reason)}catch(l){}var r=Myt(),o=r.getIntegration(t),a=i&&!0===i.__sentry_own_request__;if(!o||U_t()||a)return!0;var s=r.getClient(),c=Object(byt.i)(i)?e._eventFromIncompleteRejection(i):g_t(i,void 0,{attachStacktrace:s&&s.getOptions().attachStacktrace,rejection:!0});c.level=Jyt.Error,Object(fyt.a)(c,{handled:!1,type:"onunhandledrejection"}),r.captureEvent(c,{originalException:i})},type:"unhandledrejection"}),this._onUnhandledRejectionHandlerInstalled=!0)},t.prototype._eventFromIncompleteOnError=function(t,e,n,i){var r,o=Object(byt.e)(t)?t.message:t;if(Object(byt.k)(o)){var a=o.match(/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i);a&&(r=a[1],o=a[2])}return this._enhanceEventWithInitialFrame({exception:{values:[{type:r||"Error",value:o}]}},e,n,i)},t.prototype._eventFromIncompleteRejection=function(t){return{exception:{values:[{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+t}]}}},t.prototype._enhanceEventWithInitialFrame=function(t,e,n,i){t.exception=t.exception||{},t.exception.values=t.exception.values||[],t.exception.values[0]=t.exception.values[0]||{},t.exception.values[0].stacktrace=t.exception.values[0].stacktrace||{},t.exception.values[0].stacktrace.frames=t.exception.values[0].stacktrace.frames||[];var r=isNaN(parseInt(i,10))?void 0:i,o=isNaN(parseInt(n,10))?void 0:n,a=Object(byt.k)(e)&&e.length>0?e:Object(fyt.g)();return 0===t.exception.values[0].stacktrace.frames.length&&t.exception.values[0].stacktrace.frames.push({colno:r,filename:a,function:"?",in_app:!0,lineno:o}),t},t.id="GlobalHandlers",t}(),Y_t=function(){function t(e){void 0===e&&(e={}),this.name=t.id,this._key=e.key||"cause",this._limit=e.limit||5}return t.prototype.setupOnce=function(){kyt((function(e,n){var i=Myt().getIntegration(t);return i?i._handler(e,n):e}))},t.prototype._handler=function(t,e){if(!(t.exception&&t.exception.values&&e&&Object(byt.g)(e.originalException,Error)))return t;var n=this._walkErrorTree(e.originalException,this._key);return t.exception.values=dyt(n,t.exception.values),t},t.prototype._walkErrorTree=function(t,e,n){if(void 0===n&&(n=[]),!Object(byt.g)(t[e],Error)||n.length+1>=this._limit)return n;var i=f_t(u_t(t[e]));return this._walkErrorTree(t[e],e,dyt([i],n))},t.id="LinkedErrors",t}(),Z_t=Object(fyt.f)(),Q_t=function(){function t(){this.name=t.id}return t.prototype.setupOnce=function(){kyt((function(e){if(Myt().getIntegration(t)){if(!Z_t.navigator||!Z_t.location)return e;var n=e.request||{};return n.url=n.url||Z_t.location.href,n.headers=n.headers||{},n.headers["User-Agent"]=Z_t.navigator.userAgent,uyt({},e,{request:n})}return e}))},t.id="UserAgent",t}(),$_t=[new r.InboundFilters,new r.FunctionToString,new K_t,new H_t,new X_t,new Y_t,new Q_t];!function(t){if(void 0===t&&(t={}),void 0===t.defaultIntegrations&&(t.defaultIntegrations=$_t),void 0===t.release){var e=Object(fyt.f)();e.SENTRY_RELEASE&&e.SENTRY_RELEASE.id&&(t.release=e.SENTRY_RELEASE.id)}!function(t,e){!0===e.debug&&vyt.enable();var n=Myt(),i=new t(e);n.bindClient(i)}(z_t,t)}({dsn:"https://5ef1859eb22d496390bdb4a673120b9d@o19455.ingest.sentry.io/842726"});var J_t=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return zQ(e,t),e.prototype.handleError=function(e){if(e.error&&e.error.status&&403!==e.error.status&&404!==e.error.status&&409!==e.error.status&&t.prototype.handleError.call(this,e),e){var n=this.injector.get(Y2);e.error&&e.error.message?n.error(e.error.message):e.message?n.error(e.message):e.error&&n.error(e.error)}},e.\u0275prov=R({token:e,factory:e.\u0275fac=function(t){return twt(t||e)}}),e}(function(){function t(t){this.injector=t}return t.prototype.extractError=function(t){return t&&t.ngOriginalError&&(t=t.ngOriginalError),"string"==typeof t||t instanceof Error?t:t instanceof Ig?t.error instanceof Error?t.error:t.error instanceof ErrorEvent?t.error.message:"string"==typeof t.error?"Server returned code "+t.status+' with body "'+t.error+'"':t.message:null},t.prototype.handleError=function(t){jyt(this.extractError(t)||"Handled unknown error")},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(Xo))}}),t}()),twt=zn(J_t),ewt=["*"],nwt=[[["","mat-grid-avatar",""],["","matGridAvatar",""]],[["","mat-line",""],["","matLine",""]],"*"],iwt=["[mat-grid-avatar], [matGridAvatar]","[mat-line], [matLine]","*"],rwt=new ht("MAT_GRID_LIST"),owt=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._element=e,this._gridList=n,this._rowspan=1,this._colspan=1}return Object(g.a)(t,[{key:"_setStyle",value:function(t,e){this._element.nativeElement.style[t]=e}},{key:"rowspan",get:function(){return this._rowspan},set:function(t){this._rowspan=Math.round(im(t))}},{key:"colspan",get:function(){return this._colspan},set:function(t){this._colspan=Math.round(im(t))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(rwt,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-grid-tile"]],hostAttrs:[1,"mat-grid-tile"],hostVars:2,hostBindings:function(t,e){2&t&&oa("rowspan",e.rowspan)("colspan",e.colspan)},inputs:{rowspan:"rowspan",colspan:"colspan"},exportAs:["matGridTile"],ngContentSelectors:ewt,decls:2,vars:0,consts:[[1,"mat-figure"]],template:function(t,e){1&t&&(Ia(),ga(0,"figure",0),Da(1),va())},styles:[".mat-grid-list{display:block;position:relative}.mat-grid-tile{display:block;position:absolute;overflow:hidden}.mat-grid-tile .mat-figure{top:0;left:0;right:0;bottom:0;position:absolute;display:flex;align-items:center;justify-content:center;height:100%;padding:0;margin:0}.mat-grid-tile .mat-grid-tile-header,.mat-grid-tile .mat-grid-tile-footer{display:flex;align-items:center;height:48px;color:#fff;background:rgba(0,0,0,.38);overflow:hidden;padding:0 16px;position:absolute;left:0;right:0}.mat-grid-tile .mat-grid-tile-header>*,.mat-grid-tile .mat-grid-tile-footer>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-tile-header.mat-2-line,.mat-grid-tile .mat-grid-tile-footer.mat-2-line{height:68px}.mat-grid-tile .mat-grid-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden}.mat-grid-tile .mat-grid-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-list-text:empty{display:none}.mat-grid-tile .mat-grid-tile-header{top:0}.mat-grid-tile .mat-grid-tile-footer{bottom:0}.mat-grid-tile .mat-grid-avatar{padding-right:16px}[dir=rtl] .mat-grid-tile .mat-grid-avatar{padding-right:0;padding-left:16px}.mat-grid-tile .mat-grid-avatar:empty{display:none}\n"],encapsulation:2,changeDetection:0}),t}(),awt=function(){var t=function(){function t(e){Object(m.a)(this,t),this._element=e}return Object(g.a)(t,[{key:"ngAfterContentInit",value:function(){sJ(this._lines,this._element)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us))},t.\u0275cmp=Ht({type:t,selectors:[["mat-grid-tile-header"],["mat-grid-tile-footer"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,aJ,!0),2&t&&tl(i=sl())&&(e._lines=i)},ngContentSelectors:iwt,decls:4,vars:0,consts:[[1,"mat-grid-list-text"]],template:function(t,e){1&t&&(Ia(nwt),Da(0),ga(1,"div",0),Da(2,1),va(),Da(3,2))},encapsulation:2,changeDetection:0}),t}(),swt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","mat-grid-avatar",""],["","matGridAvatar",""]],hostAttrs:[1,"mat-grid-avatar"]}),t}(),cwt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-grid-tile-header"]],hostAttrs:[1,"mat-grid-tile-header"]}),t}(),lwt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["mat-grid-tile-footer"]],hostAttrs:[1,"mat-grid-tile-footer"]}),t}(),uwt=function(){function t(){Object(m.a)(this,t),this.columnIndex=0,this.rowIndex=0}return Object(g.a)(t,[{key:"update",value:function(t,e){var n=this;this.columnIndex=0,this.rowIndex=0,this.tracker=new Array(t),this.tracker.fill(0,0,this.tracker.length),this.positions=e.map((function(t){return n._trackTile(t)}))}},{key:"_trackTile",value:function(t){var e=this._findMatchingGap(t.colspan);return this._markTilePosition(e,t),this.columnIndex=e+t.colspan,new hwt(this.rowIndex,e)}},{key:"_findMatchingGap",value:function(t){if(t>this.tracker.length)throw Error("mat-grid-list: tile with colspan ".concat(t," is wider than ")+'grid with cols="'.concat(this.tracker.length,'".'));var e=-1,n=-1;do{this.columnIndex+t>this.tracker.length?(this._nextRow(),e=this.tracker.indexOf(0,this.columnIndex),n=this._findGapEndIndex(e)):-1!=(e=this.tracker.indexOf(0,this.columnIndex))?(n=this._findGapEndIndex(e),this.columnIndex=e+1):(this._nextRow(),e=this.tracker.indexOf(0,this.columnIndex),n=this._findGapEndIndex(e))}while(n-e<t||0==n);return Math.max(e,0)}},{key:"_nextRow",value:function(){this.columnIndex=0,this.rowIndex++;for(var t=0;t<this.tracker.length;t++)this.tracker[t]=Math.max(0,this.tracker[t]-1)}},{key:"_findGapEndIndex",value:function(t){for(var e=t+1;e<this.tracker.length;e++)if(0!=this.tracker[e])return e;return this.tracker.length}},{key:"_markTilePosition",value:function(t,e){for(var n=0;n<e.colspan;n++)this.tracker[t+n]=e.rowspan}},{key:"rowCount",get:function(){return this.rowIndex+1}},{key:"rowspan",get:function(){var t=Math.max.apply(Math,Object(u.a)(this.tracker));return t>1?this.rowCount+t-1:this.rowCount}}]),t}(),hwt=function t(e,n){Object(m.a)(this,t),this.row=e,this.col=n},dwt=/^-?\d+((\.\d+)?[A-Za-z%$]?)+$/,fwt=function(){function t(){Object(m.a)(this,t),this._rows=0,this._rowspan=0}return Object(g.a)(t,[{key:"init",value:function(t,e,n,i){this._gutterSize=bwt(t),this._rows=e.rowCount,this._rowspan=e.rowspan,this._cols=n,this._direction=i}},{key:"getBaseTileSize",value:function(t,e){return"(".concat(t,"% - (").concat(this._gutterSize," * ").concat(e,"))")}},{key:"getTilePosition",value:function(t,e){return 0===e?"0":vwt("(".concat(t," + ").concat(this._gutterSize,") * ").concat(e))}},{key:"getTileSize",value:function(t,e){return"(".concat(t," * ").concat(e,") + (").concat(e-1," * ").concat(this._gutterSize,")")}},{key:"setStyle",value:function(t,e,n){var i=100/this._cols,r=(this._cols-1)/this._cols;this.setColStyles(t,n,i,r),this.setRowStyles(t,e,i,r)}},{key:"setColStyles",value:function(t,e,n,i){var r=this.getBaseTileSize(n,i);t._setStyle("rtl"===this._direction?"right":"left",this.getTilePosition(r,e)),t._setStyle("width",vwt(this.getTileSize(r,t.colspan)))}},{key:"getGutterSpan",value:function(){return"".concat(this._gutterSize," * (").concat(this._rowspan," - 1)")}},{key:"getTileSpan",value:function(t){return"".concat(this._rowspan," * ").concat(this.getTileSize(t,1))}},{key:"getComputedHeight",value:function(){return null}}]),t}(),pwt=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this)).fixedRowHeight=t,i}return Object(g.a)(n,[{key:"init",value:function(t,e,i,r){if(Object(o.a)(Object(a.a)(n.prototype),"init",this).call(this,t,e,i,r),this.fixedRowHeight=bwt(this.fixedRowHeight),!dwt.test(this.fixedRowHeight))throw Error('Invalid value "'.concat(this.fixedRowHeight,'" set as rowHeight.'))}},{key:"setRowStyles",value:function(t,e){t._setStyle("top",this.getTilePosition(this.fixedRowHeight,e)),t._setStyle("height",vwt(this.getTileSize(this.fixedRowHeight,t.rowspan)))}},{key:"getComputedHeight",value:function(){return["height",vwt("".concat(this.getTileSpan(this.fixedRowHeight)," + ").concat(this.getGutterSpan()))]}},{key:"reset",value:function(t){t._setListStyle(["height",null]),t._tiles&&t._tiles.forEach((function(t){t._setStyle("top",null),t._setStyle("height",null)}))}}]),n}(fwt),mwt=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t){var i;return Object(m.a)(this,n),(i=e.call(this))._parseRatio(t),i}return Object(g.a)(n,[{key:"setRowStyles",value:function(t,e,n,i){this.baseTileHeight=this.getBaseTileSize(n/this.rowHeightRatio,i),t._setStyle("marginTop",this.getTilePosition(this.baseTileHeight,e)),t._setStyle("paddingTop",vwt(this.getTileSize(this.baseTileHeight,t.rowspan)))}},{key:"getComputedHeight",value:function(){return["paddingBottom",vwt("".concat(this.getTileSpan(this.baseTileHeight)," + ").concat(this.getGutterSpan()))]}},{key:"reset",value:function(t){t._setListStyle(["paddingBottom",null]),t._tiles.forEach((function(t){t._setStyle("marginTop",null),t._setStyle("paddingTop",null)}))}},{key:"_parseRatio",value:function(t){var e=t.split(":");if(2!==e.length)throw Error('mat-grid-list: invalid ratio given for row-height: "'.concat(t,'"'));this.rowHeightRatio=parseFloat(e[0])/parseFloat(e[1])}}]),n}(fwt),gwt=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return Object(g.a)(n,[{key:"setRowStyles",value:function(t,e){var n=this.getBaseTileSize(100/this._rowspan,(this._rows-1)/this._rows);t._setStyle("top",this.getTilePosition(n,e)),t._setStyle("height",vwt(this.getTileSize(n,t.rowspan)))}},{key:"reset",value:function(t){t._tiles&&t._tiles.forEach((function(t){t._setStyle("top",null),t._setStyle("height",null)}))}}]),n}(fwt);function vwt(t){return"calc(".concat(t,")")}function bwt(t){return t.match(/([A-Za-z%]+)$/)?t:"".concat(t,"px")}var ywt=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._element=e,this._dir=n,this._gutter="1px"}return Object(g.a)(t,[{key:"ngOnInit",value:function(){this._checkCols(),this._checkRowHeight()}},{key:"ngAfterContentChecked",value:function(){this._layoutTiles()}},{key:"_checkCols",value:function(){if(!this.cols)throw Error('mat-grid-list: must pass in number of columns. Example: <mat-grid-list cols="3">')}},{key:"_checkRowHeight",value:function(){this._rowHeight||this._setTileStyler("1:1")}},{key:"_setTileStyler",value:function(t){this._tileStyler&&this._tileStyler.reset(this),this._tileStyler="fit"===t?new gwt:t&&t.indexOf(":")>-1?new mwt(t):new pwt(t)}},{key:"_layoutTiles",value:function(){var t=this;this._tileCoordinator||(this._tileCoordinator=new uwt);var e=this._tileCoordinator,n=this._tiles.filter((function(e){return!e._gridList||e._gridList===t})),i=this._dir?this._dir.value:"ltr";this._tileCoordinator.update(this.cols,n),this._tileStyler.init(this.gutterSize,e,this.cols,i),n.forEach((function(n,i){var r=e.positions[i];t._tileStyler.setStyle(n,r.row,r.col)})),this._setListStyle(this._tileStyler.getComputedHeight())}},{key:"_setListStyle",value:function(t){t&&(this._element.nativeElement.style[t[0]]=t[1])}},{key:"cols",get:function(){return this._cols},set:function(t){this._cols=Math.max(1,Math.round(im(t)))}},{key:"gutterSize",get:function(){return this._gutter},set:function(t){this._gutter="".concat(null==t?"":t)}},{key:"rowHeight",get:function(){return this._rowHeight},set:function(t){var e="".concat(null==t?"":t);e!==this._rowHeight&&(this._rowHeight=e,this._setTileStyler(this._rowHeight))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(gm,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-grid-list"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,owt,!0),2&t&&tl(i=sl())&&(e._tiles=i)},hostAttrs:[1,"mat-grid-list"],hostVars:1,hostBindings:function(t,e){2&t&&oa("cols",e.cols)},inputs:{cols:"cols",gutterSize:"gutterSize",rowHeight:"rowHeight"},exportAs:["matGridList"],features:[Ns([{provide:rwt,useExisting:t}])],ngContentSelectors:ewt,decls:2,vars:0,template:function(t,e){1&t&&(Ia(),ga(0,"div"),Da(1),va())},styles:[".mat-grid-list{display:block;position:relative}.mat-grid-tile{display:block;position:absolute;overflow:hidden}.mat-grid-tile .mat-figure{top:0;left:0;right:0;bottom:0;position:absolute;display:flex;align-items:center;justify-content:center;height:100%;padding:0;margin:0}.mat-grid-tile .mat-grid-tile-header,.mat-grid-tile .mat-grid-tile-footer{display:flex;align-items:center;height:48px;color:#fff;background:rgba(0,0,0,.38);overflow:hidden;padding:0 16px;position:absolute;left:0;right:0}.mat-grid-tile .mat-grid-tile-header>*,.mat-grid-tile .mat-grid-tile-footer>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-tile-header.mat-2-line,.mat-grid-tile .mat-grid-tile-footer.mat-2-line{height:68px}.mat-grid-tile .mat-grid-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden}.mat-grid-tile .mat-grid-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-list-text:empty{display:none}.mat-grid-tile .mat-grid-tile-header{top:0}.mat-grid-tile .mat-grid-tile-footer{bottom:0}.mat-grid-tile .mat-grid-avatar{padding-right:16px}[dir=rtl] .mat-grid-tile .mat-grid-avatar{padding-right:0;padding-left:16px}.mat-grid-tile .mat-grid-avatar:empty{display:none}\n"],encapsulation:2,changeDetection:0}),t}(),_wt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[lJ,$$],lJ,$$]}),t}(),wwt=new ht("CDK_TREE_NODE_OUTLET_NODE"),kwt=function(){var t=function t(e,n){Object(m.a)(this,t),this.viewContainer=e,this._node=n};return t.\u0275fac=function(e){return new(e||t)(da(mc),da(wwt,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdkTreeNodeOutlet",""]]}),t}(),Cwt=function t(e){Object(m.a)(this,t),this.$implicit=e},Swt=function(){var t=function t(e){Object(m.a)(this,t),this.template=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["","cdkTreeNodeDef",""]],inputs:{when:["cdkTreeNodeDefWhen","when"]}}),t}();function xwt(){return Error("Could not find functions for nested/flat tree in tree control.")}var Owt=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._differs=e,this._changeDetectorRef=n,this._onDestroy=new w.b,this._levels=new Map,this.viewChange=new Pm.a({start:0,end:Number.MAX_VALUE})}return Object(g.a)(t,[{key:"ngOnInit",value:function(){if(this._dataDiffer=this._differs.find([]).create(this.trackBy),!this.treeControl)throw Error("Could not find a tree control for the tree.")}},{key:"ngOnDestroy",value:function(){this._nodeOutlet.viewContainer.clear(),this.viewChange.complete(),this._onDestroy.next(),this._onDestroy.complete(),this._dataSource&&"function"==typeof this._dataSource.disconnect&&this.dataSource.disconnect(this),this._dataSubscription&&(this._dataSubscription.unsubscribe(),this._dataSubscription=null)}},{key:"ngAfterContentChecked",value:function(){var t=this._nodeDefs.filter((function(t){return!t.when}));if(t.length>1)throw Error("There can only be one default row without a when predicate function.");this._defaultNodeDef=t[0],this.dataSource&&this._nodeDefs&&!this._dataSubscription&&this._observeRenderChanges()}},{key:"_switchDataSource",value:function(t){this._dataSource&&"function"==typeof this._dataSource.disconnect&&this.dataSource.disconnect(this),this._dataSubscription&&(this._dataSubscription.unsubscribe(),this._dataSubscription=null),t||this._nodeOutlet.viewContainer.clear(),this._dataSource=t,this._nodeDefs&&this._observeRenderChanges()}},{key:"_observeRenderChanges",value:function(){var t,e=this;if(hm(this._dataSource)?t=this._dataSource.connect(this):Object(cm.a)(this._dataSource)?t=this._dataSource:Array.isArray(this._dataSource)&&(t=Object(lm.a)(this._dataSource)),!t)throw Error("A valid data source must be provided.");this._dataSubscription=t.pipe(Object(Am.a)(this._onDestroy)).subscribe((function(t){return e.renderNodeChanges(t)}))}},{key:"renderNodeChanges",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this._dataDiffer,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this._nodeOutlet.viewContainer,r=arguments.length>3?arguments[3]:void 0,o=n.diff(t);o&&(o.forEachOperation((function(n,o,a){if(null==n.previousIndex)e.insertNode(t[a],a,i,r);else if(null==a)i.remove(o),e._levels.delete(n.item);else{var s=i.get(o);i.move(s,a)}})),this._changeDetectorRef.detectChanges())}},{key:"_getNodeDef",value:function(t,e){if(1===this._nodeDefs.length)return this._nodeDefs.first;var n=this._nodeDefs.find((function(n){return n.when&&n.when(e,t)}))||this._defaultNodeDef;if(!n)throw Error("Could not find a matching node definition for the provided node data.");return n}},{key:"insertNode",value:function(t,e,n,i){var r=this._getNodeDef(t,e),o=new Cwt(t);o.level=this.treeControl.getLevel?this.treeControl.getLevel(t):void 0!==i&&this._levels.has(i)?this._levels.get(i)+1:0,this._levels.set(t,o.level),(n||this._nodeOutlet.viewContainer).createEmbeddedView(r.template,o,e),Mwt.mostRecentTreeNode&&(Mwt.mostRecentTreeNode.data=t)}},{key:"dataSource",get:function(){return this._dataSource},set:function(t){this._dataSource!==t&&this._switchDataSource(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(cc),da(Po))},t.\u0275cmp=Ht({type:t,selectors:[["cdk-tree"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,Swt,!0),2&t&&tl(i=sl())&&(e._nodeDefs=i)},viewQuery:function(t,e){var n;1&t&&el(kwt,!0),2&t&&tl(n=sl())&&(e._nodeOutlet=n.first)},hostAttrs:["role","tree",1,"cdk-tree"],inputs:{dataSource:"dataSource",treeControl:"treeControl",trackBy:"trackBy"},exportAs:["cdkTree"],decls:1,vars:0,consts:[["cdkTreeNodeOutlet",""]],template:function(t,e){1&t&&wa(0,0)},directives:[kwt],encapsulation:2}),t}(),Mwt=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._elementRef=e,this._tree=n,this._destroyed=new w.b,this._dataChanges=new w.b,this.role="treeitem",t.mostRecentTreeNode=this}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){t.mostRecentTreeNode===this&&(t.mostRecentTreeNode=null),this._dataChanges.complete(),this._destroyed.next(),this._destroyed.complete()}},{key:"focus",value:function(){this._elementRef.nativeElement.focus()}},{key:"_setRoleFromData",value:function(){var t=this;if(this._tree.treeControl.isExpandable)this.role=this._tree.treeControl.isExpandable(this._data)?"group":"treeitem";else{if(!this._tree.treeControl.getChildren)throw xwt();var e=this._tree.treeControl.getChildren(this._data);Array.isArray(e)?this._setRoleFromChildren(e):Object(cm.a)(e)&&e.pipe(Object(Am.a)(this._destroyed)).subscribe((function(e){return t._setRoleFromChildren(e)}))}}},{key:"_setRoleFromChildren",value:function(t){this.role=t&&t.length?"group":"treeitem"}},{key:"data",get:function(){return this._data},set:function(t){t!==this._data&&(this._data=t,this._setRoleFromData(),this._dataChanges.next())}},{key:"isExpanded",get:function(){return this._tree.treeControl.isExpanded(this._data)}},{key:"level",get:function(){return this._tree.treeControl.getLevel?this._tree.treeControl.getLevel(this._data):0}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Owt))},t.\u0275dir=Wt({type:t,selectors:[["cdk-tree-node"]],hostAttrs:[1,"cdk-tree-node"],hostVars:3,hostBindings:function(t,e){2&t&&oa("aria-expanded",e.isExpanded)("aria-level","treeitem"===e.role?e.level:null)("role",e.role)},inputs:{role:"role"},exportAs:["cdkTreeNode"]}),t.mostRecentTreeNode=null,t}(),Twt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,i))._elementRef=t,o._tree=i,o._differs=r,o}return Object(g.a)(n,[{key:"ngAfterContentInit",value:function(){var t=this;if(this._dataDiffer=this._differs.find([]).create(this._tree.trackBy),!this._tree.treeControl.getChildren)throw xwt();var e=this._tree.treeControl.getChildren(this.data);Array.isArray(e)?this.updateChildrenNodes(e):Object(cm.a)(e)&&e.pipe(Object(Am.a)(this._destroyed)).subscribe((function(e){return t.updateChildrenNodes(e)})),this.nodeOutlet.changes.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){return t.updateChildrenNodes()}))}},{key:"ngOnDestroy",value:function(){this._clear(),Object(o.a)(Object(a.a)(n.prototype),"ngOnDestroy",this).call(this)}},{key:"updateChildrenNodes",value:function(t){var e=this._getNodeOutlet();t&&(this._children=t),e&&this._children?this._tree.renderNodeChanges(this._children,this._dataDiffer,e.viewContainer,this._data):this._dataDiffer.diff([])}},{key:"_clear",value:function(){var t=this._getNodeOutlet();t&&(t.viewContainer.clear(),this._dataDiffer.diff([]))}},{key:"_getNodeOutlet",value:function(){var t=this,e=this.nodeOutlet;return e&&e.find((function(e){return!e._node||e._node===t}))}}]),n}(Mwt);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Owt),da(cc))},t.\u0275dir=Wt({type:t,selectors:[["cdk-nested-tree-node"]],contentQueries:function(t,e,n){var i;1&t&&rl(n,kwt,!0),2&t&&tl(i=sl())&&(e.nodeOutlet=i)},hostAttrs:[1,"cdk-tree-node","cdk-nested-tree-node"],hostVars:2,hostBindings:function(t,e){2&t&&oa("aria-expanded",e.isExpanded)("role",e.role)},exportAs:["cdkNestedTreeNode"],features:[Ns([{provide:Mwt,useExisting:t},{provide:wwt,useExisting:t}]),ws]}),t}(),Ewt=/([A-Za-z%]+)$/,Pwt=function(){var t=function(){function t(e,n,i,r,o){var a=this;Object(m.a)(this,t),this._treeNode=e,this._tree=n,this._element=r,this._dir=o,this._destroyed=new w.b,this.indentUnits="px",this._indent=40,this._setPadding(),o&&o.change.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){return a._setPadding(!0)})),e._dataChanges.subscribe((function(){return a._setPadding()}))}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this._destroyed.next(),this._destroyed.complete()}},{key:"_paddingIndent",value:function(){var t=this._treeNode.data&&this._tree.treeControl.getLevel?this._tree.treeControl.getLevel(this._treeNode.data):null,e=null==this._level?t:this._level;return"number"==typeof e?"".concat(e*this._indent).concat(this.indentUnits):null}},{key:"_setPadding",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this._paddingIndent();if(e!==this._currentPadding||t){var n=this._element.nativeElement,i=this._dir&&"rtl"===this._dir.value?"paddingRight":"paddingLeft",r="paddingLeft"===i?"paddingRight":"paddingLeft";n.style[i]=e||"",n.style[r]="",this._currentPadding=e}}},{key:"level",get:function(){return this._level},set:function(t){this._level=im(t,null),this._setPadding()}},{key:"indent",get:function(){return this._indent},set:function(t){var e=t,n="px";if("string"==typeof t){var i=t.split(Ewt);e=i[0],n=i[1]||n}this.indentUnits=n,this._indent=im(e),this._setPadding()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Mwt),da(Owt),da(Ks),da(Us),da(gm,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdkTreeNodePadding",""]],inputs:{level:["cdkTreeNodePadding","level"],indent:["cdkTreeNodePaddingIndent","indent"]}}),t}(),Awt=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this._tree=e,this._treeNode=n,this._recursive=!1}return Object(g.a)(t,[{key:"_toggle",value:function(t){this.recursive?this._tree.treeControl.toggleDescendants(this._treeNode.data):this._tree.treeControl.toggle(this._treeNode.data),t.stopPropagation()}},{key:"recursive",get:function(){return this._recursive},set:function(t){this._recursive=nm(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Owt),da(Mwt))},t.\u0275dir=Wt({type:t,selectors:[["","cdkTreeNodeToggle",""]],hostBindings:function(t,e){1&t&&xa("click",(function(t){return e._toggle(t)}))},inputs:{recursive:["cdkTreeNodeToggleRecursive","recursive"]}}),t}(),jwt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[S$,Swt]}),t}(),Iwt=nJ(J$(Mwt)),Dwt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r){var o;return Object(m.a)(this,n),(o=e.call(this,t,i))._elementRef=t,o._tree=i,o.role="treeitem",o.tabIndex=Number(r)||0,o}return n}(Iwt);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Owt),fa("tabindex"))},t.\u0275dir=Wt({type:t,selectors:[["mat-tree-node"]],hostAttrs:[1,"mat-tree-node"],hostVars:3,hostBindings:function(t,e){2&t&&oa("aria-expanded",e.isExpanded)("aria-level","treeitem"===e.role?e.level:null)("role",e.role)},inputs:{disabled:"disabled",tabIndex:"tabIndex",role:"role"},exportAs:["matTreeNode"],features:[Ns([{provide:Mwt,useExisting:t}]),ws]}),t}(),Rwt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Swt);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matTreeNodeDef",""]],inputs:{when:["matTreeNodeDefWhen","when"],data:["matTreeNode","data"]},features:[Ns([{provide:Swt,useExisting:t}]),ws]});var e=zn(t);return t}(),Lwt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o){var a;return Object(m.a)(this,n),(a=e.call(this,t,i,r))._elementRef=t,a._tree=i,a._differs=r,a._disabled=!1,a.tabIndex=Number(o)||0,a}return Object(g.a)(n,[{key:"ngAfterContentInit",value:function(){Object(o.a)(Object(a.a)(n.prototype),"ngAfterContentInit",this).call(this)}},{key:"ngOnDestroy",value:function(){Object(o.a)(Object(a.a)(n.prototype),"ngOnDestroy",this).call(this)}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t)}},{key:"tabIndex",get:function(){return this.disabled?-1:this._tabIndex},set:function(t){this._tabIndex=null!=t?t:0}}]),n}(Twt);return t.\u0275fac=function(e){return new(e||t)(da(Us),da(Owt),da(cc),fa("tabindex"))},t.\u0275dir=Wt({type:t,selectors:[["mat-nested-tree-node"]],hostAttrs:[1,"mat-nested-tree-node"],hostVars:2,hostBindings:function(t,e){2&t&&oa("aria-expanded",e.isExpanded)("role",e.role)},inputs:{tabIndex:"tabIndex",disabled:"disabled",node:["matNestedTreeNode","node"]},exportAs:["matNestedTreeNode"],features:[Ns([{provide:Twt,useExisting:t},{provide:Mwt,useExisting:t},{provide:wwt,useExisting:t}]),ws]}),t}(),Fwt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Pwt);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matTreeNodePadding",""]],inputs:{level:["matTreeNodePadding","level"],indent:["matTreeNodePaddingIndent","indent"]},features:[Ns([{provide:Pwt,useExisting:t}]),ws]});var e=zn(t);return t}(),Nwt=function(){var t=function t(e,n){Object(m.a)(this,t),this.viewContainer=e,this._node=n};return t.\u0275fac=function(e){return new(e||t)(da(mc),da(wwt,8))},t.\u0275dir=Wt({type:t,selectors:[["","matTreeNodeOutlet",""]],features:[Ns([{provide:kwt,useExisting:t}])]}),t}(),Bwt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(Owt);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-tree"]],viewQuery:function(t,e){var n;1&t&&el(Nwt,!0),2&t&&tl(n=sl())&&(e._nodeOutlet=n.first)},hostAttrs:["role","tree",1,"mat-tree"],exportAs:["matTree"],features:[Ns([{provide:Owt,useExisting:t}]),ws],decls:1,vars:0,consts:[["matTreeNodeOutlet",""]],template:function(t,e){1&t&&wa(0,0)},directives:[Nwt],styles:[".mat-tree{display:block}.mat-tree-node{display:flex;align-items:center;flex:1;word-wrap:break-word}.mat-nested-tree-node{border-bottom-width:0}\n"],encapsulation:2});var e=zn(t);return t}(),Hwt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments)).recursive=!1,t}return n}(Awt);t.\u0275fac=function(n){return e(n||t)},t.\u0275dir=Wt({type:t,selectors:[["","matTreeNodeToggle",""]],inputs:{recursive:["matTreeNodeToggleRecursive","recursive"]},features:[Ns([{provide:Awt,useExisting:t}]),ws]});var e=zn(t);return t}(),zwt=[sot,c2,H0,g3,Ect,O2,Z3,c5,p4,c1,flt,dst,W2,z5,A8,xdt,kat,M5,S4,uat,R6,_wt,e2,function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[jwt,$$],$$]}),t}(),zrt,Rbt],Vwt=["*"];function Uwt(t,e){if(1&t){var n=ka();ga(0,"div",2),xa("click",(function(){return Se(n),Aa()._onBackdropClicked()})),va()}2&t&&Qa("mat-drawer-shown",Aa()._isShowingBackdrop())}function qwt(t,e){1&t&&(ga(0,"mat-drawer-content"),Da(1,2),va())}var Gwt=[[["mat-drawer"]],[["mat-drawer-content"]],"*"],Wwt=["mat-drawer","mat-drawer-content","*"];function Kwt(t,e){if(1&t){var n=ka();ga(0,"div",2),xa("click",(function(){return Se(n),Aa()._onBackdropClicked()})),va()}2&t&&Qa("mat-drawer-shown",Aa()._isShowingBackdrop())}function Xwt(t,e){1&t&&(ga(0,"mat-sidenav-content",3),Da(1,2),va())}var Ywt=[[["mat-sidenav"]],[["mat-sidenav-content"]],"*"],Zwt=["mat-sidenav","mat-sidenav-content","*"],Qwt={transformDrawer:Jg("transform",[rv("open, open-instant",iv({transform:"none",visibility:"visible"})),rv("void",iv({"box-shadow":"none",visibility:"hidden"})),av("void => open-instant",tv("0ms")),av("void <=> open, open-instant => void",tv("400ms cubic-bezier(0.25, 0.8, 0.25, 1)"))])};function $wt(t){throw Error("A drawer was already declared for 'position=\"".concat(t,"\"'"))}var Jwt=new ht("MAT_DRAWER_DEFAULT_AUTOSIZE",{providedIn:"root",factory:function(){return!1}}),tkt=new ht("MAT_DRAWER_CONTAINER"),ekt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){var s;return Object(m.a)(this,n),(s=e.call(this,r,o,a))._changeDetectorRef=t,s._container=i,s}return Object(g.a)(n,[{key:"ngAfterContentInit",value:function(){var t=this;this._container._contentMarginChanges.subscribe((function(){t._changeDetectorRef.markForCheck()}))}}]),n}(HJ);return t.\u0275fac=function(e){return new(e||t)(da(Po),da(Y((function(){return ikt}))),da(Us),da(BJ),da(jl))},t.\u0275cmp=Ht({type:t,selectors:[["mat-drawer-content"]],hostAttrs:[1,"mat-drawer-content"],hostVars:4,hostBindings:function(t,e){2&t&&Za("margin-left",e._container._contentMargins.left,"px")("margin-right",e._container._contentMargins.right,"px")},features:[ws],ngContentSelectors:Vwt,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),Da(0))},encapsulation:2,changeDetection:0}),t}(),nkt=function(){var t=function(){function t(e,n,i,r,o,a,s){var c=this;Object(m.a)(this,t),this._elementRef=e,this._focusTrapFactory=n,this._focusMonitor=i,this._platform=r,this._ngZone=o,this._doc=a,this._container=s,this._elementFocusedBeforeDrawerWasOpened=null,this._enableAnimations=!1,this._position="start",this._mode="over",this._disableClose=!1,this._opened=!1,this._animationStarted=new w.b,this._animationEnd=new w.b,this._animationState="void",this.openedChange=new Uc(!0),this._destroyed=new w.b,this.onPositionChanged=new Uc,this._modeChanged=new w.b,this.openedChange.subscribe((function(t){t?(c._doc&&(c._elementFocusedBeforeDrawerWasOpened=c._doc.activeElement),c._takeFocus()):c._isFocusWithinDrawer()&&c._restoreFocus()})),this._ngZone.runOutsideAngular((function(){Object(IJ.a)(c._elementRef.nativeElement,"keydown").pipe(Object(vg.a)((function(t){return 27===t.keyCode&&!c.disableClose&&!JQ(t)})),Object(Am.a)(c._destroyed)).subscribe((function(t){return c._ngZone.run((function(){c.close(),t.stopPropagation(),t.preventDefault()}))}))})),this._animationEnd.pipe(Object(RJ.a)((function(t,e){return t.fromState===e.fromState&&t.toState===e.toState}))).subscribe((function(t){var e=t.fromState,n=t.toState;(0===n.indexOf("open")&&"void"===e||"void"===n&&0===e.indexOf("open"))&&c.openedChange.emit(c._opened)}))}return Object(g.a)(t,[{key:"_takeFocus",value:function(){var t=this;this.autoFocus&&this._focusTrap&&this._focusTrap.focusInitialElementWhenReady().then((function(e){e||"function"!=typeof t._elementRef.nativeElement.focus||t._elementRef.nativeElement.focus()}))}},{key:"_restoreFocus",value:function(){this.autoFocus&&(this._elementFocusedBeforeDrawerWasOpened?this._focusMonitor.focusVia(this._elementFocusedBeforeDrawerWasOpened,this._openedVia):this._elementRef.nativeElement.blur(),this._elementFocusedBeforeDrawerWasOpened=null,this._openedVia=null)}},{key:"_isFocusWithinDrawer",value:function(){var t,e=null===(t=this._doc)||void 0===t?void 0:t.activeElement;return!!e&&this._elementRef.nativeElement.contains(e)}},{key:"ngAfterContentInit",value:function(){this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._updateFocusTrapState()}},{key:"ngAfterContentChecked",value:function(){this._platform.isBrowser&&(this._enableAnimations=!0)}},{key:"ngOnDestroy",value:function(){this._focusTrap&&this._focusTrap.destroy(),this._animationStarted.complete(),this._animationEnd.complete(),this._modeChanged.complete(),this._destroyed.next(),this._destroyed.complete()}},{key:"open",value:function(t){return this.toggle(!0,t)}},{key:"close",value:function(){return this.toggle(!1)}},{key:"_closeViaBackdropClick",value:function(){return this._setOpen(!1,!0)}},{key:"toggle",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:!this.opened,e=arguments.length>1?arguments[1]:void 0;return this._setOpen(t,!t&&this._isFocusWithinDrawer(),e)}},{key:"_setOpen",value:function(t,e){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"program";return this._opened=t,t?(this._animationState=this._enableAnimations?"open":"open-instant",this._openedVia=i):(this._animationState="void",e&&this._restoreFocus()),this._updateFocusTrapState(),new Promise((function(t){n.openedChange.pipe(Object(FX.a)(1)).subscribe((function(e){return t(e?"open":"close")}))}))}},{key:"_updateFocusTrapState",value:function(){this._focusTrap&&(this._focusTrap.enabled=this.opened&&"side"!==this.mode)}},{key:"_animationStartListener",value:function(t){this._animationStarted.next(t)}},{key:"_animationDoneListener",value:function(t){this._animationEnd.next(t)}},{key:"position",get:function(){return this._position},set:function(t){(t="end"===t?"end":"start")!=this._position&&(this._position=t,this.onPositionChanged.emit())}},{key:"mode",get:function(){return this._mode},set:function(t){this._mode=t,this._updateFocusTrapState(),this._modeChanged.next()}},{key:"disableClose",get:function(){return this._disableClose},set:function(t){this._disableClose=nm(t)}},{key:"autoFocus",get:function(){var t=this._autoFocus;return null==t?"side"!==this.mode:t},set:function(t){this._autoFocus=nm(t)}},{key:"opened",get:function(){return this._opened},set:function(t){this.toggle(nm(t))}},{key:"_openedStream",get:function(){return this.openedChange.pipe(Object(vg.a)((function(t){return t})),Object(ef.a)((function(){})))}},{key:"openedStart",get:function(){return this._animationStarted.pipe(Object(vg.a)((function(t){return t.fromState!==t.toState&&0===t.toState.indexOf("open")})),Object(ef.a)((function(){})))}},{key:"_closedStream",get:function(){return this.openedChange.pipe(Object(vg.a)((function(t){return!t})),Object(ef.a)((function(){})))}},{key:"closedStart",get:function(){return this._animationStarted.pipe(Object(vg.a)((function(t){return t.fromState!==t.toState&&"void"===t.toState})),Object(ef.a)((function(){})))}},{key:"_width",get:function(){return this._elementRef.nativeElement&&this._elementRef.nativeElement.offsetWidth||0}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(v$),da(S$),da(Cm),da(jl),da(du,8),da(tkt,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-drawer"]],hostAttrs:["tabIndex","-1",1,"mat-drawer"],hostVars:12,hostBindings:function(t,e){1&t&&Oa("@transform.start",(function(t){return e._animationStartListener(t)}))("@transform.done",(function(t){return e._animationDoneListener(t)})),2&t&&(oa("align",null),ys("@transform",e._animationState),Qa("mat-drawer-end","end"===e.position)("mat-drawer-over","over"===e.mode)("mat-drawer-push","push"===e.mode)("mat-drawer-side","side"===e.mode)("mat-drawer-opened",e.opened))},inputs:{position:"position",mode:"mode",disableClose:"disableClose",autoFocus:"autoFocus",opened:"opened"},outputs:{openedChange:"openedChange",onPositionChanged:"positionChanged",_openedStream:"opened",openedStart:"openedStart",_closedStream:"closed",closedStart:"closedStart"},exportAs:["matDrawer"],ngContentSelectors:Vwt,decls:2,vars:0,consts:[[1,"mat-drawer-inner-container"]],template:function(t,e){1&t&&(Ia(),ga(0,"div",0),Da(1),va())},encapsulation:2,data:{animation:[Qwt.transformDrawer]},changeDetection:0}),t}(),ikt=function(){var t=function(){function t(e,n,i,r,o){var a=this,s=arguments.length>5&&void 0!==arguments[5]&&arguments[5],c=arguments.length>6?arguments[6]:void 0;Object(m.a)(this,t),this._dir=e,this._element=n,this._ngZone=i,this._changeDetectorRef=r,this._animationMode=c,this._drawers=new Gc,this.backdropClick=new Uc,this._destroyed=new w.b,this._doCheckSubject=new w.b,this._contentMargins={left:null,right:null},this._contentMarginChanges=new w.b,e&&e.change.pipe(Object(Am.a)(this._destroyed)).subscribe((function(){a._validateDrawers(),a.updateContentMargins()})),o.change().pipe(Object(Am.a)(this._destroyed)).subscribe((function(){return a.updateContentMargins()})),this._autosize=s}return Object(g.a)(t,[{key:"ngAfterContentInit",value:function(){var t=this;this._allDrawers.changes.pipe(Object(NX.a)(this._allDrawers),Object(Am.a)(this._destroyed)).subscribe((function(e){t._drawers.reset(e.filter((function(e){return!e._container||e._container===t}))),t._drawers.notifyOnChanges()})),this._drawers.changes.pipe(Object(NX.a)(null)).subscribe((function(){t._validateDrawers(),t._drawers.forEach((function(e){t._watchDrawerToggle(e),t._watchDrawerPosition(e),t._watchDrawerMode(e)})),(!t._drawers.length||t._isDrawerOpen(t._start)||t._isDrawerOpen(t._end))&&t.updateContentMargins(),t._changeDetectorRef.markForCheck()})),this._doCheckSubject.pipe(Object(t$.a)(10),Object(Am.a)(this._destroyed)).subscribe((function(){return t.updateContentMargins()}))}},{key:"ngOnDestroy",value:function(){this._contentMarginChanges.complete(),this._doCheckSubject.complete(),this._drawers.destroy(),this._destroyed.next(),this._destroyed.complete()}},{key:"open",value:function(){this._drawers.forEach((function(t){return t.open()}))}},{key:"close",value:function(){this._drawers.forEach((function(t){return t.close()}))}},{key:"updateContentMargins",value:function(){var t=this,e=0,n=0;if(this._left&&this._left.opened)if("side"==this._left.mode)e+=this._left._width;else if("push"==this._left.mode){var i=this._left._width;e+=i,n-=i}if(this._right&&this._right.opened)if("side"==this._right.mode)n+=this._right._width;else if("push"==this._right.mode){var r=this._right._width;n+=r,e-=r}n=n||null,(e=e||null)===this._contentMargins.left&&n===this._contentMargins.right||(this._contentMargins={left:e,right:n},this._ngZone.run((function(){return t._contentMarginChanges.next(t._contentMargins)})))}},{key:"ngDoCheck",value:function(){var t=this;this._autosize&&this._isPushed()&&this._ngZone.runOutsideAngular((function(){return t._doCheckSubject.next()}))}},{key:"_watchDrawerToggle",value:function(t){var e=this;t._animationStarted.pipe(Object(vg.a)((function(t){return t.fromState!==t.toState})),Object(Am.a)(this._drawers.changes)).subscribe((function(t){"open-instant"!==t.toState&&"NoopAnimations"!==e._animationMode&&e._element.nativeElement.classList.add("mat-drawer-transition"),e.updateContentMargins(),e._changeDetectorRef.markForCheck()})),"side"!==t.mode&&t.openedChange.pipe(Object(Am.a)(this._drawers.changes)).subscribe((function(){return e._setContainerClass(t.opened)}))}},{key:"_watchDrawerPosition",value:function(t){var e=this;t&&t.onPositionChanged.pipe(Object(Am.a)(this._drawers.changes)).subscribe((function(){e._ngZone.onMicrotaskEmpty.asObservable().pipe(Object(FX.a)(1)).subscribe((function(){e._validateDrawers()}))}))}},{key:"_watchDrawerMode",value:function(t){var e=this;t&&t._modeChanged.pipe(Object(Am.a)(Object(C.a)(this._drawers.changes,this._destroyed))).subscribe((function(){e.updateContentMargins(),e._changeDetectorRef.markForCheck()}))}},{key:"_setContainerClass",value:function(t){var e=this._element.nativeElement.classList,n="mat-drawer-container-has-open";t?e.add(n):e.remove(n)}},{key:"_validateDrawers",value:function(){var t=this;this._start=this._end=null,this._drawers.forEach((function(e){"end"==e.position?(null!=t._end&&$wt("end"),t._end=e):(null!=t._start&&$wt("start"),t._start=e)})),this._right=this._left=null,this._dir&&"rtl"===this._dir.value?(this._left=this._end,this._right=this._start):(this._left=this._start,this._right=this._end)}},{key:"_isPushed",value:function(){return this._isDrawerOpen(this._start)&&"over"!=this._start.mode||this._isDrawerOpen(this._end)&&"over"!=this._end.mode}},{key:"_onBackdropClicked",value:function(){this.backdropClick.emit(),this._closeModalDrawersViaBackdrop()}},{key:"_closeModalDrawersViaBackdrop",value:function(){var t=this;[this._start,this._end].filter((function(e){return e&&!e.disableClose&&t._canHaveBackdrop(e)})).forEach((function(t){return t._closeViaBackdropClick()}))}},{key:"_isShowingBackdrop",value:function(){return this._isDrawerOpen(this._start)&&this._canHaveBackdrop(this._start)||this._isDrawerOpen(this._end)&&this._canHaveBackdrop(this._end)}},{key:"_canHaveBackdrop",value:function(t){return"side"!==t.mode||!!this._backdropOverride}},{key:"_isDrawerOpen",value:function(t){return null!=t&&t.opened}},{key:"start",get:function(){return this._start}},{key:"end",get:function(){return this._end}},{key:"autosize",get:function(){return this._autosize},set:function(t){this._autosize=nm(t)}},{key:"hasBackdrop",get:function(){return null==this._backdropOverride?!this._start||"side"!==this._start.mode||!this._end||"side"!==this._end.mode:this._backdropOverride},set:function(t){this._backdropOverride=null==t?null:nm(t)}},{key:"scrollable",get:function(){return this._userContent||this._content}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(gm,8),da(Us),da(jl),da(Po),da(zJ),da(Jwt),da(Cy,8))},t.\u0275cmp=Ht({type:t,selectors:[["mat-drawer-container"]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,ekt,!0),rl(n,nkt,!0)),2&t&&(tl(i=sl())&&(e._content=i.first),tl(i=sl())&&(e._allDrawers=i))},viewQuery:function(t,e){var n;1&t&&nl(ekt,!0),2&t&&tl(n=sl())&&(e._userContent=n.first)},hostAttrs:[1,"mat-drawer-container"],hostVars:2,hostBindings:function(t,e){2&t&&Qa("mat-drawer-container-explicit-backdrop",e._backdropOverride)},inputs:{autosize:"autosize",hasBackdrop:"hasBackdrop"},outputs:{backdropClick:"backdropClick"},exportAs:["matDrawerContainer"],features:[Ns([{provide:tkt,useExisting:t}])],ngContentSelectors:Wwt,decls:4,vars:2,consts:[["class","mat-drawer-backdrop",3,"mat-drawer-shown","click",4,"ngIf"],[4,"ngIf"],[1,"mat-drawer-backdrop",3,"click"]],template:function(t,e){1&t&&(Ia(Gwt),ua(0,Uwt,1,2,"div",0),Da(1),Da(2,1),ua(3,qwt,2,0,"mat-drawer-content",1)),2&t&&(pa("ngIf",e.hasBackdrop),Qi(3),pa("ngIf",!e._content))},directives:[Ah,ekt],styles:[".mat-drawer-container{position:relative;z-index:1;box-sizing:border-box;-webkit-overflow-scrolling:touch;display:block;overflow:hidden}.mat-drawer-container[fullscreen]{top:0;left:0;right:0;bottom:0;position:absolute}.mat-drawer-container[fullscreen].mat-drawer-container-has-open{overflow:hidden}.mat-drawer-container.mat-drawer-container-explicit-backdrop .mat-drawer-side{z-index:3}.mat-drawer-container.ng-animate-disabled .mat-drawer-backdrop,.mat-drawer-container.ng-animate-disabled .mat-drawer-content,.ng-animate-disabled .mat-drawer-container .mat-drawer-backdrop,.ng-animate-disabled .mat-drawer-container .mat-drawer-content{transition:none}.mat-drawer-backdrop{top:0;left:0;right:0;bottom:0;position:absolute;display:block;z-index:3;visibility:hidden}.mat-drawer-backdrop.mat-drawer-shown{visibility:visible}.mat-drawer-transition .mat-drawer-backdrop{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:background-color,visibility}.cdk-high-contrast-active .mat-drawer-backdrop{opacity:.5}.mat-drawer-content{position:relative;z-index:1;display:block;height:100%;overflow:auto}.mat-drawer-transition .mat-drawer-content{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:transform,margin-left,margin-right}.mat-drawer{position:relative;z-index:4;display:block;position:absolute;top:0;bottom:0;z-index:3;outline:0;box-sizing:border-box;overflow-y:auto;transform:translate3d(-100%, 0, 0)}.cdk-high-contrast-active .mat-drawer,.cdk-high-contrast-active [dir=rtl] .mat-drawer.mat-drawer-end{border-right:solid 1px currentColor}.cdk-high-contrast-active [dir=rtl] .mat-drawer,.cdk-high-contrast-active .mat-drawer.mat-drawer-end{border-left:solid 1px currentColor;border-right:none}.mat-drawer.mat-drawer-side{z-index:2}.mat-drawer.mat-drawer-end{right:0;transform:translate3d(100%, 0, 0)}[dir=rtl] .mat-drawer{transform:translate3d(100%, 0, 0)}[dir=rtl] .mat-drawer.mat-drawer-end{left:0;right:auto;transform:translate3d(-100%, 0, 0)}.mat-drawer-inner-container{width:100%;height:100%;overflow:auto;-webkit-overflow-scrolling:touch}.mat-sidenav-fixed{position:fixed}\n"],encapsulation:2,changeDetection:0}),t}(),rkt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(t,i,r,o,a){return Object(m.a)(this,n),e.call(this,t,i,r,o,a)}return n}(ekt);return t.\u0275fac=function(e){return new(e||t)(da(Po),da(Y((function(){return akt}))),da(Us),da(BJ),da(jl))},t.\u0275cmp=Ht({type:t,selectors:[["mat-sidenav-content"]],hostAttrs:[1,"mat-drawer-content","mat-sidenav-content"],hostVars:4,hostBindings:function(t,e){2&t&&Za("margin-left",e._container._contentMargins.left,"px")("margin-right",e._container._contentMargins.right,"px")},features:[ws],ngContentSelectors:Vwt,decls:1,vars:0,template:function(t,e){1&t&&(Ia(),Da(0))},encapsulation:2,changeDetection:0}),t}(),okt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){var t;return Object(m.a)(this,n),(t=e.apply(this,arguments))._fixedInViewport=!1,t._fixedTopGap=0,t._fixedBottomGap=0,t}return Object(g.a)(n,[{key:"fixedInViewport",get:function(){return this._fixedInViewport},set:function(t){this._fixedInViewport=nm(t)}},{key:"fixedTopGap",get:function(){return this._fixedTopGap},set:function(t){this._fixedTopGap=im(t)}},{key:"fixedBottomGap",get:function(){return this._fixedBottomGap},set:function(t){this._fixedBottomGap=im(t)}}]),n}(nkt);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-sidenav"]],hostAttrs:["tabIndex","-1",1,"mat-drawer","mat-sidenav"],hostVars:17,hostBindings:function(t,e){2&t&&(oa("align",null),Za("top",e.fixedInViewport?e.fixedTopGap:null,"px")("bottom",e.fixedInViewport?e.fixedBottomGap:null,"px"),Qa("mat-drawer-end","end"===e.position)("mat-drawer-over","over"===e.mode)("mat-drawer-push","push"===e.mode)("mat-drawer-side","side"===e.mode)("mat-drawer-opened",e.opened)("mat-sidenav-fixed",e.fixedInViewport))},inputs:{fixedInViewport:"fixedInViewport",fixedTopGap:"fixedTopGap",fixedBottomGap:"fixedBottomGap"},exportAs:["matSidenav"],features:[ws],ngContentSelectors:Vwt,decls:2,vars:0,consts:[[1,"mat-drawer-inner-container"]],template:function(t,e){1&t&&(Ia(),ga(0,"div",0),Da(1),va())},encapsulation:2,data:{animation:[Qwt.transformDrawer]},changeDetection:0});var e=zn(t);return t}(),akt=function(){var t=function(t){Object(f.a)(n,t);var e=Object(p.a)(n);function n(){return Object(m.a)(this,n),e.apply(this,arguments)}return n}(ikt);t.\u0275fac=function(n){return e(n||t)},t.\u0275cmp=Ht({type:t,selectors:[["mat-sidenav-container"]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,rkt,!0),rl(n,okt,!0)),2&t&&(tl(i=sl())&&(e._content=i.first),tl(i=sl())&&(e._allDrawers=i))},hostAttrs:[1,"mat-drawer-container","mat-sidenav-container"],hostVars:2,hostBindings:function(t,e){2&t&&Qa("mat-drawer-container-explicit-backdrop",e._backdropOverride)},exportAs:["matSidenavContainer"],features:[Ns([{provide:tkt,useExisting:t}]),ws],ngContentSelectors:Zwt,decls:4,vars:2,consts:[["class","mat-drawer-backdrop",3,"mat-drawer-shown","click",4,"ngIf"],["cdkScrollable","",4,"ngIf"],[1,"mat-drawer-backdrop",3,"click"],["cdkScrollable",""]],template:function(t,e){1&t&&(Ia(Ywt),ua(0,Kwt,1,2,"div",0),Da(1),Da(2,1),ua(3,Xwt,2,0,"mat-sidenav-content",1)),2&t&&(pa("ngIf",e.hasBackdrop),Qi(3),pa("ngIf",!e._content))},directives:[Ah,rkt,HJ],styles:[".mat-drawer-container{position:relative;z-index:1;box-sizing:border-box;-webkit-overflow-scrolling:touch;display:block;overflow:hidden}.mat-drawer-container[fullscreen]{top:0;left:0;right:0;bottom:0;position:absolute}.mat-drawer-container[fullscreen].mat-drawer-container-has-open{overflow:hidden}.mat-drawer-container.mat-drawer-container-explicit-backdrop .mat-drawer-side{z-index:3}.mat-drawer-container.ng-animate-disabled .mat-drawer-backdrop,.mat-drawer-container.ng-animate-disabled .mat-drawer-content,.ng-animate-disabled .mat-drawer-container .mat-drawer-backdrop,.ng-animate-disabled .mat-drawer-container .mat-drawer-content{transition:none}.mat-drawer-backdrop{top:0;left:0;right:0;bottom:0;position:absolute;display:block;z-index:3;visibility:hidden}.mat-drawer-backdrop.mat-drawer-shown{visibility:visible}.mat-drawer-transition .mat-drawer-backdrop{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:background-color,visibility}.cdk-high-contrast-active .mat-drawer-backdrop{opacity:.5}.mat-drawer-content{position:relative;z-index:1;display:block;height:100%;overflow:auto}.mat-drawer-transition .mat-drawer-content{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:transform,margin-left,margin-right}.mat-drawer{position:relative;z-index:4;display:block;position:absolute;top:0;bottom:0;z-index:3;outline:0;box-sizing:border-box;overflow-y:auto;transform:translate3d(-100%, 0, 0)}.cdk-high-contrast-active .mat-drawer,.cdk-high-contrast-active [dir=rtl] .mat-drawer.mat-drawer-end{border-right:solid 1px currentColor}.cdk-high-contrast-active [dir=rtl] .mat-drawer,.cdk-high-contrast-active .mat-drawer.mat-drawer-end{border-left:solid 1px currentColor;border-right:none}.mat-drawer.mat-drawer-side{z-index:2}.mat-drawer.mat-drawer-end{right:0;transform:translate3d(100%, 0, 0)}[dir=rtl] .mat-drawer{transform:translate3d(100%, 0, 0)}[dir=rtl] .mat-drawer.mat-drawer-end{left:0;right:auto;transform:translate3d(-100%, 0, 0)}.mat-drawer-inner-container{width:100%;height:100%;overflow:auto;-webkit-overflow-scrolling:touch}.mat-sidenav-fixed{position:fixed}\n"],encapsulation:2,changeDetection:0});var e=zn(t);return t}(),skt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},imports:[[hd,$$,Sm,VJ],VJ,$$]}),t}(),ckt=function(){function t(t){this.httpServer=t}return t.prototype.get=function(t){return this.httpServer.get(t,"/settings")},t.prototype.update=function(t,e){return this.httpServer.post(t,"/settings",e)},t.prototype.getSettingsForQemu=function(t){return this.httpServer.get(t,"/settings/qemu")},t.prototype.updateSettingsForQemu=function(t,e){return this.httpServer.put(t,"/settings/qemu",{enable_hardware_acceleration:e.enable_hardware_acceleration,require_hardware_acceleration:e.require_hardware_acceleration})},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}();function lkt(t,e){1&t&&(ga(0,"button",11),ds(1,"QEMU VM templates"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/qemu/templates")}function ukt(t,e){if(1&t){var n=ka();ga(0,"mat-list-item"),ga(1,"mat-checkbox",12),xa("ngModelChange",(function(t){return Se(n),Aa(2).settings.require_hardware_acceleration=t})),ds(2," Require Hardware Acceleration (KVM/HAXM) "),va(),va()}if(2&t){var i=Aa(2);Qi(1),pa("ngModel",i.settings.require_hardware_acceleration)}}function hkt(t,e){if(1&t){var n=ka();ga(0,"mat-nav-list"),ga(1,"mat-list-item"),ga(2,"mat-checkbox",12),xa("ngModelChange",(function(t){return Se(n),Aa().settings.enable_hardware_acceleration=t})),ds(3," Enable Hardware Acceleration (KVM/HAXM) "),va(),va(),ua(4,ukt,3,1,"mat-list-item",7),va()}if(2&t){var i=Aa();Qi(2),pa("ngModel",i.settings.enable_hardware_acceleration),Qi(2),pa("ngIf",i.settings.enable_hardware_acceleration)}}var dkt=function(){function t(t,e,n,i){this.route=t,this.serverService=e,this.serverSettingsService=n,this.toasterService=i}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.serverSettingsService.getSettingsForQemu(t.server).subscribe((function(e){t.settings=e}))}))},t.prototype.apply=function(){var t=this;this.settings.enable_hardware_acceleration||(this.settings.require_hardware_acceleration=!1),this.serverSettingsService.updateSettingsForQemu(this.server,this.settings).subscribe((function(e){t.toasterService.success("Changes applied")}))},t.prototype.restoreDefaults=function(){var t=this;this.serverSettingsService.updateSettingsForQemu(this.server,{enable_hardware_acceleration:!0,require_hardware_acceleration:!0}).subscribe((function(e){t.settings=e,t.toasterService.success("Restored to default settings")}))},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(ckt),da(Y2))},t.\u0275cmp=Ht({type:t,selectors:[["app-qemu-preferences"]],decls:14,vars:2,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[1,"default-content"],[1,"container","mat-elevation-z8"],[4,"ngIf"],[1,"buttons-bar"],["mat-button","","color","accent",3,"click"],["mat-raised-button","","color","primary",3,"click"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"QEMU preferences"),va(),ua(5,lkt,2,1,"button",4),va(),va(),ga(6,"div",5),ga(7,"div",6),ua(8,hkt,5,2,"mat-nav-list",7),va(),ga(9,"div",8),ga(10,"button",9),xa("click",(function(){return e.restoreDefaults()})),ds(11,"Restore defaults"),va(),ga(12,"button",10),xa("click",(function(){return e.apply()})),ds(13,"Apply"),va(),va(),va(),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(3),pa("ngIf",e.settings))},directives:[Ah,a2,hQ,y8,S8,F5,mf,Sp],styles:[".top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}"]}),t}(),fkt=function(){function t(t){this.route=t,this.serverId=""}return t.prototype.ngOnInit=function(){this.serverId=this.route.snapshot.paramMap.get("server_id")},t.\u0275fac=function(e){return new(e||t)(da(ZY))},t.\u0275cmp=Ht({type:t,selectors:[["app-general-preferences"]],decls:7,vars:0,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"container","mat-elevation-z8"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"General preferences"),va(),va(),va(),ga(5,"div",4),ba(6,"div",5),va(),va())},styles:[""]}),t}(),pkt=function(){function t(t,e){this.route=t,this.serverService=e}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e}))},t.prototype.restoreDefaults=function(){this.vpcsExecutable=""},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-vpcs-preferences"]],decls:8,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"form-field"],["matInput","","type","text","placeholder","Path to VPCS executable",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VPCS preferences"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-form-field",5),ga(7,"input",6),xa("ngModelChange",(function(t){return e.vpcsExecutable=t})),va(),va(),va(),va()),2&t&&(Qi(7),pa("ngModel",e.vpcsExecutable))},directives:[Y3,s5,cf,mf,Sp],styles:[".form-field[_ngcontent-%COMP%]{width:100%}"]}),t}(),mkt=function(){function t(t,e){this.route=t,this.serverService=e}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e}))},t.prototype.restoreDefaults=function(){this.vboxManagePath=""},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-virtual-box-preferences"]],decls:8,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"form-field"],["matInput","","type","text","placeholder","Path to VirtualBox manage",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VirtualBox preferences"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-form-field",5),ga(7,"input",6),xa("ngModelChange",(function(t){return e.vboxManagePath=t})),va(),va(),va(),va()),2&t&&(Qi(7),pa("ngModel",e.vboxManagePath))},directives:[Y3,s5,cf,mf,Sp],styles:[""]}),t}(),gkt=function(){function t(t,e,n){this.route=t,this.serverService=e,this.serverSettingsService=n}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e}))},t.prototype.restoreDefaults=function(){this.dynamipsPath=""},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(ckt))},t.\u0275cmp=Ht({type:t,selectors:[["app-dynamips-preferences"]],decls:8,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"form-field"],["matInput","","type","text","placeholder","Path to Dynamips",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"Dynamips preferences"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-form-field",5),ga(7,"input",6),xa("ngModelChange",(function(t){return e.dynamipsPath=t})),va(),va(),va(),va()),2&t&&(Qi(7),pa("ngModel",e.dynamipsPath))},directives:[Y3,s5,cf,mf,Sp],styles:[".top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.form-field[_ngcontent-%COMP%]{width:100%}"]}),t}(),vkt=function(){function t(t,e){this.route=t,this.serverService=e}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e}))},t.prototype.restoreDefaults=function(){this.vmrunPath=""},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-vmware-preferences"]],decls:8,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"form-field"],["matInput","","type","text","placeholder","Path to vmrun:",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"VMware preferences"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-form-field",5),ga(7,"input",6),xa("ngModelChange",(function(t){return e.vmrunPath=t})),va(),va(),va(),va()),2&t&&(Qi(7),pa("ngModel",e.vmrunPath))},directives:[Y3,s5,cf,mf,Sp],styles:[".form-field[_ngcontent-%COMP%]{width:100%}"]}),t}(),bkt=function(){function t(){}return t.prototype.transform=function(t,e){return t?e?(e=e.toLowerCase(),t.projectDatabase.data.filter((function(t){return t.filename.toLowerCase().includes(e)}))):t:[]},t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=Kt({name:"projectsfilter",type:t,pure:!0}),t}(),ykt=function(){function t(t){this.httpServer=t}return t.prototype.getTemplates=function(t){return this.httpServer.get(t,"/templates")},t.prototype.getTemplate=function(t,e){return this.httpServer.get(t,"/templates/"+e)},t.prototype.addTemplate=function(t,e){return this.httpServer.post(t,"/templates",e)},t.prototype.saveTemplate=function(t,e){return this.httpServer.put(t,"/templates/"+e.template_id,e)},t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(YQ))}}),t}(),_kt=function(){function t(t,e,n,i,r,o,a){this.route=t,this.serverService=e,this.tracengService=n,this.router=i,this.toasterService=r,this.templateMocksService=o,this.formBuilder=a,this.templateName="",this.ipAddress="",this.templateNameForm=this.formBuilder.group({templateName:new hp(null,[kf.required]),ipAddress:new hp(null,[kf.required])})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","traceng","templates"])},t.prototype.addTemplate=function(){var t=this;if(this.templateNameForm.invalid)this.toasterService.error("Fill all required fields");else{this.templateName=this.templateNameForm.get("templateName").value,this.ipAddress=this.templateNameForm.get("ipAddress").value;var e=this.templateMocksService.getTracengTemplate();e.template_id=Object(art.v4)(),e.name=this.templateName,e.ip_address=this.ipAddress,this.tracengService.addTemplate(this.server,e).subscribe((function(){t.goBack()}))}},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(ykt),da(lQ),da(Y2),da(oft),da(Jp))},t.\u0275cmp=Ht({type:t,selectors:[["app-add-traceng-template"]],decls:17,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","formControlName","templateName","type","text","placeholder","Template name"],["matInput","","formControlName","ipAddress","type","text","placeholder","IP address"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"New VPCS node template"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-card",5),ga(7,"form",6),ga(8,"mat-form-field",7),ba(9,"input",8),va(),ga(10,"mat-form-field",7),ba(11,"input",9),va(),va(),va(),ga(12,"div",10),ga(13,"button",11),xa("click",(function(){return e.goBack()})),ds(14,"Cancel"),va(),ga(15,"button",12),xa("click",(function(){return e.addTemplate()})),ds(16,"Add template"),va(),va(),va(),va()),2&t&&(Qi(7),pa("formGroup",e.templateNameForm))},directives:[f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),wkt=function(){function t(t,e){this.route=t,this.serverService=e}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e}))},t.prototype.restoreDefaults=function(){this.tracengExecutable=""},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-traceng-preferences"]],decls:8,vars:1,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],[1,"default-content"],[1,"form-field"],["matInput","","type","text","placeholder","Path to TraceNG executable",3,"ngModel","ngModelChange"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"TraceNG preferences"),va(),va(),va(),ga(5,"div",4),ga(6,"mat-form-field",5),ga(7,"input",6),xa("ngModelChange",(function(t){return e.tracengExecutable=t})),va(),va(),va(),va()),2&t&&(Qi(7),pa("ngModel",e.tracengExecutable))},directives:[Y3,s5,cf,mf,Sp],styles:[".form-field[_ngcontent-%COMP%]{width:100%}"]}),t}();function kkt(t,e){1&t&&(ga(0,"button",10),ds(1,"Back"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences")}function Ckt(t,e){1&t&&(ga(0,"button",11),ds(1,"Add TraceNG template"),va()),2&t&&La("routerLink","/server/",Aa().server.id,"/preferences/traceng/addtemplate")}function Skt(t,e){1&t&&ba(0,"app-empty-templates-list")}function xkt(t,e){if(1&t){var n=ka();ga(0,"div",15),ga(1,"mat-list-item",16),ds(2),va(),ga(3,"button",17),ga(4,"mat-icon"),ds(5,"more_vert"),va(),va(),ga(6,"mat-menu",null,18),ga(8,"button",19),xa("click",(function(){Se(n);var t=e.$implicit;return Aa(3).deleteTemplate(t)})),ga(9,"mat-icon"),ds(10,"delete"),va(),ga(11,"span"),ds(12,"Delete"),va(),va(),va(),va()}if(2&t){var i=e.$implicit,r=ha(7);Qi(1),Ra("routerLink",i.template_id),Qi(1),fs(i.name),Qi(1),pa("matMenuTriggerFor",r)}}function Okt(t,e){if(1&t&&(ga(0,"mat-nav-list"),ua(1,xkt,13,3,"div",14),va()),2&t){var n=Aa(2);Qi(1),pa("ngForOf",n.tracengTemplates)}}function Mkt(t,e){if(1&t&&(ga(0,"div",12),ga(1,"div",13),ua(2,Okt,2,1,"mat-nav-list",6),va(),va()),2&t){var n=Aa();Qi(2),pa("ngIf",n.server)}}var Tkt=function(){function t(t,e,n){this.route=t,this.serverService=e,this.tracengService=n,this.tracengTemplates=[]}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.getTemplates()}))},t.prototype.getTemplates=function(){var t=this;this.tracengService.getTemplates(this.server).subscribe((function(e){t.tracengTemplates=e.filter((function(t){return"traceng"===t.template_type&&!t.builtin}))}))},t.prototype.deleteTemplate=function(t){this.deleteComponent.deleteItem(t.name,t.template_id)},t.prototype.onDeleteEvent=function(){this.getTemplates()},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(ykt))},t.\u0275cmp=Ht({type:t,selectors:[["app-traceng-templates"]],viewQuery:function(t,e){var n;1&t&&nl(Pdt,!0),2&t&&tl(n=sl())&&(e.deleteComponent=n.first)},decls:11,vars:5,consts:[[1,"content"],[1,"default-header"],[1,"row"],[1,"col"],["class","top-button","class","cancel-button","mat-button","",3,"routerLink",4,"ngIf"],["class","top-button","mat-raised-button","","color","primary",3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","default-content",4,"ngIf"],[3,"server","deleteEvent"],["deleteComponent",""],["mat-button","",1,"cancel-button",3,"routerLink"],["mat-raised-button","","color","primary",1,"top-button",3,"routerLink"],[1,"default-content"],[1,"listcontainer","mat-elevation-z8"],["class","list-item",4,"ngFor","ngForOf"],[1,"list-item"],[1,"template-name",3,"routerLink"],["mat-button","",1,"menu-button",3,"matMenuTriggerFor"],["menu","matMenu"],["mat-menu-item","",3,"click"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"TraceNG node templates"),va(),ua(5,kkt,2,1,"button",4),ua(6,Ckt,2,1,"button",5),va(),va(),ua(7,Skt,1,0,"app-empty-templates-list",6),ua(8,Mkt,3,1,"div",7),va(),ga(9,"app-delete-template",8,9),xa("deleteEvent",(function(){return e.onDeleteEvent()})),va()),2&t&&(Qi(5),pa("ngIf",e.server),Qi(1),pa("ngIf",e.server),Qi(1),pa("ngIf",!e.tracengTemplates.length),Qi(1),pa("ngIf",e.tracengTemplates.length),Qi(1),pa("server",e.server))},directives:[Ah,Pdt,a2,hQ,Adt,y8,Eh,S8,N0,x2,D0,E0],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}();function Ekt(t,e){if(1&t){var n=ka();ga(0,"div",6),ga(1,"mat-card",7),ga(2,"form",8),ga(3,"mat-form-field",9),ga(4,"input",10),xa("ngModelChange",(function(t){return Se(n),Aa().tracengTemplate.name=t})),va(),va(),ga(5,"mat-form-field",9),ga(6,"input",11),xa("ngModelChange",(function(t){return Se(n),Aa().tracengTemplate.default_name_format=t})),va(),va(),ga(7,"mat-form-field",9),ga(8,"input",12),xa("ngModelChange",(function(t){return Se(n),Aa().tracengTemplate.symbol=t})),va(),va(),ga(9,"button",13),xa("click",(function(){return Se(n),Aa().chooseSymbol()})),ds(10,"Choose symbol"),va(),ba(11,"br"),ba(12,"br"),va(),va(),ga(13,"div",14),ga(14,"button",15),xa("click",(function(){return Se(n),Aa().goBack()})),ds(15,"Cancel"),va(),ga(16,"button",16),xa("click",(function(){return Se(n),Aa().onSave()})),ds(17,"Save"),va(),va(),va()}if(2&t){var i=Aa();Qi(2),pa("formGroup",i.inputForm),Qi(2),pa("ngModel",i.tracengTemplate.name),Qi(2),pa("ngModel",i.tracengTemplate.default_name_format),Qi(2),pa("ngModel",i.tracengTemplate.symbol)}}function Pkt(t,e){if(1&t){var n=ka();ga(0,"app-symbols-menu",17),xa("symbolChangedEmitter",(function(t){return Se(n),Aa().symbolChanged(t)})),va()}if(2&t){var i=Aa();pa("server",i.server)("symbol",i.tracengTemplate.symbol)}}var Akt=function(t){return{shadowed:t}},jkt=function(){function t(t,e,n,i,r,o){this.route=t,this.serverService=e,this.tracengService=n,this.toasterService=i,this.formBuilder=r,this.router=o,this.isSymbolSelectionOpened=!1,this.inputForm=this.formBuilder.group({templateName:new hp("",kf.required),defaultName:new hp("",kf.required),symbol:new hp("",kf.required)})}return t.prototype.ngOnInit=function(){var t=this,e=this.route.snapshot.paramMap.get("server_id"),n=this.route.snapshot.paramMap.get("template_id");this.serverService.get(parseInt(e,10)).then((function(e){t.server=e,t.tracengService.getTemplate(t.server,n).subscribe((function(e){t.tracengTemplate=e}))}))},t.prototype.goBack=function(){this.router.navigate(["/server",this.server.id,"preferences","traceng","templates"])},t.prototype.onSave=function(){var t=this;this.inputForm.invalid?this.toasterService.error("Fill all required fields"):this.tracengService.saveTemplate(this.server,this.tracengTemplate).subscribe((function(e){t.toasterService.success("Changes saved")}))},t.prototype.chooseSymbol=function(){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened},t.prototype.symbolChanged=function(t){this.isSymbolSelectionOpened=!this.isSymbolSelectionOpened,this.tracengTemplate.symbol=t},t.\u0275fac=function(e){return new(e||t)(da(ZY),da(ZQ),da(ykt),da(Y2),da(Jp),da(lQ))},t.\u0275cmp=Ht({type:t,selectors:[["app-traceng-template-details"]],decls:7,vars:5,consts:[[1,"content",3,"ngClass"],[1,"default-header"],[1,"row"],[1,"col"],["class","default-content",4,"ngIf"],[3,"server","symbol","symbolChangedEmitter",4,"ngIf"],[1,"default-content"],[1,"matCard"],[3,"formGroup"],[1,"form-field"],["matInput","","type","text","formControlName","templateName","placeholder","Template name",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","defaultName","placeholder","Default name format",3,"ngModel","ngModelChange"],["matInput","","type","text","formControlName","symbol","placeholder","Symbol",3,"ngModel","ngModelChange"],["mat-button","",1,"symbolSelectionButton",3,"click"],[1,"buttons-bar"],["mat-button","",1,"cancel-button",3,"click"],["mat-raised-button","","color","primary",3,"click"],[3,"server","symbol","symbolChangedEmitter"]],template:function(t,e){1&t&&(ga(0,"div",0),ga(1,"div",1),ga(2,"div",2),ga(3,"h1",3),ds(4,"TraceNG device configuration"),va(),va(),va(),ua(5,Ekt,18,4,"div",4),va(),ua(6,Pkt,1,2,"app-symbols-menu",5)),2&t&&(pa("ngClass",Ic(3,Akt,e.isSymbolSelectionOpened)),Qi(5),pa("ngIf",e.tracengTemplate),Qi(1),pa("ngIf",e.isSymbolSelectionOpened&&e.tracengTemplate))},directives:[Oh,Ah,f3,xp,gf,Pp,Y3,s5,cf,mf,Fp,a2,zdt],styles:["",".listcontainer[_ngcontent-%COMP%]{padding-left:0!important;padding-right:0!important}.cancel-button[_ngcontent-%COMP%], .choose-symbol-button[_ngcontent-%COMP%], .top-button[_ngcontent-%COMP%]{height:36px;margin-top:22px}.cancel-button[_ngcontent-%COMP%]{margin-right:10px}.form-field[_ngcontent-%COMP%], .select[_ngcontent-%COMP%]{width:100%}.shadowed[_ngcontent-%COMP%]{transition:.25s}.nonvisible[_ngcontent-%COMP%], .shadowed[_ngcontent-%COMP%]{display:none}.configButton[_ngcontent-%COMP%]{width:100%}.configHideButton[_ngcontent-%COMP%]{margin-left:80%;width:20%;margin-bottom:10px}.symbolSelectionButton[_ngcontent-%COMP%]{width:100%}.list-item[_ngcontent-%COMP%]{display:flex}.template-name[_ngcontent-%COMP%]{width:95%}.delete-button[_ngcontent-%COMP%]{width:10%;outline:none}.menu-button[_ngcontent-%COMP%]{width:5%;outline:none!important}th[_ngcontent-%COMP%]{border:0!important}th.mat-header-cell[_ngcontent-%COMP%]{padding-bottom:15px}td.mat-cell[_ngcontent-%COMP%]{padding-top:15px}.radio-button[_ngcontent-%COMP%]{width:50%;padding-top:20px}.radio-group[_ngcontent-%COMP%]{margin-bottom:20px}.file-button[_ngcontent-%COMP%]{width:18%}.file-name-form-field[_ngcontent-%COMP%]{padding-left:2%;width:80%}"]}),t}(),Ikt=n("l5mm");function Dkt(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function Rkt(t,e){var n=e?"":"none";Dkt(t.style,{touchAction:e?"":"none",webkitUserDrag:e?"":"none",webkitTapHighlightColor:e?"":"transparent",userSelect:n,msUserSelect:n,webkitUserSelect:n,MozUserSelect:n})}function Lkt(t){var e=t.toLowerCase().indexOf("ms")>-1?1:1e3;return parseFloat(t)*e}function Fkt(t,e){return t.getPropertyValue(e).split(",").map((function(t){return t.trim()}))}function Nkt(t){var e=t.getBoundingClientRect();return{top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:e.width,height:e.height}}function Bkt(t,e,n){return n>=t.top&&n<=t.bottom&&e>=t.left&&e<=t.right}function Hkt(t,e,n){t.top+=e,t.bottom=t.top+t.height,t.left+=n,t.right=t.left+t.width}function zkt(t,e,n,i){var r=t.width*e,o=t.height*e;return i>t.top-o&&i<t.bottom+o&&n>t.left-r&&n<t.right+r}var Vkt=function(){function t(e,n){Object(m.a)(this,t),this._document=e,this._viewportRuler=n,this.positions=new Map}return Object(g.a)(t,[{key:"clear",value:function(){this.positions.clear()}},{key:"cache",value:function(t){var e=this;this.clear(),this.positions.set(this._document,{scrollPosition:this._viewportRuler.getViewportScrollPosition()}),t.forEach((function(t){e.positions.set(t,{scrollPosition:{top:t.scrollTop,left:t.scrollLeft},clientRect:Nkt(t)})}))}},{key:"handleScroll",value:function(t){var e=t.target,n=this.positions.get(e);if(!n)return null;var i,r,o=e===this._document?e.documentElement:e,a=n.scrollPosition;if(e===this._document){var s=this._viewportRuler.getViewportScrollPosition();i=s.top,r=s.left}else i=e.scrollTop,r=e.scrollLeft;var c=a.top-i,l=a.left-r;return this.positions.forEach((function(t,n){t.clientRect&&e!==n&&o.contains(n)&&Hkt(t.clientRect,c,l)})),a.top=i,a.left=r,{top:c,left:l}}}]),t}(),Ukt=Mm({passive:!0}),qkt=Mm({passive:!1}),Gkt=function(){function t(e,n,i,r,o,a){var s=this;Object(m.a)(this,t),this._config=n,this._document=i,this._ngZone=r,this._viewportRuler=o,this._dragDropRegistry=a,this._passiveTransform={x:0,y:0},this._activeTransform={x:0,y:0},this._moveEvents=new w.b,this._pointerMoveSubscription=_.a.EMPTY,this._pointerUpSubscription=_.a.EMPTY,this._scrollSubscription=_.a.EMPTY,this._resizeSubscription=_.a.EMPTY,this._boundaryElement=null,this._nativeInteractionsEnabled=!0,this._handles=[],this._disabledHandles=new Set,this._direction="ltr",this.dragStartDelay=0,this._disabled=!1,this.beforeStarted=new w.b,this.started=new w.b,this.released=new w.b,this.ended=new w.b,this.entered=new w.b,this.exited=new w.b,this.dropped=new w.b,this.moved=this._moveEvents.asObservable(),this._pointerDown=function(t){if(s.beforeStarted.next(),s._handles.length){var e=s._handles.find((function(e){var n=t.target;return!!n&&(n===e||e.contains(n))}));!e||s._disabledHandles.has(e)||s.disabled||s._initializeDragSequence(e,t)}else s.disabled||s._initializeDragSequence(s._rootElement,t)},this._pointerMove=function(t){t.preventDefault();var e=s._getPointerPositionOnPage(t);if(s._hasStartedDragging){s._boundaryElement&&(s._previewRect&&(s._previewRect.width||s._previewRect.height)||(s._previewRect=(s._preview||s._rootElement).getBoundingClientRect()));var n=s._getConstrainedPointerPosition(e);if(s._hasMoved=!0,s._updatePointerDirectionDelta(n),s._dropContainer)s._updateActiveDropContainer(n);else{var i=s._activeTransform;if(i.x=n.x-s._pickupPositionOnPage.x+s._passiveTransform.x,i.y=n.y-s._pickupPositionOnPage.y+s._passiveTransform.y,s._applyRootElementTransform(i.x,i.y),"undefined"!=typeof SVGElement&&s._rootElement instanceof SVGElement){var r="translate(".concat(i.x," ").concat(i.y,")");s._rootElement.setAttribute("transform",r)}}s._moveEvents.observers.length&&s._ngZone.run((function(){s._moveEvents.next({source:s,pointerPosition:n,event:t,distance:s._getDragDistance(n),delta:s._pointerDirectionDelta})}))}else if(Math.abs(e.x-s._pickupPositionOnPage.x)+Math.abs(e.y-s._pickupPositionOnPage.y)>=s._config.dragStartThreshold){if(!(Date.now()>=s._dragStartTime+s._getDragStartDelay(t)))return void s._endDragSequence(t);s._dropContainer&&s._dropContainer.isDragging()||(s._hasStartedDragging=!0,s._ngZone.run((function(){return s._startDragSequence(t)})))}},this._pointerUp=function(t){s._endDragSequence(t)},this.withRootElement(e),this._parentPositions=new Vkt(i,o),a.registerDragItem(this)}return Object(g.a)(t,[{key:"getPlaceholderElement",value:function(){return this._placeholder}},{key:"getRootElement",value:function(){return this._rootElement}},{key:"getVisibleElement",value:function(){return this.isDragging()?this.getPlaceholderElement():this.getRootElement()}},{key:"withHandles",value:function(t){return this._handles=t.map((function(t){return sm(t)})),this._handles.forEach((function(t){return Rkt(t,!1)})),this._toggleNativeDragInteractions(),this}},{key:"withPreviewTemplate",value:function(t){return this._previewTemplate=t,this}},{key:"withPlaceholderTemplate",value:function(t){return this._placeholderTemplate=t,this}},{key:"withRootElement",value:function(t){var e=this,n=sm(t);return n!==this._rootElement&&(this._rootElement&&this._removeRootElementListeners(this._rootElement),this._ngZone.runOutsideAngular((function(){n.addEventListener("mousedown",e._pointerDown,qkt),n.addEventListener("touchstart",e._pointerDown,Ukt)})),this._initialTransform=void 0,this._rootElement=n),this}},{key:"withBoundaryElement",value:function(t){var e=this;return this._boundaryElement=t?sm(t):null,this._resizeSubscription.unsubscribe(),t&&(this._resizeSubscription=this._viewportRuler.change(10).subscribe((function(){return e._containInsideBoundaryOnResize()}))),this}},{key:"dispose",value:function(){this._removeRootElementListeners(this._rootElement),this.isDragging()&&Ykt(this._rootElement),Ykt(this._anchor),this._destroyPreview(),this._destroyPlaceholder(),this._dragDropRegistry.removeDragItem(this),this._removeSubscriptions(),this.beforeStarted.complete(),this.started.complete(),this.released.complete(),this.ended.complete(),this.entered.complete(),this.exited.complete(),this.dropped.complete(),this._moveEvents.complete(),this._handles=[],this._disabledHandles.clear(),this._dropContainer=void 0,this._resizeSubscription.unsubscribe(),this._parentPositions.clear(),this._boundaryElement=this._rootElement=this._placeholderTemplate=this._previewTemplate=this._anchor=null}},{key:"isDragging",value:function(){return this._hasStartedDragging&&this._dragDropRegistry.isDragging(this)}},{key:"reset",value:function(){this._rootElement.style.transform=this._initialTransform||"",this._activeTransform={x:0,y:0},this._passiveTransform={x:0,y:0}}},{key:"disableHandle",value:function(t){this._handles.indexOf(t)>-1&&this._disabledHandles.add(t)}},{key:"enableHandle",value:function(t){this._disabledHandles.delete(t)}},{key:"withDirection",value:function(t){return this._direction=t,this}},{key:"_withDropContainer",value:function(t){this._dropContainer=t}},{key:"getFreeDragPosition",value:function(){var t=this.isDragging()?this._activeTransform:this._passiveTransform;return{x:t.x,y:t.y}}},{key:"setFreeDragPosition",value:function(t){return this._activeTransform={x:0,y:0},this._passiveTransform.x=t.x,this._passiveTransform.y=t.y,this._dropContainer||this._applyRootElementTransform(t.x,t.y),this}},{key:"_sortFromLastPointerPosition",value:function(){var t=this._pointerPositionAtLastDirectionChange;t&&this._dropContainer&&this._updateActiveDropContainer(this._getConstrainedPointerPosition(t))}},{key:"_removeSubscriptions",value:function(){this._pointerMoveSubscription.unsubscribe(),this._pointerUpSubscription.unsubscribe(),this._scrollSubscription.unsubscribe()}},{key:"_destroyPreview",value:function(){this._preview&&Ykt(this._preview),this._previewRef&&this._previewRef.destroy(),this._preview=this._previewRef=null}},{key:"_destroyPlaceholder",value:function(){this._placeholder&&Ykt(this._placeholder),this._placeholderRef&&this._placeholderRef.destroy(),this._placeholder=this._placeholderRef=null}},{key:"_endDragSequence",value:function(t){var e=this;this._dragDropRegistry.isDragging(this)&&(this._removeSubscriptions(),this._dragDropRegistry.stopDragging(this),this._toggleNativeDragInteractions(),this._handles&&(this._rootElement.style.webkitTapHighlightColor=this._rootElementTapHighlight),this._hasStartedDragging&&(this.released.next({source:this}),this._dropContainer?(this._dropContainer._stopScrolling(),this._animatePreviewToPlaceholder().then((function(){e._cleanupDragArtifacts(t),e._cleanupCachedDimensions(),e._dragDropRegistry.stopDragging(e)}))):(this._passiveTransform.x=this._activeTransform.x,this._passiveTransform.y=this._activeTransform.y,this._ngZone.run((function(){e.ended.next({source:e,distance:e._getDragDistance(e._getPointerPositionOnPage(t))})})),this._cleanupCachedDimensions(),this._dragDropRegistry.stopDragging(this))))}},{key:"_startDragSequence",value:function(t){Zkt(t)&&(this._lastTouchEventTime=Date.now()),this._toggleNativeDragInteractions();var e,n=this._dropContainer;if(n){var i=this._rootElement,r=i.parentNode,o=this._preview=this._createPreviewElement(),a=this._placeholder=this._createPlaceholderElement(),s=this._anchor=this._anchor||this._document.createComment("");r.insertBefore(s,i),i.style.display="none",this._document.body.appendChild(r.replaceChild(a,i)),(e=this._document,e.fullscreenElement||e.webkitFullscreenElement||e.mozFullScreenElement||e.msFullscreenElement||e.body).appendChild(o),this.started.next({source:this}),n.start(),this._initialContainer=n,this._initialIndex=n.getItemIndex(this)}else this.started.next({source:this}),this._initialContainer=this._initialIndex=void 0;this._parentPositions.cache(n?n.getScrollableParents():[])}},{key:"_initializeDragSequence",value:function(t,e){var n=this;e.stopPropagation();var i=this.isDragging(),r=Zkt(e),o=!r&&0!==e.button,a=this._rootElement,s=!r&&this._lastTouchEventTime&&this._lastTouchEventTime+800>Date.now();if(e.target&&e.target.draggable&&"mousedown"===e.type&&e.preventDefault(),!(i||o||s)){this._handles.length&&(this._rootElementTapHighlight=a.style.webkitTapHighlightColor||"",a.style.webkitTapHighlightColor="transparent"),this._hasStartedDragging=this._hasMoved=!1,this._removeSubscriptions(),this._pointerMoveSubscription=this._dragDropRegistry.pointerMove.subscribe(this._pointerMove),this._pointerUpSubscription=this._dragDropRegistry.pointerUp.subscribe(this._pointerUp),this._scrollSubscription=this._dragDropRegistry.scroll.subscribe((function(t){n._updateOnScroll(t)})),this._boundaryElement&&(this._boundaryRect=Nkt(this._boundaryElement));var c=this._previewTemplate;this._pickupPositionInElement=c&&c.template&&!c.matchSize?{x:0,y:0}:this._getPointerPositionInElement(t,e);var l=this._pickupPositionOnPage=this._getPointerPositionOnPage(e);this._pointerDirectionDelta={x:0,y:0},this._pointerPositionAtLastDirectionChange={x:l.x,y:l.y},this._dragStartTime=Date.now(),this._dragDropRegistry.startDragging(this,e)}}},{key:"_cleanupDragArtifacts",value:function(t){var e=this;this._rootElement.style.display="",this._anchor.parentNode.replaceChild(this._rootElement,this._anchor),this._destroyPreview(),this._destroyPlaceholder(),this._boundaryRect=this._previewRect=void 0,this._ngZone.run((function(){var n=e._dropContainer,i=n.getItemIndex(e),r=e._getPointerPositionOnPage(t),o=e._getDragDistance(e._getPointerPositionOnPage(t)),a=n._isOverContainer(r.x,r.y);e.ended.next({source:e,distance:o}),e.dropped.next({item:e,currentIndex:i,previousIndex:e._initialIndex,container:n,previousContainer:e._initialContainer,isPointerOverContainer:a,distance:o}),n.drop(e,i,e._initialContainer,a,o,e._initialIndex),e._dropContainer=e._initialContainer}))}},{key:"_updateActiveDropContainer",value:function(t){var e=this,n=t.x,i=t.y,r=this._initialContainer._getSiblingContainerFromPosition(this,n,i);!r&&this._dropContainer!==this._initialContainer&&this._initialContainer._isOverContainer(n,i)&&(r=this._initialContainer),r&&r!==this._dropContainer&&this._ngZone.run((function(){e.exited.next({item:e,container:e._dropContainer}),e._dropContainer.exit(e),e._dropContainer=r,e._dropContainer.enter(e,n,i,r===e._initialContainer&&r.sortingDisabled?e._initialIndex:void 0),e.entered.next({item:e,container:r,currentIndex:r.getItemIndex(e)})})),this._dropContainer._startScrollingIfNecessary(n,i),this._dropContainer._sortItem(this,n,i,this._pointerDirectionDelta),this._preview.style.transform=Wkt(n-this._pickupPositionInElement.x,i-this._pickupPositionInElement.y)}},{key:"_createPreviewElement",value:function(){var t,e=this._previewTemplate,n=this.previewClass,i=e?e.template:null;if(i&&e){var r=e.matchSize?this._rootElement.getBoundingClientRect():null,o=e.viewContainer.createEmbeddedView(i,e.context);o.detectChanges(),t=Qkt(o,this._document),this._previewRef=o,e.matchSize?$kt(t,r):t.style.transform=Wkt(this._pickupPositionOnPage.x,this._pickupPositionOnPage.y)}else{var a=this._rootElement;$kt(t=Kkt(a),a.getBoundingClientRect())}return Dkt(t.style,{pointerEvents:"none",margin:"0",position:"fixed",top:"0",left:"0",zIndex:"".concat(this._config.zIndex||1e3)}),Rkt(t,!1),t.classList.add("cdk-drag-preview"),t.setAttribute("dir",this._direction),n&&(Array.isArray(n)?n.forEach((function(e){return t.classList.add(e)})):t.classList.add(n)),t}},{key:"_animatePreviewToPlaceholder",value:function(){var t=this;if(!this._hasMoved)return Promise.resolve();var e=this._placeholder.getBoundingClientRect();this._preview.classList.add("cdk-drag-animating"),this._preview.style.transform=Wkt(e.left,e.top);var n=function(t){var e=getComputedStyle(t),n=Fkt(e,"transition-property"),i=n.find((function(t){return"transform"===t||"all"===t}));if(!i)return 0;var r=n.indexOf(i),o=Fkt(e,"transition-duration"),a=Fkt(e,"transition-delay");return Lkt(o[r])+Lkt(a[r])}(this._preview);return 0===n?Promise.resolve():this._ngZone.runOutsideAngular((function(){return new Promise((function(e){var i=function n(i){(!i||i.target===t._preview&&"transform"===i.propertyName)&&(t._preview.removeEventListener("transitionend",n),e(),clearTimeout(r))},r=setTimeout(i,1.5*n);t._preview.addEventListener("transitionend",i)}))}))}},{key:"_createPlaceholderElement",value:function(){var t,e=this._placeholderTemplate,n=e?e.template:null;return n?(this._placeholderRef=e.viewContainer.createEmbeddedView(n,e.context),this._placeholderRef.detectChanges(),t=Qkt(this._placeholderRef,this._document)):t=Kkt(this._rootElement),t.classList.add("cdk-drag-placeholder"),t}},{key:"_getPointerPositionInElement",value:function(t,e){var n=this._rootElement.getBoundingClientRect(),i=t===this._rootElement?null:t,r=i?i.getBoundingClientRect():n,o=Zkt(e)?e.targetTouches[0]:e,a=this._getViewportScrollPosition();return{x:r.left-n.left+(o.pageX-r.left-a.left),y:r.top-n.top+(o.pageY-r.top-a.top)}}},{key:"_getPointerPositionOnPage",value:function(t){var e=this._getViewportScrollPosition(),n=Zkt(t)?t.touches[0]||t.changedTouches[0]||{pageX:0,pageY:0}:t;return{x:n.pageX-e.left,y:n.pageY-e.top}}},{key:"_getConstrainedPointerPosition",value:function(t){var e=this.constrainPosition?this.constrainPosition(t,this):t,n=this._dropContainer?this._dropContainer.lockAxis:null;if("x"===this.lockAxis||"x"===n?e.y=this._pickupPositionOnPage.y:"y"!==this.lockAxis&&"y"!==n||(e.x=this._pickupPositionOnPage.x),this._boundaryRect){var i=this._pickupPositionInElement,r=i.x,o=i.y,a=this._boundaryRect,s=this._previewRect,c=a.top+o,l=a.bottom-(s.height-o);e.x=Xkt(e.x,a.left+r,a.right-(s.width-r)),e.y=Xkt(e.y,c,l)}return e}},{key:"_updatePointerDirectionDelta",value:function(t){var e=t.x,n=t.y,i=this._pointerDirectionDelta,r=this._pointerPositionAtLastDirectionChange,o=Math.abs(e-r.x),a=Math.abs(n-r.y);return o>this._config.pointerDirectionChangeThreshold&&(i.x=e>r.x?1:-1,r.x=e),a>this._config.pointerDirectionChangeThreshold&&(i.y=n>r.y?1:-1,r.y=n),i}},{key:"_toggleNativeDragInteractions",value:function(){if(this._rootElement&&this._handles){var t=this._handles.length>0||!this.isDragging();t!==this._nativeInteractionsEnabled&&(this._nativeInteractionsEnabled=t,Rkt(this._rootElement,t))}}},{key:"_removeRootElementListeners",value:function(t){t.removeEventListener("mousedown",this._pointerDown,qkt),t.removeEventListener("touchstart",this._pointerDown,Ukt)}},{key:"_applyRootElementTransform",value:function(t,e){var n=Wkt(t,e);null==this._initialTransform&&(this._initialTransform=this._rootElement.style.transform||""),this._rootElement.style.transform=this._initialTransform?n+" "+this._initialTransform:n}},{key:"_getDragDistance",value:function(t){var e=this._pickupPositionOnPage;return e?{x:t.x-e.x,y:t.y-e.y}:{x:0,y:0}}},{key:"_cleanupCachedDimensions",value:function(){this._boundaryRect=this._previewRect=void 0,this._parentPositions.clear()}},{key:"_containInsideBoundaryOnResize",value:function(){var t=this._passiveTransform,e=t.x,n=t.y;if(!(0===e&&0===n||this.isDragging())&&this._boundaryElement){var i=this._boundaryElement.getBoundingClientRect(),r=this._rootElement.getBoundingClientRect();if(!(0===i.width&&0===i.height||0===r.width&&0===r.height)){var o=i.left-r.left,a=r.right-i.right,s=i.top-r.top,c=r.bottom-i.bottom;i.width>r.width?(o>0&&(e+=o),a>0&&(e-=a)):e=0,i.height>r.height?(s>0&&(n+=s),c>0&&(n-=c)):n=0,e===this._passiveTransform.x&&n===this._passiveTransform.y||this.setFreeDragPosition({y:n,x:e})}}}},{key:"_getDragStartDelay",value:function(t){var e=this.dragStartDelay;return"number"==typeof e?e:Zkt(t)?e.touch:e?e.mouse:0}},{key:"_updateOnScroll",value:function(t){var e=this._parentPositions.handleScroll(t);e&&(this._boundaryRect&&Hkt(this._boundaryRect,e.top,e.left),this._pickupPositionOnPage.x+=e.left,this._pickupPositionOnPage.y+=e.top,this._dropContainer||(this._activeTransform.x-=e.left,this._activeTransform.y-=e.top,this._applyRootElementTransform(this._activeTransform.x,this._activeTransform.y)))}},{key:"_getViewportScrollPosition",value:function(){var t=this._parentPositions.positions.get(this._document);return t?t.scrollPosition:this._viewportRuler.getViewportScrollPosition()}},{key:"disabled",get:function(){return this._disabled||!(!this._dropContainer||!this._dropContainer.disabled)},set:function(t){var e=nm(t);e!==this._disabled&&(this._disabled=e,this._toggleNativeDragInteractions())}}]),t}();function Wkt(t,e){return"translate3d(".concat(Math.round(t),"px, ").concat(Math.round(e),"px, 0)")}function Kkt(t){var e=t.cloneNode(!0),n=e.querySelectorAll("[id]"),i=t.querySelectorAll("canvas");e.removeAttribute("id");for(var r=0;r<n.length;r++)n[r].removeAttribute("id");if(i.length)for(var o=e.querySelectorAll("canvas"),a=0;a<i.length;a++){var s=o[a].getContext("2d");if(s)try{s.drawImage(i[a],0,0)}catch(MCt){}}return e}function Xkt(t,e,n){return Math.max(e,Math.min(n,t))}function Ykt(t){t&&t.parentNode&&t.parentNode.removeChild(t)}function Zkt(t){return"t"===t.type[0]}function Qkt(t,e){var n=t.rootNodes;if(1===n.length&&n[0].nodeType===e.ELEMENT_NODE)return n[0];var i=e.createElement("div");return n.forEach((function(t){return i.appendChild(t)})),i}function $kt(t,e){t.style.width="".concat(e.width,"px"),t.style.height="".concat(e.height,"px"),t.style.transform=Wkt(e.left,e.top)}function Jkt(t,e){return Math.max(0,Math.min(e,t))}var tCt=function(){function t(e,n,i,r,o){var a=this;Object(m.a)(this,t),this._dragDropRegistry=n,this._ngZone=r,this._viewportRuler=o,this.disabled=!1,this.sortingDisabled=!1,this.autoScrollDisabled=!1,this.enterPredicate=function(){return!0},this.beforeStarted=new w.b,this.entered=new w.b,this.exited=new w.b,this.dropped=new w.b,this.sorted=new w.b,this._isDragging=!1,this._itemPositions=[],this._previousSwap={drag:null,delta:0,overlaps:!1},this._siblings=[],this._orientation="vertical",this._activeSiblings=new Set,this._direction="ltr",this._viewportScrollSubscription=_.a.EMPTY,this._verticalScrollDirection=0,this._horizontalScrollDirection=0,this._stopScrollTimers=new w.b,this._cachedShadowRoot=null,this._startScrollInterval=function(){a._stopScrolling(),Object(Ikt.a)(0,DJ.a).pipe(Object(Am.a)(a._stopScrollTimers)).subscribe((function(){var t=a._scrollNode;1===a._verticalScrollDirection?nCt(t,-2):2===a._verticalScrollDirection&&nCt(t,2),1===a._horizontalScrollDirection?iCt(t,-2):2===a._horizontalScrollDirection&&iCt(t,2)}))},this.element=sm(e),this._document=i,this.withScrollableParents([this.element]),n.registerDropContainer(this),this._parentPositions=new Vkt(i,o)}return Object(g.a)(t,[{key:"dispose",value:function(){this._stopScrolling(),this._stopScrollTimers.complete(),this._viewportScrollSubscription.unsubscribe(),this.beforeStarted.complete(),this.entered.complete(),this.exited.complete(),this.dropped.complete(),this.sorted.complete(),this._activeSiblings.clear(),this._scrollNode=null,this._parentPositions.clear(),this._dragDropRegistry.removeDropContainer(this)}},{key:"isDragging",value:function(){return this._isDragging}},{key:"start",value:function(){var t=this,e=sm(this.element).style;this.beforeStarted.next(),this._isDragging=!0,this._initialScrollSnap=e.msScrollSnapType||e.scrollSnapType||"",e.scrollSnapType=e.msScrollSnapType="none",this._cacheItems(),this._siblings.forEach((function(e){return e._startReceiving(t)})),this._viewportScrollSubscription.unsubscribe(),this._listenToScrollEvents()}},{key:"enter",value:function(t,e,n,i){var r;this.start(),null==i?-1===(r=this.sortingDisabled?this._draggables.indexOf(t):-1)&&(r=this._getItemIndexFromPointerPosition(t,e,n)):r=i;var o=this._activeDraggables,a=o.indexOf(t),s=t.getPlaceholderElement(),c=o[r];if(c===t&&(c=o[r+1]),a>-1&&o.splice(a,1),c&&!this._dragDropRegistry.isDragging(c)){var l=c.getRootElement();l.parentElement.insertBefore(s,l),o.splice(r,0,t)}else if(this._shouldEnterAsFirstChild(e,n)){var u=o[0].getRootElement();u.parentNode.insertBefore(s,u),o.unshift(t)}else sm(this.element).appendChild(s),o.push(t);s.style.transform="",this._cacheItemPositions(),this._cacheParentPositions(),this.entered.next({item:t,container:this,currentIndex:this.getItemIndex(t)})}},{key:"exit",value:function(t){this._reset(),this.exited.next({item:t,container:this})}},{key:"drop",value:function(t,e,n,i,r,o){this._reset(),null==o&&(o=n.getItemIndex(t)),this.dropped.next({item:t,currentIndex:e,previousIndex:o,container:this,previousContainer:n,isPointerOverContainer:i,distance:r})}},{key:"withItems",value:function(t){var e=this,n=this._draggables;return this._draggables=t,t.forEach((function(t){return t._withDropContainer(e)})),this.isDragging()&&(n.filter((function(t){return t.isDragging()})).every((function(e){return-1===t.indexOf(e)}))?this._reset():this._cacheItems()),this}},{key:"withDirection",value:function(t){return this._direction=t,this}},{key:"connectedTo",value:function(t){return this._siblings=t.slice(),this}},{key:"withOrientation",value:function(t){return this._orientation=t,this}},{key:"withScrollableParents",value:function(t){var e=sm(this.element);return this._scrollableElements=-1===t.indexOf(e)?[e].concat(Object(u.a)(t)):t.slice(),this}},{key:"getScrollableParents",value:function(){return this._scrollableElements}},{key:"getItemIndex",value:function(t){return this._isDragging?eCt("horizontal"===this._orientation&&"rtl"===this._direction?this._itemPositions.slice().reverse():this._itemPositions,(function(e){return e.drag===t})):this._draggables.indexOf(t)}},{key:"isReceiving",value:function(){return this._activeSiblings.size>0}},{key:"_sortItem",value:function(t,e,n,i){if(!this.sortingDisabled&&zkt(this._clientRect,.05,e,n)){var r=this._itemPositions,o=this._getItemIndexFromPointerPosition(t,e,n,i);if(!(-1===o&&r.length>0)){var a="horizontal"===this._orientation,s=eCt(r,(function(e){return e.drag===t})),c=r[o],l=c.clientRect,u=s>o?1:-1,h=this._getItemOffsetPx(r[s].clientRect,l,u),d=this._getSiblingOffsetPx(s,r,u),f=r.slice();!function(t,e,n){var i=Jkt(e,t.length-1),r=Jkt(n,t.length-1);if(i!==r){for(var o=t[i],a=r<i?-1:1,s=i;s!==r;s+=a)t[s]=t[s+a];t[r]=o}}(r,s,o),this.sorted.next({previousIndex:s,currentIndex:o,container:this,item:t}),r.forEach((function(e,n){if(f[n]!==e){var i=e.drag===t,r=i?h:d,o=i?t.getPlaceholderElement():e.drag.getRootElement();e.offset+=r,a?(o.style.transform="translate3d(".concat(Math.round(e.offset),"px, 0, 0)"),Hkt(e.clientRect,0,r)):(o.style.transform="translate3d(0, ".concat(Math.round(e.offset),"px, 0)"),Hkt(e.clientRect,r,0))}})),this._previousSwap.overlaps=Bkt(l,e,n),this._previousSwap.drag=c.drag,this._previousSwap.delta=a?i.x:i.y}}}},{key:"_startScrollingIfNecessary",value:function(t,e){var n=this;if(!this.autoScrollDisabled){var i,r=0,o=0;if(this._parentPositions.positions.forEach((function(a,s){if(s!==n._document&&a.clientRect&&!i&&zkt(a.clientRect,.05,t,e)){var c=l(function(t,e,n,i){var r=rCt(e,i),o=oCt(e,n),a=0,s=0;if(r){var c=t.scrollTop;1===r?c>0&&(a=1):t.scrollHeight-c>t.clientHeight&&(a=2)}if(o){var l=t.scrollLeft;1===o?l>0&&(s=1):t.scrollWidth-l>t.clientWidth&&(s=2)}return[a,s]}(s,a.clientRect,t,e),2);o=c[1],((r=c[0])||o)&&(i=s)}})),!r&&!o){var a=this._viewportRuler.getViewportSize(),s=a.width,c=a.height,u={width:s,height:c,top:0,right:s,bottom:c,left:0};r=rCt(u,e),o=oCt(u,t),i=window}!i||r===this._verticalScrollDirection&&o===this._horizontalScrollDirection&&i===this._scrollNode||(this._verticalScrollDirection=r,this._horizontalScrollDirection=o,this._scrollNode=i,(r||o)&&i?this._ngZone.runOutsideAngular(this._startScrollInterval):this._stopScrolling())}}},{key:"_stopScrolling",value:function(){this._stopScrollTimers.next()}},{key:"_cacheParentPositions",value:function(){var t=sm(this.element);this._parentPositions.cache(this._scrollableElements),this._clientRect=this._parentPositions.positions.get(t).clientRect}},{key:"_cacheItemPositions",value:function(){var t="horizontal"===this._orientation;this._itemPositions=this._activeDraggables.map((function(t){var e=t.getVisibleElement();return{drag:t,offset:0,clientRect:Nkt(e)}})).sort((function(e,n){return t?e.clientRect.left-n.clientRect.left:e.clientRect.top-n.clientRect.top}))}},{key:"_reset",value:function(){var t=this;this._isDragging=!1;var e=sm(this.element).style;e.scrollSnapType=e.msScrollSnapType=this._initialScrollSnap,this._activeDraggables.forEach((function(t){var e=t.getRootElement();e&&(e.style.transform="")})),this._siblings.forEach((function(e){return e._stopReceiving(t)})),this._activeDraggables=[],this._itemPositions=[],this._previousSwap.drag=null,this._previousSwap.delta=0,this._previousSwap.overlaps=!1,this._stopScrolling(),this._viewportScrollSubscription.unsubscribe(),this._parentPositions.clear()}},{key:"_getSiblingOffsetPx",value:function(t,e,n){var i="horizontal"===this._orientation,r=e[t].clientRect,o=e[t+-1*n],a=r[i?"width":"height"]*n;if(o){var s=i?"left":"top",c=i?"right":"bottom";-1===n?a-=o.clientRect[s]-r[c]:a+=r[s]-o.clientRect[c]}return a}},{key:"_getItemOffsetPx",value:function(t,e,n){var i="horizontal"===this._orientation,r=i?e.left-t.left:e.top-t.top;return-1===n&&(r+=i?e.width-t.width:e.height-t.height),r}},{key:"_shouldEnterAsFirstChild",value:function(t,e){if(!this._activeDraggables.length)return!1;var n=this._itemPositions,i="horizontal"===this._orientation;if(n[0].drag!==this._activeDraggables[0]){var r=n[n.length-1].clientRect;return i?t>=r.right:e>=r.bottom}var o=n[0].clientRect;return i?t<=o.left:e<=o.top}},{key:"_getItemIndexFromPointerPosition",value:function(t,e,n,i){var r=this,o="horizontal"===this._orientation;return eCt(this._itemPositions,(function(a,s,c){var l=a.drag,u=a.clientRect;return l===t?c.length<2:(!i||l!==r._previousSwap.drag||!r._previousSwap.overlaps||(o?i.x:i.y)!==r._previousSwap.delta)&&(o?e>=Math.floor(u.left)&&e<Math.floor(u.right):n>=Math.floor(u.top)&&n<Math.floor(u.bottom))}))}},{key:"_cacheItems",value:function(){this._activeDraggables=this._draggables.slice(),this._cacheItemPositions(),this._cacheParentPositions()}},{key:"_isOverContainer",value:function(t,e){return Bkt(this._clientRect,t,e)}},{key:"_getSiblingContainerFromPosition",value:function(t,e,n){return this._siblings.find((function(i){return i._canReceive(t,e,n)}))}},{key:"_canReceive",value:function(t,e,n){if(!Bkt(this._clientRect,e,n)||!this.enterPredicate(t,this))return!1;var i=this._getShadowRoot().elementFromPoint(e,n);if(!i)return!1;var r=sm(this.element);return i===r||r.contains(i)}},{key:"_startReceiving",value:function(t){var e=this._activeSiblings;e.has(t)||(e.add(t),this._cacheParentPositions(),this._listenToScrollEvents())}},{key:"_stopReceiving",value:function(t){this._activeSiblings.delete(t),this._viewportScrollSubscription.unsubscribe()}},{key:"_listenToScrollEvents",value:function(){var t=this;this._viewportScrollSubscription=this._dragDropRegistry.scroll.subscribe((function(e){if(t.isDragging()){var n=t._parentPositions.handleScroll(e);n&&(t._itemPositions.forEach((function(t){Hkt(t.clientRect,n.top,n.left)})),t._itemPositions.forEach((function(e){var n=e.drag;t._dragDropRegistry.isDragging(n)&&n._sortFromLastPointerPosition()})))}else t.isReceiving()&&t._cacheParentPositions()}))}},{key:"_getShadowRoot",value:function(){if(!this._cachedShadowRoot){var t=Em(sm(this.element));this._cachedShadowRoot=t||this._document}return this._cachedShadowRoot}}]),t}();function eCt(t,e){for(var n=0;n<t.length;n++)if(e(t[n],n,t))return n;return-1}function nCt(t,e){t===window?t.scrollBy(0,e):t.scrollTop+=e}function iCt(t,e){t===window?t.scrollBy(e,0):t.scrollLeft+=e}function rCt(t,e){var n=t.top,i=t.bottom,r=.05*t.height;return e>=n-r&&e<=n+r?1:e>=i-r&&e<=i+r?2:0}function oCt(t,e){var n=t.left,i=t.right,r=.05*t.width;return e>=n-r&&e<=n+r?1:e>=i-r&&e<=i+r?2:0}var aCt=Mm({passive:!1,capture:!0}),sCt=function(){var t=function(){function t(e,n){var i=this;Object(m.a)(this,t),this._ngZone=e,this._dropInstances=new Set,this._dragInstances=new Set,this._activeDragInstances=new Set,this._globalListeners=new Map,this.pointerMove=new w.b,this.pointerUp=new w.b,this.scroll=new w.b,this._preventDefaultWhileDragging=function(t){i._activeDragInstances.size&&t.preventDefault()},this._document=n}return Object(g.a)(t,[{key:"registerDropContainer",value:function(t){this._dropInstances.has(t)||this._dropInstances.add(t)}},{key:"registerDragItem",value:function(t){var e=this;this._dragInstances.add(t),1===this._dragInstances.size&&this._ngZone.runOutsideAngular((function(){e._document.addEventListener("touchmove",e._preventDefaultWhileDragging,aCt)}))}},{key:"removeDropContainer",value:function(t){this._dropInstances.delete(t)}},{key:"removeDragItem",value:function(t){this._dragInstances.delete(t),this.stopDragging(t),0===this._dragInstances.size&&this._document.removeEventListener("touchmove",this._preventDefaultWhileDragging,aCt)}},{key:"startDragging",value:function(t,e){var n=this;if(!this._activeDragInstances.has(t)&&(this._activeDragInstances.add(t),1===this._activeDragInstances.size)){var i=e.type.startsWith("touch"),r=i?"touchend":"mouseup";this._globalListeners.set(i?"touchmove":"mousemove",{handler:function(t){return n.pointerMove.next(t)},options:aCt}).set(r,{handler:function(t){return n.pointerUp.next(t)},options:!0}).set("scroll",{handler:function(t){return n.scroll.next(t)},options:!0}).set("selectstart",{handler:this._preventDefaultWhileDragging,options:aCt}),this._ngZone.runOutsideAngular((function(){n._globalListeners.forEach((function(t,e){n._document.addEventListener(e,t.handler,t.options)}))}))}}},{key:"stopDragging",value:function(t){this._activeDragInstances.delete(t),0===this._activeDragInstances.size&&this._clearGlobalListeners()}},{key:"isDragging",value:function(t){return this._activeDragInstances.has(t)}},{key:"ngOnDestroy",value:function(){var t=this;this._dragInstances.forEach((function(e){return t.removeDragItem(e)})),this._dropInstances.forEach((function(e){return t.removeDropContainer(e)})),this._clearGlobalListeners(),this.pointerMove.complete(),this.pointerUp.complete()}},{key:"_clearGlobalListeners",value:function(){var t=this;this._globalListeners.forEach((function(e,n){t._document.removeEventListener(n,e.handler,e.options)})),this._globalListeners.clear()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(jl),_t(du))},t.\u0275prov=R({factory:function(){return new t(_t(jl),_t(du))},token:t,providedIn:"root"}),t}(),cCt={dragStartThreshold:5,pointerDirectionChangeThreshold:5},lCt=function(){var t=function(){function t(e,n,i,r){Object(m.a)(this,t),this._document=e,this._ngZone=n,this._viewportRuler=i,this._dragDropRegistry=r}return Object(g.a)(t,[{key:"createDrag",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:cCt;return new Gkt(t,e,this._document,this._ngZone,this._viewportRuler,this._dragDropRegistry)}},{key:"createDropList",value:function(t){return new tCt(t,this._dragDropRegistry,this._document,this._ngZone,this._viewportRuler)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(_t(du),_t(jl),_t(zJ),_t(sCt))},t.\u0275prov=R({factory:function(){return new t(_t(du),_t(jl),_t(zJ),_t(sCt))},token:t,providedIn:"root"}),t}(),uCt=new ht("CDK_DRAG_PARENT"),hCt=function(){var t=function(){function t(e,n){Object(m.a)(this,t),this.element=e,this._stateChanges=new w.b,this._disabled=!1,this._parentDrag=n,Rkt(e.nativeElement,!1)}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this._stateChanges.complete()}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t),this._stateChanges.next(this)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(uCt,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdkDragHandle",""]],hostAttrs:[1,"cdk-drag-handle"],inputs:{disabled:["cdkDragHandleDisabled","disabled"]}}),t}(),dCt=function(){var t=function t(e){Object(m.a)(this,t),this.templateRef=e};return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["ng-template","cdkDragPlaceholder",""]],inputs:{data:"data"}}),t}(),fCt=function(){var t=function(){function t(e){Object(m.a)(this,t),this.templateRef=e,this._matchSize=!1}return Object(g.a)(t,[{key:"matchSize",get:function(){return this._matchSize},set:function(t){this._matchSize=nm(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(fc))},t.\u0275dir=Wt({type:t,selectors:[["ng-template","cdkDragPreview",""]],inputs:{matchSize:"matchSize",data:"data"}}),t}(),pCt=new ht("CDK_DRAG_CONFIG"),mCt=new ht("CDK_DROP_LIST"),gCt=function(){var t=function(){function t(e,n,i,r,o,a,s,c,l){var u=this;Object(m.a)(this,t),this.element=e,this.dropContainer=n,this._document=i,this._ngZone=r,this._viewContainerRef=o,this._dir=s,this._changeDetectorRef=l,this._destroyed=new w.b,this.started=new Uc,this.released=new Uc,this.ended=new Uc,this.entered=new Uc,this.exited=new Uc,this.dropped=new Uc,this.moved=new k.a((function(t){var e=u._dragRef.moved.pipe(Object(ef.a)((function(t){return{source:u,pointerPosition:t.pointerPosition,event:t.event,delta:t.delta,distance:t.distance}}))).subscribe(t);return function(){e.unsubscribe()}})),this._dragRef=c.createDrag(e,{dragStartThreshold:a&&null!=a.dragStartThreshold?a.dragStartThreshold:5,pointerDirectionChangeThreshold:a&&null!=a.pointerDirectionChangeThreshold?a.pointerDirectionChangeThreshold:5,zIndex:null==a?void 0:a.zIndex}),this._dragRef.data=this,a&&this._assignDefaults(a),n&&(this._dragRef._withDropContainer(n._dropListRef),n.addItem(this)),this._syncInputs(this._dragRef),this._handleEvents(this._dragRef)}return Object(g.a)(t,[{key:"getPlaceholderElement",value:function(){return this._dragRef.getPlaceholderElement()}},{key:"getRootElement",value:function(){return this._dragRef.getRootElement()}},{key:"reset",value:function(){this._dragRef.reset()}},{key:"getFreeDragPosition",value:function(){return this._dragRef.getFreeDragPosition()}},{key:"ngAfterViewInit",value:function(){var t=this;this._ngZone.onStable.asObservable().pipe(Object(FX.a)(1),Object(Am.a)(this._destroyed)).subscribe((function(){t._updateRootElement(),t._handles.changes.pipe(Object(NX.a)(t._handles),Object(DX.a)((function(e){var n=e.filter((function(e){return e._parentDrag===t})).map((function(t){return t.element}));t._dragRef.withHandles(n)})),Object(LX.a)((function(t){return C.a.apply(void 0,Object(u.a)(t.map((function(t){return t._stateChanges.pipe(Object(NX.a)(t))}))))})),Object(Am.a)(t._destroyed)).subscribe((function(e){var n=t._dragRef,i=e.element.nativeElement;e.disabled?n.disableHandle(i):n.enableHandle(i)})),t.freeDragPosition&&t._dragRef.setFreeDragPosition(t.freeDragPosition)}))}},{key:"ngOnChanges",value:function(t){var e=t.rootElementSelector,n=t.freeDragPosition;e&&!e.firstChange&&this._updateRootElement(),n&&!n.firstChange&&this.freeDragPosition&&this._dragRef.setFreeDragPosition(this.freeDragPosition)}},{key:"ngOnDestroy",value:function(){this.dropContainer&&this.dropContainer.removeItem(this),this._destroyed.next(),this._destroyed.complete(),this._dragRef.dispose()}},{key:"_updateRootElement",value:function(){var t=this.element.nativeElement,e=this.rootElementSelector?vCt(t,this.rootElementSelector):t;if(e&&e.nodeType!==this._document.ELEMENT_NODE)throw Error("cdkDrag must be attached to an element node. "+'Currently attached to "'.concat(e.nodeName,'".'));this._dragRef.withRootElement(e||t)}},{key:"_getBoundaryElement",value:function(){var t=this.boundaryElement;if(!t)return null;if("string"==typeof t)return vCt(this.element.nativeElement,t);var e=sm(t);if(ii()&&!e.contains(this.element.nativeElement))throw Error("Draggable element is not inside of the node passed into cdkDragBoundary.");return e}},{key:"_syncInputs",value:function(t){var e=this;t.beforeStarted.subscribe((function(){if(!t.isDragging()){var n=e._dir,i=e.dragStartDelay,r=e._placeholderTemplate?{template:e._placeholderTemplate.templateRef,context:e._placeholderTemplate.data,viewContainer:e._viewContainerRef}:null,o=e._previewTemplate?{template:e._previewTemplate.templateRef,context:e._previewTemplate.data,matchSize:e._previewTemplate.matchSize,viewContainer:e._viewContainerRef}:null;t.disabled=e.disabled,t.lockAxis=e.lockAxis,t.dragStartDelay="object"==typeof i&&i?i:im(i),t.constrainPosition=e.constrainPosition,t.previewClass=e.previewClass,t.withBoundaryElement(e._getBoundaryElement()).withPlaceholderTemplate(r).withPreviewTemplate(o),n&&t.withDirection(n.value)}}))}},{key:"_handleEvents",value:function(t){var e=this;t.started.subscribe((function(){e.started.emit({source:e}),e._changeDetectorRef.markForCheck()})),t.released.subscribe((function(){e.released.emit({source:e})})),t.ended.subscribe((function(t){e.ended.emit({source:e,distance:t.distance}),e._changeDetectorRef.markForCheck()})),t.entered.subscribe((function(t){e.entered.emit({container:t.container.data,item:e,currentIndex:t.currentIndex})})),t.exited.subscribe((function(t){e.exited.emit({container:t.container.data,item:e})})),t.dropped.subscribe((function(t){e.dropped.emit({previousIndex:t.previousIndex,currentIndex:t.currentIndex,previousContainer:t.previousContainer.data,container:t.container.data,isPointerOverContainer:t.isPointerOverContainer,item:e,distance:t.distance})}))}},{key:"_assignDefaults",value:function(t){var e=t.lockAxis,n=t.dragStartDelay,i=t.constrainPosition,r=t.previewClass,o=t.boundaryElement,a=t.draggingDisabled,s=t.rootElementSelector;this.disabled=null!=a&&a,this.dragStartDelay=n||0,e&&(this.lockAxis=e),i&&(this.constrainPosition=i),r&&(this.previewClass=r),o&&(this.boundaryElement=o),s&&(this.rootElementSelector=s)}},{key:"disabled",get:function(){return this._disabled||this.dropContainer&&this.dropContainer.disabled},set:function(t){this._disabled=nm(t),this._dragRef.disabled=this._disabled}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(mCt,12),da(du),da(jl),da(mc),da(pCt,8),da(gm,8),da(lCt),da(Po))},t.\u0275dir=Wt({type:t,selectors:[["","cdkDrag",""]],contentQueries:function(t,e,n){var i;1&t&&(rl(n,fCt,!0),rl(n,dCt,!0),rl(n,hCt,!0)),2&t&&(tl(i=sl())&&(e._previewTemplate=i.first),tl(i=sl())&&(e._placeholderTemplate=i.first),tl(i=sl())&&(e._handles=i))},hostAttrs:[1,"cdk-drag"],hostVars:4,hostBindings:function(t,e){2&t&&Qa("cdk-drag-disabled",e.disabled)("cdk-drag-dragging",e._dragRef.isDragging())},inputs:{disabled:["cdkDragDisabled","disabled"],dragStartDelay:["cdkDragStartDelay","dragStartDelay"],lockAxis:["cdkDragLockAxis","lockAxis"],constrainPosition:["cdkDragConstrainPosition","constrainPosition"],previewClass:["cdkDragPreviewClass","previewClass"],boundaryElement:["cdkDragBoundary","boundaryElement"],rootElementSelector:["cdkDragRootElement","rootElementSelector"],data:["cdkDragData","data"],freeDragPosition:["cdkDragFreeDragPosition","freeDragPosition"]},outputs:{started:"cdkDragStarted",released:"cdkDragReleased",ended:"cdkDragEnded",entered:"cdkDragEntered",exited:"cdkDragExited",dropped:"cdkDragDropped",moved:"cdkDragMoved"},exportAs:["cdkDrag"],features:[Ns([{provide:uCt,useExisting:t}]),Ms]}),t}();function vCt(t,e){for(var n=t.parentElement;n;){if(n.matches?n.matches(e):n.msMatchesSelector(e))return n;n=n.parentElement}return null}var bCt,yCt,_Ct,wCt=function(){var t=function(){function t(){Object(m.a)(this,t),this._items=new Set,this._disabled=!1}return Object(g.a)(t,[{key:"ngOnDestroy",value:function(){this._items.clear()}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=nm(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=Wt({type:t,selectors:[["","cdkDropListGroup",""]],inputs:{disabled:["cdkDropListGroupDisabled","disabled"]},exportAs:["cdkDropListGroup"]}),t}(),kCt=0,CCt=function(){var t=function(){function t(e,n,i,r,o,a,s){var c=this;Object(m.a)(this,t),this.element=e,this._changeDetectorRef=i,this._dir=r,this._group=o,this._scrollDispatcher=a,this._destroyed=new w.b,this.connectedTo=[],this.id="cdk-drop-list-".concat(kCt++),this.enterPredicate=function(){return!0},this.dropped=new Uc,this.entered=new Uc,this.exited=new Uc,this.sorted=new Uc,this._unsortedItems=new Set,this._dropListRef=n.createDropList(e),this._dropListRef.data=this,s&&this._assignDefaults(s),this._dropListRef.enterPredicate=function(t,e){return c.enterPredicate(t.data,e.data)},this._setupInputSyncSubscription(this._dropListRef),this._handleEvents(this._dropListRef),t._dropLists.push(this),o&&o._items.add(this)}return Object(g.a)(t,[{key:"addItem",value:function(t){this._unsortedItems.add(t),this._dropListRef.isDragging()&&this._syncItemsWithRef()}},{key:"removeItem",value:function(t){this._unsortedItems.delete(t),this._dropListRef.isDragging()&&this._syncItemsWithRef()}},{key:"getSortedItems",value:function(){return Array.from(this._unsortedItems).sort((function(t,e){return t._dragRef.getVisibleElement().compareDocumentPosition(e._dragRef.getVisibleElement())&Node.DOCUMENT_POSITION_FOLLOWING?-1:1}))}},{key:"ngOnDestroy",value:function(){var e=t._dropLists.indexOf(this);e>-1&&t._dropLists.splice(e,1),this._group&&this._group._items.delete(this),this._unsortedItems.clear(),this._dropListRef.dispose(),this._destroyed.next(),this._destroyed.complete()}},{key:"_setupInputSyncSubscription",value:function(e){var n=this;this._dir&&this._dir.change.pipe(Object(NX.a)(this._dir.value),Object(Am.a)(this._destroyed)).subscribe((function(t){return e.withDirection(t)})),e.beforeStarted.subscribe((function(){var i=om(n.connectedTo).map((function(e){return"string"==typeof e?t._dropLists.find((function(t){return t.id===e})):e}));if(n._group&&n._group._items.forEach((function(t){-1===i.indexOf(t)&&i.push(t)})),!n._scrollableParentsResolved&&n._scrollDispatcher){var r=n._scrollDispatcher.getAncestorScrollContainers(n.element).map((function(t){return t.getElementRef().nativeElement}));n._dropListRef.withScrollableParents(r),n._scrollableParentsResolved=!0}e.disabled=n.disabled,e.lockAxis=n.lockAxis,e.sortingDisabled=nm(n.sortingDisabled),e.autoScrollDisabled=nm(n.autoScrollDisabled),e.connectedTo(i.filter((function(t){return t&&t!==n})).map((function(t){return t._dropListRef}))).withOrientation(n.orientation)}))}},{key:"_handleEvents",value:function(t){var e=this;t.beforeStarted.subscribe((function(){e._syncItemsWithRef(),e._changeDetectorRef.markForCheck()})),t.entered.subscribe((function(t){e.entered.emit({container:e,item:t.item.data,currentIndex:t.currentIndex})})),t.exited.subscribe((function(t){e.exited.emit({container:e,item:t.item.data}),e._changeDetectorRef.markForCheck()})),t.sorted.subscribe((function(t){e.sorted.emit({previousIndex:t.previousIndex,currentIndex:t.currentIndex,container:e,item:t.item.data})})),t.dropped.subscribe((function(t){e.dropped.emit({previousIndex:t.previousIndex,currentIndex:t.currentIndex,previousContainer:t.previousContainer.data,container:t.container.data,item:t.item.data,isPointerOverContainer:t.isPointerOverContainer,distance:t.distance}),e._changeDetectorRef.markForCheck()}))}},{key:"_assignDefaults",value:function(t){var e=t.lockAxis,n=t.draggingDisabled,i=t.sortingDisabled,r=t.listAutoScrollDisabled,o=t.listOrientation;this.disabled=null!=n&&n,this.sortingDisabled=null!=i&&i,this.autoScrollDisabled=null!=r&&r,this.orientation=o||"vertical",e&&(this.lockAxis=e)}},{key:"_syncItemsWithRef",value:function(){this._dropListRef.withItems(this.getSortedItems().map((function(t){return t._dragRef})))}},{key:"disabled",get:function(){return this._disabled||!!this._group&&this._group.disabled},set:function(t){this._dropListRef.disabled=this._disabled=nm(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(da(Us),da(lCt),da(Po),da(gm,8),da(wCt,12),da(BJ),da(pCt,8))},t.\u0275dir=Wt({type:t,selectors:[["","cdkDropList",""],["cdk-drop-list"]],hostAttrs:[1,"cdk-drop-list"],hostVars:7,hostBindings:function(t,e){2&t&&(bs("id",e.id),Qa("cdk-drop-list-disabled",e.disabled)("cdk-drop-list-dragging",e._dropListRef.isDragging())("cdk-drop-list-receiving",e._dropListRef.isReceiving()))},inputs:{connectedTo:["cdkDropListConnectedTo","connectedTo"],id:"id",enterPredicate:["cdkDropListEnterPredicate","enterPredicate"],disabled:["cdkDropListDisabled","disabled"],sortingDisabled:["cdkDropListSortingDisabled","sortingDisabled"],autoScrollDisabled:["cdkDropListAutoScrollDisabled","autoScrollDisabled"],orientation:["cdkDropListOrientation","orientation"],lockAxis:["cdkDropListLockAxis","lockAxis"],data:["cdkDropListData","data"]},outputs:{dropped:"cdkDropListDropped",entered:"cdkDropListEntered",exited:"cdkDropListExited",sorted:"cdkDropListSorted"},exportAs:["cdkDropList"],features:[Ns([{provide:wCt,useValue:void 0},{provide:mCt,useExisting:t}])]}),t._dropLists=[],t}(),SCt=function(){var t=function t(){Object(m.a)(this,t)};return t.\u0275mod=qt({type:t}),t.\u0275inj=F({factory:function(e){return new(e||t)},providers:[lCt],imports:[VJ]}),t}(),xCt=function(){function t(t){t.events.subscribe((function(t){t instanceof GX&&(gtag("set","page",t.url),gtag("send","pageview"))}))}return t.\u0275prov=R({token:t,factory:t.\u0275fac=function(e){return new(e||t)(_t(lQ))}}),t}(),OCt=function(){function t(t){this._googleAnalyticsService=t}return t.\u0275mod=qt({type:t,bootstrap:[tyt]}),t.\u0275inj=F({factory:function(e){return new(e||t)(_t(xCt))},providers:[QQ,{provide:Gn,useClass:J_t},GK,cht,$Q,a9,ZQ,yot,E2,q9,x9,NQ,YQ,olt,mlt,Y2,yet,vet,G9,M9,ayt,Nlt,Zet,lit,E9,XQ,Wut,urt,$nt,ckt,w6,fft,oft,Eft,Qft,got,dmt,hmt,umt,J7,k6,n6,T2,K5,pgt,V7,pot,i8,vot,Y7,bit,nht,tit,edt,tdt,wit,L9,F9,$8,U0,_ot,ykt,ptt,Yrt,Uvt,Kit,xCt,Q8,qbt,Kbt,Yd,cot],imports:[[Wd,Zg,Ybt,tm,em,Oy,mg,oyt,eX.forRoot(),pX,vX,SX,skt,Flt,Yct,SCt,aht,zwt,Vit.forRoot(),_bt.forRoot()]]}),t}();bCt=[Oh,Mh,Eh,Ah,zh,Hh,Rh,Lh,Fh,Nh,Bh,mQ,hQ,dQ,pQ,aY,xp,Vf,Wf,cf,Ef,Df,of,zf,Gf,jf,mf,gf,Hp,Wp,Xp,Zp,zp,qp,Sp,wp,gp,Tp,Pp,Fp,jp,Dp,dg,Jm,Bm,tg,Hm,zm,Um,Km,ig,Gm,Wm,eg,Zm,ng,$m,cg,lg,ug,pg,rg,hg,git,Cct,JK,tX,CX,kX,HJ,vm,nkt,ikt,ekt,okt,akt,rkt,Dlt,Llt,Wct,Xct,Uct,CCt,wCt,gCt,hCt,fCt,dCt,aot,a2,s2,D0,E0,N0,O0,f3,p3,m3,n3,i3,r3,o3,a3,c3,l3,u3,s3,h3,d3,Tct,Mct,x2,R3,Y3,H3,z3,V3,U3,q3,J3,t5,s5,n5,$5,t4,a4,n4,J5,c4,e4,s4,i4,o4,r4,l4,h4,u4,d4,f4,X0,i1,r1,o1,a1,hlt,ust,hst,G2,F5,B5,_8,y8,S8,w8,aJ,k8,C8,wJ,P8,E8,a8,Sdt,ydt,_dt,wdt,Cdt,kdt,gdt,mat,wat,O5,x5,EJ,xJ,k4,C4,aat,sat,rat,$ot,oat,cat,lat,eat,iat,A6,D6,ywt,owt,awt,cwt,lwt,swt,U1,P1,I1,Q1,t2,E1,Lwt,Rwt,Fwt,Hwt,Bwt,Dwt,Nwt,Hrt,Abt,xbt,Ibt,Obt,Cbt,Sbt,ybt,tyt,Uut,Iht,eht,alt,glt,Yht,wrt,grt,lrt,Jht,plt,get,q8,X8,ilt,Fct,dtt,htt,U9,ttt,Dtt,A9,Ttt,ytt,wtt,Ptt,jtt,blt,Odt,Tdt,Mdt,gst,hht,Clt,xlt,Omt,Jit,bst,Cst,Sst,wst,kst,vst,_st,yst,gmt,H9,Z9,Mtt,dkt,Ndt,dft,rft,fkt,pkt,_ft,wft,Tft,mkt,Lft,Wft,Yft,Zft,rpt,opt,hpt,bpt,ypt,zpt,Xpt,Ypt,nmt,gkt,lmt,Ymt,fgt,d9,vkt,wgt,Agt,Rgt,Edt,xtt,vtt,Pdt,Vgt,Xgt,nvt,lvt,mvt,Svt,xvt,Ovt,Tvt,Mvt,Adt,zdt,Bvt,Hdt,vlt,pmt,e9,M2,Hvt,Jbt,ort,zvt,itt,ott,qlt,xrt,yut,u2,ftt,ctt,utt,n9,f9,p9,Rrt,Z8,W8,V8,q5,W5,G4,H4,e6,_6,p6,c7,A7,C7,z7,X7,$7,n8,B8,H8,z8,_kt,wkt,Tkt,jkt,G6,Rht,Ctt,Itt,Wrt,Wit,Vvt,Rtt,Ltt,Xrt,att,$vt,Lht,Pct,Jvt,Ubt,Vbt,Bbt,i9,J8,Ylt,out,t9,Wbt,nst,o9,r9,hot,wot,Oot,D8,o8],yCt=[Wh,Zh,Kh,ed,ud,od,ad,Yh,sd,Qh,Jh,td,id,s9,Pvt,Evt,Cat,Act,bkt],(_Ct=Yht.\u0275cmp).directiveDefs=function(){return bCt.map(zt)},_Ct.pipeDefs=function(){return yCt.map(Vt)},function(){if(ni)throw new Error("Cannot enable prod mode after platform setup.");ei=!1}(),qd().bootstrapModule(OCt).then((function(t){var e,n=t.injector.get(Jl);e=new $d(n.components[0]),"undefined"!=typeof COMPILED&&COMPILED||((it.ng=it.ng||{}).profiler=e)})).catch((function(t){return console.log(t)}))},zahk:function(t,e,n){t.exports=n("T8ZO")},zuyY:function(t,e){t.exports={parse:function(){return this.createSingleNodeList(this.Identifier())}}}},[[0,0]]]);