(window.webpackJsonp=window.webpackJsonp||[]).push([[11],{jaWL:function(e,n,t){"use strict";t.r(n);var o=t("8Y7J");class l{}var s=t("pMnS"),i=t("B4Mn"),r=t("Kj3r"),c=t("Wb/s"),u=t("xVS5"),a=t("+WIb");c.Terminal.applyAddon(u);class d{constructor(e){this.$ws=e,this.io=this.$ws.connectToNamespace("log"),this.term=new c.Terminal,this.resize=new i.a}ngOnInit(){window.document.querySelector("body").classList.add("bg-black"),this.termTarget=document.getElementById("log-output"),this.term.open(this.termTarget),this.term.fit(),this.io.connected.subscribe(()=>{this.io.socket.emit("tail-log",{cols:this.term.cols,rows:this.term.rows})}),this.io.socket.on("disconnect",()=>{this.term.write("Websocket failed to connect. Is the server running?\n\r\n\r")}),this.resize.pipe(Object(r.a)(500)).subscribe(e=>{this.io.socket.emit("resize",e)}),this.io.socket.on("stdout",e=>{this.term.write(e)}),this.term.on("resize",e=>{this.resize.next(e)})}onWindowResize(e){this.term.fit()}ngOnDestroy(){window.document.querySelector("body").classList.remove("bg-black"),this.io.end(),this.term.dispose()}}var m=o["\u0275crt"]({encapsulation:2,styles:[],data:{}});function p(e){return o["\u0275vid"](0,[(e()(),o["\u0275eld"](0,0,null,null,1,"div",[["class","flex-column d-flex align-items-stretch h-100"]],null,null,null,null,null)),(e()(),o["\u0275eld"](1,0,null,null,0,"div",[["class","terminal align-self-end w-100 h-100 mb-1"],["id","log-output"]],null,null,null,null,null))],null,null)}function h(e){return o["\u0275vid"](0,[(e()(),o["\u0275eld"](0,0,null,null,1,"app-logs",[],null,[["window","resize"]],function(e,n,t){var l=!0;return"window:resize"===n&&(l=!1!==o["\u0275nov"](e,1).onWindowResize(t)&&l),l},p,m)),o["\u0275did"](1,245760,null,0,d,[a.a],null,null)],function(e,n){e(n,1,0)},null)}var w=o["\u0275ccf"]("app-logs",d,h,{},{},[]),g=t("SVse"),b=t("iInd");class f{}t.d(n,"LogsModuleNgFactory",function(){return v});var v=o["\u0275cmf"](l,[],function(e){return o["\u0275mod"]([o["\u0275mpd"](512,o.ComponentFactoryResolver,o["\u0275CodegenComponentFactoryResolver"],[[8,[s.a,w]],[3,o.ComponentFactoryResolver],o.NgModuleRef]),o["\u0275mpd"](4608,g.NgLocalization,g.NgLocaleLocalization,[o.LOCALE_ID,[2,g["\u0275angular_packages_common_common_a"]]]),o["\u0275mpd"](1073742336,g.CommonModule,g.CommonModule,[]),o["\u0275mpd"](1073742336,b.p,b.p,[[2,b.u],[2,b.l]]),o["\u0275mpd"](1073742336,f,f,[]),o["\u0275mpd"](1073742336,l,l,[]),o["\u0275mpd"](1024,b.j,function(){return[[{path:"",component:d}]]},[])])})}}]);