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.
1 lines
22 KiB
1 lines
22 KiB
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[753],{366:function(e,t,r){"use strict";var n=r(5318),o=r(862);t.Z=void 0;var i=o(r(7294)),a=(0,n(r(2108)).default)(i.createElement("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close");t.Z=a},306:function(e,t,r){"use strict";var n=r(5318),o=r(862);t.Z=void 0;var i=o(r(7294)),a=(0,n(r(2108)).default)(i.createElement("path",{d:"M21 2H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h7v2H8v2h8v-2h-2v-2h7c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 14H3V4h18v12z"}),"DesktopWindows");t.Z=a},4849:function(e,t,r){"use strict";var n=r(5318),o=r(862);t.Z=void 0;var i=o(r(7294)),a=(0,n(r(2108)).default)(i.createElement("path",{d:"M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"}),"Image");t.Z=a},2617:function(e,t,r){"use strict";var n=r(5318),o=r(862);t.Z=void 0;var i=o(r(7294)),a=(0,n(r(2108)).default)(i.createElement("path",{d:"M20 5H4c-1.1 0-1.99.9-1.99 2L2 17c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm-9 3h2v2h-2V8zm0 3h2v2h-2v-2zM8 8h2v2H8V8zm0 3h2v2H8v-2zm-1 2H5v-2h2v2zm0-3H5V8h2v2zm9 7H8v-2h8v2zm0-4h-2v-2h2v2zm0-3h-2V8h2v2zm3 3h-2v-2h2v2zm0-3h-2V8h2v2z"}),"Keyboard");t.Z=a},210:function(e,t,r){"use strict";r.d(t,{Z:function(){return C}});var n=r(5893),o=r(2809),i=r(7294),a=r(5258),s=r(1120),c=r(9956),l=r(282),u=[{text:"Files",image:"/pngs/files_on.png",uri:"/striker?files=true"},{text:"Tasks",image:"/pngs/tasks_no-jobs_icon.png",uri:"/striker?jobs=true"},{text:"Configure",image:"/pngs/configure_icon_on.png",uri:"/striker?configure=true"},{text:"Striker",image:"/pngs/striker_icon_on.png",uri:"/striker?striker=true"},{text:"Anvil",image:"/pngs/anvil_icon_on.png",uri:"/striker?anvil=true"},{text:"Email",image:"/pngs/email_on.png",uri:"/striker?email=true"},{text:"Logout",image:"/pngs/users_icon_on.png",uri:"/striker?logout=true"},{text:"Help",image:"/pngs/help_icon_on.png",uri:"https://alteeve.com/w/Support"}],d={width:"40em",height:"40em"},f=r(9753),p=r(7159),h=r(2822),m=r(998),v=r(5517),b=r(7623),g=r(442),x=r(964);function y(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function j(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?y(Object(r),!0).forEach((function(t){(0,o.Z)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):y(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var w=(0,s.Z)((function(){return(0,b.Z)({list:{width:"200px"},divider:{background:f.d},text:{paddingTop:".5em",paddingLeft:"1.5em"},dashboardButton:{paddingLeft:".1em"},dashboardIcon:{fontSize:"2.3em",color:f.s7}})})),_=function(e){var t=e.open,r=e.setOpen,o=w();return(0,n.jsx)(p.ZP,{BackdropProps:{invisible:!0},anchor:"left",open:t,onClose:function(){return r(!t)},children:(0,n.jsx)("div",{role:"presentation",children:(0,n.jsxs)(h.Z,{className:o.list,children:[(0,n.jsx)(m.Z,{button:!0,children:(0,n.jsx)(x.z,{text:"Admin"})}),(0,n.jsx)(v.Z,{className:o.divider}),(0,n.jsx)(m.Z,{button:!0,component:"a",href:"/index.html",children:(0,n.jsxs)(c.Z,{display:"flex",flexDirection:"row",width:"100%",children:[(0,n.jsx)(c.Z,{className:o.dashboardButton,children:(0,n.jsx)(g.Z,{className:o.dashboardIcon})}),(0,n.jsx)(c.Z,{flexGrow:1,className:o.text,children:(0,n.jsx)(x.A,{text:"Dashboard"})})]})}),u.map((function(e){return(0,n.jsx)(m.Z,{button:!0,component:"a",href:-1!==e.uri.search(/^https?:/)?e.uri:"".concat("/cgi-bin").concat(e.uri),children:(0,n.jsxs)(c.Z,{display:"flex",flexDirection:"row",width:"100%",children:[(0,n.jsx)(c.Z,{children:(0,n.jsx)("img",j({alt:"",src:e.image},d),"icon")}),(0,n.jsx)(c.Z,{flexGrow:1,className:o.text,children:(0,n.jsx)(x.A,{text:e.text})})]})},e.image)}))]})})})};function k(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function O(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?k(Object(r),!0).forEach((function(t){(0,o.Z)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):k(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var Z=(0,s.Z)((function(e){return{appBar:{paddingTop:e.spacing(.5),paddingBottom:e.spacing(.5),paddingLeft:e.spacing(3),paddingRight:e.spacing(3),borderBottom:"solid 1px",borderBottomColor:f.hM},input:{height:"2.8em",width:"30vw",backgroundColor:e.palette.secondary.main,borderRadius:f.n_},barElement:{padding:0},iconBox:(0,o.Z)({},e.breakpoints.down("sm"),{display:"none"}),searchBar:(0,o.Z)({},e.breakpoints.down("sm"),{flexGrow:1,paddingLeft:"15vw"}),icons:{paddingLeft:".1em",paddingRight:".1em"}}})),C=function(){var e=Z(),t=(0,i.useState)(!1),r=t[0],o=t[1];return(0,n.jsxs)(a.Z,{position:"static",className:e.appBar,children:[(0,n.jsxs)(c.Z,{display:"flex",justifyContent:"space-between",flexDirection:"row",children:[(0,n.jsx)(c.Z,{className:e.barElement,children:(0,n.jsx)(l.Z,{onClick:function(){return o(!r)},children:(0,n.jsx)("img",{alt:"",src:"/pngs/logo.png",width:"160",height:"40"})})}),(0,n.jsx)(c.Z,{className:"".concat(e.barElement," ").concat(e.iconBox),children:u.map((function(t){return(0,n.jsx)("a",{href:-1!==t.uri.search(/^https?:/)?t.uri:"".concat("/cgi-bin").concat(t.uri),children:(0,n.jsx)("img",O(O({alt:"",src:t.image},d),{},{className:e.icons}),"icon")},t.uri)}))})]}),(0,n.jsx)(_,{open:r,setOpen:o})]})}},6638:function(e,t,r){"use strict";r.d(t,{Lg:function(){return u},s_:function(){return f},V9:function(){return c}});var n=r(5893),o=r(9956),i=r(1120),a=r(9753),s=(0,i.Z)((function(){return{innerHeader:{position:"relative",padding:"0 .7em"},header:{top:"-.3em",left:"-.3em",padding:"1.4em 0",position:"absolute",content:'""',borderColor:a.d,borderWidth:"1px",borderRadius:a.n_,borderStyle:"solid",width:"100%"}}})),c=function(e){var t=e.children,r=s();return(0,n.jsxs)(o.Z,{className:r.innerHeader,whiteSpace:"pre-wrap",children:[(0,n.jsx)("div",{className:r.header}),t]})},l=(0,i.Z)((function(){return{innerBody:{borderWidth:"1px",borderRadius:a.n_,borderStyle:"solid",borderColor:a.d,marginTop:"1.4em",marginBottom:"1.4em",paddingBottom:0,position:"relative"}}})),u=function(e){var t=e.children,r=l();return(0,n.jsx)(o.Z,{className:r.innerBody,children:t})},d=(0,i.Z)((function(){return{paper:{padding:"2.1em",backgroundColor:a.v9,opacity:.8,zIndex:999},container:{margin:"1em",position:"relative"},square:{content:'""',position:"absolute",width:"2.1em",height:"2.1em",border:"1px",borderColor:a.lD,borderWidth:"1px",borderRadius:a.n_,borderStyle:"solid",padding:0,margin:0},topSquare:{top:"-.3em",left:"-.3em"},bottomSquare:{bottom:"-.3em",right:"-.3em"},"@global":{"*::-webkit-scrollbar":{width:".6em"},"*::-webkit-scrollbar-track":{backgroundColor:a.v9},"*::-webkit-scrollbar-thumb":{backgroundColor:a.lD,outline:"1px solid transparent",borderRadius:a.n_}}}})),f=function(e){var t=e.children,r=d();return(0,n.jsxs)("div",{className:r.container,children:[(0,n.jsx)("div",{className:"".concat(r.square," ").concat(r.topSquare)}),(0,n.jsx)("div",{className:"".concat(r.square," ").concat(r.bottomSquare)}),(0,n.jsx)("div",{className:r.paper,children:t})]})}},8382:function(e,t,r){"use strict";var n=r(5893),o=r(1120),i=r(5477),a=r(9753),s=(0,o.Z)((function(){return{root:{display:"flex",alignItems:"center",justifyContent:"center",marginTop:"3em"},spinner:{color:a.lD,variant:"indeterminate",size:"50em"}}}));t.Z=function(){var e=s();return(0,n.jsx)("div",{className:e.root,children:(0,n.jsx)(i.Z,{className:e.spinner})})}},964:function(e,t,r){"use strict";r.d(t,{A:function(){return d},z:function(){return c}});var n=r(5893),o=r(2318),i=r(4670),a=r(9753),s=(0,i.Z)({root:{color:a.lD}})(o.Z),c=function(e){var t=e.text;return(0,n.jsx)(s,{variant:"h4",children:t})},l=(0,r(1120).Z)((function(){return{selected:{color:a.lD},unselected:{color:a.UZ}}})),u=function(e){var t=e.text,r=e.selected,i=l();return(0,n.jsx)(o.Z,{variant:"subtitle1",className:r?i.selected:i.unselected,children:t})};u.defaultProps={selected:!0};var d=u},9386:function(e,t){"use strict";t.Z=function(e,t){return fetch(e,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})}},8771:function(e,t,r){"use strict";var n=r(1682);function o(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function i(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?o(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):o(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}t.default=function(e,t){var r=a.default,n={loading:function(e){e.error,e.isLoading;return e.pastDelay,null}};e instanceof Promise?n.loader=function(){return e}:"function"===typeof e?n.loader=e:"object"===typeof e&&(n=i(i({},n),e));(n=i(i({},n),t)).loadableGenerated&&delete(n=i(i({},n),n.loadableGenerated)).loadableGenerated;if("boolean"===typeof n.ssr){if(!n.ssr)return delete n.ssr,c(r,n);delete n.ssr}return r(n)};s(r(7294));var a=s(r(4860));function s(e){return e&&e.__esModule?e:{default:e}}function c(e,t){return delete t.webpack,delete t.modules,e(t)}},1083:function(e,t,r){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.LoadableContext=void 0;var o=((n=r(7294))&&n.__esModule?n:{default:n}).default.createContext(null);t.LoadableContext=o},4860:function(e,t,r){"use strict";var n=r(1682),o=r(2553),i=r(2012);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function c(e,t){var r;if("undefined"===typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(!e)return;if("string"===typeof e)return l(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return l(e,t)}(e))||t&&e&&"number"===typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,s=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){s=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw i}}}}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var u,d=(u=r(7294))&&u.__esModule?u:{default:u},f=r(7161),p=r(1083);var h=[],m=[],v=!1;function b(e){var t=e(),r={loading:!0,loaded:null,error:null};return r.promise=t.then((function(e){return r.loading=!1,r.loaded=e,e})).catch((function(e){throw r.loading=!1,r.error=e,e})),r}var g=function(){function e(t,r){o(this,e),this._loadFn=t,this._opts=r,this._callbacks=new Set,this._delay=null,this._timeout=null,this.retry()}return i(e,[{key:"promise",value:function(){return this._res.promise}},{key:"retry",value:function(){var e=this;this._clearTimeouts(),this._res=this._loadFn(this._opts.loader),this._state={pastDelay:!1,timedOut:!1};var t=this._res,r=this._opts;t.loading&&("number"===typeof r.delay&&(0===r.delay?this._state.pastDelay=!0:this._delay=setTimeout((function(){e._update({pastDelay:!0})}),r.delay)),"number"===typeof r.timeout&&(this._timeout=setTimeout((function(){e._update({timedOut:!0})}),r.timeout))),this._res.promise.then((function(){e._update({}),e._clearTimeouts()})).catch((function(t){e._update({}),e._clearTimeouts()})),this._update({})}},{key:"_update",value:function(e){this._state=s(s({},this._state),{},{error:this._res.error,loaded:this._res.loaded,loading:this._res.loading},e),this._callbacks.forEach((function(e){return e()}))}},{key:"_clearTimeouts",value:function(){clearTimeout(this._delay),clearTimeout(this._timeout)}},{key:"getCurrentValue",value:function(){return this._state}},{key:"subscribe",value:function(e){var t=this;return this._callbacks.add(e),function(){t._callbacks.delete(e)}}}]),e}();function x(e){return function(e,t){var r=Object.assign({loader:null,loading:null,delay:200,timeout:null,webpack:null,modules:null},t),n=null;function o(){if(!n){var t=new g(e,r);n={getCurrentValue:t.getCurrentValue.bind(t),subscribe:t.subscribe.bind(t),retry:t.retry.bind(t),promise:t.promise.bind(t)}}return n.promise()}if(!v&&"function"===typeof r.webpack){var i=r.webpack();m.push((function(e){var t,r=c(i);try{for(r.s();!(t=r.n()).done;){var n=t.value;if(-1!==e.indexOf(n))return o()}}catch(a){r.e(a)}finally{r.f()}}))}var a=function(e,t){o();var i=d.default.useContext(p.LoadableContext),a=f.useSubscription(n);return d.default.useImperativeHandle(t,(function(){return{retry:n.retry}}),[]),i&&Array.isArray(r.modules)&&r.modules.forEach((function(e){i(e)})),d.default.useMemo((function(){return a.loading||a.error?d.default.createElement(r.loading,{isLoading:a.loading,pastDelay:a.pastDelay,timedOut:a.timedOut,error:a.error,retry:n.retry}):a.loaded?d.default.createElement(function(e){return e&&e.__esModule?e.default:e}(a.loaded),e):null}),[e,a])};return a.preload=function(){return o()},a.displayName="LoadableComponent",d.default.forwardRef(a)}(b,e)}function y(e,t){for(var r=[];e.length;){var n=e.pop();r.push(n(t))}return Promise.all(r).then((function(){if(e.length)return y(e,t)}))}x.preloadAll=function(){return new Promise((function(e,t){y(h).then(e,t)}))},x.preloadReady=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return new Promise((function(t){var r=function(){return v=!0,t()};y(m,e).then(r,r)}))},window.__NEXT_PRELOADREADY=x.preloadReady;var j=x;t.default=j},8379:function(e,t,r){"use strict";r.r(t),r.d(t,{default:function(){return V}});var n=r(5893),o=r(2809),i=r(7294),a=r(1163),s=r(9008),c=r(9956),l=r(1120),u=r(809),d=r.n(u);function f(e,t,r,n,o,i,a){try{var s=e[i](a),c=s.value}catch(l){return void r(l)}s.done?t(c):Promise.resolve(c).then(n,o)}function p(e){return function(){var t=this,r=arguments;return new Promise((function(n,o){var i=e.apply(t,r);function a(e){f(i,n,o,a,s,"next",e)}function s(e){f(i,n,o,a,s,"throw",e)}a(void 0)}))}}var h=r(5152),m=r(5675),v=r(5639),b=r(2318),g=r(282),x=r(366),y=r(2617),j=r(7812),w=r(6638),_=r(9753),k="0xffe3",O="0xffe9",Z=[{keys:"Ctrl + Alt + Delete",scans:[]},{keys:"Ctrl + Alt + F1",scans:[k,O,"0xffbe"]},{keys:"Ctrl + Alt + F2",scans:[k,O,"0xffbf"]},{keys:"Ctrl + Alt + F3",scans:[k,O,"0xffc0"]},{keys:"Ctrl + Alt + F4",scans:[k,O,"0xffc1"]},{keys:"Ctrl + Alt + F5",scans:[k,O,"0xffc2"]},{keys:"Ctrl + Alt + F6",scans:[k,O,"0xffc3"]},{keys:"Ctrl + Alt + F7",scans:[k,O,"0xffc4"]},{keys:"Ctrl + Alt + F8",scans:[k,O,"0xffc5"]},{keys:"Ctrl + Alt + F9",scans:[k,O,"0xffc6"]}],C=r(9386),D=function(){var e=p(d().mark((function e(t,r,n){var o,i,a;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=new AbortController,i=setTimeout((function(){return o.abort()}),n),e.next=4,fetch(t,{method:"PUT",headers:{"Content-Type":"application/json","Keep-Alive":"timeout=120"},signal:o.signal,body:JSON.stringify(r)});case 4:return a=e.sent,clearTimeout(i),e.abrupt("return",a);case 7:case"end":return e.stop()}}),e)})));return function(t,r,n){return e.apply(this,arguments)}}(),P=r(964),N=r(8382),S=(0,h.default)((function(){return Promise.all([r.e(204),r.e(97)]).then(r.bind(r,7097))}),{ssr:!1,loadableGenerated:{webpack:function(){return[7097]},modules:["../components/Display/FullSize.tsx -> ./VncDisplay"]}}),B=(0,l.Z)((function(){return{displayBox:{width:"75vw",height:"75vh",paddingTop:"1em",paddingBottom:0,paddingLeft:0,paddingRight:0},spinnerBox:{flexDirection:"column",width:"75vw",height:"75vh",alignItems:"center",justifyContent:"center"},closeButton:{borderRadius:8,backgroundColor:_.hM,"&:hover":{backgroundColor:_.hM}},keyboardButton:{borderRadius:8,backgroundColor:_.lD,"&:hover":{backgroundColor:_.lD}},closeBox:{paddingBottom:"1em",paddingLeft:".7em",paddingRight:0},buttonsBox:{paddingTop:0},keysItem:{backgroundColor:_.lD,paddingRight:"3em","&:hover":{backgroundColor:_.lD}},buttonText:{color:_.E5}}})),E=function(e){var t=e.setMode,r=e.uuid,o=e.serverName,a=(0,i.useState)(null),s=a[0],l=a[1],u=(0,i.useRef)(),f=(0,i.useRef)(void 0),h=(0,i.useState)(void 0),k=h[0],O=h[1],E=(0,i.useState)(!1),T=E[0],z=E[1],A=B();(0,i.useEffect)((function(){f.current=window.location.hostname,k||p(d().mark((function e(){var t;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,D("".concat("/cgi-bin","/manage_vnc_pipes"),{server_uuid:r,is_open:!0},12e4);case 3:return t=e.sent,e.t0=O,e.next=7,t.json();case 7:e.t1=e.sent,(0,e.t0)(e.t1),e.next=14;break;case 11:e.prev=11,e.t2=e.catch(0),z(!0);case 14:case"end":return e.stop()}}),e,null,[[0,11]])})))()}),[r,k,T]);var R=function(){var e=p(d().mark((function e(){return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,C.Z)("".concat("/cgi-bin","/manage_vnc_pipes"),{server_uuid:r,is_open:!1});case 2:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return(0,n.jsxs)(w.s_,{children:[(0,n.jsx)(c.Z,{flexGrow:1,children:(0,n.jsx)(P.z,{text:"Server: ".concat(o)})}),k?(0,n.jsxs)(c.Z,{display:"flex",className:A.displayBox,children:[(0,n.jsx)(S,{rfb:u,url:"".concat(k.protocol,"://").concat(f.current,":").concat(k.forward_port),viewOnly:!1,focusOnClick:!1,clipViewport:!1,dragViewport:!1,scaleViewport:!0,resizeSession:!0,showDotCursor:!1,background:"",qualityLevel:6,compressionLevel:2}),(0,n.jsxs)(c.Z,{children:[(0,n.jsx)(c.Z,{className:A.closeBox,children:(0,n.jsx)(j.Z,{className:A.closeButton,style:{color:_.lD},component:"span",onClick:function(){R(),t(!0)},children:(0,n.jsx)(x.Z,{})})}),(0,n.jsxs)(c.Z,{className:A.closeBox,children:[(0,n.jsx)(j.Z,{className:A.keyboardButton,style:{color:_.E5},component:"span",onClick:function(e){l(e.currentTarget)},children:(0,n.jsx)(y.Z,{})}),(0,n.jsx)(m.Z,{anchorEl:s,keepMounted:!0,open:Boolean(s),onClose:function(){return l(null)},children:Z.map((function(e){var t=e.keys,r=e.scans;return(0,n.jsx)(v.Z,{onClick:function(){return function(e){if(u.current){if(e.length){for(var t=0;t<=e.length-1;t+=1)u.current.sendKey(e[t],1);for(var r=e.length-1;r>=0;r-=1)u.current.sendKey(e[r],0)}else u.current.sendCtrlAltDel();l(null)}}(r)},className:A.keysItem,children:(0,n.jsx)(b.Z,{variant:"subtitle1",children:t})},t)}))})]})]})]}):(0,n.jsx)(c.Z,{display:"flex",className:A.spinnerBox,children:T?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(c.Z,{style:{paddingBottom:"2em"},children:(0,n.jsx)(P.z,{text:"There was a problem connecting to the server, please try again"})}),(0,n.jsx)(g.Z,{variant:"contained",onClick:function(){z(!1)},style:{textTransform:"none"},children:(0,n.jsx)(b.Z,{className:A.buttonText,variant:"subtitle1",children:"Reconnect"})})]}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(P.z,{text:"Establishing connection with ".concat(o)}),(0,n.jsx)(P.z,{text:"This may take a few minutes"}),(0,n.jsx)(N.Z,{})]})})]})},T=r(306),z=r(4849),A=(0,l.Z)((function(){return{displayBox:{padding:0,paddingTop:".7em",width:"100%"},fullScreenButton:{borderRadius:8,backgroundColor:_.lD,"&:hover":{backgroundColor:_.lD}},fullScreenBox:{paddingLeft:"1em",padding:0},imageButton:{padding:0,color:_.lD},imageIcon:{borderRadius:8,padding:0,backgroundColor:_.s7,fontSize:"8em"}}})),R=function(e){var t=e.setMode,r=e.serverName,o=A();return(0,n.jsxs)(w.s_,{children:[(0,n.jsx)(c.Z,{flexGrow:1,children:(0,n.jsx)(P.z,{text:"Server: ".concat(r)})}),(0,n.jsxs)(c.Z,{display:"flex",className:o.displayBox,children:[(0,n.jsx)(c.Z,{children:(0,n.jsx)(j.Z,{className:o.imageButton,style:{color:_.E5},component:"span",onClick:function(){return t(!1)},children:(0,n.jsx)(z.Z,{className:o.imageIcon})})}),(0,n.jsx)(c.Z,{className:o.fullScreenBox,children:(0,n.jsx)(j.Z,{className:o.fullScreenButton,style:{color:_.E5},component:"span",onClick:function(){return t(!1)},children:(0,n.jsx)(T.Z,{})})})]})]})},L=r(210),M=(0,l.Z)((function(e){return{preview:(0,o.Z)({width:"25%",height:"100%"},e.breakpoints.down("md"),{width:"100%"}),fullView:{display:"flex",flexDirection:"row",width:"100%",justifyContent:"center"}}})),V=function(){var e=(0,i.useState)(!0),t=e[0],r=e[1],o=M(),l=(0,a.useRouter)().query,u=l.uuid,d=l.server_name;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(s.default,{children:(0,n.jsx)("title",{children:d})}),(0,n.jsx)(L.Z,{}),"string"===typeof u&&(t?(0,n.jsx)(c.Z,{className:o.preview,children:(0,n.jsx)(R,{setMode:r,serverName:d})}):(0,n.jsx)(c.Z,{className:o.fullView,children:(0,n.jsx)(E,{setMode:r,uuid:u,serverName:d})}))]})}},8954:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/server",function(){return r(8379)}])},5152:function(e,t,r){e.exports=r(8771)},1163:function(e,t,r){e.exports=r(4651)}},function(e){e.O(0,[774,322,888,179],(function(){return t=8954,e(e.s=t);var t}));var t=e.O();_N_E=t}]); |