G?KB^+WGdHNX1=1}e7FeEW=nmh*Uy
z3C3p(^na!tD)Y;7WPa8_%K?LyR~a;d^=l>Wx*%BpP_q^SVGx2U!*Ccvf*=?Uhi*SJ
zP=!w>8E1@5CKJv1Mm`5O6E&l#opI}n75;4%+zzJp*c2@-;{5PkxJVI}q$
zsegjcZU}$hLl@q`zDpsB;O_F6J9w!An3)ITTmb7nQUz`ZhR_9p>w+eI1xW?Z=HKyG
zuA-F!@fjpYP7u(WLeda&6fgz?Zh(z1nSdhciV{Ldz7hm$qK=Pax+^4YG@AD(U~D#{
zUkjlyU(R8=*&NXA6@nDLrU8m$M2kuLjem`>x(qWT*$Odyb95$Qh`uxuao94tcw|}uI
zF8aMGF8aMGF8aL*uJ(IFT=aWGT=aWGT=aWWT=aWGT=aW0yw~dudV|yb-m+R?BKxG9M9%f9P~NPREhCgXAm*gTZ33Q2PCV2)-PRM$6Gs
z<}DiwzV$qB>uqJ;acls(e&5DK$6?_(NXH$o3qaTJ7m1czm}t4T#Q?PZUeA|_o^LtO
z_xt)>-|y>leZQ~I_5I!eFZKKST;K2ObA7+B&-MMjKG*mA8eH4&_5A<*eef4nf-A`&
SB}|$C0000 {
+ const { act, data } = useBackend(context);
+ const { icon_state, direction, isSelected, onSelect } = props;
+
+ return (
+
+ );
+};
+
+const Dir = {
+ NORTH: 1,
+ SOUTH: 2,
+ EAST: 4,
+ WEST: 8,
+};
+
+export const DecalPainter = (props, context) => {
+ const { act, data } = useBackend(context);
+ const { availableStyles, selectedStyle, selectedDir, removalMode } = data;
+ return (
+
+
+
+
+
+ act('cycle_style', { offset: -1 })} />
+
+
+ act('select_style', { style: val })}
+ />
+
+
+ act('cycle_style', { offset: 1 })} />
+
+
+ act('removal_mode')}>
+ Remove decals
+
+
+
+
+
+
+ {availableStyles.map((style) => (
+
+ act('select_style', { style: style })}
+ />
+
+ ))}
+
+
+
+
+
+
+ {[Dir.NORTH, null, Dir.SOUTH].map((latitude) => (
+
+ {[latitude + Dir.WEST, latitude, latitude + Dir.EAST].map((dir) => (
+
+ {dir === null ? (
+
+ ) : (
+ act('select_direction', { direction: dir })}
+ />
+ )}
+
+ ))}
+
+ ))}
+
+
+
+
+
+
+ );
+};
diff --git a/tgui/public/tgui.bundle.js b/tgui/public/tgui.bundle.js
index cba836a24129..38ba624fa7dd 100644
--- a/tgui/public/tgui.bundle.js
+++ b/tgui/public/tgui.bundle.js
@@ -1,12 +1,12 @@
-(function(){(function(){var Jt={96376:function(T,r,n){"use strict";r.__esModule=!0,r.createPopper=void 0,r.popperGenerator=m;var e=h(n(74758)),a=h(n(28811)),t=h(n(98309)),o=h(n(44896)),p=h(n(33118)),b=h(n(10579)),y=h(n(56500)),S=h(n(17633));r.detectOverflow=S.default;var k=n(75573);function h(u){return u&&u.__esModule?u:{default:u}}var i={placement:"bottom",modifiers:[],strategy:"absolute"};function c(){for(var u=arguments.length,s=new Array(u),d=0;d0&&(0,a.round)(h.width)/y.offsetWidth||1,c=y.offsetHeight>0&&(0,a.round)(h.height)/y.offsetHeight||1);var m=(0,e.isElement)(y)?(0,t.default)(y):window,l=m.visualViewport,u=!(0,o.default)()&&k,s=(h.left+(u&&l?l.offsetLeft:0))/i,d=(h.top+(u&&l?l.offsetTop:0))/c,v=h.width/i,g=h.height/c;return{width:v,height:g,top:d,right:s+v,bottom:d+g,left:s,x:s,y:d}}},49035:function(T,r,n){"use strict";r.__esModule=!0,r.default=g;var e=n(46206),a=u(n(87991)),t=u(n(79752)),o=u(n(98309)),p=u(n(44896)),b=u(n(40600)),y=u(n(16599)),S=n(75573),k=u(n(37786)),h=u(n(57819)),i=u(n(4206)),c=u(n(12972)),m=u(n(81666)),l=n(63618);function u(C){return C&&C.__esModule?C:{default:C}}function s(C,f){var N=(0,k.default)(C,!1,f==="fixed");return N.top=N.top+C.clientTop,N.left=N.left+C.clientLeft,N.bottom=N.top+C.clientHeight,N.right=N.left+C.clientWidth,N.width=C.clientWidth,N.height=C.clientHeight,N.x=N.left,N.y=N.top,N}function d(C,f,N){return f===e.viewport?(0,m.default)((0,a.default)(C,N)):(0,S.isElement)(f)?s(f,N):(0,m.default)((0,t.default)((0,b.default)(C)))}function v(C){var f=(0,o.default)((0,h.default)(C)),N=["absolute","fixed"].indexOf((0,y.default)(C).position)>=0,V=N&&(0,S.isHTMLElement)(C)?(0,p.default)(C):C;return(0,S.isElement)(V)?f.filter(function(B){return(0,S.isElement)(B)&&(0,i.default)(B,V)&&(0,c.default)(B)!=="body"}):[]}function g(C,f,N,V){var B=f==="clippingParents"?v(C):[].concat(f),I=[].concat(B,[N]),L=I[0],w=I.reduce(function(A,x){var E=d(C,x,V);return A.top=(0,l.max)(E.top,A.top),A.right=(0,l.min)(E.right,A.right),A.bottom=(0,l.min)(E.bottom,A.bottom),A.left=(0,l.max)(E.left,A.left),A},d(C,L,V));return w.width=w.right-w.left,w.height=w.bottom-w.top,w.x=w.left,w.y=w.top,w}},74758:function(T,r,n){"use strict";r.__esModule=!0,r.default=i;var e=k(n(37786)),a=k(n(13390)),t=k(n(12972)),o=n(75573),p=k(n(79697)),b=k(n(40600)),y=k(n(10798)),S=n(63618);function k(c){return c&&c.__esModule?c:{default:c}}function h(c){var m=c.getBoundingClientRect(),l=(0,S.round)(m.width)/c.offsetWidth||1,u=(0,S.round)(m.height)/c.offsetHeight||1;return l!==1||u!==1}function i(c,m,l){l===void 0&&(l=!1);var u=(0,o.isHTMLElement)(m),s=(0,o.isHTMLElement)(m)&&h(m),d=(0,b.default)(m),v=(0,e.default)(c,s,l),g={scrollLeft:0,scrollTop:0},C={x:0,y:0};return(u||!u&&!l)&&(((0,t.default)(m)!=="body"||(0,y.default)(d))&&(g=(0,a.default)(m)),(0,o.isHTMLElement)(m)?(C=(0,e.default)(m,!0),C.x+=m.clientLeft,C.y+=m.clientTop):d&&(C.x=(0,p.default)(d))),{x:v.left+g.scrollLeft-C.x,y:v.top+g.scrollTop-C.y,width:v.width,height:v.height}}},16599:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(95115));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){return(0,e.default)(o).getComputedStyle(o)}},40600:function(T,r,n){"use strict";r.__esModule=!0,r.default=a;var e=n(75573);function a(t){return(((0,e.isElement)(t)?t.ownerDocument:t.document)||window.document).documentElement}},79752:function(T,r,n){"use strict";r.__esModule=!0,r.default=y;var e=b(n(40600)),a=b(n(16599)),t=b(n(79697)),o=b(n(43750)),p=n(63618);function b(S){return S&&S.__esModule?S:{default:S}}function y(S){var k,h=(0,e.default)(S),i=(0,o.default)(S),c=(k=S.ownerDocument)==null?void 0:k.body,m=(0,p.max)(h.scrollWidth,h.clientWidth,c?c.scrollWidth:0,c?c.clientWidth:0),l=(0,p.max)(h.scrollHeight,h.clientHeight,c?c.scrollHeight:0,c?c.clientHeight:0),u=-i.scrollLeft+(0,t.default)(S),s=-i.scrollTop;return(0,a.default)(c||h).direction==="rtl"&&(u+=(0,p.max)(h.clientWidth,c?c.clientWidth:0)-m),{width:m,height:l,x:u,y:s}}},3073:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}},28811:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(37786));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){var p=(0,e.default)(o),b=o.offsetWidth,y=o.offsetHeight;return Math.abs(p.width-b)<=1&&(b=p.width),Math.abs(p.height-y)<=1&&(y=p.height),{x:o.offsetLeft,y:o.offsetTop,width:b,height:y}}},12972:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return e?(e.nodeName||"").toLowerCase():null}},13390:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(43750)),a=p(n(95115)),t=n(75573),o=p(n(3073));function p(y){return y&&y.__esModule?y:{default:y}}function b(y){return y===(0,a.default)(y)||!(0,t.isHTMLElement)(y)?(0,e.default)(y):(0,o.default)(y)}},44896:function(T,r,n){"use strict";r.__esModule=!0,r.default=i;var e=S(n(95115)),a=S(n(12972)),t=S(n(16599)),o=n(75573),p=S(n(87031)),b=S(n(57819)),y=S(n(35366));function S(c){return c&&c.__esModule?c:{default:c}}function k(c){return!(0,o.isHTMLElement)(c)||(0,t.default)(c).position==="fixed"?null:c.offsetParent}function h(c){var m=/firefox/i.test((0,y.default)()),l=/Trident/i.test((0,y.default)());if(l&&(0,o.isHTMLElement)(c)){var u=(0,t.default)(c);if(u.position==="fixed")return null}var s=(0,b.default)(c);for((0,o.isShadowRoot)(s)&&(s=s.host);(0,o.isHTMLElement)(s)&&["html","body"].indexOf((0,a.default)(s))<0;){var d=(0,t.default)(s);if(d.transform!=="none"||d.perspective!=="none"||d.contain==="paint"||["transform","perspective"].indexOf(d.willChange)!==-1||m&&d.willChange==="filter"||m&&d.filter&&d.filter!=="none")return s;s=s.parentNode}return null}function i(c){for(var m=(0,e.default)(c),l=k(c);l&&(0,p.default)(l)&&(0,t.default)(l).position==="static";)l=k(l);return l&&((0,a.default)(l)==="html"||(0,a.default)(l)==="body"&&(0,t.default)(l).position==="static")?m:l||h(c)||m}},57819:function(T,r,n){"use strict";r.__esModule=!0,r.default=p;var e=o(n(12972)),a=o(n(40600)),t=n(75573);function o(b){return b&&b.__esModule?b:{default:b}}function p(b){return(0,e.default)(b)==="html"?b:b.assignedSlot||b.parentNode||((0,t.isShadowRoot)(b)?b.host:null)||(0,a.default)(b)}},24426:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(57819)),a=p(n(10798)),t=p(n(12972)),o=n(75573);function p(y){return y&&y.__esModule?y:{default:y}}function b(y){return["html","body","#document"].indexOf((0,t.default)(y))>=0?y.ownerDocument.body:(0,o.isHTMLElement)(y)&&(0,a.default)(y)?y:b((0,e.default)(y))}},87991:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(95115)),a=p(n(40600)),t=p(n(79697)),o=p(n(89331));function p(y){return y&&y.__esModule?y:{default:y}}function b(y,S){var k=(0,e.default)(y),h=(0,a.default)(y),i=k.visualViewport,c=h.clientWidth,m=h.clientHeight,l=0,u=0;if(i){c=i.width,m=i.height;var s=(0,o.default)();(s||!s&&S==="fixed")&&(l=i.offsetLeft,u=i.offsetTop)}return{width:c,height:m,x:l+(0,t.default)(y),y:u}}},95115:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var a=e.ownerDocument;return a&&a.defaultView||window}return e}},43750:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(95115));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){var p=(0,e.default)(o),b=p.pageXOffset,y=p.pageYOffset;return{scrollLeft:b,scrollTop:y}}},79697:function(T,r,n){"use strict";r.__esModule=!0,r.default=p;var e=o(n(37786)),a=o(n(40600)),t=o(n(43750));function o(b){return b&&b.__esModule?b:{default:b}}function p(b){return(0,e.default)((0,a.default)(b)).left+(0,t.default)(b).scrollLeft}},75573:function(T,r,n){"use strict";r.__esModule=!0,r.isElement=t,r.isHTMLElement=o,r.isShadowRoot=p;var e=a(n(95115));function a(b){return b&&b.__esModule?b:{default:b}}function t(b){var y=(0,e.default)(b).Element;return b instanceof y||b instanceof Element}function o(b){var y=(0,e.default)(b).HTMLElement;return b instanceof y||b instanceof HTMLElement}function p(b){if(typeof ShadowRoot=="undefined")return!1;var y=(0,e.default)(b).ShadowRoot;return b instanceof y||b instanceof ShadowRoot}},89331:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(35366));function a(o){return o&&o.__esModule?o:{default:o}}function t(){return!/^((?!chrome|android).)*safari/i.test((0,e.default)())}},10798:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(16599));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){var p=(0,e.default)(o),b=p.overflow,y=p.overflowX,S=p.overflowY;return/auto|scroll|overlay|hidden/.test(b+S+y)}},87031:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(12972));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){return["table","td","th"].indexOf((0,e.default)(o))>=0}},98309:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(24426)),a=p(n(57819)),t=p(n(95115)),o=p(n(10798));function p(y){return y&&y.__esModule?y:{default:y}}function b(y,S){var k;S===void 0&&(S=[]);var h=(0,e.default)(y),i=h===((k=y.ownerDocument)==null?void 0:k.body),c=(0,t.default)(h),m=i?[c].concat(c.visualViewport||[],(0,o.default)(h)?h:[]):h,l=S.concat(m);return i?l:l.concat(b((0,a.default)(m)))}},46206:function(T,r){"use strict";r.__esModule=!0,r.write=r.viewport=r.variationPlacements=r.top=r.start=r.right=r.reference=r.read=r.popper=r.placements=r.modifierPhases=r.main=r.left=r.end=r.clippingParents=r.bottom=r.beforeWrite=r.beforeRead=r.beforeMain=r.basePlacements=r.auto=r.afterWrite=r.afterRead=r.afterMain=void 0;var n=r.top="top",e=r.bottom="bottom",a=r.right="right",t=r.left="left",o=r.auto="auto",p=r.basePlacements=[n,e,a,t],b=r.start="start",y=r.end="end",S=r.clippingParents="clippingParents",k=r.viewport="viewport",h=r.popper="popper",i=r.reference="reference",c=r.variationPlacements=p.reduce(function(B,I){return B.concat([I+"-"+b,I+"-"+y])},[]),m=r.placements=[].concat(p,[o]).reduce(function(B,I){return B.concat([I,I+"-"+b,I+"-"+y])},[]),l=r.beforeRead="beforeRead",u=r.read="read",s=r.afterRead="afterRead",d=r.beforeMain="beforeMain",v=r.main="main",g=r.afterMain="afterMain",C=r.beforeWrite="beforeWrite",f=r.write="write",N=r.afterWrite="afterWrite",V=r.modifierPhases=[l,u,s,d,v,g,C,f,N]},95996:function(T,r,n){"use strict";r.__esModule=!0;var e={popperGenerator:!0,detectOverflow:!0,createPopperBase:!0,createPopper:!0,createPopperLite:!0};r.popperGenerator=r.detectOverflow=r.createPopperLite=r.createPopperBase=r.createPopper=void 0;var a=n(46206);Object.keys(a).forEach(function(y){y==="default"||y==="__esModule"||Object.prototype.hasOwnProperty.call(e,y)||y in r&&r[y]===a[y]||(r[y]=a[y])});var t=n(39805);Object.keys(t).forEach(function(y){y==="default"||y==="__esModule"||Object.prototype.hasOwnProperty.call(e,y)||y in r&&r[y]===t[y]||(r[y]=t[y])});var o=n(96376);r.popperGenerator=o.popperGenerator,r.detectOverflow=o.detectOverflow,r.createPopperBase=o.createPopper;var p=n(83312);r.createPopper=p.createPopper;var b=n(2473);r.createPopperLite=b.createPopper},19975:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=t(n(12972)),a=n(75573);function t(y){return y&&y.__esModule?y:{default:y}}function o(y){var S=y.state;Object.keys(S.elements).forEach(function(k){var h=S.styles[k]||{},i=S.attributes[k]||{},c=S.elements[k];!(0,a.isHTMLElement)(c)||!(0,e.default)(c)||(Object.assign(c.style,h),Object.keys(i).forEach(function(m){var l=i[m];l===!1?c.removeAttribute(m):c.setAttribute(m,l===!0?"":l)}))})}function p(y){var S=y.state,k={popper:{position:S.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(S.elements.popper.style,k.popper),S.styles=k,S.elements.arrow&&Object.assign(S.elements.arrow.style,k.arrow),function(){Object.keys(S.elements).forEach(function(h){var i=S.elements[h],c=S.attributes[h]||{},m=Object.keys(S.styles.hasOwnProperty(h)?S.styles[h]:k[h]),l=m.reduce(function(u,s){return u[s]="",u},{});!(0,a.isHTMLElement)(i)||!(0,e.default)(i)||(Object.assign(i.style,l),Object.keys(c).forEach(function(u){i.removeAttribute(u)}))})}}var b=r.default={name:"applyStyles",enabled:!0,phase:"write",fn:o,effect:p,requires:["computeStyles"]}},52744:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=h(n(83104)),a=h(n(28811)),t=h(n(4206)),o=h(n(44896)),p=h(n(41199)),b=n(28595),y=h(n(43286)),S=h(n(81447)),k=n(46206);function h(u){return u&&u.__esModule?u:{default:u}}var i=function(){function u(s,d){return s=typeof s=="function"?s(Object.assign({},d.rects,{placement:d.placement})):s,(0,y.default)(typeof s!="number"?s:(0,S.default)(s,k.basePlacements))}return u}();function c(u){var s,d=u.state,v=u.name,g=u.options,C=d.elements.arrow,f=d.modifiersData.popperOffsets,N=(0,e.default)(d.placement),V=(0,p.default)(N),B=[k.left,k.right].indexOf(N)>=0,I=B?"height":"width";if(!(!C||!f)){var L=i(g.padding,d),w=(0,a.default)(C),A=V==="y"?k.top:k.left,x=V==="y"?k.bottom:k.right,E=d.rects.reference[I]+d.rects.reference[V]-f[V]-d.rects.popper[I],P=f[V]-d.rects.reference[V],D=(0,o.default)(C),M=D?V==="y"?D.clientHeight||0:D.clientWidth||0:0,O=E/2-P/2,R=L[A],F=M-w[I]-L[x],W=M/2-w[I]/2+O,U=(0,b.within)(R,W,F),z=V;d.modifiersData[v]=(s={},s[z]=U,s.centerOffset=U-W,s)}}function m(u){var s=u.state,d=u.options,v=d.element,g=v===void 0?"[data-popper-arrow]":v;g!=null&&(typeof g=="string"&&(g=s.elements.popper.querySelector(g),!g)||(0,t.default)(s.elements.popper,g)&&(s.elements.arrow=g))}var l=r.default={name:"arrow",enabled:!0,phase:"main",fn:c,effect:m,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]}},59894:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0,r.mapToStyles=c;var e=n(46206),a=k(n(44896)),t=k(n(95115)),o=k(n(40600)),p=k(n(16599)),b=k(n(83104)),y=k(n(45)),S=n(63618);function k(u){return u&&u.__esModule?u:{default:u}}var h={top:"auto",right:"auto",bottom:"auto",left:"auto"};function i(u,s){var d=u.x,v=u.y,g=s.devicePixelRatio||1;return{x:(0,S.round)(d*g)/g||0,y:(0,S.round)(v*g)/g||0}}function c(u){var s,d=u.popper,v=u.popperRect,g=u.placement,C=u.variation,f=u.offsets,N=u.position,V=u.gpuAcceleration,B=u.adaptive,I=u.roundOffsets,L=u.isFixed,w=f.x,A=w===void 0?0:w,x=f.y,E=x===void 0?0:x,P=typeof I=="function"?I({x:A,y:E}):{x:A,y:E};A=P.x,E=P.y;var D=f.hasOwnProperty("x"),M=f.hasOwnProperty("y"),O=e.left,R=e.top,F=window;if(B){var W=(0,a.default)(d),U="clientHeight",z="clientWidth";if(W===(0,t.default)(d)&&(W=(0,o.default)(d),(0,p.default)(W).position!=="static"&&N==="absolute"&&(U="scrollHeight",z="scrollWidth")),W=W,g===e.top||(g===e.left||g===e.right)&&C===e.end){R=e.bottom;var $=L&&W===F&&F.visualViewport?F.visualViewport.height:W[U];E-=$-v.height,E*=V?1:-1}if(g===e.left||(g===e.top||g===e.bottom)&&C===e.end){O=e.right;var G=L&&W===F&&F.visualViewport?F.visualViewport.width:W[z];A-=G-v.width,A*=V?1:-1}}var X=Object.assign({position:N},B&&h),J=I===!0?i({x:A,y:E},(0,t.default)(d)):{x:A,y:E};if(A=J.x,E=J.y,V){var se;return Object.assign({},X,(se={},se[R]=M?"0":"",se[O]=D?"0":"",se.transform=(F.devicePixelRatio||1)<=1?"translate("+A+"px, "+E+"px)":"translate3d("+A+"px, "+E+"px, 0)",se))}return Object.assign({},X,(s={},s[R]=M?E+"px":"",s[O]=D?A+"px":"",s.transform="",s))}function m(u){var s=u.state,d=u.options,v=d.gpuAcceleration,g=v===void 0?!0:v,C=d.adaptive,f=C===void 0?!0:C,N=d.roundOffsets,V=N===void 0?!0:N,B={placement:(0,b.default)(s.placement),variation:(0,y.default)(s.placement),popper:s.elements.popper,popperRect:s.rects.popper,gpuAcceleration:g,isFixed:s.options.strategy==="fixed"};s.modifiersData.popperOffsets!=null&&(s.styles.popper=Object.assign({},s.styles.popper,c(Object.assign({},B,{offsets:s.modifiersData.popperOffsets,position:s.options.strategy,adaptive:f,roundOffsets:V})))),s.modifiersData.arrow!=null&&(s.styles.arrow=Object.assign({},s.styles.arrow,c(Object.assign({},B,{offsets:s.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:V})))),s.attributes.popper=Object.assign({},s.attributes.popper,{"data-popper-placement":s.placement})}var l=r.default={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:m,data:{}}},36692:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=a(n(95115));function a(b){return b&&b.__esModule?b:{default:b}}var t={passive:!0};function o(b){var y=b.state,S=b.instance,k=b.options,h=k.scroll,i=h===void 0?!0:h,c=k.resize,m=c===void 0?!0:c,l=(0,e.default)(y.elements.popper),u=[].concat(y.scrollParents.reference,y.scrollParents.popper);return i&&u.forEach(function(s){s.addEventListener("scroll",S.update,t)}),m&&l.addEventListener("resize",S.update,t),function(){i&&u.forEach(function(s){s.removeEventListener("scroll",S.update,t)}),m&&l.removeEventListener("resize",S.update,t)}}var p=r.default={name:"eventListeners",enabled:!0,phase:"write",fn:function(){function b(){}return b}(),effect:o,data:{}}},23798:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=S(n(71376)),a=S(n(83104)),t=S(n(86459)),o=S(n(17633)),p=S(n(9041)),b=n(46206),y=S(n(45));function S(c){return c&&c.__esModule?c:{default:c}}function k(c){if((0,a.default)(c)===b.auto)return[];var m=(0,e.default)(c);return[(0,t.default)(c),m,(0,t.default)(m)]}function h(c){var m=c.state,l=c.options,u=c.name;if(!m.modifiersData[u]._skip){for(var s=l.mainAxis,d=s===void 0?!0:s,v=l.altAxis,g=v===void 0?!0:v,C=l.fallbackPlacements,f=l.padding,N=l.boundary,V=l.rootBoundary,B=l.altBoundary,I=l.flipVariations,L=I===void 0?!0:I,w=l.allowedAutoPlacements,A=m.options.placement,x=(0,a.default)(A),E=x===A,P=C||(E||!L?[(0,e.default)(A)]:k(A)),D=[A].concat(P).reduce(function(ne,te){return ne.concat((0,a.default)(te)===b.auto?(0,p.default)(m,{placement:te,boundary:N,rootBoundary:V,padding:f,flipVariations:L,allowedAutoPlacements:w}):te)},[]),M=m.rects.reference,O=m.rects.popper,R=new Map,F=!0,W=D[0],U=0;U=0,J=X?"width":"height",se=(0,o.default)(m,{placement:z,boundary:N,rootBoundary:V,altBoundary:B,padding:f}),ie=X?G?b.right:b.left:G?b.bottom:b.top;M[J]>O[J]&&(ie=(0,e.default)(ie));var me=(0,e.default)(ie),q=[];if(d&&q.push(se[$]<=0),g&&q.push(se[ie]<=0,se[me]<=0),q.every(function(ne){return ne})){W=z,F=!1;break}R.set(z,q)}if(F)for(var re=L?3:1,ae=function(){function ne(te){var fe=D.find(function(pe){var ce=R.get(pe);if(ce)return ce.slice(0,te).every(function(Ve){return Ve})});if(fe)return W=fe,"break"}return ne}(),le=re;le>0;le--){var Z=ae(le);if(Z==="break")break}m.placement!==W&&(m.modifiersData[u]._skip=!0,m.placement=W,m.reset=!0)}}var i=r.default={name:"flip",enabled:!0,phase:"main",fn:h,requiresIfExists:["offset"],data:{_skip:!1}}},83761:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=n(46206),a=t(n(17633));function t(S){return S&&S.__esModule?S:{default:S}}function o(S,k,h){return h===void 0&&(h={x:0,y:0}),{top:S.top-k.height-h.y,right:S.right-k.width+h.x,bottom:S.bottom-k.height+h.y,left:S.left-k.width-h.x}}function p(S){return[e.top,e.right,e.bottom,e.left].some(function(k){return S[k]>=0})}function b(S){var k=S.state,h=S.name,i=k.rects.reference,c=k.rects.popper,m=k.modifiersData.preventOverflow,l=(0,a.default)(k,{elementContext:"reference"}),u=(0,a.default)(k,{altBoundary:!0}),s=o(l,i),d=o(u,c,m),v=p(s),g=p(d);k.modifiersData[h]={referenceClippingOffsets:s,popperEscapeOffsets:d,isReferenceHidden:v,hasPopperEscaped:g},k.attributes.popper=Object.assign({},k.attributes.popper,{"data-popper-reference-hidden":v,"data-popper-escaped":g})}var y=r.default={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:b}},39805:function(T,r,n){"use strict";r.__esModule=!0,r.preventOverflow=r.popperOffsets=r.offset=r.hide=r.flip=r.eventListeners=r.computeStyles=r.arrow=r.applyStyles=void 0;var e=h(n(19975));r.applyStyles=e.default;var a=h(n(52744));r.arrow=a.default;var t=h(n(59894));r.computeStyles=t.default;var o=h(n(36692));r.eventListeners=o.default;var p=h(n(23798));r.flip=p.default;var b=h(n(83761));r.hide=b.default;var y=h(n(61410));r.offset=y.default;var S=h(n(40107));r.popperOffsets=S.default;var k=h(n(75137));r.preventOverflow=k.default;function h(i){return i&&i.__esModule?i:{default:i}}},61410:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0,r.distanceAndSkiddingToXY=o;var e=t(n(83104)),a=n(46206);function t(y){return y&&y.__esModule?y:{default:y}}function o(y,S,k){var h=(0,e.default)(y),i=[a.left,a.top].indexOf(h)>=0?-1:1,c=typeof k=="function"?k(Object.assign({},S,{placement:y})):k,m=c[0],l=c[1];return m=m||0,l=(l||0)*i,[a.left,a.right].indexOf(h)>=0?{x:l,y:m}:{x:m,y:l}}function p(y){var S=y.state,k=y.options,h=y.name,i=k.offset,c=i===void 0?[0,0]:i,m=a.placements.reduce(function(d,v){return d[v]=o(v,S.rects,c),d},{}),l=m[S.placement],u=l.x,s=l.y;S.modifiersData.popperOffsets!=null&&(S.modifiersData.popperOffsets.x+=u,S.modifiersData.popperOffsets.y+=s),S.modifiersData[h]=m}var b=r.default={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:p}},40107:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=a(n(89951));function a(p){return p&&p.__esModule?p:{default:p}}function t(p){var b=p.state,y=p.name;b.modifiersData[y]=(0,e.default)({reference:b.rects.reference,element:b.rects.popper,strategy:"absolute",placement:b.placement})}var o=r.default={name:"popperOffsets",enabled:!0,phase:"read",fn:t,data:{}}},75137:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=n(46206),a=c(n(83104)),t=c(n(41199)),o=c(n(28066)),p=n(28595),b=c(n(28811)),y=c(n(44896)),S=c(n(17633)),k=c(n(45)),h=c(n(34780)),i=n(63618);function c(u){return u&&u.__esModule?u:{default:u}}function m(u){var s=u.state,d=u.options,v=u.name,g=d.mainAxis,C=g===void 0?!0:g,f=d.altAxis,N=f===void 0?!1:f,V=d.boundary,B=d.rootBoundary,I=d.altBoundary,L=d.padding,w=d.tether,A=w===void 0?!0:w,x=d.tetherOffset,E=x===void 0?0:x,P=(0,S.default)(s,{boundary:V,rootBoundary:B,padding:L,altBoundary:I}),D=(0,a.default)(s.placement),M=(0,k.default)(s.placement),O=!M,R=(0,t.default)(D),F=(0,o.default)(R),W=s.modifiersData.popperOffsets,U=s.rects.reference,z=s.rects.popper,$=typeof E=="function"?E(Object.assign({},s.rects,{placement:s.placement})):E,G=typeof $=="number"?{mainAxis:$,altAxis:$}:Object.assign({mainAxis:0,altAxis:0},$),X=s.modifiersData.offset?s.modifiersData.offset[s.placement]:null,J={x:0,y:0};if(W){if(C){var se,ie=R==="y"?e.top:e.left,me=R==="y"?e.bottom:e.right,q=R==="y"?"height":"width",re=W[R],ae=re+P[ie],le=re-P[me],Z=A?-z[q]/2:0,ne=M===e.start?U[q]:z[q],te=M===e.start?-z[q]:-U[q],fe=s.elements.arrow,pe=A&&fe?(0,b.default)(fe):{width:0,height:0},ce=s.modifiersData["arrow#persistent"]?s.modifiersData["arrow#persistent"].padding:(0,h.default)(),Ve=ce[ie],Ce=ce[me],Ne=(0,p.within)(0,U[q],pe[q]),Be=O?U[q]/2-Z-Ne-Ve-G.mainAxis:ne-Ne-Ve-G.mainAxis,be=O?-U[q]/2+Z+Ne+Ce+G.mainAxis:te+Ne+Ce+G.mainAxis,Le=s.elements.arrow&&(0,y.default)(s.elements.arrow),we=Le?R==="y"?Le.clientTop||0:Le.clientLeft||0:0,xe=(se=X==null?void 0:X[R])!=null?se:0,Re=re+Be-xe-we,He=re+be-xe,ye=(0,p.within)(A?(0,i.min)(ae,Re):ae,re,A?(0,i.max)(le,He):le);W[R]=ye,J[R]=ye-re}if(N){var de,he=R==="x"?e.top:e.left,ke=R==="x"?e.bottom:e.right,ve=W[F],Se=F==="y"?"height":"width",Pe=ve+P[he],je=ve-P[ke],Fe=[e.top,e.left].indexOf(D)!==-1,ze=(de=X==null?void 0:X[F])!=null?de:0,We=Fe?Pe:ve-U[Se]-z[Se]-ze+G.altAxis,Ue=Fe?ve+U[Se]+z[Se]-ze-G.altAxis:je,Xe=A&&Fe?(0,p.withinMaxClamp)(We,ve,Ue):(0,p.within)(A?We:Pe,ve,A?Ue:je);W[F]=Xe,J[F]=Xe-ve}s.modifiersData[v]=J}}var l=r.default={name:"preventOverflow",enabled:!0,phase:"main",fn:m,requiresIfExists:["offset"]}},2473:function(T,r,n){"use strict";r.__esModule=!0,r.defaultModifiers=r.createPopper=void 0;var e=n(96376);r.popperGenerator=e.popperGenerator,r.detectOverflow=e.detectOverflow;var a=b(n(36692)),t=b(n(40107)),o=b(n(59894)),p=b(n(19975));function b(k){return k&&k.__esModule?k:{default:k}}var y=r.defaultModifiers=[a.default,t.default,o.default,p.default],S=r.createPopper=(0,e.popperGenerator)({defaultModifiers:y})},83312:function(T,r,n){"use strict";r.__esModule=!0;var e={createPopper:!0,createPopperLite:!0,defaultModifiers:!0,popperGenerator:!0,detectOverflow:!0};r.defaultModifiers=r.createPopperLite=r.createPopper=void 0;var a=n(96376);r.popperGenerator=a.popperGenerator,r.detectOverflow=a.detectOverflow;var t=l(n(36692)),o=l(n(40107)),p=l(n(59894)),b=l(n(19975)),y=l(n(61410)),S=l(n(23798)),k=l(n(75137)),h=l(n(52744)),i=l(n(83761)),c=n(2473);r.createPopperLite=c.createPopper;var m=n(39805);Object.keys(m).forEach(function(d){d==="default"||d==="__esModule"||Object.prototype.hasOwnProperty.call(e,d)||d in r&&r[d]===m[d]||(r[d]=m[d])});function l(d){return d&&d.__esModule?d:{default:d}}var u=r.defaultModifiers=[t.default,o.default,p.default,b.default,y.default,S.default,k.default,h.default,i.default],s=r.createPopperLite=r.createPopper=(0,a.popperGenerator)({defaultModifiers:u})},9041:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(45)),a=n(46206),t=p(n(17633)),o=p(n(83104));function p(y){return y&&y.__esModule?y:{default:y}}function b(y,S){S===void 0&&(S={});var k=S,h=k.placement,i=k.boundary,c=k.rootBoundary,m=k.padding,l=k.flipVariations,u=k.allowedAutoPlacements,s=u===void 0?a.placements:u,d=(0,e.default)(h),v=d?l?a.variationPlacements:a.variationPlacements.filter(function(f){return(0,e.default)(f)===d}):a.basePlacements,g=v.filter(function(f){return s.indexOf(f)>=0});g.length===0&&(g=v);var C=g.reduce(function(f,N){return f[N]=(0,t.default)(y,{placement:N,boundary:i,rootBoundary:c,padding:m})[(0,o.default)(N)],f},{});return Object.keys(C).sort(function(f,N){return C[f]-C[N]})}},89951:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(83104)),a=p(n(45)),t=p(n(41199)),o=n(46206);function p(y){return y&&y.__esModule?y:{default:y}}function b(y){var S=y.reference,k=y.element,h=y.placement,i=h?(0,e.default)(h):null,c=h?(0,a.default)(h):null,m=S.x+S.width/2-k.width/2,l=S.y+S.height/2-k.height/2,u;switch(i){case o.top:u={x:m,y:S.y-k.height};break;case o.bottom:u={x:m,y:S.y+S.height};break;case o.right:u={x:S.x+S.width,y:l};break;case o.left:u={x:S.x-k.width,y:l};break;default:u={x:S.x,y:S.y}}var s=i?(0,t.default)(i):null;if(s!=null){var d=s==="y"?"height":"width";switch(c){case o.start:u[s]=u[s]-(S[d]/2-k[d]/2);break;case o.end:u[s]=u[s]+(S[d]/2-k[d]/2);break;default:}}return u}},10579:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){var a;return function(){return a||(a=new Promise(function(t){Promise.resolve().then(function(){a=void 0,t(e())})})),a}}},17633:function(T,r,n){"use strict";r.__esModule=!0,r.default=i;var e=h(n(49035)),a=h(n(40600)),t=h(n(37786)),o=h(n(89951)),p=h(n(81666)),b=n(46206),y=n(75573),S=h(n(43286)),k=h(n(81447));function h(c){return c&&c.__esModule?c:{default:c}}function i(c,m){m===void 0&&(m={});var l=m,u=l.placement,s=u===void 0?c.placement:u,d=l.strategy,v=d===void 0?c.strategy:d,g=l.boundary,C=g===void 0?b.clippingParents:g,f=l.rootBoundary,N=f===void 0?b.viewport:f,V=l.elementContext,B=V===void 0?b.popper:V,I=l.altBoundary,L=I===void 0?!1:I,w=l.padding,A=w===void 0?0:w,x=(0,S.default)(typeof A!="number"?A:(0,k.default)(A,b.basePlacements)),E=B===b.popper?b.reference:b.popper,P=c.rects.popper,D=c.elements[L?E:B],M=(0,e.default)((0,y.isElement)(D)?D:D.contextElement||(0,a.default)(c.elements.popper),C,N,v),O=(0,t.default)(c.elements.reference),R=(0,o.default)({reference:O,element:P,strategy:"absolute",placement:s}),F=(0,p.default)(Object.assign({},P,R)),W=B===b.popper?F:O,U={top:M.top-W.top+x.top,bottom:W.bottom-M.bottom+x.bottom,left:M.left-W.left+x.left,right:W.right-M.right+x.right},z=c.modifiersData.offset;if(B===b.popper&&z){var $=z[s];Object.keys(U).forEach(function(G){var X=[b.right,b.bottom].indexOf(G)>=0?1:-1,J=[b.top,b.bottom].indexOf(G)>=0?"y":"x";U[G]+=$[J]*X})}return U}},81447:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e,a){return a.reduce(function(t,o){return t[o]=e,t},{})}},28066:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return e==="x"?"y":"x"}},83104:function(T,r,n){"use strict";r.__esModule=!0,r.default=a;var e=n(46206);function a(t){return t.split("-")[0]}},34780:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(){return{top:0,right:0,bottom:0,left:0}}},41199:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}},71376:function(T,r){"use strict";r.__esModule=!0,r.default=e;var n={left:"right",right:"left",bottom:"top",top:"bottom"};function e(a){return a.replace(/left|right|bottom|top/g,function(t){return n[t]})}},86459:function(T,r){"use strict";r.__esModule=!0,r.default=e;var n={start:"end",end:"start"};function e(a){return a.replace(/start|end/g,function(t){return n[t]})}},45:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return e.split("-")[1]}},63618:function(T,r){"use strict";r.__esModule=!0,r.round=r.min=r.max=void 0;var n=r.max=Math.max,e=r.min=Math.min,a=r.round=Math.round},56500:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){var a=e.reduce(function(t,o){var p=t[o.name];return t[o.name]=p?Object.assign({},p,o,{options:Object.assign({},p.options,o.options),data:Object.assign({},p.data,o.data)}):o,t},{});return Object.keys(a).map(function(t){return a[t]})}},43286:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(34780));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){return Object.assign({},(0,e.default)(),o)}},33118:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=n(46206);function a(o){var p=new Map,b=new Set,y=[];o.forEach(function(k){p.set(k.name,k)});function S(k){b.add(k.name);var h=[].concat(k.requires||[],k.requiresIfExists||[]);h.forEach(function(i){if(!b.has(i)){var c=p.get(i);c&&S(c)}}),y.push(k)}return o.forEach(function(k){b.has(k.name)||S(k)}),y}function t(o){var p=a(o);return e.modifierPhases.reduce(function(b,y){return b.concat(p.filter(function(S){return S.phase===y}))},[])}},81666:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}},35366:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(a){return a.brand+"/"+a.version}).join(" "):navigator.userAgent}},28595:function(T,r,n){"use strict";r.__esModule=!0,r.within=a,r.withinMaxClamp=t;var e=n(63618);function a(o,p,b){return(0,e.max)(o,(0,e.min)(p,b))}function t(o,p,b){var y=a(o,p,b);return y>b?b:y}},15875:function(T,r){"use strict";r.__esModule=!0,r.VNodeFlags=r.ChildFlags=void 0;var n;(function(a){a[a.Unknown=0]="Unknown",a[a.HtmlElement=1]="HtmlElement",a[a.ComponentUnknown=2]="ComponentUnknown",a[a.ComponentClass=4]="ComponentClass",a[a.ComponentFunction=8]="ComponentFunction",a[a.Text=16]="Text",a[a.SvgElement=32]="SvgElement",a[a.InputElement=64]="InputElement",a[a.TextareaElement=128]="TextareaElement",a[a.SelectElement=256]="SelectElement",a[a.Portal=1024]="Portal",a[a.ReCreate=2048]="ReCreate",a[a.ContentEditable=4096]="ContentEditable",a[a.Fragment=8192]="Fragment",a[a.InUse=16384]="InUse",a[a.ForwardRef=32768]="ForwardRef",a[a.Normalized=65536]="Normalized",a[a.ForwardRefComponent=32776]="ForwardRefComponent",a[a.FormElement=448]="FormElement",a[a.Element=481]="Element",a[a.Component=14]="Component",a[a.DOMRef=1521]="DOMRef",a[a.InUseOrNormalized=81920]="InUseOrNormalized",a[a.ClearInUse=-16385]="ClearInUse",a[a.ComponentKnown=12]="ComponentKnown"})(n||(r.VNodeFlags=n={}));var e;(function(a){a[a.UnknownChildren=0]="UnknownChildren",a[a.HasInvalidChildren=1]="HasInvalidChildren",a[a.HasVNodeChildren=2]="HasVNodeChildren",a[a.HasNonKeyedChildren=4]="HasNonKeyedChildren",a[a.HasKeyedChildren=8]="HasKeyedChildren",a[a.HasTextChildren=16]="HasTextChildren",a[a.MultipleChildren=12]="MultipleChildren"})(e||(r.ChildFlags=e={}))},89292:function(T,r){"use strict";r.__esModule=!0,r.Fragment=r.EMPTY_OBJ=r.Component=r.AnimationQueues=void 0,r._CI=Ot,r._HI=pe,r._M=Ke,r._MCCC=Ft,r._ME=Dt,r._MFCC=_t,r._MP=Mt,r._MR=at,r._RFC=gt,r.__render=Ht,r.createComponentVNode=se,r.createFragment=me,r.createPortal=Z,r.createRef=nn,r.createRenderer=En,r.createTextVNode=ie,r.createVNode=$,r.directClone=ae,r.findDOMFromVNode=V,r.forwardRef=on,r.getFlagsForElementVnode=te,r.linkEvent=h,r.normalizeProps=q,r.options=void 0,r.render=zt,r.rerender=$t,r.version=void 0;var n=Array.isArray;function e(j){var _=typeof j;return _==="string"||_==="number"}function a(j){return j==null}function t(j){return j===null||j===!1||j===!0||j===void 0}function o(j){return typeof j=="function"}function p(j){return typeof j=="string"}function b(j){return typeof j=="number"}function y(j){return j===null}function S(j){return j===void 0}function k(j,_){var H={};if(j)for(var K in j)H[K]=j[K];if(_)for(var Q in _)H[Q]=_[Q];return H}function h(j,_){return o(_)?{data:j,event:_}:null}function i(j){return!y(j)&&typeof j=="object"}var c=r.EMPTY_OBJ={},m=r.Fragment="$F",l=r.AnimationQueues=function(){function j(){this.componentDidAppear=[],this.componentWillDisappear=[],this.componentWillMove=[]}return j}();function u(j){return j.substring(2).toLowerCase()}function s(j,_){j.appendChild(_)}function d(j,_,H){y(H)?s(j,_):j.insertBefore(_,H)}function v(j,_){return _?document.createElementNS("http://www.w3.org/2000/svg",j):document.createElement(j)}function g(j,_,H){j.replaceChild(_,H)}function C(j,_){j.removeChild(_)}function f(j){for(var _=0;_0?B(H.componentWillDisappear,w(j,_)):L(j,_,!1)}function x(j,_,H,K,Q,ee,oe,ue){j.componentWillMove.push({dom:K,fn:function(){function ge(){oe&4?H.componentWillMove(_,Q,K):oe&8&&H.onComponentWillMove(_,Q,K,ue)}return ge}(),next:ee,parent:Q})}function E(j,_,H,K,Q){var ee,oe,ue=_.flags;do{var ge=_.flags;if(ge&1521){!a(ee)&&(o(ee.componentWillMove)||o(ee.onComponentWillMove))?x(Q,j,ee,_.dom,H,K,ue,oe):d(H,_.dom,K);return}var Te=_.children;if(ge&4)ee=_.children,oe=_.props,_=Te.$LI;else if(ge&8)ee=_.ref,oe=_.props,_=Te;else if(ge&8192)if(_.childFlags===2)_=Te;else{for(var Ie=0,Ee=Te.length;Ie0,Te=y(ue),Ie=p(ue)&&ue[0]===U;ge||Te||Ie?(H=H||_.slice(0,ee),(ge||Ie)&&(oe=ae(oe)),(Te||Ie)&&(oe.key=U+ee),H.push(oe)):H&&H.push(oe),oe.flags|=65536}}H=H||_,H.length===0?K=1:K=8}else H=_,H.flags|=65536,_.flags&81920&&(H=ae(_)),K=2;return j.children=H,j.childFlags=K,j}function pe(j){return t(j)||e(j)?ie(j,null):n(j)?me(j,0,null):j.flags&16384?ae(j):j}var ce="http://www.w3.org/1999/xlink",Ve="http://www.w3.org/XML/1998/namespace",Ce={"xlink:actuate":ce,"xlink:arcrole":ce,"xlink:href":ce,"xlink:role":ce,"xlink:show":ce,"xlink:title":ce,"xlink:type":ce,"xml:base":Ve,"xml:lang":Ve,"xml:space":Ve};function Ne(j){return{onClick:j,onDblClick:j,onFocusIn:j,onFocusOut:j,onKeyDown:j,onKeyPress:j,onKeyUp:j,onMouseDown:j,onMouseMove:j,onMouseUp:j,onTouchEnd:j,onTouchMove:j,onTouchStart:j}}var Be=Ne(0),be=Ne(null),Le=Ne(!0);function we(j,_){var H=_.$EV;return H||(H=_.$EV=Ne(null)),H[j]||++Be[j]===1&&(be[j]=je(j)),H}function xe(j,_){var H=_.$EV;H&&H[j]&&(--Be[j]===0&&(document.removeEventListener(u(j),be[j]),be[j]=null),H[j]=null)}function Re(j,_,H,K){if(o(H))we(j,K)[j]=H;else if(i(H)){if(R(_,H))return;we(j,K)[j]=H}else xe(j,K)}function He(j){return o(j.composedPath)?j.composedPath()[0]:j.target}function ye(j,_,H,K){var Q=He(j);do{if(_&&Q.disabled)return;var ee=Q.$EV;if(ee){var oe=ee[H];if(oe&&(K.dom=Q,oe.event?oe.event(oe.data,j):oe(j),j.cancelBubble))return}Q=Q.parentNode}while(!y(Q))}function de(){this.cancelBubble=!0,this.immediatePropagationStopped||this.stopImmediatePropagation()}function he(){return this.defaultPrevented}function ke(){return this.cancelBubble}function ve(j){var _={dom:document};return j.isDefaultPrevented=he,j.isPropagationStopped=ke,j.stopPropagation=de,Object.defineProperty(j,"currentTarget",{configurable:!0,get:function(){function H(){return _.dom}return H}()}),_}function Se(j){return function(_){if(_.button!==0){_.stopPropagation();return}ye(_,!0,j,ve(_))}}function Pe(j){return function(_){ye(_,!1,j,ve(_))}}function je(j){var _=j==="onClick"||j==="onDblClick"?Se(j):Pe(j);return document.addEventListener(u(j),_),_}function Fe(j,_){var H=document.createElement("i");return H.innerHTML=_,H.innerHTML===j.innerHTML}function ze(j,_,H){if(j[_]){var K=j[_];K.event?K.event(K.data,H):K(H)}else{var Q=_.toLowerCase();j[Q]&&j[Q](H)}}function We(j,_){var H=function(){function K(Q){var ee=this.$V;if(ee){var oe=ee.props||c,ue=ee.dom;if(p(j))ze(oe,j,Q);else for(var ge=0;ge-1&&_.options[ee]&&(ue=_.options[ee].value),H&&a(ue)&&(ue=j.defaultValue),rt(K,ue)}}var Zt=We("onInput",Tt),qt=We("onChange");function en(j,_){Ue(j,"input",Zt),_.onChange&&Ue(j,"change",qt)}function Tt(j,_,H){var K=j.value,Q=_.value;if(a(K)){if(H){var ee=j.defaultValue;!a(ee)&&ee!==Q&&(_.defaultValue=ee,_.value=ee)}}else Q!==K&&(_.defaultValue=K,_.value=K)}function xt(j,_,H,K,Q,ee){j&64?ut(K,H):j&256?wt(K,H,Q,_):j&128&&Tt(K,H,Q),ee&&(H.$V=_)}function tn(j,_,H){j&64?Bt(_,H):j&256?Qt(_):j&128&&en(_,H)}function At(j){return j.type&&Xe(j.type)?!a(j.checked):!a(j.value)}function nn(){return{current:null}}function on(j){var _={render:j};return _}function st(j){j&&!W(j,null)&&j.current&&(j.current=null)}function at(j,_,H){j&&(o(j)||j.current!==void 0)&&H.push(function(){!W(j,_)&&j.current!==void 0&&(j.current=_)})}function Je(j,_,H){Ze(j,H),A(j,_,H)}function Ze(j,_){var H=j.flags,K=j.children,Q;if(H&481){Q=j.ref;var ee=j.props;st(Q);var oe=j.childFlags;if(!y(ee))for(var ue=Object.keys(ee),ge=0,Te=ue.length;ge0?B(H.componentWillDisappear,rn(_,j)):j.textContent=""}function pt(j,_,H,K){ct(H,K),_.flags&8192?A(_,j,K):mt(j,H,K)}function Et(j,_,H,K,Q){j.componentWillDisappear.push(function(ee){K&4?_.componentWillDisappear(H,ee):K&8&&_.onComponentWillDisappear(H,Q,ee)})}function an(j){var _=j.event;return function(H){_(j.data,H)}}function cn(j,_,H,K){if(i(H)){if(R(_,H))return;H=an(H)}Ue(K,u(j),H)}function ln(j,_,H){if(a(_)){H.removeAttribute("style");return}var K=H.style,Q,ee;if(p(_)){K.cssText=_;return}if(!a(j)&&!p(j)){for(Q in _)ee=_[Q],ee!==j[Q]&&K.setProperty(Q,ee);for(Q in j)a(_[Q])&&K.removeProperty(Q)}else for(Q in _)ee=_[Q],K.setProperty(Q,ee)}function dn(j,_,H,K,Q){var ee=j&&j.__html||"",oe=_&&_.__html||"";ee!==oe&&!a(oe)&&!Fe(K,oe)&&(y(H)||(H.childFlags&12?ct(H.children,Q):H.childFlags===2&&Ze(H.children,Q),H.children=null,H.childFlags=1),K.innerHTML=oe)}function vt(j,_,H,K,Q,ee,oe,ue){switch(j){case"children":case"childrenType":case"className":case"defaultValue":case"key":case"multiple":case"ref":case"selectedIndex":break;case"autoFocus":K.autofocus=!!H;break;case"allowfullscreen":case"autoplay":case"capture":case"checked":case"controls":case"default":case"disabled":case"hidden":case"indeterminate":case"loop":case"muted":case"novalidate":case"open":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"selected":K[j]=!!H;break;case"defaultChecked":case"value":case"volume":if(ee&&j==="value")break;var ge=a(H)?"":H;K[j]!==ge&&(K[j]=ge);break;case"style":ln(_,H,K);break;case"dangerouslySetInnerHTML":dn(_,H,oe,K,ue);break;default:Le[j]?Re(j,_,H,K):j.charCodeAt(0)===111&&j.charCodeAt(1)===110?cn(j,_,H,K):a(H)?K.removeAttribute(j):Q&&Ce[j]?K.setAttributeNS(Ce[j],j,H):K.setAttribute(j,H);break}}function Mt(j,_,H,K,Q,ee){var oe=!1,ue=(_&448)>0;ue&&(oe=At(H),oe&&tn(_,K,H));for(var ge in H)vt(ge,null,H[ge],K,Q,oe,null,ee);ue&&xt(_,j,K,H,!0,oe)}function Pt(j,_,H){var K=pe(j.render(_,j.state,H)),Q=H;return o(j.getChildContext)&&(Q=k(H,j.getChildContext())),j.$CX=Q,K}function Ot(j,_,H,K,Q,ee){var oe=new _(H,K),ue=oe.$N=!!(_.getDerivedStateFromProps||oe.getSnapshotBeforeUpdate);if(oe.$SVG=Q,oe.$L=ee,j.children=oe,oe.$BS=!1,oe.context=K,oe.props===c&&(oe.props=H),ue)oe.state=P(oe,H,oe.state);else if(o(oe.componentWillMount)){oe.$BR=!0,oe.componentWillMount();var ge=oe.$PS;if(!y(ge)){var Te=oe.state;if(y(Te))oe.state=ge;else for(var Ie in ge)Te[Ie]=ge[Ie];oe.$PS=null}oe.$BR=!1}return oe.$LI=Pt(oe,H,K),oe}function gt(j,_){var H=j.props||c;return j.flags&32768?j.type.render(H,j.ref,_):j.type(H,_)}function Ke(j,_,H,K,Q,ee,oe){var ue=j.flags|=16384;ue&481?Dt(j,_,H,K,Q,ee,oe):ue&4?mn(j,_,H,K,Q,ee,oe):ue&8?pn(j,_,H,K,Q,ee,oe):ue&16?Rt(j,_,Q):ue&8192?sn(j,H,_,K,Q,ee,oe):ue&1024&&un(j,H,_,Q,ee,oe)}function un(j,_,H,K,Q,ee){Ke(j.children,j.ref,_,!1,null,Q,ee);var oe=le();Rt(oe,H,K),j.dom=oe.dom}function sn(j,_,H,K,Q,ee,oe){var ue=j.children,ge=j.childFlags;ge&12&&ue.length===0&&(ge=j.childFlags=2,ue=j.children=le()),ge===2?Ke(ue,H,_,K,Q,ee,oe):ot(ue,H,_,K,Q,ee,oe)}function Rt(j,_,H){var K=j.dom=document.createTextNode(j.children);y(_)||d(_,K,H)}function Dt(j,_,H,K,Q,ee,oe){var ue=j.flags,ge=j.props,Te=j.className,Ie=j.childFlags,Ee=j.dom=v(j.type,K=K||(ue&32)>0),Ae=j.children;if(!a(Te)&&Te!==""&&(K?Ee.setAttribute("class",Te):Ee.className=Te),Ie===16)O(Ee,Ae);else if(Ie!==1){var Me=K&&j.type!=="foreignObject";Ie===2?(Ae.flags&16384&&(j.children=Ae=ae(Ae)),Ke(Ae,Ee,H,Me,null,ee,oe)):(Ie===8||Ie===4)&&ot(Ae,Ee,H,Me,null,ee,oe)}y(_)||d(_,Ee,Q),y(ge)||Mt(j,ue,ge,Ee,K,oe),at(j.ref,Ee,ee)}function ot(j,_,H,K,Q,ee,oe){for(var ue=0;ueMe)&&(Ee=V(ue[Me-1],!1).nextSibling)}Nt(Te,Ie,ue,ge,H,K,Q,Ee,j,ee,oe)}function Vn(j,_,H,K,Q){var ee=j.ref,oe=_.ref,ue=_.children;if(Nt(j.childFlags,_.childFlags,j.children,ue,ee,H,!1,null,j,K,Q),_.dom=j.dom,ee!==oe&&!t(ue)){var ge=ue.dom;C(ee,ge),s(oe,ge)}}function bn(j,_,H,K,Q,ee,oe){var ue=_.dom=j.dom,ge=j.props,Te=_.props,Ie=!1,Ee=!1,Ae;if(K=K||(Q&32)>0,ge!==Te){var Me=ge||c;if(Ae=Te||c,Ae!==c){Ie=(Q&448)>0,Ie&&(Ee=At(Ae));for(var _e in Ae){var Oe=Me[_e],$e=Ae[_e];Oe!==$e&&vt(_e,Oe,$e,ue,K,Ee,j,oe)}}if(Me!==c)for(var De in Me)a(Ae[De])&&!a(Me[De])&&vt(De,Me[De],null,ue,K,Ee,j,oe)}var tt=_.children,Ye=_.className;j.className!==Ye&&(a(Ye)?ue.removeAttribute("class"):K?ue.setAttribute("class",Ye):ue.className=Ye),Q&4096?gn(ue,tt):Nt(j.childFlags,_.childFlags,j.children,tt,ue,H,K&&_.type!=="foreignObject",null,j,ee,oe),Ie&&xt(Q,_,ue,Ae,!1,Ee);var it=_.ref,Qe=j.ref;Qe!==it&&(st(Qe),at(it,ue,ee))}function kn(j,_,H,K,Q,ee,oe){Ze(j,oe),ot(_,H,K,Q,V(j,!0),ee,oe),A(j,H,oe)}function Nt(j,_,H,K,Q,ee,oe,ue,ge,Te,Ie){switch(j){case 2:switch(_){case 2:qe(H,K,Q,ee,oe,ue,Te,Ie);break;case 1:Je(H,Q,Ie);break;case 16:Ze(H,Ie),O(Q,K);break;default:kn(H,K,Q,ee,oe,Te,Ie);break}break;case 1:switch(_){case 2:Ke(K,Q,ee,oe,ue,Te,Ie);break;case 1:break;case 16:O(Q,K);break;default:ot(K,Q,ee,oe,ue,Te,Ie);break}break;case 16:switch(_){case 16:vn(H,K,Q);break;case 2:mt(Q,H,Ie),Ke(K,Q,ee,oe,ue,Te,Ie);break;case 1:mt(Q,H,Ie);break;default:mt(Q,H,Ie),ot(K,Q,ee,oe,ue,Te,Ie);break}break;default:switch(_){case 16:ct(H,Ie),O(Q,K);break;case 2:pt(Q,ge,H,Ie),Ke(K,Q,ee,oe,ue,Te,Ie);break;case 1:pt(Q,ge,H,Ie);break;default:var Ee=H.length|0,Ae=K.length|0;Ee===0?Ae>0&&ot(K,Q,ee,oe,ue,Te,Ie):Ae===0?pt(Q,ge,H,Ie):_===8&&j===8?wn(H,K,Q,ee,oe,Ee,Ae,ue,ge,Te,Ie):Ln(H,K,Q,ee,oe,Ee,Ae,ue,Te,Ie);break}break}}function yn(j,_,H,K,Q){Q.push(function(){j.componentDidUpdate(_,H,K)})}function Wt(j,_,H,K,Q,ee,oe,ue,ge,Te){var Ie=j.state,Ee=j.props,Ae=!!j.$N,Me=o(j.shouldComponentUpdate);if(Ae&&(_=P(j,H,_!==Ie?k(Ie,_):_)),oe||!Me||Me&&j.shouldComponentUpdate(H,_,Q)){!Ae&&o(j.componentWillUpdate)&&j.componentWillUpdate(H,_,Q),j.props=H,j.state=_,j.context=Q;var _e=null,Oe=Pt(j,H,Q);Ae&&o(j.getSnapshotBeforeUpdate)&&(_e=j.getSnapshotBeforeUpdate(Ee,Ie)),qe(j.$LI,Oe,K,j.$CX,ee,ue,ge,Te),j.$LI=Oe,o(j.componentDidUpdate)&&yn(j,Ee,Ie,_e,ge)}else j.props=H,j.state=_,j.context=Q}function Sn(j,_,H,K,Q,ee,oe,ue){var ge=_.children=j.children;if(!y(ge)){ge.$L=oe;var Te=_.props||c,Ie=_.ref,Ee=j.ref,Ae=ge.state;if(!ge.$N){if(o(ge.componentWillReceiveProps)){if(ge.$BR=!0,ge.componentWillReceiveProps(Te,K),ge.$UN)return;ge.$BR=!1}y(ge.$PS)||(Ae=k(Ae,ge.$PS),ge.$PS=null)}Wt(ge,Ae,Te,H,K,Q,!1,ee,oe,ue),Ee!==Ie&&(st(Ee),at(Ie,ge,oe))}}function Bn(j,_,H,K,Q,ee,oe,ue){var ge=!0,Te=_.props||c,Ie=_.ref,Ee=j.props,Ae=!a(Ie),Me=j.children;if(Ae&&o(Ie.onComponentShouldUpdate)&&(ge=Ie.onComponentShouldUpdate(Ee,Te)),ge!==!1){Ae&&o(Ie.onComponentWillUpdate)&&Ie.onComponentWillUpdate(Ee,Te);var _e=pe(gt(_,K));qe(Me,_e,H,K,Q,ee,oe,ue),_.children=_e,Ae&&o(Ie.onComponentDidUpdate)&&Ie.onComponentDidUpdate(Ee,Te)}else _.children=Me}function In(j,_){var H=_.children,K=_.dom=j.dom;H!==j.children&&(K.nodeValue=H)}function Ln(j,_,H,K,Q,ee,oe,ue,ge,Te){for(var Ie=ee>oe?oe:ee,Ee=0,Ae,Me;Eeoe)for(Ee=Ie;EeEe||Me>Ae)break e;_e=j[Me],Oe=_[Me]}for(_e=j[Ee],Oe=_[Ae];_e.key===Oe.key;){if(Oe.flags&16384&&(_[Ae]=Oe=ae(Oe)),qe(_e,Oe,H,K,Q,ue,Te,Ie),j[Ee]=Oe,Ee--,Ae--,Me>Ee||Me>Ae)break e;_e=j[Ee],Oe=_[Ae]}}if(Me>Ee){if(Me<=Ae)for($e=Ae+1,De=$eAe)for(;Me<=Ee;)Je(j[Me++],H,Ie);else Tn(j,_,K,ee,oe,Ee,Ae,Me,H,Q,ue,ge,Te,Ie)}function Tn(j,_,H,K,Q,ee,oe,ue,ge,Te,Ie,Ee,Ae,Me){var _e,Oe,$e=0,De=0,tt=ue,Ye=ue,it=ee-ue+1,Qe=oe-ue+1,lt=new Int32Array(Qe+1),nt=it===K,bt=!1,Ge=0,dt=0;if(Q<4||(it|Qe)<32)for(De=tt;De<=ee;++De)if(_e=j[De],dtue?bt=!0:Ge=ue,Oe.flags&16384&&(_[ue]=Oe=ae(Oe)),qe(_e,Oe,ge,H,Te,Ie,Ae,Me),++dt;break}!nt&&ue>oe&&Je(_e,ge,Me)}else nt||Je(_e,ge,Me);else{var Yt={};for(De=Ye;De<=oe;++De)Yt[_[De].key]=De;for(De=tt;De<=ee;++De)if(_e=j[De],dttt;)Je(j[tt++],ge,Me);lt[ue-Ye]=De+1,Ge>ue?bt=!0:Ge=ue,Oe=_[ue],Oe.flags&16384&&(_[ue]=Oe=ae(Oe)),qe(_e,Oe,ge,H,Te,Ie,Ae,Me),++dt}else nt||Je(_e,ge,Me);else nt||Je(_e,ge,Me)}if(nt)pt(ge,Ee,j,Me),ot(_,ge,H,Te,Ie,Ae,Me);else if(bt){var Xt=xn(lt);for(ue=Xt.length-1,De=Qe-1;De>=0;De--)lt[De]===0?(Ge=De+Ye,Oe=_[Ge],Oe.flags&16384&&(_[Ge]=Oe=ae(Oe)),$e=Ge+1,Ke(Oe,ge,H,Te,$e0&&I(Me.componentWillMove)}else if(dt!==Qe)for(De=Qe-1;De>=0;De--)lt[De]===0&&(Ge=De+Ye,Oe=_[Ge],Oe.flags&16384&&(_[Ge]=Oe=ae(Oe)),$e=Ge+1,Ke(Oe,ge,H,Te,$eUt&&(Ut=ge,et=new Int32Array(ge),ft=new Int32Array(ge));H>1,j[et[ue]]<_?ee=ue+1:oe=ue;_0&&(ft[H]=et[ee-1]),et[ee]=H)}ee=Q+1;var Te=new Int32Array(ee);for(oe=et[ee-1];ee-- >0;)Te[ee]=oe,oe=ft[oe],et[ee]=0;return Te}var An=typeof document!="undefined";An&&window.Node&&(Node.prototype.$EV=null,Node.prototype.$V=null);function Ht(j,_,H,K){var Q=[],ee=new l,oe=_.$V;D.v=!0,a(oe)?a(j)||(j.flags&16384&&(j=ae(j)),Ke(j,_,K,!1,null,Q,ee),_.$V=j,oe=j):a(j)?(Je(oe,_,ee),_.$V=null):(j.flags&16384&&(j=ae(j)),qe(oe,j,_,K,!1,null,Q,ee),oe=_.$V=j),f(Q),B(ee.componentDidAppear),D.v=!1,o(H)&&H(),o(M.renderComplete)&&M.renderComplete(oe,_)}function zt(j,_,H,K){H===void 0&&(H=null),K===void 0&&(K=c),Ht(j,_,H,K)}function En(j){return function(){function _(H,K,Q,ee){j||(j=H),zt(K,j,Q,ee)}return _}()}var ht=[],Mn=typeof Promise!="undefined"?Promise.resolve().then.bind(Promise.resolve()):function(j){window.setTimeout(j,0)},Vt=!1;function Kt(j,_,H,K){var Q=j.$PS;if(o(_)&&(_=_(Q?k(j.state,Q):j.state,j.props,j.context)),a(Q))j.$PS=_;else for(var ee in _)Q[ee]=_[ee];if(j.$BR)o(H)&&j.$L.push(H.bind(j));else{if(!D.v&&ht.length===0){Gt(j,K),o(H)&&H.call(j);return}if(ht.indexOf(j)===-1&&ht.push(j),K&&(j.$F=!0),Vt||(Vt=!0,Mn($t)),o(H)){var oe=j.$QU;oe||(oe=j.$QU=[]),oe.push(H)}}}function Pn(j){for(var _=j.$QU,H=0;H<_.length;++H)_[H].call(j);j.$QU=null}function $t(){var j;for(Vt=!1;j=ht.shift();)if(!j.$UN){var _=j.$F;j.$F=!1,Gt(j,_),j.$QU&&Pn(j)}}function Gt(j,_){if(_||!j.$BR){var H=j.$PS;j.$PS=null;var K=[],Q=new l;D.v=!0,Wt(j,k(j.state,H),j.props,V(j.$LI,!0).parentNode,j.context,j.$SVG,_,null,K,Q),f(K),B(Q.componentDidAppear),D.v=!1}else j.state=j.$PS,j.$PS=null}var On=r.Component=function(){function j(H,K){this.state=null,this.props=void 0,this.context=void 0,this.displayName=void 0,this.$BR=!1,this.$BS=!0,this.$PS=null,this.$LI=null,this.$UN=!1,this.$CX=null,this.$QU=null,this.$N=!1,this.$SSR=void 0,this.$L=null,this.$SVG=!1,this.$F=!1,this.props=H||c,this.context=K||c}var _=j.prototype;return _.forceUpdate=function(){function H(K){this.$UN||Kt(this,{},K,!0)}return H}(),_.setState=function(){function H(K,Q){this.$UN||this.$BS||Kt(this,K,Q,!1)}return H}(),_.render=function(){function H(K,Q,ee){return null}return H}(),j}();On.defaultProps=null;var Dn=r.version="8.2.3"},89005:function(T,r,n){"use strict";r.__esModule=!0;var e=n(89292);Object.keys(e).forEach(function(a){a==="default"||a==="__esModule"||a in r&&r[a]===e[a]||(r[a]=e[a])})},71614:function(T,r,n){"use strict";var e=n(21285);function a(){}function t(){}t.resetWarningCache=a,T.exports=function(){function o(y,S,k,h,i,c){if(c!==e){var m=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw m.name="Invariant Violation",m}}o.isRequired=o;function p(){return o}var b={array:o,bigint:o,bool:o,func:o,number:o,object:o,string:o,symbol:o,any:o,arrayOf:p,element:o,elementType:o,instanceOf:p,node:o,objectOf:p,oneOf:p,oneOfType:p,shape:p,exact:p,checkPropTypes:t,resetWarningCache:a};return b.PropTypes=b,b}},15964:function(T,r,n){"use strict";if(0)var e,a;else T.exports=n(71614)()},21285:function(T){"use strict";var r="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";T.exports=r},95012:function(T){"use strict";var r=function(n){"use strict";var e=Object.prototype,a=e.hasOwnProperty,t=Object.defineProperty||function(M,O,R){M[O]=R.value},o,p=typeof Symbol=="function"?Symbol:{},b=p.iterator||"@@iterator",y=p.asyncIterator||"@@asyncIterator",S=p.toStringTag||"@@toStringTag";function k(M,O,R){return Object.defineProperty(M,O,{value:R,enumerable:!0,configurable:!0,writable:!0}),M[O]}try{k({},"")}catch(M){k=function(R,F,W){return R[F]=W}}function h(M,O,R,F){var W=O&&O.prototype instanceof d?O:d,U=Object.create(W.prototype),z=new E(F||[]);return t(U,"_invoke",{value:L(M,R,z)}),U}n.wrap=h;function i(M,O,R){try{return{type:"normal",arg:M.call(O,R)}}catch(F){return{type:"throw",arg:F}}}var c="suspendedStart",m="suspendedYield",l="executing",u="completed",s={};function d(){}function v(){}function g(){}var C={};k(C,b,function(){return this});var f=Object.getPrototypeOf,N=f&&f(f(P([])));N&&N!==e&&a.call(N,b)&&(C=N);var V=g.prototype=d.prototype=Object.create(C);v.prototype=g,t(V,"constructor",{value:g,configurable:!0}),t(g,"constructor",{value:v,configurable:!0}),v.displayName=k(g,S,"GeneratorFunction");function B(M){["next","throw","return"].forEach(function(O){k(M,O,function(R){return this._invoke(O,R)})})}n.isGeneratorFunction=function(M){var O=typeof M=="function"&&M.constructor;return O?O===v||(O.displayName||O.name)==="GeneratorFunction":!1},n.mark=function(M){return Object.setPrototypeOf?Object.setPrototypeOf(M,g):(M.__proto__=g,k(M,S,"GeneratorFunction")),M.prototype=Object.create(V),M},n.awrap=function(M){return{__await:M}};function I(M,O){function R(U,z,$,G){var X=i(M[U],M,z);if(X.type==="throw")G(X.arg);else{var J=X.arg,se=J.value;return se&&typeof se=="object"&&a.call(se,"__await")?O.resolve(se.__await).then(function(ie){R("next",ie,$,G)},function(ie){R("throw",ie,$,G)}):O.resolve(se).then(function(ie){J.value=ie,$(J)},function(ie){return R("throw",ie,$,G)})}}var F;function W(U,z){function $(){return new O(function(G,X){R(U,z,G,X)})}return F=F?F.then($,$):$()}t(this,"_invoke",{value:W})}B(I.prototype),k(I.prototype,y,function(){return this}),n.AsyncIterator=I,n.async=function(M,O,R,F,W){W===void 0&&(W=Promise);var U=new I(h(M,O,R,F),W);return n.isGeneratorFunction(O)?U:U.next().then(function(z){return z.done?z.value:U.next()})};function L(M,O,R){var F=c;return function(){function W(U,z){if(F===l)throw new Error("Generator is already running");if(F===u){if(U==="throw")throw z;return D()}for(R.method=U,R.arg=z;;){var $=R.delegate;if($){var G=w($,R);if(G){if(G===s)continue;return G}}if(R.method==="next")R.sent=R._sent=R.arg;else if(R.method==="throw"){if(F===c)throw F=u,R.arg;R.dispatchException(R.arg)}else R.method==="return"&&R.abrupt("return",R.arg);F=l;var X=i(M,O,R);if(X.type==="normal"){if(F=R.done?u:m,X.arg===s)continue;return{value:X.arg,done:R.done}}else X.type==="throw"&&(F=u,R.method="throw",R.arg=X.arg)}}return W}()}function w(M,O){var R=O.method,F=M.iterator[R];if(F===o)return O.delegate=null,R==="throw"&&M.iterator.return&&(O.method="return",O.arg=o,w(M,O),O.method==="throw")||R!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+R+"' method")),s;var W=i(F,M.iterator,O.arg);if(W.type==="throw")return O.method="throw",O.arg=W.arg,O.delegate=null,s;var U=W.arg;if(!U)return O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,s;if(U.done)O[M.resultName]=U.value,O.next=M.nextLoc,O.method!=="return"&&(O.method="next",O.arg=o);else return U;return O.delegate=null,s}B(V),k(V,S,"Generator"),k(V,b,function(){return this}),k(V,"toString",function(){return"[object Generator]"});function A(M){var O={tryLoc:M[0]};1 in M&&(O.catchLoc=M[1]),2 in M&&(O.finallyLoc=M[2],O.afterLoc=M[3]),this.tryEntries.push(O)}function x(M){var O=M.completion||{};O.type="normal",delete O.arg,M.completion=O}function E(M){this.tryEntries=[{tryLoc:"root"}],M.forEach(A,this),this.reset(!0)}n.keys=function(M){var O=Object(M),R=[];for(var F in O)R.push(F);return R.reverse(),function(){function W(){for(;R.length;){var U=R.pop();if(U in O)return W.value=U,W.done=!1,W}return W.done=!0,W}return W}()};function P(M){if(M!=null){var O=M[b];if(O)return O.call(M);if(typeof M.next=="function")return M;if(!isNaN(M.length)){var R=-1,F=function(){function W(){for(;++R=0;--W){var U=this.tryEntries[W],z=U.completion;if(U.tryLoc==="root")return F("end");if(U.tryLoc<=this.prev){var $=a.call(U,"catchLoc"),G=a.call(U,"finallyLoc");if($&&G){if(this.prev=0;--F){var W=this.tryEntries[F];if(W.tryLoc<=this.prev&&a.call(W,"finallyLoc")&&this.prev=0;--R){var F=this.tryEntries[R];if(F.finallyLoc===O)return this.complete(F.completion,F.afterLoc),x(F),s}}return M}(),catch:function(){function M(O){for(var R=this.tryEntries.length-1;R>=0;--R){var F=this.tryEntries[R];if(F.tryLoc===O){var W=F.completion;if(W.type==="throw"){var U=W.arg;x(F)}return U}}throw new Error("illegal catch attempt")}return M}(),delegateYield:function(){function M(O,R,F){return this.delegate={iterator:P(O),resultName:R,nextLoc:F},this.method==="next"&&(this.arg=o),s}return M}()},n}(T.exports);try{regeneratorRuntime=r}catch(n){typeof globalThis=="object"?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},30236:function(){"use strict";self.fetch||(self.fetch=function(T,r){return r=r||{},new Promise(function(n,e){var a=new XMLHttpRequest,t=[],o={},p=function(){function y(){return{ok:(a.status/100|0)==2,statusText:a.statusText,status:a.status,url:a.responseURL,text:function(){function S(){return Promise.resolve(a.responseText)}return S}(),json:function(){function S(){return Promise.resolve(a.responseText).then(JSON.parse)}return S}(),blob:function(){function S(){return Promise.resolve(new Blob([a.response]))}return S}(),clone:y,headers:{keys:function(){function S(){return t}return S}(),entries:function(){function S(){return t.map(function(k){return[k,a.getResponseHeader(k)]})}return S}(),get:function(){function S(k){return a.getResponseHeader(k)}return S}(),has:function(){function S(k){return a.getResponseHeader(k)!=null}return S}()}}}return y}();for(var b in a.open(r.method||"get",T,!0),a.onload=function(){a.getAllResponseHeaders().toLowerCase().replace(/^(.+?):/gm,function(y,S){o[S]||t.push(o[S]=S)}),n(p())},a.onerror=e,a.withCredentials=r.credentials=="include",r.headers)a.setRequestHeader(b,r.headers[b]);a.send(r.body||null)})})},88510:function(T,r){"use strict";r.__esModule=!0,r.zipWith=r.zip=r.uniqBy=r.uniq=r.toKeyedArray=r.toArray=r.sortBy=r.sort=r.reduce=r.range=r.map=r.filterMap=r.filter=void 0;function n(d,v){var g=typeof Symbol!="undefined"&&d[Symbol.iterator]||d["@@iterator"];if(g)return(g=g.call(d)).next.bind(g);if(Array.isArray(d)||(g=e(d))||v&&d&&typeof d.length=="number"){g&&(d=g);var C=0;return function(){return C>=d.length?{done:!0}:{done:!1,value:d[C++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function e(d,v){if(d){if(typeof d=="string")return a(d,v);var g={}.toString.call(d).slice(8,-1);return g==="Object"&&d.constructor&&(g=d.constructor.name),g==="Map"||g==="Set"?Array.from(d):g==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(g)?a(d,v):void 0}}function a(d,v){(v==null||v>d.length)&&(v=d.length);for(var g=0,C=Array(v);g0&&(0,a.round)(h.width)/y.offsetWidth||1,c=y.offsetHeight>0&&(0,a.round)(h.height)/y.offsetHeight||1);var m=(0,e.isElement)(y)?(0,t.default)(y):window,l=m.visualViewport,u=!(0,o.default)()&&k,s=(h.left+(u&&l?l.offsetLeft:0))/i,d=(h.top+(u&&l?l.offsetTop:0))/c,C=h.width/i,g=h.height/c;return{width:C,height:g,top:d,right:s+C,bottom:d+g,left:s,x:s,y:d}}},49035:function(T,r,n){"use strict";r.__esModule=!0,r.default=g;var e=n(46206),a=u(n(87991)),t=u(n(79752)),o=u(n(98309)),p=u(n(44896)),b=u(n(40600)),y=u(n(16599)),S=n(75573),k=u(n(37786)),h=u(n(57819)),i=u(n(4206)),c=u(n(12972)),m=u(n(81666)),l=n(63618);function u(v){return v&&v.__esModule?v:{default:v}}function s(v,f){var N=(0,k.default)(v,!1,f==="fixed");return N.top=N.top+v.clientTop,N.left=N.left+v.clientLeft,N.bottom=N.top+v.clientHeight,N.right=N.left+v.clientWidth,N.width=v.clientWidth,N.height=v.clientHeight,N.x=N.left,N.y=N.top,N}function d(v,f,N){return f===e.viewport?(0,m.default)((0,a.default)(v,N)):(0,S.isElement)(f)?s(f,N):(0,m.default)((0,t.default)((0,b.default)(v)))}function C(v){var f=(0,o.default)((0,h.default)(v)),N=["absolute","fixed"].indexOf((0,y.default)(v).position)>=0,V=N&&(0,S.isHTMLElement)(v)?(0,p.default)(v):v;return(0,S.isElement)(V)?f.filter(function(B){return(0,S.isElement)(B)&&(0,i.default)(B,V)&&(0,c.default)(B)!=="body"}):[]}function g(v,f,N,V){var B=f==="clippingParents"?C(v):[].concat(f),I=[].concat(B,[N]),L=I[0],w=I.reduce(function(A,x){var E=d(v,x,V);return A.top=(0,l.max)(E.top,A.top),A.right=(0,l.min)(E.right,A.right),A.bottom=(0,l.min)(E.bottom,A.bottom),A.left=(0,l.max)(E.left,A.left),A},d(v,L,V));return w.width=w.right-w.left,w.height=w.bottom-w.top,w.x=w.left,w.y=w.top,w}},74758:function(T,r,n){"use strict";r.__esModule=!0,r.default=i;var e=k(n(37786)),a=k(n(13390)),t=k(n(12972)),o=n(75573),p=k(n(79697)),b=k(n(40600)),y=k(n(10798)),S=n(63618);function k(c){return c&&c.__esModule?c:{default:c}}function h(c){var m=c.getBoundingClientRect(),l=(0,S.round)(m.width)/c.offsetWidth||1,u=(0,S.round)(m.height)/c.offsetHeight||1;return l!==1||u!==1}function i(c,m,l){l===void 0&&(l=!1);var u=(0,o.isHTMLElement)(m),s=(0,o.isHTMLElement)(m)&&h(m),d=(0,b.default)(m),C=(0,e.default)(c,s,l),g={scrollLeft:0,scrollTop:0},v={x:0,y:0};return(u||!u&&!l)&&(((0,t.default)(m)!=="body"||(0,y.default)(d))&&(g=(0,a.default)(m)),(0,o.isHTMLElement)(m)?(v=(0,e.default)(m,!0),v.x+=m.clientLeft,v.y+=m.clientTop):d&&(v.x=(0,p.default)(d))),{x:C.left+g.scrollLeft-v.x,y:C.top+g.scrollTop-v.y,width:C.width,height:C.height}}},16599:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(95115));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){return(0,e.default)(o).getComputedStyle(o)}},40600:function(T,r,n){"use strict";r.__esModule=!0,r.default=a;var e=n(75573);function a(t){return(((0,e.isElement)(t)?t.ownerDocument:t.document)||window.document).documentElement}},79752:function(T,r,n){"use strict";r.__esModule=!0,r.default=y;var e=b(n(40600)),a=b(n(16599)),t=b(n(79697)),o=b(n(43750)),p=n(63618);function b(S){return S&&S.__esModule?S:{default:S}}function y(S){var k,h=(0,e.default)(S),i=(0,o.default)(S),c=(k=S.ownerDocument)==null?void 0:k.body,m=(0,p.max)(h.scrollWidth,h.clientWidth,c?c.scrollWidth:0,c?c.clientWidth:0),l=(0,p.max)(h.scrollHeight,h.clientHeight,c?c.scrollHeight:0,c?c.clientHeight:0),u=-i.scrollLeft+(0,t.default)(S),s=-i.scrollTop;return(0,a.default)(c||h).direction==="rtl"&&(u+=(0,p.max)(h.clientWidth,c?c.clientWidth:0)-m),{width:m,height:l,x:u,y:s}}},3073:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}},28811:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(37786));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){var p=(0,e.default)(o),b=o.offsetWidth,y=o.offsetHeight;return Math.abs(p.width-b)<=1&&(b=p.width),Math.abs(p.height-y)<=1&&(y=p.height),{x:o.offsetLeft,y:o.offsetTop,width:b,height:y}}},12972:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return e?(e.nodeName||"").toLowerCase():null}},13390:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(43750)),a=p(n(95115)),t=n(75573),o=p(n(3073));function p(y){return y&&y.__esModule?y:{default:y}}function b(y){return y===(0,a.default)(y)||!(0,t.isHTMLElement)(y)?(0,e.default)(y):(0,o.default)(y)}},44896:function(T,r,n){"use strict";r.__esModule=!0,r.default=i;var e=S(n(95115)),a=S(n(12972)),t=S(n(16599)),o=n(75573),p=S(n(87031)),b=S(n(57819)),y=S(n(35366));function S(c){return c&&c.__esModule?c:{default:c}}function k(c){return!(0,o.isHTMLElement)(c)||(0,t.default)(c).position==="fixed"?null:c.offsetParent}function h(c){var m=/firefox/i.test((0,y.default)()),l=/Trident/i.test((0,y.default)());if(l&&(0,o.isHTMLElement)(c)){var u=(0,t.default)(c);if(u.position==="fixed")return null}var s=(0,b.default)(c);for((0,o.isShadowRoot)(s)&&(s=s.host);(0,o.isHTMLElement)(s)&&["html","body"].indexOf((0,a.default)(s))<0;){var d=(0,t.default)(s);if(d.transform!=="none"||d.perspective!=="none"||d.contain==="paint"||["transform","perspective"].indexOf(d.willChange)!==-1||m&&d.willChange==="filter"||m&&d.filter&&d.filter!=="none")return s;s=s.parentNode}return null}function i(c){for(var m=(0,e.default)(c),l=k(c);l&&(0,p.default)(l)&&(0,t.default)(l).position==="static";)l=k(l);return l&&((0,a.default)(l)==="html"||(0,a.default)(l)==="body"&&(0,t.default)(l).position==="static")?m:l||h(c)||m}},57819:function(T,r,n){"use strict";r.__esModule=!0,r.default=p;var e=o(n(12972)),a=o(n(40600)),t=n(75573);function o(b){return b&&b.__esModule?b:{default:b}}function p(b){return(0,e.default)(b)==="html"?b:b.assignedSlot||b.parentNode||((0,t.isShadowRoot)(b)?b.host:null)||(0,a.default)(b)}},24426:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(57819)),a=p(n(10798)),t=p(n(12972)),o=n(75573);function p(y){return y&&y.__esModule?y:{default:y}}function b(y){return["html","body","#document"].indexOf((0,t.default)(y))>=0?y.ownerDocument.body:(0,o.isHTMLElement)(y)&&(0,a.default)(y)?y:b((0,e.default)(y))}},87991:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(95115)),a=p(n(40600)),t=p(n(79697)),o=p(n(89331));function p(y){return y&&y.__esModule?y:{default:y}}function b(y,S){var k=(0,e.default)(y),h=(0,a.default)(y),i=k.visualViewport,c=h.clientWidth,m=h.clientHeight,l=0,u=0;if(i){c=i.width,m=i.height;var s=(0,o.default)();(s||!s&&S==="fixed")&&(l=i.offsetLeft,u=i.offsetTop)}return{width:c,height:m,x:l+(0,t.default)(y),y:u}}},95115:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var a=e.ownerDocument;return a&&a.defaultView||window}return e}},43750:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(95115));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){var p=(0,e.default)(o),b=p.pageXOffset,y=p.pageYOffset;return{scrollLeft:b,scrollTop:y}}},79697:function(T,r,n){"use strict";r.__esModule=!0,r.default=p;var e=o(n(37786)),a=o(n(40600)),t=o(n(43750));function o(b){return b&&b.__esModule?b:{default:b}}function p(b){return(0,e.default)((0,a.default)(b)).left+(0,t.default)(b).scrollLeft}},75573:function(T,r,n){"use strict";r.__esModule=!0,r.isElement=t,r.isHTMLElement=o,r.isShadowRoot=p;var e=a(n(95115));function a(b){return b&&b.__esModule?b:{default:b}}function t(b){var y=(0,e.default)(b).Element;return b instanceof y||b instanceof Element}function o(b){var y=(0,e.default)(b).HTMLElement;return b instanceof y||b instanceof HTMLElement}function p(b){if(typeof ShadowRoot=="undefined")return!1;var y=(0,e.default)(b).ShadowRoot;return b instanceof y||b instanceof ShadowRoot}},89331:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(35366));function a(o){return o&&o.__esModule?o:{default:o}}function t(){return!/^((?!chrome|android).)*safari/i.test((0,e.default)())}},10798:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(16599));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){var p=(0,e.default)(o),b=p.overflow,y=p.overflowX,S=p.overflowY;return/auto|scroll|overlay|hidden/.test(b+S+y)}},87031:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(12972));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){return["table","td","th"].indexOf((0,e.default)(o))>=0}},98309:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(24426)),a=p(n(57819)),t=p(n(95115)),o=p(n(10798));function p(y){return y&&y.__esModule?y:{default:y}}function b(y,S){var k;S===void 0&&(S=[]);var h=(0,e.default)(y),i=h===((k=y.ownerDocument)==null?void 0:k.body),c=(0,t.default)(h),m=i?[c].concat(c.visualViewport||[],(0,o.default)(h)?h:[]):h,l=S.concat(m);return i?l:l.concat(b((0,a.default)(m)))}},46206:function(T,r){"use strict";r.__esModule=!0,r.write=r.viewport=r.variationPlacements=r.top=r.start=r.right=r.reference=r.read=r.popper=r.placements=r.modifierPhases=r.main=r.left=r.end=r.clippingParents=r.bottom=r.beforeWrite=r.beforeRead=r.beforeMain=r.basePlacements=r.auto=r.afterWrite=r.afterRead=r.afterMain=void 0;var n=r.top="top",e=r.bottom="bottom",a=r.right="right",t=r.left="left",o=r.auto="auto",p=r.basePlacements=[n,e,a,t],b=r.start="start",y=r.end="end",S=r.clippingParents="clippingParents",k=r.viewport="viewport",h=r.popper="popper",i=r.reference="reference",c=r.variationPlacements=p.reduce(function(B,I){return B.concat([I+"-"+b,I+"-"+y])},[]),m=r.placements=[].concat(p,[o]).reduce(function(B,I){return B.concat([I,I+"-"+b,I+"-"+y])},[]),l=r.beforeRead="beforeRead",u=r.read="read",s=r.afterRead="afterRead",d=r.beforeMain="beforeMain",C=r.main="main",g=r.afterMain="afterMain",v=r.beforeWrite="beforeWrite",f=r.write="write",N=r.afterWrite="afterWrite",V=r.modifierPhases=[l,u,s,d,C,g,v,f,N]},95996:function(T,r,n){"use strict";r.__esModule=!0;var e={popperGenerator:!0,detectOverflow:!0,createPopperBase:!0,createPopper:!0,createPopperLite:!0};r.popperGenerator=r.detectOverflow=r.createPopperLite=r.createPopperBase=r.createPopper=void 0;var a=n(46206);Object.keys(a).forEach(function(y){y==="default"||y==="__esModule"||Object.prototype.hasOwnProperty.call(e,y)||y in r&&r[y]===a[y]||(r[y]=a[y])});var t=n(39805);Object.keys(t).forEach(function(y){y==="default"||y==="__esModule"||Object.prototype.hasOwnProperty.call(e,y)||y in r&&r[y]===t[y]||(r[y]=t[y])});var o=n(96376);r.popperGenerator=o.popperGenerator,r.detectOverflow=o.detectOverflow,r.createPopperBase=o.createPopper;var p=n(83312);r.createPopper=p.createPopper;var b=n(2473);r.createPopperLite=b.createPopper},19975:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=t(n(12972)),a=n(75573);function t(y){return y&&y.__esModule?y:{default:y}}function o(y){var S=y.state;Object.keys(S.elements).forEach(function(k){var h=S.styles[k]||{},i=S.attributes[k]||{},c=S.elements[k];!(0,a.isHTMLElement)(c)||!(0,e.default)(c)||(Object.assign(c.style,h),Object.keys(i).forEach(function(m){var l=i[m];l===!1?c.removeAttribute(m):c.setAttribute(m,l===!0?"":l)}))})}function p(y){var S=y.state,k={popper:{position:S.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(S.elements.popper.style,k.popper),S.styles=k,S.elements.arrow&&Object.assign(S.elements.arrow.style,k.arrow),function(){Object.keys(S.elements).forEach(function(h){var i=S.elements[h],c=S.attributes[h]||{},m=Object.keys(S.styles.hasOwnProperty(h)?S.styles[h]:k[h]),l=m.reduce(function(u,s){return u[s]="",u},{});!(0,a.isHTMLElement)(i)||!(0,e.default)(i)||(Object.assign(i.style,l),Object.keys(c).forEach(function(u){i.removeAttribute(u)}))})}}var b=r.default={name:"applyStyles",enabled:!0,phase:"write",fn:o,effect:p,requires:["computeStyles"]}},52744:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=h(n(83104)),a=h(n(28811)),t=h(n(4206)),o=h(n(44896)),p=h(n(41199)),b=n(28595),y=h(n(43286)),S=h(n(81447)),k=n(46206);function h(u){return u&&u.__esModule?u:{default:u}}var i=function(){function u(s,d){return s=typeof s=="function"?s(Object.assign({},d.rects,{placement:d.placement})):s,(0,y.default)(typeof s!="number"?s:(0,S.default)(s,k.basePlacements))}return u}();function c(u){var s,d=u.state,C=u.name,g=u.options,v=d.elements.arrow,f=d.modifiersData.popperOffsets,N=(0,e.default)(d.placement),V=(0,p.default)(N),B=[k.left,k.right].indexOf(N)>=0,I=B?"height":"width";if(!(!v||!f)){var L=i(g.padding,d),w=(0,a.default)(v),A=V==="y"?k.top:k.left,x=V==="y"?k.bottom:k.right,E=d.rects.reference[I]+d.rects.reference[V]-f[V]-d.rects.popper[I],P=f[V]-d.rects.reference[V],D=(0,o.default)(v),M=D?V==="y"?D.clientHeight||0:D.clientWidth||0:0,O=E/2-P/2,R=L[A],F=M-w[I]-L[x],W=M/2-w[I]/2+O,U=(0,b.within)(R,W,F),z=V;d.modifiersData[C]=(s={},s[z]=U,s.centerOffset=U-W,s)}}function m(u){var s=u.state,d=u.options,C=d.element,g=C===void 0?"[data-popper-arrow]":C;g!=null&&(typeof g=="string"&&(g=s.elements.popper.querySelector(g),!g)||(0,t.default)(s.elements.popper,g)&&(s.elements.arrow=g))}var l=r.default={name:"arrow",enabled:!0,phase:"main",fn:c,effect:m,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]}},59894:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0,r.mapToStyles=c;var e=n(46206),a=k(n(44896)),t=k(n(95115)),o=k(n(40600)),p=k(n(16599)),b=k(n(83104)),y=k(n(45)),S=n(63618);function k(u){return u&&u.__esModule?u:{default:u}}var h={top:"auto",right:"auto",bottom:"auto",left:"auto"};function i(u,s){var d=u.x,C=u.y,g=s.devicePixelRatio||1;return{x:(0,S.round)(d*g)/g||0,y:(0,S.round)(C*g)/g||0}}function c(u){var s,d=u.popper,C=u.popperRect,g=u.placement,v=u.variation,f=u.offsets,N=u.position,V=u.gpuAcceleration,B=u.adaptive,I=u.roundOffsets,L=u.isFixed,w=f.x,A=w===void 0?0:w,x=f.y,E=x===void 0?0:x,P=typeof I=="function"?I({x:A,y:E}):{x:A,y:E};A=P.x,E=P.y;var D=f.hasOwnProperty("x"),M=f.hasOwnProperty("y"),O=e.left,R=e.top,F=window;if(B){var W=(0,a.default)(d),U="clientHeight",z="clientWidth";if(W===(0,t.default)(d)&&(W=(0,o.default)(d),(0,p.default)(W).position!=="static"&&N==="absolute"&&(U="scrollHeight",z="scrollWidth")),W=W,g===e.top||(g===e.left||g===e.right)&&v===e.end){R=e.bottom;var $=L&&W===F&&F.visualViewport?F.visualViewport.height:W[U];E-=$-C.height,E*=V?1:-1}if(g===e.left||(g===e.top||g===e.bottom)&&v===e.end){O=e.right;var G=L&&W===F&&F.visualViewport?F.visualViewport.width:W[z];A-=G-C.width,A*=V?1:-1}}var X=Object.assign({position:N},B&&h),J=I===!0?i({x:A,y:E},(0,t.default)(d)):{x:A,y:E};if(A=J.x,E=J.y,V){var se;return Object.assign({},X,(se={},se[R]=M?"0":"",se[O]=D?"0":"",se.transform=(F.devicePixelRatio||1)<=1?"translate("+A+"px, "+E+"px)":"translate3d("+A+"px, "+E+"px, 0)",se))}return Object.assign({},X,(s={},s[R]=M?E+"px":"",s[O]=D?A+"px":"",s.transform="",s))}function m(u){var s=u.state,d=u.options,C=d.gpuAcceleration,g=C===void 0?!0:C,v=d.adaptive,f=v===void 0?!0:v,N=d.roundOffsets,V=N===void 0?!0:N,B={placement:(0,b.default)(s.placement),variation:(0,y.default)(s.placement),popper:s.elements.popper,popperRect:s.rects.popper,gpuAcceleration:g,isFixed:s.options.strategy==="fixed"};s.modifiersData.popperOffsets!=null&&(s.styles.popper=Object.assign({},s.styles.popper,c(Object.assign({},B,{offsets:s.modifiersData.popperOffsets,position:s.options.strategy,adaptive:f,roundOffsets:V})))),s.modifiersData.arrow!=null&&(s.styles.arrow=Object.assign({},s.styles.arrow,c(Object.assign({},B,{offsets:s.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:V})))),s.attributes.popper=Object.assign({},s.attributes.popper,{"data-popper-placement":s.placement})}var l=r.default={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:m,data:{}}},36692:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=a(n(95115));function a(b){return b&&b.__esModule?b:{default:b}}var t={passive:!0};function o(b){var y=b.state,S=b.instance,k=b.options,h=k.scroll,i=h===void 0?!0:h,c=k.resize,m=c===void 0?!0:c,l=(0,e.default)(y.elements.popper),u=[].concat(y.scrollParents.reference,y.scrollParents.popper);return i&&u.forEach(function(s){s.addEventListener("scroll",S.update,t)}),m&&l.addEventListener("resize",S.update,t),function(){i&&u.forEach(function(s){s.removeEventListener("scroll",S.update,t)}),m&&l.removeEventListener("resize",S.update,t)}}var p=r.default={name:"eventListeners",enabled:!0,phase:"write",fn:function(){function b(){}return b}(),effect:o,data:{}}},23798:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=S(n(71376)),a=S(n(83104)),t=S(n(86459)),o=S(n(17633)),p=S(n(9041)),b=n(46206),y=S(n(45));function S(c){return c&&c.__esModule?c:{default:c}}function k(c){if((0,a.default)(c)===b.auto)return[];var m=(0,e.default)(c);return[(0,t.default)(c),m,(0,t.default)(m)]}function h(c){var m=c.state,l=c.options,u=c.name;if(!m.modifiersData[u]._skip){for(var s=l.mainAxis,d=s===void 0?!0:s,C=l.altAxis,g=C===void 0?!0:C,v=l.fallbackPlacements,f=l.padding,N=l.boundary,V=l.rootBoundary,B=l.altBoundary,I=l.flipVariations,L=I===void 0?!0:I,w=l.allowedAutoPlacements,A=m.options.placement,x=(0,a.default)(A),E=x===A,P=v||(E||!L?[(0,e.default)(A)]:k(A)),D=[A].concat(P).reduce(function(ne,te){return ne.concat((0,a.default)(te)===b.auto?(0,p.default)(m,{placement:te,boundary:N,rootBoundary:V,padding:f,flipVariations:L,allowedAutoPlacements:w}):te)},[]),M=m.rects.reference,O=m.rects.popper,R=new Map,F=!0,W=D[0],U=0;U=0,J=X?"width":"height",se=(0,o.default)(m,{placement:z,boundary:N,rootBoundary:V,altBoundary:B,padding:f}),ie=X?G?b.right:b.left:G?b.bottom:b.top;M[J]>O[J]&&(ie=(0,e.default)(ie));var me=(0,e.default)(ie),q=[];if(d&&q.push(se[$]<=0),g&&q.push(se[ie]<=0,se[me]<=0),q.every(function(ne){return ne})){W=z,F=!1;break}R.set(z,q)}if(F)for(var re=L?3:1,ae=function(){function ne(te){var fe=D.find(function(pe){var ce=R.get(pe);if(ce)return ce.slice(0,te).every(function(Ve){return Ve})});if(fe)return W=fe,"break"}return ne}(),le=re;le>0;le--){var Z=ae(le);if(Z==="break")break}m.placement!==W&&(m.modifiersData[u]._skip=!0,m.placement=W,m.reset=!0)}}var i=r.default={name:"flip",enabled:!0,phase:"main",fn:h,requiresIfExists:["offset"],data:{_skip:!1}}},83761:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=n(46206),a=t(n(17633));function t(S){return S&&S.__esModule?S:{default:S}}function o(S,k,h){return h===void 0&&(h={x:0,y:0}),{top:S.top-k.height-h.y,right:S.right-k.width+h.x,bottom:S.bottom-k.height+h.y,left:S.left-k.width-h.x}}function p(S){return[e.top,e.right,e.bottom,e.left].some(function(k){return S[k]>=0})}function b(S){var k=S.state,h=S.name,i=k.rects.reference,c=k.rects.popper,m=k.modifiersData.preventOverflow,l=(0,a.default)(k,{elementContext:"reference"}),u=(0,a.default)(k,{altBoundary:!0}),s=o(l,i),d=o(u,c,m),C=p(s),g=p(d);k.modifiersData[h]={referenceClippingOffsets:s,popperEscapeOffsets:d,isReferenceHidden:C,hasPopperEscaped:g},k.attributes.popper=Object.assign({},k.attributes.popper,{"data-popper-reference-hidden":C,"data-popper-escaped":g})}var y=r.default={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:b}},39805:function(T,r,n){"use strict";r.__esModule=!0,r.preventOverflow=r.popperOffsets=r.offset=r.hide=r.flip=r.eventListeners=r.computeStyles=r.arrow=r.applyStyles=void 0;var e=h(n(19975));r.applyStyles=e.default;var a=h(n(52744));r.arrow=a.default;var t=h(n(59894));r.computeStyles=t.default;var o=h(n(36692));r.eventListeners=o.default;var p=h(n(23798));r.flip=p.default;var b=h(n(83761));r.hide=b.default;var y=h(n(61410));r.offset=y.default;var S=h(n(40107));r.popperOffsets=S.default;var k=h(n(75137));r.preventOverflow=k.default;function h(i){return i&&i.__esModule?i:{default:i}}},61410:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0,r.distanceAndSkiddingToXY=o;var e=t(n(83104)),a=n(46206);function t(y){return y&&y.__esModule?y:{default:y}}function o(y,S,k){var h=(0,e.default)(y),i=[a.left,a.top].indexOf(h)>=0?-1:1,c=typeof k=="function"?k(Object.assign({},S,{placement:y})):k,m=c[0],l=c[1];return m=m||0,l=(l||0)*i,[a.left,a.right].indexOf(h)>=0?{x:l,y:m}:{x:m,y:l}}function p(y){var S=y.state,k=y.options,h=y.name,i=k.offset,c=i===void 0?[0,0]:i,m=a.placements.reduce(function(d,C){return d[C]=o(C,S.rects,c),d},{}),l=m[S.placement],u=l.x,s=l.y;S.modifiersData.popperOffsets!=null&&(S.modifiersData.popperOffsets.x+=u,S.modifiersData.popperOffsets.y+=s),S.modifiersData[h]=m}var b=r.default={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:p}},40107:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=a(n(89951));function a(p){return p&&p.__esModule?p:{default:p}}function t(p){var b=p.state,y=p.name;b.modifiersData[y]=(0,e.default)({reference:b.rects.reference,element:b.rects.popper,strategy:"absolute",placement:b.placement})}var o=r.default={name:"popperOffsets",enabled:!0,phase:"read",fn:t,data:{}}},75137:function(T,r,n){"use strict";r.__esModule=!0,r.default=void 0;var e=n(46206),a=c(n(83104)),t=c(n(41199)),o=c(n(28066)),p=n(28595),b=c(n(28811)),y=c(n(44896)),S=c(n(17633)),k=c(n(45)),h=c(n(34780)),i=n(63618);function c(u){return u&&u.__esModule?u:{default:u}}function m(u){var s=u.state,d=u.options,C=u.name,g=d.mainAxis,v=g===void 0?!0:g,f=d.altAxis,N=f===void 0?!1:f,V=d.boundary,B=d.rootBoundary,I=d.altBoundary,L=d.padding,w=d.tether,A=w===void 0?!0:w,x=d.tetherOffset,E=x===void 0?0:x,P=(0,S.default)(s,{boundary:V,rootBoundary:B,padding:L,altBoundary:I}),D=(0,a.default)(s.placement),M=(0,k.default)(s.placement),O=!M,R=(0,t.default)(D),F=(0,o.default)(R),W=s.modifiersData.popperOffsets,U=s.rects.reference,z=s.rects.popper,$=typeof E=="function"?E(Object.assign({},s.rects,{placement:s.placement})):E,G=typeof $=="number"?{mainAxis:$,altAxis:$}:Object.assign({mainAxis:0,altAxis:0},$),X=s.modifiersData.offset?s.modifiersData.offset[s.placement]:null,J={x:0,y:0};if(W){if(v){var se,ie=R==="y"?e.top:e.left,me=R==="y"?e.bottom:e.right,q=R==="y"?"height":"width",re=W[R],ae=re+P[ie],le=re-P[me],Z=A?-z[q]/2:0,ne=M===e.start?U[q]:z[q],te=M===e.start?-z[q]:-U[q],fe=s.elements.arrow,pe=A&&fe?(0,b.default)(fe):{width:0,height:0},ce=s.modifiersData["arrow#persistent"]?s.modifiersData["arrow#persistent"].padding:(0,h.default)(),Ve=ce[ie],Ce=ce[me],Ne=(0,p.within)(0,U[q],pe[q]),Be=O?U[q]/2-Z-Ne-Ve-G.mainAxis:ne-Ne-Ve-G.mainAxis,be=O?-U[q]/2+Z+Ne+Ce+G.mainAxis:te+Ne+Ce+G.mainAxis,Le=s.elements.arrow&&(0,y.default)(s.elements.arrow),we=Le?R==="y"?Le.clientTop||0:Le.clientLeft||0:0,xe=(se=X==null?void 0:X[R])!=null?se:0,Re=re+Be-xe-we,He=re+be-xe,ye=(0,p.within)(A?(0,i.min)(ae,Re):ae,re,A?(0,i.max)(le,He):le);W[R]=ye,J[R]=ye-re}if(N){var de,he=R==="x"?e.top:e.left,ke=R==="x"?e.bottom:e.right,ve=W[F],Se=F==="y"?"height":"width",Pe=ve+P[he],je=ve-P[ke],Fe=[e.top,e.left].indexOf(D)!==-1,ze=(de=X==null?void 0:X[F])!=null?de:0,We=Fe?Pe:ve-U[Se]-z[Se]-ze+G.altAxis,Ue=Fe?ve+U[Se]+z[Se]-ze-G.altAxis:je,Xe=A&&Fe?(0,p.withinMaxClamp)(We,ve,Ue):(0,p.within)(A?We:Pe,ve,A?Ue:je);W[F]=Xe,J[F]=Xe-ve}s.modifiersData[C]=J}}var l=r.default={name:"preventOverflow",enabled:!0,phase:"main",fn:m,requiresIfExists:["offset"]}},2473:function(T,r,n){"use strict";r.__esModule=!0,r.defaultModifiers=r.createPopper=void 0;var e=n(96376);r.popperGenerator=e.popperGenerator,r.detectOverflow=e.detectOverflow;var a=b(n(36692)),t=b(n(40107)),o=b(n(59894)),p=b(n(19975));function b(k){return k&&k.__esModule?k:{default:k}}var y=r.defaultModifiers=[a.default,t.default,o.default,p.default],S=r.createPopper=(0,e.popperGenerator)({defaultModifiers:y})},83312:function(T,r,n){"use strict";r.__esModule=!0;var e={createPopper:!0,createPopperLite:!0,defaultModifiers:!0,popperGenerator:!0,detectOverflow:!0};r.defaultModifiers=r.createPopperLite=r.createPopper=void 0;var a=n(96376);r.popperGenerator=a.popperGenerator,r.detectOverflow=a.detectOverflow;var t=l(n(36692)),o=l(n(40107)),p=l(n(59894)),b=l(n(19975)),y=l(n(61410)),S=l(n(23798)),k=l(n(75137)),h=l(n(52744)),i=l(n(83761)),c=n(2473);r.createPopperLite=c.createPopper;var m=n(39805);Object.keys(m).forEach(function(d){d==="default"||d==="__esModule"||Object.prototype.hasOwnProperty.call(e,d)||d in r&&r[d]===m[d]||(r[d]=m[d])});function l(d){return d&&d.__esModule?d:{default:d}}var u=r.defaultModifiers=[t.default,o.default,p.default,b.default,y.default,S.default,k.default,h.default,i.default],s=r.createPopperLite=r.createPopper=(0,a.popperGenerator)({defaultModifiers:u})},9041:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(45)),a=n(46206),t=p(n(17633)),o=p(n(83104));function p(y){return y&&y.__esModule?y:{default:y}}function b(y,S){S===void 0&&(S={});var k=S,h=k.placement,i=k.boundary,c=k.rootBoundary,m=k.padding,l=k.flipVariations,u=k.allowedAutoPlacements,s=u===void 0?a.placements:u,d=(0,e.default)(h),C=d?l?a.variationPlacements:a.variationPlacements.filter(function(f){return(0,e.default)(f)===d}):a.basePlacements,g=C.filter(function(f){return s.indexOf(f)>=0});g.length===0&&(g=C);var v=g.reduce(function(f,N){return f[N]=(0,t.default)(y,{placement:N,boundary:i,rootBoundary:c,padding:m})[(0,o.default)(N)],f},{});return Object.keys(v).sort(function(f,N){return v[f]-v[N]})}},89951:function(T,r,n){"use strict";r.__esModule=!0,r.default=b;var e=p(n(83104)),a=p(n(45)),t=p(n(41199)),o=n(46206);function p(y){return y&&y.__esModule?y:{default:y}}function b(y){var S=y.reference,k=y.element,h=y.placement,i=h?(0,e.default)(h):null,c=h?(0,a.default)(h):null,m=S.x+S.width/2-k.width/2,l=S.y+S.height/2-k.height/2,u;switch(i){case o.top:u={x:m,y:S.y-k.height};break;case o.bottom:u={x:m,y:S.y+S.height};break;case o.right:u={x:S.x+S.width,y:l};break;case o.left:u={x:S.x-k.width,y:l};break;default:u={x:S.x,y:S.y}}var s=i?(0,t.default)(i):null;if(s!=null){var d=s==="y"?"height":"width";switch(c){case o.start:u[s]=u[s]-(S[d]/2-k[d]/2);break;case o.end:u[s]=u[s]+(S[d]/2-k[d]/2);break;default:}}return u}},10579:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){var a;return function(){return a||(a=new Promise(function(t){Promise.resolve().then(function(){a=void 0,t(e())})})),a}}},17633:function(T,r,n){"use strict";r.__esModule=!0,r.default=i;var e=h(n(49035)),a=h(n(40600)),t=h(n(37786)),o=h(n(89951)),p=h(n(81666)),b=n(46206),y=n(75573),S=h(n(43286)),k=h(n(81447));function h(c){return c&&c.__esModule?c:{default:c}}function i(c,m){m===void 0&&(m={});var l=m,u=l.placement,s=u===void 0?c.placement:u,d=l.strategy,C=d===void 0?c.strategy:d,g=l.boundary,v=g===void 0?b.clippingParents:g,f=l.rootBoundary,N=f===void 0?b.viewport:f,V=l.elementContext,B=V===void 0?b.popper:V,I=l.altBoundary,L=I===void 0?!1:I,w=l.padding,A=w===void 0?0:w,x=(0,S.default)(typeof A!="number"?A:(0,k.default)(A,b.basePlacements)),E=B===b.popper?b.reference:b.popper,P=c.rects.popper,D=c.elements[L?E:B],M=(0,e.default)((0,y.isElement)(D)?D:D.contextElement||(0,a.default)(c.elements.popper),v,N,C),O=(0,t.default)(c.elements.reference),R=(0,o.default)({reference:O,element:P,strategy:"absolute",placement:s}),F=(0,p.default)(Object.assign({},P,R)),W=B===b.popper?F:O,U={top:M.top-W.top+x.top,bottom:W.bottom-M.bottom+x.bottom,left:M.left-W.left+x.left,right:W.right-M.right+x.right},z=c.modifiersData.offset;if(B===b.popper&&z){var $=z[s];Object.keys(U).forEach(function(G){var X=[b.right,b.bottom].indexOf(G)>=0?1:-1,J=[b.top,b.bottom].indexOf(G)>=0?"y":"x";U[G]+=$[J]*X})}return U}},81447:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e,a){return a.reduce(function(t,o){return t[o]=e,t},{})}},28066:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return e==="x"?"y":"x"}},83104:function(T,r,n){"use strict";r.__esModule=!0,r.default=a;var e=n(46206);function a(t){return t.split("-")[0]}},34780:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(){return{top:0,right:0,bottom:0,left:0}}},41199:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}},71376:function(T,r){"use strict";r.__esModule=!0,r.default=e;var n={left:"right",right:"left",bottom:"top",top:"bottom"};function e(a){return a.replace(/left|right|bottom|top/g,function(t){return n[t]})}},86459:function(T,r){"use strict";r.__esModule=!0,r.default=e;var n={start:"end",end:"start"};function e(a){return a.replace(/start|end/g,function(t){return n[t]})}},45:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return e.split("-")[1]}},63618:function(T,r){"use strict";r.__esModule=!0,r.round=r.min=r.max=void 0;var n=r.max=Math.max,e=r.min=Math.min,a=r.round=Math.round},56500:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){var a=e.reduce(function(t,o){var p=t[o.name];return t[o.name]=p?Object.assign({},p,o,{options:Object.assign({},p.options,o.options),data:Object.assign({},p.data,o.data)}):o,t},{});return Object.keys(a).map(function(t){return a[t]})}},43286:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=a(n(34780));function a(o){return o&&o.__esModule?o:{default:o}}function t(o){return Object.assign({},(0,e.default)(),o)}},33118:function(T,r,n){"use strict";r.__esModule=!0,r.default=t;var e=n(46206);function a(o){var p=new Map,b=new Set,y=[];o.forEach(function(k){p.set(k.name,k)});function S(k){b.add(k.name);var h=[].concat(k.requires||[],k.requiresIfExists||[]);h.forEach(function(i){if(!b.has(i)){var c=p.get(i);c&&S(c)}}),y.push(k)}return o.forEach(function(k){b.has(k.name)||S(k)}),y}function t(o){var p=a(o);return e.modifierPhases.reduce(function(b,y){return b.concat(p.filter(function(S){return S.phase===y}))},[])}},81666:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}},35366:function(T,r){"use strict";r.__esModule=!0,r.default=n;function n(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(a){return a.brand+"/"+a.version}).join(" "):navigator.userAgent}},28595:function(T,r,n){"use strict";r.__esModule=!0,r.within=a,r.withinMaxClamp=t;var e=n(63618);function a(o,p,b){return(0,e.max)(o,(0,e.min)(p,b))}function t(o,p,b){var y=a(o,p,b);return y>b?b:y}},15875:function(T,r){"use strict";r.__esModule=!0,r.VNodeFlags=r.ChildFlags=void 0;var n;(function(a){a[a.Unknown=0]="Unknown",a[a.HtmlElement=1]="HtmlElement",a[a.ComponentUnknown=2]="ComponentUnknown",a[a.ComponentClass=4]="ComponentClass",a[a.ComponentFunction=8]="ComponentFunction",a[a.Text=16]="Text",a[a.SvgElement=32]="SvgElement",a[a.InputElement=64]="InputElement",a[a.TextareaElement=128]="TextareaElement",a[a.SelectElement=256]="SelectElement",a[a.Portal=1024]="Portal",a[a.ReCreate=2048]="ReCreate",a[a.ContentEditable=4096]="ContentEditable",a[a.Fragment=8192]="Fragment",a[a.InUse=16384]="InUse",a[a.ForwardRef=32768]="ForwardRef",a[a.Normalized=65536]="Normalized",a[a.ForwardRefComponent=32776]="ForwardRefComponent",a[a.FormElement=448]="FormElement",a[a.Element=481]="Element",a[a.Component=14]="Component",a[a.DOMRef=1521]="DOMRef",a[a.InUseOrNormalized=81920]="InUseOrNormalized",a[a.ClearInUse=-16385]="ClearInUse",a[a.ComponentKnown=12]="ComponentKnown"})(n||(r.VNodeFlags=n={}));var e;(function(a){a[a.UnknownChildren=0]="UnknownChildren",a[a.HasInvalidChildren=1]="HasInvalidChildren",a[a.HasVNodeChildren=2]="HasVNodeChildren",a[a.HasNonKeyedChildren=4]="HasNonKeyedChildren",a[a.HasKeyedChildren=8]="HasKeyedChildren",a[a.HasTextChildren=16]="HasTextChildren",a[a.MultipleChildren=12]="MultipleChildren"})(e||(r.ChildFlags=e={}))},89292:function(T,r){"use strict";r.__esModule=!0,r.Fragment=r.EMPTY_OBJ=r.Component=r.AnimationQueues=void 0,r._CI=Ot,r._HI=pe,r._M=Ke,r._MCCC=Ft,r._ME=Dt,r._MFCC=_t,r._MP=Mt,r._MR=at,r._RFC=gt,r.__render=Ht,r.createComponentVNode=se,r.createFragment=me,r.createPortal=Z,r.createRef=nn,r.createRenderer=En,r.createTextVNode=ie,r.createVNode=$,r.directClone=ae,r.findDOMFromVNode=V,r.forwardRef=on,r.getFlagsForElementVnode=te,r.linkEvent=h,r.normalizeProps=q,r.options=void 0,r.render=zt,r.rerender=$t,r.version=void 0;var n=Array.isArray;function e(j){var _=typeof j;return _==="string"||_==="number"}function a(j){return j==null}function t(j){return j===null||j===!1||j===!0||j===void 0}function o(j){return typeof j=="function"}function p(j){return typeof j=="string"}function b(j){return typeof j=="number"}function y(j){return j===null}function S(j){return j===void 0}function k(j,_){var H={};if(j)for(var K in j)H[K]=j[K];if(_)for(var Q in _)H[Q]=_[Q];return H}function h(j,_){return o(_)?{data:j,event:_}:null}function i(j){return!y(j)&&typeof j=="object"}var c=r.EMPTY_OBJ={},m=r.Fragment="$F",l=r.AnimationQueues=function(){function j(){this.componentDidAppear=[],this.componentWillDisappear=[],this.componentWillMove=[]}return j}();function u(j){return j.substring(2).toLowerCase()}function s(j,_){j.appendChild(_)}function d(j,_,H){y(H)?s(j,_):j.insertBefore(_,H)}function C(j,_){return _?document.createElementNS("http://www.w3.org/2000/svg",j):document.createElement(j)}function g(j,_,H){j.replaceChild(_,H)}function v(j,_){j.removeChild(_)}function f(j){for(var _=0;_0?B(H.componentWillDisappear,w(j,_)):L(j,_,!1)}function x(j,_,H,K,Q,ee,oe,ue){j.componentWillMove.push({dom:K,fn:function(){function ge(){oe&4?H.componentWillMove(_,Q,K):oe&8&&H.onComponentWillMove(_,Q,K,ue)}return ge}(),next:ee,parent:Q})}function E(j,_,H,K,Q){var ee,oe,ue=_.flags;do{var ge=_.flags;if(ge&1521){!a(ee)&&(o(ee.componentWillMove)||o(ee.onComponentWillMove))?x(Q,j,ee,_.dom,H,K,ue,oe):d(H,_.dom,K);return}var Te=_.children;if(ge&4)ee=_.children,oe=_.props,_=Te.$LI;else if(ge&8)ee=_.ref,oe=_.props,_=Te;else if(ge&8192)if(_.childFlags===2)_=Te;else{for(var Ie=0,Ee=Te.length;Ie0,Te=y(ue),Ie=p(ue)&&ue[0]===U;ge||Te||Ie?(H=H||_.slice(0,ee),(ge||Ie)&&(oe=ae(oe)),(Te||Ie)&&(oe.key=U+ee),H.push(oe)):H&&H.push(oe),oe.flags|=65536}}H=H||_,H.length===0?K=1:K=8}else H=_,H.flags|=65536,_.flags&81920&&(H=ae(_)),K=2;return j.children=H,j.childFlags=K,j}function pe(j){return t(j)||e(j)?ie(j,null):n(j)?me(j,0,null):j.flags&16384?ae(j):j}var ce="http://www.w3.org/1999/xlink",Ve="http://www.w3.org/XML/1998/namespace",Ce={"xlink:actuate":ce,"xlink:arcrole":ce,"xlink:href":ce,"xlink:role":ce,"xlink:show":ce,"xlink:title":ce,"xlink:type":ce,"xml:base":Ve,"xml:lang":Ve,"xml:space":Ve};function Ne(j){return{onClick:j,onDblClick:j,onFocusIn:j,onFocusOut:j,onKeyDown:j,onKeyPress:j,onKeyUp:j,onMouseDown:j,onMouseMove:j,onMouseUp:j,onTouchEnd:j,onTouchMove:j,onTouchStart:j}}var Be=Ne(0),be=Ne(null),Le=Ne(!0);function we(j,_){var H=_.$EV;return H||(H=_.$EV=Ne(null)),H[j]||++Be[j]===1&&(be[j]=je(j)),H}function xe(j,_){var H=_.$EV;H&&H[j]&&(--Be[j]===0&&(document.removeEventListener(u(j),be[j]),be[j]=null),H[j]=null)}function Re(j,_,H,K){if(o(H))we(j,K)[j]=H;else if(i(H)){if(R(_,H))return;we(j,K)[j]=H}else xe(j,K)}function He(j){return o(j.composedPath)?j.composedPath()[0]:j.target}function ye(j,_,H,K){var Q=He(j);do{if(_&&Q.disabled)return;var ee=Q.$EV;if(ee){var oe=ee[H];if(oe&&(K.dom=Q,oe.event?oe.event(oe.data,j):oe(j),j.cancelBubble))return}Q=Q.parentNode}while(!y(Q))}function de(){this.cancelBubble=!0,this.immediatePropagationStopped||this.stopImmediatePropagation()}function he(){return this.defaultPrevented}function ke(){return this.cancelBubble}function ve(j){var _={dom:document};return j.isDefaultPrevented=he,j.isPropagationStopped=ke,j.stopPropagation=de,Object.defineProperty(j,"currentTarget",{configurable:!0,get:function(){function H(){return _.dom}return H}()}),_}function Se(j){return function(_){if(_.button!==0){_.stopPropagation();return}ye(_,!0,j,ve(_))}}function Pe(j){return function(_){ye(_,!1,j,ve(_))}}function je(j){var _=j==="onClick"||j==="onDblClick"?Se(j):Pe(j);return document.addEventListener(u(j),_),_}function Fe(j,_){var H=document.createElement("i");return H.innerHTML=_,H.innerHTML===j.innerHTML}function ze(j,_,H){if(j[_]){var K=j[_];K.event?K.event(K.data,H):K(H)}else{var Q=_.toLowerCase();j[Q]&&j[Q](H)}}function We(j,_){var H=function(){function K(Q){var ee=this.$V;if(ee){var oe=ee.props||c,ue=ee.dom;if(p(j))ze(oe,j,Q);else for(var ge=0;ge-1&&_.options[ee]&&(ue=_.options[ee].value),H&&a(ue)&&(ue=j.defaultValue),rt(K,ue)}}var Zt=We("onInput",Tt),qt=We("onChange");function en(j,_){Ue(j,"input",Zt),_.onChange&&Ue(j,"change",qt)}function Tt(j,_,H){var K=j.value,Q=_.value;if(a(K)){if(H){var ee=j.defaultValue;!a(ee)&&ee!==Q&&(_.defaultValue=ee,_.value=ee)}}else Q!==K&&(_.defaultValue=K,_.value=K)}function xt(j,_,H,K,Q,ee){j&64?ut(K,H):j&256?wt(K,H,Q,_):j&128&&Tt(K,H,Q),ee&&(H.$V=_)}function tn(j,_,H){j&64?Bt(_,H):j&256?Qt(_):j&128&&en(_,H)}function At(j){return j.type&&Xe(j.type)?!a(j.checked):!a(j.value)}function nn(){return{current:null}}function on(j){var _={render:j};return _}function st(j){j&&!W(j,null)&&j.current&&(j.current=null)}function at(j,_,H){j&&(o(j)||j.current!==void 0)&&H.push(function(){!W(j,_)&&j.current!==void 0&&(j.current=_)})}function Je(j,_,H){Ze(j,H),A(j,_,H)}function Ze(j,_){var H=j.flags,K=j.children,Q;if(H&481){Q=j.ref;var ee=j.props;st(Q);var oe=j.childFlags;if(!y(ee))for(var ue=Object.keys(ee),ge=0,Te=ue.length;ge0?B(H.componentWillDisappear,rn(_,j)):j.textContent=""}function pt(j,_,H,K){ct(H,K),_.flags&8192?A(_,j,K):mt(j,H,K)}function Et(j,_,H,K,Q){j.componentWillDisappear.push(function(ee){K&4?_.componentWillDisappear(H,ee):K&8&&_.onComponentWillDisappear(H,Q,ee)})}function an(j){var _=j.event;return function(H){_(j.data,H)}}function cn(j,_,H,K){if(i(H)){if(R(_,H))return;H=an(H)}Ue(K,u(j),H)}function ln(j,_,H){if(a(_)){H.removeAttribute("style");return}var K=H.style,Q,ee;if(p(_)){K.cssText=_;return}if(!a(j)&&!p(j)){for(Q in _)ee=_[Q],ee!==j[Q]&&K.setProperty(Q,ee);for(Q in j)a(_[Q])&&K.removeProperty(Q)}else for(Q in _)ee=_[Q],K.setProperty(Q,ee)}function dn(j,_,H,K,Q){var ee=j&&j.__html||"",oe=_&&_.__html||"";ee!==oe&&!a(oe)&&!Fe(K,oe)&&(y(H)||(H.childFlags&12?ct(H.children,Q):H.childFlags===2&&Ze(H.children,Q),H.children=null,H.childFlags=1),K.innerHTML=oe)}function vt(j,_,H,K,Q,ee,oe,ue){switch(j){case"children":case"childrenType":case"className":case"defaultValue":case"key":case"multiple":case"ref":case"selectedIndex":break;case"autoFocus":K.autofocus=!!H;break;case"allowfullscreen":case"autoplay":case"capture":case"checked":case"controls":case"default":case"disabled":case"hidden":case"indeterminate":case"loop":case"muted":case"novalidate":case"open":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"selected":K[j]=!!H;break;case"defaultChecked":case"value":case"volume":if(ee&&j==="value")break;var ge=a(H)?"":H;K[j]!==ge&&(K[j]=ge);break;case"style":ln(_,H,K);break;case"dangerouslySetInnerHTML":dn(_,H,oe,K,ue);break;default:Le[j]?Re(j,_,H,K):j.charCodeAt(0)===111&&j.charCodeAt(1)===110?cn(j,_,H,K):a(H)?K.removeAttribute(j):Q&&Ce[j]?K.setAttributeNS(Ce[j],j,H):K.setAttribute(j,H);break}}function Mt(j,_,H,K,Q,ee){var oe=!1,ue=(_&448)>0;ue&&(oe=At(H),oe&&tn(_,K,H));for(var ge in H)vt(ge,null,H[ge],K,Q,oe,null,ee);ue&&xt(_,j,K,H,!0,oe)}function Pt(j,_,H){var K=pe(j.render(_,j.state,H)),Q=H;return o(j.getChildContext)&&(Q=k(H,j.getChildContext())),j.$CX=Q,K}function Ot(j,_,H,K,Q,ee){var oe=new _(H,K),ue=oe.$N=!!(_.getDerivedStateFromProps||oe.getSnapshotBeforeUpdate);if(oe.$SVG=Q,oe.$L=ee,j.children=oe,oe.$BS=!1,oe.context=K,oe.props===c&&(oe.props=H),ue)oe.state=P(oe,H,oe.state);else if(o(oe.componentWillMount)){oe.$BR=!0,oe.componentWillMount();var ge=oe.$PS;if(!y(ge)){var Te=oe.state;if(y(Te))oe.state=ge;else for(var Ie in ge)Te[Ie]=ge[Ie];oe.$PS=null}oe.$BR=!1}return oe.$LI=Pt(oe,H,K),oe}function gt(j,_){var H=j.props||c;return j.flags&32768?j.type.render(H,j.ref,_):j.type(H,_)}function Ke(j,_,H,K,Q,ee,oe){var ue=j.flags|=16384;ue&481?Dt(j,_,H,K,Q,ee,oe):ue&4?mn(j,_,H,K,Q,ee,oe):ue&8?pn(j,_,H,K,Q,ee,oe):ue&16?Rt(j,_,Q):ue&8192?sn(j,H,_,K,Q,ee,oe):ue&1024&&un(j,H,_,Q,ee,oe)}function un(j,_,H,K,Q,ee){Ke(j.children,j.ref,_,!1,null,Q,ee);var oe=le();Rt(oe,H,K),j.dom=oe.dom}function sn(j,_,H,K,Q,ee,oe){var ue=j.children,ge=j.childFlags;ge&12&&ue.length===0&&(ge=j.childFlags=2,ue=j.children=le()),ge===2?Ke(ue,H,_,K,Q,ee,oe):ot(ue,H,_,K,Q,ee,oe)}function Rt(j,_,H){var K=j.dom=document.createTextNode(j.children);y(_)||d(_,K,H)}function Dt(j,_,H,K,Q,ee,oe){var ue=j.flags,ge=j.props,Te=j.className,Ie=j.childFlags,Ee=j.dom=C(j.type,K=K||(ue&32)>0),Ae=j.children;if(!a(Te)&&Te!==""&&(K?Ee.setAttribute("class",Te):Ee.className=Te),Ie===16)O(Ee,Ae);else if(Ie!==1){var Me=K&&j.type!=="foreignObject";Ie===2?(Ae.flags&16384&&(j.children=Ae=ae(Ae)),Ke(Ae,Ee,H,Me,null,ee,oe)):(Ie===8||Ie===4)&&ot(Ae,Ee,H,Me,null,ee,oe)}y(_)||d(_,Ee,Q),y(ge)||Mt(j,ue,ge,Ee,K,oe),at(j.ref,Ee,ee)}function ot(j,_,H,K,Q,ee,oe){for(var ue=0;ueMe)&&(Ee=V(ue[Me-1],!1).nextSibling)}Nt(Te,Ie,ue,ge,H,K,Q,Ee,j,ee,oe)}function Vn(j,_,H,K,Q){var ee=j.ref,oe=_.ref,ue=_.children;if(Nt(j.childFlags,_.childFlags,j.children,ue,ee,H,!1,null,j,K,Q),_.dom=j.dom,ee!==oe&&!t(ue)){var ge=ue.dom;v(ee,ge),s(oe,ge)}}function bn(j,_,H,K,Q,ee,oe){var ue=_.dom=j.dom,ge=j.props,Te=_.props,Ie=!1,Ee=!1,Ae;if(K=K||(Q&32)>0,ge!==Te){var Me=ge||c;if(Ae=Te||c,Ae!==c){Ie=(Q&448)>0,Ie&&(Ee=At(Ae));for(var _e in Ae){var Oe=Me[_e],$e=Ae[_e];Oe!==$e&&vt(_e,Oe,$e,ue,K,Ee,j,oe)}}if(Me!==c)for(var De in Me)a(Ae[De])&&!a(Me[De])&&vt(De,Me[De],null,ue,K,Ee,j,oe)}var tt=_.children,Ye=_.className;j.className!==Ye&&(a(Ye)?ue.removeAttribute("class"):K?ue.setAttribute("class",Ye):ue.className=Ye),Q&4096?gn(ue,tt):Nt(j.childFlags,_.childFlags,j.children,tt,ue,H,K&&_.type!=="foreignObject",null,j,ee,oe),Ie&&xt(Q,_,ue,Ae,!1,Ee);var it=_.ref,Qe=j.ref;Qe!==it&&(st(Qe),at(it,ue,ee))}function kn(j,_,H,K,Q,ee,oe){Ze(j,oe),ot(_,H,K,Q,V(j,!0),ee,oe),A(j,H,oe)}function Nt(j,_,H,K,Q,ee,oe,ue,ge,Te,Ie){switch(j){case 2:switch(_){case 2:qe(H,K,Q,ee,oe,ue,Te,Ie);break;case 1:Je(H,Q,Ie);break;case 16:Ze(H,Ie),O(Q,K);break;default:kn(H,K,Q,ee,oe,Te,Ie);break}break;case 1:switch(_){case 2:Ke(K,Q,ee,oe,ue,Te,Ie);break;case 1:break;case 16:O(Q,K);break;default:ot(K,Q,ee,oe,ue,Te,Ie);break}break;case 16:switch(_){case 16:vn(H,K,Q);break;case 2:mt(Q,H,Ie),Ke(K,Q,ee,oe,ue,Te,Ie);break;case 1:mt(Q,H,Ie);break;default:mt(Q,H,Ie),ot(K,Q,ee,oe,ue,Te,Ie);break}break;default:switch(_){case 16:ct(H,Ie),O(Q,K);break;case 2:pt(Q,ge,H,Ie),Ke(K,Q,ee,oe,ue,Te,Ie);break;case 1:pt(Q,ge,H,Ie);break;default:var Ee=H.length|0,Ae=K.length|0;Ee===0?Ae>0&&ot(K,Q,ee,oe,ue,Te,Ie):Ae===0?pt(Q,ge,H,Ie):_===8&&j===8?wn(H,K,Q,ee,oe,Ee,Ae,ue,ge,Te,Ie):Ln(H,K,Q,ee,oe,Ee,Ae,ue,Te,Ie);break}break}}function yn(j,_,H,K,Q){Q.push(function(){j.componentDidUpdate(_,H,K)})}function Wt(j,_,H,K,Q,ee,oe,ue,ge,Te){var Ie=j.state,Ee=j.props,Ae=!!j.$N,Me=o(j.shouldComponentUpdate);if(Ae&&(_=P(j,H,_!==Ie?k(Ie,_):_)),oe||!Me||Me&&j.shouldComponentUpdate(H,_,Q)){!Ae&&o(j.componentWillUpdate)&&j.componentWillUpdate(H,_,Q),j.props=H,j.state=_,j.context=Q;var _e=null,Oe=Pt(j,H,Q);Ae&&o(j.getSnapshotBeforeUpdate)&&(_e=j.getSnapshotBeforeUpdate(Ee,Ie)),qe(j.$LI,Oe,K,j.$CX,ee,ue,ge,Te),j.$LI=Oe,o(j.componentDidUpdate)&&yn(j,Ee,Ie,_e,ge)}else j.props=H,j.state=_,j.context=Q}function Sn(j,_,H,K,Q,ee,oe,ue){var ge=_.children=j.children;if(!y(ge)){ge.$L=oe;var Te=_.props||c,Ie=_.ref,Ee=j.ref,Ae=ge.state;if(!ge.$N){if(o(ge.componentWillReceiveProps)){if(ge.$BR=!0,ge.componentWillReceiveProps(Te,K),ge.$UN)return;ge.$BR=!1}y(ge.$PS)||(Ae=k(Ae,ge.$PS),ge.$PS=null)}Wt(ge,Ae,Te,H,K,Q,!1,ee,oe,ue),Ee!==Ie&&(st(Ee),at(Ie,ge,oe))}}function Bn(j,_,H,K,Q,ee,oe,ue){var ge=!0,Te=_.props||c,Ie=_.ref,Ee=j.props,Ae=!a(Ie),Me=j.children;if(Ae&&o(Ie.onComponentShouldUpdate)&&(ge=Ie.onComponentShouldUpdate(Ee,Te)),ge!==!1){Ae&&o(Ie.onComponentWillUpdate)&&Ie.onComponentWillUpdate(Ee,Te);var _e=pe(gt(_,K));qe(Me,_e,H,K,Q,ee,oe,ue),_.children=_e,Ae&&o(Ie.onComponentDidUpdate)&&Ie.onComponentDidUpdate(Ee,Te)}else _.children=Me}function In(j,_){var H=_.children,K=_.dom=j.dom;H!==j.children&&(K.nodeValue=H)}function Ln(j,_,H,K,Q,ee,oe,ue,ge,Te){for(var Ie=ee>oe?oe:ee,Ee=0,Ae,Me;Eeoe)for(Ee=Ie;EeEe||Me>Ae)break e;_e=j[Me],Oe=_[Me]}for(_e=j[Ee],Oe=_[Ae];_e.key===Oe.key;){if(Oe.flags&16384&&(_[Ae]=Oe=ae(Oe)),qe(_e,Oe,H,K,Q,ue,Te,Ie),j[Ee]=Oe,Ee--,Ae--,Me>Ee||Me>Ae)break e;_e=j[Ee],Oe=_[Ae]}}if(Me>Ee){if(Me<=Ae)for($e=Ae+1,De=$eAe)for(;Me<=Ee;)Je(j[Me++],H,Ie);else Tn(j,_,K,ee,oe,Ee,Ae,Me,H,Q,ue,ge,Te,Ie)}function Tn(j,_,H,K,Q,ee,oe,ue,ge,Te,Ie,Ee,Ae,Me){var _e,Oe,$e=0,De=0,tt=ue,Ye=ue,it=ee-ue+1,Qe=oe-ue+1,lt=new Int32Array(Qe+1),nt=it===K,bt=!1,Ge=0,dt=0;if(Q<4||(it|Qe)<32)for(De=tt;De<=ee;++De)if(_e=j[De],dtue?bt=!0:Ge=ue,Oe.flags&16384&&(_[ue]=Oe=ae(Oe)),qe(_e,Oe,ge,H,Te,Ie,Ae,Me),++dt;break}!nt&&ue>oe&&Je(_e,ge,Me)}else nt||Je(_e,ge,Me);else{var Yt={};for(De=Ye;De<=oe;++De)Yt[_[De].key]=De;for(De=tt;De<=ee;++De)if(_e=j[De],dttt;)Je(j[tt++],ge,Me);lt[ue-Ye]=De+1,Ge>ue?bt=!0:Ge=ue,Oe=_[ue],Oe.flags&16384&&(_[ue]=Oe=ae(Oe)),qe(_e,Oe,ge,H,Te,Ie,Ae,Me),++dt}else nt||Je(_e,ge,Me);else nt||Je(_e,ge,Me)}if(nt)pt(ge,Ee,j,Me),ot(_,ge,H,Te,Ie,Ae,Me);else if(bt){var Xt=xn(lt);for(ue=Xt.length-1,De=Qe-1;De>=0;De--)lt[De]===0?(Ge=De+Ye,Oe=_[Ge],Oe.flags&16384&&(_[Ge]=Oe=ae(Oe)),$e=Ge+1,Ke(Oe,ge,H,Te,$e0&&I(Me.componentWillMove)}else if(dt!==Qe)for(De=Qe-1;De>=0;De--)lt[De]===0&&(Ge=De+Ye,Oe=_[Ge],Oe.flags&16384&&(_[Ge]=Oe=ae(Oe)),$e=Ge+1,Ke(Oe,ge,H,Te,$eUt&&(Ut=ge,et=new Int32Array(ge),ft=new Int32Array(ge));H>1,j[et[ue]]<_?ee=ue+1:oe=ue;_0&&(ft[H]=et[ee-1]),et[ee]=H)}ee=Q+1;var Te=new Int32Array(ee);for(oe=et[ee-1];ee-- >0;)Te[ee]=oe,oe=ft[oe],et[ee]=0;return Te}var An=typeof document!="undefined";An&&window.Node&&(Node.prototype.$EV=null,Node.prototype.$V=null);function Ht(j,_,H,K){var Q=[],ee=new l,oe=_.$V;D.v=!0,a(oe)?a(j)||(j.flags&16384&&(j=ae(j)),Ke(j,_,K,!1,null,Q,ee),_.$V=j,oe=j):a(j)?(Je(oe,_,ee),_.$V=null):(j.flags&16384&&(j=ae(j)),qe(oe,j,_,K,!1,null,Q,ee),oe=_.$V=j),f(Q),B(ee.componentDidAppear),D.v=!1,o(H)&&H(),o(M.renderComplete)&&M.renderComplete(oe,_)}function zt(j,_,H,K){H===void 0&&(H=null),K===void 0&&(K=c),Ht(j,_,H,K)}function En(j){return function(){function _(H,K,Q,ee){j||(j=H),zt(K,j,Q,ee)}return _}()}var ht=[],Mn=typeof Promise!="undefined"?Promise.resolve().then.bind(Promise.resolve()):function(j){window.setTimeout(j,0)},Vt=!1;function Kt(j,_,H,K){var Q=j.$PS;if(o(_)&&(_=_(Q?k(j.state,Q):j.state,j.props,j.context)),a(Q))j.$PS=_;else for(var ee in _)Q[ee]=_[ee];if(j.$BR)o(H)&&j.$L.push(H.bind(j));else{if(!D.v&&ht.length===0){Gt(j,K),o(H)&&H.call(j);return}if(ht.indexOf(j)===-1&&ht.push(j),K&&(j.$F=!0),Vt||(Vt=!0,Mn($t)),o(H)){var oe=j.$QU;oe||(oe=j.$QU=[]),oe.push(H)}}}function Pn(j){for(var _=j.$QU,H=0;H<_.length;++H)_[H].call(j);j.$QU=null}function $t(){var j;for(Vt=!1;j=ht.shift();)if(!j.$UN){var _=j.$F;j.$F=!1,Gt(j,_),j.$QU&&Pn(j)}}function Gt(j,_){if(_||!j.$BR){var H=j.$PS;j.$PS=null;var K=[],Q=new l;D.v=!0,Wt(j,k(j.state,H),j.props,V(j.$LI,!0).parentNode,j.context,j.$SVG,_,null,K,Q),f(K),B(Q.componentDidAppear),D.v=!1}else j.state=j.$PS,j.$PS=null}var On=r.Component=function(){function j(H,K){this.state=null,this.props=void 0,this.context=void 0,this.displayName=void 0,this.$BR=!1,this.$BS=!0,this.$PS=null,this.$LI=null,this.$UN=!1,this.$CX=null,this.$QU=null,this.$N=!1,this.$SSR=void 0,this.$L=null,this.$SVG=!1,this.$F=!1,this.props=H||c,this.context=K||c}var _=j.prototype;return _.forceUpdate=function(){function H(K){this.$UN||Kt(this,{},K,!0)}return H}(),_.setState=function(){function H(K,Q){this.$UN||this.$BS||Kt(this,K,Q,!1)}return H}(),_.render=function(){function H(K,Q,ee){return null}return H}(),j}();On.defaultProps=null;var Dn=r.version="8.2.3"},89005:function(T,r,n){"use strict";r.__esModule=!0;var e=n(89292);Object.keys(e).forEach(function(a){a==="default"||a==="__esModule"||a in r&&r[a]===e[a]||(r[a]=e[a])})},71614:function(T,r,n){"use strict";var e=n(21285);function a(){}function t(){}t.resetWarningCache=a,T.exports=function(){function o(y,S,k,h,i,c){if(c!==e){var m=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw m.name="Invariant Violation",m}}o.isRequired=o;function p(){return o}var b={array:o,bigint:o,bool:o,func:o,number:o,object:o,string:o,symbol:o,any:o,arrayOf:p,element:o,elementType:o,instanceOf:p,node:o,objectOf:p,oneOf:p,oneOfType:p,shape:p,exact:p,checkPropTypes:t,resetWarningCache:a};return b.PropTypes=b,b}},15964:function(T,r,n){"use strict";if(0)var e,a;else T.exports=n(71614)()},21285:function(T){"use strict";var r="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";T.exports=r},95012:function(T){"use strict";var r=function(n){"use strict";var e=Object.prototype,a=e.hasOwnProperty,t=Object.defineProperty||function(M,O,R){M[O]=R.value},o,p=typeof Symbol=="function"?Symbol:{},b=p.iterator||"@@iterator",y=p.asyncIterator||"@@asyncIterator",S=p.toStringTag||"@@toStringTag";function k(M,O,R){return Object.defineProperty(M,O,{value:R,enumerable:!0,configurable:!0,writable:!0}),M[O]}try{k({},"")}catch(M){k=function(R,F,W){return R[F]=W}}function h(M,O,R,F){var W=O&&O.prototype instanceof d?O:d,U=Object.create(W.prototype),z=new E(F||[]);return t(U,"_invoke",{value:L(M,R,z)}),U}n.wrap=h;function i(M,O,R){try{return{type:"normal",arg:M.call(O,R)}}catch(F){return{type:"throw",arg:F}}}var c="suspendedStart",m="suspendedYield",l="executing",u="completed",s={};function d(){}function C(){}function g(){}var v={};k(v,b,function(){return this});var f=Object.getPrototypeOf,N=f&&f(f(P([])));N&&N!==e&&a.call(N,b)&&(v=N);var V=g.prototype=d.prototype=Object.create(v);C.prototype=g,t(V,"constructor",{value:g,configurable:!0}),t(g,"constructor",{value:C,configurable:!0}),C.displayName=k(g,S,"GeneratorFunction");function B(M){["next","throw","return"].forEach(function(O){k(M,O,function(R){return this._invoke(O,R)})})}n.isGeneratorFunction=function(M){var O=typeof M=="function"&&M.constructor;return O?O===C||(O.displayName||O.name)==="GeneratorFunction":!1},n.mark=function(M){return Object.setPrototypeOf?Object.setPrototypeOf(M,g):(M.__proto__=g,k(M,S,"GeneratorFunction")),M.prototype=Object.create(V),M},n.awrap=function(M){return{__await:M}};function I(M,O){function R(U,z,$,G){var X=i(M[U],M,z);if(X.type==="throw")G(X.arg);else{var J=X.arg,se=J.value;return se&&typeof se=="object"&&a.call(se,"__await")?O.resolve(se.__await).then(function(ie){R("next",ie,$,G)},function(ie){R("throw",ie,$,G)}):O.resolve(se).then(function(ie){J.value=ie,$(J)},function(ie){return R("throw",ie,$,G)})}}var F;function W(U,z){function $(){return new O(function(G,X){R(U,z,G,X)})}return F=F?F.then($,$):$()}t(this,"_invoke",{value:W})}B(I.prototype),k(I.prototype,y,function(){return this}),n.AsyncIterator=I,n.async=function(M,O,R,F,W){W===void 0&&(W=Promise);var U=new I(h(M,O,R,F),W);return n.isGeneratorFunction(O)?U:U.next().then(function(z){return z.done?z.value:U.next()})};function L(M,O,R){var F=c;return function(){function W(U,z){if(F===l)throw new Error("Generator is already running");if(F===u){if(U==="throw")throw z;return D()}for(R.method=U,R.arg=z;;){var $=R.delegate;if($){var G=w($,R);if(G){if(G===s)continue;return G}}if(R.method==="next")R.sent=R._sent=R.arg;else if(R.method==="throw"){if(F===c)throw F=u,R.arg;R.dispatchException(R.arg)}else R.method==="return"&&R.abrupt("return",R.arg);F=l;var X=i(M,O,R);if(X.type==="normal"){if(F=R.done?u:m,X.arg===s)continue;return{value:X.arg,done:R.done}}else X.type==="throw"&&(F=u,R.method="throw",R.arg=X.arg)}}return W}()}function w(M,O){var R=O.method,F=M.iterator[R];if(F===o)return O.delegate=null,R==="throw"&&M.iterator.return&&(O.method="return",O.arg=o,w(M,O),O.method==="throw")||R!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+R+"' method")),s;var W=i(F,M.iterator,O.arg);if(W.type==="throw")return O.method="throw",O.arg=W.arg,O.delegate=null,s;var U=W.arg;if(!U)return O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,s;if(U.done)O[M.resultName]=U.value,O.next=M.nextLoc,O.method!=="return"&&(O.method="next",O.arg=o);else return U;return O.delegate=null,s}B(V),k(V,S,"Generator"),k(V,b,function(){return this}),k(V,"toString",function(){return"[object Generator]"});function A(M){var O={tryLoc:M[0]};1 in M&&(O.catchLoc=M[1]),2 in M&&(O.finallyLoc=M[2],O.afterLoc=M[3]),this.tryEntries.push(O)}function x(M){var O=M.completion||{};O.type="normal",delete O.arg,M.completion=O}function E(M){this.tryEntries=[{tryLoc:"root"}],M.forEach(A,this),this.reset(!0)}n.keys=function(M){var O=Object(M),R=[];for(var F in O)R.push(F);return R.reverse(),function(){function W(){for(;R.length;){var U=R.pop();if(U in O)return W.value=U,W.done=!1,W}return W.done=!0,W}return W}()};function P(M){if(M!=null){var O=M[b];if(O)return O.call(M);if(typeof M.next=="function")return M;if(!isNaN(M.length)){var R=-1,F=function(){function W(){for(;++R=0;--W){var U=this.tryEntries[W],z=U.completion;if(U.tryLoc==="root")return F("end");if(U.tryLoc<=this.prev){var $=a.call(U,"catchLoc"),G=a.call(U,"finallyLoc");if($&&G){if(this.prev=0;--F){var W=this.tryEntries[F];if(W.tryLoc<=this.prev&&a.call(W,"finallyLoc")&&this.prev=0;--R){var F=this.tryEntries[R];if(F.finallyLoc===O)return this.complete(F.completion,F.afterLoc),x(F),s}}return M}(),catch:function(){function M(O){for(var R=this.tryEntries.length-1;R>=0;--R){var F=this.tryEntries[R];if(F.tryLoc===O){var W=F.completion;if(W.type==="throw"){var U=W.arg;x(F)}return U}}throw new Error("illegal catch attempt")}return M}(),delegateYield:function(){function M(O,R,F){return this.delegate={iterator:P(O),resultName:R,nextLoc:F},this.method==="next"&&(this.arg=o),s}return M}()},n}(T.exports);try{regeneratorRuntime=r}catch(n){typeof globalThis=="object"?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},30236:function(){"use strict";self.fetch||(self.fetch=function(T,r){return r=r||{},new Promise(function(n,e){var a=new XMLHttpRequest,t=[],o={},p=function(){function y(){return{ok:(a.status/100|0)==2,statusText:a.statusText,status:a.status,url:a.responseURL,text:function(){function S(){return Promise.resolve(a.responseText)}return S}(),json:function(){function S(){return Promise.resolve(a.responseText).then(JSON.parse)}return S}(),blob:function(){function S(){return Promise.resolve(new Blob([a.response]))}return S}(),clone:y,headers:{keys:function(){function S(){return t}return S}(),entries:function(){function S(){return t.map(function(k){return[k,a.getResponseHeader(k)]})}return S}(),get:function(){function S(k){return a.getResponseHeader(k)}return S}(),has:function(){function S(k){return a.getResponseHeader(k)!=null}return S}()}}}return y}();for(var b in a.open(r.method||"get",T,!0),a.onload=function(){a.getAllResponseHeaders().toLowerCase().replace(/^(.+?):/gm,function(y,S){o[S]||t.push(o[S]=S)}),n(p())},a.onerror=e,a.withCredentials=r.credentials=="include",r.headers)a.setRequestHeader(b,r.headers[b]);a.send(r.body||null)})})},88510:function(T,r){"use strict";r.__esModule=!0,r.zipWith=r.zip=r.uniqBy=r.uniq=r.toKeyedArray=r.toArray=r.sortBy=r.sort=r.reduce=r.range=r.map=r.filterMap=r.filter=void 0;function n(d,C){var g=typeof Symbol!="undefined"&&d[Symbol.iterator]||d["@@iterator"];if(g)return(g=g.call(d)).next.bind(g);if(Array.isArray(d)||(g=e(d))||C&&d&&typeof d.length=="number"){g&&(d=g);var v=0;return function(){return v>=d.length?{done:!0}:{done:!1,value:d[v++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function e(d,C){if(d){if(typeof d=="string")return a(d,C);var g={}.toString.call(d).slice(8,-1);return g==="Object"&&d.constructor&&(g=d.constructor.name),g==="Map"||g==="Set"?Array.from(d):g==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(g)?a(d,C):void 0}}function a(d,C){(C==null||C>d.length)&&(C=d.length);for(var g=0,v=Array(C);gI)return 1}return 0},k=r.sortBy=function(){function d(){for(var v=arguments.length,g=new Array(v),C=0;CI)return 1}return 0},k=r.sortBy=function(){function d(){for(var C=arguments.length,g=new Array(C),v=0;v=1-n)return F[W-1];var z=U%1,$=U|0;return D.lerp(F[$],F[$+1],z)}return O}(),D}(),a=function(M,O,R){return O===void 0&&(O=0),R===void 0&&(R=Math.pow(10,O)),Math.round(R*M)/R},t={grad:360/400,turn:360,rad:360/(Math.PI*2)},o=r.hexToHsva=function(){function D(M){return I(p(M))}return D}(),p=r.hexToRgba=function(){function D(M){return M[0]==="#"&&(M=M.substring(1)),M.length<6?{r:parseInt(M[0]+M[0],16),g:parseInt(M[1]+M[1],16),b:parseInt(M[2]+M[2],16),a:M.length===4?a(parseInt(M[3]+M[3],16)/255,2):1}:{r:parseInt(M.substring(0,2),16),g:parseInt(M.substring(2,4),16),b:parseInt(M.substring(4,6),16),a:M.length===8?a(parseInt(M.substring(6,8),16)/255,2):1}}return D}(),b=r.parseHue=function(){function D(M,O){return O===void 0&&(O="deg"),Number(M)*(t[O]||1)}return D}(),y=r.hslaStringToHsva=function(){function D(M){var O=/hsla?\(?\s*(-?\d*\.?\d+)(deg|rad|grad|turn)?[,\s]+(-?\d*\.?\d+)%?[,\s]+(-?\d*\.?\d+)%?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i,R=O.exec(M);return R?k({h:b(R[1],R[2]),s:Number(R[3]),l:Number(R[4]),a:R[5]===void 0?1:Number(R[5])/(R[6]?100:1)}):{h:0,s:0,v:0,a:1}}return D}(),S=r.hslStringToHsva=y,k=r.hslaToHsva=function(){function D(M){var O=M.h,R=M.s,F=M.l,W=M.a;return R*=(F<50?F:100-F)/100,{h:O,s:R>0?2*R/(F+R)*100:0,v:F+R,a:W}}return D}(),h=r.hsvaToHex=function(){function D(M){return B(s(M))}return D}(),i=r.hsvaToHsla=function(){function D(M){var O=M.h,R=M.s,F=M.v,W=M.a,U=(200-R)*F/100;return{h:a(O),s:a(U>0&&U<200?R*F/100/(U<=100?U:200-U)*100:0),l:a(U/2),a:a(W,2)}}return D}(),c=r.hsvaToHslString=function(){function D(M){var O=i(M),R=O.h,F=O.s,W=O.l;return"hsl("+R+", "+F+"%, "+W+"%)"}return D}(),m=r.hsvaToHsvString=function(){function D(M){var O=L(M),R=O.h,F=O.s,W=O.v;return"hsv("+R+", "+F+"%, "+W+"%)"}return D}(),l=r.hsvaToHsvaString=function(){function D(M){var O=L(M),R=O.h,F=O.s,W=O.v,U=O.a;return"hsva("+R+", "+F+"%, "+W+"%, "+U+")"}return D}(),u=r.hsvaToHslaString=function(){function D(M){var O=i(M),R=O.h,F=O.s,W=O.l,U=O.a;return"hsla("+R+", "+F+"%, "+W+"%, "+U+")"}return D}(),s=r.hsvaToRgba=function(){function D(M){var O=M.h,R=M.s,F=M.v,W=M.a;O=O/360*6,R=R/100,F=F/100;var U=Math.floor(O),z=F*(1-R),$=F*(1-(O-U)*R),G=F*(1-(1-O+U)*R),X=U%6;return{r:[F,$,z,z,G,F][X]*255,g:[G,F,F,$,z,z][X]*255,b:[z,z,G,F,F,$][X]*255,a:a(W,2)}}return D}(),d=r.hsvaToRgbString=function(){function D(M){var O=s(M),R=O.r,F=O.g,W=O.b;return"rgb("+a(R)+", "+a(F)+", "+a(W)+")"}return D}(),v=r.hsvaToRgbaString=function(){function D(M){var O=s(M),R=O.r,F=O.g,W=O.b,U=O.a;return"rgba("+a(R)+", "+a(F)+", "+a(W)+", "+a(U,2)+")"}return D}(),g=r.hsvaStringToHsva=function(){function D(M){var O=/hsva?\(?\s*(-?\d*\.?\d+)(deg|rad|grad|turn)?[,\s]+(-?\d*\.?\d+)%?[,\s]+(-?\d*\.?\d+)%?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i,R=O.exec(M);return R?L({h:b(R[1],R[2]),s:Number(R[3]),v:Number(R[4]),a:R[5]===void 0?1:Number(R[5])/(R[6]?100:1)}):{h:0,s:0,v:0,a:1}}return D}(),C=r.hsvStringToHsva=g,f=r.rgbaStringToHsva=function(){function D(M){var O=/rgba?\(?\s*(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i,R=O.exec(M);return R?I({r:Number(R[1])/(R[2]?100/255:1),g:Number(R[3])/(R[4]?100/255:1),b:Number(R[5])/(R[6]?100/255:1),a:R[7]===void 0?1:Number(R[7])/(R[8]?100:1)}):{h:0,s:0,v:0,a:1}}return D}(),N=r.rgbStringToHsva=f,V=function(M){var O=M.toString(16);return O.length<2?"0"+O:O},B=r.rgbaToHex=function(){function D(M){var O=M.r,R=M.g,F=M.b,W=M.a,U=W<1?V(a(W*255)):"";return"#"+V(a(O))+V(a(R))+V(a(F))+U}return D}(),I=r.rgbaToHsva=function(){function D(M){var O=M.r,R=M.g,F=M.b,W=M.a,U=Math.max(O,R,F),z=U-Math.min(O,R,F),$=z?U===O?(R-F)/z:U===R?2+(F-O)/z:4+(O-R)/z:0;return{h:60*($<0?$+6:$),s:U?z/U*100:0,v:U/255*100,a:W}}return D}(),L=r.roundHsva=function(){function D(M){return{h:a(M.h),s:a(M.s),v:a(M.v),a:a(M.a,2)}}return D}(),w=r.rgbaToRgb=function(){function D(M){var O=M.r,R=M.g,F=M.b;return{r:O,g:R,b:F}}return D}(),A=r.hslaToHsl=function(){function D(M){var O=M.h,R=M.s,F=M.l;return{h:O,s:R,l:F}}return D}(),x=r.hsvaToHsv=function(){function D(M){var O=L(M),R=O.h,F=O.s,W=O.v;return{h:R,s:F,v:W}}return D}(),E=/^#?([0-9A-F]{3,8})$/i,P=r.validHex=function(){function D(M,O){var R=E.exec(M),F=R?R[1].length:0;return F===3||F===6||!!O&&F===4||!!O&&F===8}return D}()},92868:function(T,r){"use strict";r.__esModule=!0,r.EventEmitter=void 0;/**
+ */var n=1e-4,e=r.Color=function(){function D(O,R,F,W){O===void 0&&(O=0),R===void 0&&(R=0),F===void 0&&(F=0),W===void 0&&(W=1),this.r=void 0,this.g=void 0,this.b=void 0,this.a=void 0,this.r=O,this.g=R,this.b=F,this.a=W}var M=D.prototype;return M.toString=function(){function O(){return"rgba("+(this.r|0)+", "+(this.g|0)+", "+(this.b|0)+", "+(this.a|0)+")"}return O}(),D.fromHex=function(){function O(R){return new D(parseInt(R.substr(1,2),16),parseInt(R.substr(3,2),16),parseInt(R.substr(5,2),16))}return O}(),D.lerp=function(){function O(R,F,W){return new D((F.r-R.r)*W+R.r,(F.g-R.g)*W+R.g,(F.b-R.b)*W+R.b,(F.a-R.a)*W+R.a)}return O}(),D.lookup=function(){function O(R,F){F===void 0&&(F=[]);var W=F.length;if(W<2)throw new Error("Needs at least two colors!");var U=R*(W-1);if(R=1-n)return F[W-1];var z=U%1,$=U|0;return D.lerp(F[$],F[$+1],z)}return O}(),D}(),a=function(M,O,R){return O===void 0&&(O=0),R===void 0&&(R=Math.pow(10,O)),Math.round(R*M)/R},t={grad:360/400,turn:360,rad:360/(Math.PI*2)},o=r.hexToHsva=function(){function D(M){return I(p(M))}return D}(),p=r.hexToRgba=function(){function D(M){return M[0]==="#"&&(M=M.substring(1)),M.length<6?{r:parseInt(M[0]+M[0],16),g:parseInt(M[1]+M[1],16),b:parseInt(M[2]+M[2],16),a:M.length===4?a(parseInt(M[3]+M[3],16)/255,2):1}:{r:parseInt(M.substring(0,2),16),g:parseInt(M.substring(2,4),16),b:parseInt(M.substring(4,6),16),a:M.length===8?a(parseInt(M.substring(6,8),16)/255,2):1}}return D}(),b=r.parseHue=function(){function D(M,O){return O===void 0&&(O="deg"),Number(M)*(t[O]||1)}return D}(),y=r.hslaStringToHsva=function(){function D(M){var O=/hsla?\(?\s*(-?\d*\.?\d+)(deg|rad|grad|turn)?[,\s]+(-?\d*\.?\d+)%?[,\s]+(-?\d*\.?\d+)%?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i,R=O.exec(M);return R?k({h:b(R[1],R[2]),s:Number(R[3]),l:Number(R[4]),a:R[5]===void 0?1:Number(R[5])/(R[6]?100:1)}):{h:0,s:0,v:0,a:1}}return D}(),S=r.hslStringToHsva=y,k=r.hslaToHsva=function(){function D(M){var O=M.h,R=M.s,F=M.l,W=M.a;return R*=(F<50?F:100-F)/100,{h:O,s:R>0?2*R/(F+R)*100:0,v:F+R,a:W}}return D}(),h=r.hsvaToHex=function(){function D(M){return B(s(M))}return D}(),i=r.hsvaToHsla=function(){function D(M){var O=M.h,R=M.s,F=M.v,W=M.a,U=(200-R)*F/100;return{h:a(O),s:a(U>0&&U<200?R*F/100/(U<=100?U:200-U)*100:0),l:a(U/2),a:a(W,2)}}return D}(),c=r.hsvaToHslString=function(){function D(M){var O=i(M),R=O.h,F=O.s,W=O.l;return"hsl("+R+", "+F+"%, "+W+"%)"}return D}(),m=r.hsvaToHsvString=function(){function D(M){var O=L(M),R=O.h,F=O.s,W=O.v;return"hsv("+R+", "+F+"%, "+W+"%)"}return D}(),l=r.hsvaToHsvaString=function(){function D(M){var O=L(M),R=O.h,F=O.s,W=O.v,U=O.a;return"hsva("+R+", "+F+"%, "+W+"%, "+U+")"}return D}(),u=r.hsvaToHslaString=function(){function D(M){var O=i(M),R=O.h,F=O.s,W=O.l,U=O.a;return"hsla("+R+", "+F+"%, "+W+"%, "+U+")"}return D}(),s=r.hsvaToRgba=function(){function D(M){var O=M.h,R=M.s,F=M.v,W=M.a;O=O/360*6,R=R/100,F=F/100;var U=Math.floor(O),z=F*(1-R),$=F*(1-(O-U)*R),G=F*(1-(1-O+U)*R),X=U%6;return{r:[F,$,z,z,G,F][X]*255,g:[G,F,F,$,z,z][X]*255,b:[z,z,G,F,F,$][X]*255,a:a(W,2)}}return D}(),d=r.hsvaToRgbString=function(){function D(M){var O=s(M),R=O.r,F=O.g,W=O.b;return"rgb("+a(R)+", "+a(F)+", "+a(W)+")"}return D}(),C=r.hsvaToRgbaString=function(){function D(M){var O=s(M),R=O.r,F=O.g,W=O.b,U=O.a;return"rgba("+a(R)+", "+a(F)+", "+a(W)+", "+a(U,2)+")"}return D}(),g=r.hsvaStringToHsva=function(){function D(M){var O=/hsva?\(?\s*(-?\d*\.?\d+)(deg|rad|grad|turn)?[,\s]+(-?\d*\.?\d+)%?[,\s]+(-?\d*\.?\d+)%?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i,R=O.exec(M);return R?L({h:b(R[1],R[2]),s:Number(R[3]),v:Number(R[4]),a:R[5]===void 0?1:Number(R[5])/(R[6]?100:1)}):{h:0,s:0,v:0,a:1}}return D}(),v=r.hsvStringToHsva=g,f=r.rgbaStringToHsva=function(){function D(M){var O=/rgba?\(?\s*(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i,R=O.exec(M);return R?I({r:Number(R[1])/(R[2]?100/255:1),g:Number(R[3])/(R[4]?100/255:1),b:Number(R[5])/(R[6]?100/255:1),a:R[7]===void 0?1:Number(R[7])/(R[8]?100:1)}):{h:0,s:0,v:0,a:1}}return D}(),N=r.rgbStringToHsva=f,V=function(M){var O=M.toString(16);return O.length<2?"0"+O:O},B=r.rgbaToHex=function(){function D(M){var O=M.r,R=M.g,F=M.b,W=M.a,U=W<1?V(a(W*255)):"";return"#"+V(a(O))+V(a(R))+V(a(F))+U}return D}(),I=r.rgbaToHsva=function(){function D(M){var O=M.r,R=M.g,F=M.b,W=M.a,U=Math.max(O,R,F),z=U-Math.min(O,R,F),$=z?U===O?(R-F)/z:U===R?2+(F-O)/z:4+(O-R)/z:0;return{h:60*($<0?$+6:$),s:U?z/U*100:0,v:U/255*100,a:W}}return D}(),L=r.roundHsva=function(){function D(M){return{h:a(M.h),s:a(M.s),v:a(M.v),a:a(M.a,2)}}return D}(),w=r.rgbaToRgb=function(){function D(M){var O=M.r,R=M.g,F=M.b;return{r:O,g:R,b:F}}return D}(),A=r.hslaToHsl=function(){function D(M){var O=M.h,R=M.s,F=M.l;return{h:O,s:R,l:F}}return D}(),x=r.hsvaToHsv=function(){function D(M){var O=L(M),R=O.h,F=O.s,W=O.v;return{h:R,s:F,v:W}}return D}(),E=/^#?([0-9A-F]{3,8})$/i,P=r.validHex=function(){function D(M,O){var R=E.exec(M),F=R?R[1].length:0;return F===3||F===6||!!O&&F===4||!!O&&F===8}return D}()},92868:function(T,r){"use strict";r.__esModule=!0,r.EventEmitter=void 0;/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -20,7 +20,7 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var n=r.KEY_BACKSPACE=8,e=r.KEY_TAB=9,a=r.KEY_ENTER=13,t=r.KEY_SHIFT=16,o=r.KEY_CTRL=17,p=r.KEY_ALT=18,b=r.KEY_PAUSE=19,y=r.KEY_CAPSLOCK=20,S=r.KEY_ESCAPE=27,k=r.KEY_SPACE=32,h=r.KEY_PAGEUP=33,i=r.KEY_PAGEDOWN=34,c=r.KEY_END=35,m=r.KEY_HOME=36,l=r.KEY_LEFT=37,u=r.KEY_UP=38,s=r.KEY_RIGHT=39,d=r.KEY_DOWN=40,v=r.KEY_INSERT=45,g=r.KEY_DELETE=46,C=r.KEY_0=48,f=r.KEY_1=49,N=r.KEY_2=50,V=r.KEY_3=51,B=r.KEY_4=52,I=r.KEY_5=53,L=r.KEY_6=54,w=r.KEY_7=55,A=r.KEY_8=56,x=r.KEY_9=57,E=r.KEY_A=65,P=r.KEY_B=66,D=r.KEY_C=67,M=r.KEY_D=68,O=r.KEY_E=69,R=r.KEY_F=70,F=r.KEY_G=71,W=r.KEY_H=72,U=r.KEY_I=73,z=r.KEY_J=74,$=r.KEY_K=75,G=r.KEY_L=76,X=r.KEY_M=77,J=r.KEY_N=78,se=r.KEY_O=79,ie=r.KEY_P=80,me=r.KEY_Q=81,q=r.KEY_R=82,re=r.KEY_S=83,ae=r.KEY_T=84,le=r.KEY_U=85,Z=r.KEY_V=86,ne=r.KEY_W=87,te=r.KEY_X=88,fe=r.KEY_Y=89,pe=r.KEY_Z=90,ce=r.KEY_NUMPAD_0=96,Ve=r.KEY_NUMPAD_1=97,Ce=r.KEY_NUMPAD_2=98,Ne=r.KEY_NUMPAD_3=99,Be=r.KEY_NUMPAD_4=100,be=r.KEY_NUMPAD_5=101,Le=r.KEY_NUMPAD_6=102,we=r.KEY_NUMPAD_7=103,xe=r.KEY_NUMPAD_8=104,Re=r.KEY_NUMPAD_9=105,He=r.KEY_F1=112,ye=r.KEY_F2=113,de=r.KEY_F3=114,he=r.KEY_F4=115,ke=r.KEY_F5=116,ve=r.KEY_F6=117,Se=r.KEY_F7=118,Pe=r.KEY_F8=119,je=r.KEY_F9=120,Fe=r.KEY_F10=121,ze=r.KEY_F11=122,We=r.KEY_F12=123,Ue=r.KEY_SEMICOLON=186,Xe=r.KEY_EQUAL=187,yt=r.KEY_COMMA=188,St=r.KEY_MINUS=189,Ct=r.KEY_PERIOD=190,Bt=r.KEY_SLASH=191,ut=r.KEY_LEFT_BRACKET=219,rt=r.KEY_BACKSLASH=220,It=r.KEY_RIGHT_BRACKET=221,Lt=r.KEY_QUOTE=222},70611:function(T,r){"use strict";r.__esModule=!0,r.isEscape=r.KEY=void 0;var n=r.KEY=function(a){return a.Alt="Alt",a.Backspace="Backspace",a.Control="Control",a.Delete="Delete",a.Down="Down",a.End="End",a.Enter="Enter",a.Esc="Esc",a.Escape="Escape",a.Home="Home",a.Insert="Insert",a.Left="Left",a.PageDown="PageDown",a.PageUp="PageUp",a.Right="Right",a.Shift="Shift",a.Space=" ",a.Tab="Tab",a.Up="Up",a}({}),e=r.isEscape=function(){function a(t){return t===n.Esc||t===n.Escape}return a}()},44879:function(T,r){"use strict";r.__esModule=!0,r.toFixed=r.scale=r.round=r.rad2deg=r.keyOfMatchingRange=r.inRange=r.clamp01=r.clamp=void 0;/**
+ */var n=r.KEY_BACKSPACE=8,e=r.KEY_TAB=9,a=r.KEY_ENTER=13,t=r.KEY_SHIFT=16,o=r.KEY_CTRL=17,p=r.KEY_ALT=18,b=r.KEY_PAUSE=19,y=r.KEY_CAPSLOCK=20,S=r.KEY_ESCAPE=27,k=r.KEY_SPACE=32,h=r.KEY_PAGEUP=33,i=r.KEY_PAGEDOWN=34,c=r.KEY_END=35,m=r.KEY_HOME=36,l=r.KEY_LEFT=37,u=r.KEY_UP=38,s=r.KEY_RIGHT=39,d=r.KEY_DOWN=40,C=r.KEY_INSERT=45,g=r.KEY_DELETE=46,v=r.KEY_0=48,f=r.KEY_1=49,N=r.KEY_2=50,V=r.KEY_3=51,B=r.KEY_4=52,I=r.KEY_5=53,L=r.KEY_6=54,w=r.KEY_7=55,A=r.KEY_8=56,x=r.KEY_9=57,E=r.KEY_A=65,P=r.KEY_B=66,D=r.KEY_C=67,M=r.KEY_D=68,O=r.KEY_E=69,R=r.KEY_F=70,F=r.KEY_G=71,W=r.KEY_H=72,U=r.KEY_I=73,z=r.KEY_J=74,$=r.KEY_K=75,G=r.KEY_L=76,X=r.KEY_M=77,J=r.KEY_N=78,se=r.KEY_O=79,ie=r.KEY_P=80,me=r.KEY_Q=81,q=r.KEY_R=82,re=r.KEY_S=83,ae=r.KEY_T=84,le=r.KEY_U=85,Z=r.KEY_V=86,ne=r.KEY_W=87,te=r.KEY_X=88,fe=r.KEY_Y=89,pe=r.KEY_Z=90,ce=r.KEY_NUMPAD_0=96,Ve=r.KEY_NUMPAD_1=97,Ce=r.KEY_NUMPAD_2=98,Ne=r.KEY_NUMPAD_3=99,Be=r.KEY_NUMPAD_4=100,be=r.KEY_NUMPAD_5=101,Le=r.KEY_NUMPAD_6=102,we=r.KEY_NUMPAD_7=103,xe=r.KEY_NUMPAD_8=104,Re=r.KEY_NUMPAD_9=105,He=r.KEY_F1=112,ye=r.KEY_F2=113,de=r.KEY_F3=114,he=r.KEY_F4=115,ke=r.KEY_F5=116,ve=r.KEY_F6=117,Se=r.KEY_F7=118,Pe=r.KEY_F8=119,je=r.KEY_F9=120,Fe=r.KEY_F10=121,ze=r.KEY_F11=122,We=r.KEY_F12=123,Ue=r.KEY_SEMICOLON=186,Xe=r.KEY_EQUAL=187,yt=r.KEY_COMMA=188,St=r.KEY_MINUS=189,Ct=r.KEY_PERIOD=190,Bt=r.KEY_SLASH=191,ut=r.KEY_LEFT_BRACKET=219,rt=r.KEY_BACKSLASH=220,It=r.KEY_RIGHT_BRACKET=221,Lt=r.KEY_QUOTE=222},70611:function(T,r){"use strict";r.__esModule=!0,r.isEscape=r.KEY=void 0;var n=r.KEY=function(a){return a.Alt="Alt",a.Backspace="Backspace",a.Control="Control",a.Delete="Delete",a.Down="Down",a.End="End",a.Enter="Enter",a.Esc="Esc",a.Escape="Escape",a.Home="Home",a.Insert="Insert",a.Left="Left",a.PageDown="PageDown",a.PageUp="PageUp",a.Right="Right",a.Shift="Shift",a.Space=" ",a.Tab="Tab",a.Up="Up",a}({}),e=r.isEscape=function(){function a(t){return t===n.Esc||t===n.Escape}return a}()},44879:function(T,r){"use strict";r.__esModule=!0,r.toFixed=r.scale=r.round=r.rad2deg=r.keyOfMatchingRange=r.inRange=r.clamp01=r.clamp=void 0;/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -40,17 +40,17 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var a=r.createStore=function(){function S(k,h){if(h)return h(S)(k);var i,c=[],m=function(){function s(){return i}return s}(),l=function(){function s(d){c.push(d)}return s}(),u=function(){function s(d){i=k(i,d);for(var v=0;v1?l-1:0),s=1;s1?V-1:0),I=1;I=0;--pe){var ce=this.tryEntries[pe],Ve=ce.completion;if(ce.tryLoc==="root")return fe("end");if(ce.tryLoc<=this.prev){var Ce=N.call(ce,"catchLoc"),Ne=N.call(ce,"finallyLoc");if(Ce&&Ne){if(this.prev=0;--fe){var pe=this.tryEntries[fe];if(pe.tryLoc<=this.prev&&N.call(pe,"finallyLoc")&&this.prev=0;--te){var fe=this.tryEntries[te];if(fe.finallyLoc===ne)return this.complete(fe.completion,fe.afterLoc),re(fe),R}}return Z}(),catch:function(){function Z(ne){for(var te=this.tryEntries.length-1;te>=0;--te){var fe=this.tryEntries[te];if(fe.tryLoc===ne){var pe=fe.completion;if(pe.type==="throw"){var ce=pe.arg;re(fe)}return ce}}throw Error("illegal catch attempt")}return Z}(),delegateYield:function(){function Z(ne,te,fe){return this.delegate={iterator:le(ne),resultName:te,nextLoc:fe},this.method==="next"&&(this.arg=g),R}return Z}()},C}function e(g,C,f,N,V,B,I){try{var L=g[B](I),w=L.value}catch(A){return void f(A)}L.done?C(w):Promise.resolve(w).then(N,V)}function a(g){return function(){var C=this,f=arguments;return new Promise(function(N,V){var B=g.apply(C,f);function I(w){e(B,N,V,I,L,"next",w)}function L(w){e(B,N,V,I,L,"throw",w)}I(void 0)})}}/**
+ */var a=r.createStore=function(){function S(k,h){if(h)return h(S)(k);var i,c=[],m=function(){function s(){return i}return s}(),l=function(){function s(d){c.push(d)}return s}(),u=function(){function s(d){i=k(i,d);for(var C=0;C1?l-1:0),s=1;s1?V-1:0),I=1;I=0;--pe){var ce=this.tryEntries[pe],Ve=ce.completion;if(ce.tryLoc==="root")return fe("end");if(ce.tryLoc<=this.prev){var Ce=N.call(ce,"catchLoc"),Ne=N.call(ce,"finallyLoc");if(Ce&&Ne){if(this.prev=0;--fe){var pe=this.tryEntries[fe];if(pe.tryLoc<=this.prev&&N.call(pe,"finallyLoc")&&this.prev=0;--te){var fe=this.tryEntries[te];if(fe.finallyLoc===ne)return this.complete(fe.completion,fe.afterLoc),re(fe),R}}return Z}(),catch:function(){function Z(ne){for(var te=this.tryEntries.length-1;te>=0;--te){var fe=this.tryEntries[te];if(fe.tryLoc===ne){var pe=fe.completion;if(pe.type==="throw"){var ce=pe.arg;re(fe)}return ce}}throw Error("illegal catch attempt")}return Z}(),delegateYield:function(){function Z(ne,te,fe){return this.delegate={iterator:le(ne),resultName:te,nextLoc:fe},this.method==="next"&&(this.arg=g),R}return Z}()},v}function e(g,v,f,N,V,B,I){try{var L=g[B](I),w=L.value}catch(A){return void f(A)}L.done?v(w):Promise.resolve(w).then(N,V)}function a(g){return function(){var v=this,f=arguments;return new Promise(function(N,V){var B=g.apply(v,f);function I(w){e(B,N,V,I,L,"next",w)}function L(w){e(B,N,V,I,L,"throw",w)}I(void 0)})}}/**
* Browser-agnostic abstraction of key-value web storage.
*
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var t=r.IMPL_MEMORY=0,o=r.IMPL_HUB_STORAGE=1,p=r.IMPL_INDEXED_DB=2,b=1,y="para-tgui",S="storage-v1",k="readonly",h="readwrite",i=function(C){return function(){try{return!!C()}catch(f){return!1}}},c=i(function(){return window.hubStorage&&window.hubStorage.getItem}),m=i(function(){return(window.indexedDB||window.msIndexedDB)&&(window.IDBTransaction||window.msIDBTransaction)}),l=function(){function g(){this.impl=t,this.store={}}var C=g.prototype;return C.get=function(){var f=a(n().mark(function(){function V(B){return n().wrap(function(){function I(L){for(;;)switch(L.prev=L.next){case 0:return L.abrupt("return",this.store[B]);case 1:case"end":return L.stop()}}return I}(),V,this)}return V}()));function N(V){return f.apply(this,arguments)}return N}(),C.set=function(){var f=a(n().mark(function(){function V(B,I){return n().wrap(function(){function L(w){for(;;)switch(w.prev=w.next){case 0:this.store[B]=I;case 1:case"end":return w.stop()}}return L}(),V,this)}return V}()));function N(V,B){return f.apply(this,arguments)}return N}(),C.remove=function(){var f=a(n().mark(function(){function V(B){return n().wrap(function(){function I(L){for(;;)switch(L.prev=L.next){case 0:this.store[B]=void 0;case 1:case"end":return L.stop()}}return I}(),V,this)}return V}()));function N(V){return f.apply(this,arguments)}return N}(),C.clear=function(){var f=a(n().mark(function(){function V(){return n().wrap(function(){function B(I){for(;;)switch(I.prev=I.next){case 0:this.store={};case 1:case"end":return I.stop()}}return B}(),V,this)}return V}()));function N(){return f.apply(this,arguments)}return N}(),g}(),u=function(){function g(){this.impl=o}var C=g.prototype;return C.get=function(){var f=a(n().mark(function(){function V(B){var I;return n().wrap(function(){function L(w){for(;;)switch(w.prev=w.next){case 0:return w.next=2,window.hubStorage.getItem("paradise-"+B);case 2:if(I=w.sent,typeof I!="string"){w.next=5;break}return w.abrupt("return",JSON.parse(I));case 5:case"end":return w.stop()}}return L}(),V)}return V}()));function N(V){return f.apply(this,arguments)}return N}(),C.set=function(){function f(N,V){window.hubStorage.setItem("paradise-"+N,JSON.stringify(V))}return f}(),C.remove=function(){function f(N){window.hubStorage.removeItem("paradise-"+N)}return f}(),C.clear=function(){function f(){window.hubStorage.clear()}return f}(),g}(),s=function(){function g(){this.impl=p,this.dbPromise=new Promise(function(f,N){var V=window.indexedDB||window.msIndexedDB,B=V.open(y,b);B.onupgradeneeded=function(){try{B.result.createObjectStore(S)}catch(I){N(new Error("Failed to upgrade IDB: "+B.error))}},B.onsuccess=function(){return f(B.result)},B.onerror=function(){N(new Error("Failed to open IDB: "+B.error))}})}var C=g.prototype;return C.getStore=function(){var f=a(n().mark(function(){function V(B){return n().wrap(function(){function I(L){for(;;)switch(L.prev=L.next){case 0:return L.abrupt("return",this.dbPromise.then(function(w){return w.transaction(S,B).objectStore(S)}));case 1:case"end":return L.stop()}}return I}(),V,this)}return V}()));function N(V){return f.apply(this,arguments)}return N}(),C.get=function(){var f=a(n().mark(function(){function V(B){var I;return n().wrap(function(){function L(w){for(;;)switch(w.prev=w.next){case 0:return w.next=2,this.getStore(k);case 2:return I=w.sent,w.abrupt("return",new Promise(function(A,x){var E=I.get(B);E.onsuccess=function(){return A(E.result)},E.onerror=function(){return x(E.error)}}));case 4:case"end":return w.stop()}}return L}(),V,this)}return V}()));function N(V){return f.apply(this,arguments)}return N}(),C.set=function(){var f=a(n().mark(function(){function V(B,I){var L;return n().wrap(function(){function w(A){for(;;)switch(A.prev=A.next){case 0:return A.next=2,this.getStore(h);case 2:L=A.sent,L.put(I,B);case 4:case"end":return A.stop()}}return w}(),V,this)}return V}()));function N(V,B){return f.apply(this,arguments)}return N}(),C.remove=function(){var f=a(n().mark(function(){function V(B){var I;return n().wrap(function(){function L(w){for(;;)switch(w.prev=w.next){case 0:return w.next=2,this.getStore(h);case 2:I=w.sent,I.delete(B);case 4:case"end":return w.stop()}}return L}(),V,this)}return V}()));function N(V){return f.apply(this,arguments)}return N}(),C.clear=function(){var f=a(n().mark(function(){function V(){var B;return n().wrap(function(){function I(L){for(;;)switch(L.prev=L.next){case 0:return L.next=2,this.getStore(h);case 2:B=L.sent,B.clear();case 4:case"end":return L.stop()}}return I}(),V,this)}return V}()));function N(){return f.apply(this,arguments)}return N}(),g}(),d=function(){function g(){this.backendPromise=a(n().mark(function(){function f(){var N;return n().wrap(function(){function V(B){for(;;)switch(B.prev=B.next){case 0:if(!(!Byond.TRIDENT&&c())){B.next=2;break}return B.abrupt("return",new u);case 2:if(!m()){B.next=12;break}return B.prev=3,N=new s,B.next=7,N.dbPromise;case 7:return B.abrupt("return",N);case 10:B.prev=10,B.t0=B.catch(3);case 12:return B.abrupt("return",new l);case 13:case"end":return B.stop()}}return V}(),f,null,[[3,10]])}return f}()))()}var C=g.prototype;return C.get=function(){var f=a(n().mark(function(){function V(B){var I;return n().wrap(function(){function L(w){for(;;)switch(w.prev=w.next){case 0:return w.next=2,this.backendPromise;case 2:return I=w.sent,w.abrupt("return",I.get(B));case 4:case"end":return w.stop()}}return L}(),V,this)}return V}()));function N(V){return f.apply(this,arguments)}return N}(),C.set=function(){var f=a(n().mark(function(){function V(B,I){var L;return n().wrap(function(){function w(A){for(;;)switch(A.prev=A.next){case 0:return A.next=2,this.backendPromise;case 2:return L=A.sent,A.abrupt("return",L.set(B,I));case 4:case"end":return A.stop()}}return w}(),V,this)}return V}()));function N(V,B){return f.apply(this,arguments)}return N}(),C.remove=function(){var f=a(n().mark(function(){function V(B){var I;return n().wrap(function(){function L(w){for(;;)switch(w.prev=w.next){case 0:return w.next=2,this.backendPromise;case 2:return I=w.sent,w.abrupt("return",I.remove(B));case 4:case"end":return w.stop()}}return L}(),V,this)}return V}()));function N(V){return f.apply(this,arguments)}return N}(),C.clear=function(){var f=a(n().mark(function(){function V(){var B;return n().wrap(function(){function I(L){for(;;)switch(L.prev=L.next){case 0:return L.next=2,this.backendPromise;case 2:return B=L.sent,L.abrupt("return",B.clear());case 4:case"end":return L.stop()}}return I}(),V,this)}return V}()));function N(){return f.apply(this,arguments)}return N}(),g}(),v=r.storage=new d},25328:function(T,r){"use strict";r.__esModule=!0,r.toTitleCase=r.multiline=r.decodeHtmlEntities=r.createSearch=r.createGlobPattern=r.capitalize=r.buildQueryString=void 0;function n(h,i){var c=typeof Symbol!="undefined"&&h[Symbol.iterator]||h["@@iterator"];if(c)return(c=c.call(h)).next.bind(c);if(Array.isArray(h)||(c=e(h))||i&&h&&typeof h.length=="number"){c&&(h=c);var m=0;return function(){return m>=h.length?{done:!0}:{done:!1,value:h[m++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function e(h,i){if(h){if(typeof h=="string")return a(h,i);var c={}.toString.call(h).slice(8,-1);return c==="Object"&&h.constructor&&(c=h.constructor.name),c==="Map"||c==="Set"?Array.from(h):c==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(c)?a(h,i):void 0}}function a(h,i){(i==null||i>h.length)&&(i=h.length);for(var c=0,m=Array(i);c=h.length?{done:!0}:{done:!1,value:h[m++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function e(h,i){if(h){if(typeof h=="string")return a(h,i);var c={}.toString.call(h).slice(8,-1);return c==="Object"&&h.constructor&&(c=h.constructor.name),c==="Map"||c==="Set"?Array.from(h):c==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(c)?a(h,i):void 0}}function a(h,i){(i==null||i>h.length)&&(i=h.length);for(var c=0,m=Array(i);c",apos:"'"};return i.replace(/ /gi,"\n").replace(/<\/?[a-z0-9-_]+[^>]*>/gi,"").replace(c,function(l,u){return m[u]}).replace(/?([0-9]+);/gi,function(l,u){var s=parseInt(u,10);return String.fromCharCode(s)}).replace(/?([0-9a-f]+);/gi,function(l,u){var s=parseInt(u,16);return String.fromCharCode(s)})}return h}(),k=r.buildQueryString=function(){function h(i){return Object.keys(i).map(function(c){return encodeURIComponent(c)+"="+encodeURIComponent(i[c])}).join("&")}return h}()},69214:function(T,r){"use strict";r.__esModule=!0,r.throttle=r.sleep=r.debounce=void 0;/**
+ */var t=r.multiline=function(){function h(i){if(Array.isArray(i))return h(i.join(""));for(var c=i.split("\n"),m,l=n(c),u;!(u=l()).done;)for(var s=u.value,d=0;d",apos:"'"};return i.replace(/ /gi,"\n").replace(/<\/?[a-z0-9-_]+[^>]*>/gi,"").replace(c,function(l,u){return m[u]}).replace(/?([0-9]+);/gi,function(l,u){var s=parseInt(u,10);return String.fromCharCode(s)}).replace(/?([0-9a-f]+);/gi,function(l,u){var s=parseInt(u,16);return String.fromCharCode(s)})}return h}(),k=r.buildQueryString=function(){function h(i){return Object.keys(i).map(function(c){return encodeURIComponent(c)+"="+encodeURIComponent(i[c])}).join("&")}return h}()},69214:function(T,r){"use strict";r.__esModule=!0,r.throttle=r.sleep=r.debounce=void 0;/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -62,7 +62,7 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var a=function(u,s){return u+s},t=function(u,s){return u-s},o=function(u,s){return u*s},p=function(u,s){return u/s},b=r.vecAdd=function(){function l(){for(var u=arguments.length,s=new Array(u),d=0;d0&&(N.style=x),N}return C}(),v=r.computeBoxClassName=function(){function C(f){var N=f.textColor||f.color,V=f.backgroundColor;return(0,e.classes)([h(N)&&"color-"+N,h(V)&&"color-bg-"+V])}return C}(),g=r.Box=function(){function C(f){var N=f.as,V=N===void 0?"div":N,B=f.className,I=f.children,L=b(f,p);if(typeof I=="function")return I(d(f));var w=typeof B=="string"?B+" "+v(L):v(L),A=d(L);return(0,a.createVNode)(t.VNodeFlags.HtmlElement,V,w,I,t.ChildFlags.UnknownChildren,A)}return C}();g.defaultHooks=e.pureComponentHooks},96184:function(T,r,n){"use strict";r.__esModule=!0,r.ButtonInput=r.ButtonConfirm=r.ButtonCheckbox=r.Button=void 0;var e=n(89005),a=n(35840),t=n(92986),o=n(9394),p=n(55937),b=n(1331),y=n(62147),S=["className","fluid","translucent","icon","iconRotation","iconSpin","color","textColor","disabled","selected","tooltip","tooltipPosition","ellipsis","compact","circular","content","iconColor","iconRight","iconStyle","children","onclick","onClick","multiLine"],k=["checked"],h=["confirmContent","confirmColor","confirmIcon","icon","color","content","onClick"],i=["fluid","content","icon","iconRotation","iconSpin","tooltip","tooltipPosition","color","disabled","multiLine"];/**
+ */function b(v,f){if(v==null)return{};var N={};for(var V in v)if({}.hasOwnProperty.call(v,V)){if(f.includes(V))continue;N[V]=v[V]}return N}var y=r.unit=function(){function v(f){if(typeof f=="string")return f.endsWith("px")?parseFloat(f)/12+"rem":f;if(typeof f=="number")return f+"rem"}return v}(),S=r.halfUnit=function(){function v(f){if(typeof f=="string")return y(f);if(typeof f=="number")return y(f*.5)}return v}(),k=function(f){return!h(f)},h=function(f){if(typeof f=="string")return o.CSS_COLORS.includes(f)},i=function(f){return function(N,V){(typeof V=="number"||typeof V=="string")&&(N[f]=V)}},c=function(f,N){return function(V,B){(typeof B=="number"||typeof B=="string")&&(V[f]=N(B))}},m=function(f,N){return function(V,B){B&&(V[f]=N)}},l=function(f,N,V){return function(B,I){if(typeof I=="number"||typeof I=="string")for(var L=0;L0&&(N.style=x),N}return v}(),C=r.computeBoxClassName=function(){function v(f){var N=f.textColor||f.color,V=f.backgroundColor;return(0,e.classes)([h(N)&&"color-"+N,h(V)&&"color-bg-"+V])}return v}(),g=r.Box=function(){function v(f){var N=f.as,V=N===void 0?"div":N,B=f.className,I=f.children,L=b(f,p);if(typeof I=="function")return I(d(f));var w=typeof B=="string"?B+" "+C(L):C(L),A=d(L);return(0,a.createVNode)(t.VNodeFlags.HtmlElement,V,w,I,t.ChildFlags.UnknownChildren,A)}return v}();g.defaultHooks=e.pureComponentHooks},96184:function(T,r,n){"use strict";r.__esModule=!0,r.ButtonInput=r.ButtonConfirm=r.ButtonCheckbox=r.Button=void 0;var e=n(89005),a=n(35840),t=n(92986),o=n(9394),p=n(55937),b=n(1331),y=n(62147),S=["className","fluid","translucent","icon","iconRotation","iconSpin","color","textColor","disabled","selected","tooltip","tooltipPosition","ellipsis","compact","circular","content","iconColor","iconRight","iconStyle","children","onclick","onClick","multiLine"],k=["checked"],h=["confirmContent","confirmColor","confirmIcon","icon","color","content","onClick"],i=["fluid","content","icon","iconRotation","iconSpin","tooltip","tooltipPosition","color","disabled","multiLine"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */function c(C,f){C.prototype=Object.create(f.prototype),C.prototype.constructor=C,m(C,f)}function m(C,f){return m=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(N,V){return N.__proto__=V,N},m(C,f)}function l(C,f){if(C==null)return{};var N={};for(var V in C)if({}.hasOwnProperty.call(C,V)){if(f.includes(V))continue;N[V]=C[V]}return N}var u=(0,o.createLogger)("Button"),s=r.Button=function(){function C(f){var N=f.className,V=f.fluid,B=f.translucent,I=f.icon,L=f.iconRotation,w=f.iconSpin,A=f.color,x=f.textColor,E=f.disabled,P=f.selected,D=f.tooltip,M=f.tooltipPosition,O=f.ellipsis,R=f.compact,F=f.circular,W=f.content,U=f.iconColor,z=f.iconRight,$=f.iconStyle,G=f.children,X=f.onclick,J=f.onClick,se=f.multiLine,ie=l(f,S),me=!!(W||G);X&&u.warn("Lowercase 'onclick' is not supported on Button and lowercase prop names are discouraged in general. Please use a camelCase'onClick' instead and read: https://infernojs.org/docs/guides/event-handling"),ie.onClick=function(re){!E&&J&&J(re)};var q=(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.Box,Object.assign({className:(0,a.classes)(["Button",V&&"Button--fluid",E&&"Button--disabled"+(B?"--translucent":""),P&&"Button--selected"+(B?"--translucent":""),me&&"Button--hasContent",O&&"Button--ellipsis",F&&"Button--circular",R&&"Button--compact",z&&"Button--iconRight",se&&"Button--multiLine",A&&typeof A=="string"?"Button--color--"+A+(B?"--translucent":""):"Button--color--default"+(B?"--translucent":""),N]),tabIndex:!E&&"0",color:x,onKeyDown:function(){function re(ae){var le=window.event?ae.which:ae.keyCode;if(le===t.KEY_SPACE||le===t.KEY_ENTER){ae.preventDefault(),!E&&J&&J(ae);return}if(le===t.KEY_ESCAPE){ae.preventDefault();return}}return re}()},ie,{children:[I&&!z&&(0,e.createComponentVNode)(2,b.Icon,{name:I,color:U,rotation:L,spin:w,style:$}),W,G,I&&z&&(0,e.createComponentVNode)(2,b.Icon,{name:I,color:U,rotation:L,spin:w,style:$})]})));return D&&(q=(0,e.createComponentVNode)(2,y.Tooltip,{content:D,position:M,children:q})),q}return C}();s.defaultHooks=a.pureComponentHooks;var d=r.ButtonCheckbox=function(){function C(f){var N=f.checked,V=l(f,k);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,s,Object.assign({color:"transparent",icon:N?"check-square-o":"square-o",selected:N},V)))}return C}();s.Checkbox=d;var v=r.ButtonConfirm=function(C){function f(){var V;return V=C.call(this)||this,V.handleClick=function(){V.state.clickedOnce&&V.setClickedOnce(!1)},V.state={clickedOnce:!1},V}c(f,C);var N=f.prototype;return N.setClickedOnce=function(){function V(B){var I=this;this.setState({clickedOnce:B}),B?setTimeout(function(){return window.addEventListener("click",I.handleClick)}):window.removeEventListener("click",this.handleClick)}return V}(),N.render=function(){function V(){var B=this,I=this.props,L=I.confirmContent,w=L===void 0?"Confirm?":L,A=I.confirmColor,x=A===void 0?"bad":A,E=I.confirmIcon,P=I.icon,D=I.color,M=I.content,O=I.onClick,R=l(I,h);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,s,Object.assign({content:this.state.clickedOnce?w:M,icon:this.state.clickedOnce?E:P,color:this.state.clickedOnce?x:D,onClick:function(){function F(W){return B.state.clickedOnce?O==null?void 0:O(W):B.setClickedOnce(!0)}return F}()},R)))}return V}(),f}(e.Component);s.Confirm=v;var g=r.ButtonInput=function(C){function f(){var V;return V=C.call(this)||this,V.inputRef=void 0,V.inputRef=(0,e.createRef)(),V.state={inInput:!1},V}c(f,C);var N=f.prototype;return N.setInInput=function(){function V(B){var I=this.props.disabled;if(!I&&(this.setState({inInput:B}),this.inputRef)){var L=this.inputRef.current;if(B){L.value=this.props.currentValue||"";try{L.focus(),L.select()}catch(w){}}}}return V}(),N.commitResult=function(){function V(B){if(this.inputRef){var I=this.inputRef.current,L=I.value!=="";if(L){this.props.onCommit(B,I.value);return}else{if(!this.props.defaultValue)return;this.props.onCommit(B,this.props.defaultValue)}}}return V}(),N.render=function(){function V(){var B=this,I=this.props,L=I.fluid,w=I.content,A=I.icon,x=I.iconRotation,E=I.iconSpin,P=I.tooltip,D=I.tooltipPosition,M=I.color,O=M===void 0?"default":M,R=I.disabled,F=I.multiLine,W=l(I,i),U=(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.Box,Object.assign({className:(0,a.classes)(["Button",L&&"Button--fluid",R&&"Button--disabled","Button--color--"+O,F+"Button--multiLine"])},W,{onClick:function(){function z(){return B.setInInput(!0)}return z}(),children:[A&&(0,e.createComponentVNode)(2,b.Icon,{name:A,rotation:x,spin:E}),(0,e.createVNode)(1,"div",null,w,0),(0,e.createVNode)(64,"input","NumberInput__input",null,1,{style:{display:this.state.inInput?void 0:"none","text-align":"left"},onBlur:function(){function z($){B.state.inInput&&(B.setInInput(!1),B.commitResult($))}return z}(),onKeyDown:function(){function z($){if($.keyCode===t.KEY_ENTER){B.setInInput(!1),B.commitResult($);return}$.keyCode===t.KEY_ESCAPE&&B.setInInput(!1)}return z}()},null,this.inputRef)]})));return P&&(U=(0,e.createComponentVNode)(2,y.Tooltip,{content:P,position:D,children:U})),U}return V}(),f}(e.Component);s.Input=g},18982:function(T,r,n){"use strict";r.__esModule=!0,r.ByondUi=void 0;var e=n(89005),a=n(35840),t=n(69214),o=n(9394),p=n(55937),b=["params"],y=["params"],S=["parent","params"];function k(v,g){if(v==null)return{};var C={};for(var f in v)if({}.hasOwnProperty.call(v,f)){if(g.includes(f))continue;C[f]=v[f]}return C}function h(v,g){v.prototype=Object.create(g.prototype),v.prototype.constructor=v,i(v,g)}function i(v,g){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(C,f){return C.__proto__=f,C},i(v,g)}/**
+ */function c(v,f){v.prototype=Object.create(f.prototype),v.prototype.constructor=v,m(v,f)}function m(v,f){return m=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(N,V){return N.__proto__=V,N},m(v,f)}function l(v,f){if(v==null)return{};var N={};for(var V in v)if({}.hasOwnProperty.call(v,V)){if(f.includes(V))continue;N[V]=v[V]}return N}var u=(0,o.createLogger)("Button"),s=r.Button=function(){function v(f){var N=f.className,V=f.fluid,B=f.translucent,I=f.icon,L=f.iconRotation,w=f.iconSpin,A=f.color,x=f.textColor,E=f.disabled,P=f.selected,D=f.tooltip,M=f.tooltipPosition,O=f.ellipsis,R=f.compact,F=f.circular,W=f.content,U=f.iconColor,z=f.iconRight,$=f.iconStyle,G=f.children,X=f.onclick,J=f.onClick,se=f.multiLine,ie=l(f,S),me=!!(W||G);X&&u.warn("Lowercase 'onclick' is not supported on Button and lowercase prop names are discouraged in general. Please use a camelCase'onClick' instead and read: https://infernojs.org/docs/guides/event-handling"),ie.onClick=function(re){!E&&J&&J(re)};var q=(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.Box,Object.assign({className:(0,a.classes)(["Button",V&&"Button--fluid",E&&"Button--disabled"+(B?"--translucent":""),P&&"Button--selected"+(B?"--translucent":""),me&&"Button--hasContent",O&&"Button--ellipsis",F&&"Button--circular",R&&"Button--compact",z&&"Button--iconRight",se&&"Button--multiLine",A&&typeof A=="string"?"Button--color--"+A+(B?"--translucent":""):"Button--color--default"+(B?"--translucent":""),N]),tabIndex:!E&&"0",color:x,onKeyDown:function(){function re(ae){var le=window.event?ae.which:ae.keyCode;if(le===t.KEY_SPACE||le===t.KEY_ENTER){ae.preventDefault(),!E&&J&&J(ae);return}if(le===t.KEY_ESCAPE){ae.preventDefault();return}}return re}()},ie,{children:[I&&!z&&(0,e.createComponentVNode)(2,b.Icon,{name:I,color:U,rotation:L,spin:w,style:$}),W,G,I&&z&&(0,e.createComponentVNode)(2,b.Icon,{name:I,color:U,rotation:L,spin:w,style:$})]})));return D&&(q=(0,e.createComponentVNode)(2,y.Tooltip,{content:D,position:M,children:q})),q}return v}();s.defaultHooks=a.pureComponentHooks;var d=r.ButtonCheckbox=function(){function v(f){var N=f.checked,V=l(f,k);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,s,Object.assign({color:"transparent",icon:N?"check-square-o":"square-o",selected:N},V)))}return v}();s.Checkbox=d;var C=r.ButtonConfirm=function(v){function f(){var V;return V=v.call(this)||this,V.handleClick=function(){V.state.clickedOnce&&V.setClickedOnce(!1)},V.state={clickedOnce:!1},V}c(f,v);var N=f.prototype;return N.setClickedOnce=function(){function V(B){var I=this;this.setState({clickedOnce:B}),B?setTimeout(function(){return window.addEventListener("click",I.handleClick)}):window.removeEventListener("click",this.handleClick)}return V}(),N.render=function(){function V(){var B=this,I=this.props,L=I.confirmContent,w=L===void 0?"Confirm?":L,A=I.confirmColor,x=A===void 0?"bad":A,E=I.confirmIcon,P=I.icon,D=I.color,M=I.content,O=I.onClick,R=l(I,h);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,s,Object.assign({content:this.state.clickedOnce?w:M,icon:this.state.clickedOnce?E:P,color:this.state.clickedOnce?x:D,onClick:function(){function F(W){return B.state.clickedOnce?O==null?void 0:O(W):B.setClickedOnce(!0)}return F}()},R)))}return V}(),f}(e.Component);s.Confirm=C;var g=r.ButtonInput=function(v){function f(){var V;return V=v.call(this)||this,V.inputRef=void 0,V.inputRef=(0,e.createRef)(),V.state={inInput:!1},V}c(f,v);var N=f.prototype;return N.setInInput=function(){function V(B){var I=this.props.disabled;if(!I&&(this.setState({inInput:B}),this.inputRef)){var L=this.inputRef.current;if(B){L.value=this.props.currentValue||"";try{L.focus(),L.select()}catch(w){}}}}return V}(),N.commitResult=function(){function V(B){if(this.inputRef){var I=this.inputRef.current,L=I.value!=="";if(L){this.props.onCommit(B,I.value);return}else{if(!this.props.defaultValue)return;this.props.onCommit(B,this.props.defaultValue)}}}return V}(),N.render=function(){function V(){var B=this,I=this.props,L=I.fluid,w=I.content,A=I.icon,x=I.iconRotation,E=I.iconSpin,P=I.tooltip,D=I.tooltipPosition,M=I.color,O=M===void 0?"default":M,R=I.disabled,F=I.multiLine,W=l(I,i),U=(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.Box,Object.assign({className:(0,a.classes)(["Button",L&&"Button--fluid",R&&"Button--disabled","Button--color--"+O,F+"Button--multiLine"])},W,{onClick:function(){function z(){return B.setInInput(!0)}return z}(),children:[A&&(0,e.createComponentVNode)(2,b.Icon,{name:A,rotation:x,spin:E}),(0,e.createVNode)(1,"div",null,w,0),(0,e.createVNode)(64,"input","NumberInput__input",null,1,{style:{display:this.state.inInput?void 0:"none","text-align":"left"},onBlur:function(){function z($){B.state.inInput&&(B.setInInput(!1),B.commitResult($))}return z}(),onKeyDown:function(){function z($){if($.keyCode===t.KEY_ENTER){B.setInInput(!1),B.commitResult($);return}$.keyCode===t.KEY_ESCAPE&&B.setInInput(!1)}return z}()},null,this.inputRef)]})));return P&&(U=(0,e.createComponentVNode)(2,y.Tooltip,{content:P,position:D,children:U})),U}return V}(),f}(e.Component);s.Input=g},18982:function(T,r,n){"use strict";r.__esModule=!0,r.ByondUi=void 0;var e=n(89005),a=n(35840),t=n(69214),o=n(9394),p=n(55937),b=["params"],y=["params"],S=["parent","params"];function k(C,g){if(C==null)return{};var v={};for(var f in C)if({}.hasOwnProperty.call(C,f)){if(g.includes(f))continue;v[f]=C[f]}return v}function h(C,g){C.prototype=Object.create(g.prototype),C.prototype.constructor=C,i(C,g)}function i(C,g){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(v,f){return v.__proto__=f,v},i(C,g)}/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
-*/var c=(0,o.createLogger)("ByondUi"),m=[],l=function(g){var C=m.length;m.push(null);var f=g||"byondui_"+C;return c.log("allocated '"+f+"'"),{render:function(){function N(V){c.log("rendering '"+f+"'"),m[C]=f,Byond.winset(f,V)}return N}(),unmount:function(){function N(){c.log("unmounting '"+f+"'"),m[C]=null,Byond.winset(f,{parent:""})}return N}()}};window.addEventListener("beforeunload",function(){for(var v=0;v0){var M=D[0],O=D[D.length-1];D.push([P[0]+x,O[1]]),D.push([P[0]+x,-x]),D.push([-x,-x]),D.push([-x,M[1]])}var R=h(D);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Box,Object.assign({position:"relative"},E,{children:function(){function F(W){return(0,e.normalizeProps)((0,e.createVNode)(1,"div",null,(0,e.createVNode)(32,"svg",null,(0,e.createVNode)(32,"polyline",null,null,1,{transform:"scale(1, -1) translate(0, -"+P[1]+")",fill:I,stroke:w,"stroke-width":x,points:R}),2,{viewBox:"0 0 "+P[0]+" "+P[1],preserveAspectRatio:"none",style:{position:"absolute",top:0,left:0,right:0,bottom:0,overflow:"hidden"}}),2,Object.assign({},W),null,v.ref))}return F}()})))}return d}(),u}(e.Component);i.defaultHooks=t.pureComponentHooks;var c=function(u){return null},m=r.Chart={Line:i}},4796:function(T,r,n){"use strict";r.__esModule=!0,r.Collapsible=void 0;var e=n(89005),a=n(55937),t=n(96184),o=["children","color","title","buttons","contentStyle"];function p(k,h){if(k==null)return{};var i={};for(var c in k)if({}.hasOwnProperty.call(k,c)){if(h.includes(c))continue;i[c]=k[c]}return i}function b(k,h){k.prototype=Object.create(h.prototype),k.prototype.constructor=k,y(k,h)}function y(k,h){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,c){return i.__proto__=c,i},y(k,h)}/**
+*/var k=function(u,s,d,C){if(u.length===0)return[];var g=(0,a.zipWith)(Math.min).apply(void 0,u),v=(0,a.zipWith)(Math.max).apply(void 0,u);d!==void 0&&(g[0]=d[0],v[0]=d[1]),C!==void 0&&(g[1]=C[0],v[1]=C[1]);var f=(0,a.map)(function(N){return(0,a.zipWith)(function(V,B,I,L){return(V-B)/(I-B)*L})(N,g,v,s)})(u);return f},h=function(u){for(var s="",d=0;d0){var M=D[0],O=D[D.length-1];D.push([P[0]+x,O[1]]),D.push([P[0]+x,-x]),D.push([-x,-x]),D.push([-x,M[1]])}var R=h(D);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Box,Object.assign({position:"relative"},E,{children:function(){function F(W){return(0,e.normalizeProps)((0,e.createVNode)(1,"div",null,(0,e.createVNode)(32,"svg",null,(0,e.createVNode)(32,"polyline",null,null,1,{transform:"scale(1, -1) translate(0, -"+P[1]+")",fill:I,stroke:w,"stroke-width":x,points:R}),2,{viewBox:"0 0 "+P[0]+" "+P[1],preserveAspectRatio:"none",style:{position:"absolute",top:0,left:0,right:0,bottom:0,overflow:"hidden"}}),2,Object.assign({},W),null,C.ref))}return F}()})))}return d}(),u}(e.Component);i.defaultHooks=t.pureComponentHooks;var c=function(u){return null},m=r.Chart={Line:i}},4796:function(T,r,n){"use strict";r.__esModule=!0,r.Collapsible=void 0;var e=n(89005),a=n(55937),t=n(96184),o=["children","color","title","buttons","contentStyle"];function p(k,h){if(k==null)return{};var i={};for(var c in k)if({}.hasOwnProperty.call(k,c)){if(h.includes(c))continue;i[c]=k[c]}return i}function b(k,h){k.prototype=Object.create(h.prototype),k.prototype.constructor=k,y(k,h)}function y(k,h){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,c){return i.__proto__=c,i},y(k,h)}/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
-*/var S=r.Collapsible=function(k){function h(c){var m;m=k.call(this,c)||this;var l=c.open;return m.state={open:l||!1},m}b(h,k);var i=h.prototype;return i.render=function(){function c(){var m=this,l=this.props,u=this.state.open,s=l.children,d=l.color,v=d===void 0?"default":d,g=l.title,C=l.buttons,f=l.contentStyle,N=p(l,o);return(0,e.createComponentVNode)(2,a.Box,{className:"Collapsible",children:[(0,e.createVNode)(1,"div","Table",[(0,e.createVNode)(1,"div","Table__cell",(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Button,Object.assign({fluid:!0,color:v,icon:u?"chevron-down":"chevron-right",onClick:function(){function V(){return m.setState({open:!u})}return V}()},N,{children:g}))),2),C&&(0,e.createVNode)(1,"div","Table__cell Table__cell--collapsing",C,0)],0),u&&(0,e.createComponentVNode)(2,a.Box,{mt:1,style:f,children:s})]})}return c}(),h}(e.Component)},88894:function(T,r,n){"use strict";r.__esModule=!0,r.ColorBox=void 0;var e=n(89005),a=n(35840),t=n(55937),o=["content","children","className","color","backgroundColor"];/**
+*/var S=r.Collapsible=function(k){function h(c){var m;m=k.call(this,c)||this;var l=c.open;return m.state={open:l||!1},m}b(h,k);var i=h.prototype;return i.render=function(){function c(){var m=this,l=this.props,u=this.state.open,s=l.children,d=l.color,C=d===void 0?"default":d,g=l.title,v=l.buttons,f=l.contentStyle,N=p(l,o);return(0,e.createComponentVNode)(2,a.Box,{className:"Collapsible",children:[(0,e.createVNode)(1,"div","Table",[(0,e.createVNode)(1,"div","Table__cell",(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Button,Object.assign({fluid:!0,color:C,icon:u?"chevron-down":"chevron-right",onClick:function(){function V(){return m.setState({open:!u})}return V}()},N,{children:g}))),2),v&&(0,e.createVNode)(1,"div","Table__cell Table__cell--collapsing",v,0)],0),u&&(0,e.createComponentVNode)(2,a.Box,{mt:1,style:f,children:s})]})}return c}(),h}(e.Component)},88894:function(T,r,n){"use strict";r.__esModule=!0,r.ColorBox=void 0;var e=n(89005),a=n(35840),t=n(55937),o=["content","children","className","color","backgroundColor"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -117,11 +117,11 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var t=r.Divider=function(){function o(p){var b=p.vertical,y=p.hidden;return(0,e.createVNode)(1,"div",(0,a.classes)(["Divider",y&&"Divider--hidden",b?"Divider--vertical":"Divider--horizontal"]))}return o}()},60218:function(T,r,n){"use strict";r.__esModule=!0,r.DmIcon=void 0;var e=n(89005),a=n(79140),t=n(46085),o=n(91225),p=["className","direction","fallback","frame","icon_state","movement"];function b(u,s){if(u==null)return{};var d={};for(var v in u)if({}.hasOwnProperty.call(u,v)){if(s.includes(v))continue;d[v]=u[v]}return d}function y(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */y=function(){return s};var u,s={},d=Object.prototype,v=d.hasOwnProperty,g=Object.defineProperty||function(q,re,ae){q[re]=ae.value},C=typeof Symbol=="function"?Symbol:{},f=C.iterator||"@@iterator",N=C.asyncIterator||"@@asyncIterator",V=C.toStringTag||"@@toStringTag";function B(q,re,ae){return Object.defineProperty(q,re,{value:ae,enumerable:!0,configurable:!0,writable:!0}),q[re]}try{B({},"")}catch(q){B=function(ae,le,Z){return ae[le]=Z}}function I(q,re,ae,le){var Z=re&&re.prototype instanceof D?re:D,ne=Object.create(Z.prototype),te=new ie(le||[]);return g(ne,"_invoke",{value:G(q,ae,te)}),ne}function L(q,re,ae){try{return{type:"normal",arg:q.call(re,ae)}}catch(le){return{type:"throw",arg:le}}}s.wrap=I;var w="suspendedStart",A="suspendedYield",x="executing",E="completed",P={};function D(){}function M(){}function O(){}var R={};B(R,f,function(){return this});var F=Object.getPrototypeOf,W=F&&F(F(me([])));W&&W!==d&&v.call(W,f)&&(R=W);var U=O.prototype=D.prototype=Object.create(R);function z(q){["next","throw","return"].forEach(function(re){B(q,re,function(ae){return this._invoke(re,ae)})})}function $(q,re){function ae(Z,ne,te,fe){var pe=L(q[Z],q,ne);if(pe.type!=="throw"){var ce=pe.arg,Ve=ce.value;return Ve&&typeof Ve=="object"&&v.call(Ve,"__await")?re.resolve(Ve.__await).then(function(Ce){ae("next",Ce,te,fe)},function(Ce){ae("throw",Ce,te,fe)}):re.resolve(Ve).then(function(Ce){ce.value=Ce,te(ce)},function(Ce){return ae("throw",Ce,te,fe)})}fe(pe.arg)}var le;g(this,"_invoke",{value:function(){function Z(ne,te){function fe(){return new re(function(pe,ce){ae(ne,te,pe,ce)})}return le=le?le.then(fe,fe):fe()}return Z}()})}function G(q,re,ae){var le=w;return function(Z,ne){if(le===x)throw Error("Generator is already running");if(le===E){if(Z==="throw")throw ne;return{value:u,done:!0}}for(ae.method=Z,ae.arg=ne;;){var te=ae.delegate;if(te){var fe=X(te,ae);if(fe){if(fe===P)continue;return fe}}if(ae.method==="next")ae.sent=ae._sent=ae.arg;else if(ae.method==="throw"){if(le===w)throw le=E,ae.arg;ae.dispatchException(ae.arg)}else ae.method==="return"&&ae.abrupt("return",ae.arg);le=x;var pe=L(q,re,ae);if(pe.type==="normal"){if(le=ae.done?E:A,pe.arg===P)continue;return{value:pe.arg,done:ae.done}}pe.type==="throw"&&(le=E,ae.method="throw",ae.arg=pe.arg)}}}function X(q,re){var ae=re.method,le=q.iterator[ae];if(le===u)return re.delegate=null,ae==="throw"&&q.iterator.return&&(re.method="return",re.arg=u,X(q,re),re.method==="throw")||ae!=="return"&&(re.method="throw",re.arg=new TypeError("The iterator does not provide a '"+ae+"' method")),P;var Z=L(le,q.iterator,re.arg);if(Z.type==="throw")return re.method="throw",re.arg=Z.arg,re.delegate=null,P;var ne=Z.arg;return ne?ne.done?(re[q.resultName]=ne.value,re.next=q.nextLoc,re.method!=="return"&&(re.method="next",re.arg=u),re.delegate=null,P):ne:(re.method="throw",re.arg=new TypeError("iterator result is not an object"),re.delegate=null,P)}function J(q){var re={tryLoc:q[0]};1 in q&&(re.catchLoc=q[1]),2 in q&&(re.finallyLoc=q[2],re.afterLoc=q[3]),this.tryEntries.push(re)}function se(q){var re=q.completion||{};re.type="normal",delete re.arg,q.completion=re}function ie(q){this.tryEntries=[{tryLoc:"root"}],q.forEach(J,this),this.reset(!0)}function me(q){if(q||q===""){var re=q[f];if(re)return re.call(q);if(typeof q.next=="function")return q;if(!isNaN(q.length)){var ae=-1,le=function(){function Z(){for(;++ae=0;--Z){var ne=this.tryEntries[Z],te=ne.completion;if(ne.tryLoc==="root")return le("end");if(ne.tryLoc<=this.prev){var fe=v.call(ne,"catchLoc"),pe=v.call(ne,"finallyLoc");if(fe&&pe){if(this.prev=0;--le){var Z=this.tryEntries[le];if(Z.tryLoc<=this.prev&&v.call(Z,"finallyLoc")&&this.prev=0;--ae){var le=this.tryEntries[ae];if(le.finallyLoc===re)return this.complete(le.completion,le.afterLoc),se(le),P}}return q}(),catch:function(){function q(re){for(var ae=this.tryEntries.length-1;ae>=0;--ae){var le=this.tryEntries[ae];if(le.tryLoc===re){var Z=le.completion;if(Z.type==="throw"){var ne=Z.arg;se(le)}return ne}}throw Error("illegal catch attempt")}return q}(),delegateYield:function(){function q(re,ae,le){return this.delegate={iterator:me(re),resultName:ae,nextLoc:le},this.method==="next"&&(this.arg=u),P}return q}()},s}function S(u,s,d,v,g,C,f){try{var N=u[C](f),V=N.value}catch(B){return void d(B)}N.done?s(V):Promise.resolve(V).then(v,g)}function k(u){return function(){var s=this,d=arguments;return new Promise(function(v,g){var C=u.apply(s,d);function f(V){S(C,v,g,f,N,"next",V)}function N(V){S(C,v,g,f,N,"throw",V)}f(void 0)})}}function h(u,s){u.prototype=Object.create(s.prototype),u.prototype.constructor=u,i(u,s)}function i(u,s){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(d,v){return d.__proto__=v,d},i(u,s)}var c=function(u){return u[u.NORTH=1]="NORTH",u[u.SOUTH=2]="SOUTH",u[u.EAST=4]="EAST",u[u.WEST=8]="WEST",u[u.NORTHEAST=5]="NORTHEAST",u[u.NORTHWEST=9]="NORTHWEST",u[u.SOUTHEAST=6]="SOUTHEAST",u[u.SOUTHWEST=10]="SOUTHWEST",u}(c||{}),m,l=r.DmIcon=function(u){function s(v){var g;return g=u.call(this,v)||this,g.state={iconRef:""},g}h(s,u);var d=s.prototype;return d.fetchRefMap=function(){var v=k(y().mark(function(){function C(){var f,N;return y().wrap(function(){function V(B){for(;;)switch(B.prev=B.next){case 0:return B.prev=0,B.next=3,(0,t.fetchRetry)((0,a.resolveAsset)("icon_ref_map.json"));case 3:return f=B.sent,B.next=6,f.json();case 6:N=B.sent,m=N,this.setState({iconRef:N[this.props.icon]||""}),B.next=14;break;case 11:return B.prev=11,B.t0=B.catch(0),B.abrupt("return");case 14:case"end":return B.stop()}}return V}(),C,this,[[0,11]])}return C}()));function g(){return v.apply(this,arguments)}return g}(),d.componentDidMount=function(){function v(){m?this.setState({iconRef:m[this.props.icon]}):this.fetchRefMap()}return v}(),d.componentDidUpdate=function(){function v(g){g.icon!==this.props.icon&&(m?this.setState({iconRef:m[this.props.icon]}):this.fetchRefMap())}return v}(),d.render=function(){function v(){var g=this.props,C=g.className,f=g.direction,N=f===void 0?c.SOUTH:f,V=g.fallback,B=g.frame,I=B===void 0?1:B,L=g.icon_state,w=g.movement,A=w===void 0?!1:w,x=b(g,p),E=this.state.iconRef,P=E+"?state="+L+"&dir="+N+"&movement="+!!A+"&frame="+I;return E?(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Image,Object.assign({fixErrors:!0,src:P},x))):V||null}return v}(),s}(e.Component)},20342:function(T,r,n){"use strict";r.__esModule=!0,r.DraggableControl=void 0;var e=n(89005),a=n(44879),t=n(35840),o=n(9474);function p(h,i){h.prototype=Object.create(i.prototype),h.prototype.constructor=h,b(h,i)}function b(h,i){return b=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(c,m){return c.__proto__=m,c},b(h,i)}var y=400,S=function(i,c){return i.screenX*c[0]+i.screenY*c[1]},k=r.DraggableControl=function(h){function i(m){var l;return l=h.call(this,m)||this,l.inputRef=(0,e.createRef)(),l.state={originalValue:m.value,value:m.value,dragging:!1,editing:!1,origin:null,suppressingFlicker:!1},l.flickerTimer=null,l.suppressFlicker=function(){var u=l.props.suppressFlicker;u>0&&(l.setState({suppressingFlicker:!0}),clearTimeout(l.flickerTimer),l.flickerTimer=setTimeout(function(){return l.setState({suppressingFlicker:!1})},u))},l.handleDragStart=function(u){var s=l.props,d=s.value,v=s.dragMatrix,g=s.disabled,C=l.state.editing;C||g||(document.body.style["pointer-events"]="none",l.ref=u.currentTarget,l.setState({originalValue:d,dragging:!1,value:d,origin:S(u,v)}),l.timer=setTimeout(function(){l.setState({dragging:!0})},250),l.dragInterval=setInterval(function(){var f=l.state,N=f.dragging,V=f.value,B=l.props.onDrag;N&&B&&B(u,V)},l.props.updateRate||y),document.addEventListener("mousemove",l.handleDragMove),document.addEventListener("mouseup",l.handleDragEnd))},l.handleDragMove=function(u){var s,d=l.props,v=d.minValue,g=d.maxValue,C=d.step,f=d.dragMatrix,N=d.disabled;if(!N){var V=l.ref.offsetWidth/((g-v)/C),B=(s=l.props.stepPixelSize)!=null?s:V;typeof B=="function"&&(B=B(V)),l.setState(function(I){var L=Object.assign({},I),w=I.origin,A=S(u,f)-w;if(I.dragging){var x=Math.trunc(A/B);L.value=(0,a.clamp)(Math.floor(L.originalValue/C)*C+x*C,v,g)}else Math.abs(A)>4&&(L.dragging=!0);return L})}},l.handleDragEnd=function(u){var s=l.props,d=s.onChange,v=s.onDrag,g=l.state,C=g.dragging,f=g.value;if(document.body.style["pointer-events"]="auto",clearTimeout(l.timer),clearInterval(l.dragInterval),l.setState({originalValue:null,dragging:!1,editing:!C,origin:null}),document.removeEventListener("mousemove",l.handleDragMove),document.removeEventListener("mouseup",l.handleDragEnd),C)l.suppressFlicker(),d&&d(u,f),v&&v(u,f);else if(l.inputRef){var N=l.inputRef.current;N.value=f;try{N.focus(),N.select()}catch(V){}}},l}p(i,h);var c=i.prototype;return c.render=function(){function m(){var l=this,u=this.state,s=u.dragging,d=u.editing,v=u.value,g=u.suppressingFlicker,C=this.props,f=C.animated,N=C.value,V=C.unit,B=C.minValue,I=C.maxValue,L=C.format,w=C.onChange,A=C.onDrag,x=C.children,E=C.height,P=C.lineHeight,D=C.fontSize,M=C.disabled,O=N;(s||g)&&(O=v);var R=function(){function U(z){return z+(V?" "+V:"")}return U}(),F=f&&!s&&!g&&(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:O,format:L,children:R})||R(L?L(O):O),W=(0,e.createVNode)(64,"input","NumberInput__input",null,1,{style:{display:!d||M?"none":void 0,height:E,"line-height":P,"font-size":D},onBlur:function(){function U(z){if(d){var $=(0,a.clamp)(parseFloat(z.target.value),B,I);if(Number.isNaN($)){l.setState({editing:!1});return}l.setState({editing:!1,value:$}),l.suppressFlicker(),w&&w(z,$),A&&A(z,$)}}return U}(),onKeyDown:function(){function U(z){if(z.keyCode===13){var $=(0,a.clamp)(parseFloat(z.target.value),B,I);if(Number.isNaN($)){l.setState({editing:!1});return}l.setState({editing:!1,value:$}),l.suppressFlicker(),w&&w(z,$),A&&A(z,$);return}if(z.keyCode===27){l.setState({editing:!1});return}}return U}(),disabled:M},null,this.inputRef);return x({dragging:s,editing:d,value:N,displayValue:O,displayElement:F,inputElement:W,handleDragStart:this.handleDragStart})}return m}(),i}(e.Component);k.defaultHooks=t.pureComponentHooks,k.defaultProps={minValue:-1/0,maxValue:1/0,step:1,suppressFlicker:50,dragMatrix:[1,0]}},87099:function(T,r,n){"use strict";r.__esModule=!0,r.Dropdown=void 0;var e=n(89005),a=n(95996),t=n(35840),o=n(55937),p=n(96184),b=n(1331),y=n(96690),S=["icon","iconRotation","iconSpin","clipSelectedText","color","dropdownStyle","over","nochevron","width","onClick","onSelected","selected","disabled","displayText","buttons"],k=["className"],h;function i(g,C){if(g==null)return{};var f={};for(var N in g)if({}.hasOwnProperty.call(g,N)){if(C.includes(N))continue;f[N]=g[N]}return f}function c(g,C){g.prototype=Object.create(C.prototype),g.prototype.constructor=g,m(g,C)}function m(g,C){return m=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,N){return f.__proto__=N,f},m(g,C)}var l={placement:"left-start",modifiers:[{name:"eventListeners",enabled:!1}]},u={width:0,height:0,top:0,right:0,bottom:0,left:0,x:0,y:0,toJSON:function(){function g(){return null}return g}()},s="Layout Dropdown__menu",d="Layout Dropdown__menu-scroll",v=r.Dropdown=function(g){function C(N){var V;return V=g.call(this,N)||this,V.menuContents=void 0,V.handleClick=function(){V.state.open&&V.setOpen(!1)},V.state={open:!1,selected:V.props.selected},V.menuContents=null,V}c(C,g);var f=C.prototype;return f.getDOMNode=function(){function N(){return(0,e.findDOMFromVNode)(this.$LI,!0)}return N}(),f.componentDidMount=function(){function N(){var V=this.getDOMNode()}return N}(),f.openMenu=function(){function N(){var V=C.renderedMenu;V===void 0&&(V=document.createElement("div"),V.className=s,document.body.appendChild(V),C.renderedMenu=V);var B=this.getDOMNode();C.currentOpenMenu=B,V.scrollTop=0,V.style.width=this.props.menuWidth||B.offsetWidth+"px",V.style.opacity="1",V.style.pointerEvents="auto",setTimeout(function(){var I;(I=C.renderedMenu)==null||I.focus()},400),this.renderMenuContent()}return N}(),f.closeMenu=function(){function N(){C.currentOpenMenu===this.getDOMNode()&&(C.currentOpenMenu=void 0,C.renderedMenu.style.opacity="0",C.renderedMenu.style.pointerEvents="none")}return N}(),f.componentWillUnmount=function(){function N(){this.closeMenu(),this.setOpen(!1)}return N}(),f.renderMenuContent=function(){function N(){var V=this,B=C.renderedMenu;if(B){B.offsetHeight>200?B.className=d:B.className=s;var I=this.props.options,L=I===void 0?[]:I,w=L.map(function(x){var E,P;return typeof x=="string"?(P=x,E=x):x!==null&&(P=x.displayText,E=x.value),(0,e.createVNode)(1,"div",(0,t.classes)(["Dropdown__menuentry",V.state.selected===E&&"selected"]),P,0,{onClick:function(){function D(){V.setSelected(E)}return D}()},E)}),A=w.length?w:"No Options Found";(0,e.render)((0,e.createVNode)(1,"div",null,A,0),B,function(){var x=C.singletonPopper;x===void 0?(x=(0,a.createPopper)(C.virtualElement,B,Object.assign({},l,{placement:"bottom-start"})),C.singletonPopper=x):(x.setOptions(Object.assign({},l,{placement:"bottom-start"})),x.update())},this.context)}}return N}(),f.setOpen=function(){function N(V){var B=this;this.setState(function(I){return Object.assign({},I,{open:V})}),V?setTimeout(function(){B.openMenu(),window.addEventListener("click",B.handleClick)}):(this.closeMenu(),window.removeEventListener("click",this.handleClick))}return N}(),f.setSelected=function(){function N(V){this.setState(function(B){return Object.assign({},B,{selected:V})}),this.setOpen(!1),this.props.onSelected&&this.props.onSelected(V)}return N}(),f.getOptionValue=function(){function N(V){return typeof V=="string"?V:V.value}return N}(),f.getSelectedIndex=function(){function N(){var V=this,B=this.state.selected||this.props.selected,I=this.props.options,L=I===void 0?[]:I;return L.findIndex(function(w){return V.getOptionValue(w)===B})}return N}(),f.toPrevious=function(){function N(){if(!(this.props.options.length<1)){var V=this.getSelectedIndex(),B=0,I=this.props.options.length-1,L=V>=0;L||(V=B);var w=V===B?I:V-1;this.setSelected(this.getOptionValue(this.props.options[w]))}}return N}(),f.toNext=function(){function N(){if(!(this.props.options.length<1)){var V=this.getSelectedIndex(),B=0,I=this.props.options.length-1,L=V>=0;L||(V=I);var w=V===I?B:V+1;this.setSelected(this.getOptionValue(this.props.options[w]))}}return N}(),f.render=function(){function N(){var V=this,B=this.props,I=B.icon,L=B.iconRotation,w=B.iconSpin,A=B.clipSelectedText,x=A===void 0?!0:A,E=B.color,P=E===void 0?"default":E,D=B.dropdownStyle,M=B.over,O=B.nochevron,R=B.width,F=B.onClick,W=B.onSelected,U=B.selected,z=B.disabled,$=B.displayText,G=B.buttons,X=i(B,S),J=X.className,se=i(X,k),ie=M?!this.state.open:this.state.open;return(0,e.createComponentVNode)(2,y.Stack,{inline:!0,fill:!0,width:R,children:[(0,e.createComponentVNode)(2,y.Stack.Item,{grow:!0,children:(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Box,Object.assign({width:"100%",className:(0,t.classes)(["Dropdown__control","Button","Button--color--"+P,z&&"Button--disabled",J]),onClick:function(){function me(q){z&&!V.state.open||(V.setOpen(!V.state.open),F&&F(q))}return me}()},se,{children:[I&&(0,e.createComponentVNode)(2,b.Icon,{name:I,rotation:L,spin:w,mr:1}),(0,e.createVNode)(1,"span","Dropdown__selected-text",$||this.state.selected,0,{style:{overflow:x?"hidden":"visible"}}),O||(0,e.createVNode)(1,"span","Dropdown__arrow-button",(0,e.createComponentVNode)(2,b.Icon,{name:ie?"chevron-up":"chevron-down"}),2)]})))}),G&&(0,e.createFragment)([(0,e.createComponentVNode)(2,y.Stack.Item,{height:"100%",children:(0,e.createComponentVNode)(2,p.Button,{height:"100%",icon:"chevron-left",disabled:z,onClick:function(){function me(){z||V.toPrevious()}return me}()})}),(0,e.createComponentVNode)(2,y.Stack.Item,{height:"100%",children:(0,e.createComponentVNode)(2,p.Button,{height:"100%",icon:"chevron-right",disabled:z,onClick:function(){function me(){z||V.toNext()}return me}()})})],4)]})}return N}(),C}(e.Component);h=v,v.renderedMenu=void 0,v.singletonPopper=void 0,v.currentOpenMenu=void 0,v.virtualElement={getBoundingClientRect:function(){function g(){var C,f;return(C=(f=h.currentOpenMenu)==null?void 0:f.getBoundingClientRect())!=null?C:u}return g}()}},39473:function(T,r,n){"use strict";r.__esModule=!0,r.computeFlexProps=r.computeFlexItemProps=r.computeFlexItemClassName=r.computeFlexClassName=r.Flex=void 0;var e=n(89005),a=n(35840),t=n(55937),o=["className","direction","wrap","align","justify","inline","style"],p=["className"],b=["className","style","grow","order","shrink","basis","align"],y=["className"];/**
+ */var t=r.Divider=function(){function o(p){var b=p.vertical,y=p.hidden;return(0,e.createVNode)(1,"div",(0,a.classes)(["Divider",y&&"Divider--hidden",b?"Divider--vertical":"Divider--horizontal"]))}return o}()},60218:function(T,r,n){"use strict";r.__esModule=!0,r.DmIcon=void 0;var e=n(89005),a=n(79140),t=n(46085),o=n(91225),p=["className","direction","fallback","frame","icon_state","movement"];function b(u,s){if(u==null)return{};var d={};for(var C in u)if({}.hasOwnProperty.call(u,C)){if(s.includes(C))continue;d[C]=u[C]}return d}function y(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */y=function(){return s};var u,s={},d=Object.prototype,C=d.hasOwnProperty,g=Object.defineProperty||function(q,re,ae){q[re]=ae.value},v=typeof Symbol=="function"?Symbol:{},f=v.iterator||"@@iterator",N=v.asyncIterator||"@@asyncIterator",V=v.toStringTag||"@@toStringTag";function B(q,re,ae){return Object.defineProperty(q,re,{value:ae,enumerable:!0,configurable:!0,writable:!0}),q[re]}try{B({},"")}catch(q){B=function(ae,le,Z){return ae[le]=Z}}function I(q,re,ae,le){var Z=re&&re.prototype instanceof D?re:D,ne=Object.create(Z.prototype),te=new ie(le||[]);return g(ne,"_invoke",{value:G(q,ae,te)}),ne}function L(q,re,ae){try{return{type:"normal",arg:q.call(re,ae)}}catch(le){return{type:"throw",arg:le}}}s.wrap=I;var w="suspendedStart",A="suspendedYield",x="executing",E="completed",P={};function D(){}function M(){}function O(){}var R={};B(R,f,function(){return this});var F=Object.getPrototypeOf,W=F&&F(F(me([])));W&&W!==d&&C.call(W,f)&&(R=W);var U=O.prototype=D.prototype=Object.create(R);function z(q){["next","throw","return"].forEach(function(re){B(q,re,function(ae){return this._invoke(re,ae)})})}function $(q,re){function ae(Z,ne,te,fe){var pe=L(q[Z],q,ne);if(pe.type!=="throw"){var ce=pe.arg,Ve=ce.value;return Ve&&typeof Ve=="object"&&C.call(Ve,"__await")?re.resolve(Ve.__await).then(function(Ce){ae("next",Ce,te,fe)},function(Ce){ae("throw",Ce,te,fe)}):re.resolve(Ve).then(function(Ce){ce.value=Ce,te(ce)},function(Ce){return ae("throw",Ce,te,fe)})}fe(pe.arg)}var le;g(this,"_invoke",{value:function(){function Z(ne,te){function fe(){return new re(function(pe,ce){ae(ne,te,pe,ce)})}return le=le?le.then(fe,fe):fe()}return Z}()})}function G(q,re,ae){var le=w;return function(Z,ne){if(le===x)throw Error("Generator is already running");if(le===E){if(Z==="throw")throw ne;return{value:u,done:!0}}for(ae.method=Z,ae.arg=ne;;){var te=ae.delegate;if(te){var fe=X(te,ae);if(fe){if(fe===P)continue;return fe}}if(ae.method==="next")ae.sent=ae._sent=ae.arg;else if(ae.method==="throw"){if(le===w)throw le=E,ae.arg;ae.dispatchException(ae.arg)}else ae.method==="return"&&ae.abrupt("return",ae.arg);le=x;var pe=L(q,re,ae);if(pe.type==="normal"){if(le=ae.done?E:A,pe.arg===P)continue;return{value:pe.arg,done:ae.done}}pe.type==="throw"&&(le=E,ae.method="throw",ae.arg=pe.arg)}}}function X(q,re){var ae=re.method,le=q.iterator[ae];if(le===u)return re.delegate=null,ae==="throw"&&q.iterator.return&&(re.method="return",re.arg=u,X(q,re),re.method==="throw")||ae!=="return"&&(re.method="throw",re.arg=new TypeError("The iterator does not provide a '"+ae+"' method")),P;var Z=L(le,q.iterator,re.arg);if(Z.type==="throw")return re.method="throw",re.arg=Z.arg,re.delegate=null,P;var ne=Z.arg;return ne?ne.done?(re[q.resultName]=ne.value,re.next=q.nextLoc,re.method!=="return"&&(re.method="next",re.arg=u),re.delegate=null,P):ne:(re.method="throw",re.arg=new TypeError("iterator result is not an object"),re.delegate=null,P)}function J(q){var re={tryLoc:q[0]};1 in q&&(re.catchLoc=q[1]),2 in q&&(re.finallyLoc=q[2],re.afterLoc=q[3]),this.tryEntries.push(re)}function se(q){var re=q.completion||{};re.type="normal",delete re.arg,q.completion=re}function ie(q){this.tryEntries=[{tryLoc:"root"}],q.forEach(J,this),this.reset(!0)}function me(q){if(q||q===""){var re=q[f];if(re)return re.call(q);if(typeof q.next=="function")return q;if(!isNaN(q.length)){var ae=-1,le=function(){function Z(){for(;++ae=0;--Z){var ne=this.tryEntries[Z],te=ne.completion;if(ne.tryLoc==="root")return le("end");if(ne.tryLoc<=this.prev){var fe=C.call(ne,"catchLoc"),pe=C.call(ne,"finallyLoc");if(fe&&pe){if(this.prev=0;--le){var Z=this.tryEntries[le];if(Z.tryLoc<=this.prev&&C.call(Z,"finallyLoc")&&this.prev=0;--ae){var le=this.tryEntries[ae];if(le.finallyLoc===re)return this.complete(le.completion,le.afterLoc),se(le),P}}return q}(),catch:function(){function q(re){for(var ae=this.tryEntries.length-1;ae>=0;--ae){var le=this.tryEntries[ae];if(le.tryLoc===re){var Z=le.completion;if(Z.type==="throw"){var ne=Z.arg;se(le)}return ne}}throw Error("illegal catch attempt")}return q}(),delegateYield:function(){function q(re,ae,le){return this.delegate={iterator:me(re),resultName:ae,nextLoc:le},this.method==="next"&&(this.arg=u),P}return q}()},s}function S(u,s,d,C,g,v,f){try{var N=u[v](f),V=N.value}catch(B){return void d(B)}N.done?s(V):Promise.resolve(V).then(C,g)}function k(u){return function(){var s=this,d=arguments;return new Promise(function(C,g){var v=u.apply(s,d);function f(V){S(v,C,g,f,N,"next",V)}function N(V){S(v,C,g,f,N,"throw",V)}f(void 0)})}}function h(u,s){u.prototype=Object.create(s.prototype),u.prototype.constructor=u,i(u,s)}function i(u,s){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(d,C){return d.__proto__=C,d},i(u,s)}var c=function(u){return u[u.NORTH=1]="NORTH",u[u.SOUTH=2]="SOUTH",u[u.EAST=4]="EAST",u[u.WEST=8]="WEST",u[u.NORTHEAST=5]="NORTHEAST",u[u.NORTHWEST=9]="NORTHWEST",u[u.SOUTHEAST=6]="SOUTHEAST",u[u.SOUTHWEST=10]="SOUTHWEST",u}(c||{}),m,l=r.DmIcon=function(u){function s(C){var g;return g=u.call(this,C)||this,g.state={iconRef:""},g}h(s,u);var d=s.prototype;return d.fetchRefMap=function(){var C=k(y().mark(function(){function v(){var f,N;return y().wrap(function(){function V(B){for(;;)switch(B.prev=B.next){case 0:return B.prev=0,B.next=3,(0,t.fetchRetry)((0,a.resolveAsset)("icon_ref_map.json"));case 3:return f=B.sent,B.next=6,f.json();case 6:N=B.sent,m=N,this.setState({iconRef:N[this.props.icon]||""}),B.next=14;break;case 11:return B.prev=11,B.t0=B.catch(0),B.abrupt("return");case 14:case"end":return B.stop()}}return V}(),v,this,[[0,11]])}return v}()));function g(){return C.apply(this,arguments)}return g}(),d.componentDidMount=function(){function C(){m?this.setState({iconRef:m[this.props.icon]}):this.fetchRefMap()}return C}(),d.componentDidUpdate=function(){function C(g){g.icon!==this.props.icon&&(m?this.setState({iconRef:m[this.props.icon]}):this.fetchRefMap())}return C}(),d.render=function(){function C(){var g=this.props,v=g.className,f=g.direction,N=f===void 0?c.SOUTH:f,V=g.fallback,B=g.frame,I=B===void 0?1:B,L=g.icon_state,w=g.movement,A=w===void 0?!1:w,x=b(g,p),E=this.state.iconRef,P=E+"?state="+L+"&dir="+N+"&movement="+!!A+"&frame="+I;return E?(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Image,Object.assign({fixErrors:!0,src:P},x))):V||null}return C}(),s}(e.Component)},20342:function(T,r,n){"use strict";r.__esModule=!0,r.DraggableControl=void 0;var e=n(89005),a=n(44879),t=n(35840),o=n(9474);function p(h,i){h.prototype=Object.create(i.prototype),h.prototype.constructor=h,b(h,i)}function b(h,i){return b=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(c,m){return c.__proto__=m,c},b(h,i)}var y=400,S=function(i,c){return i.screenX*c[0]+i.screenY*c[1]},k=r.DraggableControl=function(h){function i(m){var l;return l=h.call(this,m)||this,l.inputRef=(0,e.createRef)(),l.state={originalValue:m.value,value:m.value,dragging:!1,editing:!1,origin:null,suppressingFlicker:!1},l.flickerTimer=null,l.suppressFlicker=function(){var u=l.props.suppressFlicker;u>0&&(l.setState({suppressingFlicker:!0}),clearTimeout(l.flickerTimer),l.flickerTimer=setTimeout(function(){return l.setState({suppressingFlicker:!1})},u))},l.handleDragStart=function(u){var s=l.props,d=s.value,C=s.dragMatrix,g=s.disabled,v=l.state.editing;v||g||(document.body.style["pointer-events"]="none",l.ref=u.currentTarget,l.setState({originalValue:d,dragging:!1,value:d,origin:S(u,C)}),l.timer=setTimeout(function(){l.setState({dragging:!0})},250),l.dragInterval=setInterval(function(){var f=l.state,N=f.dragging,V=f.value,B=l.props.onDrag;N&&B&&B(u,V)},l.props.updateRate||y),document.addEventListener("mousemove",l.handleDragMove),document.addEventListener("mouseup",l.handleDragEnd))},l.handleDragMove=function(u){var s,d=l.props,C=d.minValue,g=d.maxValue,v=d.step,f=d.dragMatrix,N=d.disabled;if(!N){var V=l.ref.offsetWidth/((g-C)/v),B=(s=l.props.stepPixelSize)!=null?s:V;typeof B=="function"&&(B=B(V)),l.setState(function(I){var L=Object.assign({},I),w=I.origin,A=S(u,f)-w;if(I.dragging){var x=Math.trunc(A/B);L.value=(0,a.clamp)(Math.floor(L.originalValue/v)*v+x*v,C,g)}else Math.abs(A)>4&&(L.dragging=!0);return L})}},l.handleDragEnd=function(u){var s=l.props,d=s.onChange,C=s.onDrag,g=l.state,v=g.dragging,f=g.value;if(document.body.style["pointer-events"]="auto",clearTimeout(l.timer),clearInterval(l.dragInterval),l.setState({originalValue:null,dragging:!1,editing:!v,origin:null}),document.removeEventListener("mousemove",l.handleDragMove),document.removeEventListener("mouseup",l.handleDragEnd),v)l.suppressFlicker(),d&&d(u,f),C&&C(u,f);else if(l.inputRef){var N=l.inputRef.current;N.value=f;try{N.focus(),N.select()}catch(V){}}},l}p(i,h);var c=i.prototype;return c.render=function(){function m(){var l=this,u=this.state,s=u.dragging,d=u.editing,C=u.value,g=u.suppressingFlicker,v=this.props,f=v.animated,N=v.value,V=v.unit,B=v.minValue,I=v.maxValue,L=v.format,w=v.onChange,A=v.onDrag,x=v.children,E=v.height,P=v.lineHeight,D=v.fontSize,M=v.disabled,O=N;(s||g)&&(O=C);var R=function(){function U(z){return z+(V?" "+V:"")}return U}(),F=f&&!s&&!g&&(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:O,format:L,children:R})||R(L?L(O):O),W=(0,e.createVNode)(64,"input","NumberInput__input",null,1,{style:{display:!d||M?"none":void 0,height:E,"line-height":P,"font-size":D},onBlur:function(){function U(z){if(d){var $=(0,a.clamp)(parseFloat(z.target.value),B,I);if(Number.isNaN($)){l.setState({editing:!1});return}l.setState({editing:!1,value:$}),l.suppressFlicker(),w&&w(z,$),A&&A(z,$)}}return U}(),onKeyDown:function(){function U(z){if(z.keyCode===13){var $=(0,a.clamp)(parseFloat(z.target.value),B,I);if(Number.isNaN($)){l.setState({editing:!1});return}l.setState({editing:!1,value:$}),l.suppressFlicker(),w&&w(z,$),A&&A(z,$);return}if(z.keyCode===27){l.setState({editing:!1});return}}return U}(),disabled:M},null,this.inputRef);return x({dragging:s,editing:d,value:N,displayValue:O,displayElement:F,inputElement:W,handleDragStart:this.handleDragStart})}return m}(),i}(e.Component);k.defaultHooks=t.pureComponentHooks,k.defaultProps={minValue:-1/0,maxValue:1/0,step:1,suppressFlicker:50,dragMatrix:[1,0]}},87099:function(T,r,n){"use strict";r.__esModule=!0,r.Dropdown=void 0;var e=n(89005),a=n(95996),t=n(35840),o=n(55937),p=n(96184),b=n(1331),y=n(96690),S=["icon","iconRotation","iconSpin","clipSelectedText","color","dropdownStyle","over","nochevron","width","onClick","onSelected","selected","disabled","displayText","buttons"],k=["className"],h;function i(g,v){if(g==null)return{};var f={};for(var N in g)if({}.hasOwnProperty.call(g,N)){if(v.includes(N))continue;f[N]=g[N]}return f}function c(g,v){g.prototype=Object.create(v.prototype),g.prototype.constructor=g,m(g,v)}function m(g,v){return m=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,N){return f.__proto__=N,f},m(g,v)}var l={placement:"left-start",modifiers:[{name:"eventListeners",enabled:!1}]},u={width:0,height:0,top:0,right:0,bottom:0,left:0,x:0,y:0,toJSON:function(){function g(){return null}return g}()},s="Layout Dropdown__menu",d="Layout Dropdown__menu-scroll",C=r.Dropdown=function(g){function v(N){var V;return V=g.call(this,N)||this,V.menuContents=void 0,V.handleClick=function(){V.state.open&&V.setOpen(!1)},V.state={open:!1,selected:V.props.selected},V.menuContents=null,V}c(v,g);var f=v.prototype;return f.getDOMNode=function(){function N(){return(0,e.findDOMFromVNode)(this.$LI,!0)}return N}(),f.componentDidMount=function(){function N(){var V=this.getDOMNode()}return N}(),f.openMenu=function(){function N(){var V=v.renderedMenu;V===void 0&&(V=document.createElement("div"),V.className=s,document.body.appendChild(V),v.renderedMenu=V);var B=this.getDOMNode();v.currentOpenMenu=B,V.scrollTop=0,V.style.width=this.props.menuWidth||B.offsetWidth+"px",V.style.opacity="1",V.style.pointerEvents="auto",setTimeout(function(){var I;(I=v.renderedMenu)==null||I.focus()},400),this.renderMenuContent()}return N}(),f.closeMenu=function(){function N(){v.currentOpenMenu===this.getDOMNode()&&(v.currentOpenMenu=void 0,v.renderedMenu.style.opacity="0",v.renderedMenu.style.pointerEvents="none")}return N}(),f.componentWillUnmount=function(){function N(){this.closeMenu(),this.setOpen(!1)}return N}(),f.renderMenuContent=function(){function N(){var V=this,B=v.renderedMenu;if(B){B.offsetHeight>200?B.className=d:B.className=s;var I=this.props.options,L=I===void 0?[]:I,w=L.map(function(x){var E,P;return typeof x=="string"?(P=x,E=x):x!==null&&(P=x.displayText,E=x.value),(0,e.createVNode)(1,"div",(0,t.classes)(["Dropdown__menuentry",V.state.selected===E&&"selected"]),P,0,{onClick:function(){function D(){V.setSelected(E)}return D}()},E)}),A=w.length?w:"No Options Found";(0,e.render)((0,e.createVNode)(1,"div",null,A,0),B,function(){var x=v.singletonPopper;x===void 0?(x=(0,a.createPopper)(v.virtualElement,B,Object.assign({},l,{placement:"bottom-start"})),v.singletonPopper=x):(x.setOptions(Object.assign({},l,{placement:"bottom-start"})),x.update())},this.context)}}return N}(),f.setOpen=function(){function N(V){var B=this;this.setState(function(I){return Object.assign({},I,{open:V})}),V?setTimeout(function(){B.openMenu(),window.addEventListener("click",B.handleClick)}):(this.closeMenu(),window.removeEventListener("click",this.handleClick))}return N}(),f.setSelected=function(){function N(V){this.setState(function(B){return Object.assign({},B,{selected:V})}),this.setOpen(!1),this.props.onSelected&&this.props.onSelected(V)}return N}(),f.getOptionValue=function(){function N(V){return typeof V=="string"?V:V.value}return N}(),f.getSelectedIndex=function(){function N(){var V=this,B=this.state.selected||this.props.selected,I=this.props.options,L=I===void 0?[]:I;return L.findIndex(function(w){return V.getOptionValue(w)===B})}return N}(),f.toPrevious=function(){function N(){if(!(this.props.options.length<1)){var V=this.getSelectedIndex(),B=0,I=this.props.options.length-1,L=V>=0;L||(V=B);var w=V===B?I:V-1;this.setSelected(this.getOptionValue(this.props.options[w]))}}return N}(),f.toNext=function(){function N(){if(!(this.props.options.length<1)){var V=this.getSelectedIndex(),B=0,I=this.props.options.length-1,L=V>=0;L||(V=I);var w=V===I?B:V+1;this.setSelected(this.getOptionValue(this.props.options[w]))}}return N}(),f.render=function(){function N(){var V=this,B=this.props,I=B.icon,L=B.iconRotation,w=B.iconSpin,A=B.clipSelectedText,x=A===void 0?!0:A,E=B.color,P=E===void 0?"default":E,D=B.dropdownStyle,M=B.over,O=B.nochevron,R=B.width,F=B.onClick,W=B.onSelected,U=B.selected,z=B.disabled,$=B.displayText,G=B.buttons,X=i(B,S),J=X.className,se=i(X,k),ie=M?!this.state.open:this.state.open;return(0,e.createComponentVNode)(2,y.Stack,{inline:!0,fill:!0,width:R,children:[(0,e.createComponentVNode)(2,y.Stack.Item,{grow:!0,children:(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Box,Object.assign({width:"100%",className:(0,t.classes)(["Dropdown__control","Button","Button--color--"+P,z&&"Button--disabled",J]),onClick:function(){function me(q){z&&!V.state.open||(V.setOpen(!V.state.open),F&&F(q))}return me}()},se,{children:[I&&(0,e.createComponentVNode)(2,b.Icon,{name:I,rotation:L,spin:w,mr:1}),(0,e.createVNode)(1,"span","Dropdown__selected-text",$||this.state.selected,0,{style:{overflow:x?"hidden":"visible"}}),O||(0,e.createVNode)(1,"span","Dropdown__arrow-button",(0,e.createComponentVNode)(2,b.Icon,{name:ie?"chevron-up":"chevron-down"}),2)]})))}),G&&(0,e.createFragment)([(0,e.createComponentVNode)(2,y.Stack.Item,{height:"100%",children:(0,e.createComponentVNode)(2,p.Button,{height:"100%",icon:"chevron-left",disabled:z,onClick:function(){function me(){z||V.toPrevious()}return me}()})}),(0,e.createComponentVNode)(2,y.Stack.Item,{height:"100%",children:(0,e.createComponentVNode)(2,p.Button,{height:"100%",icon:"chevron-right",disabled:z,onClick:function(){function me(){z||V.toNext()}return me}()})})],4)]})}return N}(),v}(e.Component);h=C,C.renderedMenu=void 0,C.singletonPopper=void 0,C.currentOpenMenu=void 0,C.virtualElement={getBoundingClientRect:function(){function g(){var v,f;return(v=(f=h.currentOpenMenu)==null?void 0:f.getBoundingClientRect())!=null?v:u}return g}()}},39473:function(T,r,n){"use strict";r.__esModule=!0,r.computeFlexProps=r.computeFlexItemProps=r.computeFlexItemClassName=r.computeFlexClassName=r.Flex=void 0;var e=n(89005),a=n(35840),t=n(55937),o=["className","direction","wrap","align","justify","inline","style"],p=["className"],b=["className","style","grow","order","shrink","basis","align"],y=["className"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */function S(u,s){if(u==null)return{};var d={};for(var v in u)if({}.hasOwnProperty.call(u,v)){if(s.includes(v))continue;d[v]=u[v]}return d}var k=r.computeFlexClassName=function(){function u(s){return(0,a.classes)(["Flex",s.inline&&"Flex--inline",(0,t.computeBoxClassName)(s)])}return u}(),h=r.computeFlexProps=function(){function u(s){var d=s.className,v=s.direction,g=s.wrap,C=s.align,f=s.justify,N=s.inline,V=s.style,B=S(s,o);return(0,t.computeBoxProps)(Object.assign({style:Object.assign({},V,{"flex-direction":v,"flex-wrap":g===!0?"wrap":g,"align-items":C,"justify-content":f})},B))}return u}(),i=r.Flex=function(){function u(s){var d=s.className,v=S(s,p);return(0,e.normalizeProps)((0,e.createVNode)(1,"div",(0,a.classes)([d,k(v)]),null,1,Object.assign({},h(v))))}return u}();i.defaultHooks=a.pureComponentHooks;var c=r.computeFlexItemClassName=function(){function u(s){return(0,a.classes)(["Flex__item",(0,t.computeBoxClassName)(s)])}return u}(),m=r.computeFlexItemProps=function(){function u(s){var d=s.className,v=s.style,g=s.grow,C=s.order,f=s.shrink,N=s.basis,V=N===void 0?s.width:N,B=s.align,I=S(s,b);return(0,t.computeBoxProps)(Object.assign({style:Object.assign({},v,{"flex-grow":g!==void 0&&Number(g),"flex-shrink":f!==void 0&&Number(f),"flex-basis":(0,t.unit)(V),order:C,"align-self":B})},I))}return u}(),l=function(s){var d=s.className,v=S(s,y);return(0,e.normalizeProps)((0,e.createVNode)(1,"div",(0,a.classes)([d,c(s)]),null,1,Object.assign({},m(v))))};l.defaultHooks=a.pureComponentHooks,i.Item=l},79646:function(T,r,n){"use strict";r.__esModule=!0,r.GridColumn=r.Grid=void 0;var e=n(89005),a=n(36352),t=n(35840),o=["children"],p=["size","style"];/**
+ */function S(u,s){if(u==null)return{};var d={};for(var C in u)if({}.hasOwnProperty.call(u,C)){if(s.includes(C))continue;d[C]=u[C]}return d}var k=r.computeFlexClassName=function(){function u(s){return(0,a.classes)(["Flex",s.inline&&"Flex--inline",(0,t.computeBoxClassName)(s)])}return u}(),h=r.computeFlexProps=function(){function u(s){var d=s.className,C=s.direction,g=s.wrap,v=s.align,f=s.justify,N=s.inline,V=s.style,B=S(s,o);return(0,t.computeBoxProps)(Object.assign({style:Object.assign({},V,{"flex-direction":C,"flex-wrap":g===!0?"wrap":g,"align-items":v,"justify-content":f})},B))}return u}(),i=r.Flex=function(){function u(s){var d=s.className,C=S(s,p);return(0,e.normalizeProps)((0,e.createVNode)(1,"div",(0,a.classes)([d,k(C)]),null,1,Object.assign({},h(C))))}return u}();i.defaultHooks=a.pureComponentHooks;var c=r.computeFlexItemClassName=function(){function u(s){return(0,a.classes)(["Flex__item",(0,t.computeBoxClassName)(s)])}return u}(),m=r.computeFlexItemProps=function(){function u(s){var d=s.className,C=s.style,g=s.grow,v=s.order,f=s.shrink,N=s.basis,V=N===void 0?s.width:N,B=s.align,I=S(s,b);return(0,t.computeBoxProps)(Object.assign({style:Object.assign({},C,{"flex-grow":g!==void 0&&Number(g),"flex-shrink":f!==void 0&&Number(f),"flex-basis":(0,t.unit)(V),order:v,"align-self":B})},I))}return u}(),l=function(s){var d=s.className,C=S(s,y);return(0,e.normalizeProps)((0,e.createVNode)(1,"div",(0,a.classes)([d,c(s)]),null,1,Object.assign({},m(C))))};l.defaultHooks=a.pureComponentHooks,i.Item=l},79646:function(T,r,n){"use strict";r.__esModule=!0,r.GridColumn=r.Grid=void 0;var e=n(89005),a=n(36352),t=n(35840),o=["children"],p=["size","style"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -129,19 +129,19 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */function b(h,i){if(h==null)return{};var c={};for(var m in h)if({}.hasOwnProperty.call(h,m)){if(i.includes(m))continue;c[m]=h[m]}return c}var y=/-o$/,S=r.Icon=function(){function h(i){var c=i.name,m=i.size,l=i.spin,u=i.className,s=i.style,d=s===void 0?{}:s,v=i.rotation,g=i.inverse,C=b(i,o);m&&(d["font-size"]=m*100+"%"),typeof v=="number"&&(d.transform="rotate("+v+"deg)");var f=y.test(c),N=c.replace(y,"");return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Box,Object.assign({as:"i",className:(0,a.classes)(["Icon",u,f?"far":"fas","fa-"+N,l&&"fa-spin"]),style:d},C)))}return h}();S.defaultHooks=a.pureComponentHooks;var k=r.IconStack=function(){function h(i){var c=i.className,m=i.style,l=m===void 0?{}:m,u=i.children,s=b(i,p);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Box,Object.assign({as:"span",class:(0,a.classes)(["IconStack",c]),style:l},s,{children:u})))}return h}();S.Stack=k},91225:function(T,r,n){"use strict";r.__esModule=!0,r.Image=void 0;var e=n(89005),a=n(55937),t=["fixBlur","fixErrors","objectFit","src"];function o(k,h){if(k==null)return{};var i={};for(var c in k)if({}.hasOwnProperty.call(k,c)){if(h.includes(c))continue;i[c]=k[c]}return i}function p(k,h){k.prototype=Object.create(h.prototype),k.prototype.constructor=k,b(k,h)}function b(k,h){return b=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,c){return i.__proto__=c,i},b(k,h)}var y=5,S=r.Image=function(k){function h(){for(var c,m=arguments.length,l=new Array(m),u=0;u0;u&&(l=c.containerRef)!=null&&l.current?c.props.onMove(b(c.containerRef.current,m)):c.toggleDocumentEvents(!1)},c.handleMoveEnd=function(){c.toggleDocumentEvents(!1)},c.handleKeyDown=function(m){var l=m.which||m.keyCode;l<37||l>40||(m.preventDefault(),c.props.onKey({left:l===39?.05:l===37?-.05:0,top:l===40?.05:l===38?-.05:0}))},c.props=i,c.containerRef=(0,e.createRef)(),c}t(k,S);var h=k.prototype;return h.toggleDocumentEvents=function(){function i(c){var m,l=(m=this.containerRef)==null?void 0:m.current,u=p(l),s=c?u.addEventListener:u.removeEventListener;s("mousemove",this.handleMove),s("mouseup",this.handleMoveEnd)}return i}(),h.componentDidMount=function(){function i(){this.toggleDocumentEvents(!0)}return i}(),h.componentWillUnmount=function(){function i(){this.toggleDocumentEvents(!1)}return i}(),h.render=function(){function i(){return(0,e.normalizeProps)((0,e.createVNode)(1,"div","react-colorful__interactive",this.props.children,0,Object.assign({},this.props,{style:this.props.style,onMouseDown:this.handleMoveStart,onKeyDown:this.handleKeyDown,tabIndex:0,role:"slider"}),null,this.containerRef))}return i}(),k}(e.Component)},76334:function(T,r,n){"use strict";r.__esModule=!0,r.Knob=void 0;var e=n(89005),a=n(44879),t=n(35840),o=n(55937),p=n(20342),b=n(59263),y=["animated","format","maxValue","minValue","onChange","onDrag","step","stepPixelSize","suppressFlicker","unit","value","className","style","fillValue","color","ranges","size","bipolar","children","popUpPosition"];/**
+*/var h=r.toInputValue=function(){function c(m){return typeof m!="number"&&typeof m!="string"?"":String(m)}return c}(),i=r.Input=function(c){function m(){var u;return u=c.call(this)||this,u.inputRef=(0,e.createRef)(),u.state={editing:!1},u.handleInput=function(s){var d=u.state.editing,C=u.props.onInput;d||u.setEditing(!0),C&&C(s,s.target.value)},u.handleFocus=function(s){var d=u.state.editing;d||u.setEditing(!0)},u.handleBlur=function(s){var d=u.state.editing,C=u.props.onChange;d&&(u.setEditing(!1),C&&C(s,s.target.value))},u.handleKeyDown=function(s){var d=u.props,C=d.onInput,g=d.onChange,v=d.onEnter;if(s.keyCode===o.KEY_ENTER){u.setEditing(!1),g&&g(s,s.target.value),C&&C(s,s.target.value),v&&v(s,s.target.value),u.props.selfClear?s.target.value="":s.target.blur();return}if(s.keyCode===o.KEY_ESCAPE){u.setEditing(!1),s.target.value=h(u.props.value),s.target.blur();return}},u}S(m,c);var l=m.prototype;return l.componentDidMount=function(){function u(){var s=this,d=this.props.value,C=this.inputRef.current;C&&(C.value=h(d),C.selectionStart=0,C.selectionEnd=C.value.length),(this.props.autoFocus||this.props.autoSelect)&&setTimeout(function(){C.focus(),s.props.autoSelect&&C.select()},1)}return u}(),l.componentDidUpdate=function(){function u(s,d){var C=this.state.editing,g=s.value,v=this.props.value,f=this.inputRef.current;f&&!C&&g!==v&&(f.value=h(v))}return u}(),l.setEditing=function(){function u(s){this.setState({editing:s})}return u}(),l.render=function(){function u(){var s=this.props,d=s.selfClear,C=s.onInput,g=s.onChange,v=s.onEnter,f=s.value,N=s.maxLength,V=s.placeholder,B=s.autofocus,I=s.disabled,L=s.multiline,w=s.cols,A=w===void 0?32:w,x=s.rows,E=x===void 0?4:x,P=y(s,p),D=P.className,M=P.fluid,O=P.monospace,R=y(P,b);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Box,Object.assign({className:(0,a.classes)(["Input",M&&"Input--fluid",O&&"Input--monospace",I&&"Input--disabled",D])},R,{children:[(0,e.createVNode)(1,"div","Input__baseline",".",16),L?(0,e.createVNode)(128,"textarea","Input__textarea",null,1,{placeholder:V,onInput:this.handleInput,onFocus:this.handleFocus,onBlur:this.handleBlur,maxLength:N,cols:A,rows:E,disabled:I},null,this.inputRef):(0,e.createVNode)(64,"input","Input__input",null,1,{placeholder:V,onInput:this.handleInput,onFocus:this.handleFocus,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,maxLength:N,disabled:I},null,this.inputRef)]})))}return u}(),m}(e.Component)},4454:function(T,r,n){"use strict";r.__esModule=!0,r.Interactive=void 0;var e=n(89005),a=n(44879);function t(S,k){S.prototype=Object.create(k.prototype),S.prototype.constructor=S,o(S,k)}function o(S,k){return o=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(h,i){return h.__proto__=i,h},o(S,k)}var p=function(k){return k&&k.ownerDocument.defaultView||self},b=function(k,h){var i=k.getBoundingClientRect(),c=h;return{left:(0,a.clamp)((c.pageX-(i.left+p(k).pageXOffset))/i.width,0,1),top:(0,a.clamp)((c.pageY-(i.top+p(k).pageYOffset))/i.height,0,1)}},y=r.Interactive=function(S){function k(i){var c;return c=S.call(this)||this,c.containerRef=void 0,c.props=void 0,c.handleMoveStart=function(m){var l,u=(l=c.containerRef)==null?void 0:l.current;u&&(m.preventDefault(),u.focus(),c.props.onMove(b(u,m)),c.toggleDocumentEvents(!0))},c.handleMove=function(m){var l;m.preventDefault();var u=m.buttons>0;u&&(l=c.containerRef)!=null&&l.current?c.props.onMove(b(c.containerRef.current,m)):c.toggleDocumentEvents(!1)},c.handleMoveEnd=function(){c.toggleDocumentEvents(!1)},c.handleKeyDown=function(m){var l=m.which||m.keyCode;l<37||l>40||(m.preventDefault(),c.props.onKey({left:l===39?.05:l===37?-.05:0,top:l===40?.05:l===38?-.05:0}))},c.props=i,c.containerRef=(0,e.createRef)(),c}t(k,S);var h=k.prototype;return h.toggleDocumentEvents=function(){function i(c){var m,l=(m=this.containerRef)==null?void 0:m.current,u=p(l),s=c?u.addEventListener:u.removeEventListener;s("mousemove",this.handleMove),s("mouseup",this.handleMoveEnd)}return i}(),h.componentDidMount=function(){function i(){this.toggleDocumentEvents(!0)}return i}(),h.componentWillUnmount=function(){function i(){this.toggleDocumentEvents(!1)}return i}(),h.render=function(){function i(){return(0,e.normalizeProps)((0,e.createVNode)(1,"div","react-colorful__interactive",this.props.children,0,Object.assign({},this.props,{style:this.props.style,onMouseDown:this.handleMoveStart,onKeyDown:this.handleKeyDown,tabIndex:0,role:"slider"}),null,this.containerRef))}return i}(),k}(e.Component)},76334:function(T,r,n){"use strict";r.__esModule=!0,r.Knob=void 0;var e=n(89005),a=n(44879),t=n(35840),o=n(55937),p=n(20342),b=n(59263),y=["animated","format","maxValue","minValue","onChange","onDrag","step","stepPixelSize","suppressFlicker","unit","value","className","style","fillValue","color","ranges","size","bipolar","children","popUpPosition"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */function S(h,i){if(h==null)return{};var c={};for(var m in h)if({}.hasOwnProperty.call(h,m)){if(i.includes(m))continue;c[m]=h[m]}return c}var k=r.Knob=function(){function h(i){var c=i.animated,m=i.format,l=i.maxValue,u=i.minValue,s=i.onChange,d=i.onDrag,v=i.step,g=i.stepPixelSize,C=i.suppressFlicker,f=i.unit,N=i.value,V=i.className,B=i.style,I=i.fillValue,L=i.color,w=i.ranges,A=w===void 0?{}:w,x=i.size,E=x===void 0?1:x,P=i.bipolar,D=i.children,M=i.popUpPosition,O=S(i,y);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.DraggableControl,Object.assign({dragMatrix:[0,-1]},{animated:c,format:m,maxValue:l,minValue:u,onChange:s,onDrag:d,step:v,stepPixelSize:g,suppressFlicker:C,unit:f,value:N},{children:function(){function R(F){var W=F.dragging,U=F.editing,z=F.value,$=F.displayValue,G=F.displayElement,X=F.inputElement,J=F.handleDragStart,se=(0,a.scale)(I!=null?I:$,u,l),ie=(0,a.scale)($,u,l),me=L||(0,a.keyOfMatchingRange)(I!=null?I:z,A)||"default",q=(ie-.5)*270;return(0,e.normalizeProps)((0,e.createVNode)(1,"div",(0,t.classes)(["Knob","Knob--color--"+me,P&&"Knob--bipolar",V,(0,o.computeBoxClassName)(O)]),[(0,e.createVNode)(1,"div","Knob__circle",(0,e.createVNode)(1,"div","Knob__cursorBox",(0,e.createVNode)(1,"div","Knob__cursor"),2,{style:{transform:"rotate("+q+"deg)"}}),2),W&&(0,e.createVNode)(1,"div",(0,t.classes)(["Knob__popupValue",M&&"Knob__popupValue--"+M]),G,0),(0,e.createVNode)(32,"svg","Knob__ring Knob__ringTrackPivot",(0,e.createVNode)(32,"circle","Knob__ringTrack",null,1,{cx:"50",cy:"50",r:"50"}),2,{viewBox:"0 0 100 100"}),(0,e.createVNode)(32,"svg","Knob__ring Knob__ringFillPivot",(0,e.createVNode)(32,"circle","Knob__ringFill",null,1,{style:{"stroke-dashoffset":((P?2.75:2)-se*1.5)*Math.PI*50},cx:"50",cy:"50",r:"50"}),2,{viewBox:"0 0 100 100"}),X],0,Object.assign({},(0,o.computeBoxProps)(Object.assign({style:Object.assign({"font-size":E+"em"},B)},O)),{onMouseDown:J})))}return R}()})))}return h}()},78621:function(T,r,n){"use strict";r.__esModule=!0,r.LabeledControls=void 0;var e=n(89005),a=n(39473),t=["children"],o=["label","children"];/**
+ */function S(h,i){if(h==null)return{};var c={};for(var m in h)if({}.hasOwnProperty.call(h,m)){if(i.includes(m))continue;c[m]=h[m]}return c}var k=r.Knob=function(){function h(i){var c=i.animated,m=i.format,l=i.maxValue,u=i.minValue,s=i.onChange,d=i.onDrag,C=i.step,g=i.stepPixelSize,v=i.suppressFlicker,f=i.unit,N=i.value,V=i.className,B=i.style,I=i.fillValue,L=i.color,w=i.ranges,A=w===void 0?{}:w,x=i.size,E=x===void 0?1:x,P=i.bipolar,D=i.children,M=i.popUpPosition,O=S(i,y);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.DraggableControl,Object.assign({dragMatrix:[0,-1]},{animated:c,format:m,maxValue:l,minValue:u,onChange:s,onDrag:d,step:C,stepPixelSize:g,suppressFlicker:v,unit:f,value:N},{children:function(){function R(F){var W=F.dragging,U=F.editing,z=F.value,$=F.displayValue,G=F.displayElement,X=F.inputElement,J=F.handleDragStart,se=(0,a.scale)(I!=null?I:$,u,l),ie=(0,a.scale)($,u,l),me=L||(0,a.keyOfMatchingRange)(I!=null?I:z,A)||"default",q=(ie-.5)*270;return(0,e.normalizeProps)((0,e.createVNode)(1,"div",(0,t.classes)(["Knob","Knob--color--"+me,P&&"Knob--bipolar",V,(0,o.computeBoxClassName)(O)]),[(0,e.createVNode)(1,"div","Knob__circle",(0,e.createVNode)(1,"div","Knob__cursorBox",(0,e.createVNode)(1,"div","Knob__cursor"),2,{style:{transform:"rotate("+q+"deg)"}}),2),W&&(0,e.createVNode)(1,"div",(0,t.classes)(["Knob__popupValue",M&&"Knob__popupValue--"+M]),G,0),(0,e.createVNode)(32,"svg","Knob__ring Knob__ringTrackPivot",(0,e.createVNode)(32,"circle","Knob__ringTrack",null,1,{cx:"50",cy:"50",r:"50"}),2,{viewBox:"0 0 100 100"}),(0,e.createVNode)(32,"svg","Knob__ring Knob__ringFillPivot",(0,e.createVNode)(32,"circle","Knob__ringFill",null,1,{style:{"stroke-dashoffset":((P?2.75:2)-se*1.5)*Math.PI*50},cx:"50",cy:"50",r:"50"}),2,{viewBox:"0 0 100 100"}),X],0,Object.assign({},(0,o.computeBoxProps)(Object.assign({style:Object.assign({"font-size":E+"em"},B)},O)),{onMouseDown:J})))}return R}()})))}return h}()},78621:function(T,r,n){"use strict";r.__esModule=!0,r.LabeledControls=void 0;var e=n(89005),a=n(39473),t=["children"],o=["label","children"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -149,11 +149,11 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var b=r.LabeledList=function(){function k(h){var i=h.children;return(0,e.createVNode)(1,"table","LabeledList",i,0)}return k}();b.defaultHooks=a.pureComponentHooks;var y=function(h){var i=h.className,c=h.label,m=h.labelColor,l=m===void 0?"label":m,u=h.color,s=h.textAlign,d=h.buttons,v=h.tooltip,g=h.content,C=h.children,f=h.preserveWhitespace,N=h.labelStyle,V=(0,e.createVNode)(1,"tr",(0,a.classes)(["LabeledList__row",i]),[(0,e.createComponentVNode)(2,t.Box,{as:"td",color:l,className:(0,a.classes)(["LabeledList__cell","LabeledList__label"]),style:N,children:c?c+":":null}),(0,e.createComponentVNode)(2,t.Box,{as:"td",color:u,textAlign:s,className:(0,a.classes)(["LabeledList__cell","LabeledList__content"]),colSpan:d?void 0:2,preserveWhitespace:f,children:[g,C]}),d&&(0,e.createVNode)(1,"td","LabeledList__cell LabeledList__buttons",d,0)],0);return v&&(V=(0,e.createComponentVNode)(2,p.Tooltip,{content:v,children:V})),V};y.defaultHooks=a.pureComponentHooks;var S=function(h){var i=h.size?(0,t.unit)(Math.max(0,h.size-1)):0;return(0,e.createVNode)(1,"tr","LabeledList__row",(0,e.createVNode)(1,"td",null,(0,e.createComponentVNode)(2,o.Divider),2,{colSpan:3,style:{"padding-top":i,"padding-bottom":i}}),2)};S.defaultHooks=a.pureComponentHooks,b.Item=y,b.Divider=S},36077:function(T,r,n){"use strict";r.__esModule=!0,r.Modal=void 0;var e=n(89005),a=n(35840),t=n(55937),o=n(61940),p=["className","children","onEnter"];/**
+ */var b=r.LabeledList=function(){function k(h){var i=h.children;return(0,e.createVNode)(1,"table","LabeledList",i,0)}return k}();b.defaultHooks=a.pureComponentHooks;var y=function(h){var i=h.className,c=h.label,m=h.labelColor,l=m===void 0?"label":m,u=h.color,s=h.textAlign,d=h.buttons,C=h.tooltip,g=h.content,v=h.children,f=h.preserveWhitespace,N=h.labelStyle,V=(0,e.createVNode)(1,"tr",(0,a.classes)(["LabeledList__row",i]),[(0,e.createComponentVNode)(2,t.Box,{as:"td",color:l,className:(0,a.classes)(["LabeledList__cell","LabeledList__label"]),style:N,children:c?c+":":null}),(0,e.createComponentVNode)(2,t.Box,{as:"td",color:u,textAlign:s,className:(0,a.classes)(["LabeledList__cell","LabeledList__content"]),colSpan:d?void 0:2,preserveWhitespace:f,children:[g,v]}),d&&(0,e.createVNode)(1,"td","LabeledList__cell LabeledList__buttons",d,0)],0);return C&&(V=(0,e.createComponentVNode)(2,p.Tooltip,{content:C,children:V})),V};y.defaultHooks=a.pureComponentHooks;var S=function(h){var i=h.size?(0,t.unit)(Math.max(0,h.size-1)):0;return(0,e.createVNode)(1,"tr","LabeledList__row",(0,e.createVNode)(1,"td",null,(0,e.createComponentVNode)(2,o.Divider),2,{colSpan:3,style:{"padding-top":i,"padding-bottom":i}}),2)};S.defaultHooks=a.pureComponentHooks,b.Item=y,b.Divider=S},36077:function(T,r,n){"use strict";r.__esModule=!0,r.Modal=void 0;var e=n(89005),a=n(35840),t=n(55937),o=n(61940),p=["className","children","onEnter"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */function b(S,k){if(S==null)return{};var h={};for(var i in S)if({}.hasOwnProperty.call(S,i)){if(k.includes(i))continue;h[i]=S[i]}return h}var y=r.Modal=function(){function S(k){var h=k.className,i=k.children,c=k.onEnter,m=b(k,p),l;return c&&(l=function(){function u(s){s.keyCode===13&&c(s)}return u}()),(0,e.createComponentVNode)(2,o.Dimmer,{onKeyDown:l,children:(0,e.normalizeProps)((0,e.createVNode)(1,"div",(0,a.classes)(["Modal",h,(0,t.computeBoxClassName)(m)]),i,0,Object.assign({},(0,t.computeBoxProps)(m))))})}return S}()},73280:function(T,r,n){"use strict";r.__esModule=!0,r.NanoMap=void 0;var e=n(89005),a=n(36036),t=n(72253),o=n(29319),p=n(79911),b=n(79140),y=["x","y","icon","tooltip","color","children"],S=["icon","color"];function k(g,C){if(g==null)return{};var f={};for(var N in g)if({}.hasOwnProperty.call(g,N)){if(C.includes(N))continue;f[N]=g[N]}return f}function h(g,C){g.prototype=Object.create(C.prototype),g.prototype.constructor=g,i(g,C)}function i(g,C){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,N){return f.__proto__=N,f},i(g,C)}var c=510,m=2,l=function(C){return C.stopPropagation&&C.stopPropagation(),C.preventDefault&&C.preventDefault(),C.cancelBubble=!0,C.returnValue=!1,!1},u=r.NanoMap=function(g){function C(N){var V,B,I,L;L=g.call(this,N)||this;var w=window.innerWidth/2-256,A=window.innerHeight/2-256;return L.state={offsetX:(V=N.offsetX)!=null?V:0,offsetY:(B=N.offsetY)!=null?B:0,dragging:!1,originX:null,originY:null,zoom:(I=N.zoom)!=null?I:1},L.handleDragStart=function(x){L.ref=x.target,L.setState({dragging:!1,originX:x.screenX,originY:x.screenY}),document.addEventListener("mousemove",L.handleDragMove),document.addEventListener("mouseup",L.handleDragEnd),l(x)},L.handleDragMove=function(x){L.setState(function(E){var P=Object.assign({},E),D=x.screenX-P.originX,M=x.screenY-P.originY;return E.dragging?(P.offsetX+=D/P.zoom,P.offsetY+=M/P.zoom,P.originX=x.screenX,P.originY=x.screenY):P.dragging=!0,P}),l(x)},L.handleDragEnd=function(x){L.setState({dragging:!1,originX:null,originY:null}),document.removeEventListener("mousemove",L.handleDragMove),document.removeEventListener("mouseup",L.handleDragEnd),N.onOffsetChange==null||N.onOffsetChange(x,L.state),l(x)},L.handleZoom=function(x,E){L.setState(function(P){var D=Math.min(Math.max(E,1),8);return P.zoom=D,N.onZoom&&N.onZoom(P.zoom),P})},L.handleReset=function(x){L.setState(function(E){E.offsetX=0,E.offsetY=0,E.zoom=1,L.handleZoom(x,1),N.onOffsetChange==null||N.onOffsetChange(x,E)})},L}h(C,g);var f=C.prototype;return f.getChildContext=function(){function N(){return{map:{zoom:this.state.zoom}}}return N}(),f.render=function(){function N(){var V=(0,t.useBackend)(this.context),B=V.config,I=this.state,L=I.dragging,w=I.offsetX,A=I.offsetY,x=I.zoom,E=x===void 0?1:x,P=this.props.children,D=B.map+"_nanomap_z1.png",M=c*E+"px",O={width:M,height:M,"margin-top":A*E+"px","margin-left":w*E+"px",overflow:"hidden",position:"relative",top:"50%",left:"50%",transform:"translate(-50%, -50%)","background-size":"cover","background-repeat":"no-repeat","text-align":"center",cursor:L?"move":"auto"},R={width:"100%",height:"100%",position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"};return(0,e.createComponentVNode)(2,a.Box,{className:"NanoMap__container",children:[(0,e.createComponentVNode)(2,a.Box,{style:O,onMouseDown:this.handleDragStart,children:[(0,e.createVNode)(1,"img",null,null,1,{src:(0,b.resolveAsset)(D),style:R}),(0,e.createComponentVNode)(2,a.Box,{children:P})]}),(0,e.createComponentVNode)(2,v,{zoom:E,onZoom:this.handleZoom,onReset:this.handleReset})]})}return N}(),C}(e.Component),s=function(C,f){var N=f.map.zoom,V=C.x,B=C.y,I=C.icon,L=C.tooltip,w=C.color,A=C.children,x=k(C,y),E=m*N,P=(V-1)*E,D=(B-1)*E;return(0,e.createVNode)(1,"div",null,(0,e.createComponentVNode)(2,a.Tooltip,{content:L,children:(0,e.normalizeProps)((0,e.createComponentVNode)(2,a.Box,Object.assign({position:"absolute",className:"NanoMap__marker",lineHeight:"0",bottom:D+"px",left:P+"px",width:E+"px",height:E+"px"},x,{children:A})))}),2)};u.Marker=s;var d=function(C,f){var N=f.map.zoom,V=C.icon,B=C.color,I=k(C,S),L=m*N+4/Math.ceil(N/4);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,s,Object.assign({},I,{children:(0,e.createComponentVNode)(2,a.Icon,{name:V,color:B,fontSize:L+"px",style:{position:"relative",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})})))};u.MarkerIcon=d;var v=function(C,f){return(0,e.createComponentVNode)(2,a.Box,{className:"NanoMap__zoomer",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Zoom",labelStyle:{"vertical-align":"middle"},children:(0,e.createComponentVNode)(2,a.Flex,{direction:"row",children:[(0,e.createComponentVNode)(2,p.Slider,{minValue:1,maxValue:8,stepPixelSize:10,format:function(){function N(V){return V+"x"}return N}(),value:C.zoom,onDrag:function(){function N(V,B){return C.onZoom(V,B)}return N}()}),(0,e.createComponentVNode)(2,a.Button,{ml:"0.5em",float:"right",icon:"sync",tooltip:"Reset View",onClick:function(){function N(V){return C.onReset==null?void 0:C.onReset(V)}return N}()})]})})})})};u.Zoomer=v},74733:function(T,r,n){"use strict";r.__esModule=!0,r.NoticeBox=void 0;var e=n(89005),a=n(35840),t=n(55937),o=["className","color","info","warning","success","danger"];/**
+ */function b(S,k){if(S==null)return{};var h={};for(var i in S)if({}.hasOwnProperty.call(S,i)){if(k.includes(i))continue;h[i]=S[i]}return h}var y=r.Modal=function(){function S(k){var h=k.className,i=k.children,c=k.onEnter,m=b(k,p),l;return c&&(l=function(){function u(s){s.keyCode===13&&c(s)}return u}()),(0,e.createComponentVNode)(2,o.Dimmer,{onKeyDown:l,children:(0,e.normalizeProps)((0,e.createVNode)(1,"div",(0,a.classes)(["Modal",h,(0,t.computeBoxClassName)(m)]),i,0,Object.assign({},(0,t.computeBoxProps)(m))))})}return S}()},73280:function(T,r,n){"use strict";r.__esModule=!0,r.NanoMap=void 0;var e=n(89005),a=n(36036),t=n(72253),o=n(29319),p=n(79911),b=n(79140),y=["x","y","icon","tooltip","color","children"],S=["icon","color"];function k(g,v){if(g==null)return{};var f={};for(var N in g)if({}.hasOwnProperty.call(g,N)){if(v.includes(N))continue;f[N]=g[N]}return f}function h(g,v){g.prototype=Object.create(v.prototype),g.prototype.constructor=g,i(g,v)}function i(g,v){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,N){return f.__proto__=N,f},i(g,v)}var c=510,m=2,l=function(v){return v.stopPropagation&&v.stopPropagation(),v.preventDefault&&v.preventDefault(),v.cancelBubble=!0,v.returnValue=!1,!1},u=r.NanoMap=function(g){function v(N){var V,B,I,L;L=g.call(this,N)||this;var w=window.innerWidth/2-256,A=window.innerHeight/2-256;return L.state={offsetX:(V=N.offsetX)!=null?V:0,offsetY:(B=N.offsetY)!=null?B:0,dragging:!1,originX:null,originY:null,zoom:(I=N.zoom)!=null?I:1},L.handleDragStart=function(x){L.ref=x.target,L.setState({dragging:!1,originX:x.screenX,originY:x.screenY}),document.addEventListener("mousemove",L.handleDragMove),document.addEventListener("mouseup",L.handleDragEnd),l(x)},L.handleDragMove=function(x){L.setState(function(E){var P=Object.assign({},E),D=x.screenX-P.originX,M=x.screenY-P.originY;return E.dragging?(P.offsetX+=D/P.zoom,P.offsetY+=M/P.zoom,P.originX=x.screenX,P.originY=x.screenY):P.dragging=!0,P}),l(x)},L.handleDragEnd=function(x){L.setState({dragging:!1,originX:null,originY:null}),document.removeEventListener("mousemove",L.handleDragMove),document.removeEventListener("mouseup",L.handleDragEnd),N.onOffsetChange==null||N.onOffsetChange(x,L.state),l(x)},L.handleZoom=function(x,E){L.setState(function(P){var D=Math.min(Math.max(E,1),8);return P.zoom=D,N.onZoom&&N.onZoom(P.zoom),P})},L.handleReset=function(x){L.setState(function(E){E.offsetX=0,E.offsetY=0,E.zoom=1,L.handleZoom(x,1),N.onOffsetChange==null||N.onOffsetChange(x,E)})},L}h(v,g);var f=v.prototype;return f.getChildContext=function(){function N(){return{map:{zoom:this.state.zoom}}}return N}(),f.render=function(){function N(){var V=(0,t.useBackend)(this.context),B=V.config,I=this.state,L=I.dragging,w=I.offsetX,A=I.offsetY,x=I.zoom,E=x===void 0?1:x,P=this.props.children,D=B.map+"_nanomap_z1.png",M=c*E+"px",O={width:M,height:M,"margin-top":A*E+"px","margin-left":w*E+"px",overflow:"hidden",position:"relative",top:"50%",left:"50%",transform:"translate(-50%, -50%)","background-size":"cover","background-repeat":"no-repeat","text-align":"center",cursor:L?"move":"auto"},R={width:"100%",height:"100%",position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"};return(0,e.createComponentVNode)(2,a.Box,{className:"NanoMap__container",children:[(0,e.createComponentVNode)(2,a.Box,{style:O,onMouseDown:this.handleDragStart,children:[(0,e.createVNode)(1,"img",null,null,1,{src:(0,b.resolveAsset)(D),style:R}),(0,e.createComponentVNode)(2,a.Box,{children:P})]}),(0,e.createComponentVNode)(2,C,{zoom:E,onZoom:this.handleZoom,onReset:this.handleReset})]})}return N}(),v}(e.Component),s=function(v,f){var N=f.map.zoom,V=v.x,B=v.y,I=v.icon,L=v.tooltip,w=v.color,A=v.children,x=k(v,y),E=m*N,P=(V-1)*E,D=(B-1)*E;return(0,e.createVNode)(1,"div",null,(0,e.createComponentVNode)(2,a.Tooltip,{content:L,children:(0,e.normalizeProps)((0,e.createComponentVNode)(2,a.Box,Object.assign({position:"absolute",className:"NanoMap__marker",lineHeight:"0",bottom:D+"px",left:P+"px",width:E+"px",height:E+"px"},x,{children:A})))}),2)};u.Marker=s;var d=function(v,f){var N=f.map.zoom,V=v.icon,B=v.color,I=k(v,S),L=m*N+4/Math.ceil(N/4);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,s,Object.assign({},I,{children:(0,e.createComponentVNode)(2,a.Icon,{name:V,color:B,fontSize:L+"px",style:{position:"relative",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})})))};u.MarkerIcon=d;var C=function(v,f){return(0,e.createComponentVNode)(2,a.Box,{className:"NanoMap__zoomer",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Zoom",labelStyle:{"vertical-align":"middle"},children:(0,e.createComponentVNode)(2,a.Flex,{direction:"row",children:[(0,e.createComponentVNode)(2,p.Slider,{minValue:1,maxValue:8,stepPixelSize:10,format:function(){function N(V){return V+"x"}return N}(),value:v.zoom,onDrag:function(){function N(V,B){return v.onZoom(V,B)}return N}()}),(0,e.createComponentVNode)(2,a.Button,{ml:"0.5em",float:"right",icon:"sync",tooltip:"Reset View",onClick:function(){function N(V){return v.onReset==null?void 0:v.onReset(V)}return N}()})]})})})})};u.Zoomer=C},74733:function(T,r,n){"use strict";r.__esModule=!0,r.NoticeBox=void 0;var e=n(89005),a=n(35840),t=n(55937),o=["className","color","info","warning","success","danger"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -161,23 +161,23 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
-*/var S=400,k=r.NumberInput=function(h){function i(m){var l;l=h.call(this,m)||this;var u=m.value;return l.inputRef=(0,e.createRef)(),l.state={value:u,dragging:!1,editing:!1,internalValue:null,origin:null,suppressingFlicker:!1},l.flickerTimer=null,l.suppressFlicker=function(){var s=l.props.suppressFlicker;s>0&&(l.setState({suppressingFlicker:!0}),clearTimeout(l.flickerTimer),l.flickerTimer=setTimeout(function(){return l.setState({suppressingFlicker:!1})},s))},l.handleDragStart=function(s){var d=l.props.value,v=l.state.editing;v||(document.body.style["pointer-events"]="none",l.ref=s.target,l.setState({dragging:!1,origin:s.screenY,value:d,internalValue:d}),l.timer=setTimeout(function(){l.setState({dragging:!0})},250),l.dragInterval=setInterval(function(){var g=l.state,C=g.dragging,f=g.value,N=l.props.onDrag;C&&N&&N(s,f)},l.props.updateRate||S),document.addEventListener("mousemove",l.handleDragMove),document.addEventListener("mouseup",l.handleDragEnd))},l.handleDragMove=function(s){var d=l.props,v=d.minValue,g=d.maxValue,C=d.step,f=d.stepPixelSize;l.setState(function(N){var V=Object.assign({},N),B=V.origin-s.screenY;if(N.dragging){var I=Number.isFinite(v)?v%C:0;V.internalValue=(0,a.clamp)(V.internalValue+B*C/f,v-C,g+C),V.value=(0,a.clamp)(V.internalValue-V.internalValue%C+I,v,g),V.origin=s.screenY}else Math.abs(B)>4&&(V.dragging=!0);return V})},l.handleDragEnd=function(s){var d=l.props,v=d.onChange,g=d.onDrag,C=l.state,f=C.dragging,N=C.value,V=C.internalValue;if(document.body.style["pointer-events"]="auto",clearTimeout(l.timer),clearInterval(l.dragInterval),l.setState({dragging:!1,editing:!f,origin:null}),document.removeEventListener("mousemove",l.handleDragMove),document.removeEventListener("mouseup",l.handleDragEnd),f)l.suppressFlicker(),v&&v(s,N),g&&g(s,N);else if(l.inputRef){var B=l.inputRef.current;B.value=V;try{B.focus(),B.select()}catch(I){}}},l}b(i,h);var c=i.prototype;return c.render=function(){function m(){var l=this,u=this.state,s=u.dragging,d=u.editing,v=u.value,g=u.suppressingFlicker,C=this.props,f=C.className,N=C.fluid,V=C.animated,B=C.value,I=C.unit,L=C.minValue,w=C.maxValue,A=C.height,x=C.width,E=C.lineHeight,P=C.fontSize,D=C.format,M=C.onChange,O=C.onDrag,R=B;(s||g)&&(R=v);var F=(0,e.createVNode)(1,"div","NumberInput__content",[V&&!s&&!g?(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:R,format:D}):D?D(R):R,I?" "+I:""],0);return(0,e.createComponentVNode)(2,p.Box,{className:(0,t.classes)(["NumberInput",N&&"NumberInput--fluid",f]),minWidth:x,minHeight:A,lineHeight:E,fontSize:P,onMouseDown:this.handleDragStart,children:[(0,e.createVNode)(1,"div","NumberInput__barContainer",(0,e.createVNode)(1,"div","NumberInput__bar",null,1,{style:{height:(0,a.clamp)((R-L)/(w-L)*100,0,100)+"%"}}),2),F,(0,e.createVNode)(64,"input","NumberInput__input",null,1,{style:{display:d?void 0:"none",height:A,"line-height":E,"font-size":P},onBlur:function(){function W(U){if(d){var z=(0,a.clamp)(parseFloat(U.target.value),L,w);if(Number.isNaN(z)){l.setState({editing:!1});return}l.setState({editing:!1,value:z}),l.suppressFlicker(),M&&M(U,z),O&&O(U,z)}}return W}(),onKeyDown:function(){function W(U){if(U.keyCode===13){var z=(0,a.clamp)(parseFloat(U.target.value),L,w);if(Number.isNaN(z)){l.setState({editing:!1});return}l.setState({editing:!1,value:z}),l.suppressFlicker(),M&&M(U,z),O&&O(U,z);return}if(U.keyCode===27){l.setState({editing:!1});return}}return W}()},null,this.inputRef)]})}return m}(),i}(e.Component);k.defaultHooks=t.pureComponentHooks,k.defaultProps={minValue:-1/0,maxValue:1/0,step:1,stepPixelSize:1,suppressFlicker:50}},33337:function(T,r,n){"use strict";r.__esModule=!0,r.Pointer=void 0;var e=n(89005),a=n(35840),t=r.Pointer=function(){function o(p){var b=p.className,y=p.color,S=p.left,k=p.top,h=k===void 0?.5:k,i=(0,a.classes)(["react-colorful__pointer",b]),c={top:h*100+"%",left:S*100+"%"};return(0,e.createVNode)(1,"div",i,(0,e.createVNode)(1,"div","react-colorful__pointer-fill",null,1,{style:{"background-color":y}}),2,{style:c})}return o}()},50186:function(T,r,n){"use strict";r.__esModule=!0,r.Popper=void 0;var e=n(95996),a=n(89005);function t(b,y){b.prototype=Object.create(y.prototype),b.prototype.constructor=b,o(b,y)}function o(b,y){return o=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(S,k){return S.__proto__=k,S},o(b,y)}var p=r.Popper=function(b){function y(){var k;return k=b.call(this)||this,k.renderedContent=void 0,k.popperInstance=void 0,y.id+=1,k}t(y,b);var S=y.prototype;return S.componentDidMount=function(){function k(){var h=this,i=this.props,c=i.additionalStyles,m=i.options;if(this.renderedContent=document.createElement("div"),c)for(var l=0,u=Object.entries(c);l0&&(l.setState({suppressingFlicker:!0}),clearTimeout(l.flickerTimer),l.flickerTimer=setTimeout(function(){return l.setState({suppressingFlicker:!1})},s))},l.handleDragStart=function(s){var d=l.props.value,C=l.state.editing;C||(document.body.style["pointer-events"]="none",l.ref=s.target,l.setState({dragging:!1,origin:s.screenY,value:d,internalValue:d}),l.timer=setTimeout(function(){l.setState({dragging:!0})},250),l.dragInterval=setInterval(function(){var g=l.state,v=g.dragging,f=g.value,N=l.props.onDrag;v&&N&&N(s,f)},l.props.updateRate||S),document.addEventListener("mousemove",l.handleDragMove),document.addEventListener("mouseup",l.handleDragEnd))},l.handleDragMove=function(s){var d=l.props,C=d.minValue,g=d.maxValue,v=d.step,f=d.stepPixelSize;l.setState(function(N){var V=Object.assign({},N),B=V.origin-s.screenY;if(N.dragging){var I=Number.isFinite(C)?C%v:0;V.internalValue=(0,a.clamp)(V.internalValue+B*v/f,C-v,g+v),V.value=(0,a.clamp)(V.internalValue-V.internalValue%v+I,C,g),V.origin=s.screenY}else Math.abs(B)>4&&(V.dragging=!0);return V})},l.handleDragEnd=function(s){var d=l.props,C=d.onChange,g=d.onDrag,v=l.state,f=v.dragging,N=v.value,V=v.internalValue;if(document.body.style["pointer-events"]="auto",clearTimeout(l.timer),clearInterval(l.dragInterval),l.setState({dragging:!1,editing:!f,origin:null}),document.removeEventListener("mousemove",l.handleDragMove),document.removeEventListener("mouseup",l.handleDragEnd),f)l.suppressFlicker(),C&&C(s,N),g&&g(s,N);else if(l.inputRef){var B=l.inputRef.current;B.value=V;try{B.focus(),B.select()}catch(I){}}},l}b(i,h);var c=i.prototype;return c.render=function(){function m(){var l=this,u=this.state,s=u.dragging,d=u.editing,C=u.value,g=u.suppressingFlicker,v=this.props,f=v.className,N=v.fluid,V=v.animated,B=v.value,I=v.unit,L=v.minValue,w=v.maxValue,A=v.height,x=v.width,E=v.lineHeight,P=v.fontSize,D=v.format,M=v.onChange,O=v.onDrag,R=B;(s||g)&&(R=C);var F=(0,e.createVNode)(1,"div","NumberInput__content",[V&&!s&&!g?(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:R,format:D}):D?D(R):R,I?" "+I:""],0);return(0,e.createComponentVNode)(2,p.Box,{className:(0,t.classes)(["NumberInput",N&&"NumberInput--fluid",f]),minWidth:x,minHeight:A,lineHeight:E,fontSize:P,onMouseDown:this.handleDragStart,children:[(0,e.createVNode)(1,"div","NumberInput__barContainer",(0,e.createVNode)(1,"div","NumberInput__bar",null,1,{style:{height:(0,a.clamp)((R-L)/(w-L)*100,0,100)+"%"}}),2),F,(0,e.createVNode)(64,"input","NumberInput__input",null,1,{style:{display:d?void 0:"none",height:A,"line-height":E,"font-size":P},onBlur:function(){function W(U){if(d){var z=(0,a.clamp)(parseFloat(U.target.value),L,w);if(Number.isNaN(z)){l.setState({editing:!1});return}l.setState({editing:!1,value:z}),l.suppressFlicker(),M&&M(U,z),O&&O(U,z)}}return W}(),onKeyDown:function(){function W(U){if(U.keyCode===13){var z=(0,a.clamp)(parseFloat(U.target.value),L,w);if(Number.isNaN(z)){l.setState({editing:!1});return}l.setState({editing:!1,value:z}),l.suppressFlicker(),M&&M(U,z),O&&O(U,z);return}if(U.keyCode===27){l.setState({editing:!1});return}}return W}()},null,this.inputRef)]})}return m}(),i}(e.Component);k.defaultHooks=t.pureComponentHooks,k.defaultProps={minValue:-1/0,maxValue:1/0,step:1,stepPixelSize:1,suppressFlicker:50}},33337:function(T,r,n){"use strict";r.__esModule=!0,r.Pointer=void 0;var e=n(89005),a=n(35840),t=r.Pointer=function(){function o(p){var b=p.className,y=p.color,S=p.left,k=p.top,h=k===void 0?.5:k,i=(0,a.classes)(["react-colorful__pointer",b]),c={top:h*100+"%",left:S*100+"%"};return(0,e.createVNode)(1,"div",i,(0,e.createVNode)(1,"div","react-colorful__pointer-fill",null,1,{style:{"background-color":y}}),2,{style:c})}return o}()},50186:function(T,r,n){"use strict";r.__esModule=!0,r.Popper=void 0;var e=n(95996),a=n(89005);function t(b,y){b.prototype=Object.create(y.prototype),b.prototype.constructor=b,o(b,y)}function o(b,y){return o=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(S,k){return S.__proto__=k,S},o(b,y)}var p=r.Popper=function(b){function y(){var k;return k=b.call(this)||this,k.renderedContent=void 0,k.popperInstance=void 0,y.id+=1,k}t(y,b);var S=y.prototype;return S.componentDidMount=function(){function k(){var h=this,i=this.props,c=i.additionalStyles,m=i.options;if(this.renderedContent=document.createElement("div"),c)for(var l=0,u=Object.entries(c);lm)return"in the future";c=c/10,m=m/10;var l=m-c;if(l>3600){var u=Math.round(l/3600);return u+" hour"+(u===1?"":"s")+" ago"}else if(l>60){var s=Math.round(l/60);return s+" minute"+(s===1?"":"s")+" ago"}else{var d=Math.round(l);return d+" second"+(d===1?"":"s")+" ago"}return"just now"}return i}()},40944:function(T,r,n){"use strict";r.__esModule=!0,r.KitchenSink=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595);/**
+*/var i=r.TextArea=function(c){function m(u,s){var d;d=c.call(this,u,s)||this,d.textareaRef=u.innerRef||(0,e.createRef)(),d.fillerRef=(0,e.createRef)(),d.state={editing:!1};var C=u.dontUseTabForIndent,g=C===void 0?!1:C;return d.handleOnInput=function(v){var f=d.state.editing,N=d.props.onInput;f||d.setEditing(!0),N&&N(v,v.target.value)},d.handleOnChange=function(v){var f=d.state.editing,N=d.props.onChange;f&&d.setEditing(!1),N&&N(v,v.target.value)},d.handleKeyPress=function(v){var f=d.state.editing,N=d.props.onKeyPress;f||d.setEditing(!0),N&&N(v,v.target.value)},d.handleKeyDown=function(v){var f=d.state.editing,N=d.props,V=N.onChange,B=N.onInput,I=N.onEnter,L=N.onKeyDown;if(v.keyCode===p.KEY_ENTER){d.setEditing(!1),V&&V(v,v.target.value),B&&B(v,v.target.value),I&&I(v,v.target.value),d.props.selfClear&&(v.target.value="",v.target.blur());return}if(v.keyCode===p.KEY_ESCAPE){d.props.onEscape&&d.props.onEscape(v),d.setEditing(!1),d.props.selfClear?v.target.value="":(v.target.value=(0,o.toInputValue)(d.props.value),v.target.blur());return}if(f||d.setEditing(!0),L&&L(v,v.target.value),!g){var w=v.keyCode||v.which;if(w===p.KEY_TAB){v.preventDefault();var A=v.target,x=A.value,E=A.selectionStart,P=A.selectionEnd;v.target.value=x.substring(0,E)+" "+x.substring(P),v.target.selectionEnd=E+1}}},d.handleFocus=function(v){var f=d.state.editing;f||d.setEditing(!0)},d.handleBlur=function(v){var f=d.state.editing,N=d.props.onChange;f&&(d.setEditing(!1),N&&N(v,v.target.value))},d}k(m,c);var l=m.prototype;return l.componentDidMount=function(){function u(){var s=this,d=this.props.value,C=this.textareaRef.current;C&&(C.value=(0,o.toInputValue)(d)),(this.props.autoFocus||this.props.autoSelect)&&setTimeout(function(){C.focus(),s.props.autoSelect&&C.select()},1)}return u}(),l.componentDidUpdate=function(){function u(s,d){var C=s.value,g=this.props.value,v=this.textareaRef.current;v&&typeof g=="string"&&C!==g&&(v.value=(0,o.toInputValue)(g))}return u}(),l.setEditing=function(){function u(s){this.setState({editing:s})}return u}(),l.getValue=function(){function u(){return this.textareaRef.current&&this.textareaRef.current.value}return u}(),l.render=function(){function u(){var s=this.props,d=s.onChange,C=s.onKeyDown,g=s.onKeyPress,v=s.onInput,f=s.onFocus,N=s.onBlur,V=s.onEnter,B=s.value,I=s.maxLength,L=s.placeholder,w=S(s,b),A=w.className,x=w.fluid,E=S(w,y);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Box,Object.assign({className:(0,a.classes)(["TextArea",x&&"TextArea--fluid",A])},E,{children:(0,e.createVNode)(128,"textarea","TextArea__textarea",null,1,{placeholder:L,onChange:this.handleOnChange,onKeyDown:this.handleKeyDown,onKeyPress:this.handleKeyPress,onInput:this.handleOnInput,onFocus:this.handleFocus,onBlur:this.handleBlur,maxLength:I},null,this.textareaRef)})))}return u}(),m}(e.Component)},5169:function(T,r){"use strict";r.__esModule=!0,r.TimeDisplay=void 0;var n=function(t){(!t||t<0)&&(t=0);var o=Math.floor(t/60).toString(10),p=(Math.floor(t)%60).toString(10);return[o,p].map(function(b){return b.length<2?"0"+b:b}).join(":")},e=r.TimeDisplay=function(){function a(t){var o=t.totalSeconds,p=o===void 0?0:o;return n(p)}return a}()},62147:function(T,r,n){"use strict";r.__esModule=!0,r.Tooltip=void 0;var e=n(89005),a=n(95996),t;function o(k,h){k.prototype=Object.create(h.prototype),k.prototype.constructor=k,p(k,h)}function p(k,h){return p=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,c){return i.__proto__=c,i},p(k,h)}var b={modifiers:[{name:"eventListeners",enabled:!1}]},y={width:0,height:0,top:0,right:0,bottom:0,left:0,x:0,y:0,toJSON:function(){function k(){return null}return k}()},S=r.Tooltip=function(k){function h(){return k.apply(this,arguments)||this}o(h,k);var i=h.prototype;return i.getDOMNode=function(){function c(){return(0,e.findDOMFromVNode)(this.$LI,!0)}return c}(),i.componentDidMount=function(){function c(){var m=this,l=this.getDOMNode();l&&(l.addEventListener("mouseenter",function(){var u=h.renderedTooltip;u===void 0&&(u=document.createElement("div"),u.className="Tooltip",document.body.appendChild(u),h.renderedTooltip=u),h.currentHoveredElement=l,u.style.opacity="1",m.renderPopperContent()}),l.addEventListener("mouseleave",function(){m.fadeOut()}))}return c}(),i.fadeOut=function(){function c(){h.currentHoveredElement===this.getDOMNode()&&(h.currentHoveredElement=void 0,h.renderedTooltip.style.opacity="0")}return c}(),i.renderPopperContent=function(){function c(){var m=this,l=h.renderedTooltip;l&&(0,e.render)((0,e.createVNode)(1,"span",null,this.props.content,0),l,function(){var u=h.singletonPopper;u===void 0?(u=(0,a.createPopper)(h.virtualElement,l,Object.assign({},b,{placement:m.props.position||"auto"})),h.singletonPopper=u):(u.setOptions(Object.assign({},b,{placement:m.props.position||"auto"})),u.update())},this.context)}return c}(),i.componentDidUpdate=function(){function c(){h.currentHoveredElement===this.getDOMNode()&&this.renderPopperContent()}return c}(),i.componentWillUnmount=function(){function c(){this.fadeOut()}return c}(),i.render=function(){function c(){return this.props.children}return c}(),h}(e.Component);t=S,S.renderedTooltip=void 0,S.singletonPopper=void 0,S.currentHoveredElement=void 0,S.virtualElement={getBoundingClientRect:function(){function k(){var h,i;return(h=(i=t.currentHoveredElement)==null?void 0:i.getBoundingClientRect())!=null?h:y}return k}()}},36036:function(T,r,n){"use strict";r.__esModule=!0,r.Tooltip=r.TimeDisplay=r.TextArea=r.Tabs=r.Table=r.Stack=r.Slider=r.Section=r.RoundGauge=r.RestrictedInput=r.ProgressBar=r.Popper=r.Pointer=r.NumberInput=r.NoticeBox=r.NanoMap=r.Modal=r.LabeledList=r.LabeledControls=r.Knob=r.Interactive=r.Input=r.ImageButton=r.Image=r.Icon=r.Grid=r.Flex=r.Dropdown=r.DraggableControl=r.DmIcon=r.Divider=r.Dimmer=r.Countdown=r.ColorBox=r.Collapsible=r.Chart=r.ByondUi=r.Button=r.Box=r.BlockQuote=r.Blink=r.Autofocus=r.AnimatedNumber=void 0;var e=n(9474);r.AnimatedNumber=e.AnimatedNumber;var a=n(27185);r.Autofocus=a.Autofocus;var t=n(5814);r.Blink=t.Blink;var o=n(61773);r.BlockQuote=o.BlockQuote;var p=n(55937);r.Box=p.Box;var b=n(96184);r.Button=b.Button;var y=n(18982);r.ByondUi=y.ByondUi;var S=n(66820);r.Chart=S.Chart;var k=n(4796);r.Collapsible=k.Collapsible;var h=n(88894);r.ColorBox=h.ColorBox;var i=n(73379);r.Countdown=i.Countdown;var c=n(61940);r.Dimmer=c.Dimmer;var m=n(13605);r.Divider=m.Divider;var l=n(20342);r.DraggableControl=l.DraggableControl;var u=n(87099);r.Dropdown=u.Dropdown;var s=n(39473);r.Flex=s.Flex;var d=n(79646);r.Grid=d.Grid;var C=n(4454);r.Interactive=C.Interactive;var g=n(91225);r.Image=g.Image;var v=n(60218);r.DmIcon=v.DmIcon;var f=n(1331);r.Icon=f.Icon;var N=n(79825);r.ImageButton=N.ImageButton;var V=n(79652);r.Input=V.Input;var B=n(76334);r.Knob=B.Knob;var I=n(78621);r.LabeledControls=I.LabeledControls;var L=n(29319);r.LabeledList=L.LabeledList;var w=n(36077);r.Modal=w.Modal;var A=n(73280);r.NanoMap=A.NanoMap;var x=n(74733);r.NoticeBox=x.NoticeBox;var E=n(59263);r.NumberInput=E.NumberInput;var P=n(33337);r.Pointer=P.Pointer;var D=n(50186);r.Popper=D.Popper;var M=n(92704);r.ProgressBar=M.ProgressBar;var O=n(9075);r.RestrictedInput=O.RestrictedInput;var R=n(11441);r.RoundGauge=R.RoundGauge;var F=n(97079);r.Section=F.Section;var W=n(79911);r.Slider=W.Slider;var U=n(96690);r.Stack=U.Stack;var z=n(36352);r.Table=z.Table;var $=n(85138);r.Tabs=$.Tabs;var G=n(44868);r.TextArea=G.TextArea;var X=n(5169);r.TimeDisplay=X.TimeDisplay;var J=n(62147);r.Tooltip=J.Tooltip},76910:function(T,r){"use strict";r.__esModule=!0,r.timeAgo=r.getGasLabel=r.getGasColor=r.UI_UPDATE=r.UI_INTERACTIVE=r.UI_DISABLED=r.UI_CLOSE=r.RADIO_CHANNELS=r.CSS_COLORS=r.COLORS=void 0;var n=r.UI_INTERACTIVE=2,e=r.UI_UPDATE=1,a=r.UI_DISABLED=0,t=r.UI_CLOSE=-1,o=r.COLORS={department:{command:"#526aff",security:"#CF0000",medical:"#009190",science:"#993399",engineering:"#A66300",supply:"#9F8545",service:"#80A000",centcom:"#78789B",other:"#C38312"},damageType:{oxy:"#3498db",toxin:"#2ecc71",burn:"#e67e22",brute:"#e74c3c"}},p=r.CSS_COLORS=["black","white","red","orange","yellow","olive","green","teal","blue","violet","purple","pink","brown","grey","good","average","bad","label"],b=r.RADIO_CHANNELS=[{name:"Syndicate",freq:1213,color:"#a52a2a"},{name:"SyndTeam",freq:1244,color:"#a52a2a"},{name:"Red Team",freq:1215,color:"#ff4444"},{name:"Blue Team",freq:1217,color:"#3434fd"},{name:"Response Team",freq:1345,color:"#2681a5"},{name:"Special Ops",freq:1341,color:"#2681a5"},{name:"Supply",freq:1347,color:"#b88646"},{name:"Service",freq:1349,color:"#6ca729"},{name:"Science",freq:1351,color:"#c68cfa"},{name:"Command",freq:1353,color:"#5177ff"},{name:"Procedure",freq:1339,color:"#F70285"},{name:"Medical",freq:1355,color:"#57b8f0"},{name:"Medical(I)",freq:1485,color:"#57b8f0"},{name:"Engineering",freq:1357,color:"#f37746"},{name:"Security",freq:1359,color:"#dd3535"},{name:"Security(I)",freq:1475,color:"#dd3535"},{name:"AI Private",freq:1343,color:"#d65d95"},{name:"Common",freq:1459,color:"#1ecc43"}],y=[{id:"o2",name:"Oxygen",label:"O\u2082",color:"blue"},{id:"n2",name:"Nitrogen",label:"N\u2082",color:"red"},{id:"co2",name:"Carbon Dioxide",label:"CO\u2082",color:"grey"},{id:"plasma",name:"Plasma",label:"Plasma",color:"pink"},{id:"water_vapor",name:"Water Vapor",label:"H\u2082O",color:"grey"},{id:"nob",name:"Hyper-noblium",label:"Hyper-nob",color:"teal"},{id:"n2o",name:"Nitrous Oxide",label:"N\u2082O",color:"red"},{id:"no2",name:"Nitryl",label:"NO\u2082",color:"brown"},{id:"tritium",name:"Tritium",label:"Tritium",color:"green"},{id:"bz",name:"BZ",label:"BZ",color:"purple"},{id:"stim",name:"Stimulum",label:"Stimulum",color:"purple"},{id:"pluox",name:"Pluoxium",label:"Pluoxium",color:"blue"},{id:"miasma",name:"Miasma",label:"Miasma",color:"olive"},{id:"hydrogen",name:"Hydrogen",label:"H\u2082",color:"white"},{id:"ab",name:"Agent B",label:"Agent B",color:"purple"}],S=r.getGasLabel=function(){function i(c,m){var l=String(c).toLowerCase(),u=y.find(function(s){return s.id===l||s.name.toLowerCase()===l});return u&&u.label||m||c}return i}(),k=r.getGasColor=function(){function i(c){var m=String(c).toLowerCase(),l=y.find(function(u){return u.id===m||u.name.toLowerCase()===m});return l&&l.color}return i}(),h=r.timeAgo=function(){function i(c,m){if(c>m)return"in the future";c=c/10,m=m/10;var l=m-c;if(l>3600){var u=Math.round(l/3600);return u+" hour"+(u===1?"":"s")+" ago"}else if(l>60){var s=Math.round(l/60);return s+" minute"+(s===1?"":"s")+" ago"}else{var d=Math.round(l);return d+" second"+(d===1?"":"s")+" ago"}return"just now"}return i}()},40944:function(T,r,n){"use strict";r.__esModule=!0,r.KitchenSink=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595);/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var p=n(4085),b=function(){return p.keys().map(function(k){return p(k)})},y=r.KitchenSink=function(){function S(k,h){var i=k.panel,c=(0,a.useLocalState)(h,"kitchenSinkTheme"),m=c[0],l=(0,a.useLocalState)(h,"pageIndex",0),u=l[0],s=l[1],d=b(),v=d[u],g=i?o.Pane:o.Window;return(0,e.createComponentVNode)(2,g,{title:"Kitchen Sink",width:600,height:500,theme:m,children:(0,e.createComponentVNode)(2,t.Flex,{height:"100%",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{m:1,mr:0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,fitted:!0,children:(0,e.createComponentVNode)(2,t.Tabs,{vertical:!0,children:d.map(function(C,f){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{color:"transparent",selected:f===u,onClick:function(){function N(){return s(f)}return N}(),children:C.meta.title},f)})})})}),(0,e.createComponentVNode)(2,t.Flex.Item,{position:"relative",grow:1,children:(0,e.createComponentVNode)(2,g.Content,{scrollable:!0,children:v.meta.render()})})]})})}return S}()},77384:function(T,r,n){"use strict";r.__esModule=!0,r.toggleKitchenSink=r.toggleDebugLayout=r.openExternalBrowser=void 0;var e=n(85307);/**
+ */var p=n(4085),b=function(){return p.keys().map(function(k){return p(k)})},y=r.KitchenSink=function(){function S(k,h){var i=k.panel,c=(0,a.useLocalState)(h,"kitchenSinkTheme"),m=c[0],l=(0,a.useLocalState)(h,"pageIndex",0),u=l[0],s=l[1],d=b(),C=d[u],g=i?o.Pane:o.Window;return(0,e.createComponentVNode)(2,g,{title:"Kitchen Sink",width:600,height:500,theme:m,children:(0,e.createComponentVNode)(2,t.Flex,{height:"100%",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{m:1,mr:0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,fitted:!0,children:(0,e.createComponentVNode)(2,t.Tabs,{vertical:!0,children:d.map(function(v,f){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{color:"transparent",selected:f===u,onClick:function(){function N(){return s(f)}return N}(),children:v.meta.title},f)})})})}),(0,e.createComponentVNode)(2,t.Flex.Item,{position:"relative",grow:1,children:(0,e.createComponentVNode)(2,g.Content,{scrollable:!0,children:C.meta.render()})})]})})}return S}()},77384:function(T,r,n){"use strict";r.__esModule=!0,r.toggleKitchenSink=r.toggleDebugLayout=r.openExternalBrowser=void 0;var e=n(85307);/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -222,13 +222,13 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
-*/var y=(0,t.createLogger)("drag"),S=Byond.windowId,k=!1,h=!1,i=[0,0],c,m,l,u,s,d=r.setWindowKey=function(){function R(F){S=F}return R}(),v=r.getWindowPosition=function(){function R(){return[window.screenLeft,window.screenTop]}return R}(),g=r.getWindowSize=function(){function R(){return[window.innerWidth,window.innerHeight]}return R}(),C=r.setWindowPosition=function(){function R(F){var W=(0,a.vecAdd)(F,i);return Byond.winset(Byond.windowId,{pos:W[0]+","+W[1]})}return R}(),f=r.setWindowSize=function(){function R(F){return Byond.winset(Byond.windowId,{size:F[0]+"x"+F[1]})}return R}(),N=r.getScreenPosition=function(){function R(){return[0-i[0],0-i[1]]}return R}(),V=r.getScreenSize=function(){function R(){return[window.screen.availWidth,window.screen.availHeight]}return R}(),B=function(F,W,U){U===void 0&&(U=50);for(var z=[W],$,G=0;Gse&&($[X]=se-W[X],G=!0)}return[G,$]},x=r.dragStartHandler=function(){function R(F){y.log("drag start"),k=!0,m=[window.screenLeft-F.screenX,window.screenTop-F.screenY],document.addEventListener("mousemove",P),document.addEventListener("mouseup",E),P(F)}return R}(),E=function R(F){y.log("drag end"),P(F),document.removeEventListener("mousemove",P),document.removeEventListener("mouseup",R),k=!1,I()},P=function(F){k&&(F.preventDefault(),C((0,a.vecAdd)([F.screenX,F.screenY],m)))},D=r.resizeStartHandler=function(){function R(F,W){return function(U){l=[F,W],y.log("resize start",l),h=!0,m=[window.screenLeft-U.screenX,window.screenTop-U.screenY],u=[window.innerWidth,window.innerHeight],document.addEventListener("mousemove",O),document.addEventListener("mouseup",M),O(U)}}return R}(),M=function R(F){y.log("resize end",s),O(F),document.removeEventListener("mousemove",O),document.removeEventListener("mouseup",R),h=!1,I()},O=function(F){h&&(F.preventDefault(),s=(0,a.vecAdd)(u,(0,a.vecMultiply)(l,(0,a.vecAdd)([F.screenX,F.screenY],(0,a.vecInverse)([window.screenLeft,window.screenTop]),m,[1,1]))),s[0]=Math.max(s[0],150),s[1]=Math.max(s[1],50),f(s))}},24826:function(T,r,n){"use strict";r.__esModule=!0,r.setupGlobalEvents=r.removeScrollableNode=r.globalEvents=r.canStealFocus=r.addScrollableNode=r.KeyEvent=void 0;var e=n(92868),a=n(92986);/**
+*/var y=(0,t.createLogger)("drag"),S=Byond.windowId,k=!1,h=!1,i=[0,0],c,m,l,u,s,d=r.setWindowKey=function(){function R(F){S=F}return R}(),C=r.getWindowPosition=function(){function R(){return[window.screenLeft,window.screenTop]}return R}(),g=r.getWindowSize=function(){function R(){return[window.innerWidth,window.innerHeight]}return R}(),v=r.setWindowPosition=function(){function R(F){var W=(0,a.vecAdd)(F,i);return Byond.winset(Byond.windowId,{pos:W[0]+","+W[1]})}return R}(),f=r.setWindowSize=function(){function R(F){return Byond.winset(Byond.windowId,{size:F[0]+"x"+F[1]})}return R}(),N=r.getScreenPosition=function(){function R(){return[0-i[0],0-i[1]]}return R}(),V=r.getScreenSize=function(){function R(){return[window.screen.availWidth,window.screen.availHeight]}return R}(),B=function(F,W,U){U===void 0&&(U=50);for(var z=[W],$,G=0;Gse&&($[X]=se-W[X],G=!0)}return[G,$]},x=r.dragStartHandler=function(){function R(F){y.log("drag start"),k=!0,m=[window.screenLeft-F.screenX,window.screenTop-F.screenY],document.addEventListener("mousemove",P),document.addEventListener("mouseup",E),P(F)}return R}(),E=function R(F){y.log("drag end"),P(F),document.removeEventListener("mousemove",P),document.removeEventListener("mouseup",R),k=!1,I()},P=function(F){k&&(F.preventDefault(),v((0,a.vecAdd)([F.screenX,F.screenY],m)))},D=r.resizeStartHandler=function(){function R(F,W){return function(U){l=[F,W],y.log("resize start",l),h=!0,m=[window.screenLeft-U.screenX,window.screenTop-U.screenY],u=[window.innerWidth,window.innerHeight],document.addEventListener("mousemove",O),document.addEventListener("mouseup",M),O(U)}}return R}(),M=function R(F){y.log("resize end",s),O(F),document.removeEventListener("mousemove",O),document.removeEventListener("mouseup",R),h=!1,I()},O=function(F){h&&(F.preventDefault(),s=(0,a.vecAdd)(u,(0,a.vecMultiply)(l,(0,a.vecAdd)([F.screenX,F.screenY],(0,a.vecInverse)([window.screenLeft,window.screenTop]),m,[1,1]))),s[0]=Math.max(s[0],150),s[1]=Math.max(s[1],50),f(s))}},24826:function(T,r,n){"use strict";r.__esModule=!0,r.setupGlobalEvents=r.removeScrollableNode=r.globalEvents=r.canStealFocus=r.addScrollableNode=r.KeyEvent=void 0;var e=n(92868),a=n(92986);/**
* Normalized browser focus events and BYOND-specific focus helpers.
*
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var t=r.globalEvents=new e.EventEmitter,o=!1,p=r.setupGlobalEvents=function(){function f(N){N===void 0&&(N={}),o=!!N.ignoreWindowFocus}return f}(),b,y=!0,S=function f(N,V){if(o){y=!0;return}if(b&&(clearTimeout(b),b=null),V){b=setTimeout(function(){return f(N)});return}y!==N&&(y=N,t.emit(N?"window-focus":"window-blur"),t.emit("window-focus-change",N))},k=null,h=r.canStealFocus=function(){function f(N){var V=String(N.tagName).toLowerCase();return V==="input"||V==="textarea"}return f}(),i=function(N){c(),k=N,k.addEventListener("blur",c)},c=function f(){k&&(k.removeEventListener("blur",f),k=null)},m=null,l=null,u=[],s=r.addScrollableNode=function(){function f(N){u.push(N)}return f}(),d=r.removeScrollableNode=function(){function f(N){var V=u.indexOf(N);V>=0&&u.splice(V,1)}return f}(),v=function(N){if(!(k||!y))for(var V=document.body;N&&N!==V;){if(u.includes(N)){if(N.contains(m))return;m=N,N.focus();return}N=N.parentNode}};window.addEventListener("mousemove",function(f){var N=f.target;N!==l&&(l=N,v(N))}),window.addEventListener("focusin",function(f){if(l=null,m=f.target,S(!0),h(f.target)){i(f.target);return}}),window.addEventListener("focusout",function(f){l=null,S(!1,!0)}),window.addEventListener("blur",function(f){l=null,S(!1,!0)}),window.addEventListener("beforeunload",function(f){S(!1)});var g={},C=r.KeyEvent=function(){function f(V,B,I){this.event=V,this.type=B,this.code=window.event?V.which:V.keyCode,this.ctrl=V.ctrlKey,this.shift=V.shiftKey,this.alt=V.altKey,this.repeat=!!I}var N=f.prototype;return N.hasModifierKeys=function(){function V(){return this.ctrl||this.alt||this.shift}return V}(),N.isModifierKey=function(){function V(){return this.code===a.KEY_CTRL||this.code===a.KEY_SHIFT||this.code===a.KEY_ALT}return V}(),N.isDown=function(){function V(){return this.type==="keydown"}return V}(),N.isUp=function(){function V(){return this.type==="keyup"}return V}(),N.toString=function(){function V(){return this._str?this._str:(this._str="",this.ctrl&&(this._str+="Ctrl+"),this.alt&&(this._str+="Alt+"),this.shift&&(this._str+="Shift+"),this.code>=48&&this.code<=90?this._str+=String.fromCharCode(this.code):this.code>=a.KEY_F1&&this.code<=a.KEY_F12?this._str+="F"+(this.code-111):this._str+="["+this.code+"]",this._str)}return V}(),f}();document.addEventListener("keydown",function(f){if(!h(f.target)){var N=f.keyCode,V=new C(f,"keydown",g[N]);t.emit("keydown",V),t.emit("key",V),g[N]=!0}}),document.addEventListener("keyup",function(f){if(!h(f.target)){var N=f.keyCode,V=new C(f,"keyup");t.emit("keyup",V),t.emit("key",V),g[N]=!1}})},87695:function(T,r){"use strict";r.__esModule=!0,r.focusWindow=r.focusMap=void 0;/**
+ */var t=r.globalEvents=new e.EventEmitter,o=!1,p=r.setupGlobalEvents=function(){function f(N){N===void 0&&(N={}),o=!!N.ignoreWindowFocus}return f}(),b,y=!0,S=function f(N,V){if(o){y=!0;return}if(b&&(clearTimeout(b),b=null),V){b=setTimeout(function(){return f(N)});return}y!==N&&(y=N,t.emit(N?"window-focus":"window-blur"),t.emit("window-focus-change",N))},k=null,h=r.canStealFocus=function(){function f(N){var V=String(N.tagName).toLowerCase();return V==="input"||V==="textarea"}return f}(),i=function(N){c(),k=N,k.addEventListener("blur",c)},c=function f(){k&&(k.removeEventListener("blur",f),k=null)},m=null,l=null,u=[],s=r.addScrollableNode=function(){function f(N){u.push(N)}return f}(),d=r.removeScrollableNode=function(){function f(N){var V=u.indexOf(N);V>=0&&u.splice(V,1)}return f}(),C=function(N){if(!(k||!y))for(var V=document.body;N&&N!==V;){if(u.includes(N)){if(N.contains(m))return;m=N,N.focus();return}N=N.parentNode}};window.addEventListener("mousemove",function(f){var N=f.target;N!==l&&(l=N,C(N))}),window.addEventListener("focusin",function(f){if(l=null,m=f.target,S(!0),h(f.target)){i(f.target);return}}),window.addEventListener("focusout",function(f){l=null,S(!1,!0)}),window.addEventListener("blur",function(f){l=null,S(!1,!0)}),window.addEventListener("beforeunload",function(f){S(!1)});var g={},v=r.KeyEvent=function(){function f(V,B,I){this.event=V,this.type=B,this.code=window.event?V.which:V.keyCode,this.ctrl=V.ctrlKey,this.shift=V.shiftKey,this.alt=V.altKey,this.repeat=!!I}var N=f.prototype;return N.hasModifierKeys=function(){function V(){return this.ctrl||this.alt||this.shift}return V}(),N.isModifierKey=function(){function V(){return this.code===a.KEY_CTRL||this.code===a.KEY_SHIFT||this.code===a.KEY_ALT}return V}(),N.isDown=function(){function V(){return this.type==="keydown"}return V}(),N.isUp=function(){function V(){return this.type==="keyup"}return V}(),N.toString=function(){function V(){return this._str?this._str:(this._str="",this.ctrl&&(this._str+="Ctrl+"),this.alt&&(this._str+="Alt+"),this.shift&&(this._str+="Shift+"),this.code>=48&&this.code<=90?this._str+=String.fromCharCode(this.code):this.code>=a.KEY_F1&&this.code<=a.KEY_F12?this._str+="F"+(this.code-111):this._str+="["+this.code+"]",this._str)}return V}(),f}();document.addEventListener("keydown",function(f){if(!h(f.target)){var N=f.keyCode,V=new v(f,"keydown",g[N]);t.emit("keydown",V),t.emit("key",V),g[N]=!0}}),document.addEventListener("keyup",function(f){if(!h(f.target)){var N=f.keyCode,V=new v(f,"keyup");t.emit("keyup",V),t.emit("key",V),g[N]=!1}})},87695:function(T,r){"use strict";r.__esModule=!0,r.focusWindow=r.focusMap=void 0;/**
* Various focus helpers.
*
* @file
@@ -238,20 +238,20 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var a=["f","p","n","\u03BC","m"," ","k","M","G","T","P","E","Z","Y"],t=a.indexOf(" "),o=r.formatSiUnit=function(){function S(k,h,i){if(h===void 0&&(h=-t),i===void 0&&(i=""),typeof k!="number"||!Number.isFinite(k))return k;var c=Math.floor(Math.log10(k)),m=Math.floor(Math.max(h*3,c)),l=Math.floor(c/3),u=Math.floor(m/3),s=(0,e.clamp)(t+u,0,a.length),d=a[s],v=k/Math.pow(1e3,u),g=l>h?2+u*3-m:0,C=(0,e.toFixed)(v,g)+" "+d+i;return C.trim()}return S}(),p=r.formatPower=function(){function S(k,h){return h===void 0&&(h=0),o(k,h,"W")}return S}(),b=r.formatMoney=function(){function S(k,h){if(h===void 0&&(h=0),!Number.isFinite(k))return k;var i=(0,e.round)(k,h);h>0&&(i=(0,e.toFixed)(k,h)),i=String(i);var c=i.length,m=i.indexOf(".");m===-1&&(m=c);for(var l="",u=0;u0&&u=0?"+":h<0?"\u2013":"",c=Math.abs(h);return c===1/0?c="Inf":c=(0,e.toFixed)(c,2),i+c+" dB"}return S}()},56518:function(T,r,n){"use strict";r.__esModule=!0,r.setupHotKeys=r.releaseHotKey=r.releaseHeldKeys=r.acquireHotKey=void 0;var e=p(n(92986)),a=n(24826),t=n(9394);function o(s){if(typeof WeakMap!="function")return null;var d=new WeakMap,v=new WeakMap;return(o=function(C){return C?v:d})(s)}function p(s,d){if(!d&&s&&s.__esModule)return s;if(s===null||typeof s!="object"&&typeof s!="function")return{default:s};var v=o(d);if(v&&v.has(s))return v.get(s);var g={__proto__:null},C=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var f in s)if(f!=="default"&&{}.hasOwnProperty.call(s,f)){var N=C?Object.getOwnPropertyDescriptor(s,f):null;N&&(N.get||N.set)?Object.defineProperty(g,f,N):g[f]=s[f]}return g.default=s,v&&v.set(s,g),g}/**
+ */var a=["f","p","n","\u03BC","m"," ","k","M","G","T","P","E","Z","Y"],t=a.indexOf(" "),o=r.formatSiUnit=function(){function S(k,h,i){if(h===void 0&&(h=-t),i===void 0&&(i=""),typeof k!="number"||!Number.isFinite(k))return k;var c=Math.floor(Math.log10(k)),m=Math.floor(Math.max(h*3,c)),l=Math.floor(c/3),u=Math.floor(m/3),s=(0,e.clamp)(t+u,0,a.length),d=a[s],C=k/Math.pow(1e3,u),g=l>h?2+u*3-m:0,v=(0,e.toFixed)(C,g)+" "+d+i;return v.trim()}return S}(),p=r.formatPower=function(){function S(k,h){return h===void 0&&(h=0),o(k,h,"W")}return S}(),b=r.formatMoney=function(){function S(k,h){if(h===void 0&&(h=0),!Number.isFinite(k))return k;var i=(0,e.round)(k,h);h>0&&(i=(0,e.toFixed)(k,h)),i=String(i);var c=i.length,m=i.indexOf(".");m===-1&&(m=c);for(var l="",u=0;u0&&u=0?"+":h<0?"\u2013":"",c=Math.abs(h);return c===1/0?c="Inf":c=(0,e.toFixed)(c,2),i+c+" dB"}return S}()},56518:function(T,r,n){"use strict";r.__esModule=!0,r.setupHotKeys=r.releaseHotKey=r.releaseHeldKeys=r.acquireHotKey=void 0;var e=p(n(92986)),a=n(24826),t=n(9394);function o(s){if(typeof WeakMap!="function")return null;var d=new WeakMap,C=new WeakMap;return(o=function(v){return v?C:d})(s)}function p(s,d){if(!d&&s&&s.__esModule)return s;if(s===null||typeof s!="object"&&typeof s!="function")return{default:s};var C=o(d);if(C&&C.has(s))return C.get(s);var g={__proto__:null},v=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var f in s)if(f!=="default"&&{}.hasOwnProperty.call(s,f)){var N=v?Object.getOwnPropertyDescriptor(s,f):null;N&&(N.get||N.set)?Object.defineProperty(g,f,N):g[f]=s[f]}return g.default=s,C&&C.set(s,g),g}/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */var b=(0,t.createLogger)("hotkeys"),y={},S=[e.KEY_ESCAPE,e.KEY_ENTER,e.KEY_SPACE,e.KEY_TAB,e.KEY_CTRL,e.KEY_SHIFT,e.KEY_UP,e.KEY_DOWN,e.KEY_LEFT,e.KEY_RIGHT],k={},h=function(d){if(d===16)return"Shift";if(d===17)return"Ctrl";if(d===18)return"Alt";if(d===33)return"Northeast";if(d===34)return"Southeast";if(d===35)return"Southwest";if(d===36)return"Northwest";if(d===37)return"West";if(d===38)return"North";if(d===39)return"East";if(d===40)return"South";if(d===45)return"Insert";if(d===46)return"Delete";if(d>=48&&d<=57||d>=65&&d<=90)return String.fromCharCode(d);if(d>=96&&d<=105)return"Numpad"+(d-96);if(d>=112&&d<=123)return"F"+(d-111);if(d===188)return",";if(d===189)return"-";if(d===190)return"."},i=function(d){var v=String(d);if(v==="Ctrl+F5"||v==="Ctrl+R"){location.reload();return}if(v!=="Ctrl+F"&&!(d.event.defaultPrevented||d.isModifierKey()||S.includes(d.code))){v==="F5"&&(d.event.preventDefault(),d.event.returnValue=!1);var g=h(d.code);if(g){var C=y[g];if(C)return b.debug("macro",C),Byond.command(C);if(d.isDown()&&!k[g]){k[g]=!0;var f='Key_Down "'+g+'"';return b.debug(f),Byond.command(f)}if(d.isUp()&&k[g]){k[g]=!1;var N='Key_Up "'+g+'"';return b.debug(N),Byond.command(N)}}}},c=r.acquireHotKey=function(){function s(d){S.push(d)}return s}(),m=r.releaseHotKey=function(){function s(d){var v=S.indexOf(d);v>=0&&S.splice(v,1)}return s}(),l=r.releaseHeldKeys=function(){function s(){for(var d=0,v=Object.keys(k);d0||(0,a.fetchRetry)((0,e.resolveAsset)("icon_ref_map.json")).then(function(b){return b.json()}).then(function(b){return Byond.iconRefMap=b}).catch(function(b){return t.logger.log(b)})}return p}()},1090:function(T,r,n){"use strict";r.__esModule=!0,r.AICard=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AICard=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;if(i.has_ai===0)return(0,e.createComponentVNode)(2,o.Window,{width:250,height:120,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Stored AI",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createVNode)(1,"h3",null,"No AI detected.",16)})})})});var c=null;return i.integrity>=75?c="green":i.integrity>=25?c="yellow":c="red",(0,e.createComponentVNode)(2,o.Window,{width:600,height:420,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:i.name,children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Integrity",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:c,value:i.integrity/100})})}),(0,e.createComponentVNode)(2,t.Box,{color:"red",children:(0,e.createVNode)(1,"h2",null,i.flushing===1?"Wipe of AI in progress...":"",0)})]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Laws",children:!!i.has_laws&&(0,e.createComponentVNode)(2,t.Box,{children:i.laws.map(function(m,l){return(0,e.createComponentVNode)(2,t.Box,{children:m},l)})})||(0,e.createComponentVNode)(2,t.Box,{color:"red",children:(0,e.createVNode)(1,"h3",null,"No laws detected.",16)})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Actions",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Wireless Activity",children:(0,e.createComponentVNode)(2,t.Button,{width:10,icon:i.wireless?"check":"times",content:i.wireless?"Enabled":"Disabled",color:i.wireless?"green":"red",onClick:function(){function m(){return h("wireless")}return m}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Subspace Transceiver",children:(0,e.createComponentVNode)(2,t.Button,{width:10,icon:i.radio?"check":"times",content:i.radio?"Enabled":"Disabled",color:i.radio?"green":"red",onClick:function(){function m(){return h("radio")}return m}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Wipe",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{width:10,icon:"trash-alt",confirmIcon:"trash-alt",disabled:i.flushing||i.integrity===0,confirmColor:"red",content:"Wipe AI",onClick:function(){function m(){return h("wipe")}return m}()})})]})})})]})})})}return b}()},39454:function(T,r,n){"use strict";r.__esModule=!0,r.AIFixer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AIFixer=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;if(i.occupant===null)return(0,e.createComponentVNode)(2,o.Window,{width:550,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Stored AI",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"average",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"robot",size:5,color:"silver"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"h3",null,"No Artificial Intelligence detected.",16)]})})})})});var c=!0;(i.stat===2||i.stat===null)&&(c=!1);var m=null;i.integrity>=75?m="green":i.integrity>=25?m="yellow":m="red";var l=!0;return i.integrity>=100&&i.stat!==2&&(l=!1),(0,e.createComponentVNode)(2,o.Window,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:i.occupant,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Integrity",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:m,value:i.integrity/100})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:c?"green":"red",children:c?"Functional":"Non-Functional"})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Laws",children:!!i.has_laws&&(0,e.createComponentVNode)(2,t.Box,{children:i.laws.map(function(u,s){return(0,e.createComponentVNode)(2,t.Box,{inline:!0,children:u},s)})})||(0,e.createComponentVNode)(2,t.Box,{color:"red",children:(0,e.createVNode)(1,"h3",null,"No laws detected.",16)})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Actions",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Wireless Activity",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.wireless?"times":"check",content:i.wireless?"Disabled":"Enabled",color:i.wireless?"red":"green",onClick:function(){function u(){return h("wireless")}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Subspace Transceiver",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.radio?"times":"check",content:i.radio?"Disabled":"Enabled",color:i.radio?"red":"green",onClick:function(){function u(){return h("radio")}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Start Repairs",children:(0,e.createComponentVNode)(2,t.Button,{icon:"wrench",disabled:!l||i.active,content:!l||i.active?"Already Repaired":"Repair",onClick:function(){function u(){return h("fix")}return u}()})})]}),(0,e.createComponentVNode)(2,t.Box,{color:"green",lineHeight:2,children:i.active?"Reconstruction in progress.":""})]})})]})})})}return b}()},88422:function(T,r,n){"use strict";r.__esModule=!0,r.APC=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(195),b=r.APC=function(){function h(i,c){return(0,e.createComponentVNode)(2,o.Window,{width:510,height:435,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,k)})})}return h}(),y={2:{color:"good",externalPowerText:"External Power",chargingText:"Fully Charged"},1:{color:"average",externalPowerText:"Low External Power",chargingText:"Charging"},0:{color:"bad",externalPowerText:"No External Power",chargingText:"Not Charging"}},S={1:{icon:"terminal",content:"Override Programming",action:"hack"},2:{icon:"caret-square-down",content:"Shunt Core Process",action:"occupy"},3:{icon:"caret-square-left",content:"Return to Main Core",action:"deoccupy"},4:{icon:"caret-square-down",content:"Shunt Core Process",action:"occupy"}},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.locked&&!u.siliconUser,d=u.normallyLocked,v=y[u.externalPower]||y[0],g=y[u.chargingStatus]||y[0],C=u.powerChannels||[],f=S[u.malfStatus]||S[0],N=u.powerCellStatus/100;return(0,e.createFragment)([(0,e.createComponentVNode)(2,p.InterfaceLockNoticeBox),(0,e.createComponentVNode)(2,t.Section,{title:"Power Status",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Main Breaker",color:v.color,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:u.isOperating?"power-off":"times",content:u.isOperating?"On":"Off",selected:u.isOperating&&!s,color:u.isOperating?"":"bad",disabled:s,onClick:function(){function V(){return l("breaker")}return V}()}),children:["[ ",v.externalPowerText," ]"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power Cell",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:"good",value:N})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Charge Mode",color:g.color,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:u.chargeMode?"sync":"times",content:u.chargeMode?"Auto":"Off",selected:u.chargeMode,disabled:s,onClick:function(){function V(){return l("charge")}return V}()}),children:["[ ",g.chargingText," ]"]})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Power Channels",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[C.map(function(V){var B=V.topicParams;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:V.title,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{inline:!0,mx:2,color:V.status>=2?"good":"bad",children:V.status>=2?"On":"Off"}),(0,e.createComponentVNode)(2,t.Button,{icon:"sync",content:"Auto",selected:!s&&(V.status===1||V.status===3),disabled:s,onClick:function(){function I(){return l("channel",B.auto)}return I}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:"On",selected:!s&&V.status===2,disabled:s,onClick:function(){function I(){return l("channel",B.on)}return I}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Off",selected:!s&&V.status===0,disabled:s,onClick:function(){function I(){return l("channel",B.off)}return I}()})],4),children:[V.powerLoad," W"]},V.title)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Total Load",children:(0,e.createVNode)(1,"b",null,[u.totalLoad,(0,e.createTextVNode)(" W")],0)})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Misc",buttons:!!u.siliconUser&&(0,e.createFragment)([!!u.malfStatus&&(0,e.createComponentVNode)(2,t.Button,{icon:f.icon,content:f.content,color:"bad",onClick:function(){function V(){return l(f.action)}return V}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"lightbulb-o",content:"Overload",onClick:function(){function V(){return l("overload")}return V}()})],0),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cover Lock",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.4,icon:u.coverLocked?"lock":"unlock",content:u.coverLocked?"Engaged":"Disengaged",disabled:s,onClick:function(){function V(){return l("cover")}return V}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Emergency Lighting",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"lightbulb-o",content:u.emergencyLights?"Enabled":"Disabled",disabled:s,onClick:function(){function V(){return l("emergency_lighting")}return V}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Night Shift Lighting",buttons:(0,e.createComponentVNode)(2,t.Button,{mt:.4,icon:"lightbulb-o",content:u.nightshiftLights?"Enabled":"Disabled",onClick:function(){function V(){return l("toggle_nightshift")}return V}()})})]})})],4)}},99660:function(T,r,n){"use strict";r.__esModule=!0,r.ATM=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ATM=function(){function m(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=v.view_screen,C=v.authenticated_account,f=v.ticks_left_locked_down,N=v.linked_db,V;if(f>0)V=(0,e.createComponentVNode)(2,t.Box,{bold:!0,color:"bad",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-triangle"}),"Maximum number of pin attempts exceeded! Access to this ATM has been temporarily disabled."]});else if(!N)V=(0,e.createComponentVNode)(2,t.Box,{bold:!0,color:"bad",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-triangle"}),"Unable to connect to accounts database, please retry and if the issue persists contact Nanotrasen IT support."]});else if(C)switch(g){case 1:V=(0,e.createComponentVNode)(2,y);break;case 2:V=(0,e.createComponentVNode)(2,S);break;case 3:V=(0,e.createComponentVNode)(2,i);break;default:V=(0,e.createComponentVNode)(2,k)}else V=(0,e.createComponentVNode)(2,h);return(0,e.createComponentVNode)(2,o.Window,{width:550,height:650,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,t.Section,{children:V})]})})}return m}(),b=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=v.machine_id,C=v.held_card_name;return(0,e.createComponentVNode)(2,t.Section,{title:"Nanotrasen Automatic Teller Machine",children:[(0,e.createComponentVNode)(2,t.Box,{children:"For all your monetary needs!"}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Card",children:(0,e.createComponentVNode)(2,t.Button,{content:C,icon:"eject",onClick:function(){function f(){return d("insert_card")}return f}()})})})]})},y=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=v.security_level;return(0,e.createComponentVNode)(2,t.Section,{title:"Select a new security level for this account",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Level",children:(0,e.createComponentVNode)(2,t.Button,{content:"Account Number",icon:"unlock",selected:g===0,onClick:function(){function C(){return d("change_security_level",{new_security_level:1})}return C}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:"Either the account number or card is required to access this account. EFTPOS transactions will require a card."}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Level",children:(0,e.createComponentVNode)(2,t.Button,{content:"Account Pin",icon:"unlock",selected:g===2,onClick:function(){function C(){return d("change_security_level",{new_security_level:2})}return C}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:"An account number and pin must be manually entered to access this account and process transactions."})]}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,c)]})},S=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=(0,a.useLocalState)(u,"targetAccNumber",0),C=g[0],f=g[1],N=(0,a.useLocalState)(u,"fundsAmount",0),V=N[0],B=N[1],I=(0,a.useLocalState)(u,"purpose",0),L=I[0],w=I[1],A=v.money;return(0,e.createComponentVNode)(2,t.Section,{title:"Transfer Fund",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Account Balance",children:["$",A]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target Account Number",children:(0,e.createComponentVNode)(2,t.Input,{placeholder:"7 Digit Number",onInput:function(){function x(E,P){return f(P)}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Funds to Transfer",children:(0,e.createComponentVNode)(2,t.Input,{onInput:function(){function x(E,P){return B(P)}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Transaction Purpose",children:(0,e.createComponentVNode)(2,t.Input,{fluid:!0,onInput:function(){function x(E,P){return w(P)}return x}()})})]}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.Button,{content:"Transfer",icon:"sign-out-alt",onClick:function(){function x(){return d("transfer",{target_acc_number:C,funds_amount:V,purpose:L})}return x}()}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,c)]})},k=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=(0,a.useLocalState)(u,"fundsAmount",0),C=g[0],f=g[1],N=v.owner_name,V=v.money;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"Welcome, "+N,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Logout",icon:"sign-out-alt",onClick:function(){function B(){return d("logout")}return B}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Account Balance",children:["$",V]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Withdrawal Amount",children:(0,e.createComponentVNode)(2,t.Input,{onInput:function(){function B(I,L){return f(L)}return B}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Withdraw Funds",icon:"sign-out-alt",onClick:function(){function B(){return d("withdrawal",{funds_amount:C})}return B}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Menu",children:[(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Change account security level",icon:"lock",onClick:function(){function B(){return d("view_screen",{view_screen:1})}return B}()})}),(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Make transfer",icon:"exchange-alt",onClick:function(){function B(){return d("view_screen",{view_screen:2})}return B}()})}),(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"View transaction log",icon:"list",onClick:function(){function B(){return d("view_screen",{view_screen:3})}return B}()})}),(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Print balance statement",icon:"print",onClick:function(){function B(){return d("balance_statement")}return B}()})})]})],4)},h=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=(0,a.useLocalState)(u,"accountID",null),C=g[0],f=g[1],N=(0,a.useLocalState)(u,"accountPin",null),V=N[0],B=N[1],I=v.machine_id,L=v.held_card_name;return(0,e.createComponentVNode)(2,t.Section,{title:"Insert card or enter ID and pin to login",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Account ID",children:(0,e.createComponentVNode)(2,t.Input,{placeholder:"6 Digit Number",onInput:function(){function w(A,x){return f(x)}return w}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Pin",children:(0,e.createComponentVNode)(2,t.Input,{placeholder:"6 Digit Number",onInput:function(){function w(A,x){return B(x)}return w}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Login",icon:"sign-in-alt",onClick:function(){function w(){return d("attempt_auth",{account_num:C,account_pin:V})}return w}()})})]})})},i=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=v.transaction_log;return(0,e.createComponentVNode)(2,t.Section,{title:"Transactions",children:[(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Timestamp"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Reason"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Value"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Terminal"})]}),g.map(function(C){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:C.time}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:C.purpose}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:C.is_deposit?"green":"red",children:["$",C.amount]}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:C.target_name})]},C)})]}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,c)]})},c=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data;return(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"sign-out-alt",onClick:function(){function g(){return d("view_screen",{view_screen:0})}return g}()})}},86423:function(T,r,n){"use strict";r.__esModule=!0,r.AccountsUplinkTerminal=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(36352),b=n(98595),y=n(321),S=n(5485),k=r.AccountsUplinkTerminal=function(){function v(g,C){var f=(0,t.useBackend)(C),N=f.act,V=f.data,B=V.loginState,I=V.currentPage,L;if(B.logged_in)I===1?L=(0,e.createComponentVNode)(2,i):I===2?L=(0,e.createComponentVNode)(2,s):I===3&&(L=(0,e.createComponentVNode)(2,d));else return(0,e.createComponentVNode)(2,b.Window,{width:800,height:600,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,S.LoginScreen)})})});return(0,e.createComponentVNode)(2,b.Window,{width:800,height:600,children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y.LoginInfo),(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:L})]})})})}return v}(),h=function(g,C){var f=(0,t.useBackend)(C),N=f.data,V=(0,t.useLocalState)(C,"tabIndex",0),B=V[0],I=V[1],L=N.login_state;return(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,mb:1,children:(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"list",selected:B===0,onClick:function(){function w(){return I(0)}return w}(),children:"User Accounts"}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"list",selected:B===1,onClick:function(){function w(){return I(1)}return w}(),children:"Department Accounts"})]})})})},i=function(g,C){var f=(0,t.useLocalState)(C,"tabIndex",0),N=f[0];switch(N){case 0:return(0,e.createComponentVNode)(2,c);case 1:return(0,e.createComponentVNode)(2,m);default:return"You are somehow on a tab that doesn't exist! Please let a coder know."}},c=function(g,C){var f=(0,t.useBackend)(C),N=f.act,V=f.data,B=V.accounts,I=(0,t.useLocalState)(C,"searchText",""),L=I[0],w=I[1],A=(0,t.useLocalState)(C,"sortId","owner_name"),x=A[0],E=A[1],P=(0,t.useLocalState)(C,"sortOrder",!0),D=P[0],M=P[1];return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,u),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"AccountsUplinkTerminal__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,l,{id:"owner_name",children:"Account Holder"}),(0,e.createComponentVNode)(2,l,{id:"account_number",children:"Account Number"}),(0,e.createComponentVNode)(2,l,{id:"suspended",children:"Account Status"}),(0,e.createComponentVNode)(2,l,{id:"money",children:"Account Balance"})]}),B.filter((0,a.createSearch)(L,function(O){return O.owner_name+"|"+O.account_number+"|"+O.suspended+"|"+O.money})).sort(function(O,R){var F=D?1:-1;return O[x].localeCompare(R[x])*F}).map(function(O){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"AccountsUplinkTerminal__listRow--"+O.suspended,onClick:function(){function R(){return N("view_account_detail",{account_num:O.account_number})}return R}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user"})," ",O.owner_name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:["#",O.account_number]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:O.suspended}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:O.money})]},O.account_number)})]})})})]})},m=function(g,C){var f=(0,t.useBackend)(C),N=f.act,V=f.data,B=V.department_accounts;return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.Table,{className:"AccountsUplinkTerminal__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,p.TableCell,{children:"Department Name"}),(0,e.createComponentVNode)(2,p.TableCell,{children:"Account Number"}),(0,e.createComponentVNode)(2,p.TableCell,{children:"Account Status"}),(0,e.createComponentVNode)(2,p.TableCell,{children:"Account Balance"})]}),B.map(function(I){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"AccountsUplinkTerminal__listRow--"+I.suspended,onClick:function(){function L(){return N("view_account_detail",{account_num:I.account_number})}return L}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"wallet"})," ",I.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:["#",I.account_number]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:I.suspended}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:I.money})]},I.account_number)})]})})})})},l=function(g,C){var f=(0,t.useLocalState)(C,"sortId","name"),N=f[0],V=f[1],B=(0,t.useLocalState)(C,"sortOrder",!0),I=B[0],L=B[1],w=g.id,A=g.children;return(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{color:N!==w&&"transparent",width:"100%",onClick:function(){function x(){N===w?L(!I):(V(w),L(!0))}return x}(),children:[A,N===w&&(0,e.createComponentVNode)(2,o.Icon,{name:I?"sort-up":"sort-down",ml:"0.25rem;"})]})})},u=function(g,C){var f=(0,t.useBackend)(C),N=f.act,V=f.data,B=V.is_printing,I=(0,t.useLocalState)(C,"searchText",""),L=I[0],w=I[1];return(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{content:"New Account",icon:"plus",onClick:function(){function A(){return N("create_new_account")}return A}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"Search by account holder, number, status",width:"100%",onInput:function(){function A(x,E){return w(E)}return A}()})})]})},s=function(g,C){var f=(0,t.useBackend)(C),N=f.act,V=f.data,B=V.account_number,I=V.owner_name,L=V.money,w=V.suspended,A=V.transactions,x=V.account_pin,E=V.is_department_account;return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:"#"+B+" / "+I,buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"arrow-left",content:"Back",onClick:function(){function P(){return N("back")}return P}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Number",children:["#",B]}),!!E&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Pin",children:x}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Pin Actions",children:(0,e.createComponentVNode)(2,o.Button,{ml:1,icon:"user-cog",content:"Set New Pin",disabled:!!E,onClick:function(){function P(){return N("set_account_pin",{account_number:B})}return P}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Holder",children:I}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Balance",children:L}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Status",color:w?"red":"green",children:[w?"Suspended":"Active",(0,e.createComponentVNode)(2,o.Button,{ml:1,content:w?"Unsuspend":"Suspend",icon:w?"unlock":"lock",onClick:function(){function P(){return N("toggle_suspension")}return P}()})]})]})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Transactions",children:(0,e.createComponentVNode)(2,o.Table,{children:[(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Timestamp"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Reason"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Value"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Terminal"})]}),A.map(function(P){return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:P.time}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:P.purpose}),(0,e.createComponentVNode)(2,o.Table.Cell,{color:P.is_deposit?"green":"red",children:["$",P.amount]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:P.target_name})]},P)})]})})})]})},d=function(g,C){var f=(0,t.useBackend)(C),N=f.act,V=f.data,B=(0,t.useLocalState)(C,"accName",""),I=B[0],L=B[1],w=(0,t.useLocalState)(C,"accDeposit",""),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,o.Section,{title:"Create Account",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"arrow-left",content:"Back",onClick:function(){function E(){return N("back")}return E}()}),children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Holder",children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"Name Here",onChange:function(){function E(P,D){return L(D)}return E}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Initial Deposit",children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"0",onChange:function(){function E(P,D){return x(D)}return E}()})})]}),(0,e.createComponentVNode)(2,o.Button,{mt:1,fluid:!0,content:"Create Account",onClick:function(){function E(){return N("finalise_create_account",{holder_name:I,starting_funds:A})}return E}()})]})}},39683:function(T,r,n){"use strict";r.__esModule=!0,r.AgentCardInfo=r.AgentCardAppearances=r.AgentCard=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=[{name:"Male",icon:"mars"},{name:"Female",icon:"venus"},{name:"Genderless",icon:"genderless"}],b=["A+","A-","B+","B-","AB+","AB-","O+","O-"],y="Empty",S=function(m){var l=m.label,u=m.value,s=m.onCommit,d=m.onClick,v=m.onRClick,g=m.tooltip;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:l,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,mb:-.5,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button.Input,{fluid:!0,textAlign:"center",content:u||y,onCommit:s})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"file-signature",tooltip:g,tooltipPosition:"bottom-end",onClick:d,onContextMenu:v})})]})})},k=r.AgentCard=function(){function c(m,l){var u=(0,a.useLocalState)(l,"tabIndex",0),s=u[0],d=u[1],v=function(){function g(C){switch(C){case 0:return(0,e.createComponentVNode)(2,h);case 1:return(0,e.createComponentVNode)(2,i);default:return(0,e.createComponentVNode)(2,h)}}return g}();return(0,e.createComponentVNode)(2,o.Window,{width:435,height:500,theme:"syndicate",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Tabs,{fluid:!0,children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:s===0,onClick:function(){function g(){return d(0)}return g}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"table"})," Card Info"]},"Card Info"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:s===1,onClick:function(){function g(){return d(1)}return g}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"id-card"})," Appearance"]},"Appearance")]})}),v(s)]})})})}return c}(),h=r.AgentCardInfo=function(){function c(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,v=d.registered_name,g=d.sex,C=d.age,f=d.assignment,N=d.job_icon,V=d.associated_account_number,B=d.blood_type,I=d.dna_hash,L=d.fingerprint_hash,w=d.photo,A=d.ai_tracking,x=d.photo_cooldown,E=(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("Autofill options."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("LMB - Autofill your own data."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("RMB - Autofill someone else data.")],4),P=(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("Autofill options."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("LMB - Autofill your own data."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("RMB - Autofill with random data.")],4);return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Card Info",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,S,{label:"Name",value:v,tooltip:E,onCommit:function(){function D(M,O){return s("change_name",{name:O})}return D}(),onClick:function(){function D(){return s("change_name",{option:"Primary"})}return D}(),onRClick:function(){function D(M){M.preventDefault(),s("change_name",{option:"Secondary"})}return D}()}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Sex",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,mb:-.5,children:p.map(function(D){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:D.icon,content:D.name,selected:g===D.name,onClick:function(){function M(){return s("change_sex",{sex:D.name})}return M}()})},D.name)})})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Age",children:(0,e.createComponentVNode)(2,t.Slider,{fluid:!0,minValue:17,value:C||0,maxValue:300,onChange:function(){function D(M,O){return s("change_age",{age:O})}return D}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rank",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,mb:-.5,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:function(){function D(){return s("change_occupation")}return D}(),textAlign:"middle",children:f||"[UNSET]"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{tooltip:"Change HUD icon",tooltipPosition:"bottom-end",onClick:function(){function D(){return s("change_occupation",{option:"Primary"})}return D}(),children:[(0,e.createComponentVNode)(2,t.DmIcon,{fill:!0,icon:"icons/mob/hud/job_assets.dmi",icon_state:N,verticalAlign:"bottom",my:"2px",width:"16px"})," "]})})]})}),(0,e.createComponentVNode)(2,S,{label:"Fingerprint",value:L,onCommit:function(){function D(M,O){return s("change_fingerprints",{new_fingerprints:O})}return D}(),onClick:function(){function D(){return s("change_fingerprints",{option:"Primary"})}return D}(),onRClick:function(){function D(M){M.preventDefault(),s("change_fingerprints",{option:"Secondary"})}return D}(),tooltip:P}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood Type",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,mb:-.5,children:b.map(function(D){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:D,selected:B===D,onClick:function(){function M(){return s("change_blood_type",{new_type:D})}return M}()})},D)})})}),(0,e.createComponentVNode)(2,S,{label:"DNA",value:I,onCommit:function(){function D(M,O){return s("change_dna_hash",{new_dna:O})}return D}(),onClick:function(){function D(){return s("change_dna_hash",{option:"Primary"})}return D}(),onRClick:function(){function D(M){M.preventDefault(),s("change_dna_hash",{option:"Secondary"})}return D}(),tooltip:P}),(0,e.createComponentVNode)(2,S,{label:"Account",value:V||0,onCommit:function(){function D(M,O){return s("change_money_account",{new_account:O})}return D}(),onClick:function(){function D(){return s("change_money_account",{option:"Primary"})}return D}(),onRClick:function(){function D(M){M.preventDefault(),s("change_money_account",{option:"Secondary"})}return D}(),tooltip:P}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Photo",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",disabled:!x,tooltip:x?"":"You can't generate a new photo yet.",onClick:function(){function D(){return s("change_photo")}return D}(),children:w?"Update":y})})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Card Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Card Info",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{fluid:!0,textAlign:"center",content:"Delete Card Info",confirmContent:"Are you sure?",onClick:function(){function D(){return s("delete_info")}return D}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Access",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{fluid:!0,textAlign:"center",content:"Reset Access",confirmContent:"Are you sure?",onClick:function(){function D(){return s("clear_access")}return D}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"AI Tracking",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",onClick:function(){function D(){return s("change_ai_tracking")}return D}(),children:A?"Untrackable":"Trackable"})})]})})})],4)}return c}(),i=r.AgentCardAppearances=function(){function c(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,v=(0,a.useSharedState)(l,"selectedAppearance",null),g=v[0],C=v[1],f=d.appearances,N=d.id_icon;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Card Appearance",children:f.map(function(V){return(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:N,dmIconState:V,imageSize:64,compact:!0,selected:V===g,tooltip:V,style:{opacity:V===g&&"1"||"0.5"},onClick:function(){function B(){C(V),s("change_appearance",{new_appearance:V})}return B}()},V)})})})}return c}()},56793:function(T,r,n){"use strict";r.__esModule=!0,r.AiAirlock=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p={2:{color:"good",localStatusText:"Offline"},1:{color:"average",localStatusText:"Caution"},0:{color:"bad",localStatusText:"Optimal"}},b=r.AiAirlock=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=p[c.power.main]||p[0],l=p[c.power.backup]||p[0],u=p[c.shock]||p[0];return(0,e.createComponentVNode)(2,o.Window,{width:500,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Power Status",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Main",color:m.color,buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,icon:"lightbulb-o",disabled:!c.power.main,content:"Disrupt",onClick:function(){function s(){return i("disrupt-main")}return s}()}),children:[c.power.main?"Online":"Offline"," ",!c.wires.main_power&&"[Wires have been cut!]"||c.power.main_timeleft>0&&"["+c.power.main_timeleft+"s]"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Backup",color:l.color,buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,icon:"lightbulb-o",disabled:!c.power.backup,content:"Disrupt",onClick:function(){function s(){return i("disrupt-backup")}return s}()}),children:[c.power.backup?"Online":"Offline"," ",!c.wires.backup_power&&"[Wires have been cut!]"||c.power.backup_timeleft>0&&"["+c.power.backup_timeleft+"s]"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Electrify",color:u.color,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{mr:.5,icon:"wrench",disabled:!(c.wires.shock&&c.shock!==2),content:"Restore",onClick:function(){function s(){return i("shock-restore")}return s}()}),(0,e.createComponentVNode)(2,t.Button,{mr:.5,icon:"bolt",disabled:!c.wires.shock,content:"Temporary",onClick:function(){function s(){return i("shock-temp")}return s}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"bolt",disabled:!c.wires.shock||c.shock===0,content:"Permanent",onClick:function(){function s(){return i("shock-perm")}return s}()})],4),children:[c.shock===2?"Safe":"Electrified"," ",!c.wires.shock&&"[Wires have been cut!]"||c.shock_timeleft>0&&"["+c.shock_timeleft+"s]"||c.shock_timeleft===-1&&"[Permanent]"]})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Access and Door Control",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID Scan",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,width:6.5,icon:c.id_scanner?"power-off":"times",content:c.id_scanner?"Enabled":"Disabled",selected:c.id_scanner,disabled:!c.wires.id_scanner,onClick:function(){function s(){return i("idscan-toggle")}return s}()}),children:!c.wires.id_scanner&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Emergency Access",buttons:(0,e.createComponentVNode)(2,t.Button,{width:6.5,icon:c.emergency?"power-off":"times",content:c.emergency?"Enabled":"Disabled",selected:c.emergency,onClick:function(){function s(){return i("emergency-toggle")}return s}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Bolts",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,icon:c.locked?"lock":"unlock",content:c.locked?"Lowered":"Raised",selected:c.locked,disabled:!c.wires.bolts,onClick:function(){function s(){return i("bolt-toggle")}return s}()}),children:!c.wires.bolts&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Bolt Lights",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,width:6.5,icon:c.lights?"power-off":"times",content:c.lights?"Enabled":"Disabled",selected:c.lights,disabled:!c.wires.lights,onClick:function(){function s(){return i("light-toggle")}return s}()}),children:!c.wires.lights&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Force Sensors",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,width:6.5,icon:c.safe?"power-off":"times",content:c.safe?"Enabled":"Disabled",selected:c.safe,disabled:!c.wires.safe,onClick:function(){function s(){return i("safe-toggle")}return s}()}),children:!c.wires.safe&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Timing Safety",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,width:6.5,icon:c.speed?"power-off":"times",content:c.speed?"Enabled":"Disabled",selected:c.speed,disabled:!c.wires.timing,onClick:function(){function s(){return i("speed-toggle")}return s}()}),children:!c.wires.timing&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Control",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:c.opened?"sign-out-alt":"sign-in-alt",content:c.opened?"Open":"Closed",selected:c.opened,disabled:c.locked||c.welded,onClick:function(){function s(){return i("open-close")}return s}()}),children:!!(c.locked||c.welded)&&(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("[Door is "),c.locked?"bolted":"",c.locked&&c.welded?" and ":"",c.welded?"welded":"",(0,e.createTextVNode)("!]")],0)})]})})]})})}return y}()},72475:function(T,r,n){"use strict";r.__esModule=!0,r.AirAlarm=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(195),b=r.AirAlarm=function(){function u(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.locked;return(0,e.createComponentVNode)(2,o.Window,{width:570,height:f?310:755,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,p.InterfaceLockNoticeBox),(0,e.createComponentVNode)(2,S),!f&&(0,e.createFragment)([(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,h)],4)]})})}return u}(),y=function(s){return s===0?"green":s===1?"orange":"red"},S=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.air,N=C.mode,V=C.atmos_alarm,B=C.locked,I=C.alarmActivated,L=C.rcon,w=C.target_temp,A;return f.danger.overall===0?V===0?A="Optimal":A="Caution: Atmos alert in area":f.danger.overall===1?A="Caution":A="DANGER: Internals Required",(0,e.createComponentVNode)(2,t.Section,{title:"Air Status",children:f?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Pressure",children:(0,e.createComponentVNode)(2,t.Box,{color:y(f.danger.pressure),children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:f.pressure})," kPa",!B&&(0,e.createFragment)([(0,e.createTextVNode)("\xA0"),(0,e.createComponentVNode)(2,t.Button,{content:N===3?"Deactivate Panic Siphon":"Activate Panic Siphon",selected:N===3,icon:"exclamation-triangle",onClick:function(){function x(){return g("mode",{mode:N===3?1:3})}return x}()})],4)]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Oxygen",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.oxygen/100,fractionDigits:"1",color:y(f.danger.oxygen)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Nitrogen",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.nitrogen/100,fractionDigits:"1",color:y(f.danger.nitrogen)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Carbon Dioxide",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.co2/100,fractionDigits:"1",color:y(f.danger.co2)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Toxins",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.plasma/100,fractionDigits:"1",color:y(f.danger.plasma)})}),f.contents.n2o>.1&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Nitrous Oxide",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.n2o/100,fractionDigits:"1",color:y(f.danger.n2o)})}),f.contents.other>.1&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Other",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.other/100,fractionDigits:"1",color:y(f.danger.other)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,t.Box,{color:y(f.danger.temperature),children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:f.temperature})," K / ",(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:f.temperature_c})," C\xA0",(0,e.createComponentVNode)(2,t.Button,{icon:"thermometer-full",content:w+" C",onClick:function(){function x(){return g("temperature")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{content:f.thermostat_state?"On":"Off",selected:f.thermostat_state,icon:"power-off",onClick:function(){function x(){return g("thermostat_state")}return x}()})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Local Status",children:(0,e.createComponentVNode)(2,t.Box,{color:y(f.danger.overall),children:[A,!B&&(0,e.createFragment)([(0,e.createTextVNode)("\xA0"),(0,e.createComponentVNode)(2,t.Button,{content:I?"Reset Alarm":"Activate Alarm",selected:I,onClick:function(){function x(){return g(I?"atmos_reset":"atmos_alarm")}return x}()})],4)]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Remote Control Settings",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Off",selected:L===1,onClick:function(){function x(){return g("set_rcon",{rcon:1})}return x}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Auto",selected:L===2,onClick:function(){function x(){return g("set_rcon",{rcon:2})}return x}()}),(0,e.createComponentVNode)(2,t.Button,{content:"On",selected:L===3,onClick:function(){function x(){return g("set_rcon",{rcon:3})}return x}()})]})]}):(0,e.createComponentVNode)(2,t.Box,{children:"Unable to acquire air sample!"})})},k=function(s,d){var v=(0,a.useLocalState)(d,"tabIndex",0),g=v[0],C=v[1];return(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g===0,onClick:function(){function f(){return C(0)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"sign-out-alt"})," Vent Control"]},"Vents"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g===1,onClick:function(){function f(){return C(1)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"sign-in-alt"})," Scrubber Control"]},"Scrubbers"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g===2,onClick:function(){function f(){return C(2)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"cog"})," Mode"]},"Mode"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g===3,onClick:function(){function f(){return C(3)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"tachometer-alt"})," Thresholds"]},"Thresholds")]})},h=function(s,d){var v=(0,a.useLocalState)(d,"tabIndex",0),g=v[0],C=v[1];switch(g){case 0:return(0,e.createComponentVNode)(2,i);case 1:return(0,e.createComponentVNode)(2,c);case 2:return(0,e.createComponentVNode)(2,m);case 3:return(0,e.createComponentVNode)(2,l);default:return"WE SHOULDN'T BE HERE!"}},i=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.vents;return f.map(function(N){return(0,e.createComponentVNode)(2,t.Section,{title:N.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:[(0,e.createComponentVNode)(2,t.Button,{content:N.power?"On":"Off",selected:N.power,icon:"power-off",onClick:function(){function V(){return g("command",{cmd:"power",val:!N.power,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:N.direction?"Blowing":"Siphoning",icon:N.direction?"sign-out-alt":"sign-in-alt",onClick:function(){function V(){return g("command",{cmd:"direction",val:!N.direction,id_tag:N.id_tag})}return V}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Pressure Checks",children:[(0,e.createComponentVNode)(2,t.Button,{content:"External",selected:N.checks===1,onClick:function(){function V(){return g("command",{cmd:"checks",val:1,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Internal",selected:N.checks===2,onClick:function(){function V(){return g("command",{cmd:"checks",val:2,id_tag:N.id_tag})}return V}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"External Pressure Target",children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:N.external})," kPa\xA0",(0,e.createComponentVNode)(2,t.Button,{content:"Set",icon:"cog",onClick:function(){function V(){return g("command",{cmd:"set_external_pressure",id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Reset",icon:"redo-alt",onClick:function(){function V(){return g("command",{cmd:"set_external_pressure",val:101.325,id_tag:N.id_tag})}return V}()})]})]})},N.name)})},c=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.scrubbers;return f.map(function(N){return(0,e.createComponentVNode)(2,t.Section,{title:N.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:[(0,e.createComponentVNode)(2,t.Button,{content:N.power?"On":"Off",selected:N.power,icon:"power-off",onClick:function(){function V(){return g("command",{cmd:"power",val:!N.power,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:N.scrubbing?"Scrubbing":"Siphoning",icon:N.scrubbing?"filter":"sign-in-alt",onClick:function(){function V(){return g("command",{cmd:"scrubbing",val:!N.scrubbing,id_tag:N.id_tag})}return V}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Range",children:(0,e.createComponentVNode)(2,t.Button,{content:N.widenet?"Extended":"Normal",selected:N.widenet,icon:"expand-arrows-alt",onClick:function(){function V(){return g("command",{cmd:"widenet",val:!N.widenet,id_tag:N.id_tag})}return V}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Filtering",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Carbon Dioxide",selected:N.filter_co2,onClick:function(){function V(){return g("command",{cmd:"co2_scrub",val:!N.filter_co2,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Plasma",selected:N.filter_toxins,onClick:function(){function V(){return g("command",{cmd:"tox_scrub",val:!N.filter_toxins,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Nitrous Oxide",selected:N.filter_n2o,onClick:function(){function V(){return g("command",{cmd:"n2o_scrub",val:!N.filter_n2o,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Oxygen",selected:N.filter_o2,onClick:function(){function V(){return g("command",{cmd:"o2_scrub",val:!N.filter_o2,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Nitrogen",selected:N.filter_n2,onClick:function(){function V(){return g("command",{cmd:"n2_scrub",val:!N.filter_n2,id_tag:N.id_tag})}return V}()})]})]})},N.name)})},m=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.modes,N=C.presets,V=C.emagged,B=C.mode,I=C.preset;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"System Mode",children:(0,e.createComponentVNode)(2,t.Table,{children:f.map(function(L){return(!L.emagonly||L.emagonly&&!!V)&&(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",width:1,children:(0,e.createComponentVNode)(2,t.Button,{content:L.name,icon:"cog",selected:L.id===B,onClick:function(){function w(){return g("mode",{mode:L.id})}return w}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:L.desc})]},L.name)})})}),(0,e.createComponentVNode)(2,t.Section,{title:"System Presets",children:[(0,e.createComponentVNode)(2,t.Box,{italic:!0,children:"After making a selection, the system will automatically cycle in order to remove contaminants."}),(0,e.createComponentVNode)(2,t.Table,{mt:1,children:N.map(function(L){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",width:1,children:(0,e.createComponentVNode)(2,t.Button,{content:L.name,icon:"cog",selected:L.id===I,onClick:function(){function w(){return g("preset",{preset:L.id})}return w}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:L.desc})]},L.name)})})]})],4)},l=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.thresholds;return(0,e.createComponentVNode)(2,t.Section,{title:"Alarm Thresholds",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{width:"20%",children:"Value"}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:"red",width:"20%",children:"Danger Min"}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:"orange",width:"20%",children:"Warning Min"}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:"orange",width:"20%",children:"Warning Max"}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:"red",width:"20%",children:"Danger Max"})]}),f.map(function(N){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:N.name}),N.settings.map(function(V){return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:V.selected===-1?"Off":V.selected,onClick:function(){function B(){return g("command",{cmd:"set_threshold",env:V.env,var:V.val})}return B}()})},V.val)})]},N.name)})]})})}},12333:function(T,r,n){"use strict";r.__esModule=!0,r.AirlockAccessController=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AirlockAccessController=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.exterior_status,m=i.interior_status,l=i.processing,u,s;return c==="open"?u=(0,e.createComponentVNode)(2,t.Button,{width:"50%",content:"Lock Exterior Door",icon:"exclamation-triangle",disabled:l,onClick:function(){function d(){return h("force_ext")}return d}()}):u=(0,e.createComponentVNode)(2,t.Button,{width:"50%",content:"Cycle to Exterior",icon:"arrow-circle-left",disabled:l,onClick:function(){function d(){return h("cycle_ext_door")}return d}()}),m==="open"?s=(0,e.createComponentVNode)(2,t.Button,{width:"49%",content:"Lock Interior Door",icon:"exclamation-triangle",disabled:l,color:m==="open"?"red":l?"yellow":null,onClick:function(){function d(){return h("force_int")}return d}()}):s=(0,e.createComponentVNode)(2,t.Button,{width:"49%",content:"Cycle to Interior",icon:"arrow-circle-right",disabled:l,onClick:function(){function d(){return h("cycle_int_door")}return d}()}),(0,e.createComponentVNode)(2,o.Window,{width:330,height:200,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Information",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"External Door Status",children:c==="closed"?"Locked":"Open"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Internal Door Status",children:m==="closed"?"Locked":"Open"})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Actions",children:(0,e.createComponentVNode)(2,t.Box,{children:[u,s]})})]})})}return b}()},28736:function(T,r,n){"use strict";r.__esModule=!0,r.AirlockElectronics=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(49148),b=1,y=2,S=4,k=8,h=r.AirlockElectronics=function(){function m(l,u){return(0,e.createComponentVNode)(2,o.Window,{width:450,height:565,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c)]})})})}return m}(),i=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=v.unrestricted_dir;return(0,e.createComponentVNode)(2,t.Section,{title:"Access Control",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,mb:1,children:"Unrestricted Access From:"}),(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"arrow-left",content:"East",selected:g&S,onClick:function(){function C(){return d("unrestricted_access",{unres_dir:S})}return C}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"arrow-up",content:"South",selected:g&y,onClick:function(){function C(){return d("unrestricted_access",{unres_dir:y})}return C}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"arrow-right",content:"West",selected:g&k,onClick:function(){function C(){return d("unrestricted_access",{unres_dir:k})}return C}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"arrow-down",content:"North",selected:g&b,onClick:function(){function C(){return d("unrestricted_access",{unres_dir:b})}return C}()})})]})]})})},c=function(l,u){var s=(0,a.useBackend)(u),d=s.act,v=s.data,g=v.selected_accesses,C=v.one_access,f=v.regions;return(0,e.createComponentVNode)(2,p.AccessList,{usedByRcd:1,rcdButtons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:C,content:"One",onClick:function(){function N(){return d("set_one_access",{access:"one"})}return N}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!C,content:"All",onClick:function(){function N(){return d("set_one_access",{access:"all"})}return N}()})],4),accesses:f,selectedList:g,accessMod:function(){function N(V){return d("set",{access:V})}return N}(),grantAll:function(){function N(){return d("grant_all")}return N}(),denyAll:function(){function N(){return d("clear_all")}return N}(),grantDep:function(){function N(V){return d("grant_region",{region:V})}return N}(),denyDep:function(){function N(V){return d("deny_region",{region:V})}return N}()})}},47365:function(T,r,n){"use strict";r.__esModule=!0,r.AlertModal=void 0;var e=n(89005),a=n(51057),t=n(72253),o=n(92986),p=n(36036),b=n(98595),y=-1,S=1,k=r.AlertModal=function(){function c(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=d.autofocus,g=d.buttons,C=g===void 0?[]:g,f=d.large_buttons,N=d.message,V=N===void 0?"":N,B=d.timeout,I=d.title,L=(0,t.useLocalState)(l,"selected",0),w=L[0],A=L[1],x=110+(V.length>30?Math.ceil(V.length/4):0)+(V.length&&f?5:0),E=325+(C.length>2?100:0),P=function(){function D(M){w===0&&M===y?A(C.length-1):w===C.length-1&&M===S?A(0):A(w+M)}return D}();return(0,e.createComponentVNode)(2,b.Window,{title:I,height:x,width:E,children:[!!B&&(0,e.createComponentVNode)(2,a.Loader,{value:B}),(0,e.createComponentVNode)(2,b.Window.Content,{onKeyDown:function(){function D(M){var O=window.event?M.which:M.keyCode;O===o.KEY_SPACE||O===o.KEY_ENTER?s("choose",{choice:C[w]}):O===o.KEY_ESCAPE?s("cancel"):O===o.KEY_LEFT?(M.preventDefault(),P(y)):(O===o.KEY_TAB||O===o.KEY_RIGHT)&&(M.preventDefault(),P(S))}return D}(),children:(0,e.createComponentVNode)(2,p.Section,{fill:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,m:1,children:(0,e.createComponentVNode)(2,p.Box,{color:"label",overflow:"hidden",children:V})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:[!!v&&(0,e.createComponentVNode)(2,p.Autofocus),(0,e.createComponentVNode)(2,h,{selected:w})]})]})})})]})}return c}(),h=function(m,l){var u=(0,t.useBackend)(l),s=u.data,d=s.buttons,v=d===void 0?[]:d,g=s.large_buttons,C=s.swapped_buttons,f=m.selected;return(0,e.createComponentVNode)(2,p.Flex,{fill:!0,align:"center",direction:C?"row":"row-reverse",justify:"space-around",wrap:!0,children:v==null?void 0:v.map(function(N,V){return g&&v.length<3?(0,e.createComponentVNode)(2,p.Flex.Item,{grow:!0,children:(0,e.createComponentVNode)(2,i,{button:N,id:V.toString(),selected:f===V})},V):(0,e.createComponentVNode)(2,p.Flex.Item,{grow:g?1:0,children:(0,e.createComponentVNode)(2,i,{button:N,id:V.toString(),selected:f===V})},V)})})},i=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=d.large_buttons,g=m.button,C=m.selected,f=g.length>7?"100%":7;return(0,e.createComponentVNode)(2,p.Button,{mx:v?1:0,pt:v?.33:0,content:g,fluid:!!v,onClick:function(){function N(){return s("choose",{choice:g})}return N}(),selected:C,textAlign:"center",height:!!v&&2,width:!v&&f})}},71824:function(T,r,n){"use strict";r.__esModule=!0,r.AppearanceChanger=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AppearanceChanger=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.change_race,l=c.species,u=c.specimen,s=c.change_gender,d=c.gender,v=c.change_eye_color,g=c.change_skin_tone,C=c.change_skin_color,f=c.change_runechat_color,N=c.change_head_accessory_color,V=c.change_hair_color,B=c.change_secondary_hair_color,I=c.change_facial_hair_color,L=c.change_secondary_facial_hair_color,w=c.change_head_marking_color,A=c.change_body_marking_color,x=c.change_tail_marking_color,E=c.change_head_accessory,P=c.head_accessory_styles,D=c.head_accessory_style,M=c.change_hair,O=c.hair_styles,R=c.hair_style,F=c.change_hair_gradient,W=c.change_facial_hair,U=c.facial_hair_styles,z=c.facial_hair_style,$=c.change_head_markings,G=c.head_marking_styles,X=c.head_marking_style,J=c.change_body_markings,se=c.body_marking_styles,ie=c.body_marking_style,me=c.change_tail_markings,q=c.tail_marking_styles,re=c.tail_marking_style,ae=c.change_body_accessory,le=c.body_accessory_styles,Z=c.body_accessory_style,ne=c.change_alt_head,te=c.alt_head_styles,fe=c.alt_head_style,pe=!1;return(v||g||C||N||f||V||B||I||L||w||A||x)&&(pe=!0),(0,e.createComponentVNode)(2,o.Window,{width:800,height:450,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[!!m&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Species",children:l.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.specimen,selected:ce.specimen===u,onClick:function(){function Ve(){return i("race",{race:ce.specimen})}return Ve}()},ce.specimen)})}),!!s&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Gender",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Male",selected:d==="male",onClick:function(){function ce(){return i("gender",{gender:"male"})}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Female",selected:d==="female",onClick:function(){function ce(){return i("gender",{gender:"female"})}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Genderless",selected:d==="plural",onClick:function(){function ce(){return i("gender",{gender:"plural"})}return ce}()})]}),!!pe&&(0,e.createComponentVNode)(2,b),!!E&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Head accessory",children:P.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.headaccessorystyle,selected:ce.headaccessorystyle===D,onClick:function(){function Ve(){return i("head_accessory",{head_accessory:ce.headaccessorystyle})}return Ve}()},ce.headaccessorystyle)})}),!!M&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hair",children:O.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.hairstyle,selected:ce.hairstyle===R,onClick:function(){function Ve(){return i("hair",{hair:ce.hairstyle})}return Ve}()},ce.hairstyle)})}),!!F&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hair Gradient",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Change Style",onClick:function(){function ce(){return i("hair_gradient")}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Change Offset",onClick:function(){function ce(){return i("hair_gradient_offset")}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Change Color",onClick:function(){function ce(){return i("hair_gradient_colour")}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Change Alpha",onClick:function(){function ce(){return i("hair_gradient_alpha")}return ce}()})]}),!!W&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Facial hair",children:U.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.facialhairstyle,selected:ce.facialhairstyle===z,onClick:function(){function Ve(){return i("facial_hair",{facial_hair:ce.facialhairstyle})}return Ve}()},ce.facialhairstyle)})}),!!$&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Head markings",children:G.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.headmarkingstyle,selected:ce.headmarkingstyle===X,onClick:function(){function Ve(){return i("head_marking",{head_marking:ce.headmarkingstyle})}return Ve}()},ce.headmarkingstyle)})}),!!J&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Body markings",children:se.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.bodymarkingstyle,selected:ce.bodymarkingstyle===ie,onClick:function(){function Ve(){return i("body_marking",{body_marking:ce.bodymarkingstyle})}return Ve}()},ce.bodymarkingstyle)})}),!!me&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tail markings",children:q.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.tailmarkingstyle,selected:ce.tailmarkingstyle===re,onClick:function(){function Ve(){return i("tail_marking",{tail_marking:ce.tailmarkingstyle})}return Ve}()},ce.tailmarkingstyle)})}),!!ae&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Body accessory",children:le.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.bodyaccessorystyle,selected:ce.bodyaccessorystyle===Z,onClick:function(){function Ve(){return i("body_accessory",{body_accessory:ce.bodyaccessorystyle})}return Ve}()},ce.bodyaccessorystyle)})}),!!ne&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Alternate head",children:te.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.altheadstyle,selected:ce.altheadstyle===fe,onClick:function(){function Ve(){return i("alt_head",{alt_head:ce.altheadstyle})}return Ve}()},ce.altheadstyle)})})]})})})}return y}(),b=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=[{key:"change_eye_color",text:"Change eye color",action:"eye_color"},{key:"change_skin_tone",text:"Change skin tone",action:"skin_tone"},{key:"change_skin_color",text:"Change skin color",action:"skin_color"},{key:"change_runechat_color",text:"Change runechat color",action:"runechat_color"},{key:"change_head_accessory_color",text:"Change head accessory color",action:"head_accessory_color"},{key:"change_hair_color",text:"Change hair color",action:"hair_color"},{key:"change_secondary_hair_color",text:"Change secondary hair color",action:"secondary_hair_color"},{key:"change_facial_hair_color",text:"Change facial hair color",action:"facial_hair_color"},{key:"change_secondary_facial_hair_color",text:"Change secondary facial hair color",action:"secondary_facial_hair_color"},{key:"change_head_marking_color",text:"Change head marking color",action:"head_marking_color"},{key:"change_body_marking_color",text:"Change body marking color",action:"body_marking_color"},{key:"change_tail_marking_color",text:"Change tail marking color",action:"tail_marking_color"}];return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Colors",children:m.map(function(l){return!!c[l.key]&&(0,e.createComponentVNode)(2,t.Button,{content:l.text,onClick:function(){function u(){return i(l.action)}return u}()},l.key)})})}},72285:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosAlertConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AtmosAlertConsole=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.priority||[],m=i.minor||[];return(0,e.createComponentVNode)(2,o.Window,{width:350,height:300,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Alarms",children:(0,e.createVNode)(1,"ul",null,[c.length===0&&(0,e.createVNode)(1,"li","color-good","No Priority Alerts",16),c.map(function(l){return(0,e.createVNode)(1,"li","color-bad",l,0,null,l)}),m.length===0&&(0,e.createVNode)(1,"li","color-good","No Minor Alerts",16),m.map(function(l){return(0,e.createVNode)(1,"li","color-average",l,0,null,l)})],0)})})})}return b}()},65805:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosControl=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(36352),p=n(98595),b=function(c){if(c===0)return(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Good"});if(c===1)return(0,e.createComponentVNode)(2,t.Box,{color:"orange",bold:!0,children:"Warning"});if(c===2)return(0,e.createComponentVNode)(2,t.Box,{color:"red",bold:!0,children:"DANGER"})},y=function(c){if(c===0)return"green";if(c===1)return"orange";if(c===2)return"red"},S=r.AtmosControl=function(){function i(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=(0,a.useLocalState)(m,"tabIndex",0),v=d[0],g=d[1],C=function(){function f(N){switch(N){case 0:return(0,e.createComponentVNode)(2,k);case 1:return(0,e.createComponentVNode)(2,h);default:return"WE SHOULDN'T BE HERE!"}}return f}();return(0,e.createComponentVNode)(2,p.Window,{width:800,height:600,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:v===0,children:(0,e.createComponentVNode)(2,t.Box,{fillPositionedParent:!0,children:[(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:v===0,onClick:function(){function f(){return g(0)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"table"})," Data View"]},"DataView"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:v===1,onClick:function(){function f(){return g(1)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"map-marked-alt"})," Map View"]},"MapView")]}),C(v)]})})})}return i}(),k=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.alarms;return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Access"})]}),d.map(function(v){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,o.TableCell,{children:v.name}),(0,e.createComponentVNode)(2,o.TableCell,{children:b(v.danger)}),(0,e.createComponentVNode)(2,o.TableCell,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"cog",content:"Access",onClick:function(){function g(){return u("open_alarm",{aref:v.ref})}return g}()})})]},v.name)})]})})},h=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.alarms;return(0,e.createComponentVNode)(2,t.Box,{height:"526px",mb:"0.5rem",overflow:"hidden",children:(0,e.createComponentVNode)(2,t.NanoMap,{children:d.filter(function(v){return v.z===2}).map(function(v){return(0,e.createComponentVNode)(2,t.NanoMap.MarkerIcon,{x:v.x,y:v.y,icon:"circle",tooltip:v.name,color:y(v.danger),onClick:function(){function g(){return u("open_alarm",{aref:v.ref})}return g}()},v.ref)})})})}},87816:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosFilter=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AtmosFilter=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.on,m=i.pressure,l=i.max_pressure,u=i.filter_type,s=i.filter_type_list;return(0,e.createComponentVNode)(2,o.Window,{width:380,height:140,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:c?"On":"Off",color:c?null:"red",selected:c,onClick:function(){function d(){return h("power")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",textAlign:"center",disabled:m===0,width:2.2,onClick:function(){function d(){return h("min_pressure")}return d}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"kPa",width:6.1,lineHeight:1.5,step:10,minValue:0,maxValue:l,value:m,onDrag:function(){function d(v,g){return h("custom_pressure",{pressure:g})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",textAlign:"center",disabled:m===l,width:2.2,onClick:function(){function d(){return h("max_pressure")}return d}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Filter",children:s.map(function(d){return(0,e.createComponentVNode)(2,t.Button,{selected:d.gas_type===u,content:d.label,onClick:function(){function v(){return h("set_filter",{filter:d.gas_type})}return v}()},d.label)})})]})})})})}return b}()},52977:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosMixer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AtmosMixer=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.on,l=c.pressure,u=c.max_pressure,s=c.node1_concentration,d=c.node2_concentration;return(0,e.createComponentVNode)(2,o.Window,{width:330,height:165,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:m?"On":"Off",color:m?null:"red",selected:m,onClick:function(){function v(){return i("power")}return v}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",textAlign:"center",disabled:l===0,width:2.2,onClick:function(){function v(){return i("min_pressure")}return v}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"kPa",width:6.1,lineHeight:1.5,step:10,minValue:0,maxValue:u,value:l,onDrag:function(){function v(g,C){return i("custom_pressure",{pressure:C})}return v}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",textAlign:"center",disabled:l===u,width:2.2,onClick:function(){function v(){return i("max_pressure")}return v}()})]}),(0,e.createComponentVNode)(2,b,{node_name:"Node 1",node_ref:s}),(0,e.createComponentVNode)(2,b,{node_name:"Node 2",node_ref:d})]})})})})}return y}(),b=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=S.node_name,l=S.node_ref;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:m,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",textAlign:"center",width:2.2,disabled:l===0,onClick:function(){function u(){return i("set_node",{node_name:m,concentration:(l-10)/100})}return u}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"%",width:6.1,lineHeight:1.5,stepPixelSize:10,minValue:0,maxValue:100,value:l,onChange:function(){function u(s,d){return i("set_node",{node_name:m,concentration:d/100})}return u}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",textAlign:"center",width:2.2,disabled:l===100,onClick:function(){function u(){return i("set_node",{node_name:m,concentration:(l+10)/100})}return u}()})]})}},11748:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosPump=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AtmosPump=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.on,m=i.rate,l=i.max_rate,u=i.gas_unit,s=i.step;return(0,e.createComponentVNode)(2,o.Window,{width:330,height:110,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:c?"On":"Off",color:c?null:"red",selected:c,onClick:function(){function d(){return h("power")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",textAlign:"center",disabled:m===0,width:2.2,onClick:function(){function d(){return h("min_rate")}return d}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:u,width:6.1,lineHeight:1.5,step:s,minValue:0,maxValue:l,value:m,onDrag:function(){function d(v,g){return h("custom_rate",{rate:g})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",textAlign:"center",disabled:m===l,width:2.2,onClick:function(){function d(){return h("max_rate")}return d}()})]})]})})})})}return b}()},69321:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosTankControl=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(44879),p=n(76910),b=n(98595),y=r.AtmosTankControl=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.sensors||{};return(0,e.createComponentVNode)(2,b.Window,{width:400,height:400,children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:[Object.keys(l).map(function(u){return(0,e.createComponentVNode)(2,t.Section,{title:u,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[Object.keys(l[u]).indexOf("pressure")>-1?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Pressure",children:[l[u].pressure," kpa"]}):"",Object.keys(l[u]).indexOf("temperature")>-1?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",children:[l[u].temperature," K"]}):"",["o2","n2","plasma","co2","n2o"].map(function(s){return Object.keys(l[u]).indexOf(s)>-1?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:(0,p.getGasLabel)(s),children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:(0,p.getGasColor)(s),value:l[u][s],minValue:0,maxValue:100,children:(0,o.toFixed)(l[u][s],2)+"%"})},(0,p.getGasLabel)(s)):""})]})},u)}),m.inlet&&Object.keys(m.inlet).length>0?(0,e.createComponentVNode)(2,t.Section,{title:"Inlet Control",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:(m.inlet.on,"power-off"),content:m.inlet.on?"On":"Off",color:m.inlet.on?null:"red",selected:m.inlet.on,onClick:function(){function u(){return c("toggle_active",{dev:"inlet"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"L/s",width:6.1,lineHeight:1.5,step:1,minValue:0,maxValue:50,value:m.inlet.rate,onDrag:function(){function u(s,d){return c("set_pressure",{dev:"inlet",val:d})}return u}()})})]})}):"",m.outlet&&Object.keys(m.outlet).length>0?(0,e.createComponentVNode)(2,t.Section,{title:"Outlet Control",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:(m.outlet.on,"power-off"),content:m.outlet.on?"On":"Off",color:m.outlet.on?null:"red",selected:m.outlet.on,onClick:function(){function u(){return c("toggle_active",{dev:"outlet"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"kPa",width:6.1,lineHeight:1.5,step:10,minValue:0,maxValue:5066,value:m.outlet.rate,onDrag:function(){function u(s,d){return c("set_pressure",{dev:"outlet",val:d})}return u}()})})]})}):""]})})}return S}()},92444:function(T,r,n){"use strict";r.__esModule=!0,r.AugmentMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(25328),b=r.AugmentMenu=function(){function k(h,i){return(0,e.createComponentVNode)(2,o.Window,{width:700,height:660,theme:"malfunction",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:(0,e.createComponentVNode)(2,y,{context:i})})})})}return k}(),y=function(h){var i=h.context,c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.usable_swarms,s=l.ability_tabs,d=l.known_abilities,v=(0,a.useLocalState)(i,"selectedTab",s[0]),g=v[0],C=v[1],f=(0,a.useLocalState)(i,"searchText",""),N=f[0],V=f[1],B=function(){var E=s.find(function(D){return D.category_name===g.category_name});if(!E)return[];var P=Math.min(E.category_stage,4);return E.abilities.filter(function(D){return D.stage<=P&&(!N||D.name.toLowerCase().includes(N.toLowerCase()))}).sort(function(D,M){return["intruder","destroyer"].includes(g.category_name.toLowerCase())?D.stage-M.stage:0})},I=B(),L=s.find(function(x){return x.category_name===g.category_name}),w=["intruder","destroyer"].includes(g.category_name.toLowerCase()),A=function(E){var P=d.find(function(O){return O.ability_path===E.ability_path}),D=P?P.cost:E.cost,M=P&&P.current_level>0?P.current_level+" / "+P.max_level:"0 / "+E.max_level;return(0,e.createComponentVNode)(2,t.Stack.Item,{direction:"row",children:[(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Button,{height:"20px",width:"35px",mb:1,textAlign:"center",content:D,disabled:D>u||P&&P.current_level===P.max_level,tooltip:"Purchase this ability?",onClick:function(){function O(){m("purchase",{ability_path:E.ability_path}),C(g)}return O}()}),(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"16px",children:E.name})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"13px",children:E.desc||"Description not available"}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:["Level: ",(0,e.createVNode)(1,"span",null,M,0,{style:{color:"green"}}),w&&E.stage>0&&(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)(" (Stage: "),E.stage,(0,e.createTextVNode)(")")],0)]}),(0,e.createComponentVNode)(2,t.Stack.Divider)]})})]},E.name)};return(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createVNode)(1,"div",null,[(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,style:{marginRight:"10px"},children:[(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("Swarms: "),(0,e.createVNode)(1,"span",null,u,0,{style:{color:"green"}})],4),w&&L&&(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("Category Stage: "),(0,e.createVNode)(1,"span",null,Math.min(L.category_stage,4),0,{style:{color:"green"}})],4)]}),(0,e.createVNode)(1,"div","Section__buttons",(0,e.createComponentVNode)(2,t.Input,{width:"200px",placeholder:"Search Abilities",onInput:function(){function x(E,P){return V(P)}return x}(),value:N}),2)],4,{style:{display:"flex",alignItems:"center"}}),children:[(0,e.createComponentVNode)(2,t.Tabs,{children:[s.map(function(x){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g.category_name===x.category_name,onClick:function(){function E(){C(x),V("")}return E}(),children:(0,p.capitalize)(x.category_name)},x.category_name)}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g.category_name==="upgrades",onClick:function(){function x(){return C({category_name:"upgrades"})}return x}(),children:"Upgrades"},"upgrades")]}),g.category_name==="upgrades"?(0,e.createComponentVNode)(2,S,{act:m,abilityTabs:s,knownAbilities:d,usableSwarms:u}):(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:I.map(A)})]})},S=function(h){var i=h.act,c=h.abilityTabs,m=h.knownAbilities,l=h.usableSwarms,u=m.filter(function(d){return d.current_levell,tooltip:"Upgrade this ability?",onClick:function(){function C(){return i("purchase",{ability_path:v.ability_path})}return C}()}),(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"16px",children:v.name})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"13px",children:v.upgrade_text}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:["Level:"," ",(0,e.createVNode)(1,"span",null,v.current_level+" / "+v.max_level,0,{style:{color:"green"}}),g&&g.stage>0&&(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)(" (Stage: "),g.stage,(0,e.createTextVNode)(")")],0)]}),(0,e.createComponentVNode)(2,t.Stack.Divider)]})})]},v.name)};return(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:u.map(s)})}},59179:function(T,r,n){"use strict";r.__esModule=!0,r.Autolathe=void 0;var e=n(89005),a=n(64795),t=n(88510),o=n(72253),p=n(36036),b=n(98595),y=n(25328),S=function(i,c,m,l){return i.requirements===null?!0:!(i.requirements.metal*l>c||i.requirements.glass*l>m)},k=r.Autolathe=function(){function h(i,c){var m=(0,o.useBackend)(c),l=m.act,u=m.data,s=u.total_amount,d=u.max_amount,v=u.metal_amount,g=u.glass_amount,C=u.busyname,f=u.busyamt,N=u.showhacked,V=u.buildQueue,B=u.buildQueueLen,I=u.recipes,L=u.categories,w=(0,o.useSharedState)(c,"category",0),A=w[0],x=w[1];A===0&&(A="Tools");var E=v.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,"),P=g.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,"),D=s.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,"),M=(0,o.useSharedState)(c,"search_text",""),O=M[0],R=M[1],F=(0,y.createSearch)(O,function($){return $.name}),W="";B>0&&(W=V.map(function($,G){return(0,e.createComponentVNode)(2,p.Box,{children:(0,e.createComponentVNode)(2,p.Button,{fluid:!0,icon:"times",color:"transparent",content:V[G][0],onClick:function(){function X(){return l("remove_from_queue",{remove_from_queue:V.indexOf($)+1})}return X}()},$)},G)}));var U=(0,a.flow)([(0,t.filter)(function($){return($.category.indexOf(A)>-1||O)&&(u.showhacked||!$.hacked)}),O&&(0,t.filter)(F),(0,t.sortBy)(function($){return $.name.toLowerCase()})])(I),z="Build";return O?z="Results for: '"+O+"':":A&&(z="Build ("+A+")"),(0,e.createComponentVNode)(2,b.Window,{width:750,height:525,children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,horizontal:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{width:"70%",children:(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,title:z,buttons:(0,e.createComponentVNode)(2,p.Dropdown,{width:"150px",options:L,selected:A,onSelected:function(){function $(G){return x(G)}return $}()}),children:[(0,e.createComponentVNode)(2,p.Input,{fluid:!0,placeholder:"Search for...",onInput:function(){function $(G,X){return R(X)}return $}(),mb:1}),U.map(function($){return(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:[(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+$.image,style:{"vertical-align":"middle",width:"32px",margin:"0px","margin-left":"0px"}}),(0,e.createComponentVNode)(2,p.Button,{mr:1,icon:"hammer",selected:u.busyname===$.name&&u.busyamt===1,disabled:!S($,u.metal_amount,u.glass_amount,1),onClick:function(){function G(){return l("make",{make:$.uid,multiplier:1})}return G}(),children:(0,y.toTitleCase)($.name)}),$.max_multiplier>=10&&(0,e.createComponentVNode)(2,p.Button,{mr:1,icon:"hammer",selected:u.busyname===$.name&&u.busyamt===10,disabled:!S($,u.metal_amount,u.glass_amount,10),onClick:function(){function G(){return l("make",{make:$.uid,multiplier:10})}return G}(),children:"10x"}),$.max_multiplier>=25&&(0,e.createComponentVNode)(2,p.Button,{mr:1,icon:"hammer",selected:u.busyname===$.name&&u.busyamt===25,disabled:!S($,u.metal_amount,u.glass_amount,25),onClick:function(){function G(){return l("make",{make:$.uid,multiplier:25})}return G}(),children:"25x"}),$.max_multiplier>25&&(0,e.createComponentVNode)(2,p.Button,{mr:1,icon:"hammer",selected:u.busyname===$.name&&u.busyamt===$.max_multiplier,disabled:!S($,u.metal_amount,u.glass_amount,$.max_multiplier),onClick:function(){function G(){return l("make",{make:$.uid,multiplier:$.max_multiplier})}return G}(),children:[$.max_multiplier,"x"]}),$.requirements&&Object.keys($.requirements).map(function(G){return(0,y.toTitleCase)(G)+": "+$.requirements[G]}).join(", ")||(0,e.createComponentVNode)(2,p.Box,{children:"No resources required."})]},$.ref)})]})}),(0,e.createComponentVNode)(2,p.Stack.Item,{width:"30%",children:[(0,e.createComponentVNode)(2,p.Section,{title:"Materials",children:(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Metal",children:E}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Glass",children:P}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Total",children:D}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Storage",children:[u.fill_percent,"% Full"]})]})}),(0,e.createComponentVNode)(2,p.Section,{title:"Building",children:(0,e.createComponentVNode)(2,p.Box,{color:C?"green":"",children:C||"Nothing"})}),(0,e.createComponentVNode)(2,p.Section,{title:"Build Queue",height:23.7,children:[W,(0,e.createComponentVNode)(2,p.Button,{mt:.5,fluid:!0,icon:"times",content:"Clear All",color:"red",disabled:!u.buildQueueLen,onClick:function(){function $(){return l("clear_queue")}return $}()})]})]})]})})})}return h}()},5147:function(T,r,n){"use strict";r.__esModule=!0,r.BioChipPad=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.BioChipPad=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.implant,m=i.contains_case,l=i.gps,u=i.tag,s=(0,a.useLocalState)(S,"newTag",u),d=s[0],v=s[1];return(0,e.createComponentVNode)(2,o.Window,{width:410,height:325,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Bio-chip Mini-Computer",buttons:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Eject Case",icon:"eject",disabled:!m,onClick:function(){function g(){return h("eject_case")}return g}()})}),children:c&&m?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{bold:!0,mb:2,children:[(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+c.image,ml:0,mr:2,style:{"vertical-align":"middle",width:"32px"}}),c.name]}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Life",children:c.life}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Notes",children:c.notes}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Function",children:c.function}),!!l&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tag",children:[(0,e.createComponentVNode)(2,t.Input,{width:"5.5rem",value:u,onEnter:function(){function g(){return h("tag",{newtag:d})}return g}(),onInput:function(){function g(C,f){return v(f)}return g}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:u===d,width:"20px",mb:"0",ml:"0.25rem",onClick:function(){function g(){return h("tag",{newtag:d})}return g}(),children:(0,e.createComponentVNode)(2,t.Icon,{name:"pen"})})]})]})],4):m?(0,e.createComponentVNode)(2,t.Box,{children:"This bio-chip case has no implant!"}):(0,e.createComponentVNode)(2,t.Box,{children:"Please insert a bio-chip casing!"})})})})}return b}()},64273:function(T,r,n){"use strict";r.__esModule=!0,r.Biogenerator=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(62411),b=r.Biogenerator=function(){function i(c,m){var l=(0,a.useBackend)(m),u=l.data,s=l.config,d=u.container,v=u.processing,g=s.title;return(0,e.createComponentVNode)(2,o.Window,{width:390,height:595,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Operating,{operating:v,name:g}),(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k),d?(0,e.createComponentVNode)(2,h):(0,e.createComponentVNode)(2,y)]})})})}return i}(),y=function(c,m){return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"silver",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"flask",size:5,mb:"10px"}),(0,e.createVNode)(1,"br"),"The biogenerator is missing a container."]})})})},S=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.biomass,v=s.container,g=s.container_curr_reagents,C=s.container_max_reagents;return(0,e.createComponentVNode)(2,t.Section,{title:"Storage",children:[(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{mr:"20px",color:"silver",children:"Biomass:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{mr:"5px",children:d}),(0,e.createComponentVNode)(2,t.Icon,{name:"leaf",size:1.2,color:"#3d8c40"})]}),(0,e.createComponentVNode)(2,t.Stack,{height:"21px",mt:"8px",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{mr:"10px",color:"silver",children:"Container:"}),v?(0,e.createComponentVNode)(2,t.ProgressBar,{value:g,maxValue:C,children:(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",children:g+" / "+C+" units"})}):(0,e.createComponentVNode)(2,t.Stack.Item,{children:"None"})]})]})},k=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.has_plants,v=s.container;return(0,e.createComponentVNode)(2,t.Section,{title:"Controls",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"power-off",disabled:!d,tooltip:d?"":"There are no plants in the biogenerator.",tooltipPosition:"top-start",content:"Activate",onClick:function(){function g(){return u("activate")}return g}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"40%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"flask",disabled:!v,tooltip:v?"":"The biogenerator does not have a container.",tooltipPosition:"top",content:"Detach Container",onClick:function(){function g(){return u("detach_container")}return g}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"eject",disabled:!d,tooltip:d?"":"There are no stored plants to eject.",tooltipPosition:"top-end",content:"Eject Plants",onClick:function(){function g(){return u("eject_plants")}return g}()})})]})})},h=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.biomass,v=s.product_list,g=(0,a.useSharedState)(m,"vendAmount",1),C=g[0],f=g[1],N=Object.entries(v).map(function(V,B){var I=Object.entries(V[1]).map(function(L){return L[1]});return(0,e.createComponentVNode)(2,t.Collapsible,{title:V[0],open:!0,children:I.map(function(L){return(0,e.createComponentVNode)(2,t.Stack,{py:"2px",className:"candystripe",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"50%",ml:"2px",children:L.name}),(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"right",width:"20%",children:[L.cost*C,(0,e.createComponentVNode)(2,t.Icon,{ml:"5px",name:"leaf",size:1.2,color:"#3d8c40"})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"right",width:"40%",children:(0,e.createComponentVNode)(2,t.Button,{content:"Vend",disabled:d.25?750+400*Math.random():290+150*Math.random(),time:60+150*Math.random(),children:(0,e.createComponentVNode)(2,t.Stack,{mb:"30px",fontsize:"256px",children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,color:"red",fontsize:"256px",textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"skull",size:14,mb:"64px"}),(0,e.createVNode)(1,"br"),"E$#OR:& U#KN!WN IN%ERF#R_NCE"]})})})})}return k}(),y=r.BluespaceTap=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.product||[],s=l.desiredMiningPower,d=l.miningPower,v=l.points,g=l.totalPoints,C=l.powerUse,f=l.availablePower,N=l.emagged,V=l.autoShutown,B=l.stabilizers,I=l.stabilizerPower,L=l.stabilizerPriority,w=s>d&&"bad"||"good";return(0,e.createComponentVNode)(2,o.Window,{width:650,height:450,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,t.Collapsible,{title:"Input Management",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Input",children:[(0,e.createComponentVNode)(2,t.Button,{icon:V&&!N?"toggle-on":"toggle-off",content:"Auto shutdown",color:V&&!N?"green":"red",disabled:!!N,tooltip:"Turn auto shutdown on or off",tooltipPosition:"top",onClick:function(){function A(){return m("auto_shutdown")}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:B&&!N?"toggle-on":"toggle-off",content:"Stabilizers",color:B&&!N?"green":"red",disabled:!!N,tooltip:"Turn stabilizers on or off",tooltipPosition:"top",onClick:function(){function A(){return m("stabilizers")}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:L&&!N?"toggle-on":"toggle-off",content:"Stabilizer priority",color:L&&!N?"green":"red",disabled:!!N,tooltip:"On: Mining power will not exceed what can be stabilized",tooltipPosition:"top",onClick:function(){function A(){return m("stabilizer_priority")}return A}()}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Desired Mining Power",children:(0,p.formatPower)(s)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{labelStyle:{"vertical-align":"top"},label:"Set Desired Mining Power",children:(0,e.createComponentVNode)(2,t.Stack,{width:"100%",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"step-backward",disabled:s===0||N,tooltip:"Set to 0",tooltipPosition:"bottom",onClick:function(){function A(){return m("set",{set_power:0})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",tooltip:"Decrease by 10 MW",tooltipPosition:"bottom",disabled:s===0||N,onClick:function(){function A(){return m("set",{set_power:s-1e7})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"backward",disabled:s===0||N,tooltip:"Decrease by 1 MW",tooltipPosition:"bottom",onClick:function(){function A(){return m("set",{set_power:s-1e6})}return A}()})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{mx:1,children:(0,e.createComponentVNode)(2,t.NumberInput,{disabled:N,minvalue:0,value:s,maxvalue:1/0,step:1,onChange:function(){function A(x,E){return m("set",{set_power:E})}return A}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"forward",disabled:N,tooltip:"Increase by one MW",tooltipPosition:"bottom",onClick:function(){function A(){return m("set",{set_power:s+1e6})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",disabled:N,tooltip:"Increase by 10MW",tooltipPosition:"bottom",onClick:function(){function A(){return m("set",{set_power:s+1e7})}return A}()})]})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Total Power Use",children:(0,p.formatPower)(C)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mining Power Use",children:(0,p.formatPower)(d)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Stabilizer Power Use",children:(0,p.formatPower)(I)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Surplus Power",children:(0,p.formatPower)(f)})]})]})}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Output",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Available Points",children:v}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Total Points",children:g})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{align:"end",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:u.map(function(A){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:A.name,children:(0,e.createComponentVNode)(2,t.Button,{disabled:A.price>=v,onClick:function(){function x(){return m("vend",{target:A.key})}return x}(),content:A.price})},A.key)})})})})]})})]})})})}return k}(),S=r.Alerts=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.product||[],s=l.miningPower,d=l.stabilizerPower,v=l.emagged,g=l.safeLevels,C=l.autoShutown,f=l.stabilizers,N=l.overhead;return(0,e.createFragment)([!C&&!v&&(0,e.createComponentVNode)(2,t.NoticeBox,{danger:1,children:"Auto shutdown disabled"}),v?(0,e.createComponentVNode)(2,t.NoticeBox,{danger:1,children:"All safeties disabled"}):s<=15e6?"":f?s>d+15e6?(0,e.createComponentVNode)(2,t.NoticeBox,{danger:1,children:"Stabilizers overwhelmed, Instability likely"}):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"High Power, engaging stabilizers"}):(0,e.createComponentVNode)(2,t.NoticeBox,{danger:1,children:"Stabilizers disabled, Instability likely"})],0)}return k}()},33758:function(T,r,n){"use strict";r.__esModule=!0,r.BodyScanner=void 0;var e=n(89005),a=n(44879),t=n(25328),o=n(72253),p=n(36036),b=n(98595),y=[["good","Alive"],["average","Critical"],["bad","DEAD"]],S=[["hasVirus","bad","Viral pathogen detected in blood stream."],["blind","average","Cataracts detected."],["colourblind","average","Photoreceptor abnormalities detected."],["nearsighted","average","Retinal misalignment detected."]],k=[["Respiratory","oxyLoss"],["Brain","brainLoss"],["Toxin","toxLoss"],["Radiation","radLoss"],["Brute","bruteLoss"],["Cellular","cloneLoss"],["Burn","fireLoss"],["Inebriation","drunkenness"]],h={average:[.25,.5],bad:[.5,1/0]},i=function(B,I){for(var L=[],w=0;w0?B.filter(function(I){return!!I}).reduce(function(I,L){return(0,e.createFragment)([I,(0,e.createComponentVNode)(2,p.Box,{children:L},L)],0)},null):null},m=function(B){if(B>100){if(B<300)return"mild infection";if(B<400)return"mild infection+";if(B<500)return"mild infection++";if(B<700)return"acute infection";if(B<800)return"acute infection+";if(B<900)return"acute infection++";if(B>=900)return"septic"}return""},l=r.BodyScanner=function(){function V(B,I){var L=(0,o.useBackend)(I),w=L.data,A=w.occupied,x=w.occupant,E=x===void 0?{}:x,P=A?(0,e.createComponentVNode)(2,u,{occupant:E}):(0,e.createComponentVNode)(2,N);return(0,e.createComponentVNode)(2,b.Window,{width:700,height:600,title:"Body Scanner",children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:P})})}return V}(),u=function(B){var I=B.occupant;return(0,e.createComponentVNode)(2,p.Box,{children:[(0,e.createComponentVNode)(2,s,{occupant:I}),(0,e.createComponentVNode)(2,d,{occupant:I}),(0,e.createComponentVNode)(2,v,{occupant:I}),(0,e.createComponentVNode)(2,C,{organs:I.extOrgan}),(0,e.createComponentVNode)(2,f,{organs:I.intOrgan})]})},s=function(B,I){var L=(0,o.useBackend)(I),w=L.act,A=L.data,x=A.occupant;return(0,e.createComponentVNode)(2,p.Section,{title:"Occupant",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Button,{icon:"print",onClick:function(){function E(){return w("print_p")}return E}(),children:"Print Report"}),(0,e.createComponentVNode)(2,p.Button,{icon:"user-slash",onClick:function(){function E(){return w("ejectify")}return E}(),children:"Eject"})],4),children:(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Name",children:x.name}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:x.maxHealth,value:x.health/x.maxHealth,ranges:{good:[.5,1/0],average:[0,.5],bad:[-1/0,0]}})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Status",color:y[x.stat][0],children:y[x.stat][1]}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Temperature",children:[(0,e.createComponentVNode)(2,p.AnimatedNumber,{value:(0,a.round)(x.bodyTempC)}),"\xB0C,\xA0",(0,e.createComponentVNode)(2,p.AnimatedNumber,{value:(0,a.round)(x.bodyTempF)}),"\xB0F"]}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Implants",children:x.implant_len?(0,e.createComponentVNode)(2,p.Box,{children:x.implant.map(function(E){return E.name}).join(", ")}):(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"None"})})]})})},d=function(B){var I=B.occupant;return I.hasBorer||I.blind||I.colourblind||I.nearsighted||I.hasVirus?(0,e.createComponentVNode)(2,p.Section,{title:"Abnormalities",children:S.map(function(L,w){if(I[L[0]])return(0,e.createComponentVNode)(2,p.Box,{color:L[1],bold:L[1]==="bad",children:L[2]},L[2])})}):(0,e.createComponentVNode)(2,p.Section,{title:"Abnormalities",children:(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"No abnormalities found."})})},v=function(B){var I=B.occupant;return(0,e.createComponentVNode)(2,p.Section,{title:"Damage",children:(0,e.createComponentVNode)(2,p.Table,{children:i(k,function(L,w,A){return(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Table.Row,{color:"label",children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:[L[0],":"]}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:!!w&&w[0]+":"})]}),(0,e.createComponentVNode)(2,p.Table.Row,{children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:(0,e.createComponentVNode)(2,g,{value:I[L[1]],marginBottom:A100)&&"average"||!!I.status.robotic&&"label",width:"33%",children:(0,t.capitalize)(I.name)}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,p.ProgressBar,{m:-.5,min:"0",max:I.maxHealth,mt:L>0&&"0.5rem",value:I.totalLoss/I.maxHealth,ranges:h,children:(0,e.createComponentVNode)(2,p.Stack,{children:[(0,e.createComponentVNode)(2,p.Tooltip,{content:"Total damage",children:(0,e.createComponentVNode)(2,p.Stack.Item,{children:[(0,e.createComponentVNode)(2,p.Icon,{name:"heartbeat",mr:.5}),(0,a.round)(I.totalLoss)]})}),!!I.bruteLoss&&(0,e.createComponentVNode)(2,p.Tooltip,{content:"Brute damage",children:(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:[(0,e.createComponentVNode)(2,p.Icon,{name:"bone",mr:.5}),(0,a.round)(I.bruteLoss)]})}),!!I.fireLoss&&(0,e.createComponentVNode)(2,p.Tooltip,{content:"Burn damage",children:(0,e.createComponentVNode)(2,p.Stack.Item,{children:[(0,e.createComponentVNode)(2,p.Icon,{name:"fire",mr:.5}),(0,a.round)(I.fireLoss)]})})]})})}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"right",verticalAlign:"top",width:"33%",pt:L>0&&"calc(0.5rem + 2px)",children:[(0,e.createComponentVNode)(2,p.Box,{color:"average",inline:!0,children:c([!!I.internalBleeding&&"Internal bleeding",!!I.burnWound&&"Critical tissue burns",!!I.lungRuptured&&"Ruptured lung",!!I.status.broken&&I.status.broken,m(I.germ_level),!!I.open&&"Open incision"])}),(0,e.createComponentVNode)(2,p.Box,{inline:!0,children:[c([!!I.status.splinted&&(0,e.createComponentVNode)(2,p.Box,{color:"good",children:"Splinted"}),!!I.status.robotic&&(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"Robotic"}),!!I.status.dead&&(0,e.createComponentVNode)(2,p.Box,{color:"bad",bold:!0,children:"DEAD"})]),c(I.shrapnel.map(function(w){return w.known?w.name:"Unknown object"}))]})]})]},L)})]})})},f=function(B){return B.organs.length===0?(0,e.createComponentVNode)(2,p.Section,{title:"Internal Organs",children:(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"N/A"})}):(0,e.createComponentVNode)(2,p.Section,{title:"Internal Organs",children:(0,e.createComponentVNode)(2,p.Table,{children:[(0,e.createComponentVNode)(2,p.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"center",children:"Damage"}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"right",children:"Injuries"})]}),B.organs.map(function(I,L){return(0,e.createComponentVNode)(2,p.Table.Row,{children:[(0,e.createComponentVNode)(2,p.Table.Cell,{color:!!I.dead&&"bad"||I.germ_level>100&&"average"||I.robotic>0&&"label",width:"33%",children:(0,t.capitalize)(I.name)}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:I.maxHealth,value:I.damage/I.maxHealth,mt:L>0&&"0.5rem",ranges:h,children:(0,a.round)(I.damage)})}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"right",verticalAlign:"top",width:"33%",pt:L>0&&"calc(0.5rem + 2px)",children:[(0,e.createComponentVNode)(2,p.Box,{color:"average",inline:!0,children:c([m(I.germ_level)])}),(0,e.createComponentVNode)(2,p.Box,{inline:!0,children:c([I.robotic===1&&(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"Robotic"}),I.robotic===2&&(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"Assisted"}),!!I.dead&&(0,e.createComponentVNode)(2,p.Box,{color:"bad",bold:!0,children:"DEAD"})])})]})]},L)})]})})},N=function(){return(0,e.createComponentVNode)(2,p.Section,{fill:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,p.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No occupant detected."]})})})}},67963:function(T,r,n){"use strict";r.__esModule=!0,r.BookBinder=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=n(39473),y=r.BookBinder=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.selectedbook,u=m.book_categories,s=[];return u.map(function(d){return s[d.description]=d.category_id}),(0,e.createComponentVNode)(2,o.Window,{width:600,height:400,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Book Binder",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"print",width:"auto",content:"Print Book",onClick:function(){function d(){return c("print_book")}return d}()}),children:[(0,e.createComponentVNode)(2,t.Box,{ml:10,fontSize:"1.2rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"search-plus",verticalAlign:"middle",size:3,mr:"1rem"}),"Book Binder"]}),(0,e.createComponentVNode)(2,t.Stack,{children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,t.Button,{textAlign:"left",icon:"pen",width:"auto",content:l.title,onClick:function(){function d(){return(0,p.modalOpen)(h,"edit_selected_title")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:(0,e.createComponentVNode)(2,t.Button,{textAlign:"left",icon:"pen",width:"auto",content:l.author,onClick:function(){function d(){return(0,p.modalOpen)(h,"edit_selected_author")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Categories",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Dropdown,{width:"190px",options:u.map(function(d){return d.description}),onSelected:function(){function d(v){return c("toggle_binder_category",{category_id:s[v]})}return d}()})})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Summary",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pen",width:"auto",content:"Edit Summary",onClick:function(){function d(){return(0,p.modalOpen)(h,"edit_selected_summary")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:l.summary})]}),(0,e.createVNode)(1,"br"),u.filter(function(d){return l.categories.includes(d.category_id)}).map(function(d){return(0,e.createComponentVNode)(2,t.Button,{content:d.description,selected:!0,icon:"unlink",onClick:function(){function v(){return c("toggle_binder_category",{category_id:d.category_id})}return v}()},d.category_id)})]})})]})})})]})}return S}()},61925:function(T,r,n){"use strict";r.__esModule=!0,r.BotCall=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(i){var c=[{modes:[0],label:"Idle",color:"green"},{modes:[1,2,3],label:"Arresting",color:"yellow"},{modes:[4,5],label:"Patrolling",color:"average"},{modes:[9],label:"Moving",color:"average"},{modes:[6,11],label:"Responding",color:"green"},{modes:[12],label:"Delivering Cargo",color:"blue"},{modes:[13],label:"Returning Home",color:"blue"},{modes:[7,8,10,14,15,16,17,18,19],label:"Working",color:"blue"}],m=c.find(function(l){return l.modes.includes(i)});return(0,e.createComponentVNode)(2,t.Box,{color:m.color,children:[" ",m.label," "]})},b=r.BotCall=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=(0,a.useLocalState)(c,"tabIndex",0),d=s[0],v=s[1],g={0:"Security",1:"Medibot",2:"Cleanbot",3:"Floorbot",4:"Mule",5:"Honkbot"},C=function(){function f(N){return g[N]?(0,e.createComponentVNode)(2,y,{model:g[N]}):"This should not happen. Report on Paradise Github"}return f}();return(0,e.createComponentVNode)(2,o.Window,{width:700,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:d===0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Tabs,{fluid:!0,textAlign:"center",children:Array.from({length:6}).map(function(f,N){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:d===N,onClick:function(){function V(){return v(N)}return V}(),children:g[N]},N)})})}),C(d)]})})})}return h}(),y=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.bots;return s[i.model]!==void 0?(0,e.createComponentVNode)(2,k,{model:[i.model]}):(0,e.createComponentVNode)(2,S,{model:[i.model]})},S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data;return(0,e.createComponentVNode)(2,t.Stack,{justify:"center",align:"center",fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Box,{bold:1,color:"bad",children:["No ",[i.model]," detected"]})})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.bots;return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Model"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Location"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Interface"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Call"})]}),s[i.model].map(function(d){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.model}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.on?p(d.status):(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Off"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.location}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Interface",onClick:function(){function v(){return l("interface",{botref:d.UID})}return v}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Call",onClick:function(){function v(){return l("call",{botref:d.UID})}return v}()})})]},d.UID)})]})})})}},20464:function(T,r,n){"use strict";r.__esModule=!0,r.BotClean=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotClean=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.locked,l=c.noaccess,u=c.maintpanel,s=c.on,d=c.autopatrol,v=c.canhack,g=c.emagged,C=c.remote_disabled,f=c.painame,N=c.cleanblood,V=c.area;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,p.BotStatus),(0,e.createComponentVNode)(2,t.Section,{title:"Cleaning Settings",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:N,content:"Clean Blood",disabled:l,onClick:function(){function B(){return i("blood")}return B}()})}),(0,e.createComponentVNode)(2,t.Section,{title:"Misc Settings",children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:V?"Reset Area Selection":"Restrict to Current Area",onClick:function(){function B(){return i("area")}return B}()}),V!==null&&(0,e.createComponentVNode)(2,t.LabeledList,{mb:1,children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Locked Area",children:V})})]}),f&&(0,e.createComponentVNode)(2,t.Section,{title:"pAI",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"eject",content:f,disabled:l,onClick:function(){function B(){return i("ejectpai")}return B}()})})]})})}return y}()},69479:function(T,r,n){"use strict";r.__esModule=!0,r.BotFloor=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotFloor=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.noaccess,l=c.painame,u=c.hullplating,s=c.replace,d=c.eat,v=c.make,g=c.fixfloor,C=c.nag_empty,f=c.magnet,N=c.tiles_amount;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:510,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,p.BotStatus),(0,e.createComponentVNode)(2,t.Section,{title:"Floor Settings",children:[(0,e.createComponentVNode)(2,t.Box,{mb:"5px",children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tiles Left",children:N})}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:u,content:"Add tiles to new hull plating",tooltip:"Fixing a plating requires the removal of floor tile. This will place it back after repairing. Same goes for hull breaches",disabled:m,onClick:function(){function V(){return i("autotile")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:s,content:"Add floor tiles on exposed hull plating",tooltip:"Example: It will add tiles to maintenance",disabled:m,onClick:function(){function V(){return i("replacetiles")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:g,content:"Repair damaged tiles and platings",disabled:m,onClick:function(){function V(){return i("fixfloors")}return V}()})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Miscellaneous",children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:d,content:"Finds tiles",disabled:m,onClick:function(){function V(){return i("eattiles")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:v,content:"Make pieces of metal into tiles when empty",disabled:m,onClick:function(){function V(){return i("maketiles")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:C,content:"Transmit notice when empty",disabled:m,onClick:function(){function V(){return i("nagonempty")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:f,content:"Traction Magnets",disabled:m,onClick:function(){function V(){return i("anchored")}return V}()})]}),l&&(0,e.createComponentVNode)(2,t.Section,{title:"pAI",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,icon:"eject",content:l,disabled:m,onClick:function(){function V(){return i("ejectpai")}return V}()})})]})})}return y}()},59887:function(T,r,n){"use strict";r.__esModule=!0,r.BotHonk=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotHonk=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:220,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,p.BotStatus)})})}return y}()},80063:function(T,r,n){"use strict";r.__esModule=!0,r.BotMed=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotMed=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.locked,l=c.noaccess,u=c.maintpanel,s=c.on,d=c.autopatrol,v=c.canhack,g=c.emagged,C=c.remote_disabled,f=c.painame,N=c.shut_up,V=c.declare_crit,B=c.stationary_mode,I=c.heal_threshold,L=c.injection_amount,w=c.use_beaker,A=c.treat_virus,x=c.reagent_glass;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.BotStatus),(0,e.createComponentVNode)(2,t.Section,{title:"Communication Settings",children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,content:"Speaker",checked:!N,disabled:l,onClick:function(){function E(){return i("toggle_speaker")}return E}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,content:"Critical Patient Alerts",checked:V,disabled:l,onClick:function(){function E(){return i("toggle_critical_alerts")}return E}()})]}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Treatment Settings",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Healing Threshold",children:(0,e.createComponentVNode)(2,t.Slider,{value:I.value,minValue:I.min,maxValue:I.max,step:5,disabled:l,onChange:function(){function E(P,D){return i("set_heal_threshold",{target:D})}return E}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Injection Level",children:(0,e.createComponentVNode)(2,t.Slider,{value:L.value,minValue:L.min,maxValue:L.max,step:5,format:function(){function E(P){return P+"u"}return E}(),disabled:l,onChange:function(){function E(P,D){return i("set_injection_amount",{target:D})}return E}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Reagent Source",children:(0,e.createComponentVNode)(2,t.Button,{content:w?"Beaker":"Internal Synthesizer",icon:w?"flask":"cogs",disabled:l,onClick:function(){function E(){return i("toggle_use_beaker")}return E}()})}),x&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Beaker",children:(0,e.createComponentVNode)(2,t.Stack,{inline:!0,width:"100%",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1,children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:x.amount,minValue:0,maxValue:x.max_amount,children:[x.amount," / ",x.max_amount]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{ml:1,children:(0,e.createComponentVNode)(2,t.Button,{content:"Eject",disabled:l,onClick:function(){function E(){return i("eject_reagent_glass")}return E}()})})]})})]}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{mt:1,fluid:!0,content:"Treat Viral Infections",checked:A,disabled:l,onClick:function(){function E(){return i("toggle_treat_viral")}return E}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,content:"Stationary Mode",checked:B,disabled:l,onClick:function(){function E(){return i("toggle_stationary_mode")}return E}()})]}),f&&(0,e.createComponentVNode)(2,t.Section,{title:"pAI",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"eject",content:f,disabled:l,onClick:function(){function E(){return i("ejectpai")}return E}()})})]})})})}return y}()},74439:function(T,r,n){"use strict";r.__esModule=!0,r.BotSecurity=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotSecurity=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.noaccess,l=c.painame,u=c.check_id,s=c.check_weapons,d=c.check_warrant,v=c.arrest_mode,g=c.arrest_declare;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:445,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,p.BotStatus),(0,e.createComponentVNode)(2,t.Section,{title:"Who To Arrest",children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:u,content:"Unidentifiable Persons",disabled:m,onClick:function(){function C(){return i("authid")}return C}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:s,content:"Unauthorized Weapons",disabled:m,onClick:function(){function C(){return i("authweapon")}return C}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:d,content:"Wanted Criminals",disabled:m,onClick:function(){function C(){return i("authwarrant")}return C}()})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Arrest Procedure",children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:v,content:"Detain Targets Indefinitely",disabled:m,onClick:function(){function C(){return i("arrtype")}return C}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:g,content:"Announce Arrests On Radio",disabled:m,onClick:function(){function C(){return i("arrdeclare")}return C}()})]}),l&&(0,e.createComponentVNode)(2,t.Section,{title:"pAI",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"eject",content:l,disabled:m,onClick:function(){function C(){return i("ejectpai")}return C}()})})]})})}return y}()},10833:function(T,r,n){"use strict";r.__esModule=!0,r.BrigCells=void 0;var e=n(89005),a=n(98595),t=n(36036),o=n(72253),p=function(k,h){var i=k.cell,c=(0,o.useBackend)(h),m=c.act,l=i.cell_id,u=i.occupant,s=i.crimes,d=i.brigged_by,v=i.time_left_seconds,g=i.time_set_seconds,C=i.ref,f="";v>0&&(f+=" BrigCells__listRow--active");var N=function(){m("release",{ref:C})};return(0,e.createComponentVNode)(2,t.Table.Row,{className:f,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:l}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:s}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.TimeDisplay,{totalSeconds:g})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.TimeDisplay,{totalSeconds:v})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{type:"button",onClick:N,children:"Release"})})]})},b=function(k){var h=k.cells;return(0,e.createComponentVNode)(2,t.Table,{className:"BrigCells__list",children:[(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Cell"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Occupant"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Crimes"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Brigged By"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Time Brigged For"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Time Left"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Release"})]}),h.map(function(i){return(0,e.createComponentVNode)(2,p,{cell:i},i.ref)})]})},y=r.BrigCells=function(){function S(k,h){var i=(0,o.useBackend)(h),c=i.act,m=i.data,l=m.cells;return(0,e.createComponentVNode)(2,a.Window,{theme:"security",width:800,height:400,children:(0,e.createComponentVNode)(2,a.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,b,{cells:l})})})})})}return S}()},45761:function(T,r,n){"use strict";r.__esModule=!0,r.BrigTimer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.BrigTimer=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;i.nameText=i.occupant,i.timing&&(i.prisoner_hasrec?i.nameText=(0,e.createComponentVNode)(2,t.Box,{color:"green",children:i.occupant}):i.nameText=(0,e.createComponentVNode)(2,t.Box,{color:"red",children:i.occupant}));var c="pencil-alt";i.prisoner_name&&(i.prisoner_hasrec||(c="exclamation-triangle"));var m=[],l=0;for(l=0;lm?this.substring(0,m)+"...":this};var k=function(l,u){var s,d;if(!u)return[];var v=l.findIndex(function(g){return g.name===u.name});return[(s=l[v-1])==null?void 0:s.name,(d=l[v+1])==null?void 0:d.name]},h=function(l,u){u===void 0&&(u="");var s=(0,p.createSearch)(u,function(d){return d.name});return(0,t.flow)([(0,a.filter)(function(d){return d==null?void 0:d.name}),u&&(0,a.filter)(s),(0,a.sortBy)(function(d){return d.name})])(l)},i=r.CameraConsole=function(){function m(l,u){var s=(0,b.useBackend)(u),d=s.act,v=s.data,g=s.config,C=v.mapRef,f=v.activeCamera,N=h(v.cameras),V=k(N,f),B=V[0],I=V[1];return(0,e.createComponentVNode)(2,S.Window,{width:870,height:708,children:[(0,e.createVNode)(1,"div","CameraConsole__left",(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,y.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,c)})}),2),(0,e.createVNode)(1,"div","CameraConsole__right",[(0,e.createVNode)(1,"div","CameraConsole__toolbar",[(0,e.createVNode)(1,"b",null,"Camera: ",16),f&&f.name||"\u2014"],0),(0,e.createVNode)(1,"div","CameraConsole__toolbarRight",[(0,e.createComponentVNode)(2,y.Button,{icon:"chevron-left",disabled:!B,onClick:function(){function L(){return d("switch_camera",{name:B})}return L}()}),(0,e.createComponentVNode)(2,y.Button,{icon:"chevron-right",disabled:!I,onClick:function(){function L(){return d("switch_camera",{name:I})}return L}()})],4),(0,e.createComponentVNode)(2,y.ByondUi,{className:"CameraConsole__map",params:{id:C,type:"map"}})],4)]})}return m}(),c=r.CameraConsoleContent=function(){function m(l,u){var s=(0,b.useBackend)(u),d=s.act,v=s.data,g=(0,b.useLocalState)(u,"searchText",""),C=g[0],f=g[1],N=v.activeCamera,V=h(v.cameras,C);return(0,e.createComponentVNode)(2,y.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y.Stack.Item,{children:(0,e.createComponentVNode)(2,y.Input,{fluid:!0,placeholder:"Search for a camera",onInput:function(){function B(I,L){return f(L)}return B}()})}),(0,e.createComponentVNode)(2,y.Stack.Item,{grow:!0,m:0,children:(0,e.createComponentVNode)(2,y.Section,{fill:!0,scrollable:!0,children:V.map(function(B){return(0,e.createVNode)(1,"div",(0,o.classes)(["Button","Button--fluid","Button--color--transparent",N&&B.name===N.name&&"Button--selected"]),B.name.trimLongStr(23),0,{title:B.name,onClick:function(){function I(){return d("switch_camera",{name:B.name})}return I}()},B.name)})})})]})}return m}()},52927:function(T,r,n){"use strict";r.__esModule=!0,r.Canister=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(49968),b=n(98595),y=r.Canister=function(){function S(k,h){var i=(0,t.useBackend)(h),c=i.act,m=i.data,l=m.portConnected,u=m.tankPressure,s=m.releasePressure,d=m.defaultReleasePressure,v=m.minReleasePressure,g=m.maxReleasePressure,C=m.valveOpen,f=m.name,N=m.canLabel,V=m.colorContainer,B=m.color_index,I=m.hasHoldingTank,L=m.holdingTank,w="";B.prim&&(w=V.prim.options[B.prim].name);var A="";B.sec&&(A=V.sec.options[B.sec].name);var x="";B.ter&&(x=V.ter.options[B.ter].name);var E="";B.quart&&(E=V.quart.options[B.quart].name);var P=[],D=[],M=[],O=[],R=0;for(R=0;Rf.current_positions&&(0,e.createComponentVNode)(2,t.Box,{color:"green",children:f.total_positions-f.current_positions})||(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"0"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{content:"-",disabled:d.cooldown_time||!f.can_close,onClick:function(){function N(){return s("make_job_unavailable",{job:f.title})}return N}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{content:"+",disabled:d.cooldown_time||!f.can_open,onClick:function(){function N(){return s("make_job_available",{job:f.title})}return N}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:d.target_dept&&(0,e.createComponentVNode)(2,t.Box,{color:"green",children:d.priority_jobs.indexOf(f.title)>-1?"Yes":""})||(0,e.createComponentVNode)(2,t.Button,{content:f.is_priority?"Yes":"No",selected:f.is_priority,disabled:d.cooldown_time||!f.can_prioritize,onClick:function(){function N(){return s("prioritize_job",{job:f.title})}return N}()})})]},f.title)})]})})]}):C=(0,e.createComponentVNode)(2,S);break;case 2:!d.authenticated||!d.scan_name?C=(0,e.createComponentVNode)(2,S):d.modify_name?C=(0,e.createComponentVNode)(2,p.AccessList,{accesses:d.regions,selectedList:d.selectedAccess,accessMod:function(){function f(N){return s("set",{access:N})}return f}(),grantAll:function(){function f(){return s("grant_all")}return f}(),denyAll:function(){function f(){return s("clear_all")}return f}(),grantDep:function(){function f(N){return s("grant_region",{region:N})}return f}(),denyDep:function(){function f(N){return s("deny_region",{region:N})}return f}()}):C=(0,e.createComponentVNode)(2,k);break;case 3:d.authenticated?d.records.length?C=(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Records",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Delete All Records",disabled:!d.authenticated||d.records.length===0||d.target_dept,onClick:function(){function f(){return s("wipe_all_logs")}return f}()}),children:[(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{height:2,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Crewman"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Old Rank"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"New Rank"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Authorized By"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Time"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Reason"}),!!d.iscentcom&&(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Deleted By"})]}),d.records.map(function(f){return(0,e.createComponentVNode)(2,t.Table.Row,{height:2,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.transferee}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.oldvalue}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.newvalue}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.whodidit}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.timestamp}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.reason}),!!d.iscentcom&&(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.deletedby})]},f.timestamp)})]}),!!d.iscentcom&&(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:"Delete MY Records",color:"purple",disabled:!d.authenticated||d.records.length===0,onClick:function(){function f(){return s("wipe_my_logs")}return f}()})})]}):C=(0,e.createComponentVNode)(2,h):C=(0,e.createComponentVNode)(2,S);break;case 4:!d.authenticated||!d.scan_name?C=(0,e.createComponentVNode)(2,S):C=(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Your Team",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{height:2,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Rank"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Sec Status"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Actions"})]}),d.people_dept.map(function(f){return(0,e.createComponentVNode)(2,t.Table.Row,{height:2,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.title}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.crimstat}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:f.buttontext,disabled:!f.demotable,onClick:function(){function N(){return s("remote_demote",{remote_demote:f.name})}return N}()})})]},f.title)})]})});break;default:C=(0,e.createComponentVNode)(2,t.Section,{title:"Warning",color:"red",children:"ERROR: Unknown Mode."})}return(0,e.createComponentVNode)(2,o.Window,{width:800,height:800,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:g}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:v}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:C})]})})})}return c}()},64083:function(T,r,n){"use strict";r.__esModule=!0,r.CargoConsole=void 0;var e=n(89005),a=n(64795),t=n(88510),o=n(72253),p=n(36036),b=n(98595),y=n(25328),S=r.CargoConsole=function(){function u(s,d){return(0,e.createComponentVNode)(2,b.Window,{width:900,height:800,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,l)]})})})}return u}(),k=function(s,d){var v=(0,o.useLocalState)(d,"contentsModal",null),g=v[0],C=v[1],f=(0,o.useLocalState)(d,"contentsModalTitle",null),N=f[0],V=f[1];if(g!==null&&N!==null)return(0,e.createComponentVNode)(2,p.Modal,{maxWidth:"75%",width:window.innerWidth+"px",maxHeight:window.innerHeight*.75+"px",mx:"auto",children:[(0,e.createComponentVNode)(2,p.Box,{width:"100%",bold:!0,children:(0,e.createVNode)(1,"h1",null,[N,(0,e.createTextVNode)(" contents:")],0)}),(0,e.createComponentVNode)(2,p.Box,{children:g.map(function(B){return(0,e.createComponentVNode)(2,p.Box,{children:["- ",B]},B)})}),(0,e.createComponentVNode)(2,p.Box,{m:2,children:(0,e.createComponentVNode)(2,p.Button,{content:"Close",onClick:function(){function B(){C(null),V(null)}return B}()})})]})},h=function(s,d){var v=(0,o.useBackend)(d),g=v.act,C=v.data,f=C.is_public,N=C.timeleft,V=C.moving,B=C.at_station,I,L;return!V&&!B?(I="Docked off-station",L="Call Shuttle"):!V&&B?(I="Docked at the station",L="Return Shuttle"):V&&(L="In Transit...",N!==1?I="Shuttle is en route (ETA: "+N+" minutes)":I="Shuttle is en route (ETA: "+N+" minute)"),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Section,{title:"Status",children:(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Shuttle Status",children:I}),f===0&&(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Controls",children:[(0,e.createComponentVNode)(2,p.Button,{content:L,disabled:V,onClick:function(){function w(){return g("moveShuttle")}return w}()}),(0,e.createComponentVNode)(2,p.Button,{content:"View Central Command Messages",onClick:function(){function w(){return g("showMessages")}return w}()})]})]})})})},i=function(s,d){var v,g=(0,o.useBackend)(d),C=g.act,f=g.data,N=f.accounts,V=(0,o.useLocalState)(d,"selectedAccount"),B=V[0],I=V[1],L=[];return N.map(function(w){return L[w.name]=w.account_UID}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Section,{title:"Payment",children:[(0,e.createComponentVNode)(2,p.Dropdown,{width:"190px",options:N.map(function(w){return w.name}),selected:(v=N.filter(function(w){return w.account_UID===B})[0])==null?void 0:v.name,onSelected:function(){function w(A){return I(L[A])}return w}()}),N.filter(function(w){return w.account_UID===B}).map(function(w){return(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Account Name",children:(0,e.createComponentVNode)(2,p.Stack.Item,{mt:1,children:w.name})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Balance",children:(0,e.createComponentVNode)(2,p.Stack.Item,{children:w.balance})})]},w.account_UID)})]})})},c=function(s,d){var v=(0,o.useBackend)(d),g=v.act,C=v.data,f=C.requests,N=C.categories,V=C.supply_packs,B=(0,o.useSharedState)(d,"category","Emergency"),I=B[0],L=B[1],w=(0,o.useSharedState)(d,"search_text",""),A=w[0],x=w[1],E=(0,o.useLocalState)(d,"contentsModal",null),P=E[0],D=E[1],M=(0,o.useLocalState)(d,"contentsModalTitle",null),O=M[0],R=M[1],F=(0,y.createSearch)(A,function(X){return X.name}),W=(0,o.useLocalState)(d,"selectedAccount"),U=W[0],z=W[1],$=(0,a.flow)([(0,t.filter)(function(X){return X.cat===N.filter(function(J){return J.name===I})[0].category||A}),A&&(0,t.filter)(F),(0,t.sortBy)(function(X){return X.name.toLowerCase()})])(V),G="Crate Catalogue";return A?G="Results for '"+A+"':":I&&(G="Browsing "+I),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Section,{title:G,buttons:(0,e.createComponentVNode)(2,p.Dropdown,{width:"190px",options:N.map(function(X){return X.name}),selected:I,onSelected:function(){function X(J){return L(J)}return X}()}),children:[(0,e.createComponentVNode)(2,p.Input,{fluid:!0,placeholder:"Search for...",onInput:function(){function X(J,se){return x(se)}return X}(),mb:1}),(0,e.createComponentVNode)(2,p.Box,{maxHeight:25,overflowY:"auto",overflowX:"hidden",children:(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:$.map(function(X){return(0,e.createComponentVNode)(2,p.Table.Row,{children:[(0,e.createComponentVNode)(2,p.Table.Cell,{bold:!0,children:[X.name," (",X.cost," Credits)"]}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"right",pr:1,children:[(0,e.createComponentVNode)(2,p.Button,{content:"Order 1",icon:"shopping-cart",disabled:!U,onClick:function(){function J(){return g("order",{crate:X.ref,multiple:!1,account:U})}return J}()}),(0,e.createComponentVNode)(2,p.Button,{content:"Order Multiple",icon:"cart-plus",disabled:!U||X.singleton,onClick:function(){function J(){return g("order",{crate:X.ref,multiple:!0,account:U})}return J}()}),(0,e.createComponentVNode)(2,p.Button,{content:"View Contents",icon:"search",onClick:function(){function J(){D(X.contents),R(X.name)}return J}()})]})]},X.name)})})})]})})},m=function(s,d){var v=s.request,g,C;switch(v.department){case"Engineering":C="CE",g="orange";break;case"Medical":C="CMO",g="teal";break;case"Science":C="RD",g="purple";break;case"Supply":C="CT",g="brown";break;case"Service":C="HOP",g="olive";break;case"Security":C="HOS",g="red";break;case"Command":C="CAP",g="blue";break;case"Assistant":C="Any Head",g="grey";break}return(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{mt:.5,children:"Approval Required:"}),!!v.req_cargo_approval&&(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button,{color:"brown",content:"QM",icon:"user-tie",tooltip:"This Order requires approval from the QM still"})}),!!v.req_head_approval&&(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button,{color:g,content:C,disabled:v.req_cargo_approval,icon:"user-tie",tooltip:v.req_cargo_approval?"This Order first requires approval from the QM before the "+C+" can approve it":"This Order requires approval from the "+C+" still"})})]})},l=function(s,d){var v=(0,o.useBackend)(d),g=v.act,C=v.data,f=C.requests,N=C.orders,V=C.shipments;return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,title:"Orders",children:[(0,e.createComponentVNode)(2,p.Box,{bold:!0,children:"Requests"}),(0,e.createComponentVNode)(2,p.Table,{children:f.map(function(B){return(0,e.createComponentVNode)(2,p.Table.Row,{className:"Cargo_RequestList",children:[(0,e.createComponentVNode)(2,p.Table.Cell,{mb:1,children:[(0,e.createComponentVNode)(2,p.Box,{children:["Order #",B.ordernum,": ",B.supply_type," (",B.cost," credits) for ",(0,e.createVNode)(1,"b",null,B.orderedby,0)," with"," ",B.department?"The "+B.department+" Department":"Their Personal"," Account"]}),(0,e.createComponentVNode)(2,p.Box,{italic:!0,children:["Reason: ",B.comment]}),(0,e.createComponentVNode)(2,m,{request:B})]}),(0,e.createComponentVNode)(2,p.Stack.Item,{textAlign:"right",children:[(0,e.createComponentVNode)(2,p.Button,{content:"Approve",color:"green",disabled:!B.can_approve,onClick:function(){function I(){return g("approve",{ordernum:B.ordernum})}return I}()}),(0,e.createComponentVNode)(2,p.Button,{content:"Deny",color:"red",disabled:!B.can_deny,onClick:function(){function I(){return g("deny",{ordernum:B.ordernum})}return I}()})]})]},B.ordernum)})}),(0,e.createComponentVNode)(2,p.Box,{bold:!0,children:"Orders Awaiting Delivery"}),(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:N.map(function(B){return(0,e.createComponentVNode)(2,p.Table.Row,{children:(0,e.createComponentVNode)(2,p.Table.Cell,{children:[(0,e.createComponentVNode)(2,p.Box,{children:["- #",B.ordernum,": ",B.supply_type," for ",(0,e.createVNode)(1,"b",null,B.orderedby,0)]}),(0,e.createComponentVNode)(2,p.Box,{italic:!0,children:["Reason: ",B.comment]})]})},B.ordernum)})}),(0,e.createComponentVNode)(2,p.Box,{bold:!0,children:"Order in Transit"}),(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:V.map(function(B){return(0,e.createComponentVNode)(2,p.Table.Row,{children:(0,e.createComponentVNode)(2,p.Table.Cell,{children:[(0,e.createComponentVNode)(2,p.Box,{children:["- #",B.ordernum,": ",B.supply_type," for ",(0,e.createVNode)(1,"b",null,B.orderedby,0)]}),(0,e.createComponentVNode)(2,p.Box,{italic:!0,children:["Reason: ",B.comment]})]})},B.ordernum)})})]})}},36232:function(T,r,n){"use strict";r.__esModule=!0,r.ChameleonAppearances=r.Chameleon=void 0;var e=n(89005),a=n(25328),t=n(64795),o=n(88510),p=n(72253),b=n(36036),y=n(98595),S=r.Chameleon=function(){function i(c,m){return(0,e.createComponentVNode)(2,y.Window,{width:431,height:500,theme:"syndicate",children:(0,e.createComponentVNode)(2,y.Window.Content,{children:(0,e.createComponentVNode)(2,h)})})}return i}(),k=function(c,m){m===void 0&&(m="");var l=(0,a.createSearch)(m,function(u){return u.name});return(0,t.flow)([(0,o.filter)(function(u){return u==null?void 0:u.name}),m&&(0,o.filter)(l)])(c)},h=r.ChameleonAppearances=function(){function i(c,m){var l=(0,p.useBackend)(m),u=l.act,s=l.data,d=(0,p.useLocalState)(m,"searchText",""),v=d[0],g=d[1],C=k(s.chameleon_skins,v),f=s.selected_appearance;return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Input,{fluid:!0,placeholder:"Search for an appearance",onInput:function(){function N(V,B){return g(B)}return N}()})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Item Appearance",children:C.map(function(N){var V=N.name+"_"+N.icon_state;return(0,e.createComponentVNode)(2,b.ImageButton,{dmIcon:N.icon,dmIconState:N.icon_state,imageSize:64,m:.5,compact:!0,selected:V===f,tooltip:N.name,style:{opacity:V===f&&"1"||"0.5"},onClick:function(){function B(){u("change_appearance",{new_appearance:V})}return B}()},V)})})})]})}return i}()},87331:function(T,r,n){"use strict";r.__esModule=!0,r.ChangelogView=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ChangelogView=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=(0,a.useLocalState)(S,"onlyRecent",0),m=c[0],l=c[1],u=i.cl_data,s=i.last_cl,d={FIX:(0,e.createComponentVNode)(2,t.Icon,{name:"tools",title:"Fix"}),WIP:(0,e.createComponentVNode)(2,t.Icon,{name:"hard-hat",title:"WIP",color:"orange"}),TWEAK:(0,e.createComponentVNode)(2,t.Icon,{name:"sliders-h",title:"Tweak"}),SOUNDADD:(0,e.createComponentVNode)(2,t.Icon,{name:"volume-up",title:"Sound Added",color:"green"}),SOUNDDEL:(0,e.createComponentVNode)(2,t.Icon,{name:"volume-mute",title:"Sound Removed",color:"red"}),CODEADD:(0,e.createComponentVNode)(2,t.Icon,{name:"plus",title:"Code Addition",color:"green"}),CODEDEL:(0,e.createComponentVNode)(2,t.Icon,{name:"minus",title:"Code Removal",color:"red"}),IMAGEADD:(0,e.createComponentVNode)(2,t.Icon,{name:"folder-plus",title:"Sprite Addition",color:"green"}),IMAGEDEL:(0,e.createComponentVNode)(2,t.Icon,{name:"folder-minus",title:"Sprite Removal",color:"red"}),SPELLCHECK:(0,e.createComponentVNode)(2,t.Icon,{name:"font",title:"Spelling/Grammar Fix"}),EXPERIMENT:(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-triangle",title:"Experimental",color:"orange"})},v=function(){function g(C){return C in d?d[C]:(0,e.createComponentVNode)(2,t.Icon,{name:"plus",color:"green"})}return g}();return(0,e.createComponentVNode)(2,o.Window,{width:750,height:800,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"ParadiseSS13 Changelog",mt:2,buttons:(0,e.createComponentVNode)(2,t.Button,{content:m?"Showing all changes":"Showing changes since last connection",onClick:function(){function g(){return l(!m)}return g}()}),children:u.map(function(g){return!m&&g.merge_ts<=s||(0,e.createComponentVNode)(2,t.Section,{mb:2,title:g.author+" - Merged on "+g.merge_date,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"#"+g.num,onClick:function(){function C(){return h("open_pr",{pr_number:g.num})}return C}()}),children:g.entries.map(function(C){return(0,e.createComponentVNode)(2,t.Box,{m:1,children:[v(C.etype)," ",C.etext]},C)})},g)})})})})}return b}()},91360:function(T,r,n){"use strict";r.__esModule=!0,r.CheckboxListInputModal=void 0;var e=n(89005),a=n(51057),t=n(19203),o=n(36036),p=n(72253),b=n(98595),y=r.CheckboxListInputModal=function(){function k(h,i){var c=(0,p.useBackend)(i),m=c.act,l=c.data,u=l.items,s=u===void 0?[]:u,d=l.message,v=d===void 0?"":d,g=l.init_value,C=l.timeout,f=l.title,N=(0,p.useLocalState)(i,"edittedItems",s),V=N[0],B=N[1],I=330+Math.ceil(v.length/3),L=function(){function w(A){A===void 0&&(A=null);var x=[].concat(V);x=x.map(function(E){return E.key===A.key?Object.assign({},E,{checked:!A.checked}):E}),B(x)}return w}();return(0,e.createComponentVNode)(2,b.Window,{title:f,width:325,height:I,children:[C&&(0,e.createComponentVNode)(2,a.Loader,{value:C}),(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{className:"ListInput__Section",fill:!0,title:v,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,S,{filteredItems:V,onClick:L})}),(0,e.createComponentVNode)(2,o.Stack.Item,{mt:.5,children:(0,e.createComponentVNode)(2,t.InputButtons,{input:V})})]})})})]})}return k}(),S=function(h,i){var c=h.filteredItems,m=h.onClick;return(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,tabIndex:0,children:c.map(function(l,u){return(0,e.createComponentVNode)(2,o.Button.Checkbox,{fluid:!0,id:u,onClick:function(){function s(){return m(l)}return s}(),checked:l.checked,style:{animation:"none",transition:"none"},children:l.key.replace(/^\w/,function(s){return s.toUpperCase()})},u)})})}},36108:function(T,r,n){"use strict";r.__esModule=!0,r.ChemDispenser=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(85870),p=n(98595),b=[1,5,10,20,30,50],y=[1,5,10],S=r.ChemDispenser=function(){function c(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,v=d.chemicals;return(0,e.createComponentVNode)(2,p.Window,{width:400,height:400+v.length*8,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,i)]})})})}return c}(),k=function(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,v=d.amount,g=d.energy,C=d.maxEnergy;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Energy",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:g,minValue:0,maxValue:C,ranges:{good:[C*.5,1/0],average:[C*.25,C*.5],bad:[-1/0,C*.25]},children:[g," / ",C," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Dispense",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,t.Stack,{children:b.map(function(f,N){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,width:"15%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"cog",selected:v===f,content:f,onClick:function(){function V(){return s("amount",{amount:f})}return V}()})},N)})})})]})})})},h=function(m,l){for(var u=(0,a.useBackend)(l),s=u.act,d=u.data,v=d.chemicals,g=v===void 0?[]:v,C=[],f=0;f<(g.length+1)%3;f++)C.push(!0);return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:d.glass?"Drink Dispenser":"Chemical Dispenser",children:[g.map(function(N,V){return(0,e.createComponentVNode)(2,t.Button,{m:.1,width:"32.5%",icon:"arrow-circle-down",overflow:"hidden",textOverflow:"ellipsis",content:N.title,style:{"margin-left":"2px"},onClick:function(){function B(){return s("dispense",{reagent:N.id})}return B}()},V)}),C.map(function(N,V){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%"},V)})]})})},i=function(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,v=d.isBeakerLoaded,g=d.beakerCurrentVolume,C=d.beakerMaxVolume,f=d.beakerContents,N=f===void 0?[]:f;return(0,e.createComponentVNode)(2,t.Stack.Item,{height:16,children:(0,e.createComponentVNode)(2,t.Section,{title:d.glass?"Glass":"Beaker",fill:!0,scrollable:!0,buttons:(0,e.createComponentVNode)(2,t.Box,{children:[!!v&&(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:"label",mr:2,children:[g," / ",C," units"]}),(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:"Eject",disabled:!v,onClick:function(){function V(){return s("ejectBeaker")}return V}()})]}),children:(0,e.createComponentVNode)(2,o.BeakerContents,{beakerLoaded:v,beakerContents:N,buttons:function(){function V(B){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"Isolate",icon:"compress-arrows-alt",onClick:function(){function I(){return s("remove",{reagent:B.id,amount:-1})}return I}()}),y.map(function(I,L){return(0,e.createComponentVNode)(2,t.Button,{content:I,onClick:function(){function w(){return s("remove",{reagent:B.id,amount:I})}return w}()},L)}),(0,e.createComponentVNode)(2,t.Button,{content:"ALL",onClick:function(){function I(){return s("remove",{reagent:B.id,amount:B.volume})}return I}()})],0)}return V}()})})})}},13146:function(T,r,n){"use strict";r.__esModule=!0,r.ChemHeater=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(85870),b=n(98595),y=r.ChemHeater=function(){function h(i,c){return(0,e.createComponentVNode)(2,b.Window,{width:350,height:275,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k)]})})})}return h}(),S=function(i,c){var m=(0,t.useBackend)(c),l=m.act,u=m.data,s=u.targetTemp,d=u.targetTempReached,v=u.autoEject,g=u.isActive,C=u.currentTemp,f=u.isBeakerLoaded;return(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Settings",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{content:"Auto-eject",icon:v?"toggle-on":"toggle-off",selected:v,onClick:function(){function N(){return l("toggle_autoeject")}return N}()}),(0,e.createComponentVNode)(2,o.Button,{content:g?"On":"Off",icon:"power-off",selected:g,disabled:!f,onClick:function(){function N(){return l("toggle_on")}return N}()})],4),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Target",children:(0,e.createComponentVNode)(2,o.NumberInput,{width:"65px",unit:"K",step:10,stepPixelSize:3,value:(0,a.round)(s,0),minValue:0,maxValue:1e3,onDrag:function(){function N(V,B){return l("adjust_temperature",{target:B})}return N}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Reading",color:d?"good":"average",children:f&&(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:C,format:function(){function N(V){return(0,a.toFixed)(V)+" K"}return N}()})||"\u2014"})]})})})},k=function(i,c){var m=(0,t.useBackend)(c),l=m.act,u=m.data,s=u.isBeakerLoaded,d=u.beakerCurrentVolume,v=u.beakerMaxVolume,g=u.beakerContents;return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{title:"Beaker",fill:!0,scrollable:!0,buttons:!!s&&(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,o.Box,{inline:!0,color:"label",mr:2,children:[d," / ",v," units"]}),(0,e.createComponentVNode)(2,o.Button,{icon:"eject",content:"Eject",onClick:function(){function C(){return l("eject_beaker")}return C}()})]}),children:(0,e.createComponentVNode)(2,p.BeakerContents,{beakerLoaded:s,beakerContents:g})})})}},56541:function(T,r,n){"use strict";r.__esModule=!0,r.ChemMaster=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(85870),b=n(3939),y=n(35840),S=["icon"];function k(I,L){if(I==null)return{};var w={};for(var A in I)if({}.hasOwnProperty.call(I,A)){if(L.includes(A))continue;w[A]=I[A]}return w}function h(I,L){I.prototype=Object.create(L.prototype),I.prototype.constructor=I,i(I,L)}function i(I,L){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(w,A){return w.__proto__=A,w},i(I,L)}var c=[1,5,10],m=function(L,w){var A=(0,a.useBackend)(w),x=A.act,E=A.data,P=L.args.analysis;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:E.condi?"Condiment Analysis":"Reagent Analysis",children:(0,e.createComponentVNode)(2,t.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:P.name}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:(P.desc||"").length>0?P.desc:"N/A"}),P.blood_type&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood type",children:P.blood_type}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood DNA",className:"LabeledList__breakContents",children:P.blood_dna})],4),!E.condi&&(0,e.createComponentVNode)(2,t.Button,{icon:E.printing?"spinner":"print",disabled:E.printing,iconSpin:!!E.printing,ml:"0.5rem",content:"Print",onClick:function(){function D(){return x("print",{idx:P.idx,beaker:L.args.beaker})}return D}()})]})})})})},l=function(I){return I[I.ToDisposals=0]="ToDisposals",I[I.ToBeaker=1]="ToBeaker",I}(l||{}),u=r.ChemMaster=function(){function I(L,w){return(0,e.createComponentVNode)(2,o.Window,{width:575,height:650,children:[(0,e.createComponentVNode)(2,b.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,s),(0,e.createComponentVNode)(2,d),(0,e.createComponentVNode)(2,v),(0,e.createComponentVNode)(2,B)]})})]})}return I}(),s=function(L,w){var A=(0,a.useBackend)(w),x=A.act,E=A.data,P=E.beaker,D=E.beaker_reagents,M=E.buffer_reagents,O=M.length>0;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Beaker",fill:!0,scrollable:!0,buttons:O?(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"eject",disabled:!P,content:"Eject and Clear Buffer",onClick:function(){function R(){return x("eject")}return R}()}):(0,e.createComponentVNode)(2,t.Button,{icon:"eject",disabled:!P,content:"Eject and Clear Buffer",onClick:function(){function R(){return x("eject")}return R}()}),children:P?(0,e.createComponentVNode)(2,p.BeakerContents,{beakerLoaded:!0,beakerContents:D,buttons:function(){function R(F,W){return(0,e.createComponentVNode)(2,t.Box,{mb:W0?(0,e.createComponentVNode)(2,p.BeakerContents,{beakerLoaded:!0,beakerContents:D,buttons:function(){function M(O,R){return(0,e.createComponentVNode)(2,t.Box,{mb:R0&&(O=M.map(function(R){var F=R.id,W=R.sprite;return(0,e.createComponentVNode)(2,N,{icon:W,translucent:!0,onClick:function(){function U(){return x("set_sprite_style",{production_mode:P,style:F})}return U}(),selected:D===F},F)})),(0,e.createComponentVNode)(2,f,{productionData:L.productionData,children:O&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Style",children:O})})},B=function(L,w){var A=(0,a.useBackend)(w),x=A.act,E=A.data,P=E.loaded_pill_bottle_style,D=E.containerstyles,M=E.loaded_pill_bottle,O={width:"20px",height:"20px"},R=D.map(function(F){var W=F.color,U=F.name,z=P===W;return(0,e.createComponentVNode)(2,t.Button,{style:{position:"relative",width:O.width,height:O.height},onClick:function(){function $(){return x("set_container_style",{style:W})}return $}(),icon:z&&"check",iconStyle:{position:"relative","z-index":1},tooltip:U,tooltipPosition:"top",children:[!z&&(0,e.createVNode)(1,"div",null,null,1,{style:{display:"inline-block"}}),(0,e.createVNode)(1,"span","Button",null,1,{style:{display:"inline-block",position:"absolute",top:0,left:0,margin:0,padding:0,width:O.width,height:O.height,"background-color":W,opacity:.6,filter:"alpha(opacity=60)"}})]},W)});return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Container Customization",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"eject",disabled:!M,content:"Eject Container",onClick:function(){function F(){return x("ejectp")}return F}()}),children:M?(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Style",children:[(0,e.createComponentVNode)(2,t.Button,{style:{width:O.width,height:O.height},icon:"tint-slash",onClick:function(){function F(){return x("clear_container_style")}return F}(),selected:!P,tooltip:"Default",tooltipPosition:"top"}),R]})}):(0,e.createComponentVNode)(2,t.Box,{color:"label",children:"No pill bottle or patch pack loaded."})})})};(0,b.modalRegisterBodyOverride)("analyze",m)},37173:function(T,r,n){"use strict";r.__esModule=!0,r.CloningConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(79140),b=1,y=32,S=128,k=r.CloningConsole=function(){function u(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.tab,N=C.has_scanner,V=C.pod_amount;return(0,e.createComponentVNode)(2,o.Window,{width:640,height:520,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Cloning Console",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Connected scanner",children:N?"Online":"Missing"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Connected pods",children:V})]})}),(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:f===1,icon:"home",onClick:function(){function B(){return g("menu",{tab:1})}return B}(),children:"Main Menu"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:f===2,icon:"user",onClick:function(){function B(){return g("menu",{tab:2})}return B}(),children:"Damage Configuration"})]}),(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,h)})]})})}return u}(),h=function(s,d){var v=(0,a.useBackend)(d),g=v.data,C=g.tab,f;return C===1?f=(0,e.createComponentVNode)(2,i):C===2&&(f=(0,e.createComponentVNode)(2,c)),f},i=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.pods,N=C.pod_amount,V=C.selected_pod_UID;return(0,e.createComponentVNode)(2,t.Box,{children:[!N&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Notice: No pods connected."}),!!N&&f.map(function(B,I){return(0,e.createComponentVNode)(2,t.Section,{layer:2,title:"Pod "+(I+1),children:(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{basis:"96px",shrink:0,children:[(0,e.createVNode)(1,"img",null,null,1,{src:(0,p.resolveAsset)("pod_"+(B.cloning?"cloning":"idle")+".gif"),style:{width:"100%","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}}),(0,e.createComponentVNode)(2,t.Button,{selected:V===B.uid,onClick:function(){function L(){return g("select_pod",{uid:B.uid})}return L}(),children:"Select"})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Progress",children:[!B.cloning&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Pod is inactive."}),!!B.cloning&&(0,e.createComponentVNode)(2,t.ProgressBar,{value:B.clone_progress,maxValue:100,color:"good"})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Biomass",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:B.biomass,ranges:{good:[2*B.biomass_storage_capacity/3,B.biomass_storage_capacity],average:[B.biomass_storage_capacity/3,2*B.biomass_storage_capacity/3],bad:[0,B.biomass_storage_capacity/3]},minValue:0,maxValue:B.biomass_storage_capacity,children:[B.biomass,"/",B.biomass_storage_capacity+" ("+100*B.biomass/B.biomass_storage_capacity+"%)"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Sanguine Reagent",children:B.sanguine_reagent}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Osseous Reagent",children:B.osseous_reagent})]})})]})},B)})]})},c=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.selected_pod_data,N=C.has_scanned,V=C.scanner_has_patient,B=C.feedback,I=C.scan_successful,L=C.cloning_cost,w=C.has_scanner,A=C.currently_scanning;return(0,e.createComponentVNode)(2,t.Box,{children:[!w&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Notice: No scanner connected."}),!!w&&(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Section,{layer:2,title:"Scanner Info",buttons:(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"hourglass-half",onClick:function(){function x(){return g("scan")}return x}(),disabled:!V||A,children:"Scan"}),(0,e.createComponentVNode)(2,t.Button,{icon:"eject",onClick:function(){function x(){return g("eject")}return x}(),disabled:!V||A,children:"Eject Patient"})]}),children:[!N&&!A&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:V?"No scan detected for current patient.":"No patient is in the scanner."}),(!!N||!!A)&&(0,e.createComponentVNode)(2,t.Box,{color:B.color,children:B.text})]}),(0,e.createComponentVNode)(2,t.Section,{layer:2,title:"Damages Breakdown",children:(0,e.createComponentVNode)(2,t.Box,{children:[(!I||!N)&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"No valid scan detected."}),!!I&&!!N&&(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function x(){return g("fix_all")}return x}(),children:"Repair All Damages"}),(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function x(){return g("fix_none")}return x}(),children:"Repair No Damages"})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function x(){return g("clone")}return x}(),children:"Clone"})})]}),(0,e.createComponentVNode)(2,t.Stack,{height:"25px",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"40%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:L[0],maxValue:f.biomass_storage_capacity,ranges:{bad:[2*f.biomass_storage_capacity/3,f.biomass_storage_capacity],average:[f.biomass_storage_capacity/3,2*f.biomass_storage_capacity/3],good:[0,f.biomass_storage_capacity/3]},color:L[0]>f.biomass?"bad":null,children:["Biomass: ",L[0],"/",f.biomass,"/",f.biomass_storage_capacity]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:L[1],maxValue:f.max_reagent_capacity,ranges:{bad:[2*f.max_reagent_capacity/3,f.max_reagent_capacity],average:[f.max_reagent_capacity/3,2*f.max_reagent_capacity/3],good:[0,f.max_reagent_capacity/3]},color:L[1]>f.sanguine_reagent?"bad":"good",children:["Sanguine: ",L[1],"/",f.sanguine_reagent,"/",f.max_reagent_capacity]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:L[2],maxValue:f.max_reagent_capacity,ranges:{bad:[2*f.max_reagent_capacity/3,f.max_reagent_capacity],average:[f.max_reagent_capacity/3,2*f.max_reagent_capacity/3],good:[0,f.max_reagent_capacity/3]},color:L[2]>f.osseous_reagent?"bad":"good",children:["Osseous: ",L[2],"/",f.osseous_reagent,"/",f.max_reagent_capacity]})})]}),(0,e.createComponentVNode)(2,m),(0,e.createComponentVNode)(2,l)]})]})})]})]})},m=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.patient_limb_data,N=C.limb_list,V=C.desired_limb_data;return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Limbs",children:N.map(function(B,I){return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Stack,{align:"baseline",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"15%",height:"20px",children:[f[B][4],":"," "]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),f[B][3]===0&&(0,e.createComponentVNode)(2,t.Stack.Item,{width:"60%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:V[B][0]+V[B][1],maxValue:f[B][5],ranges:{good:[0,f[B][5]/3],average:[f[B][5]/3,2*f[B][5]/3],bad:[2*f[B][5]/3,f[B][5]]},children:["Post-Cloning Damage: ",(0,e.createComponentVNode)(2,t.Icon,{name:"bone"})," "+V[B][0]+" / ",(0,e.createComponentVNode)(2,t.Icon,{name:"fire"})," "+V[B][1]]})}),f[B][3]!==0&&(0,e.createComponentVNode)(2,t.Stack.Item,{width:"60%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:"bad",value:0,children:["The patient's ",f[B][4]," is missing!"]})})]}),(0,e.createComponentVNode)(2,t.Stack,{children:[!!f[B][3]&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!V[B][3],onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"replace"})}return L}(),children:"Replace Limb"})}),!f[B][3]&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!(f[B][0]||f[B][1]),checked:!(V[B][0]||V[B][1]),onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"damage"})}return L}(),children:"Repair Damages"}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!(f[B][2]&b),checked:!(V[B][2]&b),onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"bone"})}return L}(),children:"Mend Bone"}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!(f[B][2]&y),checked:!(V[B][2]&y),onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"ib"})}return L}(),children:"Mend IB"}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!(f[B][2]&S),checked:!(V[B][2]&S),onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"critburn"})}return L}(),children:"Mend Critical Burn"})]})]})]},B)})})},l=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.patient_organ_data,N=C.organ_list,V=C.desired_organ_data;return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Organs",children:N.map(function(B,I){return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Stack,{align:"baseline",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"20%",height:"20px",children:[f[B][3],":"," "]}),f[B][5]!=="heart"&&(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:[!!f[B][2]&&(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!V[B][2]&&!V[B][1],onClick:function(){function L(){return g("toggle_organ_repair",{organ:B,type:"replace"})}return L}(),children:"Replace Organ"}),!f[B][2]&&(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!f[B][0],checked:!V[B][0],onClick:function(){function L(){return g("toggle_organ_repair",{organ:B,type:"damage"})}return L}(),children:"Repair Damages"})})]})}),f[B][5]==="heart"&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Heart replacement is required for cloning."}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"35%",children:[!!f[B][2]&&(0,e.createComponentVNode)(2,t.ProgressBar,{color:"bad",value:0,children:["The patient's ",f[B][3]," is missing!"]}),!f[B][2]&&(0,e.createComponentVNode)(2,t.ProgressBar,{value:V[B][0],maxValue:f[B][4],ranges:{good:[0,f[B][4]/3],average:[f[B][4]/3,2*f[B][4]/3],bad:[2*f[B][4]/3,f[B][4]]},children:"Post-Cloning Damage: "+V[B][0]})]})]})},B)})})}},98723:function(T,r,n){"use strict";r.__esModule=!0,r.CloningPod=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.CloningPod=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.biomass,m=i.biomass_storage_capacity,l=i.sanguine_reagent,u=i.osseous_reagent,s=i.organs,d=i.currently_cloning;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Liquid Storage",children:[(0,e.createComponentVNode)(2,t.Stack,{height:"25px",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"25%",children:["Biomass:"," "]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1,children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:c,ranges:{good:[2*m/3,m],average:[m/3,2*m/3],bad:[0,m/3]},minValue:0,maxValue:m})})]}),(0,e.createComponentVNode)(2,t.Stack,{height:"25px",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"25%",children:["Sanguine Reagent:"," "]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:l+" units"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.NumberInput,{value:0,minValue:0,maxValue:l,step:1,unit:"units",onChange:function(){function v(g,C){return h("remove_reagent",{reagent:"sanguine_reagent",amount:C})}return v}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Remove All",onClick:function(){function v(){return h("purge_reagent",{reagent:"sanguine_reagent"})}return v}()})})]}),(0,e.createComponentVNode)(2,t.Stack,{height:"25px",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"25%",children:["Osseous Reagent:"," "]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:u+" units"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.NumberInput,{value:0,minValue:0,maxValue:u,step:1,unit:"units",onChange:function(){function v(g,C){return h("remove_reagent",{reagent:"osseous_reagent",amount:C})}return v}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Remove All",onClick:function(){function v(){return h("purge_reagent",{reagent:"osseous_reagent"})}return v}()})})]})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Organ Storage",children:[!d&&(0,e.createComponentVNode)(2,t.Box,{children:[!s&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Notice: No organs loaded."}),!!s&&s.map(function(v){return(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:v.name}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Eject",onClick:function(){function g(){return h("eject_organ",{organ_ref:v.ref})}return g}()})})]},v)})]}),!!d&&(0,e.createComponentVNode)(2,t.Stack,{height:"100%",children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:"1",textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"lock",size:"5",mb:3}),(0,e.createVNode)(1,"br"),"Unable to access organ storage while cloning."]})})]})]})})}return b}()},18259:function(T,r,n){"use strict";r.__esModule=!0,r.CoinMint=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=n(98595),b=r.CoinMint=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.act,c=h.data,m=c.materials,l=c.moneyBag,u=c.moneyBagContent,s=c.moneyBagMaxContent,d=(l?210:138)+Math.ceil(m.length/4)*64;return(0,e.createComponentVNode)(2,p.Window,{width:210,height:d,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.NoticeBox,{m:0,info:!0,children:["Total coins produced: ",c.totalCoins]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Coin Type",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"power-off",color:c.active&&"bad",tooltip:!l&&"Need a money bag",disabled:!l,onClick:function(){function v(){return i("activate")}return v}()}),children:(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.ProgressBar,{minValue:0,maxValue:c.maxMaterials,value:c.totalMaterials})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:"eject",tooltip:"Eject selected material",onClick:function(){function v(){return i("ejectMat")}return v}()})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:m.map(function(v){return(0,e.createComponentVNode)(2,o.Button,{bold:!0,inline:!0,translucent:!0,m:.2,textAlign:"center",selected:v.id===c.chosenMaterial,tooltip:v.name,content:(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{className:(0,a.classes)(["materials32x32",v.id])}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:v.amount})]}),onClick:function(){function g(){return i("selectMaterial",{material:v.id})}return g}()},v.id)})})]})})}),!!l&&(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:"Money Bag",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"eject",content:"Eject",disabled:c.active,onClick:function(){function v(){return i("ejectBag")}return v}()}),children:(0,e.createComponentVNode)(2,o.ProgressBar,{width:"100%",minValue:0,maxValue:s,value:u,children:[u," / ",s]})})})]})})})}return y}()},93858:function(T,r,n){"use strict";r.__esModule=!0,r.HexColorInput=r.ColorSelector=r.ColorPickerModal=r.ColorInput=void 0;var e=n(89005),a=n(51057),t=n(72253),o=n(36036),p=n(98595),b=n(44879),y=n(14448),S=n(4454),k=n(35840),h=n(9394),i=n(19203),c=["prefixed","alpha","color","fluid","onChange"];/**
+ */var b=(0,t.createLogger)("hotkeys"),y={},S=[e.KEY_ESCAPE,e.KEY_ENTER,e.KEY_SPACE,e.KEY_TAB,e.KEY_CTRL,e.KEY_SHIFT,e.KEY_UP,e.KEY_DOWN,e.KEY_LEFT,e.KEY_RIGHT],k={},h=function(d){if(d===16)return"Shift";if(d===17)return"Ctrl";if(d===18)return"Alt";if(d===33)return"Northeast";if(d===34)return"Southeast";if(d===35)return"Southwest";if(d===36)return"Northwest";if(d===37)return"West";if(d===38)return"North";if(d===39)return"East";if(d===40)return"South";if(d===45)return"Insert";if(d===46)return"Delete";if(d>=48&&d<=57||d>=65&&d<=90)return String.fromCharCode(d);if(d>=96&&d<=105)return"Numpad"+(d-96);if(d>=112&&d<=123)return"F"+(d-111);if(d===188)return",";if(d===189)return"-";if(d===190)return"."},i=function(d){var C=String(d);if(C==="Ctrl+F5"||C==="Ctrl+R"){location.reload();return}if(C!=="Ctrl+F"&&!(d.event.defaultPrevented||d.isModifierKey()||S.includes(d.code))){C==="F5"&&(d.event.preventDefault(),d.event.returnValue=!1);var g=h(d.code);if(g){var v=y[g];if(v)return b.debug("macro",v),Byond.command(v);if(d.isDown()&&!k[g]){k[g]=!0;var f='Key_Down "'+g+'"';return b.debug(f),Byond.command(f)}if(d.isUp()&&k[g]){k[g]=!1;var N='Key_Up "'+g+'"';return b.debug(N),Byond.command(N)}}}},c=r.acquireHotKey=function(){function s(d){S.push(d)}return s}(),m=r.releaseHotKey=function(){function s(d){var C=S.indexOf(d);C>=0&&S.splice(C,1)}return s}(),l=r.releaseHeldKeys=function(){function s(){for(var d=0,C=Object.keys(k);d0||(0,a.fetchRetry)((0,e.resolveAsset)("icon_ref_map.json")).then(function(b){return b.json()}).then(function(b){return Byond.iconRefMap=b}).catch(function(b){return t.logger.log(b)})}return p}()},1090:function(T,r,n){"use strict";r.__esModule=!0,r.AICard=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AICard=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;if(i.has_ai===0)return(0,e.createComponentVNode)(2,o.Window,{width:250,height:120,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Stored AI",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createVNode)(1,"h3",null,"No AI detected.",16)})})})});var c=null;return i.integrity>=75?c="green":i.integrity>=25?c="yellow":c="red",(0,e.createComponentVNode)(2,o.Window,{width:600,height:420,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:i.name,children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Integrity",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:c,value:i.integrity/100})})}),(0,e.createComponentVNode)(2,t.Box,{color:"red",children:(0,e.createVNode)(1,"h2",null,i.flushing===1?"Wipe of AI in progress...":"",0)})]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Laws",children:!!i.has_laws&&(0,e.createComponentVNode)(2,t.Box,{children:i.laws.map(function(m,l){return(0,e.createComponentVNode)(2,t.Box,{children:m},l)})})||(0,e.createComponentVNode)(2,t.Box,{color:"red",children:(0,e.createVNode)(1,"h3",null,"No laws detected.",16)})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Actions",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Wireless Activity",children:(0,e.createComponentVNode)(2,t.Button,{width:10,icon:i.wireless?"check":"times",content:i.wireless?"Enabled":"Disabled",color:i.wireless?"green":"red",onClick:function(){function m(){return h("wireless")}return m}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Subspace Transceiver",children:(0,e.createComponentVNode)(2,t.Button,{width:10,icon:i.radio?"check":"times",content:i.radio?"Enabled":"Disabled",color:i.radio?"green":"red",onClick:function(){function m(){return h("radio")}return m}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Wipe",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{width:10,icon:"trash-alt",confirmIcon:"trash-alt",disabled:i.flushing||i.integrity===0,confirmColor:"red",content:"Wipe AI",onClick:function(){function m(){return h("wipe")}return m}()})})]})})})]})})})}return b}()},39454:function(T,r,n){"use strict";r.__esModule=!0,r.AIFixer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AIFixer=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;if(i.occupant===null)return(0,e.createComponentVNode)(2,o.Window,{width:550,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Stored AI",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"average",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"robot",size:5,color:"silver"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"h3",null,"No Artificial Intelligence detected.",16)]})})})})});var c=!0;(i.stat===2||i.stat===null)&&(c=!1);var m=null;i.integrity>=75?m="green":i.integrity>=25?m="yellow":m="red";var l=!0;return i.integrity>=100&&i.stat!==2&&(l=!1),(0,e.createComponentVNode)(2,o.Window,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:i.occupant,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Integrity",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:m,value:i.integrity/100})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:c?"green":"red",children:c?"Functional":"Non-Functional"})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Laws",children:!!i.has_laws&&(0,e.createComponentVNode)(2,t.Box,{children:i.laws.map(function(u,s){return(0,e.createComponentVNode)(2,t.Box,{inline:!0,children:u},s)})})||(0,e.createComponentVNode)(2,t.Box,{color:"red",children:(0,e.createVNode)(1,"h3",null,"No laws detected.",16)})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Actions",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Wireless Activity",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.wireless?"times":"check",content:i.wireless?"Disabled":"Enabled",color:i.wireless?"red":"green",onClick:function(){function u(){return h("wireless")}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Subspace Transceiver",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.radio?"times":"check",content:i.radio?"Disabled":"Enabled",color:i.radio?"red":"green",onClick:function(){function u(){return h("radio")}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Start Repairs",children:(0,e.createComponentVNode)(2,t.Button,{icon:"wrench",disabled:!l||i.active,content:!l||i.active?"Already Repaired":"Repair",onClick:function(){function u(){return h("fix")}return u}()})})]}),(0,e.createComponentVNode)(2,t.Box,{color:"green",lineHeight:2,children:i.active?"Reconstruction in progress.":""})]})})]})})})}return b}()},88422:function(T,r,n){"use strict";r.__esModule=!0,r.APC=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(195),b=r.APC=function(){function h(i,c){return(0,e.createComponentVNode)(2,o.Window,{width:510,height:435,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,k)})})}return h}(),y={2:{color:"good",externalPowerText:"External Power",chargingText:"Fully Charged"},1:{color:"average",externalPowerText:"Low External Power",chargingText:"Charging"},0:{color:"bad",externalPowerText:"No External Power",chargingText:"Not Charging"}},S={1:{icon:"terminal",content:"Override Programming",action:"hack"},2:{icon:"caret-square-down",content:"Shunt Core Process",action:"occupy"},3:{icon:"caret-square-left",content:"Return to Main Core",action:"deoccupy"},4:{icon:"caret-square-down",content:"Shunt Core Process",action:"occupy"}},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.locked&&!u.siliconUser,d=u.normallyLocked,C=y[u.externalPower]||y[0],g=y[u.chargingStatus]||y[0],v=u.powerChannels||[],f=S[u.malfStatus]||S[0],N=u.powerCellStatus/100;return(0,e.createFragment)([(0,e.createComponentVNode)(2,p.InterfaceLockNoticeBox),(0,e.createComponentVNode)(2,t.Section,{title:"Power Status",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Main Breaker",color:C.color,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:u.isOperating?"power-off":"times",content:u.isOperating?"On":"Off",selected:u.isOperating&&!s,color:u.isOperating?"":"bad",disabled:s,onClick:function(){function V(){return l("breaker")}return V}()}),children:["[ ",C.externalPowerText," ]"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power Cell",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:"good",value:N})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Charge Mode",color:g.color,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:u.chargeMode?"sync":"times",content:u.chargeMode?"Auto":"Off",selected:u.chargeMode,disabled:s,onClick:function(){function V(){return l("charge")}return V}()}),children:["[ ",g.chargingText," ]"]})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Power Channels",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[v.map(function(V){var B=V.topicParams;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:V.title,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{inline:!0,mx:2,color:V.status>=2?"good":"bad",children:V.status>=2?"On":"Off"}),(0,e.createComponentVNode)(2,t.Button,{icon:"sync",content:"Auto",selected:!s&&(V.status===1||V.status===3),disabled:s,onClick:function(){function I(){return l("channel",B.auto)}return I}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:"On",selected:!s&&V.status===2,disabled:s,onClick:function(){function I(){return l("channel",B.on)}return I}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Off",selected:!s&&V.status===0,disabled:s,onClick:function(){function I(){return l("channel",B.off)}return I}()})],4),children:[V.powerLoad," W"]},V.title)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Total Load",children:(0,e.createVNode)(1,"b",null,[u.totalLoad,(0,e.createTextVNode)(" W")],0)})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Misc",buttons:!!u.siliconUser&&(0,e.createFragment)([!!u.malfStatus&&(0,e.createComponentVNode)(2,t.Button,{icon:f.icon,content:f.content,color:"bad",onClick:function(){function V(){return l(f.action)}return V}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"lightbulb-o",content:"Overload",onClick:function(){function V(){return l("overload")}return V}()})],0),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cover Lock",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.4,icon:u.coverLocked?"lock":"unlock",content:u.coverLocked?"Engaged":"Disengaged",disabled:s,onClick:function(){function V(){return l("cover")}return V}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Emergency Lighting",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"lightbulb-o",content:u.emergencyLights?"Enabled":"Disabled",disabled:s,onClick:function(){function V(){return l("emergency_lighting")}return V}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Night Shift Lighting",buttons:(0,e.createComponentVNode)(2,t.Button,{mt:.4,icon:"lightbulb-o",content:u.nightshiftLights?"Enabled":"Disabled",onClick:function(){function V(){return l("toggle_nightshift")}return V}()})})]})})],4)}},99660:function(T,r,n){"use strict";r.__esModule=!0,r.ATM=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ATM=function(){function m(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=C.view_screen,v=C.authenticated_account,f=C.ticks_left_locked_down,N=C.linked_db,V;if(f>0)V=(0,e.createComponentVNode)(2,t.Box,{bold:!0,color:"bad",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-triangle"}),"Maximum number of pin attempts exceeded! Access to this ATM has been temporarily disabled."]});else if(!N)V=(0,e.createComponentVNode)(2,t.Box,{bold:!0,color:"bad",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-triangle"}),"Unable to connect to accounts database, please retry and if the issue persists contact Nanotrasen IT support."]});else if(v)switch(g){case 1:V=(0,e.createComponentVNode)(2,y);break;case 2:V=(0,e.createComponentVNode)(2,S);break;case 3:V=(0,e.createComponentVNode)(2,i);break;default:V=(0,e.createComponentVNode)(2,k)}else V=(0,e.createComponentVNode)(2,h);return(0,e.createComponentVNode)(2,o.Window,{width:550,height:650,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,t.Section,{children:V})]})})}return m}(),b=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=C.machine_id,v=C.held_card_name;return(0,e.createComponentVNode)(2,t.Section,{title:"Nanotrasen Automatic Teller Machine",children:[(0,e.createComponentVNode)(2,t.Box,{children:"For all your monetary needs!"}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Card",children:(0,e.createComponentVNode)(2,t.Button,{content:v,icon:"eject",onClick:function(){function f(){return d("insert_card")}return f}()})})})]})},y=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=C.security_level;return(0,e.createComponentVNode)(2,t.Section,{title:"Select a new security level for this account",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Level",children:(0,e.createComponentVNode)(2,t.Button,{content:"Account Number",icon:"unlock",selected:g===0,onClick:function(){function v(){return d("change_security_level",{new_security_level:1})}return v}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:"Either the account number or card is required to access this account. EFTPOS transactions will require a card."}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Level",children:(0,e.createComponentVNode)(2,t.Button,{content:"Account Pin",icon:"unlock",selected:g===2,onClick:function(){function v(){return d("change_security_level",{new_security_level:2})}return v}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:"An account number and pin must be manually entered to access this account and process transactions."})]}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,c)]})},S=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=(0,a.useLocalState)(u,"targetAccNumber",0),v=g[0],f=g[1],N=(0,a.useLocalState)(u,"fundsAmount",0),V=N[0],B=N[1],I=(0,a.useLocalState)(u,"purpose",0),L=I[0],w=I[1],A=C.money;return(0,e.createComponentVNode)(2,t.Section,{title:"Transfer Fund",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Account Balance",children:["$",A]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target Account Number",children:(0,e.createComponentVNode)(2,t.Input,{placeholder:"7 Digit Number",onInput:function(){function x(E,P){return f(P)}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Funds to Transfer",children:(0,e.createComponentVNode)(2,t.Input,{onInput:function(){function x(E,P){return B(P)}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Transaction Purpose",children:(0,e.createComponentVNode)(2,t.Input,{fluid:!0,onInput:function(){function x(E,P){return w(P)}return x}()})})]}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.Button,{content:"Transfer",icon:"sign-out-alt",onClick:function(){function x(){return d("transfer",{target_acc_number:v,funds_amount:V,purpose:L})}return x}()}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,c)]})},k=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=(0,a.useLocalState)(u,"fundsAmount",0),v=g[0],f=g[1],N=C.owner_name,V=C.money;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"Welcome, "+N,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Logout",icon:"sign-out-alt",onClick:function(){function B(){return d("logout")}return B}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Account Balance",children:["$",V]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Withdrawal Amount",children:(0,e.createComponentVNode)(2,t.Input,{onInput:function(){function B(I,L){return f(L)}return B}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Withdraw Funds",icon:"sign-out-alt",onClick:function(){function B(){return d("withdrawal",{funds_amount:v})}return B}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Menu",children:[(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Change account security level",icon:"lock",onClick:function(){function B(){return d("view_screen",{view_screen:1})}return B}()})}),(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Make transfer",icon:"exchange-alt",onClick:function(){function B(){return d("view_screen",{view_screen:2})}return B}()})}),(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"View transaction log",icon:"list",onClick:function(){function B(){return d("view_screen",{view_screen:3})}return B}()})}),(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Print balance statement",icon:"print",onClick:function(){function B(){return d("balance_statement")}return B}()})})]})],4)},h=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=(0,a.useLocalState)(u,"accountID",null),v=g[0],f=g[1],N=(0,a.useLocalState)(u,"accountPin",null),V=N[0],B=N[1],I=C.machine_id,L=C.held_card_name;return(0,e.createComponentVNode)(2,t.Section,{title:"Insert card or enter ID and pin to login",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Account ID",children:(0,e.createComponentVNode)(2,t.Input,{placeholder:"6 Digit Number",onInput:function(){function w(A,x){return f(x)}return w}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Pin",children:(0,e.createComponentVNode)(2,t.Input,{placeholder:"6 Digit Number",onInput:function(){function w(A,x){return B(x)}return w}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Login",icon:"sign-in-alt",onClick:function(){function w(){return d("attempt_auth",{account_num:v,account_pin:V})}return w}()})})]})})},i=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=C.transaction_log;return(0,e.createComponentVNode)(2,t.Section,{title:"Transactions",children:[(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Timestamp"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Reason"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Value"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Terminal"})]}),g.map(function(v){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:v.time}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:v.purpose}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:v.is_deposit?"green":"red",children:["$",v.amount]}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:v.target_name})]},v)})]}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,c)]})},c=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data;return(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"sign-out-alt",onClick:function(){function g(){return d("view_screen",{view_screen:0})}return g}()})}},86423:function(T,r,n){"use strict";r.__esModule=!0,r.AccountsUplinkTerminal=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(36352),b=n(98595),y=n(321),S=n(5485),k=r.AccountsUplinkTerminal=function(){function C(g,v){var f=(0,t.useBackend)(v),N=f.act,V=f.data,B=V.loginState,I=V.currentPage,L;if(B.logged_in)I===1?L=(0,e.createComponentVNode)(2,i):I===2?L=(0,e.createComponentVNode)(2,s):I===3&&(L=(0,e.createComponentVNode)(2,d));else return(0,e.createComponentVNode)(2,b.Window,{width:800,height:600,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,S.LoginScreen)})})});return(0,e.createComponentVNode)(2,b.Window,{width:800,height:600,children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y.LoginInfo),(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:L})]})})})}return C}(),h=function(g,v){var f=(0,t.useBackend)(v),N=f.data,V=(0,t.useLocalState)(v,"tabIndex",0),B=V[0],I=V[1],L=N.login_state;return(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,mb:1,children:(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"list",selected:B===0,onClick:function(){function w(){return I(0)}return w}(),children:"User Accounts"}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"list",selected:B===1,onClick:function(){function w(){return I(1)}return w}(),children:"Department Accounts"})]})})})},i=function(g,v){var f=(0,t.useLocalState)(v,"tabIndex",0),N=f[0];switch(N){case 0:return(0,e.createComponentVNode)(2,c);case 1:return(0,e.createComponentVNode)(2,m);default:return"You are somehow on a tab that doesn't exist! Please let a coder know."}},c=function(g,v){var f=(0,t.useBackend)(v),N=f.act,V=f.data,B=V.accounts,I=(0,t.useLocalState)(v,"searchText",""),L=I[0],w=I[1],A=(0,t.useLocalState)(v,"sortId","owner_name"),x=A[0],E=A[1],P=(0,t.useLocalState)(v,"sortOrder",!0),D=P[0],M=P[1];return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,u),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"AccountsUplinkTerminal__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,l,{id:"owner_name",children:"Account Holder"}),(0,e.createComponentVNode)(2,l,{id:"account_number",children:"Account Number"}),(0,e.createComponentVNode)(2,l,{id:"suspended",children:"Account Status"}),(0,e.createComponentVNode)(2,l,{id:"money",children:"Account Balance"})]}),B.filter((0,a.createSearch)(L,function(O){return O.owner_name+"|"+O.account_number+"|"+O.suspended+"|"+O.money})).sort(function(O,R){var F=D?1:-1;return O[x].localeCompare(R[x])*F}).map(function(O){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"AccountsUplinkTerminal__listRow--"+O.suspended,onClick:function(){function R(){return N("view_account_detail",{account_num:O.account_number})}return R}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user"})," ",O.owner_name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:["#",O.account_number]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:O.suspended}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:O.money})]},O.account_number)})]})})})]})},m=function(g,v){var f=(0,t.useBackend)(v),N=f.act,V=f.data,B=V.department_accounts;return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.Table,{className:"AccountsUplinkTerminal__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,p.TableCell,{children:"Department Name"}),(0,e.createComponentVNode)(2,p.TableCell,{children:"Account Number"}),(0,e.createComponentVNode)(2,p.TableCell,{children:"Account Status"}),(0,e.createComponentVNode)(2,p.TableCell,{children:"Account Balance"})]}),B.map(function(I){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"AccountsUplinkTerminal__listRow--"+I.suspended,onClick:function(){function L(){return N("view_account_detail",{account_num:I.account_number})}return L}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"wallet"})," ",I.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:["#",I.account_number]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:I.suspended}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:I.money})]},I.account_number)})]})})})})},l=function(g,v){var f=(0,t.useLocalState)(v,"sortId","name"),N=f[0],V=f[1],B=(0,t.useLocalState)(v,"sortOrder",!0),I=B[0],L=B[1],w=g.id,A=g.children;return(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{color:N!==w&&"transparent",width:"100%",onClick:function(){function x(){N===w?L(!I):(V(w),L(!0))}return x}(),children:[A,N===w&&(0,e.createComponentVNode)(2,o.Icon,{name:I?"sort-up":"sort-down",ml:"0.25rem;"})]})})},u=function(g,v){var f=(0,t.useBackend)(v),N=f.act,V=f.data,B=V.is_printing,I=(0,t.useLocalState)(v,"searchText",""),L=I[0],w=I[1];return(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{content:"New Account",icon:"plus",onClick:function(){function A(){return N("create_new_account")}return A}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"Search by account holder, number, status",width:"100%",onInput:function(){function A(x,E){return w(E)}return A}()})})]})},s=function(g,v){var f=(0,t.useBackend)(v),N=f.act,V=f.data,B=V.account_number,I=V.owner_name,L=V.money,w=V.suspended,A=V.transactions,x=V.account_pin,E=V.is_department_account;return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:"#"+B+" / "+I,buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"arrow-left",content:"Back",onClick:function(){function P(){return N("back")}return P}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Number",children:["#",B]}),!!E&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Pin",children:x}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Pin Actions",children:(0,e.createComponentVNode)(2,o.Button,{ml:1,icon:"user-cog",content:"Set New Pin",disabled:!!E,onClick:function(){function P(){return N("set_account_pin",{account_number:B})}return P}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Holder",children:I}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Balance",children:L}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Status",color:w?"red":"green",children:[w?"Suspended":"Active",(0,e.createComponentVNode)(2,o.Button,{ml:1,content:w?"Unsuspend":"Suspend",icon:w?"unlock":"lock",onClick:function(){function P(){return N("toggle_suspension")}return P}()})]})]})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Transactions",children:(0,e.createComponentVNode)(2,o.Table,{children:[(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Timestamp"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Reason"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Value"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Terminal"})]}),A.map(function(P){return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:P.time}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:P.purpose}),(0,e.createComponentVNode)(2,o.Table.Cell,{color:P.is_deposit?"green":"red",children:["$",P.amount]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:P.target_name})]},P)})]})})})]})},d=function(g,v){var f=(0,t.useBackend)(v),N=f.act,V=f.data,B=(0,t.useLocalState)(v,"accName",""),I=B[0],L=B[1],w=(0,t.useLocalState)(v,"accDeposit",""),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,o.Section,{title:"Create Account",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"arrow-left",content:"Back",onClick:function(){function E(){return N("back")}return E}()}),children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Holder",children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"Name Here",onChange:function(){function E(P,D){return L(D)}return E}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Initial Deposit",children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"0",onChange:function(){function E(P,D){return x(D)}return E}()})})]}),(0,e.createComponentVNode)(2,o.Button,{mt:1,fluid:!0,content:"Create Account",onClick:function(){function E(){return N("finalise_create_account",{holder_name:I,starting_funds:A})}return E}()})]})}},39683:function(T,r,n){"use strict";r.__esModule=!0,r.AgentCardInfo=r.AgentCardAppearances=r.AgentCard=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=[{name:"Male",icon:"mars"},{name:"Female",icon:"venus"},{name:"Genderless",icon:"genderless"}],b=["A+","A-","B+","B-","AB+","AB-","O+","O-"],y="Empty",S=function(m){var l=m.label,u=m.value,s=m.onCommit,d=m.onClick,C=m.onRClick,g=m.tooltip;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:l,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,mb:-.5,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button.Input,{fluid:!0,textAlign:"center",content:u||y,onCommit:s})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"file-signature",tooltip:g,tooltipPosition:"bottom-end",onClick:d,onContextMenu:C})})]})})},k=r.AgentCard=function(){function c(m,l){var u=(0,a.useLocalState)(l,"tabIndex",0),s=u[0],d=u[1],C=function(){function g(v){switch(v){case 0:return(0,e.createComponentVNode)(2,h);case 1:return(0,e.createComponentVNode)(2,i);default:return(0,e.createComponentVNode)(2,h)}}return g}();return(0,e.createComponentVNode)(2,o.Window,{width:435,height:500,theme:"syndicate",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Tabs,{fluid:!0,children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:s===0,onClick:function(){function g(){return d(0)}return g}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"table"})," Card Info"]},"Card Info"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:s===1,onClick:function(){function g(){return d(1)}return g}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"id-card"})," Appearance"]},"Appearance")]})}),C(s)]})})})}return c}(),h=r.AgentCardInfo=function(){function c(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,C=d.registered_name,g=d.sex,v=d.age,f=d.assignment,N=d.job_icon,V=d.associated_account_number,B=d.blood_type,I=d.dna_hash,L=d.fingerprint_hash,w=d.photo,A=d.ai_tracking,x=d.photo_cooldown,E=(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("Autofill options."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("LMB - Autofill your own data."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("RMB - Autofill someone else data.")],4),P=(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("Autofill options."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("LMB - Autofill your own data."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("RMB - Autofill with random data.")],4);return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Card Info",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,S,{label:"Name",value:C,tooltip:E,onCommit:function(){function D(M,O){return s("change_name",{name:O})}return D}(),onClick:function(){function D(){return s("change_name",{option:"Primary"})}return D}(),onRClick:function(){function D(M){M.preventDefault(),s("change_name",{option:"Secondary"})}return D}()}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Sex",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,mb:-.5,children:p.map(function(D){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:D.icon,content:D.name,selected:g===D.name,onClick:function(){function M(){return s("change_sex",{sex:D.name})}return M}()})},D.name)})})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Age",children:(0,e.createComponentVNode)(2,t.Slider,{fluid:!0,minValue:17,value:v||0,maxValue:300,onChange:function(){function D(M,O){return s("change_age",{age:O})}return D}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rank",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,mb:-.5,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:function(){function D(){return s("change_occupation")}return D}(),textAlign:"middle",children:f||"[UNSET]"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{tooltip:"Change HUD icon",tooltipPosition:"bottom-end",onClick:function(){function D(){return s("change_occupation",{option:"Primary"})}return D}(),children:[(0,e.createComponentVNode)(2,t.DmIcon,{fill:!0,icon:"icons/mob/hud/job_assets.dmi",icon_state:N,verticalAlign:"bottom",my:"2px",width:"16px"})," "]})})]})}),(0,e.createComponentVNode)(2,S,{label:"Fingerprint",value:L,onCommit:function(){function D(M,O){return s("change_fingerprints",{new_fingerprints:O})}return D}(),onClick:function(){function D(){return s("change_fingerprints",{option:"Primary"})}return D}(),onRClick:function(){function D(M){M.preventDefault(),s("change_fingerprints",{option:"Secondary"})}return D}(),tooltip:P}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood Type",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,mb:-.5,children:b.map(function(D){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:D,selected:B===D,onClick:function(){function M(){return s("change_blood_type",{new_type:D})}return M}()})},D)})})}),(0,e.createComponentVNode)(2,S,{label:"DNA",value:I,onCommit:function(){function D(M,O){return s("change_dna_hash",{new_dna:O})}return D}(),onClick:function(){function D(){return s("change_dna_hash",{option:"Primary"})}return D}(),onRClick:function(){function D(M){M.preventDefault(),s("change_dna_hash",{option:"Secondary"})}return D}(),tooltip:P}),(0,e.createComponentVNode)(2,S,{label:"Account",value:V||0,onCommit:function(){function D(M,O){return s("change_money_account",{new_account:O})}return D}(),onClick:function(){function D(){return s("change_money_account",{option:"Primary"})}return D}(),onRClick:function(){function D(M){M.preventDefault(),s("change_money_account",{option:"Secondary"})}return D}(),tooltip:P}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Photo",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",disabled:!x,tooltip:x?"":"You can't generate a new photo yet.",onClick:function(){function D(){return s("change_photo")}return D}(),children:w?"Update":y})})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Card Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Card Info",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{fluid:!0,textAlign:"center",content:"Delete Card Info",confirmContent:"Are you sure?",onClick:function(){function D(){return s("delete_info")}return D}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Access",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{fluid:!0,textAlign:"center",content:"Reset Access",confirmContent:"Are you sure?",onClick:function(){function D(){return s("clear_access")}return D}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"AI Tracking",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",onClick:function(){function D(){return s("change_ai_tracking")}return D}(),children:A?"Untrackable":"Trackable"})})]})})})],4)}return c}(),i=r.AgentCardAppearances=function(){function c(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,C=(0,a.useSharedState)(l,"selectedAppearance",null),g=C[0],v=C[1],f=d.appearances,N=d.id_icon;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Card Appearance",children:f.map(function(V){return(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:N,dmIconState:V,imageSize:64,compact:!0,selected:V===g,tooltip:V,style:{opacity:V===g&&"1"||"0.5"},onClick:function(){function B(){v(V),s("change_appearance",{new_appearance:V})}return B}()},V)})})})}return c}()},56793:function(T,r,n){"use strict";r.__esModule=!0,r.AiAirlock=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p={2:{color:"good",localStatusText:"Offline"},1:{color:"average",localStatusText:"Caution"},0:{color:"bad",localStatusText:"Optimal"}},b=r.AiAirlock=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=p[c.power.main]||p[0],l=p[c.power.backup]||p[0],u=p[c.shock]||p[0];return(0,e.createComponentVNode)(2,o.Window,{width:500,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Power Status",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Main",color:m.color,buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,icon:"lightbulb-o",disabled:!c.power.main,content:"Disrupt",onClick:function(){function s(){return i("disrupt-main")}return s}()}),children:[c.power.main?"Online":"Offline"," ",!c.wires.main_power&&"[Wires have been cut!]"||c.power.main_timeleft>0&&"["+c.power.main_timeleft+"s]"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Backup",color:l.color,buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,icon:"lightbulb-o",disabled:!c.power.backup,content:"Disrupt",onClick:function(){function s(){return i("disrupt-backup")}return s}()}),children:[c.power.backup?"Online":"Offline"," ",!c.wires.backup_power&&"[Wires have been cut!]"||c.power.backup_timeleft>0&&"["+c.power.backup_timeleft+"s]"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Electrify",color:u.color,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{mr:.5,icon:"wrench",disabled:!(c.wires.shock&&c.shock!==2),content:"Restore",onClick:function(){function s(){return i("shock-restore")}return s}()}),(0,e.createComponentVNode)(2,t.Button,{mr:.5,icon:"bolt",disabled:!c.wires.shock,content:"Temporary",onClick:function(){function s(){return i("shock-temp")}return s}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"bolt",disabled:!c.wires.shock||c.shock===0,content:"Permanent",onClick:function(){function s(){return i("shock-perm")}return s}()})],4),children:[c.shock===2?"Safe":"Electrified"," ",!c.wires.shock&&"[Wires have been cut!]"||c.shock_timeleft>0&&"["+c.shock_timeleft+"s]"||c.shock_timeleft===-1&&"[Permanent]"]})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Access and Door Control",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID Scan",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,width:6.5,icon:c.id_scanner?"power-off":"times",content:c.id_scanner?"Enabled":"Disabled",selected:c.id_scanner,disabled:!c.wires.id_scanner,onClick:function(){function s(){return i("idscan-toggle")}return s}()}),children:!c.wires.id_scanner&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Emergency Access",buttons:(0,e.createComponentVNode)(2,t.Button,{width:6.5,icon:c.emergency?"power-off":"times",content:c.emergency?"Enabled":"Disabled",selected:c.emergency,onClick:function(){function s(){return i("emergency-toggle")}return s}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Bolts",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,icon:c.locked?"lock":"unlock",content:c.locked?"Lowered":"Raised",selected:c.locked,disabled:!c.wires.bolts,onClick:function(){function s(){return i("bolt-toggle")}return s}()}),children:!c.wires.bolts&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Bolt Lights",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,width:6.5,icon:c.lights?"power-off":"times",content:c.lights?"Enabled":"Disabled",selected:c.lights,disabled:!c.wires.lights,onClick:function(){function s(){return i("light-toggle")}return s}()}),children:!c.wires.lights&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Force Sensors",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,width:6.5,icon:c.safe?"power-off":"times",content:c.safe?"Enabled":"Disabled",selected:c.safe,disabled:!c.wires.safe,onClick:function(){function s(){return i("safe-toggle")}return s}()}),children:!c.wires.safe&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Timing Safety",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{mb:.5,width:6.5,icon:c.speed?"power-off":"times",content:c.speed?"Enabled":"Disabled",selected:c.speed,disabled:!c.wires.timing,onClick:function(){function s(){return i("speed-toggle")}return s}()}),children:!c.wires.timing&&"[Wires have been cut!]"}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Door Control",color:"bad",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:c.opened?"sign-out-alt":"sign-in-alt",content:c.opened?"Open":"Closed",selected:c.opened,disabled:c.locked||c.welded,onClick:function(){function s(){return i("open-close")}return s}()}),children:!!(c.locked||c.welded)&&(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("[Door is "),c.locked?"bolted":"",c.locked&&c.welded?" and ":"",c.welded?"welded":"",(0,e.createTextVNode)("!]")],0)})]})})]})})}return y}()},72475:function(T,r,n){"use strict";r.__esModule=!0,r.AirAlarm=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(195),b=r.AirAlarm=function(){function u(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.locked;return(0,e.createComponentVNode)(2,o.Window,{width:570,height:f?310:755,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,p.InterfaceLockNoticeBox),(0,e.createComponentVNode)(2,S),!f&&(0,e.createFragment)([(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,h)],4)]})})}return u}(),y=function(s){return s===0?"green":s===1?"orange":"red"},S=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.air,N=v.mode,V=v.atmos_alarm,B=v.locked,I=v.alarmActivated,L=v.rcon,w=v.target_temp,A;return f.danger.overall===0?V===0?A="Optimal":A="Caution: Atmos alert in area":f.danger.overall===1?A="Caution":A="DANGER: Internals Required",(0,e.createComponentVNode)(2,t.Section,{title:"Air Status",children:f?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Pressure",children:(0,e.createComponentVNode)(2,t.Box,{color:y(f.danger.pressure),children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:f.pressure})," kPa",!B&&(0,e.createFragment)([(0,e.createTextVNode)("\xA0"),(0,e.createComponentVNode)(2,t.Button,{content:N===3?"Deactivate Panic Siphon":"Activate Panic Siphon",selected:N===3,icon:"exclamation-triangle",onClick:function(){function x(){return g("mode",{mode:N===3?1:3})}return x}()})],4)]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Oxygen",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.oxygen/100,fractionDigits:"1",color:y(f.danger.oxygen)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Nitrogen",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.nitrogen/100,fractionDigits:"1",color:y(f.danger.nitrogen)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Carbon Dioxide",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.co2/100,fractionDigits:"1",color:y(f.danger.co2)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Toxins",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.plasma/100,fractionDigits:"1",color:y(f.danger.plasma)})}),f.contents.n2o>.1&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Nitrous Oxide",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.n2o/100,fractionDigits:"1",color:y(f.danger.n2o)})}),f.contents.other>.1&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Other",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:f.contents.other/100,fractionDigits:"1",color:y(f.danger.other)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,t.Box,{color:y(f.danger.temperature),children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:f.temperature})," K / ",(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:f.temperature_c})," C\xA0",(0,e.createComponentVNode)(2,t.Button,{icon:"thermometer-full",content:w+" C",onClick:function(){function x(){return g("temperature")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{content:f.thermostat_state?"On":"Off",selected:f.thermostat_state,icon:"power-off",onClick:function(){function x(){return g("thermostat_state")}return x}()})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Local Status",children:(0,e.createComponentVNode)(2,t.Box,{color:y(f.danger.overall),children:[A,!B&&(0,e.createFragment)([(0,e.createTextVNode)("\xA0"),(0,e.createComponentVNode)(2,t.Button,{content:I?"Reset Alarm":"Activate Alarm",selected:I,onClick:function(){function x(){return g(I?"atmos_reset":"atmos_alarm")}return x}()})],4)]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Remote Control Settings",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Off",selected:L===1,onClick:function(){function x(){return g("set_rcon",{rcon:1})}return x}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Auto",selected:L===2,onClick:function(){function x(){return g("set_rcon",{rcon:2})}return x}()}),(0,e.createComponentVNode)(2,t.Button,{content:"On",selected:L===3,onClick:function(){function x(){return g("set_rcon",{rcon:3})}return x}()})]})]}):(0,e.createComponentVNode)(2,t.Box,{children:"Unable to acquire air sample!"})})},k=function(s,d){var C=(0,a.useLocalState)(d,"tabIndex",0),g=C[0],v=C[1];return(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g===0,onClick:function(){function f(){return v(0)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"sign-out-alt"})," Vent Control"]},"Vents"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g===1,onClick:function(){function f(){return v(1)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"sign-in-alt"})," Scrubber Control"]},"Scrubbers"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g===2,onClick:function(){function f(){return v(2)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"cog"})," Mode"]},"Mode"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g===3,onClick:function(){function f(){return v(3)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"tachometer-alt"})," Thresholds"]},"Thresholds")]})},h=function(s,d){var C=(0,a.useLocalState)(d,"tabIndex",0),g=C[0],v=C[1];switch(g){case 0:return(0,e.createComponentVNode)(2,i);case 1:return(0,e.createComponentVNode)(2,c);case 2:return(0,e.createComponentVNode)(2,m);case 3:return(0,e.createComponentVNode)(2,l);default:return"WE SHOULDN'T BE HERE!"}},i=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.vents;return f.map(function(N){return(0,e.createComponentVNode)(2,t.Section,{title:N.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:[(0,e.createComponentVNode)(2,t.Button,{content:N.power?"On":"Off",selected:N.power,icon:"power-off",onClick:function(){function V(){return g("command",{cmd:"power",val:!N.power,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:N.direction?"Blowing":"Siphoning",icon:N.direction?"sign-out-alt":"sign-in-alt",onClick:function(){function V(){return g("command",{cmd:"direction",val:!N.direction,id_tag:N.id_tag})}return V}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Pressure Checks",children:[(0,e.createComponentVNode)(2,t.Button,{content:"External",selected:N.checks===1,onClick:function(){function V(){return g("command",{cmd:"checks",val:1,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Internal",selected:N.checks===2,onClick:function(){function V(){return g("command",{cmd:"checks",val:2,id_tag:N.id_tag})}return V}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"External Pressure Target",children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:N.external})," kPa\xA0",(0,e.createComponentVNode)(2,t.Button,{content:"Set",icon:"cog",onClick:function(){function V(){return g("command",{cmd:"set_external_pressure",id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Reset",icon:"redo-alt",onClick:function(){function V(){return g("command",{cmd:"set_external_pressure",val:101.325,id_tag:N.id_tag})}return V}()})]})]})},N.name)})},c=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.scrubbers;return f.map(function(N){return(0,e.createComponentVNode)(2,t.Section,{title:N.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:[(0,e.createComponentVNode)(2,t.Button,{content:N.power?"On":"Off",selected:N.power,icon:"power-off",onClick:function(){function V(){return g("command",{cmd:"power",val:!N.power,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:N.scrubbing?"Scrubbing":"Siphoning",icon:N.scrubbing?"filter":"sign-in-alt",onClick:function(){function V(){return g("command",{cmd:"scrubbing",val:!N.scrubbing,id_tag:N.id_tag})}return V}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Range",children:(0,e.createComponentVNode)(2,t.Button,{content:N.widenet?"Extended":"Normal",selected:N.widenet,icon:"expand-arrows-alt",onClick:function(){function V(){return g("command",{cmd:"widenet",val:!N.widenet,id_tag:N.id_tag})}return V}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Filtering",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Carbon Dioxide",selected:N.filter_co2,onClick:function(){function V(){return g("command",{cmd:"co2_scrub",val:!N.filter_co2,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Plasma",selected:N.filter_toxins,onClick:function(){function V(){return g("command",{cmd:"tox_scrub",val:!N.filter_toxins,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Nitrous Oxide",selected:N.filter_n2o,onClick:function(){function V(){return g("command",{cmd:"n2o_scrub",val:!N.filter_n2o,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Oxygen",selected:N.filter_o2,onClick:function(){function V(){return g("command",{cmd:"o2_scrub",val:!N.filter_o2,id_tag:N.id_tag})}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Nitrogen",selected:N.filter_n2,onClick:function(){function V(){return g("command",{cmd:"n2_scrub",val:!N.filter_n2,id_tag:N.id_tag})}return V}()})]})]})},N.name)})},m=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.modes,N=v.presets,V=v.emagged,B=v.mode,I=v.preset;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"System Mode",children:(0,e.createComponentVNode)(2,t.Table,{children:f.map(function(L){return(!L.emagonly||L.emagonly&&!!V)&&(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",width:1,children:(0,e.createComponentVNode)(2,t.Button,{content:L.name,icon:"cog",selected:L.id===B,onClick:function(){function w(){return g("mode",{mode:L.id})}return w}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:L.desc})]},L.name)})})}),(0,e.createComponentVNode)(2,t.Section,{title:"System Presets",children:[(0,e.createComponentVNode)(2,t.Box,{italic:!0,children:"After making a selection, the system will automatically cycle in order to remove contaminants."}),(0,e.createComponentVNode)(2,t.Table,{mt:1,children:N.map(function(L){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",width:1,children:(0,e.createComponentVNode)(2,t.Button,{content:L.name,icon:"cog",selected:L.id===I,onClick:function(){function w(){return g("preset",{preset:L.id})}return w}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:L.desc})]},L.name)})})]})],4)},l=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.thresholds;return(0,e.createComponentVNode)(2,t.Section,{title:"Alarm Thresholds",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{width:"20%",children:"Value"}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:"red",width:"20%",children:"Danger Min"}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:"orange",width:"20%",children:"Warning Min"}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:"orange",width:"20%",children:"Warning Max"}),(0,e.createComponentVNode)(2,t.Table.Cell,{color:"red",width:"20%",children:"Danger Max"})]}),f.map(function(N){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:N.name}),N.settings.map(function(V){return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:V.selected===-1?"Off":V.selected,onClick:function(){function B(){return g("command",{cmd:"set_threshold",env:V.env,var:V.val})}return B}()})},V.val)})]},N.name)})]})})}},12333:function(T,r,n){"use strict";r.__esModule=!0,r.AirlockAccessController=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AirlockAccessController=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.exterior_status,m=i.interior_status,l=i.processing,u,s;return c==="open"?u=(0,e.createComponentVNode)(2,t.Button,{width:"50%",content:"Lock Exterior Door",icon:"exclamation-triangle",disabled:l,onClick:function(){function d(){return h("force_ext")}return d}()}):u=(0,e.createComponentVNode)(2,t.Button,{width:"50%",content:"Cycle to Exterior",icon:"arrow-circle-left",disabled:l,onClick:function(){function d(){return h("cycle_ext_door")}return d}()}),m==="open"?s=(0,e.createComponentVNode)(2,t.Button,{width:"49%",content:"Lock Interior Door",icon:"exclamation-triangle",disabled:l,color:m==="open"?"red":l?"yellow":null,onClick:function(){function d(){return h("force_int")}return d}()}):s=(0,e.createComponentVNode)(2,t.Button,{width:"49%",content:"Cycle to Interior",icon:"arrow-circle-right",disabled:l,onClick:function(){function d(){return h("cycle_int_door")}return d}()}),(0,e.createComponentVNode)(2,o.Window,{width:330,height:200,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Information",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"External Door Status",children:c==="closed"?"Locked":"Open"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Internal Door Status",children:m==="closed"?"Locked":"Open"})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Actions",children:(0,e.createComponentVNode)(2,t.Box,{children:[u,s]})})]})})}return b}()},28736:function(T,r,n){"use strict";r.__esModule=!0,r.AirlockElectronics=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(49148),b=1,y=2,S=4,k=8,h=r.AirlockElectronics=function(){function m(l,u){return(0,e.createComponentVNode)(2,o.Window,{width:450,height:565,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c)]})})})}return m}(),i=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=C.unrestricted_dir;return(0,e.createComponentVNode)(2,t.Section,{title:"Access Control",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,mb:1,children:"Unrestricted Access From:"}),(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"arrow-left",content:"East",selected:g&S,onClick:function(){function v(){return d("unrestricted_access",{unres_dir:S})}return v}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"arrow-up",content:"South",selected:g&y,onClick:function(){function v(){return d("unrestricted_access",{unres_dir:y})}return v}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"arrow-right",content:"West",selected:g&k,onClick:function(){function v(){return d("unrestricted_access",{unres_dir:k})}return v}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"arrow-down",content:"North",selected:g&b,onClick:function(){function v(){return d("unrestricted_access",{unres_dir:b})}return v}()})})]})]})})},c=function(l,u){var s=(0,a.useBackend)(u),d=s.act,C=s.data,g=C.selected_accesses,v=C.one_access,f=C.regions;return(0,e.createComponentVNode)(2,p.AccessList,{usedByRcd:1,rcdButtons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:v,content:"One",onClick:function(){function N(){return d("set_one_access",{access:"one"})}return N}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!v,content:"All",onClick:function(){function N(){return d("set_one_access",{access:"all"})}return N}()})],4),accesses:f,selectedList:g,accessMod:function(){function N(V){return d("set",{access:V})}return N}(),grantAll:function(){function N(){return d("grant_all")}return N}(),denyAll:function(){function N(){return d("clear_all")}return N}(),grantDep:function(){function N(V){return d("grant_region",{region:V})}return N}(),denyDep:function(){function N(V){return d("deny_region",{region:V})}return N}()})}},47365:function(T,r,n){"use strict";r.__esModule=!0,r.AlertModal=void 0;var e=n(89005),a=n(51057),t=n(72253),o=n(92986),p=n(36036),b=n(98595),y=-1,S=1,k=r.AlertModal=function(){function c(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=d.autofocus,g=d.buttons,v=g===void 0?[]:g,f=d.large_buttons,N=d.message,V=N===void 0?"":N,B=d.timeout,I=d.title,L=(0,t.useLocalState)(l,"selected",0),w=L[0],A=L[1],x=110+(V.length>30?Math.ceil(V.length/4):0)+(V.length&&f?5:0),E=325+(v.length>2?100:0),P=function(){function D(M){w===0&&M===y?A(v.length-1):w===v.length-1&&M===S?A(0):A(w+M)}return D}();return(0,e.createComponentVNode)(2,b.Window,{title:I,height:x,width:E,children:[!!B&&(0,e.createComponentVNode)(2,a.Loader,{value:B}),(0,e.createComponentVNode)(2,b.Window.Content,{onKeyDown:function(){function D(M){var O=window.event?M.which:M.keyCode;O===o.KEY_SPACE||O===o.KEY_ENTER?s("choose",{choice:v[w]}):O===o.KEY_ESCAPE?s("cancel"):O===o.KEY_LEFT?(M.preventDefault(),P(y)):(O===o.KEY_TAB||O===o.KEY_RIGHT)&&(M.preventDefault(),P(S))}return D}(),children:(0,e.createComponentVNode)(2,p.Section,{fill:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,m:1,children:(0,e.createComponentVNode)(2,p.Box,{color:"label",overflow:"hidden",children:V})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:[!!C&&(0,e.createComponentVNode)(2,p.Autofocus),(0,e.createComponentVNode)(2,h,{selected:w})]})]})})})]})}return c}(),h=function(m,l){var u=(0,t.useBackend)(l),s=u.data,d=s.buttons,C=d===void 0?[]:d,g=s.large_buttons,v=s.swapped_buttons,f=m.selected;return(0,e.createComponentVNode)(2,p.Flex,{fill:!0,align:"center",direction:v?"row":"row-reverse",justify:"space-around",wrap:!0,children:C==null?void 0:C.map(function(N,V){return g&&C.length<3?(0,e.createComponentVNode)(2,p.Flex.Item,{grow:!0,children:(0,e.createComponentVNode)(2,i,{button:N,id:V.toString(),selected:f===V})},V):(0,e.createComponentVNode)(2,p.Flex.Item,{grow:g?1:0,children:(0,e.createComponentVNode)(2,i,{button:N,id:V.toString(),selected:f===V})},V)})})},i=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=d.large_buttons,g=m.button,v=m.selected,f=g.length>7?"100%":7;return(0,e.createComponentVNode)(2,p.Button,{mx:C?1:0,pt:C?.33:0,content:g,fluid:!!C,onClick:function(){function N(){return s("choose",{choice:g})}return N}(),selected:v,textAlign:"center",height:!!C&&2,width:!C&&f})}},71824:function(T,r,n){"use strict";r.__esModule=!0,r.AppearanceChanger=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AppearanceChanger=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.change_race,l=c.species,u=c.specimen,s=c.change_gender,d=c.gender,C=c.change_eye_color,g=c.change_skin_tone,v=c.change_skin_color,f=c.change_runechat_color,N=c.change_head_accessory_color,V=c.change_hair_color,B=c.change_secondary_hair_color,I=c.change_facial_hair_color,L=c.change_secondary_facial_hair_color,w=c.change_head_marking_color,A=c.change_body_marking_color,x=c.change_tail_marking_color,E=c.change_head_accessory,P=c.head_accessory_styles,D=c.head_accessory_style,M=c.change_hair,O=c.hair_styles,R=c.hair_style,F=c.change_hair_gradient,W=c.change_facial_hair,U=c.facial_hair_styles,z=c.facial_hair_style,$=c.change_head_markings,G=c.head_marking_styles,X=c.head_marking_style,J=c.change_body_markings,se=c.body_marking_styles,ie=c.body_marking_style,me=c.change_tail_markings,q=c.tail_marking_styles,re=c.tail_marking_style,ae=c.change_body_accessory,le=c.body_accessory_styles,Z=c.body_accessory_style,ne=c.change_alt_head,te=c.alt_head_styles,fe=c.alt_head_style,pe=!1;return(C||g||v||N||f||V||B||I||L||w||A||x)&&(pe=!0),(0,e.createComponentVNode)(2,o.Window,{width:800,height:450,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[!!m&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Species",children:l.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.specimen,selected:ce.specimen===u,onClick:function(){function Ve(){return i("race",{race:ce.specimen})}return Ve}()},ce.specimen)})}),!!s&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Gender",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Male",selected:d==="male",onClick:function(){function ce(){return i("gender",{gender:"male"})}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Female",selected:d==="female",onClick:function(){function ce(){return i("gender",{gender:"female"})}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Genderless",selected:d==="plural",onClick:function(){function ce(){return i("gender",{gender:"plural"})}return ce}()})]}),!!pe&&(0,e.createComponentVNode)(2,b),!!E&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Head accessory",children:P.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.headaccessorystyle,selected:ce.headaccessorystyle===D,onClick:function(){function Ve(){return i("head_accessory",{head_accessory:ce.headaccessorystyle})}return Ve}()},ce.headaccessorystyle)})}),!!M&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hair",children:O.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.hairstyle,selected:ce.hairstyle===R,onClick:function(){function Ve(){return i("hair",{hair:ce.hairstyle})}return Ve}()},ce.hairstyle)})}),!!F&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hair Gradient",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Change Style",onClick:function(){function ce(){return i("hair_gradient")}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Change Offset",onClick:function(){function ce(){return i("hair_gradient_offset")}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Change Color",onClick:function(){function ce(){return i("hair_gradient_colour")}return ce}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Change Alpha",onClick:function(){function ce(){return i("hair_gradient_alpha")}return ce}()})]}),!!W&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Facial hair",children:U.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.facialhairstyle,selected:ce.facialhairstyle===z,onClick:function(){function Ve(){return i("facial_hair",{facial_hair:ce.facialhairstyle})}return Ve}()},ce.facialhairstyle)})}),!!$&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Head markings",children:G.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.headmarkingstyle,selected:ce.headmarkingstyle===X,onClick:function(){function Ve(){return i("head_marking",{head_marking:ce.headmarkingstyle})}return Ve}()},ce.headmarkingstyle)})}),!!J&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Body markings",children:se.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.bodymarkingstyle,selected:ce.bodymarkingstyle===ie,onClick:function(){function Ve(){return i("body_marking",{body_marking:ce.bodymarkingstyle})}return Ve}()},ce.bodymarkingstyle)})}),!!me&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tail markings",children:q.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.tailmarkingstyle,selected:ce.tailmarkingstyle===re,onClick:function(){function Ve(){return i("tail_marking",{tail_marking:ce.tailmarkingstyle})}return Ve}()},ce.tailmarkingstyle)})}),!!ae&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Body accessory",children:le.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.bodyaccessorystyle,selected:ce.bodyaccessorystyle===Z,onClick:function(){function Ve(){return i("body_accessory",{body_accessory:ce.bodyaccessorystyle})}return Ve}()},ce.bodyaccessorystyle)})}),!!ne&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Alternate head",children:te.map(function(ce){return(0,e.createComponentVNode)(2,t.Button,{content:ce.altheadstyle,selected:ce.altheadstyle===fe,onClick:function(){function Ve(){return i("alt_head",{alt_head:ce.altheadstyle})}return Ve}()},ce.altheadstyle)})})]})})})}return y}(),b=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=[{key:"change_eye_color",text:"Change eye color",action:"eye_color"},{key:"change_skin_tone",text:"Change skin tone",action:"skin_tone"},{key:"change_skin_color",text:"Change skin color",action:"skin_color"},{key:"change_runechat_color",text:"Change runechat color",action:"runechat_color"},{key:"change_head_accessory_color",text:"Change head accessory color",action:"head_accessory_color"},{key:"change_hair_color",text:"Change hair color",action:"hair_color"},{key:"change_secondary_hair_color",text:"Change secondary hair color",action:"secondary_hair_color"},{key:"change_facial_hair_color",text:"Change facial hair color",action:"facial_hair_color"},{key:"change_secondary_facial_hair_color",text:"Change secondary facial hair color",action:"secondary_facial_hair_color"},{key:"change_head_marking_color",text:"Change head marking color",action:"head_marking_color"},{key:"change_body_marking_color",text:"Change body marking color",action:"body_marking_color"},{key:"change_tail_marking_color",text:"Change tail marking color",action:"tail_marking_color"}];return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Colors",children:m.map(function(l){return!!c[l.key]&&(0,e.createComponentVNode)(2,t.Button,{content:l.text,onClick:function(){function u(){return i(l.action)}return u}()},l.key)})})}},72285:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosAlertConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AtmosAlertConsole=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.priority||[],m=i.minor||[];return(0,e.createComponentVNode)(2,o.Window,{width:350,height:300,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Alarms",children:(0,e.createVNode)(1,"ul",null,[c.length===0&&(0,e.createVNode)(1,"li","color-good","No Priority Alerts",16),c.map(function(l){return(0,e.createVNode)(1,"li","color-bad",l,0,null,l)}),m.length===0&&(0,e.createVNode)(1,"li","color-good","No Minor Alerts",16),m.map(function(l){return(0,e.createVNode)(1,"li","color-average",l,0,null,l)})],0)})})})}return b}()},65805:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosControl=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(36352),p=n(98595),b=function(c){if(c===0)return(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Good"});if(c===1)return(0,e.createComponentVNode)(2,t.Box,{color:"orange",bold:!0,children:"Warning"});if(c===2)return(0,e.createComponentVNode)(2,t.Box,{color:"red",bold:!0,children:"DANGER"})},y=function(c){if(c===0)return"green";if(c===1)return"orange";if(c===2)return"red"},S=r.AtmosControl=function(){function i(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=(0,a.useLocalState)(m,"tabIndex",0),C=d[0],g=d[1],v=function(){function f(N){switch(N){case 0:return(0,e.createComponentVNode)(2,k);case 1:return(0,e.createComponentVNode)(2,h);default:return"WE SHOULDN'T BE HERE!"}}return f}();return(0,e.createComponentVNode)(2,p.Window,{width:800,height:600,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:C===0,children:(0,e.createComponentVNode)(2,t.Box,{fillPositionedParent:!0,children:[(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:C===0,onClick:function(){function f(){return g(0)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"table"})," Data View"]},"DataView"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:C===1,onClick:function(){function f(){return g(1)}return f}(),children:[(0,e.createComponentVNode)(2,t.Icon,{name:"map-marked-alt"})," Map View"]},"MapView")]}),v(C)]})})})}return i}(),k=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.alarms;return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Access"})]}),d.map(function(C){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,o.TableCell,{children:C.name}),(0,e.createComponentVNode)(2,o.TableCell,{children:b(C.danger)}),(0,e.createComponentVNode)(2,o.TableCell,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"cog",content:"Access",onClick:function(){function g(){return u("open_alarm",{aref:C.ref})}return g}()})})]},C.name)})]})})},h=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.alarms;return(0,e.createComponentVNode)(2,t.Box,{height:"526px",mb:"0.5rem",overflow:"hidden",children:(0,e.createComponentVNode)(2,t.NanoMap,{children:d.filter(function(C){return C.z===2}).map(function(C){return(0,e.createComponentVNode)(2,t.NanoMap.MarkerIcon,{x:C.x,y:C.y,icon:"circle",tooltip:C.name,color:y(C.danger),onClick:function(){function g(){return u("open_alarm",{aref:C.ref})}return g}()},C.ref)})})})}},87816:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosFilter=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AtmosFilter=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.on,m=i.pressure,l=i.max_pressure,u=i.filter_type,s=i.filter_type_list;return(0,e.createComponentVNode)(2,o.Window,{width:380,height:140,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:c?"On":"Off",color:c?null:"red",selected:c,onClick:function(){function d(){return h("power")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",textAlign:"center",disabled:m===0,width:2.2,onClick:function(){function d(){return h("min_pressure")}return d}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"kPa",width:6.1,lineHeight:1.5,step:10,minValue:0,maxValue:l,value:m,onDrag:function(){function d(C,g){return h("custom_pressure",{pressure:g})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",textAlign:"center",disabled:m===l,width:2.2,onClick:function(){function d(){return h("max_pressure")}return d}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Filter",children:s.map(function(d){return(0,e.createComponentVNode)(2,t.Button,{selected:d.gas_type===u,content:d.label,onClick:function(){function C(){return h("set_filter",{filter:d.gas_type})}return C}()},d.label)})})]})})})})}return b}()},52977:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosMixer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AtmosMixer=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.on,l=c.pressure,u=c.max_pressure,s=c.node1_concentration,d=c.node2_concentration;return(0,e.createComponentVNode)(2,o.Window,{width:330,height:165,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:m?"On":"Off",color:m?null:"red",selected:m,onClick:function(){function C(){return i("power")}return C}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",textAlign:"center",disabled:l===0,width:2.2,onClick:function(){function C(){return i("min_pressure")}return C}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"kPa",width:6.1,lineHeight:1.5,step:10,minValue:0,maxValue:u,value:l,onDrag:function(){function C(g,v){return i("custom_pressure",{pressure:v})}return C}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",textAlign:"center",disabled:l===u,width:2.2,onClick:function(){function C(){return i("max_pressure")}return C}()})]}),(0,e.createComponentVNode)(2,b,{node_name:"Node 1",node_ref:s}),(0,e.createComponentVNode)(2,b,{node_name:"Node 2",node_ref:d})]})})})})}return y}(),b=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=S.node_name,l=S.node_ref;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:m,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",textAlign:"center",width:2.2,disabled:l===0,onClick:function(){function u(){return i("set_node",{node_name:m,concentration:(l-10)/100})}return u}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"%",width:6.1,lineHeight:1.5,stepPixelSize:10,minValue:0,maxValue:100,value:l,onChange:function(){function u(s,d){return i("set_node",{node_name:m,concentration:d/100})}return u}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",textAlign:"center",width:2.2,disabled:l===100,onClick:function(){function u(){return i("set_node",{node_name:m,concentration:(l+10)/100})}return u}()})]})}},11748:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosPump=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.AtmosPump=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.on,m=i.rate,l=i.max_rate,u=i.gas_unit,s=i.step;return(0,e.createComponentVNode)(2,o.Window,{width:330,height:110,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:c?"On":"Off",color:c?null:"red",selected:c,onClick:function(){function d(){return h("power")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",textAlign:"center",disabled:m===0,width:2.2,onClick:function(){function d(){return h("min_rate")}return d}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:u,width:6.1,lineHeight:1.5,step:s,minValue:0,maxValue:l,value:m,onDrag:function(){function d(C,g){return h("custom_rate",{rate:g})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",textAlign:"center",disabled:m===l,width:2.2,onClick:function(){function d(){return h("max_rate")}return d}()})]})]})})})})}return b}()},69321:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosTankControl=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(44879),p=n(76910),b=n(98595),y=r.AtmosTankControl=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.sensors||{};return(0,e.createComponentVNode)(2,b.Window,{width:400,height:400,children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:[Object.keys(l).map(function(u){return(0,e.createComponentVNode)(2,t.Section,{title:u,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[Object.keys(l[u]).indexOf("pressure")>-1?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Pressure",children:[l[u].pressure," kpa"]}):"",Object.keys(l[u]).indexOf("temperature")>-1?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",children:[l[u].temperature," K"]}):"",["o2","n2","plasma","co2","n2o"].map(function(s){return Object.keys(l[u]).indexOf(s)>-1?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:(0,p.getGasLabel)(s),children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:(0,p.getGasColor)(s),value:l[u][s],minValue:0,maxValue:100,children:(0,o.toFixed)(l[u][s],2)+"%"})},(0,p.getGasLabel)(s)):""})]})},u)}),m.inlet&&Object.keys(m.inlet).length>0?(0,e.createComponentVNode)(2,t.Section,{title:"Inlet Control",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:(m.inlet.on,"power-off"),content:m.inlet.on?"On":"Off",color:m.inlet.on?null:"red",selected:m.inlet.on,onClick:function(){function u(){return c("toggle_active",{dev:"inlet"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"L/s",width:6.1,lineHeight:1.5,step:1,minValue:0,maxValue:50,value:m.inlet.rate,onDrag:function(){function u(s,d){return c("set_pressure",{dev:"inlet",val:d})}return u}()})})]})}):"",m.outlet&&Object.keys(m.outlet).length>0?(0,e.createComponentVNode)(2,t.Section,{title:"Outlet Control",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:(m.outlet.on,"power-off"),content:m.outlet.on?"On":"Off",color:m.outlet.on?null:"red",selected:m.outlet.on,onClick:function(){function u(){return c("toggle_active",{dev:"outlet"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rate",children:(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,unit:"kPa",width:6.1,lineHeight:1.5,step:10,minValue:0,maxValue:5066,value:m.outlet.rate,onDrag:function(){function u(s,d){return c("set_pressure",{dev:"outlet",val:d})}return u}()})})]})}):""]})})}return S}()},92444:function(T,r,n){"use strict";r.__esModule=!0,r.AugmentMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(25328),b=r.AugmentMenu=function(){function k(h,i){return(0,e.createComponentVNode)(2,o.Window,{width:700,height:660,theme:"malfunction",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:(0,e.createComponentVNode)(2,y,{context:i})})})})}return k}(),y=function(h){var i=h.context,c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.usable_swarms,s=l.ability_tabs,d=l.known_abilities,C=(0,a.useLocalState)(i,"selectedTab",s[0]),g=C[0],v=C[1],f=(0,a.useLocalState)(i,"searchText",""),N=f[0],V=f[1],B=function(){var E=s.find(function(D){return D.category_name===g.category_name});if(!E)return[];var P=Math.min(E.category_stage,4);return E.abilities.filter(function(D){return D.stage<=P&&(!N||D.name.toLowerCase().includes(N.toLowerCase()))}).sort(function(D,M){return["intruder","destroyer"].includes(g.category_name.toLowerCase())?D.stage-M.stage:0})},I=B(),L=s.find(function(x){return x.category_name===g.category_name}),w=["intruder","destroyer"].includes(g.category_name.toLowerCase()),A=function(E){var P=d.find(function(O){return O.ability_path===E.ability_path}),D=P?P.cost:E.cost,M=P&&P.current_level>0?P.current_level+" / "+P.max_level:"0 / "+E.max_level;return(0,e.createComponentVNode)(2,t.Stack.Item,{direction:"row",children:[(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Button,{height:"20px",width:"35px",mb:1,textAlign:"center",content:D,disabled:D>u||P&&P.current_level===P.max_level,tooltip:"Purchase this ability?",onClick:function(){function O(){m("purchase",{ability_path:E.ability_path}),v(g)}return O}()}),(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"16px",children:E.name})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"13px",children:E.desc||"Description not available"}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:["Level: ",(0,e.createVNode)(1,"span",null,M,0,{style:{color:"green"}}),w&&E.stage>0&&(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)(" (Stage: "),E.stage,(0,e.createTextVNode)(")")],0)]}),(0,e.createComponentVNode)(2,t.Stack.Divider)]})})]},E.name)};return(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createVNode)(1,"div",null,[(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,style:{marginRight:"10px"},children:[(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("Swarms: "),(0,e.createVNode)(1,"span",null,u,0,{style:{color:"green"}})],4),w&&L&&(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)("Category Stage: "),(0,e.createVNode)(1,"span",null,Math.min(L.category_stage,4),0,{style:{color:"green"}})],4)]}),(0,e.createVNode)(1,"div","Section__buttons",(0,e.createComponentVNode)(2,t.Input,{width:"200px",placeholder:"Search Abilities",onInput:function(){function x(E,P){return V(P)}return x}(),value:N}),2)],4,{style:{display:"flex",alignItems:"center"}}),children:[(0,e.createComponentVNode)(2,t.Tabs,{children:[s.map(function(x){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g.category_name===x.category_name,onClick:function(){function E(){v(x),V("")}return E}(),children:(0,p.capitalize)(x.category_name)},x.category_name)}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:g.category_name==="upgrades",onClick:function(){function x(){return v({category_name:"upgrades"})}return x}(),children:"Upgrades"},"upgrades")]}),g.category_name==="upgrades"?(0,e.createComponentVNode)(2,S,{act:m,abilityTabs:s,knownAbilities:d,usableSwarms:u}):(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:I.map(A)})]})},S=function(h){var i=h.act,c=h.abilityTabs,m=h.knownAbilities,l=h.usableSwarms,u=m.filter(function(d){return d.current_levell,tooltip:"Upgrade this ability?",onClick:function(){function v(){return i("purchase",{ability_path:C.ability_path})}return v}()}),(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"16px",children:C.name})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"13px",children:C.upgrade_text}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:["Level:"," ",(0,e.createVNode)(1,"span",null,C.current_level+" / "+C.max_level,0,{style:{color:"green"}}),g&&g.stage>0&&(0,e.createVNode)(1,"span",null,[(0,e.createTextVNode)(" (Stage: "),g.stage,(0,e.createTextVNode)(")")],0)]}),(0,e.createComponentVNode)(2,t.Stack.Divider)]})})]},C.name)};return(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:u.map(s)})}},59179:function(T,r,n){"use strict";r.__esModule=!0,r.Autolathe=void 0;var e=n(89005),a=n(64795),t=n(88510),o=n(72253),p=n(36036),b=n(98595),y=n(25328),S=function(i,c,m,l){return i.requirements===null?!0:!(i.requirements.metal*l>c||i.requirements.glass*l>m)},k=r.Autolathe=function(){function h(i,c){var m=(0,o.useBackend)(c),l=m.act,u=m.data,s=u.total_amount,d=u.max_amount,C=u.metal_amount,g=u.glass_amount,v=u.busyname,f=u.busyamt,N=u.showhacked,V=u.buildQueue,B=u.buildQueueLen,I=u.recipes,L=u.categories,w=(0,o.useSharedState)(c,"category",0),A=w[0],x=w[1];A===0&&(A="Tools");var E=C.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,"),P=g.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,"),D=s.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,"),M=(0,o.useSharedState)(c,"search_text",""),O=M[0],R=M[1],F=(0,y.createSearch)(O,function($){return $.name}),W="";B>0&&(W=V.map(function($,G){return(0,e.createComponentVNode)(2,p.Box,{children:(0,e.createComponentVNode)(2,p.Button,{fluid:!0,icon:"times",color:"transparent",content:V[G][0],onClick:function(){function X(){return l("remove_from_queue",{remove_from_queue:V.indexOf($)+1})}return X}()},$)},G)}));var U=(0,a.flow)([(0,t.filter)(function($){return($.category.indexOf(A)>-1||O)&&(u.showhacked||!$.hacked)}),O&&(0,t.filter)(F),(0,t.sortBy)(function($){return $.name.toLowerCase()})])(I),z="Build";return O?z="Results for: '"+O+"':":A&&(z="Build ("+A+")"),(0,e.createComponentVNode)(2,b.Window,{width:750,height:525,children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,horizontal:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{width:"70%",children:(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,title:z,buttons:(0,e.createComponentVNode)(2,p.Dropdown,{width:"150px",options:L,selected:A,onSelected:function(){function $(G){return x(G)}return $}()}),children:[(0,e.createComponentVNode)(2,p.Input,{fluid:!0,placeholder:"Search for...",onInput:function(){function $(G,X){return R(X)}return $}(),mb:1}),U.map(function($){return(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:[(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+$.image,style:{"vertical-align":"middle",width:"32px",margin:"0px","margin-left":"0px"}}),(0,e.createComponentVNode)(2,p.Button,{mr:1,icon:"hammer",selected:u.busyname===$.name&&u.busyamt===1,disabled:!S($,u.metal_amount,u.glass_amount,1),onClick:function(){function G(){return l("make",{make:$.uid,multiplier:1})}return G}(),children:(0,y.toTitleCase)($.name)}),$.max_multiplier>=10&&(0,e.createComponentVNode)(2,p.Button,{mr:1,icon:"hammer",selected:u.busyname===$.name&&u.busyamt===10,disabled:!S($,u.metal_amount,u.glass_amount,10),onClick:function(){function G(){return l("make",{make:$.uid,multiplier:10})}return G}(),children:"10x"}),$.max_multiplier>=25&&(0,e.createComponentVNode)(2,p.Button,{mr:1,icon:"hammer",selected:u.busyname===$.name&&u.busyamt===25,disabled:!S($,u.metal_amount,u.glass_amount,25),onClick:function(){function G(){return l("make",{make:$.uid,multiplier:25})}return G}(),children:"25x"}),$.max_multiplier>25&&(0,e.createComponentVNode)(2,p.Button,{mr:1,icon:"hammer",selected:u.busyname===$.name&&u.busyamt===$.max_multiplier,disabled:!S($,u.metal_amount,u.glass_amount,$.max_multiplier),onClick:function(){function G(){return l("make",{make:$.uid,multiplier:$.max_multiplier})}return G}(),children:[$.max_multiplier,"x"]}),$.requirements&&Object.keys($.requirements).map(function(G){return(0,y.toTitleCase)(G)+": "+$.requirements[G]}).join(", ")||(0,e.createComponentVNode)(2,p.Box,{children:"No resources required."})]},$.ref)})]})}),(0,e.createComponentVNode)(2,p.Stack.Item,{width:"30%",children:[(0,e.createComponentVNode)(2,p.Section,{title:"Materials",children:(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Metal",children:E}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Glass",children:P}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Total",children:D}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Storage",children:[u.fill_percent,"% Full"]})]})}),(0,e.createComponentVNode)(2,p.Section,{title:"Building",children:(0,e.createComponentVNode)(2,p.Box,{color:v?"green":"",children:v||"Nothing"})}),(0,e.createComponentVNode)(2,p.Section,{title:"Build Queue",height:23.7,children:[W,(0,e.createComponentVNode)(2,p.Button,{mt:.5,fluid:!0,icon:"times",content:"Clear All",color:"red",disabled:!u.buildQueueLen,onClick:function(){function $(){return l("clear_queue")}return $}()})]})]})]})})})}return h}()},5147:function(T,r,n){"use strict";r.__esModule=!0,r.BioChipPad=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.BioChipPad=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.implant,m=i.contains_case,l=i.gps,u=i.tag,s=(0,a.useLocalState)(S,"newTag",u),d=s[0],C=s[1];return(0,e.createComponentVNode)(2,o.Window,{width:410,height:325,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Bio-chip Mini-Computer",buttons:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Eject Case",icon:"eject",disabled:!m,onClick:function(){function g(){return h("eject_case")}return g}()})}),children:c&&m?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{bold:!0,mb:2,children:[(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+c.image,ml:0,mr:2,style:{"vertical-align":"middle",width:"32px"}}),c.name]}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Life",children:c.life}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Notes",children:c.notes}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Function",children:c.function}),!!l&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tag",children:[(0,e.createComponentVNode)(2,t.Input,{width:"5.5rem",value:u,onEnter:function(){function g(){return h("tag",{newtag:d})}return g}(),onInput:function(){function g(v,f){return C(f)}return g}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:u===d,width:"20px",mb:"0",ml:"0.25rem",onClick:function(){function g(){return h("tag",{newtag:d})}return g}(),children:(0,e.createComponentVNode)(2,t.Icon,{name:"pen"})})]})]})],4):m?(0,e.createComponentVNode)(2,t.Box,{children:"This bio-chip case has no implant!"}):(0,e.createComponentVNode)(2,t.Box,{children:"Please insert a bio-chip casing!"})})})})}return b}()},64273:function(T,r,n){"use strict";r.__esModule=!0,r.Biogenerator=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(62411),b=r.Biogenerator=function(){function i(c,m){var l=(0,a.useBackend)(m),u=l.data,s=l.config,d=u.container,C=u.processing,g=s.title;return(0,e.createComponentVNode)(2,o.Window,{width:390,height:595,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Operating,{operating:C,name:g}),(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k),d?(0,e.createComponentVNode)(2,h):(0,e.createComponentVNode)(2,y)]})})})}return i}(),y=function(c,m){return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"silver",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"flask",size:5,mb:"10px"}),(0,e.createVNode)(1,"br"),"The biogenerator is missing a container."]})})})},S=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.biomass,C=s.container,g=s.container_curr_reagents,v=s.container_max_reagents;return(0,e.createComponentVNode)(2,t.Section,{title:"Storage",children:[(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{mr:"20px",color:"silver",children:"Biomass:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{mr:"5px",children:d}),(0,e.createComponentVNode)(2,t.Icon,{name:"leaf",size:1.2,color:"#3d8c40"})]}),(0,e.createComponentVNode)(2,t.Stack,{height:"21px",mt:"8px",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{mr:"10px",color:"silver",children:"Container:"}),C?(0,e.createComponentVNode)(2,t.ProgressBar,{value:g,maxValue:v,children:(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",children:g+" / "+v+" units"})}):(0,e.createComponentVNode)(2,t.Stack.Item,{children:"None"})]})]})},k=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.has_plants,C=s.container;return(0,e.createComponentVNode)(2,t.Section,{title:"Controls",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"power-off",disabled:!d,tooltip:d?"":"There are no plants in the biogenerator.",tooltipPosition:"top-start",content:"Activate",onClick:function(){function g(){return u("activate")}return g}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"40%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"flask",disabled:!C,tooltip:C?"":"The biogenerator does not have a container.",tooltipPosition:"top",content:"Detach Container",onClick:function(){function g(){return u("detach_container")}return g}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"eject",disabled:!d,tooltip:d?"":"There are no stored plants to eject.",tooltipPosition:"top-end",content:"Eject Plants",onClick:function(){function g(){return u("eject_plants")}return g}()})})]})})},h=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.biomass,C=s.product_list,g=(0,a.useSharedState)(m,"vendAmount",1),v=g[0],f=g[1],N=Object.entries(C).map(function(V,B){var I=Object.entries(V[1]).map(function(L){return L[1]});return(0,e.createComponentVNode)(2,t.Collapsible,{title:V[0],open:!0,children:I.map(function(L){return(0,e.createComponentVNode)(2,t.Stack,{py:"2px",className:"candystripe",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"50%",ml:"2px",children:L.name}),(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"right",width:"20%",children:[L.cost*v,(0,e.createComponentVNode)(2,t.Icon,{ml:"5px",name:"leaf",size:1.2,color:"#3d8c40"})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"right",width:"40%",children:(0,e.createComponentVNode)(2,t.Button,{content:"Vend",disabled:d.25?750+400*Math.random():290+150*Math.random(),time:60+150*Math.random(),children:(0,e.createComponentVNode)(2,t.Stack,{mb:"30px",fontsize:"256px",children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,color:"red",fontsize:"256px",textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"skull",size:14,mb:"64px"}),(0,e.createVNode)(1,"br"),"E$#OR:& U#KN!WN IN%ERF#R_NCE"]})})})})}return k}(),y=r.BluespaceTap=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.product||[],s=l.desiredMiningPower,d=l.miningPower,C=l.points,g=l.totalPoints,v=l.powerUse,f=l.availablePower,N=l.emagged,V=l.autoShutown,B=l.stabilizers,I=l.stabilizerPower,L=l.stabilizerPriority,w=s>d&&"bad"||"good";return(0,e.createComponentVNode)(2,o.Window,{width:650,height:450,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,t.Collapsible,{title:"Input Management",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Input",children:[(0,e.createComponentVNode)(2,t.Button,{icon:V&&!N?"toggle-on":"toggle-off",content:"Auto shutdown",color:V&&!N?"green":"red",disabled:!!N,tooltip:"Turn auto shutdown on or off",tooltipPosition:"top",onClick:function(){function A(){return m("auto_shutdown")}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:B&&!N?"toggle-on":"toggle-off",content:"Stabilizers",color:B&&!N?"green":"red",disabled:!!N,tooltip:"Turn stabilizers on or off",tooltipPosition:"top",onClick:function(){function A(){return m("stabilizers")}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:L&&!N?"toggle-on":"toggle-off",content:"Stabilizer priority",color:L&&!N?"green":"red",disabled:!!N,tooltip:"On: Mining power will not exceed what can be stabilized",tooltipPosition:"top",onClick:function(){function A(){return m("stabilizer_priority")}return A}()}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Desired Mining Power",children:(0,p.formatPower)(s)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{labelStyle:{"vertical-align":"top"},label:"Set Desired Mining Power",children:(0,e.createComponentVNode)(2,t.Stack,{width:"100%",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"step-backward",disabled:s===0||N,tooltip:"Set to 0",tooltipPosition:"bottom",onClick:function(){function A(){return m("set",{set_power:0})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",tooltip:"Decrease by 10 MW",tooltipPosition:"bottom",disabled:s===0||N,onClick:function(){function A(){return m("set",{set_power:s-1e7})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"backward",disabled:s===0||N,tooltip:"Decrease by 1 MW",tooltipPosition:"bottom",onClick:function(){function A(){return m("set",{set_power:s-1e6})}return A}()})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{mx:1,children:(0,e.createComponentVNode)(2,t.NumberInput,{disabled:N,minvalue:0,value:s,maxvalue:1/0,step:1,onChange:function(){function A(x,E){return m("set",{set_power:E})}return A}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"forward",disabled:N,tooltip:"Increase by one MW",tooltipPosition:"bottom",onClick:function(){function A(){return m("set",{set_power:s+1e6})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",disabled:N,tooltip:"Increase by 10MW",tooltipPosition:"bottom",onClick:function(){function A(){return m("set",{set_power:s+1e7})}return A}()})]})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Total Power Use",children:(0,p.formatPower)(v)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mining Power Use",children:(0,p.formatPower)(d)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Stabilizer Power Use",children:(0,p.formatPower)(I)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Surplus Power",children:(0,p.formatPower)(f)})]})]})}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Output",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Available Points",children:C}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Total Points",children:g})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{align:"end",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:u.map(function(A){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:A.name,children:(0,e.createComponentVNode)(2,t.Button,{disabled:A.price>=C,onClick:function(){function x(){return m("vend",{target:A.key})}return x}(),content:A.price})},A.key)})})})})]})})]})})})}return k}(),S=r.Alerts=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.product||[],s=l.miningPower,d=l.stabilizerPower,C=l.emagged,g=l.safeLevels,v=l.autoShutown,f=l.stabilizers,N=l.overhead;return(0,e.createFragment)([!v&&!C&&(0,e.createComponentVNode)(2,t.NoticeBox,{danger:1,children:"Auto shutdown disabled"}),C?(0,e.createComponentVNode)(2,t.NoticeBox,{danger:1,children:"All safeties disabled"}):s<=15e6?"":f?s>d+15e6?(0,e.createComponentVNode)(2,t.NoticeBox,{danger:1,children:"Stabilizers overwhelmed, Instability likely"}):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"High Power, engaging stabilizers"}):(0,e.createComponentVNode)(2,t.NoticeBox,{danger:1,children:"Stabilizers disabled, Instability likely"})],0)}return k}()},33758:function(T,r,n){"use strict";r.__esModule=!0,r.BodyScanner=void 0;var e=n(89005),a=n(44879),t=n(25328),o=n(72253),p=n(36036),b=n(98595),y=[["good","Alive"],["average","Critical"],["bad","DEAD"]],S=[["hasVirus","bad","Viral pathogen detected in blood stream."],["blind","average","Cataracts detected."],["colourblind","average","Photoreceptor abnormalities detected."],["nearsighted","average","Retinal misalignment detected."]],k=[["Respiratory","oxyLoss"],["Brain","brainLoss"],["Toxin","toxLoss"],["Radiation","radLoss"],["Brute","bruteLoss"],["Cellular","cloneLoss"],["Burn","fireLoss"],["Inebriation","drunkenness"]],h={average:[.25,.5],bad:[.5,1/0]},i=function(B,I){for(var L=[],w=0;w0?B.filter(function(I){return!!I}).reduce(function(I,L){return(0,e.createFragment)([I,(0,e.createComponentVNode)(2,p.Box,{children:L},L)],0)},null):null},m=function(B){if(B>100){if(B<300)return"mild infection";if(B<400)return"mild infection+";if(B<500)return"mild infection++";if(B<700)return"acute infection";if(B<800)return"acute infection+";if(B<900)return"acute infection++";if(B>=900)return"septic"}return""},l=r.BodyScanner=function(){function V(B,I){var L=(0,o.useBackend)(I),w=L.data,A=w.occupied,x=w.occupant,E=x===void 0?{}:x,P=A?(0,e.createComponentVNode)(2,u,{occupant:E}):(0,e.createComponentVNode)(2,N);return(0,e.createComponentVNode)(2,b.Window,{width:700,height:600,title:"Body Scanner",children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:P})})}return V}(),u=function(B){var I=B.occupant;return(0,e.createComponentVNode)(2,p.Box,{children:[(0,e.createComponentVNode)(2,s,{occupant:I}),(0,e.createComponentVNode)(2,d,{occupant:I}),(0,e.createComponentVNode)(2,C,{occupant:I}),(0,e.createComponentVNode)(2,v,{organs:I.extOrgan}),(0,e.createComponentVNode)(2,f,{organs:I.intOrgan})]})},s=function(B,I){var L=(0,o.useBackend)(I),w=L.act,A=L.data,x=A.occupant;return(0,e.createComponentVNode)(2,p.Section,{title:"Occupant",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Button,{icon:"print",onClick:function(){function E(){return w("print_p")}return E}(),children:"Print Report"}),(0,e.createComponentVNode)(2,p.Button,{icon:"user-slash",onClick:function(){function E(){return w("ejectify")}return E}(),children:"Eject"})],4),children:(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Name",children:x.name}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:x.maxHealth,value:x.health/x.maxHealth,ranges:{good:[.5,1/0],average:[0,.5],bad:[-1/0,0]}})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Status",color:y[x.stat][0],children:y[x.stat][1]}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Temperature",children:[(0,e.createComponentVNode)(2,p.AnimatedNumber,{value:(0,a.round)(x.bodyTempC)}),"\xB0C,\xA0",(0,e.createComponentVNode)(2,p.AnimatedNumber,{value:(0,a.round)(x.bodyTempF)}),"\xB0F"]}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Implants",children:x.implant_len?(0,e.createComponentVNode)(2,p.Box,{children:x.implant.map(function(E){return E.name}).join(", ")}):(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"None"})})]})})},d=function(B){var I=B.occupant;return I.hasBorer||I.blind||I.colourblind||I.nearsighted||I.hasVirus?(0,e.createComponentVNode)(2,p.Section,{title:"Abnormalities",children:S.map(function(L,w){if(I[L[0]])return(0,e.createComponentVNode)(2,p.Box,{color:L[1],bold:L[1]==="bad",children:L[2]},L[2])})}):(0,e.createComponentVNode)(2,p.Section,{title:"Abnormalities",children:(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"No abnormalities found."})})},C=function(B){var I=B.occupant;return(0,e.createComponentVNode)(2,p.Section,{title:"Damage",children:(0,e.createComponentVNode)(2,p.Table,{children:i(k,function(L,w,A){return(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Table.Row,{color:"label",children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:[L[0],":"]}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:!!w&&w[0]+":"})]}),(0,e.createComponentVNode)(2,p.Table.Row,{children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:(0,e.createComponentVNode)(2,g,{value:I[L[1]],marginBottom:A100)&&"average"||!!I.status.robotic&&"label",width:"33%",children:(0,t.capitalize)(I.name)}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,p.ProgressBar,{m:-.5,min:"0",max:I.maxHealth,mt:L>0&&"0.5rem",value:I.totalLoss/I.maxHealth,ranges:h,children:(0,e.createComponentVNode)(2,p.Stack,{children:[(0,e.createComponentVNode)(2,p.Tooltip,{content:"Total damage",children:(0,e.createComponentVNode)(2,p.Stack.Item,{children:[(0,e.createComponentVNode)(2,p.Icon,{name:"heartbeat",mr:.5}),(0,a.round)(I.totalLoss)]})}),!!I.bruteLoss&&(0,e.createComponentVNode)(2,p.Tooltip,{content:"Brute damage",children:(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:[(0,e.createComponentVNode)(2,p.Icon,{name:"bone",mr:.5}),(0,a.round)(I.bruteLoss)]})}),!!I.fireLoss&&(0,e.createComponentVNode)(2,p.Tooltip,{content:"Burn damage",children:(0,e.createComponentVNode)(2,p.Stack.Item,{children:[(0,e.createComponentVNode)(2,p.Icon,{name:"fire",mr:.5}),(0,a.round)(I.fireLoss)]})})]})})}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"right",verticalAlign:"top",width:"33%",pt:L>0&&"calc(0.5rem + 2px)",children:[(0,e.createComponentVNode)(2,p.Box,{color:"average",inline:!0,children:c([!!I.internalBleeding&&"Internal bleeding",!!I.burnWound&&"Critical tissue burns",!!I.lungRuptured&&"Ruptured lung",!!I.status.broken&&I.status.broken,m(I.germ_level),!!I.open&&"Open incision"])}),(0,e.createComponentVNode)(2,p.Box,{inline:!0,children:[c([!!I.status.splinted&&(0,e.createComponentVNode)(2,p.Box,{color:"good",children:"Splinted"}),!!I.status.robotic&&(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"Robotic"}),!!I.status.dead&&(0,e.createComponentVNode)(2,p.Box,{color:"bad",bold:!0,children:"DEAD"})]),c(I.shrapnel.map(function(w){return w.known?w.name:"Unknown object"}))]})]})]},L)})]})})},f=function(B){return B.organs.length===0?(0,e.createComponentVNode)(2,p.Section,{title:"Internal Organs",children:(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"N/A"})}):(0,e.createComponentVNode)(2,p.Section,{title:"Internal Organs",children:(0,e.createComponentVNode)(2,p.Table,{children:[(0,e.createComponentVNode)(2,p.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"center",children:"Damage"}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"right",children:"Injuries"})]}),B.organs.map(function(I,L){return(0,e.createComponentVNode)(2,p.Table.Row,{children:[(0,e.createComponentVNode)(2,p.Table.Cell,{color:!!I.dead&&"bad"||I.germ_level>100&&"average"||I.robotic>0&&"label",width:"33%",children:(0,t.capitalize)(I.name)}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:I.maxHealth,value:I.damage/I.maxHealth,mt:L>0&&"0.5rem",ranges:h,children:(0,a.round)(I.damage)})}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"right",verticalAlign:"top",width:"33%",pt:L>0&&"calc(0.5rem + 2px)",children:[(0,e.createComponentVNode)(2,p.Box,{color:"average",inline:!0,children:c([m(I.germ_level)])}),(0,e.createComponentVNode)(2,p.Box,{inline:!0,children:c([I.robotic===1&&(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"Robotic"}),I.robotic===2&&(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"Assisted"}),!!I.dead&&(0,e.createComponentVNode)(2,p.Box,{color:"bad",bold:!0,children:"DEAD"})])})]})]},L)})]})})},N=function(){return(0,e.createComponentVNode)(2,p.Section,{fill:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,p.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No occupant detected."]})})})}},67963:function(T,r,n){"use strict";r.__esModule=!0,r.BookBinder=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=n(39473),y=r.BookBinder=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.selectedbook,u=m.book_categories,s=[];return u.map(function(d){return s[d.description]=d.category_id}),(0,e.createComponentVNode)(2,o.Window,{width:600,height:400,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Book Binder",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"print",width:"auto",content:"Print Book",onClick:function(){function d(){return c("print_book")}return d}()}),children:[(0,e.createComponentVNode)(2,t.Box,{ml:10,fontSize:"1.2rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"search-plus",verticalAlign:"middle",size:3,mr:"1rem"}),"Book Binder"]}),(0,e.createComponentVNode)(2,t.Stack,{children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,t.Button,{textAlign:"left",icon:"pen",width:"auto",content:l.title,onClick:function(){function d(){return(0,p.modalOpen)(h,"edit_selected_title")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:(0,e.createComponentVNode)(2,t.Button,{textAlign:"left",icon:"pen",width:"auto",content:l.author,onClick:function(){function d(){return(0,p.modalOpen)(h,"edit_selected_author")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Categories",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Dropdown,{width:"190px",options:u.map(function(d){return d.description}),onSelected:function(){function d(C){return c("toggle_binder_category",{category_id:s[C]})}return d}()})})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Summary",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pen",width:"auto",content:"Edit Summary",onClick:function(){function d(){return(0,p.modalOpen)(h,"edit_selected_summary")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:l.summary})]}),(0,e.createVNode)(1,"br"),u.filter(function(d){return l.categories.includes(d.category_id)}).map(function(d){return(0,e.createComponentVNode)(2,t.Button,{content:d.description,selected:!0,icon:"unlink",onClick:function(){function C(){return c("toggle_binder_category",{category_id:d.category_id})}return C}()},d.category_id)})]})})]})})})]})}return S}()},61925:function(T,r,n){"use strict";r.__esModule=!0,r.BotCall=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(i){var c=[{modes:[0],label:"Idle",color:"green"},{modes:[1,2,3],label:"Arresting",color:"yellow"},{modes:[4,5],label:"Patrolling",color:"average"},{modes:[9],label:"Moving",color:"average"},{modes:[6,11],label:"Responding",color:"green"},{modes:[12],label:"Delivering Cargo",color:"blue"},{modes:[13],label:"Returning Home",color:"blue"},{modes:[7,8,10,14,15,16,17,18,19],label:"Working",color:"blue"}],m=c.find(function(l){return l.modes.includes(i)});return(0,e.createComponentVNode)(2,t.Box,{color:m.color,children:[" ",m.label," "]})},b=r.BotCall=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=(0,a.useLocalState)(c,"tabIndex",0),d=s[0],C=s[1],g={0:"Security",1:"Medibot",2:"Cleanbot",3:"Floorbot",4:"Mule",5:"Honkbot"},v=function(){function f(N){return g[N]?(0,e.createComponentVNode)(2,y,{model:g[N]}):"This should not happen. Report on Paradise Github"}return f}();return(0,e.createComponentVNode)(2,o.Window,{width:700,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:d===0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Tabs,{fluid:!0,textAlign:"center",children:Array.from({length:6}).map(function(f,N){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:d===N,onClick:function(){function V(){return C(N)}return V}(),children:g[N]},N)})})}),v(d)]})})})}return h}(),y=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.bots;return s[i.model]!==void 0?(0,e.createComponentVNode)(2,k,{model:[i.model]}):(0,e.createComponentVNode)(2,S,{model:[i.model]})},S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data;return(0,e.createComponentVNode)(2,t.Stack,{justify:"center",align:"center",fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Box,{bold:1,color:"bad",children:["No ",[i.model]," detected"]})})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.bots;return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Model"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Location"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Interface"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Call"})]}),s[i.model].map(function(d){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.model}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.on?p(d.status):(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Off"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.location}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Interface",onClick:function(){function C(){return l("interface",{botref:d.UID})}return C}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Call",onClick:function(){function C(){return l("call",{botref:d.UID})}return C}()})})]},d.UID)})]})})})}},20464:function(T,r,n){"use strict";r.__esModule=!0,r.BotClean=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotClean=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.locked,l=c.noaccess,u=c.maintpanel,s=c.on,d=c.autopatrol,C=c.canhack,g=c.emagged,v=c.remote_disabled,f=c.painame,N=c.cleanblood,V=c.area;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,p.BotStatus),(0,e.createComponentVNode)(2,t.Section,{title:"Cleaning Settings",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:N,content:"Clean Blood",disabled:l,onClick:function(){function B(){return i("blood")}return B}()})}),(0,e.createComponentVNode)(2,t.Section,{title:"Misc Settings",children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:V?"Reset Area Selection":"Restrict to Current Area",onClick:function(){function B(){return i("area")}return B}()}),V!==null&&(0,e.createComponentVNode)(2,t.LabeledList,{mb:1,children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Locked Area",children:V})})]}),f&&(0,e.createComponentVNode)(2,t.Section,{title:"pAI",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"eject",content:f,disabled:l,onClick:function(){function B(){return i("ejectpai")}return B}()})})]})})}return y}()},69479:function(T,r,n){"use strict";r.__esModule=!0,r.BotFloor=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotFloor=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.noaccess,l=c.painame,u=c.hullplating,s=c.replace,d=c.eat,C=c.make,g=c.fixfloor,v=c.nag_empty,f=c.magnet,N=c.tiles_amount;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:510,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,p.BotStatus),(0,e.createComponentVNode)(2,t.Section,{title:"Floor Settings",children:[(0,e.createComponentVNode)(2,t.Box,{mb:"5px",children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tiles Left",children:N})}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:u,content:"Add tiles to new hull plating",tooltip:"Fixing a plating requires the removal of floor tile. This will place it back after repairing. Same goes for hull breaches",disabled:m,onClick:function(){function V(){return i("autotile")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:s,content:"Add floor tiles on exposed hull plating",tooltip:"Example: It will add tiles to maintenance",disabled:m,onClick:function(){function V(){return i("replacetiles")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:g,content:"Repair damaged tiles and platings",disabled:m,onClick:function(){function V(){return i("fixfloors")}return V}()})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Miscellaneous",children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:d,content:"Finds tiles",disabled:m,onClick:function(){function V(){return i("eattiles")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:C,content:"Make pieces of metal into tiles when empty",disabled:m,onClick:function(){function V(){return i("maketiles")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:v,content:"Transmit notice when empty",disabled:m,onClick:function(){function V(){return i("nagonempty")}return V}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:f,content:"Traction Magnets",disabled:m,onClick:function(){function V(){return i("anchored")}return V}()})]}),l&&(0,e.createComponentVNode)(2,t.Section,{title:"pAI",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,icon:"eject",content:l,disabled:m,onClick:function(){function V(){return i("ejectpai")}return V}()})})]})})}return y}()},59887:function(T,r,n){"use strict";r.__esModule=!0,r.BotHonk=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotHonk=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:220,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,p.BotStatus)})})}return y}()},80063:function(T,r,n){"use strict";r.__esModule=!0,r.BotMed=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotMed=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.locked,l=c.noaccess,u=c.maintpanel,s=c.on,d=c.autopatrol,C=c.canhack,g=c.emagged,v=c.remote_disabled,f=c.painame,N=c.shut_up,V=c.declare_crit,B=c.stationary_mode,I=c.heal_threshold,L=c.injection_amount,w=c.use_beaker,A=c.treat_virus,x=c.reagent_glass;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.BotStatus),(0,e.createComponentVNode)(2,t.Section,{title:"Communication Settings",children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,content:"Speaker",checked:!N,disabled:l,onClick:function(){function E(){return i("toggle_speaker")}return E}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,content:"Critical Patient Alerts",checked:V,disabled:l,onClick:function(){function E(){return i("toggle_critical_alerts")}return E}()})]}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Treatment Settings",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Healing Threshold",children:(0,e.createComponentVNode)(2,t.Slider,{value:I.value,minValue:I.min,maxValue:I.max,step:5,disabled:l,onChange:function(){function E(P,D){return i("set_heal_threshold",{target:D})}return E}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Injection Level",children:(0,e.createComponentVNode)(2,t.Slider,{value:L.value,minValue:L.min,maxValue:L.max,step:5,format:function(){function E(P){return P+"u"}return E}(),disabled:l,onChange:function(){function E(P,D){return i("set_injection_amount",{target:D})}return E}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Reagent Source",children:(0,e.createComponentVNode)(2,t.Button,{content:w?"Beaker":"Internal Synthesizer",icon:w?"flask":"cogs",disabled:l,onClick:function(){function E(){return i("toggle_use_beaker")}return E}()})}),x&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Beaker",children:(0,e.createComponentVNode)(2,t.Stack,{inline:!0,width:"100%",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1,children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:x.amount,minValue:0,maxValue:x.max_amount,children:[x.amount," / ",x.max_amount]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{ml:1,children:(0,e.createComponentVNode)(2,t.Button,{content:"Eject",disabled:l,onClick:function(){function E(){return i("eject_reagent_glass")}return E}()})})]})})]}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{mt:1,fluid:!0,content:"Treat Viral Infections",checked:A,disabled:l,onClick:function(){function E(){return i("toggle_treat_viral")}return E}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,content:"Stationary Mode",checked:B,disabled:l,onClick:function(){function E(){return i("toggle_stationary_mode")}return E}()})]}),f&&(0,e.createComponentVNode)(2,t.Section,{title:"pAI",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"eject",content:f,disabled:l,onClick:function(){function E(){return i("ejectpai")}return E}()})})]})})})}return y}()},74439:function(T,r,n){"use strict";r.__esModule=!0,r.BotSecurity=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(92963),b=r.BotSecurity=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.noaccess,l=c.painame,u=c.check_id,s=c.check_weapons,d=c.check_warrant,C=c.arrest_mode,g=c.arrest_declare;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:445,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,p.BotStatus),(0,e.createComponentVNode)(2,t.Section,{title:"Who To Arrest",children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:u,content:"Unidentifiable Persons",disabled:m,onClick:function(){function v(){return i("authid")}return v}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:s,content:"Unauthorized Weapons",disabled:m,onClick:function(){function v(){return i("authweapon")}return v}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:d,content:"Wanted Criminals",disabled:m,onClick:function(){function v(){return i("authwarrant")}return v}()})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Arrest Procedure",children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:C,content:"Detain Targets Indefinitely",disabled:m,onClick:function(){function v(){return i("arrtype")}return v}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:g,content:"Announce Arrests On Radio",disabled:m,onClick:function(){function v(){return i("arrdeclare")}return v}()})]}),l&&(0,e.createComponentVNode)(2,t.Section,{title:"pAI",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"eject",content:l,disabled:m,onClick:function(){function v(){return i("ejectpai")}return v}()})})]})})}return y}()},10833:function(T,r,n){"use strict";r.__esModule=!0,r.BrigCells=void 0;var e=n(89005),a=n(98595),t=n(36036),o=n(72253),p=function(k,h){var i=k.cell,c=(0,o.useBackend)(h),m=c.act,l=i.cell_id,u=i.occupant,s=i.crimes,d=i.brigged_by,C=i.time_left_seconds,g=i.time_set_seconds,v=i.ref,f="";C>0&&(f+=" BrigCells__listRow--active");var N=function(){m("release",{ref:v})};return(0,e.createComponentVNode)(2,t.Table.Row,{className:f,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:l}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:s}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.TimeDisplay,{totalSeconds:g})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.TimeDisplay,{totalSeconds:C})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{type:"button",onClick:N,children:"Release"})})]})},b=function(k){var h=k.cells;return(0,e.createComponentVNode)(2,t.Table,{className:"BrigCells__list",children:[(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Cell"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Occupant"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Crimes"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Brigged By"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Time Brigged For"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Time Left"}),(0,e.createComponentVNode)(2,t.Table.Cell,{header:!0,children:"Release"})]}),h.map(function(i){return(0,e.createComponentVNode)(2,p,{cell:i},i.ref)})]})},y=r.BrigCells=function(){function S(k,h){var i=(0,o.useBackend)(h),c=i.act,m=i.data,l=m.cells;return(0,e.createComponentVNode)(2,a.Window,{theme:"security",width:800,height:400,children:(0,e.createComponentVNode)(2,a.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,b,{cells:l})})})})})}return S}()},45761:function(T,r,n){"use strict";r.__esModule=!0,r.BrigTimer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.BrigTimer=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;i.nameText=i.occupant,i.timing&&(i.prisoner_hasrec?i.nameText=(0,e.createComponentVNode)(2,t.Box,{color:"green",children:i.occupant}):i.nameText=(0,e.createComponentVNode)(2,t.Box,{color:"red",children:i.occupant}));var c="pencil-alt";i.prisoner_name&&(i.prisoner_hasrec||(c="exclamation-triangle"));var m=[],l=0;for(l=0;lm?this.substring(0,m)+"...":this};var k=function(l,u){var s,d;if(!u)return[];var C=l.findIndex(function(g){return g.name===u.name});return[(s=l[C-1])==null?void 0:s.name,(d=l[C+1])==null?void 0:d.name]},h=function(l,u){u===void 0&&(u="");var s=(0,p.createSearch)(u,function(d){return d.name});return(0,t.flow)([(0,a.filter)(function(d){return d==null?void 0:d.name}),u&&(0,a.filter)(s),(0,a.sortBy)(function(d){return d.name})])(l)},i=r.CameraConsole=function(){function m(l,u){var s=(0,b.useBackend)(u),d=s.act,C=s.data,g=s.config,v=C.mapRef,f=C.activeCamera,N=h(C.cameras),V=k(N,f),B=V[0],I=V[1];return(0,e.createComponentVNode)(2,S.Window,{width:870,height:708,children:[(0,e.createVNode)(1,"div","CameraConsole__left",(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,y.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,c)})}),2),(0,e.createVNode)(1,"div","CameraConsole__right",[(0,e.createVNode)(1,"div","CameraConsole__toolbar",[(0,e.createVNode)(1,"b",null,"Camera: ",16),f&&f.name||"\u2014"],0),(0,e.createVNode)(1,"div","CameraConsole__toolbarRight",[(0,e.createComponentVNode)(2,y.Button,{icon:"chevron-left",disabled:!B,onClick:function(){function L(){return d("switch_camera",{name:B})}return L}()}),(0,e.createComponentVNode)(2,y.Button,{icon:"chevron-right",disabled:!I,onClick:function(){function L(){return d("switch_camera",{name:I})}return L}()})],4),(0,e.createComponentVNode)(2,y.ByondUi,{className:"CameraConsole__map",params:{id:v,type:"map"}})],4)]})}return m}(),c=r.CameraConsoleContent=function(){function m(l,u){var s=(0,b.useBackend)(u),d=s.act,C=s.data,g=(0,b.useLocalState)(u,"searchText",""),v=g[0],f=g[1],N=C.activeCamera,V=h(C.cameras,v);return(0,e.createComponentVNode)(2,y.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y.Stack.Item,{children:(0,e.createComponentVNode)(2,y.Input,{fluid:!0,placeholder:"Search for a camera",onInput:function(){function B(I,L){return f(L)}return B}()})}),(0,e.createComponentVNode)(2,y.Stack.Item,{grow:!0,m:0,children:(0,e.createComponentVNode)(2,y.Section,{fill:!0,scrollable:!0,children:V.map(function(B){return(0,e.createVNode)(1,"div",(0,o.classes)(["Button","Button--fluid","Button--color--transparent",N&&B.name===N.name&&"Button--selected"]),B.name.trimLongStr(23),0,{title:B.name,onClick:function(){function I(){return d("switch_camera",{name:B.name})}return I}()},B.name)})})})]})}return m}()},52927:function(T,r,n){"use strict";r.__esModule=!0,r.Canister=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(49968),b=n(98595),y=r.Canister=function(){function S(k,h){var i=(0,t.useBackend)(h),c=i.act,m=i.data,l=m.portConnected,u=m.tankPressure,s=m.releasePressure,d=m.defaultReleasePressure,C=m.minReleasePressure,g=m.maxReleasePressure,v=m.valveOpen,f=m.name,N=m.canLabel,V=m.colorContainer,B=m.color_index,I=m.hasHoldingTank,L=m.holdingTank,w="";B.prim&&(w=V.prim.options[B.prim].name);var A="";B.sec&&(A=V.sec.options[B.sec].name);var x="";B.ter&&(x=V.ter.options[B.ter].name);var E="";B.quart&&(E=V.quart.options[B.quart].name);var P=[],D=[],M=[],O=[],R=0;for(R=0;Rf.current_positions&&(0,e.createComponentVNode)(2,t.Box,{color:"green",children:f.total_positions-f.current_positions})||(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"0"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{content:"-",disabled:d.cooldown_time||!f.can_close,onClick:function(){function N(){return s("make_job_unavailable",{job:f.title})}return N}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{content:"+",disabled:d.cooldown_time||!f.can_open,onClick:function(){function N(){return s("make_job_available",{job:f.title})}return N}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:d.target_dept&&(0,e.createComponentVNode)(2,t.Box,{color:"green",children:d.priority_jobs.indexOf(f.title)>-1?"Yes":""})||(0,e.createComponentVNode)(2,t.Button,{content:f.is_priority?"Yes":"No",selected:f.is_priority,disabled:d.cooldown_time||!f.can_prioritize,onClick:function(){function N(){return s("prioritize_job",{job:f.title})}return N}()})})]},f.title)})]})})]}):v=(0,e.createComponentVNode)(2,S);break;case 2:!d.authenticated||!d.scan_name?v=(0,e.createComponentVNode)(2,S):d.modify_name?v=(0,e.createComponentVNode)(2,p.AccessList,{accesses:d.regions,selectedList:d.selectedAccess,accessMod:function(){function f(N){return s("set",{access:N})}return f}(),grantAll:function(){function f(){return s("grant_all")}return f}(),denyAll:function(){function f(){return s("clear_all")}return f}(),grantDep:function(){function f(N){return s("grant_region",{region:N})}return f}(),denyDep:function(){function f(N){return s("deny_region",{region:N})}return f}()}):v=(0,e.createComponentVNode)(2,k);break;case 3:d.authenticated?d.records.length?v=(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Records",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Delete All Records",disabled:!d.authenticated||d.records.length===0||d.target_dept,onClick:function(){function f(){return s("wipe_all_logs")}return f}()}),children:[(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{height:2,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Crewman"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Old Rank"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"New Rank"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Authorized By"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Time"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Reason"}),!!d.iscentcom&&(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Deleted By"})]}),d.records.map(function(f){return(0,e.createComponentVNode)(2,t.Table.Row,{height:2,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.transferee}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.oldvalue}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.newvalue}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.whodidit}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.timestamp}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.reason}),!!d.iscentcom&&(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.deletedby})]},f.timestamp)})]}),!!d.iscentcom&&(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:"Delete MY Records",color:"purple",disabled:!d.authenticated||d.records.length===0,onClick:function(){function f(){return s("wipe_my_logs")}return f}()})})]}):v=(0,e.createComponentVNode)(2,h):v=(0,e.createComponentVNode)(2,S);break;case 4:!d.authenticated||!d.scan_name?v=(0,e.createComponentVNode)(2,S):v=(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Your Team",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{height:2,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Rank"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Sec Status"}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Actions"})]}),d.people_dept.map(function(f){return(0,e.createComponentVNode)(2,t.Table.Row,{height:2,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.title}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.crimstat}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:f.buttontext,disabled:!f.demotable,onClick:function(){function N(){return s("remote_demote",{remote_demote:f.name})}return N}()})})]},f.title)})]})});break;default:v=(0,e.createComponentVNode)(2,t.Section,{title:"Warning",color:"red",children:"ERROR: Unknown Mode."})}return(0,e.createComponentVNode)(2,o.Window,{width:800,height:800,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:g}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:C}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:v})]})})})}return c}()},64083:function(T,r,n){"use strict";r.__esModule=!0,r.CargoConsole=void 0;var e=n(89005),a=n(64795),t=n(88510),o=n(72253),p=n(36036),b=n(98595),y=n(25328),S=r.CargoConsole=function(){function u(s,d){return(0,e.createComponentVNode)(2,b.Window,{width:900,height:800,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,l)]})})})}return u}(),k=function(s,d){var C=(0,o.useLocalState)(d,"contentsModal",null),g=C[0],v=C[1],f=(0,o.useLocalState)(d,"contentsModalTitle",null),N=f[0],V=f[1];if(g!==null&&N!==null)return(0,e.createComponentVNode)(2,p.Modal,{maxWidth:"75%",width:window.innerWidth+"px",maxHeight:window.innerHeight*.75+"px",mx:"auto",children:[(0,e.createComponentVNode)(2,p.Box,{width:"100%",bold:!0,children:(0,e.createVNode)(1,"h1",null,[N,(0,e.createTextVNode)(" contents:")],0)}),(0,e.createComponentVNode)(2,p.Box,{children:g.map(function(B){return(0,e.createComponentVNode)(2,p.Box,{children:["- ",B]},B)})}),(0,e.createComponentVNode)(2,p.Box,{m:2,children:(0,e.createComponentVNode)(2,p.Button,{content:"Close",onClick:function(){function B(){v(null),V(null)}return B}()})})]})},h=function(s,d){var C=(0,o.useBackend)(d),g=C.act,v=C.data,f=v.is_public,N=v.timeleft,V=v.moving,B=v.at_station,I,L;return!V&&!B?(I="Docked off-station",L="Call Shuttle"):!V&&B?(I="Docked at the station",L="Return Shuttle"):V&&(L="In Transit...",N!==1?I="Shuttle is en route (ETA: "+N+" minutes)":I="Shuttle is en route (ETA: "+N+" minute)"),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Section,{title:"Status",children:(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Shuttle Status",children:I}),f===0&&(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Controls",children:[(0,e.createComponentVNode)(2,p.Button,{content:L,disabled:V,onClick:function(){function w(){return g("moveShuttle")}return w}()}),(0,e.createComponentVNode)(2,p.Button,{content:"View Central Command Messages",onClick:function(){function w(){return g("showMessages")}return w}()})]})]})})})},i=function(s,d){var C,g=(0,o.useBackend)(d),v=g.act,f=g.data,N=f.accounts,V=(0,o.useLocalState)(d,"selectedAccount"),B=V[0],I=V[1],L=[];return N.map(function(w){return L[w.name]=w.account_UID}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Section,{title:"Payment",children:[(0,e.createComponentVNode)(2,p.Dropdown,{width:"190px",options:N.map(function(w){return w.name}),selected:(C=N.filter(function(w){return w.account_UID===B})[0])==null?void 0:C.name,onSelected:function(){function w(A){return I(L[A])}return w}()}),N.filter(function(w){return w.account_UID===B}).map(function(w){return(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Account Name",children:(0,e.createComponentVNode)(2,p.Stack.Item,{mt:1,children:w.name})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Balance",children:(0,e.createComponentVNode)(2,p.Stack.Item,{children:w.balance})})]},w.account_UID)})]})})},c=function(s,d){var C=(0,o.useBackend)(d),g=C.act,v=C.data,f=v.requests,N=v.categories,V=v.supply_packs,B=(0,o.useSharedState)(d,"category","Emergency"),I=B[0],L=B[1],w=(0,o.useSharedState)(d,"search_text",""),A=w[0],x=w[1],E=(0,o.useLocalState)(d,"contentsModal",null),P=E[0],D=E[1],M=(0,o.useLocalState)(d,"contentsModalTitle",null),O=M[0],R=M[1],F=(0,y.createSearch)(A,function(X){return X.name}),W=(0,o.useLocalState)(d,"selectedAccount"),U=W[0],z=W[1],$=(0,a.flow)([(0,t.filter)(function(X){return X.cat===N.filter(function(J){return J.name===I})[0].category||A}),A&&(0,t.filter)(F),(0,t.sortBy)(function(X){return X.name.toLowerCase()})])(V),G="Crate Catalogue";return A?G="Results for '"+A+"':":I&&(G="Browsing "+I),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Section,{title:G,buttons:(0,e.createComponentVNode)(2,p.Dropdown,{width:"190px",options:N.map(function(X){return X.name}),selected:I,onSelected:function(){function X(J){return L(J)}return X}()}),children:[(0,e.createComponentVNode)(2,p.Input,{fluid:!0,placeholder:"Search for...",onInput:function(){function X(J,se){return x(se)}return X}(),mb:1}),(0,e.createComponentVNode)(2,p.Box,{maxHeight:25,overflowY:"auto",overflowX:"hidden",children:(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:$.map(function(X){return(0,e.createComponentVNode)(2,p.Table.Row,{children:[(0,e.createComponentVNode)(2,p.Table.Cell,{bold:!0,children:[X.name," (",X.cost," Credits)"]}),(0,e.createComponentVNode)(2,p.Table.Cell,{textAlign:"right",pr:1,children:[(0,e.createComponentVNode)(2,p.Button,{content:"Order 1",icon:"shopping-cart",disabled:!U,onClick:function(){function J(){return g("order",{crate:X.ref,multiple:!1,account:U})}return J}()}),(0,e.createComponentVNode)(2,p.Button,{content:"Order Multiple",icon:"cart-plus",disabled:!U||X.singleton,onClick:function(){function J(){return g("order",{crate:X.ref,multiple:!0,account:U})}return J}()}),(0,e.createComponentVNode)(2,p.Button,{content:"View Contents",icon:"search",onClick:function(){function J(){D(X.contents),R(X.name)}return J}()})]})]},X.name)})})})]})})},m=function(s,d){var C=s.request,g,v;switch(C.department){case"Engineering":v="CE",g="orange";break;case"Medical":v="CMO",g="teal";break;case"Science":v="RD",g="purple";break;case"Supply":v="CT",g="brown";break;case"Service":v="HOP",g="olive";break;case"Security":v="HOS",g="red";break;case"Command":v="CAP",g="blue";break;case"Assistant":v="Any Head",g="grey";break}return(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{mt:.5,children:"Approval Required:"}),!!C.req_cargo_approval&&(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button,{color:"brown",content:"QM",icon:"user-tie",tooltip:"This Order requires approval from the QM still"})}),!!C.req_head_approval&&(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button,{color:g,content:v,disabled:C.req_cargo_approval,icon:"user-tie",tooltip:C.req_cargo_approval?"This Order first requires approval from the QM before the "+v+" can approve it":"This Order requires approval from the "+v+" still"})})]})},l=function(s,d){var C=(0,o.useBackend)(d),g=C.act,v=C.data,f=v.requests,N=v.orders,V=v.shipments;return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,title:"Orders",children:[(0,e.createComponentVNode)(2,p.Box,{bold:!0,children:"Requests"}),(0,e.createComponentVNode)(2,p.Table,{children:f.map(function(B){return(0,e.createComponentVNode)(2,p.Table.Row,{className:"Cargo_RequestList",children:[(0,e.createComponentVNode)(2,p.Table.Cell,{mb:1,children:[(0,e.createComponentVNode)(2,p.Box,{children:["Order #",B.ordernum,": ",B.supply_type," (",B.cost," credits) for ",(0,e.createVNode)(1,"b",null,B.orderedby,0)," with"," ",B.department?"The "+B.department+" Department":"Their Personal"," Account"]}),(0,e.createComponentVNode)(2,p.Box,{italic:!0,children:["Reason: ",B.comment]}),(0,e.createComponentVNode)(2,m,{request:B})]}),(0,e.createComponentVNode)(2,p.Stack.Item,{textAlign:"right",children:[(0,e.createComponentVNode)(2,p.Button,{content:"Approve",color:"green",disabled:!B.can_approve,onClick:function(){function I(){return g("approve",{ordernum:B.ordernum})}return I}()}),(0,e.createComponentVNode)(2,p.Button,{content:"Deny",color:"red",disabled:!B.can_deny,onClick:function(){function I(){return g("deny",{ordernum:B.ordernum})}return I}()})]})]},B.ordernum)})}),(0,e.createComponentVNode)(2,p.Box,{bold:!0,children:"Orders Awaiting Delivery"}),(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:N.map(function(B){return(0,e.createComponentVNode)(2,p.Table.Row,{children:(0,e.createComponentVNode)(2,p.Table.Cell,{children:[(0,e.createComponentVNode)(2,p.Box,{children:["- #",B.ordernum,": ",B.supply_type," for ",(0,e.createVNode)(1,"b",null,B.orderedby,0)]}),(0,e.createComponentVNode)(2,p.Box,{italic:!0,children:["Reason: ",B.comment]})]})},B.ordernum)})}),(0,e.createComponentVNode)(2,p.Box,{bold:!0,children:"Order in Transit"}),(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:V.map(function(B){return(0,e.createComponentVNode)(2,p.Table.Row,{children:(0,e.createComponentVNode)(2,p.Table.Cell,{children:[(0,e.createComponentVNode)(2,p.Box,{children:["- #",B.ordernum,": ",B.supply_type," for ",(0,e.createVNode)(1,"b",null,B.orderedby,0)]}),(0,e.createComponentVNode)(2,p.Box,{italic:!0,children:["Reason: ",B.comment]})]})},B.ordernum)})})]})}},36232:function(T,r,n){"use strict";r.__esModule=!0,r.ChameleonAppearances=r.Chameleon=void 0;var e=n(89005),a=n(25328),t=n(64795),o=n(88510),p=n(72253),b=n(36036),y=n(98595),S=r.Chameleon=function(){function i(c,m){return(0,e.createComponentVNode)(2,y.Window,{width:431,height:500,theme:"syndicate",children:(0,e.createComponentVNode)(2,y.Window.Content,{children:(0,e.createComponentVNode)(2,h)})})}return i}(),k=function(c,m){m===void 0&&(m="");var l=(0,a.createSearch)(m,function(u){return u.name});return(0,t.flow)([(0,o.filter)(function(u){return u==null?void 0:u.name}),m&&(0,o.filter)(l)])(c)},h=r.ChameleonAppearances=function(){function i(c,m){var l=(0,p.useBackend)(m),u=l.act,s=l.data,d=(0,p.useLocalState)(m,"searchText",""),C=d[0],g=d[1],v=k(s.chameleon_skins,C),f=s.selected_appearance;return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Input,{fluid:!0,placeholder:"Search for an appearance",onInput:function(){function N(V,B){return g(B)}return N}()})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Item Appearance",children:v.map(function(N){var V=N.name+"_"+N.icon_state;return(0,e.createComponentVNode)(2,b.ImageButton,{dmIcon:N.icon,dmIconState:N.icon_state,imageSize:64,m:.5,compact:!0,selected:V===f,tooltip:N.name,style:{opacity:V===f&&"1"||"0.5"},onClick:function(){function B(){u("change_appearance",{new_appearance:V})}return B}()},V)})})})]})}return i}()},87331:function(T,r,n){"use strict";r.__esModule=!0,r.ChangelogView=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ChangelogView=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=(0,a.useLocalState)(S,"onlyRecent",0),m=c[0],l=c[1],u=i.cl_data,s=i.last_cl,d={FIX:(0,e.createComponentVNode)(2,t.Icon,{name:"tools",title:"Fix"}),WIP:(0,e.createComponentVNode)(2,t.Icon,{name:"hard-hat",title:"WIP",color:"orange"}),TWEAK:(0,e.createComponentVNode)(2,t.Icon,{name:"sliders-h",title:"Tweak"}),SOUNDADD:(0,e.createComponentVNode)(2,t.Icon,{name:"volume-up",title:"Sound Added",color:"green"}),SOUNDDEL:(0,e.createComponentVNode)(2,t.Icon,{name:"volume-mute",title:"Sound Removed",color:"red"}),CODEADD:(0,e.createComponentVNode)(2,t.Icon,{name:"plus",title:"Code Addition",color:"green"}),CODEDEL:(0,e.createComponentVNode)(2,t.Icon,{name:"minus",title:"Code Removal",color:"red"}),IMAGEADD:(0,e.createComponentVNode)(2,t.Icon,{name:"folder-plus",title:"Sprite Addition",color:"green"}),IMAGEDEL:(0,e.createComponentVNode)(2,t.Icon,{name:"folder-minus",title:"Sprite Removal",color:"red"}),SPELLCHECK:(0,e.createComponentVNode)(2,t.Icon,{name:"font",title:"Spelling/Grammar Fix"}),EXPERIMENT:(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-triangle",title:"Experimental",color:"orange"})},C=function(){function g(v){return v in d?d[v]:(0,e.createComponentVNode)(2,t.Icon,{name:"plus",color:"green"})}return g}();return(0,e.createComponentVNode)(2,o.Window,{width:750,height:800,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"ParadiseSS13 Changelog",mt:2,buttons:(0,e.createComponentVNode)(2,t.Button,{content:m?"Showing all changes":"Showing changes since last connection",onClick:function(){function g(){return l(!m)}return g}()}),children:u.map(function(g){return!m&&g.merge_ts<=s||(0,e.createComponentVNode)(2,t.Section,{mb:2,title:g.author+" - Merged on "+g.merge_date,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"#"+g.num,onClick:function(){function v(){return h("open_pr",{pr_number:g.num})}return v}()}),children:g.entries.map(function(v){return(0,e.createComponentVNode)(2,t.Box,{m:1,children:[C(v.etype)," ",v.etext]},v)})},g)})})})})}return b}()},91360:function(T,r,n){"use strict";r.__esModule=!0,r.CheckboxListInputModal=void 0;var e=n(89005),a=n(51057),t=n(19203),o=n(36036),p=n(72253),b=n(98595),y=r.CheckboxListInputModal=function(){function k(h,i){var c=(0,p.useBackend)(i),m=c.act,l=c.data,u=l.items,s=u===void 0?[]:u,d=l.message,C=d===void 0?"":d,g=l.init_value,v=l.timeout,f=l.title,N=(0,p.useLocalState)(i,"edittedItems",s),V=N[0],B=N[1],I=330+Math.ceil(C.length/3),L=function(){function w(A){A===void 0&&(A=null);var x=[].concat(V);x=x.map(function(E){return E.key===A.key?Object.assign({},E,{checked:!A.checked}):E}),B(x)}return w}();return(0,e.createComponentVNode)(2,b.Window,{title:f,width:325,height:I,children:[v&&(0,e.createComponentVNode)(2,a.Loader,{value:v}),(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{className:"ListInput__Section",fill:!0,title:C,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,S,{filteredItems:V,onClick:L})}),(0,e.createComponentVNode)(2,o.Stack.Item,{mt:.5,children:(0,e.createComponentVNode)(2,t.InputButtons,{input:V})})]})})})]})}return k}(),S=function(h,i){var c=h.filteredItems,m=h.onClick;return(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,tabIndex:0,children:c.map(function(l,u){return(0,e.createComponentVNode)(2,o.Button.Checkbox,{fluid:!0,id:u,onClick:function(){function s(){return m(l)}return s}(),checked:l.checked,style:{animation:"none",transition:"none"},children:l.key.replace(/^\w/,function(s){return s.toUpperCase()})},u)})})}},36108:function(T,r,n){"use strict";r.__esModule=!0,r.ChemDispenser=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(85870),p=n(98595),b=[1,5,10,20,30,50],y=[1,5,10],S=r.ChemDispenser=function(){function c(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,C=d.chemicals;return(0,e.createComponentVNode)(2,p.Window,{width:400,height:400+C.length*8,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,i)]})})})}return c}(),k=function(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,C=d.amount,g=d.energy,v=d.maxEnergy;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Energy",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:g,minValue:0,maxValue:v,ranges:{good:[v*.5,1/0],average:[v*.25,v*.5],bad:[-1/0,v*.25]},children:[g," / ",v," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Dispense",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,t.Stack,{children:b.map(function(f,N){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,width:"15%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"cog",selected:C===f,content:f,onClick:function(){function V(){return s("amount",{amount:f})}return V}()})},N)})})})]})})})},h=function(m,l){for(var u=(0,a.useBackend)(l),s=u.act,d=u.data,C=d.chemicals,g=C===void 0?[]:C,v=[],f=0;f<(g.length+1)%3;f++)v.push(!0);return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:d.glass?"Drink Dispenser":"Chemical Dispenser",children:[g.map(function(N,V){return(0,e.createComponentVNode)(2,t.Button,{m:.1,width:"32.5%",icon:"arrow-circle-down",overflow:"hidden",textOverflow:"ellipsis",content:N.title,style:{"margin-left":"2px"},onClick:function(){function B(){return s("dispense",{reagent:N.id})}return B}()},V)}),v.map(function(N,V){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%"},V)})]})})},i=function(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,C=d.isBeakerLoaded,g=d.beakerCurrentVolume,v=d.beakerMaxVolume,f=d.beakerContents,N=f===void 0?[]:f;return(0,e.createComponentVNode)(2,t.Stack.Item,{height:16,children:(0,e.createComponentVNode)(2,t.Section,{title:d.glass?"Glass":"Beaker",fill:!0,scrollable:!0,buttons:(0,e.createComponentVNode)(2,t.Box,{children:[!!C&&(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:"label",mr:2,children:[g," / ",v," units"]}),(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:"Eject",disabled:!C,onClick:function(){function V(){return s("ejectBeaker")}return V}()})]}),children:(0,e.createComponentVNode)(2,o.BeakerContents,{beakerLoaded:C,beakerContents:N,buttons:function(){function V(B){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"Isolate",icon:"compress-arrows-alt",onClick:function(){function I(){return s("remove",{reagent:B.id,amount:-1})}return I}()}),y.map(function(I,L){return(0,e.createComponentVNode)(2,t.Button,{content:I,onClick:function(){function w(){return s("remove",{reagent:B.id,amount:I})}return w}()},L)}),(0,e.createComponentVNode)(2,t.Button,{content:"ALL",onClick:function(){function I(){return s("remove",{reagent:B.id,amount:B.volume})}return I}()})],0)}return V}()})})})}},13146:function(T,r,n){"use strict";r.__esModule=!0,r.ChemHeater=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(85870),b=n(98595),y=r.ChemHeater=function(){function h(i,c){return(0,e.createComponentVNode)(2,b.Window,{width:350,height:275,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k)]})})})}return h}(),S=function(i,c){var m=(0,t.useBackend)(c),l=m.act,u=m.data,s=u.targetTemp,d=u.targetTempReached,C=u.autoEject,g=u.isActive,v=u.currentTemp,f=u.isBeakerLoaded;return(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Settings",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{content:"Auto-eject",icon:C?"toggle-on":"toggle-off",selected:C,onClick:function(){function N(){return l("toggle_autoeject")}return N}()}),(0,e.createComponentVNode)(2,o.Button,{content:g?"On":"Off",icon:"power-off",selected:g,disabled:!f,onClick:function(){function N(){return l("toggle_on")}return N}()})],4),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Target",children:(0,e.createComponentVNode)(2,o.NumberInput,{width:"65px",unit:"K",step:10,stepPixelSize:3,value:(0,a.round)(s,0),minValue:0,maxValue:1e3,onDrag:function(){function N(V,B){return l("adjust_temperature",{target:B})}return N}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Reading",color:d?"good":"average",children:f&&(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:v,format:function(){function N(V){return(0,a.toFixed)(V)+" K"}return N}()})||"\u2014"})]})})})},k=function(i,c){var m=(0,t.useBackend)(c),l=m.act,u=m.data,s=u.isBeakerLoaded,d=u.beakerCurrentVolume,C=u.beakerMaxVolume,g=u.beakerContents;return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{title:"Beaker",fill:!0,scrollable:!0,buttons:!!s&&(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,o.Box,{inline:!0,color:"label",mr:2,children:[d," / ",C," units"]}),(0,e.createComponentVNode)(2,o.Button,{icon:"eject",content:"Eject",onClick:function(){function v(){return l("eject_beaker")}return v}()})]}),children:(0,e.createComponentVNode)(2,p.BeakerContents,{beakerLoaded:s,beakerContents:g})})})}},56541:function(T,r,n){"use strict";r.__esModule=!0,r.ChemMaster=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(85870),b=n(3939),y=n(35840),S=["icon"];function k(I,L){if(I==null)return{};var w={};for(var A in I)if({}.hasOwnProperty.call(I,A)){if(L.includes(A))continue;w[A]=I[A]}return w}function h(I,L){I.prototype=Object.create(L.prototype),I.prototype.constructor=I,i(I,L)}function i(I,L){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(w,A){return w.__proto__=A,w},i(I,L)}var c=[1,5,10],m=function(L,w){var A=(0,a.useBackend)(w),x=A.act,E=A.data,P=L.args.analysis;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:E.condi?"Condiment Analysis":"Reagent Analysis",children:(0,e.createComponentVNode)(2,t.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:P.name}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:(P.desc||"").length>0?P.desc:"N/A"}),P.blood_type&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood type",children:P.blood_type}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood DNA",className:"LabeledList__breakContents",children:P.blood_dna})],4),!E.condi&&(0,e.createComponentVNode)(2,t.Button,{icon:E.printing?"spinner":"print",disabled:E.printing,iconSpin:!!E.printing,ml:"0.5rem",content:"Print",onClick:function(){function D(){return x("print",{idx:P.idx,beaker:L.args.beaker})}return D}()})]})})})})},l=function(I){return I[I.ToDisposals=0]="ToDisposals",I[I.ToBeaker=1]="ToBeaker",I}(l||{}),u=r.ChemMaster=function(){function I(L,w){return(0,e.createComponentVNode)(2,o.Window,{width:575,height:650,children:[(0,e.createComponentVNode)(2,b.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,s),(0,e.createComponentVNode)(2,d),(0,e.createComponentVNode)(2,C),(0,e.createComponentVNode)(2,B)]})})]})}return I}(),s=function(L,w){var A=(0,a.useBackend)(w),x=A.act,E=A.data,P=E.beaker,D=E.beaker_reagents,M=E.buffer_reagents,O=M.length>0;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Beaker",fill:!0,scrollable:!0,buttons:O?(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"eject",disabled:!P,content:"Eject and Clear Buffer",onClick:function(){function R(){return x("eject")}return R}()}):(0,e.createComponentVNode)(2,t.Button,{icon:"eject",disabled:!P,content:"Eject and Clear Buffer",onClick:function(){function R(){return x("eject")}return R}()}),children:P?(0,e.createComponentVNode)(2,p.BeakerContents,{beakerLoaded:!0,beakerContents:D,buttons:function(){function R(F,W){return(0,e.createComponentVNode)(2,t.Box,{mb:W0?(0,e.createComponentVNode)(2,p.BeakerContents,{beakerLoaded:!0,beakerContents:D,buttons:function(){function M(O,R){return(0,e.createComponentVNode)(2,t.Box,{mb:R0&&(O=M.map(function(R){var F=R.id,W=R.sprite;return(0,e.createComponentVNode)(2,N,{icon:W,translucent:!0,onClick:function(){function U(){return x("set_sprite_style",{production_mode:P,style:F})}return U}(),selected:D===F},F)})),(0,e.createComponentVNode)(2,f,{productionData:L.productionData,children:O&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Style",children:O})})},B=function(L,w){var A=(0,a.useBackend)(w),x=A.act,E=A.data,P=E.loaded_pill_bottle_style,D=E.containerstyles,M=E.loaded_pill_bottle,O={width:"20px",height:"20px"},R=D.map(function(F){var W=F.color,U=F.name,z=P===W;return(0,e.createComponentVNode)(2,t.Button,{style:{position:"relative",width:O.width,height:O.height},onClick:function(){function $(){return x("set_container_style",{style:W})}return $}(),icon:z&&"check",iconStyle:{position:"relative","z-index":1},tooltip:U,tooltipPosition:"top",children:[!z&&(0,e.createVNode)(1,"div",null,null,1,{style:{display:"inline-block"}}),(0,e.createVNode)(1,"span","Button",null,1,{style:{display:"inline-block",position:"absolute",top:0,left:0,margin:0,padding:0,width:O.width,height:O.height,"background-color":W,opacity:.6,filter:"alpha(opacity=60)"}})]},W)});return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Container Customization",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"eject",disabled:!M,content:"Eject Container",onClick:function(){function F(){return x("ejectp")}return F}()}),children:M?(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Style",children:[(0,e.createComponentVNode)(2,t.Button,{style:{width:O.width,height:O.height},icon:"tint-slash",onClick:function(){function F(){return x("clear_container_style")}return F}(),selected:!P,tooltip:"Default",tooltipPosition:"top"}),R]})}):(0,e.createComponentVNode)(2,t.Box,{color:"label",children:"No pill bottle or patch pack loaded."})})})};(0,b.modalRegisterBodyOverride)("analyze",m)},37173:function(T,r,n){"use strict";r.__esModule=!0,r.CloningConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(79140),b=1,y=32,S=128,k=r.CloningConsole=function(){function u(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.tab,N=v.has_scanner,V=v.pod_amount;return(0,e.createComponentVNode)(2,o.Window,{width:640,height:520,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Cloning Console",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Connected scanner",children:N?"Online":"Missing"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Connected pods",children:V})]})}),(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:f===1,icon:"home",onClick:function(){function B(){return g("menu",{tab:1})}return B}(),children:"Main Menu"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:f===2,icon:"user",onClick:function(){function B(){return g("menu",{tab:2})}return B}(),children:"Damage Configuration"})]}),(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,h)})]})})}return u}(),h=function(s,d){var C=(0,a.useBackend)(d),g=C.data,v=g.tab,f;return v===1?f=(0,e.createComponentVNode)(2,i):v===2&&(f=(0,e.createComponentVNode)(2,c)),f},i=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.pods,N=v.pod_amount,V=v.selected_pod_UID;return(0,e.createComponentVNode)(2,t.Box,{children:[!N&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Notice: No pods connected."}),!!N&&f.map(function(B,I){return(0,e.createComponentVNode)(2,t.Section,{layer:2,title:"Pod "+(I+1),children:(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{basis:"96px",shrink:0,children:[(0,e.createVNode)(1,"img",null,null,1,{src:(0,p.resolveAsset)("pod_"+(B.cloning?"cloning":"idle")+".gif"),style:{width:"100%","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}}),(0,e.createComponentVNode)(2,t.Button,{selected:V===B.uid,onClick:function(){function L(){return g("select_pod",{uid:B.uid})}return L}(),children:"Select"})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Progress",children:[!B.cloning&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Pod is inactive."}),!!B.cloning&&(0,e.createComponentVNode)(2,t.ProgressBar,{value:B.clone_progress,maxValue:100,color:"good"})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Biomass",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:B.biomass,ranges:{good:[2*B.biomass_storage_capacity/3,B.biomass_storage_capacity],average:[B.biomass_storage_capacity/3,2*B.biomass_storage_capacity/3],bad:[0,B.biomass_storage_capacity/3]},minValue:0,maxValue:B.biomass_storage_capacity,children:[B.biomass,"/",B.biomass_storage_capacity+" ("+100*B.biomass/B.biomass_storage_capacity+"%)"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Sanguine Reagent",children:B.sanguine_reagent}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Osseous Reagent",children:B.osseous_reagent})]})})]})},B)})]})},c=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.selected_pod_data,N=v.has_scanned,V=v.scanner_has_patient,B=v.feedback,I=v.scan_successful,L=v.cloning_cost,w=v.has_scanner,A=v.currently_scanning;return(0,e.createComponentVNode)(2,t.Box,{children:[!w&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Notice: No scanner connected."}),!!w&&(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Section,{layer:2,title:"Scanner Info",buttons:(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"hourglass-half",onClick:function(){function x(){return g("scan")}return x}(),disabled:!V||A,children:"Scan"}),(0,e.createComponentVNode)(2,t.Button,{icon:"eject",onClick:function(){function x(){return g("eject")}return x}(),disabled:!V||A,children:"Eject Patient"})]}),children:[!N&&!A&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:V?"No scan detected for current patient.":"No patient is in the scanner."}),(!!N||!!A)&&(0,e.createComponentVNode)(2,t.Box,{color:B.color,children:B.text})]}),(0,e.createComponentVNode)(2,t.Section,{layer:2,title:"Damages Breakdown",children:(0,e.createComponentVNode)(2,t.Box,{children:[(!I||!N)&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"No valid scan detected."}),!!I&&!!N&&(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function x(){return g("fix_all")}return x}(),children:"Repair All Damages"}),(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function x(){return g("fix_none")}return x}(),children:"Repair No Damages"})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function x(){return g("clone")}return x}(),children:"Clone"})})]}),(0,e.createComponentVNode)(2,t.Stack,{height:"25px",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"40%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:L[0],maxValue:f.biomass_storage_capacity,ranges:{bad:[2*f.biomass_storage_capacity/3,f.biomass_storage_capacity],average:[f.biomass_storage_capacity/3,2*f.biomass_storage_capacity/3],good:[0,f.biomass_storage_capacity/3]},color:L[0]>f.biomass?"bad":null,children:["Biomass: ",L[0],"/",f.biomass,"/",f.biomass_storage_capacity]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:L[1],maxValue:f.max_reagent_capacity,ranges:{bad:[2*f.max_reagent_capacity/3,f.max_reagent_capacity],average:[f.max_reagent_capacity/3,2*f.max_reagent_capacity/3],good:[0,f.max_reagent_capacity/3]},color:L[1]>f.sanguine_reagent?"bad":"good",children:["Sanguine: ",L[1],"/",f.sanguine_reagent,"/",f.max_reagent_capacity]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:L[2],maxValue:f.max_reagent_capacity,ranges:{bad:[2*f.max_reagent_capacity/3,f.max_reagent_capacity],average:[f.max_reagent_capacity/3,2*f.max_reagent_capacity/3],good:[0,f.max_reagent_capacity/3]},color:L[2]>f.osseous_reagent?"bad":"good",children:["Osseous: ",L[2],"/",f.osseous_reagent,"/",f.max_reagent_capacity]})})]}),(0,e.createComponentVNode)(2,m),(0,e.createComponentVNode)(2,l)]})]})})]})]})},m=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.patient_limb_data,N=v.limb_list,V=v.desired_limb_data;return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Limbs",children:N.map(function(B,I){return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Stack,{align:"baseline",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"15%",height:"20px",children:[f[B][4],":"," "]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),f[B][3]===0&&(0,e.createComponentVNode)(2,t.Stack.Item,{width:"60%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:V[B][0]+V[B][1],maxValue:f[B][5],ranges:{good:[0,f[B][5]/3],average:[f[B][5]/3,2*f[B][5]/3],bad:[2*f[B][5]/3,f[B][5]]},children:["Post-Cloning Damage: ",(0,e.createComponentVNode)(2,t.Icon,{name:"bone"})," "+V[B][0]+" / ",(0,e.createComponentVNode)(2,t.Icon,{name:"fire"})," "+V[B][1]]})}),f[B][3]!==0&&(0,e.createComponentVNode)(2,t.Stack.Item,{width:"60%",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:"bad",value:0,children:["The patient's ",f[B][4]," is missing!"]})})]}),(0,e.createComponentVNode)(2,t.Stack,{children:[!!f[B][3]&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!V[B][3],onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"replace"})}return L}(),children:"Replace Limb"})}),!f[B][3]&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!(f[B][0]||f[B][1]),checked:!(V[B][0]||V[B][1]),onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"damage"})}return L}(),children:"Repair Damages"}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!(f[B][2]&b),checked:!(V[B][2]&b),onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"bone"})}return L}(),children:"Mend Bone"}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!(f[B][2]&y),checked:!(V[B][2]&y),onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"ib"})}return L}(),children:"Mend IB"}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!(f[B][2]&S),checked:!(V[B][2]&S),onClick:function(){function L(){return g("toggle_limb_repair",{limb:B,type:"critburn"})}return L}(),children:"Mend Critical Burn"})]})]})]},B)})})},l=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.patient_organ_data,N=v.organ_list,V=v.desired_organ_data;return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Organs",children:N.map(function(B,I){return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Stack,{align:"baseline",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"20%",height:"20px",children:[f[B][3],":"," "]}),f[B][5]!=="heart"&&(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:[!!f[B][2]&&(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!V[B][2]&&!V[B][1],onClick:function(){function L(){return g("toggle_organ_repair",{organ:B,type:"replace"})}return L}(),children:"Replace Organ"}),!f[B][2]&&(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{disabled:!f[B][0],checked:!V[B][0],onClick:function(){function L(){return g("toggle_organ_repair",{organ:B,type:"damage"})}return L}(),children:"Repair Damages"})})]})}),f[B][5]==="heart"&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Heart replacement is required for cloning."}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"35%",children:[!!f[B][2]&&(0,e.createComponentVNode)(2,t.ProgressBar,{color:"bad",value:0,children:["The patient's ",f[B][3]," is missing!"]}),!f[B][2]&&(0,e.createComponentVNode)(2,t.ProgressBar,{value:V[B][0],maxValue:f[B][4],ranges:{good:[0,f[B][4]/3],average:[f[B][4]/3,2*f[B][4]/3],bad:[2*f[B][4]/3,f[B][4]]},children:"Post-Cloning Damage: "+V[B][0]})]})]})},B)})})}},98723:function(T,r,n){"use strict";r.__esModule=!0,r.CloningPod=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.CloningPod=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.biomass,m=i.biomass_storage_capacity,l=i.sanguine_reagent,u=i.osseous_reagent,s=i.organs,d=i.currently_cloning;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Liquid Storage",children:[(0,e.createComponentVNode)(2,t.Stack,{height:"25px",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"25%",children:["Biomass:"," "]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1,children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:c,ranges:{good:[2*m/3,m],average:[m/3,2*m/3],bad:[0,m/3]},minValue:0,maxValue:m})})]}),(0,e.createComponentVNode)(2,t.Stack,{height:"25px",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"25%",children:["Sanguine Reagent:"," "]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:l+" units"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.NumberInput,{value:0,minValue:0,maxValue:l,step:1,unit:"units",onChange:function(){function C(g,v){return h("remove_reagent",{reagent:"sanguine_reagent",amount:v})}return C}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Remove All",onClick:function(){function C(){return h("purge_reagent",{reagent:"sanguine_reagent"})}return C}()})})]}),(0,e.createComponentVNode)(2,t.Stack,{height:"25px",align:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{color:"label",width:"25%",children:["Osseous Reagent:"," "]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:u+" units"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.NumberInput,{value:0,minValue:0,maxValue:u,step:1,unit:"units",onChange:function(){function C(g,v){return h("remove_reagent",{reagent:"osseous_reagent",amount:v})}return C}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Remove All",onClick:function(){function C(){return h("purge_reagent",{reagent:"osseous_reagent"})}return C}()})})]})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Organ Storage",children:[!d&&(0,e.createComponentVNode)(2,t.Box,{children:[!s&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Notice: No organs loaded."}),!!s&&s.map(function(C){return(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:C.name}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:1}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Eject",onClick:function(){function g(){return h("eject_organ",{organ_ref:C.ref})}return g}()})})]},C)})]}),!!d&&(0,e.createComponentVNode)(2,t.Stack,{height:"100%",children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:"1",textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"lock",size:"5",mb:3}),(0,e.createVNode)(1,"br"),"Unable to access organ storage while cloning."]})})]})]})})}return b}()},18259:function(T,r,n){"use strict";r.__esModule=!0,r.CoinMint=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=n(98595),b=r.CoinMint=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.act,c=h.data,m=c.materials,l=c.moneyBag,u=c.moneyBagContent,s=c.moneyBagMaxContent,d=(l?210:138)+Math.ceil(m.length/4)*64;return(0,e.createComponentVNode)(2,p.Window,{width:210,height:d,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.NoticeBox,{m:0,info:!0,children:["Total coins produced: ",c.totalCoins]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Coin Type",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"power-off",color:c.active&&"bad",tooltip:!l&&"Need a money bag",disabled:!l,onClick:function(){function C(){return i("activate")}return C}()}),children:(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.ProgressBar,{minValue:0,maxValue:c.maxMaterials,value:c.totalMaterials})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:"eject",tooltip:"Eject selected material",onClick:function(){function C(){return i("ejectMat")}return C}()})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:m.map(function(C){return(0,e.createComponentVNode)(2,o.Button,{bold:!0,inline:!0,translucent:!0,m:.2,textAlign:"center",selected:C.id===c.chosenMaterial,tooltip:C.name,content:(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{className:(0,a.classes)(["materials32x32",C.id])}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:C.amount})]}),onClick:function(){function g(){return i("selectMaterial",{material:C.id})}return g}()},C.id)})})]})})}),!!l&&(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:"Money Bag",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"eject",content:"Eject",disabled:c.active,onClick:function(){function C(){return i("ejectBag")}return C}()}),children:(0,e.createComponentVNode)(2,o.ProgressBar,{width:"100%",minValue:0,maxValue:s,value:u,children:[u," / ",s]})})})]})})})}return y}()},93858:function(T,r,n){"use strict";r.__esModule=!0,r.HexColorInput=r.ColorSelector=r.ColorPickerModal=r.ColorInput=void 0;var e=n(89005),a=n(51057),t=n(72253),o=n(36036),p=n(98595),b=n(44879),y=n(14448),S=n(4454),k=n(35840),h=n(9394),i=n(19203),c=["prefixed","alpha","color","fluid","onChange"];/**
* @file
* @copyright 2023 itsmeow
* @license MIT
- */function m(w,A){w.prototype=Object.create(A.prototype),w.prototype.constructor=w,l(w,A)}function l(w,A){return l=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(x,E){return x.__proto__=E,x},l(w,A)}function u(w,A){if(w==null)return{};var x={};for(var E in w)if({}.hasOwnProperty.call(w,E)){if(A.includes(E))continue;x[E]=w[E]}return x}var s=r.ColorPickerModal=function(){function w(A,x){var E=(0,t.useBackend)(x),P=E.data,D=P.timeout,M=P.message,O=P.title,R=P.autofocus,F=P.default_color,W=F===void 0?"#000000":F,U=(0,t.useLocalState)(x,"color_picker_choice",(0,y.hexToHsva)(W)),z=U[0],$=U[1];return(0,e.createComponentVNode)(2,p.Window,{height:400,title:O,width:600,theme:"generic",children:[!!D&&(0,e.createComponentVNode)(2,a.Loader,{value:D}),(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[M&&(0,e.createComponentVNode)(2,o.Stack.Item,{m:1,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:(0,e.createComponentVNode)(2,o.Box,{color:"label",overflow:"hidden",children:M})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:[!!R&&(0,e.createComponentVNode)(2,o.Autofocus),(0,e.createComponentVNode)(2,d,{color:z,setColor:$,defaultColor:W})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,i.InputButtons,{input:(0,y.hsvaToHex)(z)})})]})})]})}return w}(),d=r.ColorSelector=function(){function w(A,x){var E=A.color,P=A.setColor,D=A.defaultColor,M=function(){function F(W){P(function(U){return Object.assign({},U,W)})}return F}(),O=(0,y.hsvaToRgba)(E),R=(0,y.hsvaToHex)(E);return(0,e.createComponentVNode)(2,o.Flex,{direction:"row",children:[(0,e.createComponentVNode)(2,o.Flex.Item,{mr:2,children:(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createVNode)(1,"div","react-colorful",[(0,e.createComponentVNode)(2,N,{hsva:E,onChange:M}),(0,e.createComponentVNode)(2,V,{hue:E.h,onChange:M,className:"react-colorful__last-control"})],4)}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:[(0,e.createComponentVNode)(2,o.Box,{inline:!0,width:"100px",height:"20px",textAlign:"center",children:"Current"}),(0,e.createComponentVNode)(2,o.Box,{inline:!0,width:"100px",height:"20px",textAlign:"center",children:"Previous"}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Tooltip,{content:R,position:"bottom",children:(0,e.createComponentVNode)(2,o.Box,{inline:!0,width:"100px",height:"30px",backgroundColor:R})}),(0,e.createComponentVNode)(2,o.Tooltip,{content:D,position:"bottom",children:(0,e.createComponentVNode)(2,o.Box,{inline:!0,width:"100px",height:"30px",backgroundColor:D})})]})]})}),(0,e.createComponentVNode)(2,o.Flex.Item,{grow:!0,fontSize:"15px",lineHeight:"24px",children:(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"Hex:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,height:"24px",children:(0,e.createComponentVNode)(2,C,{fluid:!0,color:(0,y.hsvaToHex)(E).substring(1),onChange:function(){function F(W){h.logger.info(W),P((0,y.hexToHsva)(W))}return F}(),prefixed:!0})})]})}),(0,e.createComponentVNode)(2,o.Stack.Divider),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"H:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,V,{hue:E.h,onChange:M})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,v,{value:E.h,callback:function(){function F(W,U){return M({h:U})}return F}(),max:360,unit:"\xB0"})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"S:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,B,{color:E,onChange:M})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,v,{value:E.s,callback:function(){function F(W,U){return M({s:U})}return F}(),unit:"%"})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"V:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,I,{color:E,onChange:M})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,v,{value:E.v,callback:function(){function F(W,U){return M({v:U})}return F}(),unit:"%"})})]})}),(0,e.createComponentVNode)(2,o.Stack.Divider),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"R:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,L,{color:E,onChange:M,target:"r"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,v,{value:O.r,callback:function(){function F(W,U){O.r=U,M((0,y.rgbaToHsva)(O))}return F}(),max:255})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"G:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,L,{color:E,onChange:M,target:"g"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,v,{value:O.g,callback:function(){function F(W,U){O.g=U,M((0,y.rgbaToHsva)(O))}return F}(),max:255})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"B:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,L,{color:E,onChange:M,target:"b"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,v,{value:O.b,callback:function(){function F(W,U){O.b=U,M((0,y.rgbaToHsva)(O))}return F}(),max:255})})]})})]})})]})}return w}(),v=function(A){var x=A.value,E=A.callback,P=A.min,D=P===void 0?0:P,M=A.max,O=M===void 0?100:M,R=A.unit;return(0,e.createComponentVNode)(2,o.NumberInput,{width:"70px",value:Math.round(x),step:1,minValue:D,maxValue:O,onChange:E,unit:R})},g=function(A){return"#"+A},C=r.HexColorInput=function(){function w(A){var x=A.prefixed,E=A.alpha,P=A.color,D=A.fluid,M=A.onChange,O=u(A,c),R=function(){function W(U){return U.replace(/([^0-9A-F]+)/gi,"").substring(0,E?8:6)}return W}(),F=function(){function W(U){return(0,y.validHex)(U,E)}return W}();return(0,e.normalizeProps)((0,e.createComponentVNode)(2,f,Object.assign({},O,{fluid:D,color:P,onChange:M,escape:R,format:x?g:void 0,validate:F})))}return w}(),f=r.ColorInput=function(w){function A(E){var P;return P=w.call(this)||this,P.props=void 0,P.state=void 0,P.handleInput=function(D){var M=P.props.escape(D.currentTarget.value);P.setState({localValue:M})},P.handleBlur=function(D){D.currentTarget&&(P.props.validate(D.currentTarget.value)?P.props.onChange(P.props.escape?P.props.escape(D.currentTarget.value):D.currentTarget.value):P.setState({localValue:P.props.escape(P.props.color)}))},P.props=E,P.state={localValue:P.props.escape(P.props.color)},P}m(A,w);var x=A.prototype;return x.componentDidUpdate=function(){function E(P,D){P.color!==this.props.color&&this.setState({localValue:this.props.escape(this.props.color)})}return E}(),x.render=function(){function E(){return(0,e.createComponentVNode)(2,o.Box,{className:(0,k.classes)(["Input",this.props.fluid&&"Input--fluid"]),children:[(0,e.createVNode)(1,"div","Input__baseline",".",16),(0,e.createVNode)(64,"input","Input__input",null,1,{value:this.props.format?this.props.format(this.state.localValue):this.state.localValue,spellCheck:"false",onInput:this.handleInput,onBlur:this.handleBlur})]})}return E}(),A}(e.Component),N=function(A){var x=A.hsva,E=A.onChange,P=function(R){E({s:R.left*100,v:100-R.top*100})},D=function(R){E({s:(0,b.clamp)(x.s+R.left*100,0,100),v:(0,b.clamp)(x.v-R.top*100,0,100)})},M={"background-color":(0,y.hsvaToHslString)({h:x.h,s:100,v:100,a:1})+" !important"};return(0,e.createVNode)(1,"div","react-colorful__saturation_value",(0,e.createComponentVNode)(2,S.Interactive,{onMove:P,onKey:D,"aria-label":"Color","aria-valuetext":"Saturation "+Math.round(x.s)+"%, Brightness "+Math.round(x.v)+"%",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__saturation_value-pointer",top:1-x.v/100,left:x.s/100,color:(0,y.hsvaToHslString)(x)})}),2,{style:M})},V=function(A){var x=A.className,E=A.hue,P=A.onChange,D=function(F){P({h:360*F.left})},M=function(F){P({h:(0,b.clamp)(E+F.left*360,0,360)})},O=(0,k.classes)(["react-colorful__hue",x]);return(0,e.createVNode)(1,"div",O,(0,e.createComponentVNode)(2,S.Interactive,{onMove:D,onKey:M,"aria-label":"Hue","aria-valuenow":Math.round(E),"aria-valuemax":"360","aria-valuemin":"0",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__hue-pointer",left:E/360,color:(0,y.hsvaToHslString)({h:E,s:100,v:100,a:1})})}),2)},B=function(A){var x=A.className,E=A.color,P=A.onChange,D=function(F){P({s:100*F.left})},M=function(F){P({s:(0,b.clamp)(E.s+F.left*100,0,100)})},O=(0,k.classes)(["react-colorful__saturation",x]);return(0,e.createVNode)(1,"div",O,(0,e.createComponentVNode)(2,S.Interactive,{style:{background:"linear-gradient(to right, "+(0,y.hsvaToHslString)({h:E.h,s:0,v:E.v,a:1})+", "+(0,y.hsvaToHslString)({h:E.h,s:100,v:E.v,a:1})+")"},onMove:D,onKey:M,"aria-label":"Saturation","aria-valuenow":Math.round(E.s),"aria-valuemax":"100","aria-valuemin":"0",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__saturation-pointer",left:E.s/100,color:(0,y.hsvaToHslString)({h:E.h,s:E.s,v:E.v,a:1})})}),2)},I=function(A){var x=A.className,E=A.color,P=A.onChange,D=function(F){P({v:100*F.left})},M=function(F){P({v:(0,b.clamp)(E.v+F.left*100,0,100)})},O=(0,k.classes)(["react-colorful__value",x]);return(0,e.createVNode)(1,"div",O,(0,e.createComponentVNode)(2,S.Interactive,{style:{background:"linear-gradient(to right, "+(0,y.hsvaToHslString)({h:E.h,s:E.s,v:0,a:1})+", "+(0,y.hsvaToHslString)({h:E.h,s:E.s,v:100,a:1})+")"},onMove:D,onKey:M,"aria-label":"Value","aria-valuenow":Math.round(E.s),"aria-valuemax":"100","aria-valuemin":"0",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__value-pointer",left:E.v/100,color:(0,y.hsvaToHslString)({h:E.h,s:E.s,v:E.v,a:1})})}),2)},L=function(A){var x=A.className,E=A.color,P=A.onChange,D=A.target,M=(0,y.hsvaToRgba)(E),O=function($){M[D]=$,P((0,y.rgbaToHsva)(M))},R=function($){O(255*$.left)},F=function($){O((0,b.clamp)(M[D]+$.left*255,0,255))},W=(0,k.classes)(["react-colorful__"+D,x]),U=D==="r"?"rgb("+Math.round(M.r)+",0,0)":D==="g"?"rgb(0,"+Math.round(M.g)+",0)":"rgb(0,0,"+Math.round(M.b)+")";return(0,e.createVNode)(1,"div",W,(0,e.createComponentVNode)(2,S.Interactive,{onMove:R,onKey:F,"aria-valuenow":M[D],"aria-valuemax":"100","aria-valuemin":"0",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__"+D+"-pointer",left:M[D]/255,color:U})}),2)}},8444:function(T,r,n){"use strict";r.__esModule=!0,r.ColourMatrixTester=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ColourMatrixTester=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.colour_data,m=[[{name:"RR",idx:0},{name:"RG",idx:1},{name:"RB",idx:2},{name:"RA",idx:3}],[{name:"GR",idx:4},{name:"GG",idx:5},{name:"GB",idx:6},{name:"GA",idx:7}],[{name:"BR",idx:8},{name:"BG",idx:9},{name:"BB",idx:10},{name:"BA",idx:11}],[{name:"AR",idx:12},{name:"AG",idx:13},{name:"AB",idx:14},{name:"AA",idx:15}]];return(0,e.createComponentVNode)(2,o.Window,{width:360,height:190,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Modify Matrix",children:m.map(function(l){return(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",textColor:"label",children:l.map(function(u){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,mt:1,children:[u.name,":\xA0",(0,e.createComponentVNode)(2,t.NumberInput,{width:4,value:c[u.idx],step:.05,minValue:-5,maxValue:5,stepPixelSize:5,onChange:function(){function s(d,v){return h("setvalue",{idx:u.idx+1,value:v})}return s}()})]},u.name)})},l)})})})})})}return b}()},63818:function(T,r,n){"use strict";r.__esModule=!0,r.CommunicationsComputer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(s){switch(s){case 1:return(0,e.createComponentVNode)(2,S);case 2:return(0,e.createComponentVNode)(2,i);case 3:return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,c)})});case 4:return(0,e.createComponentVNode)(2,l);default:return"ERROR. Unknown menu_state. Please contact NT Technical Support."}},b=r.CommunicationsComputer=function(){function u(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.menu_state;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y),p(f)]})})})}return u}(),y=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.authenticated,N=C.noauthbutton,V=C.esc_section,B=C.esc_callable,I=C.esc_recallable,L=C.esc_status,w=C.authhead,A=C.is_ai,x=C.lastCallLoc,E=!1,P;return f?f===1?P="Command":f===2?P="Captain":f===3?P="CentComm Officer":f===4?(P="CentComm Secure Connection",E=!0):P="ERROR: Report This Bug!":P="Not Logged In",(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Authentication",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:E&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Access",children:P})||(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:(0,e.createComponentVNode)(2,t.Button,{icon:f?"sign-out-alt":"id-card",selected:f,disabled:N,content:f?"Log Out ("+P+")":"Log In",onClick:function(){function D(){return g("auth")}return D}()})})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:!!V&&(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Escape Shuttle",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[!!L&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:L}),!!B&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Options",children:(0,e.createComponentVNode)(2,t.Button,{icon:"rocket",content:"Call Shuttle",disabled:!w,onClick:function(){function D(){return g("callshuttle")}return D}()})}),!!I&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Options",children:(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Recall Shuttle",disabled:!w||A,onClick:function(){function D(){return g("cancelshuttle")}return D}()})}),!!x&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Last Call/Recall From",children:x})]})})})],4)},S=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.is_admin;return f?(0,e.createComponentVNode)(2,k):(0,e.createComponentVNode)(2,h)},k=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.is_admin,N=C.gamma_armory_location,V=C.admin_levels,B=C.authenticated,I=C.ert_allowed;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"CentComm Actions",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Change Alert",children:(0,e.createComponentVNode)(2,m,{levels:V,required_access:f,use_confirm:1})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Announcement",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"bullhorn",content:"Make Central Announcement",disabled:!f,onClick:function(){function L(){return g("send_to_cc_announcement_page")}return L}()}),B===4&&(0,e.createComponentVNode)(2,t.Button,{icon:"plus",content:"Make Other Announcement",disabled:!f,onClick:function(){function L(){return g("make_other_announcement")}return L}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Response Team",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"ambulance",content:"Dispatch ERT",disabled:!f,onClick:function(){function L(){return g("dispatch_ert")}return L}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:I,content:I?"ERT calling enabled":"ERT calling disabled",tooltip:I?"Command can request an ERT":"ERTs cannot be requested",disabled:!f,onClick:function(){function L(){return g("toggle_ert_allowed")}return L}(),selected:null})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Nuclear Device",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"bomb",content:"Get Authentication Codes",disabled:!f,onClick:function(){function L(){return g("send_nuke_codes")}return L}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Gamma Armory",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"biohazard",content:N?"Send Gamma Armory":"Recall Gamma Armory",disabled:!f,onClick:function(){function L(){return g("move_gamma_armory")}return L}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Other",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"coins",content:"View Economy",disabled:!f,onClick:function(){function L(){return g("view_econ")}return L}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fax",content:"Fax Manager",disabled:!f,onClick:function(){function L(){return g("view_fax")}return L}()})]})]})}),(0,e.createComponentVNode)(2,t.Collapsible,{title:"View Command accessible controls",children:(0,e.createComponentVNode)(2,h)})]})},h=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.msg_cooldown,N=C.emagged,V=C.cc_cooldown,B=C.security_level_color,I=C.str_security_level,L=C.levels,w=C.authcapt,A=C.authhead,x=C.messages,E="Make Priority Announcement";f>0&&(E+=" ("+f+"s)");var P=N?"Message [UNKNOWN]":"Message CentComm",D="Request Authentication Codes";return V>0&&(P+=" ("+V+"s)",D+=" ("+V+"s)"),(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Captain-Only Actions",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Alert",color:B,children:I}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Change Alert",children:(0,e.createComponentVNode)(2,m,{levels:L,required_access:w})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Announcement",children:(0,e.createComponentVNode)(2,t.Button,{icon:"bullhorn",content:E,disabled:!w||f>0,onClick:function(){function M(){return g("announce")}return M}()})}),!!N&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Transmit",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"broadcast-tower",color:"red",content:P,disabled:!w||V>0,onClick:function(){function M(){return g("MessageSyndicate")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sync-alt",content:"Reset Relays",disabled:!w,onClick:function(){function M(){return g("RestoreBackup")}return M}()})]})||(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Transmit",children:(0,e.createComponentVNode)(2,t.Button,{icon:"broadcast-tower",content:P,disabled:!w||V>0,onClick:function(){function M(){return g("MessageCentcomm")}return M}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Nuclear Device",children:(0,e.createComponentVNode)(2,t.Button,{icon:"bomb",content:D,disabled:!w||V>0,onClick:function(){function M(){return g("nukerequest")}return M}()})})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Command Staff Actions",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Displays",children:(0,e.createComponentVNode)(2,t.Button,{icon:"tv",content:"Change Status Displays",disabled:!A,onClick:function(){function M(){return g("status")}return M}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Incoming Messages",children:(0,e.createComponentVNode)(2,t.Button,{icon:"folder-open",content:"View ("+x.length+")",disabled:!A,onClick:function(){function M(){return g("messagelist")}return M}()})})]})})})],4)},i=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.stat_display,N=C.authhead,V=C.current_message_title,B=f.presets.map(function(L){return(0,e.createComponentVNode)(2,t.Button,{content:L.label,selected:L.name===f.type,disabled:!N,onClick:function(){function w(){return g("setstat",{statdisp:L.name})}return w}()},L.name)}),I=f.alerts.map(function(L){return(0,e.createComponentVNode)(2,t.Button,{content:L.label,selected:L.alert===f.icon,disabled:!N,onClick:function(){function w(){return g("setstat",{statdisp:3,alert:L.alert})}return w}()},L.alert)});return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Modify Status Screens",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-left",content:"Back To Main Menu",onClick:function(){function L(){return g("main")}return L}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Presets",children:B}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Alerts",children:I}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Message Line 1",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:f.line_1,disabled:!N,onClick:function(){function L(){return g("setmsg1")}return L}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Message Line 2",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:f.line_2,disabled:!N,onClick:function(){function L(){return g("setmsg2")}return L}()})})]})})})},c=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.authhead,N=C.current_message_title,V=C.current_message,B=C.messages,I=C.security_level,L;if(N)L=(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:N,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Return To Message List",disabled:!f,onClick:function(){function A(){return g("messagelist")}return A}()}),children:(0,e.createComponentVNode)(2,t.Box,{children:V})})});else{var w=B.map(function(A){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:A.title,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"eye",content:"View",disabled:!f||N===A.title,onClick:function(){function x(){return g("messagelist",{msgid:A.id})}return x}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"times",content:"Delete",disabled:!f,onClick:function(){function x(){return g("delmessage",{msgid:A.id})}return x}()})]},A.id)});L=(0,e.createComponentVNode)(2,t.Section,{title:"Messages Received",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-left",content:"Back To Main Menu",onClick:function(){function A(){return g("main")}return A}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:w})})}return(0,e.createComponentVNode)(2,t.Box,{children:L})},m=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=s.levels,N=s.required_access,V=s.use_confirm,B=C.security_level;return V?f.map(function(I){return(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:I.icon,content:I.name,disabled:!N||I.id===B,tooltip:I.tooltip,onClick:function(){function L(){return g("newalertlevel",{level:I.id})}return L}()},I.name)}):f.map(function(I){return(0,e.createComponentVNode)(2,t.Button,{icon:I.icon,content:I.name,disabled:!N||I.id===B,tooltip:I.tooltip,onClick:function(){function L(){return g("newalertlevel",{level:I.id})}return L}()},I.name)})},l=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.is_admin,N=C.possible_cc_sounds;if(!f)return g("main");var V=(0,a.useLocalState)(d,"subtitle",""),B=V[0],I=V[1],L=(0,a.useLocalState)(d,"text",""),w=L[0],A=L[1],x=(0,a.useLocalState)(d,"classified",0),E=x[0],P=x[1],D=(0,a.useLocalState)(d,"beepsound","Beep"),M=D[0],O=D[1];return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Central Command Report",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-left",content:"Back To Main Menu",onClick:function(){function R(){return g("main")}return R}()}),children:[(0,e.createComponentVNode)(2,t.Input,{placeholder:"Enter Subtitle here.",fluid:!0,value:B,onChange:function(){function R(F,W){return I(W)}return R}(),mb:"5px"}),(0,e.createComponentVNode)(2,t.Input,{placeholder:"Enter Announcement here,\nMultiline input is accepted.",rows:10,fluid:!0,multiline:1,value:w,onChange:function(){function R(F,W){return A(W)}return R}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Send Announcement",fluid:!0,icon:"paper-plane",center:!0,mt:"5px",textAlign:"center",onClick:function(){function R(){return g("make_cc_announcement",{subtitle:B,text:w,classified:E,beepsound:M})}return R}()}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Dropdown,{width:"260px",height:"20px",options:N,selected:M,onSelected:function(){function R(F){return O(F)}return R}(),disabled:E})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"volume-up",mx:"5px",disabled:E,tooltip:"Test sound",onClick:function(){function R(){return g("test_sound",{sound:M})}return R}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:E,content:"Classified",fluid:!0,tooltip:E?"Sent to station communications consoles":"Publically announced",onClick:function(){function R(){return P(!E)}return R}()})})]})]})})}},20562:function(T,r,n){"use strict";r.__esModule=!0,r.CompostBin=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.CompostBin=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.biomass,m=i.compost,l=i.biomass_capacity,u=i.compost_capacity,s=i.potassium,d=i.potassium_capacity,v=i.potash,g=i.potash_capacity,C=(0,a.useSharedState)(S,"vendAmount",1),f=C[0],N=C[1];return(0,e.createComponentVNode)(2,o.Window,{width:360,height:250,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Section,{label:"Resources",children:(0,e.createComponentVNode)(2,t.Stack,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Biomass",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ml:.5,mt:1,width:20,value:c,minValue:0,maxValue:l,ranges:{good:[l*.5,1/0],average:[l*.25,l*.5],bad:[-1/0,l*.25]},children:[c," / ",l," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Compost",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ml:.5,mt:1,width:20,value:m,minValue:0,maxValue:u,ranges:{good:[u*.5,1/0],average:[u*.25,u*.5],bad:[-1/0,u*.25]},children:[m," / ",u," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Potassium",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ml:.5,mt:1,width:20,value:s,minValue:0,maxValue:d,ranges:{good:[d*.5,1/0],average:[d*.25,d*.5],bad:[-1/0,d*.25]},children:[s," / ",d," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Potash",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ml:.5,mt:1,width:20,value:v,minValue:0,maxValue:g,ranges:{good:[g*.5,1/0],average:[g*.25,g*.5],bad:[-1/0,g*.25]},children:[v," / ",g," Units"]})})]})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Controls",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{inline:!0,mr:"5px",color:"silver",children:"Soil clumps to make:"}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,value:f,width:"32px",minValue:1,maxValue:10,stepPixelSize:7,onChange:function(){function V(B,I){return N(I)}return V}()})],4),children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,align:"center",content:"Make Soil",disabled:m<25*f,icon:"arrow-circle-down",onClick:function(){function V(){return h("create",{amount:f})}return V}()})})})]})})})}return b}()},21813:function(T,r,n){"use strict";r.__esModule=!0,r.Contractor=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(73379),b=n(98595);function y(g,C){g.prototype=Object.create(C.prototype),g.prototype.constructor=g,S(g,C)}function S(g,C){return S=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,N){return f.__proto__=N,f},S(g,C)}var k={1:["ACTIVE","good"],2:["COMPLETED","good"],3:["FAILED","bad"]},h=["Recording biometric data...","Analyzing embedded syndicate info...","STATUS CONFIRMED","Contacting Syndicate database...","Awaiting response...","Awaiting response...","Awaiting response...","Awaiting response...","Awaiting response...","Awaiting response...","Response received, ack 4851234...","CONFIRM ACC "+Math.round(Math.random()*2e4),"Setting up private accounts...","CONTRACTOR ACCOUNT CREATED","Searching for available contracts...","Searching for available contracts...","Searching for available contracts...","Searching for available contracts...","CONTRACTS FOUND","WELCOME, AGENT"],i=r.Contractor=function(){function g(C,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I;B.unauthorized?I=(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",backgroundColor:"rgba(0, 0, 0, 0.8)",children:(0,e.createComponentVNode)(2,d,{height:"100%",allMessages:["ERROR: UNAUTHORIZED USER"],finishedTimeout:100,onFinished:function(){function x(){}return x}()})}):B.load_animation_completed?I=(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Flex.Item,{basis:"content",children:(0,e.createComponentVNode)(2,c)}),(0,e.createComponentVNode)(2,o.Flex.Item,{basis:"content",mt:"0.5rem",children:(0,e.createComponentVNode)(2,m)}),(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",overflow:"hidden",children:B.page===1?(0,e.createComponentVNode)(2,l,{height:"100%"}):(0,e.createComponentVNode)(2,s,{height:"100%"})})],4):I=(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",backgroundColor:"rgba(0, 0, 0, 0.8)",children:(0,e.createComponentVNode)(2,d,{height:"100%",allMessages:h,finishedTimeout:3e3,onFinished:function(){function x(){return V("complete_load_animation")}return x}()})});var L=(0,t.useLocalState)(f,"viewingPhoto",""),w=L[0],A=L[1];return(0,e.createComponentVNode)(2,b.Window,{theme:"syndicate",width:500,height:600,children:[w&&(0,e.createComponentVNode)(2,v),(0,e.createComponentVNode)(2,b.Window.Content,{className:"Contractor",children:(0,e.createComponentVNode)(2,o.Flex,{direction:"column",height:"100%",children:I})})]})}return g}(),c=function(C,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I=B.tc_available,L=B.tc_paid_out,w=B.completed_contracts,A=B.rep;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({title:"Summary",buttons:(0,e.createComponentVNode)(2,o.Box,{verticalAlign:"middle",mt:"0.25rem",children:[A," Rep"]})},C,{children:(0,e.createComponentVNode)(2,o.Flex,{children:[(0,e.createComponentVNode)(2,o.Box,{flexBasis:"50%",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"TC Available",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,o.Flex,{align:"center",children:[(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",children:[I," TC"]}),(0,e.createComponentVNode)(2,o.Button,{disabled:I<=0,content:"Claim",mx:"0.75rem",mb:"0",flexBasis:"content",onClick:function(){function x(){return V("claim")}return x}()})]})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"TC Earned",children:[L," TC"]})]})}),(0,e.createComponentVNode)(2,o.Box,{flexBasis:"50%",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Contracts Completed",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,o.Box,{height:"20px",lineHeight:"20px",inline:!0,children:w})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Contractor Status",verticalAlign:"middle",children:"ACTIVE"})]})})]})})))},m=function(C,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I=B.page;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Tabs,Object.assign({},C,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:I===1,onClick:function(){function L(){return V("page",{page:1})}return L}(),children:[(0,e.createComponentVNode)(2,o.Icon,{name:"suitcase"}),"Contracts"]}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:I===2,onClick:function(){function L(){return V("page",{page:2})}return L}(),children:[(0,e.createComponentVNode)(2,o.Icon,{name:"shopping-cart"}),"Hub"]})]})))},l=function(C,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I=B.contracts,L=B.contract_active,w=B.can_extract,A=!!L&&I.filter(function(M){return M.status===1})[0],x=A&&A.time_left>0,E=(0,t.useLocalState)(f,"viewingPhoto",""),P=E[0],D=E[1];return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({title:"Available Contracts",overflow:"auto",buttons:(0,e.createComponentVNode)(2,o.Button,{disabled:!w||x,icon:"parachute-box",content:["Call Extraction",x&&(0,e.createComponentVNode)(2,p.Countdown,{timeLeft:A.time_left,format:function(){function M(O,R){return" ("+R.substr(3)+")"}return M}()})],onClick:function(){function M(){return V("extract")}return M}()})},C,{children:I.slice().sort(function(M,O){return M.status===1?-1:O.status===1?1:M.status-O.status}).map(function(M){var O;return(0,e.createComponentVNode)(2,o.Section,{title:(0,e.createComponentVNode)(2,o.Flex,{children:[(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",color:M.status===1&&"good",children:M.target_name}),(0,e.createComponentVNode)(2,o.Flex.Item,{basis:"content",children:M.has_photo&&(0,e.createComponentVNode)(2,o.Button,{icon:"camera",mb:"-0.5rem",ml:"0.5rem",onClick:function(){function R(){return D("target_photo_"+M.uid+".png")}return R}()})})]}),className:"Contractor__Contract",buttons:(0,e.createComponentVNode)(2,o.Box,{width:"100%",children:[!!k[M.status]&&(0,e.createComponentVNode)(2,o.Box,{color:k[M.status][1],inline:!0,mt:M.status!==1&&"0.125rem",mr:"0.25rem",lineHeight:"20px",children:k[M.status][0]}),M.status===1&&(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"ban",color:"bad",content:"Abort",ml:"0.5rem",onClick:function(){function R(){return V("abort")}return R}()})]}),children:(0,e.createComponentVNode)(2,o.Flex,{children:[(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"2",mr:"0.5rem",children:[M.fluff_message,!!M.completed_time&&(0,e.createComponentVNode)(2,o.Box,{color:"good",children:[(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Icon,{name:"check",mr:"0.5rem"}),"Contract completed at ",M.completed_time]}),!!M.dead_extraction&&(0,e.createComponentVNode)(2,o.Box,{color:"bad",mt:"0.5rem",bold:!0,children:[(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-triangle",mr:"0.5rem"}),"Telecrystals reward reduced drastically as the target was dead during extraction."]}),!!M.fail_reason&&(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:[(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Icon,{name:"times",mr:"0.5rem"}),"Contract failed: ",M.fail_reason]})]}),(0,e.createComponentVNode)(2,o.Flex.Item,{flexBasis:"100%",children:[(0,e.createComponentVNode)(2,o.Flex,{mb:"0.5rem",color:"label",children:["Extraction Zone:\xA0",u(M)]}),(O=M.difficulties)==null?void 0:O.map(function(R,F){return(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:!!L,content:R.name+" ("+R.reward+" TC)",onClick:function(){function W(){return V("activate",{uid:M.uid,difficulty:F+1})}return W}()},F)}),!!M.objective&&(0,e.createComponentVNode)(2,o.Box,{color:"white",bold:!0,children:[M.objective.extraction_name,(0,e.createVNode)(1,"br"),"(",(M.objective.rewards.tc||0)+" TC",",\xA0",(M.objective.rewards.credits||0)+" Credits",")"]})]})]})},M.uid)})})))},u=function(C){if(!(!C.objective||C.status>1)){var f=C.objective.locs.user_area_id,N=C.objective.locs.user_coords,V=C.objective.locs.target_area_id,B=C.objective.locs.target_coords,I=f===V;return(0,e.createComponentVNode)(2,o.Flex.Item,{children:(0,e.createComponentVNode)(2,o.Icon,{name:I?"dot-circle-o":"arrow-alt-circle-right-o",color:I?"green":"yellow",rotation:I?null:-(0,a.rad2deg)(Math.atan2(B[1]-N[1],B[0]-N[0])),lineHeight:I?null:"0.85",size:"1.5"})})}},s=function(C,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I=B.rep,L=B.buyables;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({title:"Available Purchases",overflow:"auto"},C,{children:L.map(function(w){return(0,e.createComponentVNode)(2,o.Section,{title:w.name,children:[w.description,(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:I-1&&(0,e.createComponentVNode)(2,o.Box,{as:"span",color:w.stock===0?"bad":"good",ml:"0.5rem",children:[w.stock," in stock"]})]},w.uid)})})))},d=function(g){function C(N){var V;return V=g.call(this,N)||this,V.timer=null,V.state={currentIndex:0,currentDisplay:[]},V}y(C,g);var f=C.prototype;return f.tick=function(){function N(){var V=this.props,B=this.state;if(B.currentIndex<=V.allMessages.length){this.setState(function(L){return{currentIndex:L.currentIndex+1}});var I=B.currentDisplay;I.push(V.allMessages[B.currentIndex])}else clearTimeout(this.timer),setTimeout(V.onFinished,V.finishedTimeout)}return N}(),f.componentDidMount=function(){function N(){var V=this,B=this.props.linesPerSecond,I=B===void 0?2.5:B;this.timer=setInterval(function(){return V.tick()},1e3/I)}return N}(),f.componentWillUnmount=function(){function N(){clearTimeout(this.timer)}return N}(),f.render=function(){function N(){return(0,e.createComponentVNode)(2,o.Box,{m:1,children:this.state.currentDisplay.map(function(V){return(0,e.createFragment)([V,(0,e.createVNode)(1,"br")],0,V)})})}return N}(),C}(e.Component),v=function(C,f){var N=(0,t.useLocalState)(f,"viewingPhoto",""),V=N[0],B=N[1];return(0,e.createComponentVNode)(2,o.Modal,{className:"Contractor__photoZoom",children:[(0,e.createComponentVNode)(2,o.Box,{as:"img",src:V}),(0,e.createComponentVNode)(2,o.Button,{icon:"times",content:"Close",color:"grey",mt:"1rem",onClick:function(){function I(){return B("")}return I}()})]})}},54151:function(T,r,n){"use strict";r.__esModule=!0,r.ConveyorSwitch=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ConveyorSwitch=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.slowFactor,m=i.oneWay,l=i.position;return(0,e.createComponentVNode)(2,o.Window,{width:350,height:135,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Lever position",children:l>0?"forward":l<0?"reverse":"neutral"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Allow reverse",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!m,onClick:function(){function u(){return h("toggleOneWay")}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Slowdown factor",children:(0,e.createComponentVNode)(2,t.Flex,{children:[(0,e.createComponentVNode)(2,t.Flex.Item,{mx:"1px",children:[" ",(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-left",onClick:function(){function u(){return h("slowFactor",{value:c-5})}return u}()})," "]}),(0,e.createComponentVNode)(2,t.Flex.Item,{mx:"1px",children:[" ",(0,e.createComponentVNode)(2,t.Button,{icon:"angle-left",onClick:function(){function u(){return h("slowFactor",{value:c-1})}return u}()})," "]}),(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Slider,{width:"100px",mx:"1px",value:c,fillValue:c,minValue:1,maxValue:50,step:1,format:function(){function u(s){return s+"x"}return u}(),onChange:function(){function u(s,d){return h("slowFactor",{value:d})}return u}()})}),(0,e.createComponentVNode)(2,t.Flex.Item,{mx:"1px",children:[" ",(0,e.createComponentVNode)(2,t.Button,{icon:"angle-right",onClick:function(){function u(){return h("slowFactor",{value:c+1})}return u}()})," "]}),(0,e.createComponentVNode)(2,t.Flex.Item,{mx:"1px",children:[" ",(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-right",onClick:function(){function u(){return h("slowFactor",{value:c+5})}return u}()})," "]})]})})]})})})})}return b}()},73169:function(T,r,n){"use strict";r.__esModule=!0,r.CrewMonitor=void 0;var e=n(89005),a=n(88510),t=n(25328),o=n(72253),p=n(36036),b=n(36352),y=n(76910),S=n(98595),k=n(96184),h=["color"];function i(v,g){if(v==null)return{};var C={};for(var f in v)if({}.hasOwnProperty.call(v,f)){if(g.includes(f))continue;C[f]=v[f]}return C}var c=function(g,C){return g.dead?"Deceased":parseInt(g.health,10)<=C?"Critical":parseInt(g.stat,10)===1?"Unconscious":"Living"},m=function(g,C){return g.dead?"red":parseInt(g.health,10)<=C?"orange":parseInt(g.stat,10)===1?"blue":"green"},l=r.CrewMonitor=function(){function v(g,C){var f=(0,o.useBackend)(C),N=f.act,V=f.data,B=(0,o.useLocalState)(C,"tabIndex",V.tabIndex),I=B[0],L=B[1],w=function(){function x(E){L(E),N("set_tab_index",{tab_index:E})}return x}(),A=function(){function x(E){switch(E){case 0:return(0,e.createComponentVNode)(2,u);case 1:return(0,e.createComponentVNode)(2,d);default:return"WE SHOULDN'T BE HERE!"}}return x}();return(0,e.createComponentVNode)(2,S.Window,{width:800,height:600,children:(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,fillPositionedParent:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Tabs,{children:[(0,e.createComponentVNode)(2,p.Tabs.Tab,{icon:"table",selected:I===0,onClick:function(){function x(){return w(0)}return x}(),children:"Data View"},"DataView"),(0,e.createComponentVNode)(2,p.Tabs.Tab,{icon:"map-marked-alt",selected:I===1,onClick:function(){function x(){return w(1)}return x}(),children:"Map View"},"MapView")]})}),A(I)]})})})}return v}(),u=function(g,C){var f=(0,o.useBackend)(C),N=f.act,V=f.data,B=V.possible_levels,I=V.viewing_current_z_level,L=V.is_advanced,w=V.highlightedNames,A=(0,a.sortBy)(function(M){return!w.includes(M.name)},function(M){return M.name})(V.crewmembers||[]),x=(0,o.useLocalState)(C,"search",""),E=x[0],P=x[1],D=(0,t.createSearch)(E,function(M){return M.name+"|"+M.assignment+"|"+M.area});return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,backgroundColor:"transparent",children:[(0,e.createComponentVNode)(2,p.Stack,{children:[(0,e.createComponentVNode)(2,p.Stack.Item,{width:"100%",ml:"5px",children:(0,e.createComponentVNode)(2,p.Input,{placeholder:"Search by name, assignment or location..",width:"100%",onInput:function(){function M(O,R){return P(R)}return M}()})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:L?(0,e.createComponentVNode)(2,p.Dropdown,{mr:"5px",width:"50px",options:B,selected:I,onSelected:function(){function M(O){return N("switch_level",{new_level:O})}return M}()}):null})]}),(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,p.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:(0,e.createComponentVNode)(2,p.Button,{tooltip:"Clear highlights",icon:"square-xmark",onClick:function(){function M(){return N("clear_highlighted_names")}return M}()})}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Location"})]}),A.filter(D).map(function(M){var O=w.includes(M.name);return(0,e.createComponentVNode)(2,p.Table.Row,{bold:!!M.is_command,children:[(0,e.createComponentVNode)(2,b.TableCell,{children:(0,e.createComponentVNode)(2,k.ButtonCheckbox,{checked:O,tooltip:"Mark on map",onClick:function(){function R(){return N(O?"remove_highlighted_name":"add_highlighted_name",{name:M.name})}return R}()})}),(0,e.createComponentVNode)(2,b.TableCell,{children:[M.name," (",M.assignment,")"]}),(0,e.createComponentVNode)(2,b.TableCell,{children:[(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:m(M,V.critThreshold),children:c(M,V.critThreshold)}),M.sensor_type>=2||V.ignoreSensors?(0,e.createComponentVNode)(2,p.Box,{inline:!0,ml:1,children:["(",(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:y.COLORS.damageType.oxy,children:M.oxy}),"|",(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:y.COLORS.damageType.toxin,children:M.tox}),"|",(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:y.COLORS.damageType.burn,children:M.fire}),"|",(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:y.COLORS.damageType.brute,children:M.brute}),")"]}):null]}),(0,e.createComponentVNode)(2,b.TableCell,{children:M.sensor_type===3||V.ignoreSensors?V.isAI||V.isObserver?(0,e.createComponentVNode)(2,p.Button,{fluid:!0,icon:"location-arrow",content:M.area+" ("+M.x+", "+M.y+")",onClick:function(){function R(){return N("track",{track:M.ref})}return R}()}):M.area+" ("+M.x+", "+M.y+")":(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:"grey",children:"Not Available"})})]},M.name)})]})]})},s=function(g,C){var f=g.color,N=i(g,h);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.NanoMap.Marker,Object.assign({},N,{children:(0,e.createVNode)(1,"span","highlighted-marker color-border-"+f)})))},d=function(g,C){var f=(0,o.useBackend)(C),N=f.act,V=f.data,B=V.highlightedNames;return(0,e.createComponentVNode)(2,p.Box,{height:"100vh",mb:"0.5rem",overflow:"hidden",children:(0,e.createComponentVNode)(2,p.NanoMap,{zoom:V.zoom,offsetX:V.offsetX,offsetY:V.offsetY,onZoom:function(){function I(L){return N("set_zoom",{zoom:L})}return I}(),onOffsetChange:function(){function I(L,w){return N("set_offset",{offset_x:w.offsetX,offset_y:w.offsetY})}return I}(),children:V.crewmembers.filter(function(I){return I.sensor_type===3||V.ignoreSensors}).map(function(I){var L=m(I,V.critThreshold),w=B.includes(I.name),A=function(){return V.isObserver?N("track",{track:I.ref}):null},x=function(){return N(w?"remove_highlighted_name":"add_highlighted_name",{name:I.name})},E=I.name+" ("+I.assignment+")";return w?(0,e.createComponentVNode)(2,s,{x:I.x,y:I.y,tooltip:E,color:L,onClick:A,onDblClick:x},I.ref):(0,e.createComponentVNode)(2,p.NanoMap.MarkerIcon,{x:I.x,y:I.y,icon:"circle",tooltip:E,color:L,onClick:A,onDblClick:x},I.ref)})})})}},63987:function(T,r,n){"use strict";r.__esModule=!0,r.Cryo=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=[{label:"Resp.",type:"oxyLoss"},{label:"Toxin",type:"toxLoss"},{label:"Brute",type:"bruteLoss"},{label:"Burn",type:"fireLoss"}],b=[["good","Conscious"],["average","Unconscious"],["bad","DEAD"]],y=r.Cryo=function(){function h(i,c){return(0,e.createComponentVNode)(2,o.Window,{width:520,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,S)})})})}return h}(),S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.isOperating,d=u.hasOccupant,v=u.occupant,g=v===void 0?[]:v,C=u.cellTemperature,f=u.cellTemperatureStatus,N=u.isBeakerLoaded,V=u.cooldownProgress,B=u.auto_eject_healthy,I=u.auto_eject_dead;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Occupant",fill:!0,scrollable:!0,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"user-slash",onClick:function(){function L(){return l("ejectOccupant")}return L}(),disabled:!d,children:"Eject"}),children:d?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Occupant",children:g.name||"Unknown"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,t.ProgressBar,{min:g.health,max:g.maxHealth,value:g.health/g.maxHealth,color:g.health>0?"good":"average",children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:Math.round(g.health)})})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:b[g.stat][0],children:b[g.stat][1]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:Math.round(g.bodyTemperature)})," K"]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),p.map(function(L){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:L.label,children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:g[L.type]/100,ranges:{bad:[.01,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:Math.round(g[L.type])})})},L.id)})]}):(0,e.createComponentVNode)(2,t.Stack,{fill:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No occupant detected."]})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Cell",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"eject",onClick:function(){function L(){return l("ejectBeaker")}return L}(),disabled:!N,children:"Eject Beaker"}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",onClick:function(){function L(){return l(s?"switchOff":"switchOn")}return L}(),selected:s,children:s?"On":"Off"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",color:f,children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:C})," K"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Beaker",children:(0,e.createComponentVNode)(2,k)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Dosage interval",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ranges:{average:[-1/0,99],good:[99,1/0]},color:!N&&"average",value:V,minValue:0,maxValue:100})}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auto-eject healthy occupants",children:(0,e.createComponentVNode)(2,t.Button,{icon:B?"toggle-on":"toggle-off",selected:B,onClick:function(){function L(){return l(B?"auto_eject_healthy_off":"auto_eject_healthy_on")}return L}(),children:B?"On":"Off"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auto-eject dead occupants",children:(0,e.createComponentVNode)(2,t.Button,{icon:I?"toggle-on":"toggle-off",selected:I,onClick:function(){function L(){return l(I?"auto_eject_dead_off":"auto_eject_dead_on")}return L}(),children:I?"On":"Off"})})]})})})],4)},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.isBeakerLoaded,d=u.beakerLabel,v=u.beakerVolume;return s?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:!d&&"average",children:[d||"No label",":"]}),(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:!v&&"bad",ml:1,children:v?(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:v,format:function(){function g(C){return Math.round(C)+" units remaining"}return g}()}):"Beaker is empty"})],4):(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:"bad",children:"No beaker loaded"})}},86099:function(T,r,n){"use strict";r.__esModule=!0,r.CryopodConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(25328),b=r.CryopodConsole=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.account_name,u=m.allow_items;return(0,e.createComponentVNode)(2,o.Window,{title:"Cryopod Console",width:400,height:480,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Hello, "+(l||"[REDACTED]")+"!",children:"This automated cryogenic freezing unit will safely store your corporeal form until your next assignment."}),(0,e.createComponentVNode)(2,y),!!u&&(0,e.createComponentVNode)(2,S)]})})}return k}(),y=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.frozen_crew;return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Stored Crew",children:l.length?(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:l.map(function(u,s){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:u.name,children:u.rank},s)})})}):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No stored crew!"})})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.frozen_items,s=function(v){var g=v.toString();return g.startsWith("the ")&&(g=g.slice(4,g.length)),(0,p.toTitleCase)(g)};return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Stored Items",children:u.length?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:u.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:s(d.name),buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-down",content:"Drop",mr:1,onClick:function(){function v(){return m("one_item",{item:d.uid})}return v}()})},d)})})}),(0,e.createComponentVNode)(2,t.Button,{content:"Drop All Items",color:"red",onClick:function(){function d(){return m("all_items")}return d}()})],4):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No stored items!"})})}},12692:function(T,r,n){"use strict";r.__esModule=!0,r.DNAModifier=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=[["good","Alive"],["average","Critical"],["bad","DEAD"]],y=[["ui","Modify U.I.","dna"],["se","Modify S.E.","dna"],["buffer","Transfer Buffers","syringe"],["rejuvenators","Rejuvenators","flask"]],S=[5,10,20,30,50],k=r.DNAModifier=function(){function f(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.irradiating,A=L.dnaBlockSize,x=L.occupant;V.dnaBlockSize=A,V.isDNAInvalid=!x.isViableSubject||!x.uniqueIdentity||!x.structuralEnzymes;var E;return w&&(E=(0,e.createComponentVNode)(2,g,{duration:w})),(0,e.createComponentVNode)(2,o.Window,{width:660,height:775,children:[(0,e.createComponentVNode)(2,p.ComplexModal),E,(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,h)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,i)})]})})]})}return f}(),h=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.locked,A=L.hasOccupant,x=L.occupant;return(0,e.createComponentVNode)(2,t.Section,{title:"Occupant",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{color:"label",inline:!0,mr:"0.5rem",children:"Door Lock:"}),(0,e.createComponentVNode)(2,t.Button,{disabled:!A,selected:w,icon:w?"toggle-on":"toggle-off",content:w?"Engaged":"Disengaged",onClick:function(){function E(){return I("toggleLock")}return E}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!A||w,icon:"user-slash",content:"Eject",onClick:function(){function E(){return I("ejectOccupant")}return E}()})],4),children:A?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:x.name}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,t.ProgressBar,{min:x.minHealth,max:x.maxHealth,value:x.health/x.maxHealth,ranges:{good:[.5,1/0],average:[0,.5],bad:[-1/0,0]}})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:b[x.stat][0],children:b[x.stat][1]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider)]})}),V.isDNAInvalid?(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-circle"}),"\xA0 The occupant's DNA structure is ruined beyond recognition, please insert a subject with an intact DNA structure."]}):(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Radiation",children:(0,e.createComponentVNode)(2,t.ProgressBar,{min:"0",max:"100",value:x.radiationLevel/100,color:"average"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Unique Enzymes",children:L.occupant.uniqueEnzymes?L.occupant.uniqueEnzymes:(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-circle"}),"\xA0 Unknown"]})})]})],0):(0,e.createComponentVNode)(2,t.Box,{color:"label",children:"Cell unoccupied."})})},i=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.selectedMenuKey,A=L.hasOccupant,x=L.occupant;if(A){if(V.isDNAInvalid)return(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,align:"center",textAlign:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No operation possible on this subject."]})})})}else return(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,align:"center",textAlign:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No occupant in DNA modifier."]})})});var E;return w==="ui"?E=(0,e.createFragment)([(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,l)],4):w==="se"?E=(0,e.createFragment)([(0,e.createComponentVNode)(2,m),(0,e.createComponentVNode)(2,l)],4):w==="buffer"?E=(0,e.createComponentVNode)(2,u):w==="rejuvenators"&&(E=(0,e.createComponentVNode)(2,v)),(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Tabs,{children:y.map(function(P,D){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:P[2],selected:w===P[0],onClick:function(){function M(){return I("selectMenuKey",{key:P[0]})}return M}(),children:P[1]},D)})}),E]})},c=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.selectedUIBlock,A=L.selectedUISubBlock,x=L.selectedUITarget,E=L.occupant;return(0,e.createComponentVNode)(2,t.Section,{title:"Modify Unique Identifier",children:[(0,e.createComponentVNode)(2,C,{dnaString:E.uniqueIdentity,selectedBlock:w,selectedSubblock:A,blockSize:V.dnaBlockSize,action:"selectUIBlock"}),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target",children:(0,e.createComponentVNode)(2,t.Knob,{minValue:1,maxValue:15,stepPixelSize:"20",value:x,format:function(){function P(D){return D.toString(16).toUpperCase()}return P}(),ml:"0",onChange:function(){function P(D,M){return I("changeUITarget",{value:M})}return P}()})})}),(0,e.createComponentVNode)(2,t.Button,{icon:"radiation",content:"Irradiate Block",mt:"0.5rem",onClick:function(){function P(){return I("pulseUIRadiation")}return P}()})]})},m=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.selectedSEBlock,A=L.selectedSESubBlock,x=L.occupant;return(0,e.createComponentVNode)(2,t.Section,{title:"Modify Structural Enzymes",children:[(0,e.createComponentVNode)(2,C,{dnaString:x.structuralEnzymes,selectedBlock:w,selectedSubblock:A,blockSize:V.dnaBlockSize,action:"selectSEBlock"}),(0,e.createComponentVNode)(2,t.Button,{icon:"radiation",content:"Irradiate Block",onClick:function(){function E(){return I("pulseSERadiation")}return E}()})]})},l=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.radiationIntensity,A=L.radiationDuration;return(0,e.createComponentVNode)(2,t.Section,{title:"Radiation Emitter",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Intensity",children:(0,e.createComponentVNode)(2,t.Knob,{minValue:1,maxValue:10,stepPixelSize:20,value:w,popUpPosition:"right",ml:"0",onChange:function(){function x(E,P){return I("radiationIntensity",{value:P})}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Duration",children:(0,e.createComponentVNode)(2,t.Knob,{minValue:1,maxValue:20,stepPixelSize:10,unit:"s",value:A,popUpPosition:"right",ml:"0",onChange:function(){function x(E,P){return I("radiationDuration",{value:P})}return x}()})})]}),(0,e.createComponentVNode)(2,t.Button,{icon:"radiation",content:"Pulse Radiation",tooltip:"Mutates a random block of either the occupant's UI or SE.",tooltipPosition:"top-start",mt:"0.5rem",onClick:function(){function x(){return I("pulseRadiation")}return x}()})]})},u=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.buffers,A=w.map(function(x,E){return(0,e.createComponentVNode)(2,s,{id:E+1,name:"Buffer "+(E+1),buffer:x},E)});return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{height:"75%",mt:1,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Buffers",children:A})}),(0,e.createComponentVNode)(2,t.Stack.Item,{height:"25%",children:(0,e.createComponentVNode)(2,d)})]})},s=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=N.id,A=N.name,x=N.buffer,E=L.isInjectorReady,P=A+(x.data?" - "+x.label:"");return(0,e.createComponentVNode)(2,t.Box,{backgroundColor:"rgba(0, 0, 0, 0.33)",mb:"0.5rem",children:(0,e.createComponentVNode)(2,t.Section,{title:P,mx:"0",lineHeight:"18px",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Confirm,{disabled:!x.data,icon:"trash",content:"Clear",onClick:function(){function D(){return I("bufferOption",{option:"clear",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!x.data,icon:"pen",content:"Rename",onClick:function(){function D(){return I("bufferOption",{option:"changeLabel",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!x.data||!L.hasDisk,icon:"save",content:"Export",tooltip:"Exports this buffer to the currently loaded data disk.",tooltipPosition:"bottom-start",onClick:function(){function D(){return I("bufferOption",{option:"saveDisk",id:w})}return D}()})],4),children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Write",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-down",content:"Subject U.I",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"saveUI",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-down",content:"Subject U.I and U.E.",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"saveUIAndUE",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-down",content:"Subject S.E.",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"saveSE",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!L.hasDisk||!L.disk.data,icon:"arrow-circle-down",content:"From Disk",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"loadDisk",id:w})}return D}()})]}),!!x.data&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Subject",children:x.owner||(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Unknown"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Data Type",children:[x.type==="ui"?"Unique Identifiers":"Structural Enzymes",!!x.ue&&" and Unique Enzymes"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Transfer to",children:[(0,e.createComponentVNode)(2,t.Button,{disabled:!E,icon:E?"syringe":"spinner",iconSpin:!E,content:"Injector",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"createInjector",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!E,icon:E?"syringe":"spinner",iconSpin:!E,content:"Block Injector",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"createInjector",id:w,block:1})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"user",content:"Subject",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"transfer",id:w})}return D}()})]})],4)]}),!x.data&&(0,e.createComponentVNode)(2,t.Box,{color:"label",mt:"0.5rem",children:"This buffer is empty."})]})})},d=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.hasDisk,A=L.disk;return(0,e.createComponentVNode)(2,t.Section,{title:"Data Disk",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Confirm,{disabled:!w||!A.data,icon:"trash",content:"Wipe",onClick:function(){function x(){return I("wipeDisk")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!w,icon:"eject",content:"Eject",onClick:function(){function x(){return I("ejectDisk")}return x}()})],4),children:w?A.data?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Label",children:A.label?A.label:"No label"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Subject",children:A.owner?A.owner:(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Unknown"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Data Type",children:[A.type==="ui"?"Unique Identifiers":"Structural Enzymes",!!A.ue&&" and Unique Enzymes"]})]}):(0,e.createComponentVNode)(2,t.Box,{color:"label",children:"Disk is blank."}):(0,e.createComponentVNode)(2,t.Box,{color:"label",textAlign:"center",my:"1rem",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"save-o",size:"4"}),(0,e.createVNode)(1,"br"),"No disk inserted."]})})},v=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.isBeakerLoaded,A=L.beakerVolume,x=L.beakerLabel;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Rejuvenators and Beaker",buttons:(0,e.createComponentVNode)(2,t.Button,{disabled:!w,icon:"eject",content:"Eject",onClick:function(){function E(){return I("ejectBeaker")}return E}()}),children:w?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Inject",children:[S.map(function(E,P){return(0,e.createComponentVNode)(2,t.Button,{disabled:E>A,icon:"syringe",content:E,onClick:function(){function D(){return I("injectRejuvenators",{amount:E})}return D}()},P)}),(0,e.createComponentVNode)(2,t.Button,{disabled:A<=0,icon:"syringe",content:"All",onClick:function(){function E(){return I("injectRejuvenators",{amount:A})}return E}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Beaker",children:[(0,e.createComponentVNode)(2,t.Box,{mb:"0.5rem",children:x||"No label"}),A?(0,e.createComponentVNode)(2,t.Box,{color:"good",children:[A," unit",A===1?"":"s"," remaining"]}):(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"Empty"})]})]}):(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"flask",size:5,color:"silver"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"h3",null,"No beaker loaded.",16)]})})})},g=function(N,V){return(0,e.createComponentVNode)(2,t.Dimmer,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"spinner",size:"5",spin:!0}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Box,{color:"average",children:(0,e.createVNode)(1,"h1",null,[(0,e.createComponentVNode)(2,t.Icon,{name:"radiation"}),(0,e.createTextVNode)("\xA0Irradiating occupant\xA0"),(0,e.createComponentVNode)(2,t.Icon,{name:"radiation"})],4)}),(0,e.createComponentVNode)(2,t.Box,{color:"label",children:(0,e.createVNode)(1,"h3",null,[(0,e.createTextVNode)("For "),N.duration,(0,e.createTextVNode)(" second"),N.duration===1?"":"s"],0)})]})},C=function(N,V){for(var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=N.dnaString,A=N.selectedBlock,x=N.selectedSubblock,E=N.blockSize,P=N.action,D=w.split(""),M=0,O=[],R=function(){for(var U=F/E+1,z=[],$=function(){var J=G+1;z.push((0,e.createComponentVNode)(2,t.Button,{selected:A===U&&x===J,content:D[F+G],mb:"0",onClick:function(){function se(){return I(P,{block:U,subblock:J})}return se}()}))},G=0;Gd.spawnpoints?"red":"green",children:[d.total," total, versus ",d.spawnpoints," spawnpoints"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Dispatch",children:(0,e.createComponentVNode)(2,t.Button,{width:10.5,textAlign:"center",icon:"ambulance",content:"Send ERT",onClick:function(){function N(){return s("dispatch_ert",{silent:C})}return N}()})})]})})})},h=function(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,v=d.ert_request_messages;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:v&&v.length?v.map(function(g){return(0,e.createComponentVNode)(2,t.Section,{title:g.time,buttons:(0,e.createComponentVNode)(2,t.Button,{content:g.sender_real_name,onClick:function(){function C(){return s("view_player_panel",{uid:g.sender_uid})}return C}(),tooltip:"View player panel"}),children:g.message},(0,p.decodeHtmlEntities)(g.time))}):(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"average",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"broadcast-tower",size:5,color:"gray"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"No ERT requests."]})})})})},i=function(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,v=(0,a.useLocalState)(l,"text",""),g=v[0],C=v[1];return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Input,{placeholder:"Enter ERT denial reason here,\nMultiline input is accepted.",rows:19,fluid:!0,multiline:1,value:g,onChange:function(){function f(N,V){return C(V)}return f}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Deny ERT",fluid:!0,icon:"times",center:!0,mt:2,textAlign:"center",onClick:function(){function f(){return s("deny_ert",{reason:g})}return f}()})]})})}},90217:function(T,r,n){"use strict";r.__esModule=!0,r.EconomyManager=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=r.EconomyManager=function(){function S(k,h){return(0,e.createComponentVNode)(2,o.Window,{width:600,height:325,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,className:"Layout__content--flexColumn",children:(0,e.createComponentVNode)(2,y)})]})}return S}(),y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.next_payroll_time;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.4rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"coins",verticalAlign:"middle",size:3,mr:"1rem"}),"Economy Manager"]}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.LabeledList,{label:"Pay Bonuses and Deductions",children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Global",children:(0,e.createComponentVNode)(2,t.Button,{icon:"dollar-sign",width:"auto",content:"Global Payroll Modification",onClick:function(){function u(){return c("payroll_modification",{mod_type:"global"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Department Accounts",children:(0,e.createComponentVNode)(2,t.Button,{icon:"dollar-sign",width:"auto",content:"Department Account Payroll Modification",onClick:function(){function u(){return c("payroll_modification",{mod_type:"department"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Department Members",children:(0,e.createComponentVNode)(2,t.Button,{icon:"dollar-sign",width:"auto",content:"Department Members Payroll Modification",onClick:function(){function u(){return c("payroll_modification",{mod_type:"department_members"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Single Accounts",children:(0,e.createComponentVNode)(2,t.Button,{icon:"dollar-sign",width:"auto",content:"Crew Member Payroll Modification",onClick:function(){function u(){return c("payroll_modification",{mod_type:"crew_member"})}return u}()})})]}),(0,e.createVNode)(1,"hr"),(0,e.createComponentVNode)(2,t.Box,{mb:.5,children:["Next Payroll in: ",l," Minutes"]}),(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-left",width:"auto",color:"bad",content:"Delay Payroll",onClick:function(){function u(){return c("delay_payroll")}return u}()}),(0,e.createComponentVNode)(2,t.Button,{width:"auto",content:"Set Payroll Time",onClick:function(){function u(){return c("set_payroll")}return u}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-right",width:"auto",color:"good",content:"Accelerate Payroll",onClick:function(){function u(){return c("accelerate_payroll")}return u}()})]}),(0,e.createComponentVNode)(2,t.NoticeBox,{children:[(0,e.createVNode)(1,"b",null,"WARNING:",16)," You take full responsibility for unbalancing the economy with these buttons!"]})],4)}},82565:function(T,r,n){"use strict";r.__esModule=!0,r.Electropack=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.Electropack=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.act,c=h.data,m=c.power,l=c.code,u=c.frequency,s=c.minFrequency,d=c.maxFrequency;return(0,e.createComponentVNode)(2,p.Window,{width:360,height:135,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,o.Button,{icon:m?"power-off":"times",content:m?"On":"Off",selected:m,onClick:function(){function v(){return i("power")}return v}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Frequency",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"sync",content:"Reset",onClick:function(){function v(){return i("reset",{reset:"freq"})}return v}()}),children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,unit:"kHz",step:.2,stepPixelSize:6,minValue:s/10,maxValue:d/10,value:u/10,format:function(){function v(g){return(0,a.toFixed)(g,1)}return v}(),width:"80px",onChange:function(){function v(g,C){return i("freq",{freq:C})}return v}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Code",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"sync",content:"Reset",onClick:function(){function v(){return i("reset",{reset:"code"})}return v}()}),children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:1,stepPixelSize:6,minValue:1,maxValue:100,value:l,width:"80px",onChange:function(){function v(g,C){return i("code",{code:C})}return v}()})})]})})})})}return y}()},11243:function(T,r,n){"use strict";r.__esModule=!0,r.Emojipedia=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=n(98595),b=r.Emojipedia=function(){function S(k,h){var i=(0,t.useBackend)(h),c=i.data,m=c.emoji_list,l=(0,t.useLocalState)(h,"searchText",""),u=l[0],s=l[1],d=m.filter(function(v){return v.name.toLowerCase().includes(u.toLowerCase())});return(0,e.createComponentVNode)(2,p.Window,{width:325,height:400,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Emojipedia v1.0.1",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Input,{placeholder:"Search by name",value:u,onInput:function(){function v(g,C){return s(C)}return v}()}),(0,e.createComponentVNode)(2,o.Button,{tooltip:"Click on an emoji to copy its tag!",tooltipPosition:"bottom",icon:"circle-question"})],4),children:d.map(function(v){return(0,e.createComponentVNode)(2,o.Button,{m:1,color:"transparent",className:(0,a.classes)(["emoji16x16","emoji-"+v.name]),style:{transform:"scale(1.5)"},tooltip:v.name,onClick:function(){function g(){y(v.name)}return g}()},v.name)})})})})}return S}(),y=function(k){var h=document.createElement("input"),i=":"+k+":";h.value=i,document.body.appendChild(h),h.select(),document.execCommand("copy"),document.body.removeChild(h)}},36730:function(T,r,n){"use strict";r.__esModule=!0,r.EvolutionMenu=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=n(64795),y=n(88510),S=r.EvolutionMenu=function(){function i(c,m){return(0,e.createComponentVNode)(2,p.Window,{width:480,height:580,theme:"changeling",children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,h)]})})})}return i}(),k=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.evo_points,v=s.can_respec;return(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:"Evolution Points",height:5.5,children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{mt:.5,color:"label",children:"Points remaining:"}),(0,e.createComponentVNode)(2,o.Stack.Item,{mt:.5,ml:2,bold:!0,color:"#1b945c",children:d}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:[(0,e.createComponentVNode)(2,o.Button,{ml:2.5,disabled:!v,content:"Readapt",icon:"sync",onClick:function(){function g(){return u("readapt")}return g}()}),(0,e.createComponentVNode)(2,o.Button,{tooltip:"By transforming a humanoid into a husk, we gain the ability to readapt our chosen evolutions.",tooltipPosition:"bottom",icon:"question-circle"})]})]})})})},h=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.evo_points,v=s.ability_tabs,g=s.purchased_abilities,C=s.view_mode,f=(0,t.useLocalState)(m,"selectedTab",v[0]),N=f[0],V=f[1],B=(0,t.useLocalState)(m,"searchText",""),I=B[0],L=B[1],w=(0,t.useLocalState)(m,"ability_tabs",v[0].abilities),A=w[0],x=w[1],E=function(O,R){if(R===void 0&&(R=""),!O||O.length===0)return[];var F=(0,a.createSearch)(R,function(W){return W.name+"|"+W.description});return(0,b.flow)([(0,y.filter)(function(W){return W==null?void 0:W.name}),(0,y.filter)(F),(0,y.sortBy)(function(W){return W==null?void 0:W.name})])(O)},P=function(O){if(L(O),O==="")return x(N.abilities);x(E(v.map(function(R){return R.abilities}).flat(),O))},D=function(O){V(O),x(O.abilities),L("")};return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Abilities",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Input,{width:"200px",placeholder:"Search Abilities",onInput:function(){function M(O,R){P(R)}return M}(),value:I}),(0,e.createComponentVNode)(2,o.Button,{icon:C?"square-o":"check-square-o",selected:!C,content:"Compact",onClick:function(){function M(){return u("set_view_mode",{mode:0})}return M}()}),(0,e.createComponentVNode)(2,o.Button,{icon:C?"check-square-o":"square-o",selected:C,content:"Expanded",onClick:function(){function M(){return u("set_view_mode",{mode:1})}return M}()})],4),children:[(0,e.createComponentVNode)(2,o.Tabs,{children:v.map(function(M){return(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:I===""&&N===M,onClick:function(){function O(){D(M)}return O}(),children:M.category},M)})}),A.map(function(M,O){return(0,e.createComponentVNode)(2,o.Box,{p:.5,mx:-1,className:"candystripe",children:[(0,e.createComponentVNode)(2,o.Stack,{align:"center",children:[(0,e.createComponentVNode)(2,o.Stack.Item,{ml:.5,color:"#dedede",children:M.name}),g.includes(M.power_path)&&(0,e.createComponentVNode)(2,o.Stack.Item,{ml:2,bold:!0,color:"#1b945c",children:"(Purchased)"}),(0,e.createComponentVNode)(2,o.Stack.Item,{mr:3,textAlign:"right",grow:1,children:[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:["Cost:"," "]}),(0,e.createComponentVNode)(2,o.Box,{as:"span",bold:!0,color:"#1b945c",children:M.cost})]}),(0,e.createComponentVNode)(2,o.Stack.Item,{textAlign:"right",children:(0,e.createComponentVNode)(2,o.Button,{mr:.5,disabled:M.cost>d||g.includes(M.power_path),content:"Evolve",onClick:function(){function R(){return u("purchase",{power_path:M.power_path})}return R}()})})]}),!!C&&(0,e.createComponentVNode)(2,o.Stack,{color:"#8a8a8a",my:1,ml:1.5,width:"95%",children:M.description+" "+M.helptext})]},O)})]})})}},17370:function(T,r,n){"use strict";r.__esModule=!0,r.ExosuitFabricator=void 0;var e=n(89005),a=n(35840),t=n(25328),o=n(72253),p=n(36036),b=n(73379),y=n(98595),S=["id","amount","lineDisplay","onClick"];function k(f,N){if(f==null)return{};var V={};for(var B in f)if({}.hasOwnProperty.call(f,B)){if(N.includes(B))continue;V[B]=f[B]}return V}var h=2e3,i={bananium:"clown",tranquillite:"mime"},c=r.ExosuitFabricator=function(){function f(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.building,A=L.linked;return A?(0,e.createComponentVNode)(2,y.Window,{width:950,height:625,children:(0,e.createComponentVNode)(2,y.Window.Content,{className:"Exofab",children:[(0,e.createComponentVNode)(2,C),(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,l)}),w&&(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,u)})]})}),(0,e.createComponentVNode)(2,p.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,m)}),(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,s)})]})})]})]})}):(0,e.createComponentVNode)(2,g)}return f}(),m=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.materials,A=L.capacity,x=Object.values(w).reduce(function(E,P){return E+P},0);return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,title:"Materials",className:"Exofab__materials",buttons:(0,e.createComponentVNode)(2,p.Box,{color:"label",mt:"0.25rem",children:[(x/A*100).toPrecision(3),"% full"]}),children:["metal","glass","silver","gold","uranium","titanium","plasma","diamond","bluespace","bananium","tranquillite","plastic"].map(function(E){return(0,e.createComponentVNode)(2,d,{mt:-2,id:E,bold:E==="metal"||E==="glass",onClick:function(){function P(){return I("withdraw",{id:E})}return P}()},E)})})},l=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.curCategory,A=L.categories,x=L.designs,E=L.syncing,P=(0,o.useLocalState)(V,"searchText",""),D=P[0],M=P[1],O=(0,t.createSearch)(D,function(z){return z.name}),R=x.filter(O),F=(0,o.useLocalState)(V,"levelsModal",!1),W=F[0],U=F[1];return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,className:"Exofab__designs",title:(0,e.createComponentVNode)(2,p.Dropdown,{width:"19rem",className:"Exofab__dropdown",selected:w,options:A,onSelected:function(){function z($){return I("category",{cat:$})}return z}()}),buttons:(0,e.createComponentVNode)(2,p.Box,{mt:"2px",children:[(0,e.createComponentVNode)(2,p.Button,{icon:"plus",content:"Queue all",onClick:function(){function z(){return I("queueall")}return z}()}),(0,e.createComponentVNode)(2,p.Button,{icon:"info",content:"Show current tech levels",onClick:function(){function z(){return U(!0)}return z}()}),(0,e.createComponentVNode)(2,p.Button,{icon:"unlink",color:"red",tooltip:"Disconnect from R&D network",onClick:function(){function z(){return I("unlink")}return z}()})]}),children:[(0,e.createComponentVNode)(2,p.Input,{placeholder:"Search by name...",mb:"0.5rem",width:"100%",onInput:function(){function z($,G){return M(G)}return z}()}),R.map(function(z){return(0,e.createComponentVNode)(2,v,{design:z},z.id)}),R.length===0&&(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"No designs found."})]})},u=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.building,A=L.buildStart,x=L.buildEnd,E=L.worldTime;return(0,e.createComponentVNode)(2,p.Section,{className:"Exofab__building",stretchContents:!0,children:(0,e.createComponentVNode)(2,p.ProgressBar.Countdown,{start:A,current:E,end:x,children:(0,e.createComponentVNode)(2,p.Stack,{children:[(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Icon,{name:"cog",spin:!0})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:["Building ",w,"\xA0(",(0,e.createComponentVNode)(2,b.Countdown,{current:E,timeLeft:x-E,format:function(){function P(D,M){return M.substr(3)}return P}()}),")"]})]})})})},s=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.queue,A=L.processingQueue,x=Object.entries(L.queueDeficit).filter(function(P){return P[1]<0}),E=w.reduce(function(P,D){return P+D.time},0);return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,className:"Exofab__queue",title:"Queue",buttons:(0,e.createComponentVNode)(2,p.Box,{children:[(0,e.createComponentVNode)(2,p.Button,{selected:A,icon:A?"toggle-on":"toggle-off",content:"Process",onClick:function(){function P(){return I("process")}return P}()}),(0,e.createComponentVNode)(2,p.Button,{disabled:w.length===0,icon:"eraser",content:"Clear",onClick:function(){function P(){return I("unqueueall")}return P}()})]}),children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:w.length===0?(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"The queue is empty."}):(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Stack.Item,{className:"Exofab__queue--queue",grow:!0,overflow:"auto",children:w.map(function(P,D){return(0,e.createComponentVNode)(2,p.Box,{color:P.notEnough&&"bad",children:[D+1,". ",P.name,D>0&&(0,e.createComponentVNode)(2,p.Button,{icon:"arrow-up",onClick:function(){function M(){return I("queueswap",{from:D+1,to:D})}return M}()}),D0&&(0,e.createComponentVNode)(2,p.Stack.Item,{className:"Exofab__queue--time",children:[(0,e.createComponentVNode)(2,p.Divider),"Processing time:",(0,e.createComponentVNode)(2,p.Icon,{name:"clock",mx:"0.5rem"}),(0,e.createComponentVNode)(2,p.Box,{inline:!0,bold:!0,children:new Date(E/10*1e3).toISOString().substr(14,5)})]}),Object.keys(x).length>0&&(0,e.createComponentVNode)(2,p.Stack.Item,{className:"Exofab__queue--deficit",shrink:"0",children:[(0,e.createComponentVNode)(2,p.Divider),"Lacking materials to complete:",x.map(function(P){return(0,e.createComponentVNode)(2,p.Box,{children:(0,e.createComponentVNode)(2,d,{id:P[0],amount:-P[1],lineDisplay:!0})},P[0])})]})],0)})})},d=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=N.id,A=N.amount,x=N.lineDisplay,E=N.onClick,P=k(N,S),D=L.materials[w]||0,M=A||D;if(!(M<=0&&!(w==="metal"||w==="glass"))){var O=A&&A>D;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.Stack,Object.assign({align:"center",className:(0,a.classes)(["Exofab__material",x&&"Exofab__material--line"])},P,{children:x?(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Stack.Item,{className:(0,a.classes)(["materials32x32",w])}),(0,e.createComponentVNode)(2,p.Stack.Item,{className:"Exofab__material--amount",color:O&&"bad",ml:0,mr:1,children:M.toLocaleString("en-US")})],4):(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Stack.Item,{basis:"content",children:(0,e.createComponentVNode)(2,p.Button,{width:"85%",color:"transparent",onClick:E,children:(0,e.createComponentVNode)(2,p.Box,{mt:1,className:(0,a.classes)(["materials32x32",w])})})}),(0,e.createComponentVNode)(2,p.Stack.Item,{grow:"1",children:[(0,e.createComponentVNode)(2,p.Box,{className:"Exofab__material--name",children:w}),(0,e.createComponentVNode)(2,p.Box,{className:"Exofab__material--amount",children:[M.toLocaleString("en-US")," cm\xB3 (",Math.round(M/h*10)/10," ","sheets)"]})]})],4)})))}},v=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=N.design;return(0,e.createComponentVNode)(2,p.Box,{className:"Exofab__design",children:[(0,e.createComponentVNode)(2,p.Button,{disabled:w.notEnough||L.building,icon:"cog",content:w.name,onClick:function(){function A(){return I("build",{id:w.id})}return A}()}),(0,e.createComponentVNode)(2,p.Button,{icon:"plus-circle",onClick:function(){function A(){return I("queue",{id:w.id})}return A}()}),(0,e.createComponentVNode)(2,p.Box,{className:"Exofab__design--cost",children:Object.entries(w.cost).map(function(A){return(0,e.createComponentVNode)(2,p.Box,{children:(0,e.createComponentVNode)(2,d,{id:A[0],amount:A[1],lineDisplay:!0})},A[0])})}),(0,e.createComponentVNode)(2,p.Stack,{className:"Exofab__design--time",children:(0,e.createComponentVNode)(2,p.Stack.Item,{children:[(0,e.createComponentVNode)(2,p.Icon,{name:"clock"}),w.time>0?(0,e.createFragment)([w.time/10,(0,e.createTextVNode)(" seconds")],0):"Instant"]})})]})},g=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.controllers;return(0,e.createComponentVNode)(2,y.Window,{children:(0,e.createComponentVNode)(2,y.Window.Content,{children:(0,e.createComponentVNode)(2,p.Section,{title:"Setup Linkage",children:(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,p.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Link"})]}),w.map(function(A){return(0,e.createComponentVNode)(2,p.Table.Row,{children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:A.addr}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:A.net_id}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:(0,e.createComponentVNode)(2,p.Button,{content:"Link",icon:"link",onClick:function(){function x(){return I("linktonetworkcontroller",{target_controller:A.addr})}return x}()})})]},A.addr)})]})})})})},C=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.tech_levels,A=(0,o.useLocalState)(V,"levelsModal",!1),x=A[0],E=A[1];return x?(0,e.createComponentVNode)(2,p.Modal,{maxWidth:"75%",width:window.innerWidth+"px",maxHeight:window.innerHeight*.75+"px",mx:"auto",children:(0,e.createComponentVNode)(2,p.Section,{title:"Current tech levels",buttons:(0,e.createComponentVNode)(2,p.Button,{content:"Close",onClick:function(){function P(){E(!1)}return P}()}),children:(0,e.createComponentVNode)(2,p.LabeledList,{children:w.map(function(P){var D=P.name,M=P.level;return(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:D,children:M},D)})})})}):null}},59128:function(T,r,n){"use strict";r.__esModule=!0,r.ExperimentConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=new Map([[0,{text:"Conscious",color:"good"}],[1,{text:"Unconscious",color:"average"}],[2,{text:"Deceased",color:"bad"}]]),b=new Map([[0,{label:"Probe",icon:"thermometer"}],[1,{label:"Dissect",icon:"brain"}],[2,{label:"Analyze",icon:"search"}]]),y=r.ExperimentConsole=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.open,u=m.feedback,s=m.occupant,d=m.occupant_name,v=m.occupant_status,g=function(){function f(){if(!s)return(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No specimen detected."});var N=function(){function B(){return p.get(v)}return B}(),V=N();return(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:d}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:V.color,children:V.text}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Experiments",children:[0,1,2].map(function(B){return(0,e.createComponentVNode)(2,t.Button,{icon:b.get(B).icon,content:b.get(B).label,onClick:function(){function I(){return c("experiment",{experiment_type:B})}return I}()},B)})})]})}return f}(),C=g();return(0,e.createComponentVNode)(2,o.Window,{theme:"abductor",width:350,height:200,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:u})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Scanner",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:"Eject",disabled:!l,onClick:function(){function f(){return c("door")}return f}()}),children:C})]})})}return S}()},97086:function(T,r,n){"use strict";r.__esModule=!0,r.ExternalAirlockController=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=0,b=1013,y=function(h){var i="good",c=80,m=95,l=110,u=120;return hl?i="average":h>u&&(i="bad"),i},S=r.ExternalAirlockController=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.chamber_pressure,s=l.exterior_status,d=l.interior_status,v=l.processing;return(0,e.createComponentVNode)(2,o.Window,{width:330,height:205,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Information",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Chamber Pressure",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:y(u),value:u,minValue:p,maxValue:b,children:[u," kPa"]})})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Actions",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Abort",icon:"ban",color:"red",disabled:!v,onClick:function(){function g(){return m("abort")}return g}()}),children:[(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{width:"49%",content:"Cycle to Exterior",icon:"arrow-circle-left",disabled:v,onClick:function(){function g(){return m("cycle_ext")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{width:"50%",content:"Cycle to Interior",icon:"arrow-circle-right",disabled:v,onClick:function(){function g(){return m("cycle_int")}return g}()})]}),(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{width:"49%",content:"Force Exterior Door",icon:"exclamation-triangle",color:d==="open"?"red":v?"yellow":null,onClick:function(){function g(){return m("force_ext")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{width:"50%",content:"Force Interior Door",icon:"exclamation-triangle",color:d==="open"?"red":v?"yellow":null,onClick:function(){function g(){return m("force_int")}return g}()})]})]})]})})}return k}()},96142:function(T,r,n){"use strict";r.__esModule=!0,r.FaxMachine=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.FaxMachine=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;return(0,e.createComponentVNode)(2,o.Window,{width:540,height:295,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Authorization",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID Card",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.scan_name?"eject":"id-card",selected:i.scan_name,content:i.scan_name?i.scan_name:"-----",tooltip:i.scan_name?"Eject ID":"Insert ID",onClick:function(){function c(){return h("scan")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Authorize",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.authenticated?"sign-out-alt":"id-card",selected:i.authenticated,disabled:i.nologin,content:i.realauth?"Log Out":"Log In",onClick:function(){function c(){return h("auth")}return c}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Fax Menu",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Network",children:i.network}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Document",children:[(0,e.createComponentVNode)(2,t.Button,{icon:i.paper?"eject":"paperclip",disabled:!i.authenticated&&!i.paper,content:i.paper?i.paper:"-----",onClick:function(){function c(){return h("paper")}return c}()}),!!i.paper&&(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:"Rename",onClick:function(){function c(){return h("rename")}return c}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Sending To",children:(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:i.destination?i.destination:"-----",disabled:!i.authenticated,onClick:function(){function c(){return h("dept")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Action",children:(0,e.createComponentVNode)(2,t.Button,{icon:"envelope",content:i.sendError?i.sendError:"Send",disabled:!i.paper||!i.destination||!i.authenticated||i.sendError,onClick:function(){function c(){return h("send")}return c}()})})]})})]})})}return b}()},74123:function(T,r,n){"use strict";r.__esModule=!0,r.FilingCabinet=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.FilingCabinet=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=k.config,m=i.contents,l=c.title;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:300,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Contents",children:[!m&&(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"average",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"folder-open",size:5,color:"gray"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"The ",l," is empty."]})}),!!m&&m.slice().map(function(u){return(0,e.createComponentVNode)(2,t.Stack,{mt:.5,className:"candystripe",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"80%",children:u.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-down",content:"Retrieve",onClick:function(){function s(){return h("retrieve",{index:u.index})}return s}()})})]},u)})]})})})})}return b}()},83767:function(T,r,n){"use strict";r.__esModule=!0,r.FloorPainter=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=k.icon_state,u=k.direction,s=k.isSelected,d=k.onSelect;return(0,e.createComponentVNode)(2,t.DmIcon,{icon:m.icon,icon_state:l,direction:u,onClick:d,style:{"border-style":s&&"solid"||"none","border-width":"2px","border-color":"orange",padding:s&&"0px"||"2px"}})},b={NORTH:1,SOUTH:2,EAST:4,WEST:8},y=r.FloorPainter=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.availableStyles,u=m.selectedStyle,s=m.selectedDir;return(0,e.createComponentVNode)(2,o.Window,{width:405,height:475,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Decal setup",children:[(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-left",onClick:function(){function d(){return c("cycle_style",{offset:-1})}return d}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Dropdown,{options:l,selected:u,width:"150px",nochevron:!0,onSelected:function(){function d(v){return c("select_style",{style:v})}return d}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-right",onClick:function(){function d(){return c("cycle_style",{offset:1})}return d}()})})]}),(0,e.createComponentVNode)(2,t.Box,{mt:"5px",mb:"5px",children:(0,e.createComponentVNode)(2,t.Flex,{overflowY:"auto",maxHeight:"239px",wrap:"wrap",children:l.map(function(d){return(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,p,{icon_state:d,isSelected:u===d,onSelect:function(){function v(){return c("select_style",{style:d})}return v}()})},d)})})}),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Direction",children:(0,e.createComponentVNode)(2,t.Table,{style:{display:"inline"},children:[b.NORTH,null,b.SOUTH].map(function(d){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[d+b.WEST,d,d+b.EAST].map(function(v){return(0,e.createComponentVNode)(2,t.Table.Cell,{style:{"vertical-align":"middle","text-align":"center"},children:v===null?(0,e.createComponentVNode)(2,t.Icon,{name:"arrows-alt",size:3}):(0,e.createComponentVNode)(2,p,{icon_state:u,direction:v,isSelected:v===s,onSelect:function(){function g(){return c("select_direction",{direction:v})}return g}()})},v)})},d)})})})})]})})})}return S}()},53424:function(T,r,n){"use strict";r.__esModule=!0,r.GPS=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=function(l){return l?"("+l.join(", ")+")":"ERROR"},y=function(l,u){if(!(!l||!u)){if(l[2]!==u[2])return null;var s=Math.atan2(u[1]-l[1],u[0]-l[0]),d=Math.sqrt(Math.pow(u[1]-l[1],2)+Math.pow(u[0]-l[0],2));return{angle:(0,a.rad2deg)(s),distance:d}}},S=r.GPS=function(){function m(l,u){var s=(0,t.useBackend)(u),d=s.data,v=d.emped,g=d.active,C=d.area,f=d.position,N=d.saved;return(0,e.createComponentVNode)(2,p.Window,{width:400,height:600,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:v?(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,basis:"0",children:(0,e.createComponentVNode)(2,k,{emp:!0})}):(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,h)}),g?(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,i,{area:C,position:f})}),N&&(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,i,{title:"Saved Position",position:N})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,basis:"0",children:(0,e.createComponentVNode)(2,c,{height:"100%"})})],0):(0,e.createComponentVNode)(2,k)],0)})})})}return m}(),k=function(l,u){var s=l.emp;return(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:(0,e.createComponentVNode)(2,o.Box,{width:"100%",height:"100%",color:"label",textAlign:"center",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon,{name:s?"ban":"power-off",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),s?"ERROR: Device temporarily lost signal.":"Device is disabled."]})})})})},h=function(l,u){var s=(0,t.useBackend)(u),d=s.act,v=s.data,g=v.active,C=v.tag,f=v.same_z,N=(0,t.useLocalState)(u,"newTag",C),V=N[0],B=N[1];return(0,e.createComponentVNode)(2,o.Section,{title:"Settings",buttons:(0,e.createComponentVNode)(2,o.Button,{selected:g,icon:g?"toggle-on":"toggle-off",content:g?"On":"Off",onClick:function(){function I(){return d("toggle")}return I}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Tag",children:[(0,e.createComponentVNode)(2,o.Input,{width:"5rem",value:C,onEnter:function(){function I(){return d("tag",{newtag:V})}return I}(),onInput:function(){function I(L,w){return B(w)}return I}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:C===V,width:"20px",mb:"0",ml:"0.25rem",onClick:function(){function I(){return d("tag",{newtag:V})}return I}(),children:(0,e.createComponentVNode)(2,o.Icon,{name:"pen"})})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Range",children:(0,e.createComponentVNode)(2,o.Button,{selected:!f,icon:f?"compress":"expand",content:f?"Local Sector":"Global",onClick:function(){function I(){return d("same_z")}return I}()})})]})})},i=function(l,u){var s=l.title,d=l.area,v=l.position;return(0,e.createComponentVNode)(2,o.Section,{title:s||"Position",children:(0,e.createComponentVNode)(2,o.Box,{fontSize:"1.5rem",children:[d&&(0,e.createFragment)([d,(0,e.createVNode)(1,"br")],0),b(v)]})})},c=function(l,u){var s=(0,t.useBackend)(u),d=s.data,v=d.position,g=d.signals;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({fill:!0,scrollable:!0,title:"Signals"},l,{children:(0,e.createComponentVNode)(2,o.Table,{children:g.map(function(C){return Object.assign({},C,y(v,C.position))}).map(function(C,f){return(0,e.createComponentVNode)(2,o.Table.Row,{backgroundColor:f%2===0&&"rgba(255, 255, 255, 0.05)",children:[(0,e.createComponentVNode)(2,o.Table.Cell,{width:"30%",verticalAlign:"middle",color:"label",p:"0.25rem",bold:!0,children:C.tag}),(0,e.createComponentVNode)(2,o.Table.Cell,{verticalAlign:"middle",color:"grey",children:C.area}),(0,e.createComponentVNode)(2,o.Table.Cell,{verticalAlign:"middle",collapsing:!0,children:C.distance!==void 0&&(0,e.createComponentVNode)(2,o.Box,{opacity:Math.max(1-Math.min(C.distance,100)/100,.5),children:[(0,e.createComponentVNode)(2,o.Icon,{name:C.distance>0?"arrow-right":"circle",rotation:-C.angle}),"\xA0",Math.floor(C.distance)+"m"]})}),(0,e.createComponentVNode)(2,o.Table.Cell,{verticalAlign:"middle",pr:"0.25rem",collapsing:!0,children:b(C.position)})]},f)})})})))}},89124:function(T,r,n){"use strict";r.__esModule=!0,r.GeneModder=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(3939),p=n(98595),b=r.GeneModder=function(){function u(s,d){var v=(0,a.useBackend)(d),g=v.data,C=g.has_seed;return(0,e.createComponentVNode)(2,p.Window,{width:950,height:650,children:[(0,e.createVNode)(1,"div","GeneModder__left",(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,l,{scrollable:!0})}),2),(0,e.createVNode)(1,"div","GeneModder__right",(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:[(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,o.ComplexModal,{maxWidth:"75%",maxHeight:"75%"}),C===0?(0,e.createComponentVNode)(2,S):(0,e.createComponentVNode)(2,y)]})}),2)]})}return u}(),y=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.disk;return(0,e.createComponentVNode)(2,t.Section,{title:"Genes",fill:!0,scrollable:!0,children:[(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c)]})},S=function(s,d){return(0,e.createComponentVNode)(2,t.Section,{fill:!0,height:"85%",children:(0,e.createComponentVNode)(2,t.Stack,{height:"100%",children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:"1",textAlign:"center",align:"center",color:"green",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"leaf",size:5,mb:"10px"}),(0,e.createVNode)(1,"br"),"The plant DNA manipulator is missing a seed."]})})})},k=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.has_seed,N=C.seed,V=C.has_disk,B=C.disk,I,L;return f?I=(0,e.createComponentVNode)(2,t.Stack.Item,{mb:"-6px",mt:"-4px",children:[(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+N.image,style:{"vertical-align":"middle",width:"32px",margin:"-1px","margin-left":"-11px"}}),(0,e.createComponentVNode)(2,t.Button,{content:N.name,onClick:function(){function w(){return g("eject_seed")}return w}()}),(0,e.createComponentVNode)(2,t.Button,{ml:"3px",icon:"pen",tooltip:"Name Variant",onClick:function(){function w(){return g("variant_name")}return w}()})]}):I=(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{ml:3.3,content:"None",onClick:function(){function w(){return g("eject_seed")}return w}()})}),V?L=B.name:L="None",(0,e.createComponentVNode)(2,t.Section,{title:"Storage",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Plant Sample",children:I}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Data Disk",children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{ml:3.3,content:L,tooltip:"Select Empty Disk",onClick:function(){function w(){return g("select_empty_disk")}return w}()})})})]})})},h=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.disk,N=C.core_genes;return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Core Genes",open:!0,children:[N.map(function(V){return(0,e.createComponentVNode)(2,t.Stack,{py:"2px",className:"candystripe",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"100%",ml:"2px",children:V.name}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Extract",disabled:!(f!=null&&f.can_extract),icon:"save",onClick:function(){function B(){return g("extract",{id:V.id})}return B}()})})]},V)})," ",(0,e.createComponentVNode)(2,t.Stack,{children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Extract All",disabled:!(f!=null&&f.can_extract),icon:"save",onClick:function(){function V(){return g("bulk_extract_core")}return V}()})})})]},"Core Genes")},i=function(s,d){var v=(0,a.useBackend)(d),g=v.data,C=g.reagent_genes,f=g.has_reagent;return(0,e.createComponentVNode)(2,m,{title:"Reagent Genes",gene_set:C,do_we_show:f})},c=function(s,d){var v=(0,a.useBackend)(d),g=v.data,C=g.trait_genes,f=g.has_trait;return(0,e.createComponentVNode)(2,m,{title:"Trait Genes",gene_set:C,do_we_show:f})},m=function(s,d){var v=s.title,g=s.gene_set,C=s.do_we_show,f=(0,a.useBackend)(d),N=f.act,V=f.data,B=V.disk;return(0,e.createComponentVNode)(2,t.Collapsible,{title:v,open:!0,children:C?g.map(function(I){return(0,e.createComponentVNode)(2,t.Stack,{py:"2px",className:"candystripe",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"100%",ml:"2px",children:I.name}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Extract",disabled:!(B!=null&&B.can_extract),icon:"save",onClick:function(){function L(){return N("extract",{id:I.id})}return L}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Remove",icon:"times",onClick:function(){function L(){return N("remove",{id:I.id})}return L}()})})]},I)}):(0,e.createComponentVNode)(2,t.Stack.Item,{children:"No Genes Detected"})},v)},l=function(s,d){var v=s.title,g=s.gene_set,C=s.do_we_show,f=(0,a.useBackend)(d),N=f.act,V=f.data,B=V.has_seed,I=V.empty_disks,L=V.stat_disks,w=V.trait_disks,A=V.reagent_disks;return(0,e.createComponentVNode)(2,t.Section,{title:"Disks",children:[(0,e.createVNode)(1,"br"),"Empty Disks: ",I,(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{width:12,icon:"arrow-down",tooltip:"Eject an Empty disk",content:"Eject Empty Disk",onClick:function(){function x(){return N("eject_empty_disk")}return x}()}),(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Stats",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:[L.slice().sort(function(x,E){return x.display_name.localeCompare(E.display_name)}).map(function(x){return(0,e.createComponentVNode)(2,t.Stack,{mr:2,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"49%",children:x.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:25,children:[x.stat==="All"?(0,e.createComponentVNode)(2,t.Button,{content:"Replace All",tooltip:"Write disk stats to seed",disabled:!(x!=null&&x.ready)||!B,icon:"arrow-circle-down",onClick:function(){function E(){return N("bulk_replace_core",{index:x.index})}return E}()}):(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-circle-down",tooltip:"Write disk stat to seed",disabled:!x||!B,content:"Replace",onClick:function(){function E(){return N("replace",{index:x.index,stat:x.stat})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-right",content:"Select",tooltip:"Choose as target for extracted genes",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("select",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:5,icon:"arrow-down",content:"Eject",tooltip:"Eject Disk",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("eject_disk",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:2,icon:x.read_only?"lock":"lock-open",content:"",tool_tip:"Set/unset Read Only",onClick:function(){function E(){return N("set_read_only",{index:x.index,read_only:x.read_only})}return E}()})]})]},x)}),(0,e.createComponentVNode)(2,t.Button)]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Traits",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:[w.slice().sort(function(x,E){return x.display_name.localeCompare(E.display_name)}).map(function(x){return(0,e.createComponentVNode)(2,t.Stack,{mr:2,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"49%",children:x.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:25,children:[(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-circle-down",disabled:!x||!x.can_insert,tooltip:"Add disk trait to seed",content:"Insert",onClick:function(){function E(){return N("insert",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-right",content:"Select",tooltip:"Choose as target for extracted genes",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("select",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:5,icon:"arrow-down",content:"Eject",tooltip:"Eject Disk",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("eject_disk",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:2,icon:x.read_only?"lock":"lock-open",content:"",tool_tip:"Set/unset Read Only",onClick:function(){function E(){return N("set_read_only",{index:x.index,read_only:x.read_only})}return E}()})]})]},x)}),(0,e.createComponentVNode)(2,t.Button)]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Reagents",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:[A.slice().sort(function(x,E){return x.display_name.localeCompare(E.display_name)}).map(function(x){return(0,e.createComponentVNode)(2,t.Stack,{mr:2,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"49%",children:x.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:25,children:[(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-circle-down",disabled:!x||!x.can_insert,tooltip:"Add disk reagent to seed",content:"Insert",onClick:function(){function E(){return N("insert",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-right",content:"Select",tooltip:"Choose as target for extracted genes",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("select",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:5,icon:"arrow-down",content:"Eject",tooltip:"Eject Disk",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("eject_disk",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:2,icon:x.read_only?"lock":"lock-open",content:"",tool_tip:"Set/unset Read Only",onClick:function(){function E(){return N("set_read_only",{index:x.index,read_only:x.read_only})}return E}()})]})]},x)}),(0,e.createComponentVNode)(2,t.Button)]})})]})]})}},73053:function(T,r,n){"use strict";r.__esModule=!0,r.GenericCrewManifest=void 0;var e=n(89005),a=n(36036),t=n(98595),o=n(41874),p=r.GenericCrewManifest=function(){function b(y,S){return(0,e.createComponentVNode)(2,t.Window,{theme:"nologo",width:588,height:510,children:(0,e.createComponentVNode)(2,t.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,a.Section,{noTopPadding:!0,children:(0,e.createComponentVNode)(2,o.CrewManifest)})})})}return b}()},42914:function(T,r,n){"use strict";r.__esModule=!0,r.GhostHudPanel=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.GhostHudPanel=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.data,c=i.security,m=i.medical,l=i.diagnostic,u=i.radioactivity,s=i.ahud;return(0,e.createComponentVNode)(2,o.Window,{width:250,height:207,theme:"nologo",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,b,{label:"Medical",type:"medical",is_active:m}),(0,e.createComponentVNode)(2,b,{label:"Security",type:"security",is_active:c}),(0,e.createComponentVNode)(2,b,{label:"Diagnostic",type:"diagnostic",is_active:l}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,b,{label:"Radioactivity",type:"radioactivity",is_active:u,act_on:"rads_on",act_off:"rads_off"}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,b,{label:"Antag HUD",is_active:s,act_on:"ahud_on",act_off:"ahud_off"})]})})})}return y}(),b=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=S.label,m=S.type,l=m===void 0?null:m,u=S.is_active,s=S.act_on,d=s===void 0?"hud_on":s,v=S.act_off,g=v===void 0?"hud_off":v;return(0,e.createComponentVNode)(2,t.Flex,{pt:.3,color:"label",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{pl:.5,align:"center",width:"80%",children:c}),(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Button,{mr:.6,content:u?"On":"Off",icon:u?"toggle-on":"toggle-off",selected:u,onClick:function(){function C(){return i(u?g:d,{hud_type:l})}return C}()})})]})}},25825:function(T,r,n){"use strict";r.__esModule=!0,r.GlandDispenser=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.GlandDispenser=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.glands,m=c===void 0?[]:c;return(0,e.createComponentVNode)(2,o.Window,{width:300,height:338,theme:"abductor",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:m.map(function(l){return(0,e.createComponentVNode)(2,t.Button,{width:"60px",height:"60px",m:.75,textAlign:"center",fontSize:"17px",lineHeight:"55px",icon:"eject",backgroundColor:l.color,content:l.amount||"0",disabled:!l.amount,onClick:function(){function u(){return h("dispense",{gland_id:l.id})}return u}()},l.id)})})})})}return b}()},10270:function(T,r,n){"use strict";r.__esModule=!0,r.GravityGen=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.GravityGen=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.charging_state,m=i.charge_count,l=i.breaker,u=i.ext_power,s=function(){function v(g){return g>0?(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:"average",children:["[ ",g===1?"Charging":"Discharging"," ]"]}):(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:u?"good":"bad",children:["[ ",u?"Powered":"Unpowered"," ]"]})}return v}(),d=function(){function v(g){if(g>0)return(0,e.createComponentVNode)(2,t.NoticeBox,{danger:!0,p:1.5,children:[(0,e.createVNode)(1,"b",null,"WARNING:",16)," Radiation Detected!"]})}return v}();return(0,e.createComponentVNode)(2,o.Window,{width:350,height:170,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[d(c),(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Generator Status",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:l?"power-off":"times",content:l?"Online":"Offline",color:l?"green":"red",px:1.5,onClick:function(){function v(){return h("breaker")}return v}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power Status",color:u?"good":"bad",children:s(c)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Gravity Charge",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:m/100,ranges:{good:[.9,1/0],average:[.5,.9],bad:[-1/0,.5]}})})]})})]})})})}return b}()},48657:function(T,r,n){"use strict";r.__esModule=!0,r.GuestPass=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(49148),b=r.GuestPass=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:690,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"id-card",selected:!c.showlogs,onClick:function(){function m(){return i("mode",{mode:0})}return m}(),children:"Issue Pass"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"scroll",selected:c.showlogs,onClick:function(){function m(){return i("mode",{mode:1})}return m}(),children:["Records (",c.issue_log.length,")"]})]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Authorization",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID Card",children:(0,e.createComponentVNode)(2,t.Button,{icon:c.scan_name?"eject":"id-card",selected:c.scan_name,content:c.scan_name?c.scan_name:"-----",tooltip:c.scan_name?"Eject ID":"Insert ID",onClick:function(){function m(){return i("scan")}return m}()})})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:!c.showlogs&&(0,e.createComponentVNode)(2,t.Section,{title:"Issue Guest Pass",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Issue To",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:c.giv_name?c.giv_name:"-----",disabled:!c.scan_name,onClick:function(){function m(){return i("giv_name")}return m}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Reason",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:c.reason?c.reason:"-----",disabled:!c.scan_name,onClick:function(){function m(){return i("reason")}return m}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Duration",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:c.duration?c.duration:"-----",disabled:!c.scan_name,onClick:function(){function m(){return i("duration")}return m}()})})]})})}),!c.showlogs&&(c.scan_name?(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.AccessList,{sectionButtons:(0,e.createComponentVNode)(2,t.Button,{icon:"id-card",content:c.printmsg,disabled:!c.canprint,onClick:function(){function m(){return i("issue")}return m}()}),grantableList:c.grantableList,accesses:c.regions,selectedList:c.selectedAccess,accessMod:function(){function m(l){return i("access",{access:l})}return m}(),grantAll:function(){function m(){return i("grant_all")}return m}(),denyAll:function(){function m(){return i("clear_all")}return m}(),grantDep:function(){function m(l){return i("grant_region",{region:l})}return m}(),denyDep:function(){function m(l){return i("deny_region",{region:l})}return m}()})}):(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,fontSize:1.5,textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"id-card",size:5,color:"gray",mb:5}),(0,e.createVNode)(1,"br"),"Please, insert ID Card"]})})})})),!!c.showlogs&&(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,m:0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Issuance Log",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:"Print",disabled:!c.scan_name,onClick:function(){function m(){return i("print")}return m}()}),children:!!c.issue_log.length&&(0,e.createComponentVNode)(2,t.LabeledList,{children:c.issue_log.map(function(m,l){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:m},l)})})||(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,fontSize:1.5,textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"scroll",size:5,color:"gray"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"No logs"]})})})})]})})})}return y}()},67834:function(T,r,n){"use strict";r.__esModule=!0,r.HandheldChemDispenser=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=[1,5,10,20,30,50],b=null,y=r.HandheldChemDispenser=function(){function h(i,c){return(0,e.createComponentVNode)(2,o.Window,{width:390,height:430,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k)]})})})}return h}(),S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.amount,d=u.energy,v=u.maxEnergy,g=u.mode;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Energy",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:d,minValue:0,maxValue:v,ranges:{good:[v*.5,1/0],average:[v*.25,v*.5],bad:[-1/0,v*.25]},children:[d," / ",v," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Amount",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,t.Stack,{children:p.map(function(C,f){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,width:"15%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"cog",selected:s===C,content:C,onClick:function(){function N(){return l("amount",{amount:C})}return N}()})},f)})})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mode",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,t.Stack,{justify:"space-between",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"cog",selected:g==="dispense",content:"Dispense",m:"0",width:"32%",onClick:function(){function C(){return l("mode",{mode:"dispense"})}return C}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"cog",selected:g==="remove",content:"Remove",m:"0",width:"32%",onClick:function(){function C(){return l("mode",{mode:"remove"})}return C}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"cog",selected:g==="isolate",content:"Isolate",m:"0",width:"32%",onClick:function(){function C(){return l("mode",{mode:"isolate"})}return C}()})]})})]})})})},k=function(i,c){for(var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.chemicals,d=s===void 0?[]:s,v=u.current_reagent,g=[],C=0;C<(d.length+1)%3;C++)g.push(!0);return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,height:"18%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:u.glass?"Drink Selector":"Chemical Selector",children:[d.map(function(f,N){return(0,e.createComponentVNode)(2,t.Button,{width:"32%",icon:"arrow-circle-down",overflow:"hidden",textOverflow:"ellipsis",selected:v===f.id,content:f.title,style:{"margin-left":"2px"},onClick:function(){function V(){return l("dispense",{reagent:f.id})}return V}()},N)}),g.map(function(f,N){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:"1",basis:"25%"},N)})]})})}},46098:function(T,r,n){"use strict";r.__esModule=!0,r.HealthSensor=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.HealthSensor=function(){function S(k,h){var i=(0,t.useBackend)(h),c=i.act,m=i.data,l=m.on,u=m.user_health,s=m.minHealth,d=m.maxHealth,v=m.alarm_health;return(0,e.createComponentVNode)(2,p.Window,{width:300,height:125,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Scanning",children:(0,e.createComponentVNode)(2,o.Button,{icon:"power-off",content:l?"On":"Off",color:l?null:"red",selected:l,onClick:function(){function g(){return c("scan_toggle")}return g}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Health activation",children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:2,stepPixelSize:6,minValue:s,maxValue:d,value:v,format:function(){function g(C){return(0,a.toFixed)(C,1)}return g}(),width:"80px",onDrag:function(){function g(C,f){return c("alarm_health",{alarm_health:f})}return g}()})}),u!==null&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"User health",children:(0,e.createComponentVNode)(2,o.Box,{color:y(u),bold:u>=100,children:(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:u})})})]})})})})}return S}(),y=function(k){return k>50?"green":k>0?"orange":"red"}},36771:function(T,r,n){"use strict";r.__esModule=!0,r.Holodeck=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Holodeck=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=(0,a.useLocalState)(k,"currentDeck",""),l=m[0],u=m[1],s=(0,a.useLocalState)(k,"showReload",!1),d=s[0],v=s[1],g=c.decks,C=c.ai_override,f=c.emagged,N=function(){function V(B){i("select_deck",{deck:B}),u(B),v(!0),setTimeout(function(){v(!1)},3e3)}return V}();return(0,e.createComponentVNode)(2,o.Window,{width:400,height:320,children:[d&&(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Holodeck Control System",children:(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createVNode)(1,"b",null,"Currently Loaded Program:",16)," ",l]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Available Programs",children:[g.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{width:15.5,color:"transparent",content:V,selected:V===l,onClick:function(){function B(){return N(V)}return B}()},V)}),(0,e.createVNode)(1,"hr",null,null,1,{color:"gray"}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[!!C&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Override Protocols",children:(0,e.createComponentVNode)(2,t.Button,{content:f?"Turn On":"Turn Off",color:f?"good":"bad",onClick:function(){function V(){return i("ai_override")}return V}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Safety Protocols",children:(0,e.createComponentVNode)(2,t.Box,{color:f?"bad":"good",children:[f?"Off":"On",!!f&&(0,e.createComponentVNode)(2,t.Button,{ml:9.5,width:15.5,color:"red",content:"Wildlife Simulation",onClick:function(){function V(){return i("wildlifecarp")}return V}()})]})})]})]})})]})})]})}return y}(),b=function(S,k){return(0,e.createComponentVNode)(2,t.Dimmer,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"spinner",size:"5",spin:!0}),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Box,{color:"white",children:(0,e.createVNode)(1,"h1",null,"\xA0Recalibrating projection apparatus.\xA0",16)}),(0,e.createComponentVNode)(2,t.Box,{color:"label",children:(0,e.createVNode)(1,"h3",null,"Please, wait for 3 seconds.",16)})]})}},25471:function(T,r,n){"use strict";r.__esModule=!0,r.Instrument=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.Instrument=function(){function i(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data;return(0,e.createComponentVNode)(2,p.Window,{width:600,height:505,children:[(0,e.createComponentVNode)(2,y),(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,h)]})})]})}return i}(),y=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.help;if(d)return(0,e.createComponentVNode)(2,o.Modal,{maxWidth:"75%",height:window.innerHeight*.75+"px",mx:"auto",py:"0",px:"0.5rem",children:(0,e.createComponentVNode)(2,o.Section,{height:"100%",title:"Help",level:"2",overflow:"auto",children:(0,e.createComponentVNode)(2,o.Box,{px:"0.5rem",mt:"-0.5rem",children:[(0,e.createVNode)(1,"h1",null,"Making a Song",16),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Lines are a series of chords, separated by commas\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"(,)"}),(0,e.createTextVNode)(", each with notes separated by hyphens\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"(-)"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Every note in a chord will play together, with the chord timed by the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"tempo"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("as defined above.")],0),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Notes are played by the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"names of the note"}),(0,e.createTextVNode)(", and optionally, the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"accidental"}),(0,e.createTextVNode)(", and/or the"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave number"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("By default, every note is\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"natural"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("and in\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave 3"}),(0,e.createTextVNode)(". Defining a different state for either is remembered for each"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"note"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"Example:"}),(0,e.createTextVNode)("\xA0"),(0,e.createVNode)(1,"i",null,"C,D,E,F,G,A,B",16),(0,e.createTextVNode)(" will play a\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"C"}),(0,e.createTextVNode)("\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"major"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("scale.")],0),(0,e.createVNode)(1,"li",null,[(0,e.createTextVNode)("After a note has an\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"accidental"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("or\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("placed, it will be remembered:\xA0"),(0,e.createVNode)(1,"i",null,"C,C4,C#,C3",16),(0,e.createTextVNode)(" is "),(0,e.createVNode)(1,"i",null,"C3,C4,C4#,C3#",16)],0)],4)],0),(0,e.createVNode)(1,"p",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"Chords"}),(0,e.createTextVNode)("\xA0can be played simply by seperating each note with a hyphen: "),(0,e.createVNode)(1,"i",null,"A-C#,Cn-E,E-G#,Gn-B",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("A"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"pause"}),(0,e.createTextVNode)("\xA0may be denoted by an empty chord: "),(0,e.createVNode)(1,"i",null,"C,E,,C,G",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("To make a chord be a different time, end it with /x, where the chord length will be length defined by\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"tempo / x"}),(0,e.createTextVNode)(",\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"eg:"}),(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"i",null,"C,G/2,E/4",16),(0,e.createTextVNode)(".")],0),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Combined, an example line is: "),(0,e.createVNode)(1,"i",null,"E-E4/4,F#/2,G#/8,B/8,E3-E4/4",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,"Lines may be up to 300 characters.",16),(0,e.createVNode)(1,"li",null,"A song may only contain up to 1,000 lines.",16)],4)],4),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Lines are a series of chords, separated by commas\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"(,)"}),(0,e.createTextVNode)(", each with notes separated by hyphens\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"(-)"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Every note in a chord will play together, with the chord timed by the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"tempo"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("as defined above.")],0),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Notes are played by the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"names of the note"}),(0,e.createTextVNode)(", and optionally, the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"accidental"}),(0,e.createTextVNode)(", and/or the"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave number"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("By default, every note is\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"natural"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("and in\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave 3"}),(0,e.createTextVNode)(". Defining a different state for either is remembered for each"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"note"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"Example:"}),(0,e.createTextVNode)("\xA0"),(0,e.createVNode)(1,"i",null,"C,D,E,F,G,A,B",16),(0,e.createTextVNode)(" will play a\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"C"}),(0,e.createTextVNode)("\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"major"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("scale.")],0),(0,e.createVNode)(1,"li",null,[(0,e.createTextVNode)("After a note has an\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"accidental"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("or\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("placed, it will be remembered:\xA0"),(0,e.createVNode)(1,"i",null,"C,C4,C#,C3",16),(0,e.createTextVNode)(" is "),(0,e.createVNode)(1,"i",null,"C3,C4,C4#,C3#",16)],0)],4)],0),(0,e.createVNode)(1,"p",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"Chords"}),(0,e.createTextVNode)("\xA0can be played simply by seperating each note with a hyphen: "),(0,e.createVNode)(1,"i",null,"A-C#,Cn-E,E-G#,Gn-B",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("A"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"pause"}),(0,e.createTextVNode)("\xA0may be denoted by an empty chord: "),(0,e.createVNode)(1,"i",null,"C,E,,C,G",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("To make a chord be a different time, end it with /x, where the chord length will be length defined by\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"tempo / x"}),(0,e.createTextVNode)(",\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"eg:"}),(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"i",null,"C,G/2,E/4",16),(0,e.createTextVNode)(".")],0),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Combined, an example line is: "),(0,e.createVNode)(1,"i",null,"E-E4/4,F#/2,G#/8,B/8,E3-E4/4",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,"Lines may be up to 300 characters.",16),(0,e.createVNode)(1,"li",null,"A song may only contain up to 1,000 lines.",16)],4)],4),(0,e.createVNode)(1,"h1",null,"Instrument Advanced Settings",16),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Type:"}),(0,e.createTextVNode)("\xA0Whether the instrument is legacy or synthesized."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Legacy instruments have a collection of sounds that are selectively used depending on the note to play."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Synthesized instruments use a base sound and change its pitch to match the note to play.")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Current:"}),(0,e.createTextVNode)("\xA0Which instrument sample to play. Some instruments can be tuned to play different samples. Experiment!")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Note Shift/Note Transpose:"}),(0,e.createTextVNode)("\xA0The pitch to apply to all notes of the song.")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Sustain Mode:"}),(0,e.createTextVNode)("\xA0How a played note fades out."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Linear sustain means a note will fade out at a constant rate."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Exponential sustain means a note will fade out at an exponential rate, sounding smoother.")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Volume Dropoff Threshold:"}),(0,e.createTextVNode)("\xA0The volume threshold at which a note is fully stopped.")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Sustain indefinitely last held note:"}),(0,e.createTextVNode)("\xA0Whether the last note should be sustained indefinitely.")],4)],4),(0,e.createComponentVNode)(2,o.Button,{color:"grey",content:"Close",onClick:function(){function v(){return u("help")}return v}()})]})})})},S=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.lines,v=s.playing,g=s.repeat,C=s.maxRepeats,f=s.tempo,N=s.minTempo,V=s.maxTempo,B=s.tickLag,I=s.volume,L=s.minVolume,w=s.maxVolume,A=s.ready;return(0,e.createComponentVNode)(2,o.Section,{title:"Instrument",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{icon:"info",content:"Help",onClick:function(){function x(){return u("help")}return x}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"file",content:"New",onClick:function(){function x(){return u("newsong")}return x}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"upload",content:"Import",onClick:function(){function x(){return u("import")}return x}()})],4),children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Playback",children:[(0,e.createComponentVNode)(2,o.Button,{selected:v,disabled:d.length===0||g<0,icon:"play",content:"Play",onClick:function(){function x(){return u("play")}return x}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:!v,icon:"stop",content:"Stop",onClick:function(){function x(){return u("stop")}return x}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Repeat",children:(0,e.createComponentVNode)(2,o.Slider,{animated:!0,minValue:0,maxValue:C,value:g,stepPixelSize:59,onChange:function(){function x(E,P){return u("repeat",{new:P})}return x}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Tempo",children:(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,o.Button,{disabled:f>=V,content:"-",as:"span",mr:"0.5rem",onClick:function(){function x(){return u("tempo",{new:f+B})}return x}()}),(0,a.round)(600/f)," BPM",(0,e.createComponentVNode)(2,o.Button,{disabled:f<=N,content:"+",as:"span",ml:"0.5rem",onClick:function(){function x(){return u("tempo",{new:f-B})}return x}()})]})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Volume",children:(0,e.createComponentVNode)(2,o.Slider,{animated:!0,minValue:L,maxValue:w,value:I,stepPixelSize:6,onDrag:function(){function x(E,P){return u("setvolume",{new:P})}return x}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Status",children:A?(0,e.createComponentVNode)(2,o.Box,{color:"good",children:"Ready"}):(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:"Instrument Definition Error!"})})]}),(0,e.createComponentVNode)(2,k)]})},k=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.allowedInstrumentNames,v=s.instrumentLoaded,g=s.instrument,C=s.canNoteShift,f=s.noteShift,N=s.noteShiftMin,V=s.noteShiftMax,B=s.sustainMode,I=s.sustainLinearDuration,L=s.sustainExponentialDropoff,w=s.legacy,A=s.sustainDropoffVolume,x=s.sustainHeldNote,E,P;return B===1?(E="Linear",P=(0,e.createComponentVNode)(2,o.Slider,{minValue:.1,maxValue:5,value:I,step:.5,stepPixelSize:85,format:function(){function D(M){return(0,a.round)(M*100)/100+" seconds"}return D}(),onChange:function(){function D(M,O){return u("setlinearfalloff",{new:O/10})}return D}()})):B===2&&(E="Exponential",P=(0,e.createComponentVNode)(2,o.Slider,{minValue:1.025,maxValue:10,value:L,step:.01,format:function(){function D(M){return(0,a.round)(M*1e3)/1e3+"% per decisecond"}return D}(),onChange:function(){function D(M,O){return u("setexpfalloff",{new:O})}return D}()})),d.sort(),(0,e.createComponentVNode)(2,o.Box,{my:-1,children:(0,e.createComponentVNode)(2,o.Collapsible,{mt:"1rem",mb:"0",title:"Advanced",children:(0,e.createComponentVNode)(2,o.Section,{mt:-1,children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Type",children:w?"Legacy":"Synthesized"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Current",children:v?(0,e.createComponentVNode)(2,o.Dropdown,{options:d,selected:g,width:"50%",onSelected:function(){function D(M){return u("switchinstrument",{name:M})}return D}()}):(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:"None!"})}),!!(!w&&C)&&(0,e.createFragment)([(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Note Shift/Note Transpose",children:(0,e.createComponentVNode)(2,o.Slider,{minValue:N,maxValue:V,value:f,stepPixelSize:2,format:function(){function D(M){return M+" keys / "+(0,a.round)(M/12*100)/100+" octaves"}return D}(),onChange:function(){function D(M,O){return u("setnoteshift",{new:O})}return D}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Sustain Mode",children:[(0,e.createComponentVNode)(2,o.Dropdown,{options:["Linear","Exponential"],selected:E,mb:"0.4rem",onSelected:function(){function D(M){return u("setsustainmode",{new:M})}return D}()}),P]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Volume Dropoff Threshold",children:(0,e.createComponentVNode)(2,o.Slider,{animated:!0,minValue:.01,maxValue:100,value:A,stepPixelSize:6,onChange:function(){function D(M,O){return u("setdropoffvolume",{new:O})}return D}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Sustain indefinitely last held note",children:(0,e.createComponentVNode)(2,o.Button,{selected:x,icon:x?"toggle-on":"toggle-off",content:x?"Yes":"No",onClick:function(){function D(){return u("togglesustainhold")}return D}()})})],4)]}),(0,e.createComponentVNode)(2,o.Button,{icon:"redo",content:"Reset to Default",mt:"0.5rem",onClick:function(){function D(){return u("reset")}return D}()})]})})})},h=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.playing,v=s.lines,g=s.editing;return(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Editor",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{disabled:!g||d,icon:"plus",content:"Add Line",onClick:function(){function C(){return u("newline",{line:v.length+1})}return C}()}),(0,e.createComponentVNode)(2,o.Button,{selected:!g,icon:g?"chevron-up":"chevron-down",onClick:function(){function C(){return u("edit")}return C}()})],4),children:!!g&&(v.length>0?(0,e.createComponentVNode)(2,o.LabeledList,{children:v.map(function(C,f){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:f+1,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{disabled:d,icon:"pen",onClick:function(){function N(){return u("modifyline",{line:f+1})}return N}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:d,icon:"trash",onClick:function(){function N(){return u("deleteline",{line:f+1})}return N}()})],4),children:C},f)})}):(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"Song is empty."}))})}},13618:function(T,r,n){"use strict";r.__esModule=!0,r.KeyComboModal=void 0;var e=n(89005),a=n(70611),t=n(72253),o=n(36036),p=n(98595),b=n(19203),y=n(51057),S=function(l){return l.key!==a.KEY.Alt&&l.key!==a.KEY.Control&&l.key!==a.KEY.Shift&&l.key!==a.KEY.Escape},k={DEL:"Delete",DOWN:"South",END:"Southwest",HOME:"Northwest",INSERT:"Insert",LEFT:"West",PAGEDOWN:"Southeast",PAGEUP:"Northeast",RIGHT:"East",SPACEBAR:"Space",UP:"North"},h=3,i=function(l){var u="";if(l.altKey&&(u+="Alt"),l.ctrlKey&&(u+="Ctrl"),l.shiftKey&&!(l.keyCode>=48&&l.keyCode<=57)&&(u+="Shift"),l.location===h&&(u+="Numpad"),S(l))if(l.shiftKey&&l.keyCode>=48&&l.keyCode<=57){var s=l.keyCode-48;u+="Shift"+s}else{var d=l.key.toUpperCase();u+=k[d]||d}return u},c=r.KeyComboModal=function(){function m(l,u){var s=(0,t.useBackend)(u),d=s.act,v=s.data,g=v.init_value,C=v.large_buttons,f=v.message,N=f===void 0?"":f,V=v.title,B=v.timeout,I=(0,t.useLocalState)(u,"input",g),L=I[0],w=I[1],A=(0,t.useLocalState)(u,"binding",!0),x=A[0],E=A[1],P=function(){function O(R){if(!x){R.key===a.KEY.Enter&&d("submit",{entry:L}),(0,a.isEscape)(R.key)&&d("cancel");return}if(R.preventDefault(),S(R)){D(i(R)),E(!1);return}else if(R.key===a.KEY.Escape){D(g),E(!1);return}}return O}(),D=function(){function O(R){R!==L&&w(R)}return O}(),M=130+(N.length>30?Math.ceil(N.length/3):0)+(N.length&&C?5:0);return(0,e.createComponentVNode)(2,p.Window,{title:V,width:240,height:M,children:[B&&(0,e.createComponentVNode)(2,y.Loader,{value:B}),(0,e.createComponentVNode)(2,p.Window.Content,{onKeyDown:function(){function O(R){P(R)}return O}(),children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Autofocus),(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Box,{color:"label",children:N})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{disabled:x,content:x&&x!==null?"Awaiting input...":""+L,width:"100%",textAlign:"center",onClick:function(){function O(){D(g),E(!0)}return O}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,b.InputButtons,{input:L})})]})]})})]})}return m}()},35655:function(T,r,n){"use strict";r.__esModule=!0,r.KeycardAuth=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.KeycardAuth=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=(0,e.createComponentVNode)(2,t.Section,{title:"Keycard Authentication Device",children:(0,e.createComponentVNode)(2,t.Box,{children:"This device is used to trigger certain high security events. It requires the simultaneous swipe of two high-level ID cards."})});if(!i.swiping&&!i.busy)return(0,e.createComponentVNode)(2,o.Window,{width:540,height:280,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[c,(0,e.createComponentVNode)(2,t.Section,{title:"Choose Action",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Red Alert",children:(0,e.createComponentVNode)(2,t.Button,{icon:"exclamation-triangle",disabled:!i.redAvailable,onClick:function(){function l(){return h("triggerevent",{triggerevent:"Red Alert"})}return l}(),content:"Red Alert"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ERT",children:(0,e.createComponentVNode)(2,t.Button,{icon:"broadcast-tower",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Emergency Response Team"})}return l}(),content:"Call ERT"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Emergency Maint Access",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"door-open",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Grant Emergency Maintenance Access"})}return l}(),content:"Grant"}),(0,e.createComponentVNode)(2,t.Button,{icon:"door-closed",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Revoke Emergency Maintenance Access"})}return l}(),content:"Revoke"})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Emergency Station-Wide Access",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"door-open",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Activate Station-Wide Emergency Access"})}return l}(),content:"Grant"}),(0,e.createComponentVNode)(2,t.Button,{icon:"door-closed",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Deactivate Station-Wide Emergency Access"})}return l}(),content:"Revoke"})]})]})})]})});var m=(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Waiting for YOU to swipe your ID..."});return!i.hasSwiped&&!i.ertreason&&i.event==="Emergency Response Team"?m=(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Fill out the reason for your ERT request."}):i.hasConfirm?m=(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Request Confirmed!"}):i.isRemote?m=(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"Swipe your card to CONFIRM the remote request."}):i.hasSwiped&&(m=(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"Waiting for second person to confirm..."})),(0,e.createComponentVNode)(2,o.Window,{width:540,height:265,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[c,i.event==="Emergency Response Team"&&(0,e.createComponentVNode)(2,t.Section,{title:"Reason for ERT Call",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{color:i.ertreason?"":"red",icon:i.ertreason?"check":"pencil-alt",content:i.ertreason?i.ertreason:"-----",disabled:i.busy,onClick:function(){function l(){return h("ert")}return l}()})})}),(0,e.createComponentVNode)(2,t.Section,{title:i.event,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-left",content:"Back",disabled:i.busy||i.hasConfirm,onClick:function(){function l(){return h("reset")}return l}()}),children:m})]})})}return b}()},62955:function(T,r,n){"use strict";r.__esModule=!0,r.KitchenMachine=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(62411),b=r.KitchenMachine=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.data,m=i.config,l=c.ingredients,u=c.operating,s=m.title;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:320,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Operating,{operating:u,name:s}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,y)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Ingredients",children:(0,e.createComponentVNode)(2,t.Table,{className:"Ingredient__Table",children:l.map(function(d){return(0,e.createComponentVNode)(2,t.Table.Row,{tr:5,children:[(0,e.createVNode)(1,"td",null,(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:d.name}),2),(0,e.createVNode)(1,"td",null,(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,textAlign:"center",children:[d.amount," ",d.units]}),2)]},d.name)})})})})]})})})}return S}(),y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.inactive,u=m.tooltip;return(0,e.createComponentVNode)(2,t.Section,{title:"Controls",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"50%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"power-off",disabled:l,tooltip:l?u:"",tooltipPosition:"bottom",content:"Activate",onClick:function(){function s(){return c("cook")}return s}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"50%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"eject",disabled:l,tooltip:l?u:"",tooltipPosition:"bottom",content:"Eject Contents",onClick:function(){function s(){return c("eject")}return s}()})})]})})}},9525:function(T,r,n){"use strict";r.__esModule=!0,r.LawManager=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.LawManager=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.isAdmin,s=l.isSlaved,d=l.isMalf,v=l.isAIMalf,g=l.view;return(0,e.createComponentVNode)(2,o.Window,{width:800,height:d?620:365,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[!!(u&&s)&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:["This unit is slaved to ",s,"."]}),!!(d||v)&&(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Law Management",selected:g===0,onClick:function(){function C(){return m("set_view",{set_view:0})}return C}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Lawsets",selected:g===1,onClick:function(){function C(){return m("set_view",{set_view:1})}return C}()})]}),g===0&&(0,e.createComponentVNode)(2,b),g===1&&(0,e.createComponentVNode)(2,y)]})})}return k}(),b=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.has_zeroth_laws,s=l.zeroth_laws,d=l.has_ion_laws,v=l.ion_laws,g=l.ion_law_nr,C=l.has_inherent_laws,f=l.inherent_laws,N=l.has_supplied_laws,V=l.supplied_laws,B=l.channels,I=l.channel,L=l.isMalf,w=l.isAdmin,A=l.zeroth_law,x=l.ion_law,E=l.inherent_law,P=l.supplied_law,D=l.supplied_law_position;return(0,e.createFragment)([!!u&&(0,e.createComponentVNode)(2,S,{title:"ERR_NULL_VALUE",laws:s,ctx:i}),!!d&&(0,e.createComponentVNode)(2,S,{title:g,laws:v,ctx:i}),!!C&&(0,e.createComponentVNode)(2,S,{title:"Inherent",laws:f,ctx:i}),!!N&&(0,e.createComponentVNode)(2,S,{title:"Supplied",laws:V,ctx:i}),(0,e.createComponentVNode)(2,t.Section,{title:"Statement Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Statement Channel",children:B.map(function(M){return(0,e.createComponentVNode)(2,t.Button,{content:M.channel,selected:M.channel===I,onClick:function(){function O(){return m("law_channel",{law_channel:M.channel})}return O}()},M.channel)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"State Laws",children:(0,e.createComponentVNode)(2,t.Button,{content:"State Laws",onClick:function(){function M(){return m("state_laws")}return M}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Law Notification",children:(0,e.createComponentVNode)(2,t.Button,{content:"Notify",onClick:function(){function M(){return m("notify_laws")}return M}()})})]})}),!!L&&(0,e.createComponentVNode)(2,t.Section,{title:"Add Laws",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{width:"10%",children:"Type"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"60%",children:"Law"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"10%",children:"Index"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"20%",children:"Actions"})]}),!!(w&&!u)&&(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Zero"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:A}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"N/A"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function M(){return m("change_zeroth_law")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Add",icon:"plus",onClick:function(){function M(){return m("add_zeroth_law")}return M}()})]})]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Ion"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:x}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"N/A"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function M(){return m("change_ion_law")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Add",icon:"plus",onClick:function(){function M(){return m("add_ion_law")}return M}()})]})]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Inherent"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:E}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"N/A"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function M(){return m("change_inherent_law")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Add",icon:"plus",onClick:function(){function M(){return m("add_inherent_law")}return M}()})]})]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Supplied"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:P}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:D,onClick:function(){function M(){return m("change_supplied_law_position")}return M}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function M(){return m("change_supplied_law")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Add",icon:"plus",onClick:function(){function M(){return m("add_supplied_law")}return M}()})]})]})]})})],0)},y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.law_sets;return(0,e.createComponentVNode)(2,t.Box,{children:u.map(function(s){return(0,e.createComponentVNode)(2,t.Section,{title:s.name+" - "+s.header,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Load Laws",icon:"download",onClick:function(){function d(){return m("transfer_laws",{transfer_laws:s.ref})}return d}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[s.laws.has_ion_laws>0&&s.laws.ion_laws.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.index,children:d.law},d.index)}),s.laws.has_zeroth_laws>0&&s.laws.zeroth_laws.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.index,children:d.law},d.index)}),s.laws.has_inherent_laws>0&&s.laws.inherent_laws.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.index,children:d.law},d.index)}),s.laws.has_supplied_laws>0&&s.laws.inherent_laws.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.index,children:d.law},d.index)})]})},s.name)})})},S=function(h,i){var c=(0,a.useBackend)(h.ctx),m=c.act,l=c.data,u=l.isMalf;return(0,e.createComponentVNode)(2,t.Section,{title:h.title+" Laws",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{width:"10%",children:"Index"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"69%",children:"Law"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"21%",children:"State?"})]}),h.laws.map(function(s){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:s.index}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:s.law}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:s.state?"Yes":"No",selected:s.state,onClick:function(){function d(){return m("state_law",{ref:s.ref,state_law:s.state?0:1})}return d}()}),!!u&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function d(){return m("edit_law",{edit_law:s.ref})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Delete",icon:"trash",color:"red",onClick:function(){function d(){return m("delete_law",{delete_law:s.ref})}return d}()})],4)]})]},s.law)})]})})}},85066:function(T,r,n){"use strict";r.__esModule=!0,r.LibraryComputer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=r.LibraryComputer=function(){function g(C,f){return(0,e.createComponentVNode)(2,o.Window,{width:1050,height:600,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c)]})})]})}return g}(),y=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=C.args,L=B.user_ckey;return(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:I.title}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:I.author}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Summary",children:I.summary}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rating",children:[I.rating,(0,e.createComponentVNode)(2,t.Icon,{name:"star",color:"yellow",verticalAlign:"top"})]}),!I.isProgrammatic&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Categories",children:I.categories.join(", ")})]}),(0,e.createVNode)(1,"br"),L===I.ckey&&(0,e.createComponentVNode)(2,t.Button,{content:"Delete Book",icon:"trash",color:"red",disabled:I.isProgrammatic,onClick:function(){function w(){return V("delete_book",{bookid:I.id,user_ckey:L})}return w}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Report Book",icon:"flag",color:"red",disabled:I.isProgrammatic,onClick:function(){function w(){return(0,p.modalOpen)(f,"report_book",{bookid:I.id})}return w}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Rate Book",icon:"star",color:"caution",disabled:I.isProgrammatic,onClick:function(){function w(){return(0,p.modalOpen)(f,"rate_info",{bookid:I.id})}return w}()})]})},S=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=C.args,L=B.selected_report,w=B.report_categories,A=B.user_ckey;return(0,e.createComponentVNode)(2,t.Section,{level:2,m:"-1rem",pb:"1.5rem",title:"Report this book for Rule Violations",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:I.title}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Reasons",children:(0,e.createComponentVNode)(2,t.Box,{children:w.map(function(x,E){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:x.description,selected:x.category_id===L,onClick:function(){function P(){return V("set_report",{report_type:x.category_id})}return P}()}),(0,e.createVNode)(1,"br")],4,E)})})})]}),(0,e.createComponentVNode)(2,t.Button.Confirm,{bold:!0,icon:"paper-plane",content:"Submit Report",onClick:function(){function x(){return V("submit_report",{bookid:I.id,user_ckey:A})}return x}()})]})},k=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.selected_rating,L=Array(10).fill().map(function(w,A){return 1+A});return(0,e.createComponentVNode)(2,t.Stack,{children:[L.map(function(w,A){return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{bold:!0,icon:"star",color:I>=w?"caution":"default",onClick:function(){function x(){return V("set_rating",{rating_value:w})}return x}()})},A)}),(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,ml:2,fontSize:"150%",children:[I+"/10",(0,e.createComponentVNode)(2,t.Icon,{name:"star",color:"yellow",ml:.5,verticalAlign:"top"})]})]})},h=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=C.args,L=B.user_ckey;return(0,e.createComponentVNode)(2,t.Section,{level:2,m:"-1rem",pb:"1.5rem",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:I.title}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:I.author}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rating",children:[I.current_rating?I.current_rating:0,(0,e.createComponentVNode)(2,t.Icon,{name:"star",color:"yellow",ml:.5,verticalAlign:"middle"})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Total Ratings",children:I.total_ratings?I.total_ratings:0})]}),(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,t.Button.Confirm,{mt:2,content:"Submit",icon:"paper-plane",onClick:function(){function w(){return V("rate_book",{bookid:I.id,user_ckey:L})}return w}()})]})},i=function(C,f){var N=(0,a.useBackend)(f),V=N.data,B=(0,a.useLocalState)(f,"tabIndex",0),I=B[0],L=B[1],w=V.login_state;return(0,e.createComponentVNode)(2,t.Stack.Item,{mb:1,children:(0,e.createComponentVNode)(2,t.Tabs,{fluid:!0,textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===0,onClick:function(){function A(){return L(0)}return A}(),children:"Book Archives"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===1,onClick:function(){function A(){return L(1)}return A}(),children:"Corporate Literature"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===2,onClick:function(){function A(){return L(2)}return A}(),children:"Upload Book"}),w===1&&(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===3,onClick:function(){function A(){return L(3)}return A}(),children:"Patron Manager"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===4,onClick:function(){function A(){return L(4)}return A}(),children:"Inventory"})]})})},c=function(C,f){var N=(0,a.useLocalState)(f,"tabIndex",0),V=N[0];switch(V){case 0:return(0,e.createComponentVNode)(2,l);case 1:return(0,e.createComponentVNode)(2,u);case 2:return(0,e.createComponentVNode)(2,s);case 3:return(0,e.createComponentVNode)(2,d);case 4:return(0,e.createComponentVNode)(2,v);default:return"You are somehow on a tab that doesn't exist! Please let a coder know."}},m=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.searchcontent,L=B.book_categories,w=B.user_ckey,A=[];return L.map(function(x){return A[x.description]=x.category_id}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"35%",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",m:".5em",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"edit",verticalAlign:"middle",size:1.5,mr:"1rem"}),"Search Inputs"]}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,t.Button,{textAlign:"left",icon:"pen",width:20,content:I.title||"Input Title",onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_search_title")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:(0,e.createComponentVNode)(2,t.Button,{textAlign:"left",icon:"pen",width:20,content:I.author||"Input Author",onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_search_author")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Ratings",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{mr:1,width:"min-content",content:I.ratingmin,onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_search_ratingmin")}return x}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:"To"}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{ml:1,width:"min-content",content:I.ratingmax,onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_search_ratingmax")}return x}()})})]})})]})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"40%",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",m:".5em",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"clipboard-list",verticalAlign:"middle",size:1.5,mr:"1rem"}),"Book Categories"]}),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Categories",children:(0,e.createComponentVNode)(2,t.Box,{mt:2,children:(0,e.createComponentVNode)(2,t.Dropdown,{mt:.6,width:"190px",options:L.map(function(x){return x.description}),onSelected:function(){function x(E){return V("toggle_search_category",{category_id:A[E]})}return x}()})})})}),(0,e.createVNode)(1,"br"),L.filter(function(x){return I.categories.includes(x.category_id)}).map(function(x){return(0,e.createComponentVNode)(2,t.Button,{content:x.description,selected:!0,icon:"unlink",onClick:function(){function E(){return V("toggle_search_category",{category_id:x.category_id})}return E}()},x.category_id)})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",m:".5em",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"search-plus",verticalAlign:"middle",size:1.5,mr:"1rem"}),"Search Actions"]}),(0,e.createComponentVNode)(2,t.Button,{content:"Clear Search",icon:"eraser",onClick:function(){function x(){return V("clear_search")}return x}()}),I.ckey?(0,e.createComponentVNode)(2,t.Button,{mb:.5,content:"Stop Showing My Books",color:"bad",icon:"search",onClick:function(){function x(){return V("clear_ckey_search")}return x}()}):(0,e.createComponentVNode)(2,t.Button,{content:"Find My Books",icon:"search",onClick:function(){function x(){return V("find_users_books",{user_ckey:w})}return x}()})]})]})},l=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.external_booklist,L=B.archive_pagenumber,w=B.num_pages,A=B.login_state;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Book System Access",buttons:(0,e.createVNode)(1,"div",null,[(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-left",disabled:L===1,onClick:function(){function x(){return V("deincrementpagemax")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-left",disabled:L===1,onClick:function(){function x(){return V("deincrementpage")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{bold:!0,content:L,onClick:function(){function x(){return(0,p.modalOpen)(f,"setpagenumber")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-right",disabled:L===w,onClick:function(){function x(){return V("incrementpage")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-right",disabled:L===w,onClick:function(){function x(){return V("incrementpagemax")}return x}()})],4),children:[(0,e.createComponentVNode)(2,m),(0,e.createVNode)(1,"hr"),(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"SSID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Ratings"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Category"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"middle",children:"Actions"})]}),I.map(function(x){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:x.id}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book",mr:.5}),x.title.length>45?x.title.substr(0,45)+"...":x.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:x.author.length>30?x.author.substr(0,30)+"...":x.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[x.rating,(0,e.createComponentVNode)(2,t.Icon,{name:"star",ml:.5,color:"yellow",verticalAlign:"middle"})]}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:x.categories.join(", ").substr(0,45)}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",children:[A===1&&(0,e.createComponentVNode)(2,t.Button,{content:"Order",icon:"print",onClick:function(){function E(){return V("order_external_book",{bookid:x.id})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{content:"More...",onClick:function(){function E(){return(0,p.modalOpen)(f,"expand_info",{bookid:x.id})}return E}()})]})]},x.id)})]})]})},u=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.programmatic_booklist,L=B.login_state;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Corporate Book Catalog",children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"SSID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"middle",children:"Actions"})]}),I.map(function(w,A){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:w.id}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book",mr:2}),w.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:w.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",children:[L===1&&(0,e.createComponentVNode)(2,t.Button,{content:"Order",icon:"print",onClick:function(){function x(){return V("order_programmatic_book",{bookid:w.id})}return x}()}),(0,e.createComponentVNode)(2,t.Button,{content:"More...",onClick:function(){function x(){return(0,p.modalOpen)(f,"expand_info",{bookid:w.id})}return x}()})]})]},A)})]})})},s=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.selectedbook,L=B.book_categories,w=B.user_ckey,A=[];return L.map(function(x){return A[x.description]=x.category_id}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Book System Upload",buttons:(0,e.createComponentVNode)(2,t.Button.Confirm,{bold:!0,width:9.5,icon:"upload",disabled:I.copyright,content:"Upload Book",onClick:function(){function x(){return V("uploadbook",{user_ckey:w})}return x}()}),children:[I.copyright?(0,e.createComponentVNode)(2,t.NoticeBox,{color:"red",children:"WARNING: You cannot upload or modify the attributes of a copyrighted book"}):(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Box,{ml:15,mb:3,fontSize:"1.2rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"search-plus",verticalAlign:"middle",size:3,mr:2}),"Book Uploader"]}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,t.Button,{width:20,textAlign:"left",icon:"pen",disabled:I.copyright,content:I.title,onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_selected_title")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:(0,e.createComponentVNode)(2,t.Button,{width:20,textAlign:"left",icon:"pen",disabled:I.copyright,content:I.author,onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_selected_author")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Categories",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Dropdown,{width:"240px",options:L.map(function(x){return x.description}),onSelected:function(){function x(E){return V("toggle_upload_category",{category_id:A[E]})}return x}()})})})]}),(0,e.createVNode)(1,"br"),L.filter(function(x){return I.categories.includes(x.category_id)}).map(function(x){return(0,e.createComponentVNode)(2,t.Button,{content:x.description,disabled:I.copyright,selected:!0,icon:"unlink",onClick:function(){function E(){return V("toggle_upload_category",{category_id:x.category_id})}return E}()},x.category_id)})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{mr:75,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Summary",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pen",width:"auto",disabled:I.copyright,content:"Edit Summary",onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_selected_summary")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:I.summary})]})})]})]})},d=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.checkout_data;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Checked Out Books",children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Patron"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Time Left"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Actions"})]}),I.map(function(L,w){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-tag"}),L.patron_name]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:L.title}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:L.timeleft>=0?L.timeleft:"LATE"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:(0,e.createComponentVNode)(2,t.Button,{content:"Mark Lost",icon:"flag",color:"bad",disabled:L.timeleft>=0,onClick:function(){function A(){return V("reportlost",{libraryid:L.libraryid})}return A}()})})]},w)})]})})},v=function(C,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.inventory_list;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Library Inventory",children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"LIB ID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Status"})]}),I.map(function(L,w){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:L.libraryid}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book"})," ",L.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:L.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:L.checked_out?"Checked Out":"Available"})]},w)})]})})};(0,p.modalRegisterBodyOverride)("expand_info",y),(0,p.modalRegisterBodyOverride)("report_book",S),(0,p.modalRegisterBodyOverride)("rate_info",h)},9516:function(T,r,n){"use strict";r.__esModule=!0,r.LibraryManager=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=r.LibraryManager=function(){function i(c,m){return(0,e.createComponentVNode)(2,o.Window,{width:600,height:600,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,className:"Layout__content--flexColumn",children:(0,e.createComponentVNode)(2,y)})]})}return i}(),y=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.pagestate;switch(d){case 1:return(0,e.createComponentVNode)(2,S);case 2:return(0,e.createComponentVNode)(2,h);case 3:return(0,e.createComponentVNode)(2,k);default:return"WE SHOULDN'T BE HERE!"}},S=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data;return(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.4rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-shield",verticalAlign:"middle",size:3,mr:"1rem"}),"Library Manager"]}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{icon:"trash",width:"auto",color:"danger",content:"Delete Book by SSID",onClick:function(){function d(){return(0,p.modalOpen)(m,"specify_ssid_delete")}return d}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"user-slash",width:"auto",color:"danger",content:"Delete All Books By CKEY",onClick:function(){function d(){return(0,p.modalOpen)(m,"specify_ckey_delete")}return d}()}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{icon:"search",width:"auto",content:"View All Books By CKEY",onClick:function(){function d(){return(0,p.modalOpen)(m,"specify_ckey_search")}return d}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"search",width:"auto",content:"View All Reported Books",onClick:function(){function d(){return u("view_reported_books")}return d}()})]})},k=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.reports;return(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-secret",verticalAlign:"middle",size:2,mr:"1rem"}),(0,e.createVNode)(1,"br"),"All Reported Books",(0,e.createVNode)(1,"br")]}),(0,e.createComponentVNode)(2,t.Button,{content:"Return to Main",icon:"arrow-alt-circle-left",onClick:function(){function v(){return u("return")}return v}()}),(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Uploader CKEY"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"SSID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Report Type"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Reporter Ckey"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"middle",children:"Administrative Actions"})]}),d.map(function(v){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:v.uploader_ckey}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:v.id}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book"}),v.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:v.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:v.report_description}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:v.reporter_ckey}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Delete",icon:"trash",onClick:function(){function g(){return u("delete_book",{bookid:v.id})}return g}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Unflag",icon:"flag",color:"caution",onClick:function(){function g(){return u("unflag_book",{bookid:v.id})}return g}()}),(0,e.createComponentVNode)(2,t.Button,{content:"View",onClick:function(){function g(){return u("view_book",{bookid:v.id})}return g}()})]})]},v.id)})]})})},h=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.ckey,v=s.booklist;return(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user",verticalAlign:"middle",size:2,mr:"1rem"}),(0,e.createVNode)(1,"br"),"Books uploaded by ",d,(0,e.createVNode)(1,"br")]}),(0,e.createComponentVNode)(2,t.Button,{mt:1,content:"Return to Main",icon:"arrow-alt-circle-left",onClick:function(){function g(){return u("return")}return g}()}),(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"SSID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"middle",children:"Administrative Actions"})]}),v.map(function(g){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:g.id}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book"}),g.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:g.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",children:[(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Delete",icon:"trash",color:"bad",onClick:function(){function C(){return u("delete_book",{bookid:g.id})}return C}()}),(0,e.createComponentVNode)(2,t.Button,{content:"View",onClick:function(){function C(){return u("view_book",{bookid:g.id})}return C}()})]})]},g.id)})]})})}},90447:function(T,r,n){"use strict";r.__esModule=!0,r.ListInputModal=void 0;var e=n(89005),a=n(51057),t=n(19203),o=n(36036),p=n(72253),b=n(92986),y=n(98595),S=r.ListInputModal=function(){function i(c,m){var l=(0,p.useBackend)(m),u=l.act,s=l.data,d=s.items,v=d===void 0?[]:d,g=s.message,C=g===void 0?"":g,f=s.init_value,N=s.timeout,V=s.title,B=(0,p.useLocalState)(m,"selected",v.indexOf(f)),I=B[0],L=B[1],w=(0,p.useLocalState)(m,"searchBarVisible",v.length>10),A=w[0],x=w[1],E=(0,p.useLocalState)(m,"searchQuery",""),P=E[0],D=E[1],M=function(){function G(X){var J=z.length-1;if(X===b.KEY_DOWN)if(I===null||I===J){var se;L(0),(se=document.getElementById("0"))==null||se.scrollIntoView()}else{var ie;L(I+1),(ie=document.getElementById((I+1).toString()))==null||ie.scrollIntoView()}else if(X===b.KEY_UP)if(I===null||I===0){var me;L(J),(me=document.getElementById(J.toString()))==null||me.scrollIntoView()}else{var q;L(I-1),(q=document.getElementById((I-1).toString()))==null||q.scrollIntoView()}}return G}(),O=function(){function G(X){X!==I&&L(X)}return G}(),R=function(){function G(){x(!1),x(!0)}return G}(),F=function(){function G(X){var J=String.fromCharCode(X),se=v.find(function(q){return q==null?void 0:q.toLowerCase().startsWith(J==null?void 0:J.toLowerCase())});if(se){var ie,me=v.indexOf(se);L(me),(ie=document.getElementById(me.toString()))==null||ie.scrollIntoView()}}return G}(),W=function(){function G(X){var J;X!==P&&(D(X),L(0),(J=document.getElementById("0"))==null||J.scrollIntoView())}return G}(),U=function(){function G(){x(!A),D("")}return G}(),z=v.filter(function(G){return G==null?void 0:G.toLowerCase().includes(P.toLowerCase())}),$=330+Math.ceil(C.length/3);return A||setTimeout(function(){var G;return(G=document.getElementById(I.toString()))==null?void 0:G.focus()},1),(0,e.createComponentVNode)(2,y.Window,{title:V,width:325,height:$,children:[N&&(0,e.createComponentVNode)(2,a.Loader,{value:N}),(0,e.createComponentVNode)(2,y.Window.Content,{onKeyDown:function(){function G(X){var J=window.event?X.which:X.keyCode;(J===b.KEY_DOWN||J===b.KEY_UP)&&(X.preventDefault(),M(J)),J===b.KEY_ENTER&&(X.preventDefault(),u("submit",{entry:z[I]})),!A&&J>=b.KEY_A&&J<=b.KEY_Z&&(X.preventDefault(),F(J)),J===b.KEY_ESCAPE&&(X.preventDefault(),u("cancel"))}return G}(),children:(0,e.createComponentVNode)(2,o.Section,{buttons:(0,e.createComponentVNode)(2,o.Button,{compact:!0,icon:A?"search":"font",selected:!0,tooltip:A?"Search Mode. Type to search or use arrow keys to select manually.":"Hotkey Mode. Type a letter to jump to the first match. Enter to select.",tooltipPosition:"left",onClick:function(){function G(){return U()}return G}()}),className:"ListInput__Section",fill:!0,title:C,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,k,{filteredItems:z,onClick:O,onFocusSearch:R,searchBarVisible:A,selected:I})}),(0,e.createComponentVNode)(2,o.Stack.Item,{m:0,children:A&&(0,e.createComponentVNode)(2,h,{filteredItems:z,onSearch:W,searchQuery:P,selected:I})}),(0,e.createComponentVNode)(2,o.Stack.Item,{mt:.5,children:(0,e.createComponentVNode)(2,t.InputButtons,{input:z[I]})})]})})})]})}return i}(),k=function(c,m){var l=(0,p.useBackend)(m),u=l.act,s=c.filteredItems,d=c.onClick,v=c.onFocusSearch,g=c.searchBarVisible,C=c.selected;return(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,tabIndex:0,children:s.map(function(f,N){return(0,e.createComponentVNode)(2,o.Button,{fluid:!0,color:"transparent",id:N,onClick:function(){function V(){return d(N)}return V}(),onDblClick:function(){function V(B){B.preventDefault(),u("submit",{entry:s[C]})}return V}(),onKeyDown:function(){function V(B){var I=window.event?B.which:B.keyCode;g&&I>=b.KEY_A&&I<=b.KEY_Z&&(B.preventDefault(),v())}return V}(),selected:N===C,style:{animation:"none",transition:"none"},children:f.replace(/^\w/,function(V){return V.toUpperCase()})},N)})})},h=function(c,m){var l=(0,p.useBackend)(m),u=l.act,s=c.filteredItems,d=c.onSearch,v=c.searchQuery,g=c.selected;return(0,e.createComponentVNode)(2,o.Input,{width:"100%",autoFocus:!0,autoSelect:!0,onEnter:function(){function C(f){f.preventDefault(),u("submit",{entry:s[g]})}return C}(),onInput:function(){function C(f,N){return d(N)}return C}(),placeholder:"Search...",value:v})}},26826:function(T,r,n){"use strict";r.__esModule=!0,r.Loadout=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b={Default:function(){function c(m,l){return m.gear.gear_tier-l.gear.gear_tier}return c}(),Alphabetical:function(){function c(m,l){return m.gear.name.toLowerCase().localeCompare(l.gear.name.toLowerCase())}return c}(),Cost:function(){function c(m,l){return m.gear.cost-l.gear.cost}return c}()},y=r.Loadout=function(){function c(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=(0,t.useLocalState)(l,"search",!1),g=v[0],C=v[1],f=(0,t.useLocalState)(l,"searchText",""),N=f[0],V=f[1],B=(0,t.useLocalState)(l,"category",Object.keys(d.gears)[0]),I=B[0],L=B[1],w=(0,t.useLocalState)(l,"tweakedGear",""),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,p.Window,{width:975,height:650,children:[A&&(0,e.createComponentVNode)(2,i,{tweakedGear:A,setTweakedGear:x}),(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,S,{category:I,setCategory:L})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"25%",children:(0,e.createComponentVNode)(2,h,{setTweakedGear:x})}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"75%",children:(0,e.createComponentVNode)(2,k,{category:I,search:g,setSearch:C,searchText:N,setSearchText:V})})]})})]})})]})}return c}(),S=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=m.category,g=m.setCategory;return(0,e.createComponentVNode)(2,o.Tabs,{fluid:!0,textAlign:"center",style:{"flex-wrap":"wrap-reverse"},children:Object.keys(d.gears).map(function(C){return(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:C===v,style:{"white-space":"nowrap"},onClick:function(){function f(){return g(C)}return f}(),children:C},C)})})},k=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=d.user_tier,g=d.gear_slots,C=d.max_gear_slots,f=m.category,N=m.search,V=m.setSearch,B=m.searchText,I=m.setSearchText,L=(0,t.useLocalState)(l,"sortType","Default"),w=L[0],A=L[1],x=(0,t.useLocalState)(l,"sortReverse",!1),E=x[0],P=x[1],D=(0,a.createSearch)(B,function(O){return O.name}),M;return B.length>2?M=Object.entries(d.gears).reduce(function(O,R){var F=R[0],W=R[1];return O.concat(Object.entries(W).map(function(U){var z=U[0],$=U[1];return{key:z,gear:$}}))},[]).filter(function(O){var R=O.gear;return D(R)}):M=Object.entries(d.gears[f]).map(function(O){var R=O[0],F=O[1];return{key:R,gear:F}}),M.sort(b[w]),E&&(M=M.reverse()),(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:f,buttons:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Dropdown,{height:1.66,selected:w,options:Object.keys(b),onSelected:function(){function O(R){return A(R)}return O}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:E?"arrow-down-wide-short":"arrow-down-short-wide",tooltip:E?"Ascending order":"Descending order",tooltipPosition:"bottom-end",onClick:function(){function O(){return P(!E)}return O}()})}),N&&(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Input,{width:20,placeholder:"Search...",value:B,onInput:function(){function O(R){return I(R.target.value)}return O}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:"magnifying-glass",selected:N,tooltip:"Toggle search field",tooltipPosition:"bottom-end",onClick:function(){function O(){V(!N),I("")}return O}()})})]}),children:M.map(function(O){var R=O.key,F=O.gear,W=12,U=Object.keys(d.selected_gears).includes(R),z=F.cost===1?F.cost+" Point":F.cost+" Points",$=(0,e.createComponentVNode)(2,o.Box,{children:[F.name.length>W&&(0,e.createComponentVNode)(2,o.Box,{children:F.name}),F.gear_tier>v&&(0,e.createComponentVNode)(2,o.Box,{mt:F.name.length>W&&1.5,textColor:"red",children:"That gear is only available at a higher donation tier than you are on."})]}),G=(0,e.createFragment)([F.allowed_roles&&(0,e.createComponentVNode)(2,o.Button,{width:"22px",color:"transparent",icon:"user",tooltip:(0,e.createComponentVNode)(2,o.Section,{m:-1,title:"Allowed Roles",children:F.allowed_roles.map(function(J){return(0,e.createComponentVNode)(2,o.Box,{children:J},J)})}),tooltipPosition:"left"}),Object.entries(F.tweaks).map(function(J){var se=J[0],ie=J[1];return ie.map(function(me){return(0,e.createComponentVNode)(2,o.Button,{width:"22px",color:"transparent",icon:me.icon,tooltip:me.tooltip,tooltipPosition:"top"},se)})}),(0,e.createComponentVNode)(2,o.Button,{width:"22px",color:"transparent",icon:"info",tooltip:F.desc,tooltipPosition:"top"})],0),X=(0,e.createComponentVNode)(2,o.Box,{class:"Loadout-InfoBox",children:[(0,e.createComponentVNode)(2,o.Box,{style:{"flex-grow":1},fontSize:1,color:"gold",opacity:.75,children:F.gear_tier>0&&"Tier "+F.gear_tier}),(0,e.createComponentVNode)(2,o.Box,{fontSize:.75,opacity:.66,children:z})]});return(0,e.createComponentVNode)(2,o.ImageButton,{m:.5,imageSize:84,dmIcon:F.icon,dmIconState:F.icon_state,tooltip:(F.name.length>W||F.gear_tier>0)&&$,tooltipPosition:"bottom",selected:U,disabled:F.gear_tier>v||g+F.cost>C&&!U,buttons:G,buttonsAlt:X,onClick:function(){function J(){return s("toggle_gear",{gear:R})}return J}(),children:F.name},R)})})},h=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=m.setTweakedGear,g=Object.entries(d.gears).reduce(function(C,f){var N=f[0],V=f[1],B=Object.entries(V).filter(function(I){var L=I[0];return Object.keys(d.selected_gears).includes(L)}).map(function(I){var L=I[0],w=I[1];return Object.assign({key:L},w)});return C.concat(B)},[]);return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Selected Equipment",buttons:(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",tooltip:"Clear Loadout",tooltipPosition:"bottom-end",onClick:function(){function C(){return s("clear_loadout")}return C}()}),children:g.map(function(C){return(0,e.createComponentVNode)(2,o.ImageButton,{fluid:!0,imageSize:32,dmIcon:C.icon,dmIconState:C.icon_state,buttons:(0,e.createFragment)([Object.entries(C.tweaks).length>0&&(0,e.createComponentVNode)(2,o.Button,{translucent:!0,icon:"gears",iconColor:"gray",width:"33px",onClick:function(){function f(){return v(C)}return f}()}),(0,e.createComponentVNode)(2,o.Button,{translucent:!0,icon:"times",iconColor:"red",width:"32px",onClick:function(){function f(){return s("toggle_gear",{gear:C.key})}return f}()})],0),children:C.name},C.key)})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.ProgressBar,{value:d.gear_slots,maxValue:d.max_gear_slots,ranges:{bad:[d.max_gear_slots,1/0],average:[d.max_gear_slots*.66,d.max_gear_slots],good:[0,d.max_gear_slots*.66]},children:(0,e.createComponentVNode)(2,o.Box,{textAlign:"center",children:["Used points ",d.gear_slots,"/",d.max_gear_slots]})})})})]})},i=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=m.tweakedGear,g=m.setTweakedGear;return(0,e.createComponentVNode)(2,o.Dimmer,{children:(0,e.createComponentVNode)(2,o.Box,{className:"Loadout-Modal__background",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,width:20,height:20,title:v.name,buttons:(0,e.createComponentVNode)(2,o.Button,{color:"red",icon:"times",tooltip:"Close",tooltipPosition:"top",onClick:function(){function C(){return g("")}return C}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:Object.entries(v.tweaks).map(function(C){var f=C[0],N=C[1];return N.map(function(V){var B=d.selected_gears[v.key][f];return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:V.name,color:B?"":"gray",buttons:(0,e.createComponentVNode)(2,o.Button,{color:"transparent",icon:"pen",onClick:function(){function I(){return s("set_tweak",{gear:v.key,tweak:f})}return I}()}),children:[B||"Default",(0,e.createComponentVNode)(2,o.Box,{inline:!0,ml:1,width:1,height:1,verticalAlign:"middle",style:{"background-color":""+B}})]},f)})})})})})})}},77613:function(T,r,n){"use strict";r.__esModule=!0,r.MODsuitContent=r.MODsuit=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(I,L){var w=I.name,A=I.value,x=I.module_ref,E=(0,a.useBackend)(L),P=E.act;return(0,e.createComponentVNode)(2,t.NumberInput,{value:A,minValue:-50,maxValue:50,stepPixelSize:5,width:"39px",onChange:function(){function D(M,O){return P("configure",{key:w,value:O,ref:x})}return D}()})},b=function(I,L){var w=I.name,A=I.value,x=I.module_ref,E=(0,a.useBackend)(L),P=E.act;return(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:A,onClick:function(){function D(){return P("configure",{key:w,value:!A,ref:x})}return D}()})},y=function(I,L){var w=I.name,A=I.value,x=I.module_ref,E=(0,a.useBackend)(L),P=E.act;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:"paint-brush",onClick:function(){function D(){return P("configure",{key:w,ref:x})}return D}()}),(0,e.createComponentVNode)(2,t.ColorBox,{color:A,mr:.5})],4)},S=function(I,L){var w=I.name,A=I.value,x=I.values,E=I.module_ref,P=(0,a.useBackend)(L),D=P.act;return(0,e.createComponentVNode)(2,t.Dropdown,{displayText:A,options:x,onSelected:function(){function M(O){return D("configure",{key:w,value:O,ref:E})}return M}()})},k=function(I,L){var w=I.name,A=I.display_name,x=I.type,E=I.value,P=I.values,D=I.module_ref,M={number:(0,e.normalizeProps)((0,e.createComponentVNode)(2,p,Object.assign({},I))),bool:(0,e.normalizeProps)((0,e.createComponentVNode)(2,b,Object.assign({},I))),color:(0,e.normalizeProps)((0,e.createComponentVNode)(2,y,Object.assign({},I))),list:(0,e.normalizeProps)((0,e.createComponentVNode)(2,S,Object.assign({},I)))};return(0,e.createComponentVNode)(2,t.Box,{children:[A,": ",M[x]]})},h=function(I,L){var w=I.active,A=I.userradiated,x=I.usertoxins,E=I.usermaxtoxins,P=I.threatlevel;return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Radiation Level",color:w&&A?"bad":"good",children:w&&A?"IRRADIATED!":"RADIATION-FREE"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Toxins Level",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?x/E:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:x})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Hazard Level",color:w&&P?"bad":"good",bold:!0,children:w&&P?P:0})})]})},i=function(I,L){var w=I.active,A=I.userhealth,x=I.usermaxhealth,E=I.userbrute,P=I.userburn,D=I.usertoxin,M=I.useroxy;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"Health",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?A/x:0,ranges:{good:[.5,1/0],average:[.2,.5],bad:[-1/0,.2]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?A:0})})}),(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Brute",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?E/x:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?E:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Burn",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?P/x:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?P:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Toxin",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?D/x:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?D:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Suffocation",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?M/x:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?M:0})})})})]})],4)},c=function(I,L){var w=I.active,A=I.statustime,x=I.statusid,E=I.statushealth,P=I.statusmaxhealth,D=I.statusbrute,M=I.statusburn,O=I.statustoxin,R=I.statusoxy,F=I.statustemp,W=I.statusnutrition,U=I.statusfingerprints,z=I.statusdna,$=I.statusviruses;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Operation Time",children:w?A:"00:00:00"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Operation Number",children:w?x||"0":"???"})})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Health",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?E/P:0,ranges:{good:[.5,1/0],average:[.2,.5],bad:[-1/0,.2]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?E:0})})}),(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Brute",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?D/P:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?D:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Burn",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?M/P:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?M:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Toxin",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?O/P:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:O})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Suffocation",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?R/P:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:R})})})})]}),(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Body Temperature",children:w?F:0})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Nutrition Status",children:w?W:0})})]}),(0,e.createComponentVNode)(2,t.Section,{title:"DNA",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fingerprints",children:w?U:"???"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Unique Enzymes",children:w?z:"???"})]})}),!!w&&!!$&&(0,e.createComponentVNode)(2,t.Section,{title:"Diseases",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"signature",tooltip:"Name",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"wind",tooltip:"Type",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"bolt",tooltip:"Stage",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"flask",tooltip:"Cure",tooltipPosition:"top"})})]}),$.map(function(G){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:G.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:G.type}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:[G.stage,"/",G.maxstage]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:G.cure})]},G.name)})]})})],0)},m={rad_counter:h,health_analyzer:i,status_readout:c},l=function(){return(0,e.createComponentVNode)(2,t.Section,{align:"center",fill:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{color:"red",name:"exclamation-triangle",size:15}),(0,e.createComponentVNode)(2,t.Box,{fontSize:"30px",color:"red",children:"ERROR: INTERFACE UNRESPONSIVE"})]})},u=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data;return(0,e.createComponentVNode)(2,t.Dimmer,{children:(0,e.createComponentVNode)(2,t.Stack,{children:(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"16px",color:"blue",children:"SUIT UNPOWERED"})})})},s=function(I,L){var w=I.configuration_data,A=I.module_ref,x=Object.keys(w);return(0,e.createComponentVNode)(2,t.Dimmer,{backgroundColor:"rgba(0, 0, 0, 0.8)",children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:[x.map(function(E){var P=w[E];return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,k,{name:E,display_name:P.display_name,type:P.type,value:P.value,values:P.values,module_ref:A})},P.key)}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:I.onExit,icon:"times",textAlign:"center",children:"Exit"})})})]})})},d=function(I){switch(I){case 1:return"Use";case 2:return"Toggle";case 3:return"Select"}},v=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.active,P=x.malfunctioning,D=x.locked,M=x.open,O=x.selected_module,R=x.complexity,F=x.complexity_max,W=x.wearer_name,U=x.wearer_job,z=P?"Malfunctioning":E?"Active":"Inactive";return(0,e.createComponentVNode)(2,t.Section,{title:"Parameters",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:E?"Deactivate":"Activate",onClick:function(){function $(){return A("activate")}return $}()}),children:z}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID Lock",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:D?"lock-open":"lock",content:D?"Unlock":"Lock",onClick:function(){function $(){return A("lock")}return $}()}),children:D?"Locked":"Unlocked"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cover",children:M?"Open":"Closed"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Selected Module",children:O||"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Complexity",children:[R," (",F,")"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Occupant",children:[W,", ",U]})]})})},g=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.active,P=x.control,D=x.helmet,M=x.chestplate,O=x.gauntlets,R=x.boots,F=x.core,W=x.charge;return(0,e.createComponentVNode)(2,t.Section,{title:"Hardware",children:[(0,e.createComponentVNode)(2,t.Collapsible,{title:"Parts",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Control Unit",children:P}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Helmet",children:D||"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Chestplate",children:M||"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Gauntlets",children:O||"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Boots",children:R||"None"})]})}),(0,e.createComponentVNode)(2,t.Collapsible,{title:"Core",children:F&&(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Core Type",children:F}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Core Charge",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:W/100,content:W+"%",ranges:{good:[.6,1/0],average:[.3,.6],bad:[-1/0,.3]}})})]})||(0,e.createComponentVNode)(2,t.Box,{color:"bad",textAlign:"center",children:"No Core Detected"})})]})},C=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.active,P=x.modules,D=P.filter(function(M){return!!M.id});return(0,e.createComponentVNode)(2,t.Section,{title:"Info",children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:D.length!==0&&D.map(function(M){var O=m[M.id];return(0,e.createComponentVNode)(2,t.Stack.Item,{children:[!E&&(0,e.createComponentVNode)(2,u),(0,e.normalizeProps)((0,e.createComponentVNode)(2,O,Object.assign({},M,{active:E})))]},M.ref)})||(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",children:"No Info Modules Detected"})})})},f=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.complexity_max,P=x.modules,D=(0,a.useLocalState)(L,"module_configuration",null),M=D[0],O=D[1];return(0,e.createComponentVNode)(2,t.Section,{title:"Modules",fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:P.length!==0&&P.map(function(R){return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Collapsible,{title:R.module_name,children:(0,e.createComponentVNode)(2,t.Section,{children:[M===R.ref&&(0,e.createComponentVNode)(2,s,{configuration_data:R.configuration_data,module_ref:R.ref,onExit:function(){function F(){return O(null)}return F}()}),(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"save",tooltip:"Complexity",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"plug",tooltip:"Idle Power Cost",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"lightbulb",tooltip:"Active Power Cost",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"bolt",tooltip:"Use Power Cost",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"hourglass-half",tooltip:"Cooldown",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"tasks",tooltip:"Actions",tooltipPosition:"top"})})]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:[R.module_complexity,"/",E]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:R.idle_power}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:R.active_power}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:R.use_power}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:[R.cooldown>0&&R.cooldown/10||"0","/",R.cooldown_time/10,"s"]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function F(){return A("select",{ref:R.ref})}return F}(),icon:"bullseye",selected:R.module_active,tooltip:d(R.module_type),tooltipPosition:"left",disabled:!R.module_type}),(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function F(){return O(R.ref)}return F}(),icon:"cog",selected:M===R.ref,tooltip:"Configure",tooltipPosition:"left",disabled:R.configuration_data.length===0}),(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function F(){return A("pin",{ref:R.ref})}return F}(),icon:"thumbtack",selected:R.pinned,tooltip:"Pin",tooltipPosition:"left",disabled:!R.module_type})]})]})]}),(0,e.createComponentVNode)(2,t.Box,{children:R.description})]})})},R.ref)})||(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",children:"No Modules Detected"})})})})},N=r.MODsuitContent=function(){function B(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.ui_theme,P=x.interface_break;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!P,children:!!P&&(0,e.createComponentVNode)(2,l)||(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,v)}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,g)}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,C)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,f)})]})})}return B}(),V=r.MODsuit=function(){function B(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.ui_theme,P=x.interface_break;return(0,e.createComponentVNode)(2,o.Window,{theme:E,width:400,height:620,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,N)})})})}return B}()},78624:function(T,r,n){"use strict";r.__esModule=!0,r.MagnetController=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=n(3939),y=new Map([["n",{icon:"arrow-up",tooltip:"Move North"}],["e",{icon:"arrow-right",tooltip:"Move East"}],["s",{icon:"arrow-down",tooltip:"Move South"}],["w",{icon:"arrow-left",tooltip:"Move West"}],["c",{icon:"crosshairs",tooltip:"Move to Magnet"}],["r",{icon:"dice",tooltip:"Move Randomly"}]]),S=r.MagnetController=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=l.autolink,s=l.code,d=l.frequency,v=l.linkedMagnets,g=l.magnetConfiguration,C=l.path,f=l.pathPosition,N=l.probing,V=l.powerState,B=l.speed;return(0,e.createComponentVNode)(2,p.Window,{width:400,height:600,children:[(0,e.createComponentVNode)(2,b.ComplexModal),(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:[!u&&(0,e.createComponentVNode)(2,o.Section,{buttons:(0,e.createComponentVNode)(2,o.Button,{content:"Probe",icon:N?"spinner":"sync",iconSpin:!!N,disabled:N,onClick:function(){function I(){return m("probe_magnets")}return I}()}),title:"Magnet Linking",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Frequency",children:(0,a.toFixed)(d/10,1)}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Code",children:s})]})}),(0,e.createComponentVNode)(2,o.Section,{buttons:(0,e.createComponentVNode)(2,o.Button,{icon:V?"power-off":"times",content:V?"On":"Off",selected:V,onClick:function(){function I(){return m("toggle_power")}return I}()}),title:"Controller Configuration",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Speed",children:(0,e.createComponentVNode)(2,o.Slider,{value:B.value,minValue:B.min,maxValue:B.max,onChange:function(){function I(L,w){return m("set_speed",{speed:w})}return I}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Path",children:[Array.from(y.entries()).map(function(I){var L=I[0],w=I[1],A=w.icon,x=w.tooltip;return(0,e.createComponentVNode)(2,o.Button,{icon:A,tooltip:x,onClick:function(){function E(){return m("path_add",{code:L})}return E}()},L)}),(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",confirmIcon:"trash",confirmContent:"",float:"right",tooltip:"Reset Path",tooltipPosition:"left",onClick:function(){function I(){return m("path_clear")}return I}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"file-import",float:"right",tooltip:"Manually input path",tooltipPosition:"left",onClick:function(){function I(){return(0,b.modalOpen)(i,"path_custom_input")}return I}()}),(0,e.createComponentVNode)(2,o.BlockQuote,{children:C.map(function(I,L){var w=y.get(I)||{icon:"question"},A=w.icon,x=w.tooltip;return(0,e.createComponentVNode)(2,o.Button.Confirm,{selected:L+2===f,icon:A,confirmIcon:A,confirmContent:"",tooltip:x,onClick:function(){function E(){return m("path_remove",{index:L+1,code:I})}return E}()},L)})})]})]})}),v.map(function(I,L){var w=I.uid,A=I.powerState,x=I.electricityLevel,E=I.magneticField;return(0,e.createComponentVNode)(2,o.Section,{title:"Magnet #"+(L+1)+" Configuration",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:A?"power-off":"times",content:A?"On":"Off",selected:A,onClick:function(){function P(){return m("toggle_magnet_power",{id:w})}return P}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Move Speed",children:(0,e.createComponentVNode)(2,o.Slider,{value:x,minValue:g.electricityLevel.min,maxValue:g.electricityLevel.max,onChange:function(){function P(D,M){return m("set_electricity_level",{id:w,electricityLevel:M})}return P}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Field Size",children:(0,e.createComponentVNode)(2,o.Slider,{value:E,minValue:g.magneticField.min,maxValue:g.magneticField.max,onChange:function(){function P(D,M){return m("set_magnetic_field",{id:w,magneticField:M})}return P}()})})]})},w)})]})]})}return k}()},72106:function(T,r,n){"use strict";r.__esModule=!0,r.MechBayConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.MechBayConsole=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.recharge_port,m=c&&c.mech,l=m&&m.cell,u=m&&m.name;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:155,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:u?"Mech status: "+u:"Mech status",textAlign:"center",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"sync",content:"Sync",onClick:function(){function s(){return h("reconnect")}return s}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Integrity",children:!c&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No power port detected. Please re-sync."})||!m&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No mech detected."})||(0,e.createComponentVNode)(2,t.ProgressBar,{value:m.health/m.maxhealth,ranges:{good:[.7,1/0],average:[.3,.7],bad:[-1/0,.3]}})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:!c&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No power port detected. Please re-sync."})||!m&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No mech detected."})||!l&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No cell is installed."})||(0,e.createComponentVNode)(2,t.ProgressBar,{value:l.charge/l.maxcharge,ranges:{good:[.7,1/0],average:[.3,.7],bad:[-1/0,.3]},children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:l.charge})," / "+l.maxcharge]})})]})})})})}return b}()},7466:function(T,r,n){"use strict";r.__esModule=!0,r.MechaControlConsole=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=n(25328),y=r.MechaControlConsole=function(){function S(k,h){var i=(0,t.useBackend)(h),c=i.act,m=i.data,l=m.beacons,u=m.stored_data;return u.length?(0,e.createComponentVNode)(2,p.Window,{width:420,height:500,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Section,{title:"Log",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"window-close",onClick:function(){function s(){return c("clear_log")}return s}()}),children:u.map(function(s){return(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,o.Box,{color:"label",children:["(",s.time,")"]}),(0,e.createComponentVNode)(2,o.Box,{children:(0,b.decodeHtmlEntities)(s.message)})]},s.time)})})})}):(0,e.createComponentVNode)(2,p.Window,{width:420,height:500,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:l.length&&l.map(function(s){return(0,e.createComponentVNode)(2,o.Section,{title:s.name,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{icon:"comment",onClick:function(){function d(){return c("send_message",{mt:s.uid})}return d}(),children:"Message"}),(0,e.createComponentVNode)(2,o.Button,{icon:"eye",onClick:function(){function d(){return c("get_log",{mt:s.uid})}return d}(),children:"View Log"}),(0,e.createComponentVNode)(2,o.Button.Confirm,{color:"red",content:"Sabotage",icon:"bomb",onClick:function(){function d(){return c("shock",{mt:s.uid})}return d}()})],4),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,o.ProgressBar,{ranges:{good:[s.maxHealth*.75,1/0],average:[s.maxHealth*.5,s.maxHealth*.75],bad:[-1/0,s.maxHealth*.5]},value:s.health,maxValue:s.maxHealth})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Cell Charge",children:s.cell&&(0,e.createComponentVNode)(2,o.ProgressBar,{ranges:{good:[s.cellMaxCharge*.75,1/0],average:[s.cellMaxCharge*.5,s.cellMaxCharge*.75],bad:[-1/0,s.cellMaxCharge*.5]},value:s.cellCharge,maxValue:s.cellMaxCharge})||(0,e.createComponentVNode)(2,o.NoticeBox,{children:"No Cell Installed"})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Air Tank",children:[s.airtank,"kPa"]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Pilot",children:s.pilot||"Unoccupied"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Location",children:(0,b.toTitleCase)(s.location)||"Unknown"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Active Equipment",children:s.active||"None"}),s.cargoMax&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Cargo Space",children:(0,e.createComponentVNode)(2,o.ProgressBar,{ranges:{bad:[s.cargoMax*.75,1/0],average:[s.cargoMax*.5,s.cargoMax*.75],good:[-1/0,s.cargoMax*.5]},value:s.cargoUsed,maxValue:s.cargoMax})})||null]})},s.name)})||(0,e.createComponentVNode)(2,o.NoticeBox,{children:"No mecha beacons found."})})})}return S}()},79625:function(T,r,n){"use strict";r.__esModule=!0,r.MedicalRecords=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(3939),b=n(98595),y=n(321),S=n(5485),k=n(22091),h={Minor:"lightgray",Medium:"good",Harmful:"average","Dangerous!":"bad","BIOHAZARD THREAT!":"darkred"},i={"*Deceased*":"deceased","*SSD*":"ssd","Physically Unfit":"physically_unfit",Disabled:"disabled"},c=function(A,x){(0,p.modalOpen)(A,"edit",{field:x.edit,value:x.value})},m=function(A,x){var E=A.args;return(0,e.createComponentVNode)(2,o.Section,{m:"-1rem",pb:"1.5rem",title:E.name||"Virus",children:(0,e.createComponentVNode)(2,o.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Number of stages",children:E.max_stages}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Spread",children:[E.spread_text," Transmission"]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Possible cure",children:E.cure}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Notes",children:E.desc}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Severity",color:h[E.severity],children:E.severity})]})})})},l=r.MedicalRecords=function(){function w(A,x){var E=(0,t.useBackend)(x),P=E.data,D=P.loginState,M=P.screen;if(!D.logged_in)return(0,e.createComponentVNode)(2,b.Window,{width:800,height:900,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,S.LoginScreen)})});var O;return M===2?O=(0,e.createComponentVNode)(2,u):M===3?O=(0,e.createComponentVNode)(2,s):M===4?O=(0,e.createComponentVNode)(2,d):M===5?O=(0,e.createComponentVNode)(2,f):M===6?O=(0,e.createComponentVNode)(2,N):M===7&&(O=(0,e.createComponentVNode)(2,V)),(0,e.createComponentVNode)(2,b.Window,{width:800,height:900,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y.LoginInfo),(0,e.createComponentVNode)(2,k.TemporaryNotice),(0,e.createComponentVNode)(2,L),O]})})]})}return w}(),u=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.records,O=(0,t.useLocalState)(x,"searchText",""),R=O[0],F=O[1],W=(0,t.useLocalState)(x,"sortId","name"),U=W[0],z=W[1],$=(0,t.useLocalState)(x,"sortOrder",!0),G=$[0],X=$[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{content:"Manage Records",icon:"wrench",ml:"0.25rem",onClick:function(){function J(){return P("screen",{screen:3})}return J}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{fluid:!0,placeholder:"Search by Name, ID, Physical Status, or Mental Status",onInput:function(){function J(se,ie){return F(ie)}return J}()})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,mt:.5,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"MedicalRecords__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,B,{id:"name",children:"Name"}),(0,e.createComponentVNode)(2,B,{id:"id",children:"ID"}),(0,e.createComponentVNode)(2,B,{id:"rank",children:"Assignment"}),(0,e.createComponentVNode)(2,B,{id:"p_stat",children:"Patient Status"}),(0,e.createComponentVNode)(2,B,{id:"m_stat",children:"Mental Status"})]}),M.filter((0,a.createSearch)(R,function(J){return J.name+"|"+J.id+"|"+J.rank+"|"+J.p_stat+"|"+J.m_stat})).sort(function(J,se){var ie=G?1:-1;return J[U].localeCompare(se[U])*ie}).map(function(J){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"MedicalRecords__listRow--"+i[J.p_stat],onClick:function(){function se(){return P("view_record",{view_record:J.ref})}return se}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user"})," ",J.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.id}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.rank}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.p_stat}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.m_stat})]},J.id)})]})})})],4)},s=function(A,x){var E=(0,t.useBackend)(x),P=E.act;return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,translucent:!0,lineHeight:3,icon:"download",content:"Backup to Disk",disabled:!0})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:[(0,e.createComponentVNode)(2,o.Button,{fluid:!0,translucent:!0,lineHeight:3,icon:"upload",content:"Upload from Disk",my:"0.5rem",disabled:!0})," "]}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Button.Confirm,{fluid:!0,translucent:!0,lineHeight:3,icon:"trash",content:"Delete All Medical Records",onClick:function(){function D(){return P("del_all_med_records")}return D}()})})]})})},d=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.medical,O=D.printing;return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{height:"235px",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"General Data",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:O?"spinner":"print",disabled:O,iconSpin:!!O,content:"Print Record",ml:"0.5rem",onClick:function(){function R(){return P("print_record")}return R}()}),children:(0,e.createComponentVNode)(2,v)})}),!M||!M.fields?(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Medical Data",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"pen",content:"Create New Record",onClick:function(){function R(){return P("new_med_record")}return R}()}),children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{bold:!0,grow:!0,textAlign:"center",fontSize:1.75,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon.Stack,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"scroll",size:5,color:"gray"}),(0,e.createComponentVNode)(2,o.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"Medical records lost!"]})})})}):(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Medical Data",buttons:(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",disabled:!!M.empty,content:"Delete Medical Record",onClick:function(){function R(){return P("del_med_record")}return R}()}),children:(0,e.createComponentVNode)(2,g)})}),(0,e.createComponentVNode)(2,C)],4)],0)},v=function(A,x){var E=(0,t.useBackend)(x),P=E.data,D=P.general;return!D||!D.fields?(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:"General records lost!"})})}):(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:D.fields.map(function(M,O){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:M.field,children:[(0,e.createComponentVNode)(2,o.Box,{height:"20px",inline:!0,children:M.value}),!!M.edit&&(0,e.createComponentVNode)(2,o.Button,{icon:"pen",ml:"0.5rem",onClick:function(){function R(){return c(x,M)}return R}()})]},O)})})}),!!D.has_photos&&D.photos.map(function(M,O){return(0,e.createComponentVNode)(2,o.Stack.Item,{inline:!0,textAlign:"center",color:"label",ml:0,children:[(0,e.createVNode)(1,"img",null,null,1,{src:M,style:{width:"96px","margin-top":"2.5rem","margin-bottom":"0.5rem","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}}),(0,e.createVNode)(1,"br"),"Photo #",O+1]},O)})]})},g=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.medical;return!M||!M.fields?(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:"Medical records lost!"})})}):(0,e.createComponentVNode)(2,o.Stack,{children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:M.fields.map(function(O,R){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:O.field,preserveWhitespace:!0,children:[(0,a.decodeHtmlEntities)(O.value),!!O.edit&&(0,e.createComponentVNode)(2,o.Button,{icon:"pen",ml:"0.5rem",mb:O.line_break?"1rem":"initial",onClick:function(){function F(){return c(x,O)}return F}()})]},R)})})})})},C=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.medical;return(0,e.createComponentVNode)(2,o.Stack.Item,{height:"150px",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Comments/Log",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"comment",content:"Add Entry",onClick:function(){function O(){return(0,p.modalOpen)(x,"add_comment")}return O}()}),children:M.comments.length===0?(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No comments found."}):M.comments.map(function(O,R){return(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,o.Box,{color:"label",inline:!0,children:O.header}),(0,e.createVNode)(1,"br"),O.text,(0,e.createComponentVNode)(2,o.Button,{icon:"comment-slash",color:"bad",ml:"0.5rem",onClick:function(){function F(){return P("del_comment",{del_comment:R+1})}return F}()})]},R)})})})},f=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.virus,O=(0,t.useLocalState)(x,"searchText",""),R=O[0],F=O[1],W=(0,t.useLocalState)(x,"sortId2","name"),U=W[0],z=W[1],$=(0,t.useLocalState)(x,"sortOrder2",!0),G=$[0],X=$[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{ml:"0.25rem",fluid:!0,placeholder:"Search by Name, Max Stages, or Severity",onInput:function(){function J(se,ie){return F(ie)}return J}()})}),(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,mt:.5,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"MedicalRecords__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,I,{id:"name",children:"Name"}),(0,e.createComponentVNode)(2,I,{id:"max_stages",children:"Max Stages"}),(0,e.createComponentVNode)(2,I,{id:"severity",children:"Severity"})]}),M.filter((0,a.createSearch)(R,function(J){return J.name+"|"+J.max_stages+"|"+J.severity})).sort(function(J,se){var ie=G?1:-1;return J[U].localeCompare(se[U])*ie}).map(function(J){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"MedicalRecords__listVirus--"+J.severity,onClick:function(){function se(){return P("vir",{vir:J.D})}return se}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"virus"})," ",J.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.max_stages}),(0,e.createComponentVNode)(2,o.Table.Cell,{color:h[J.severity],children:J.severity})]},J.id)})]})})})})],4)},N=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.goals;return(0,e.createComponentVNode)(2,o.Section,{title:"Virology Goals",fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:M.length!==0&&M.map(function(O){return(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:O.name,children:[(0,e.createComponentVNode)(2,o.Table,{children:(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:(0,e.createComponentVNode)(2,o.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,o.ProgressBar,{value:O.delivered,minValue:0,maxValue:O.deliverygoal,ranges:{good:[O.deliverygoal*.5,1/0],average:[O.deliverygoal*.25,O.deliverygoal*.5],bad:[-1/0,O.deliverygoal*.25]},children:[O.delivered," / ",O.deliverygoal," Units"]})})})}),(0,e.createComponentVNode)(2,o.Box,{children:O.report})]})},O.id)})||(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Box,{textAlign:"center",children:"No Goals Detected"})})})})},V=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.medbots;return M.length===0?(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{bold:!0,grow:!0,textAlign:"center",fontSize:1.75,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon.Stack,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"robot",size:5,color:"gray"}),(0,e.createComponentVNode)(2,o.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"There are no Medibots."]})})})}):(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"MedicalRecords__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Area"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Chemicals"})]}),M.map(function(O){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"MedicalRecords__listMedbot--"+O.on,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"medical"})," ",O.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:[O.area||"Unknown"," (",O.x,", ",O.y,")"]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:O.on?(0,e.createComponentVNode)(2,o.Box,{color:"good",children:"Online"}):(0,e.createComponentVNode)(2,o.Box,{color:"average",children:"Offline"})}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:O.use_beaker?"Reservoir: "+O.total_volume+"/"+O.maximum_volume:"Using internal synthesizer"})]},O.id)})]})})})},B=function(A,x){var E=(0,t.useLocalState)(x,"sortId","name"),P=E[0],D=E[1],M=(0,t.useLocalState)(x,"sortOrder",!0),O=M[0],R=M[1],F=A.id,W=A.children;return(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,color:P!==F&&"transparent",onClick:function(){function U(){P===F?R(!O):(D(F),R(!0))}return U}(),children:[W,P===F&&(0,e.createComponentVNode)(2,o.Icon,{name:O?"sort-up":"sort-down",ml:"0.25rem;"})]})})},I=function(A,x){var E=(0,t.useLocalState)(x,"sortId2","name"),P=E[0],D=E[1],M=(0,t.useLocalState)(x,"sortOrder2",!0),O=M[0],R=M[1],F=A.id,W=A.children;return(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,color:P!==F&&"transparent",onClick:function(){function U(){P===F?R(!O):(D(F),R(!0))}return U}(),children:[W,P===F&&(0,e.createComponentVNode)(2,o.Icon,{name:O?"sort-up":"sort-down",ml:"0.25rem;"})]})})},L=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.screen,O=D.general;return(0,e.createComponentVNode)(2,o.Stack.Item,{m:0,children:(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"list",selected:M===2,onClick:function(){function R(){P("screen",{screen:2})}return R}(),children:"List Records"}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"database",selected:M===5,onClick:function(){function R(){P("screen",{screen:5})}return R}(),children:"Virus Database"}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"vial",selected:M===6,onClick:function(){function R(){P("screen",{screen:6})}return R}(),children:"Virology Goals"}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"plus-square",selected:M===7,onClick:function(){function R(){return P("screen",{screen:7})}return R}(),children:"Medibot Tracking"}),M===3&&(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"wrench",selected:M===3,children:"Record Maintenance"}),M===4&&O&&!O.empty&&(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"file",selected:M===4,children:["Record: ",O.fields[0].value]})]})})};(0,p.modalRegisterBodyOverride)("virus",m)},54989:function(T,r,n){"use strict";r.__esModule=!0,r.MerchVendor=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=h.product,s=h.productImage,d=h.productCategory,v=l.user_money;return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,children:(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+s,style:{"vertical-align":"middle",width:"32px",margin:"0px","margin-left":"0px"}})}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:u.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{disabled:u.price>v,icon:"shopping-cart",content:u.price,textAlign:"left",onClick:function(){function g(){return m("purchase",{name:u.name,category:d})}return g}()})})]})},b=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=(0,a.useLocalState)(i,"tabIndex",1),u=l[0],s=m.products,d=m.imagelist,v=["apparel","toy","decoration"];return(0,e.createComponentVNode)(2,t.Table,{children:s[v[u]].map(function(g){return(0,e.createComponentVNode)(2,p,{product:g,productImage:d[g.path],productCategory:v[u]},g.name)})})},y=r.MerchVendor=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.user_cash,s=l.inserted_cash;return(0,e.createComponentVNode)(2,o.Window,{title:"Merch Computer",width:450,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"User",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{color:"light-grey",inline:!0,mr:"0.5rem",children:["There is ",(0,e.createVNode)(1,"b",null,s,0)," credits inserted."]}),(0,e.createComponentVNode)(2,t.Button,{disabled:!s,icon:"money-bill-wave-alt",content:"Dispense Change",textAlign:"left",onClick:function(){function d(){return m("change")}return d}()})],4),children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:["Doing your job and not getting any recognition at work? Well, welcome to the merch shop! Here, you can buy cool things in exchange for money you earn when you have completed your Job Objectives.",u!==null&&(0,e.createComponentVNode)(2,t.Box,{mt:"0.5rem",children:["Your balance is ",(0,e.createVNode)(1,"b",null,[u||0,(0,e.createTextVNode)(" credits")],0),"."]})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Products",children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,b)]})})]})})})}return k}(),S=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=(0,a.useLocalState)(i,"tabIndex",1),u=l[0],s=l[1],d=m.login_state;return(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"dice",selected:u===1,onClick:function(){function v(){return s(1)}return v}(),children:"Toys"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"flag",selected:u===2,onClick:function(){function v(){return s(2)}return v}(),children:"Decorations"})]})}},87684:function(T,r,n){"use strict";r.__esModule=!0,r.MiningVendor=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=["title","items","gridLayout"];function y(l,u){if(l==null)return{};var s={};for(var d in l)if({}.hasOwnProperty.call(l,d)){if(u.includes(d))continue;s[d]=l[d]}return s}var S={Alphabetical:function(){function l(u,s){return u-s}return l}(),Availability:function(){function l(u,s){return-(u.affordable-s.affordable)}return l}(),Price:function(){function l(u,s){return u.price-s.price}return l}()},k=r.MiningVendor=function(){function l(u,s){var d=(0,t.useLocalState)(s,"gridLayout",!1),v=d[0],g=d[1];return(0,e.createComponentVNode)(2,p.Window,{width:400,height:525,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,c,{gridLayout:v,setGridLayout:g}),(0,e.createComponentVNode)(2,i,{gridLayout:v})]})})})}return l}(),h=function(u,s){var d=(0,t.useBackend)(s),v=d.act,g=d.data,C=g.has_id,f=g.id;return(0,e.createComponentVNode)(2,o.NoticeBox,{success:C,children:C?(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Box,{inline:!0,verticalAlign:"middle",style:{float:"left"},children:["Logged in as ",f.name,".",(0,e.createVNode)(1,"br"),"You have ",f.points.toLocaleString("en-US")," points."]}),(0,e.createComponentVNode)(2,o.Button,{icon:"eject",content:"Eject ID",style:{float:"right"},onClick:function(){function N(){return v("logoff")}return N}()}),(0,e.createComponentVNode)(2,o.Box,{style:{clear:"both"}})],4):"Please insert an ID in order to make purchases."})},i=function(u,s){var d=(0,t.useBackend)(s),v=d.act,g=d.data,C=g.has_id,f=g.id,N=g.items,V=u.gridLayout,B=(0,t.useLocalState)(s,"search",""),I=B[0],L=B[1],w=(0,t.useLocalState)(s,"sort","Alphabetical"),A=w[0],x=w[1],E=(0,t.useLocalState)(s,"descending",!1),P=E[0],D=E[1],M=(0,a.createSearch)(I,function(F){return F[0]}),O=!1,R=Object.entries(N).map(function(F,W){var U=Object.entries(F[1]).filter(M).map(function(z){return z[1].affordable=C&&f.points>=z[1].price,z[1]}).sort(S[A]);if(U.length!==0)return P&&(U=U.reverse()),O=!0,(0,e.createComponentVNode)(2,m,{title:F[0],items:U,gridLayout:V},F[0])});return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,mt:.5,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:O?R:(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No items matching your criteria was found!"})})})},c=function(u,s){var d=u.gridLayout,v=u.setGridLayout,g=(0,t.useLocalState)(s,"search",""),C=g[0],f=g[1],N=(0,t.useLocalState)(s,"sort",""),V=N[0],B=N[1],I=(0,t.useLocalState)(s,"descending",!1),L=I[0],w=I[1];return(0,e.createComponentVNode)(2,o.Box,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{mt:.2,placeholder:"Search by item name..",width:"100%",onInput:function(){function A(x,E){return f(E)}return A}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:d?"list":"table-cells-large",height:1.75,tooltip:d?"Toggle List Layout":"Toggle Grid Layout",tooltipPosition:"bottom-start",onClick:function(){function A(){return v(!d)}return A}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"30%",children:(0,e.createComponentVNode)(2,o.Dropdown,{selected:"Alphabetical",options:Object.keys(S),width:"100%",onSelected:function(){function A(x){return B(x)}return A}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:L?"arrow-down":"arrow-up",height:1.75,tooltip:L?"Descending order":"Ascending order",tooltipPosition:"bottom-start",onClick:function(){function A(){return w(!L)}return A}()})})]})})},m=function(u,s){var d=(0,t.useBackend)(s),v=d.act,g=d.data,C=u.title,f=u.items,N=u.gridLayout,V=y(u,b);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Collapsible,Object.assign({open:!0,title:C},V,{children:f.map(function(B){return N?(0,e.createComponentVNode)(2,o.ImageButton,{mb:.5,imageSize:57.5,dmIcon:B.icon,dmIconState:B.icon_state,disabled:!g.has_id||g.id.points0&&(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__menuButton--unread",children:ae>=10?"9+":ae})}),(0,e.createComponentVNode)(2,s,{icon:"briefcase",title:"Job Openings",selected:R===1,onClick:function(){function le(){return x("jobs")}return le}()}),(0,e.createComponentVNode)(2,o.Divider)]}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:F.map(function(le){return(0,e.createComponentVNode)(2,s,{icon:le.icon,title:le.name,selected:R===2&&F[U-1]===le,onClick:function(){function Z(){return x("channel",{uid:le.uid})}return Z}(),children:le.unread>0&&(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__menuButton--unread",children:le.unread>=10?"9+":le.unread})},le)})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:[(0,e.createComponentVNode)(2,o.Divider),(!!P||!!D)&&(0,e.createFragment)([(0,e.createComponentVNode)(2,s,{security:!0,icon:"exclamation-circle",title:"Edit Wanted Notice",mb:"0.5rem",onClick:function(){function le(){return(0,y.modalOpen)(w,"wanted_notice")}return le}()}),(0,e.createComponentVNode)(2,s,{security:!0,icon:me?"minus-square":"minus-square-o",title:"Censor Mode: "+(me?"On":"Off"),mb:"0.5rem",onClick:function(){function le(){return q(!me)}return le}()}),(0,e.createComponentVNode)(2,o.Divider)],4),(0,e.createComponentVNode)(2,s,{icon:"pen-alt",title:"New Story",mb:"0.5rem",onClick:function(){function le(){return(0,y.modalOpen)(w,"create_story")}return le}()}),(0,e.createComponentVNode)(2,s,{icon:"plus-circle",title:"New Channel",onClick:function(){function le(){return(0,y.modalOpen)(w,"create_channel")}return le}()}),(0,e.createComponentVNode)(2,o.Divider),(0,e.createComponentVNode)(2,s,{icon:O?"spinner":"print",iconSpin:O,title:O?"Printing...":"Print Newspaper",onClick:function(){function le(){return x("print_newspaper")}return le}()}),(0,e.createComponentVNode)(2,s,{icon:M?"volume-mute":"volume-up",title:"Mute: "+(M?"On":"Off"),onClick:function(){function le(){return x("toggle_mute")}return le}()})]})]})}),(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,width:"100%",children:[(0,e.createComponentVNode)(2,S.TemporaryNotice),re]})]})})]})}return I}(),s=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=L.icon,P=E===void 0?"":E,D=L.iconSpin,M=L.selected,O=M===void 0?!1:M,R=L.security,F=R===void 0?!1:R,W=L.onClick,U=L.title,z=L.children,$=i(L,k);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Box,Object.assign({className:(0,a.classes)(["Newscaster__menuButton",O&&"Newscaster__menuButton--selected",F&&"Newscaster__menuButton--security"]),onClick:W},$,{children:[O&&(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__menuButton--selectedBar"}),(0,e.createComponentVNode)(2,o.Icon,{name:P,spin:D,size:"2"}),(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__menuButton--title",children:U}),z]})))},d=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=E.screen,D=E.is_admin,M=E.channel_idx,O=E.channel_can_manage,R=E.channels,F=E.stories,W=E.wanted,U=(0,t.useLocalState)(w,"fullStories",[]),z=U[0],$=U[1],G=(0,t.useLocalState)(w,"censorMode",!1),X=G[0],J=G[1],se=P===2&&M>-1?R[M-1]:null;return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[!!W&&(0,e.createComponentVNode)(2,g,{story:W,wanted:!0}),(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Icon,{name:se?se.icon:"newspaper",mr:"0.5rem"}),se?se.name:"Headlines"],0),children:F.length>0?F.slice().reverse().map(function(ie){return!z.includes(ie.uid)&&ie.body.length+3>c?Object.assign({},ie,{body_short:ie.body.substr(0,c-4)+"..."}):ie}).map(function(ie,me){return(0,e.createComponentVNode)(2,g,{story:ie},me)}):(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__emptyNotice",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"times",size:"3"}),(0,e.createVNode)(1,"br"),"There are no stories at this time."]})}),!!se&&(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,height:"40%",title:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Icon,{name:"info-circle",mr:"0.5rem"}),(0,e.createTextVNode)("About")],4),buttons:(0,e.createFragment)([X&&(0,e.createComponentVNode)(2,o.Button,{disabled:!!se.admin&&!D,selected:se.censored,icon:se.censored?"comment-slash":"comment",content:se.censored?"Uncensor Channel":"Censor Channel",mr:"0.5rem",onClick:function(){function ie(){return x("censor_channel",{uid:se.uid})}return ie}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:!O,icon:"cog",content:"Manage",onClick:function(){function ie(){return(0,y.modalOpen)(w,"manage_channel",{uid:se.uid})}return ie}()})],0),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Description",children:se.description||"N/A"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Owner",children:se.author||"N/A"}),!!D&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Ckey",children:se.author_ckey}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Public",children:se.public?"Yes":"No"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Total Views",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"eye",mr:"0.5rem"}),F.reduce(function(ie,me){return ie+me.view_count},0).toLocaleString()]})]})})]})},v=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=E.jobs,D=E.wanted,M=Object.entries(P).reduce(function(O,R){var F=R[0],W=R[1];return O+W.length},0);return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[!!D&&(0,e.createComponentVNode)(2,g,{story:D,wanted:!0}),(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Icon,{name:"briefcase",mr:"0.5rem"}),(0,e.createTextVNode)("Job Openings")],4),buttons:(0,e.createComponentVNode)(2,o.Box,{mt:"0.25rem",color:"label",children:"Work for a better future at Nanotrasen"}),children:M>0?m.map(function(O){return Object.assign({},l[O],{id:O,jobs:P[O]})}).filter(function(O){return!!O&&O.jobs.length>0}).map(function(O){return(0,e.createComponentVNode)(2,o.Section,{className:(0,a.classes)(["Newscaster__jobCategory","Newscaster__jobCategory--"+O.id]),title:O.title,buttons:(0,e.createComponentVNode)(2,o.Box,{mt:"0.25rem",color:"label",children:O.fluff_text}),children:O.jobs.map(function(R){return(0,e.createComponentVNode)(2,o.Box,{class:(0,a.classes)(["Newscaster__jobOpening",!!R.is_command&&"Newscaster__jobOpening--command"]),children:["\u2022 ",R.title]},R.title)})},O.id)}):(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__emptyNotice",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"times",size:"3"}),(0,e.createVNode)(1,"br"),"There are no openings at this time."]})}),(0,e.createComponentVNode)(2,o.Section,{height:"17%",children:["Interested in serving Nanotrasen?",(0,e.createVNode)(1,"br"),"Sign up for any of the above position now at the ",(0,e.createVNode)(1,"b",null,"Head of Personnel's Office!",16),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Box,{as:"small",color:"label",children:"By signing up for a job at Nanotrasen, you agree to transfer your soul to the loyalty department of the omnipresent and helpful watcher of humanity."})]})]})},g=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=L.story,D=L.wanted,M=D===void 0?!1:D,O=E.is_admin,R=(0,t.useLocalState)(w,"fullStories",[]),F=R[0],W=R[1],U=(0,t.useLocalState)(w,"censorMode",!1),z=U[0],$=U[1];return(0,e.createComponentVNode)(2,o.Section,{className:(0,a.classes)(["Newscaster__story",M&&"Newscaster__story--wanted"]),title:(0,e.createFragment)([M&&(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-circle",mr:"0.5rem"}),P.censor_flags&2&&"[REDACTED]"||P.title||"News from "+P.author],0),buttons:(0,e.createComponentVNode)(2,o.Box,{mt:"0.25rem",children:(0,e.createComponentVNode)(2,o.Box,{color:"label",children:[!M&&z&&(0,e.createComponentVNode)(2,o.Box,{inline:!0,children:(0,e.createComponentVNode)(2,o.Button,{enabled:P.censor_flags&2,icon:P.censor_flags&2?"comment-slash":"comment",content:P.censor_flags&2?"Uncensor":"Censor",mr:"0.5rem",mt:"-0.25rem",onClick:function(){function G(){return x("censor_story",{uid:P.uid})}return G}()})}),(0,e.createComponentVNode)(2,o.Box,{inline:!0,children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user"})," ",P.author," |\xA0",!!O&&(0,e.createFragment)([(0,e.createTextVNode)("ckey: "),P.author_ckey,(0,e.createTextVNode)(" |\xA0")],0),!M&&(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Icon,{name:"eye"}),(0,e.createTextVNode)(" "),P.view_count.toLocaleString(),(0,e.createTextVNode)(" |\xA0")],0),(0,e.createComponentVNode)(2,o.Icon,{name:"clock"})," ",(0,p.timeAgo)(P.publish_time,E.world_time)]})]})}),children:(0,e.createComponentVNode)(2,o.Box,{children:P.censor_flags&2?"[REDACTED]":(0,e.createFragment)([!!P.has_photo&&(0,e.createComponentVNode)(2,C,{name:"story_photo_"+P.uid+".png",float:"right",ml:"0.5rem"}),(P.body_short||P.body).split("\n").map(function(G,X){return(0,e.createComponentVNode)(2,o.Box,{children:G||(0,e.createVNode)(1,"br")},X)}),P.body_short&&(0,e.createComponentVNode)(2,o.Button,{content:"Read more..",mt:"0.5rem",onClick:function(){function G(){return W([].concat(F,[P.uid]))}return G}()}),(0,e.createComponentVNode)(2,o.Box,{clear:"right"})],0)})})},C=function(L,w){var A=L.name,x=i(L,h),E=(0,t.useLocalState)(w,"viewingPhoto",""),P=E[0],D=E[1];return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Box,Object.assign({as:"img",className:"Newscaster__photo",src:A,onClick:function(){function M(){return D(A)}return M}()},x)))},f=function(L,w){var A=(0,t.useLocalState)(w,"viewingPhoto",""),x=A[0],E=A[1];return(0,e.createComponentVNode)(2,o.Modal,{className:"Newscaster__photoZoom",children:[(0,e.createComponentVNode)(2,o.Box,{as:"img",src:x}),(0,e.createComponentVNode)(2,o.Button,{icon:"times",content:"Close",color:"grey",mt:"1rem",onClick:function(){function P(){return E("")}return P}()})]})},N=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=!!L.args.uid&&E.channels.filter(function(te){return te.uid===L.args.uid}).pop();if(L.id==="manage_channel"&&!P){(0,y.modalClose)(w);return}var D=L.id==="manage_channel",M=!!L.args.is_admin,O=L.args.scanned_user,R=(0,t.useLocalState)(w,"author",(P==null?void 0:P.author)||O||"Unknown"),F=R[0],W=R[1],U=(0,t.useLocalState)(w,"name",(P==null?void 0:P.name)||""),z=U[0],$=U[1],G=(0,t.useLocalState)(w,"description",(P==null?void 0:P.description)||""),X=G[0],J=G[1],se=(0,t.useLocalState)(w,"icon",(P==null?void 0:P.icon)||"newspaper"),ie=se[0],me=se[1],q=(0,t.useLocalState)(w,"isPublic",D?!!(P!=null&&P.public):!1),re=q[0],ae=q[1],le=(0,t.useLocalState)(w,"adminLocked",(P==null?void 0:P.admin)===1||!1),Z=le[0],ne=le[1];return(0,e.createComponentVNode)(2,o.Section,{m:"-1rem",pb:"1.5rem",title:D?"Manage "+P.name:"Create New Channel",children:[(0,e.createComponentVNode)(2,o.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Owner",children:(0,e.createComponentVNode)(2,o.Input,{disabled:!M,width:"100%",value:F,onInput:function(){function te(fe,pe){return W(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Name",children:(0,e.createComponentVNode)(2,o.Input,{width:"100%",placeholder:"50 characters max.",maxLength:"50",value:z,onInput:function(){function te(fe,pe){return $(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Description (optional)",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Input,{multiline:!0,width:"100%",placeholder:"128 characters max.",maxLength:"128",value:X,onInput:function(){function te(fe,pe){return J(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Icon",children:[(0,e.createComponentVNode)(2,o.Input,{disabled:!M,value:ie,width:"35%",mr:"0.5rem",onInput:function(){function te(fe,pe){return me(pe)}return te}()}),(0,e.createComponentVNode)(2,o.Icon,{name:ie,size:"2",verticalAlign:"middle",mr:"0.5rem"})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Accept Public Stories?",children:(0,e.createComponentVNode)(2,o.Button,{selected:re,icon:re?"toggle-on":"toggle-off",content:re?"Yes":"No",onClick:function(){function te(){return ae(!re)}return te}()})}),M&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"CentComm Lock",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Button,{selected:Z,icon:Z?"lock":"lock-open",content:Z?"On":"Off",tooltip:"Locking this channel will make it editable by nobody but CentComm officers.",tooltipPosition:"top",onClick:function(){function te(){return ne(!Z)}return te}()})})]})}),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:F.trim().length===0||z.trim().length===0,icon:"check",color:"good",content:"Submit",position:"absolute",right:"1rem",bottom:"-0.75rem",onClick:function(){function te(){(0,y.modalAnswer)(w,L.id,"",{author:F,name:z.substr(0,49),description:X.substr(0,128),icon:ie,public:re?1:0,admin_locked:Z?1:0})}return te}()})]})},V=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=E.photo,D=E.channels,M=E.channel_idx,O=M===void 0?-1:M,R=!!L.args.is_admin,F=L.args.scanned_user,W=D.slice().sort(function(te,fe){if(O<0)return 0;var pe=D[O-1];if(pe.uid===te.uid)return-1;if(pe.uid===fe.uid)return 1}).filter(function(te){return R||!te.frozen&&(te.author===F||!!te.public)}),U=(0,t.useLocalState)(w,"author",F||"Unknown"),z=U[0],$=U[1],G=(0,t.useLocalState)(w,"channel",W.length>0?W[0].name:""),X=G[0],J=G[1],se=(0,t.useLocalState)(w,"title",""),ie=se[0],me=se[1],q=(0,t.useLocalState)(w,"body",""),re=q[0],ae=q[1],le=(0,t.useLocalState)(w,"adminLocked",!1),Z=le[0],ne=le[1];return(0,e.createComponentVNode)(2,o.Section,{m:"-1rem",pb:"1.5rem",title:"Create New Story",children:[(0,e.createComponentVNode)(2,o.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Author",children:(0,e.createComponentVNode)(2,o.Input,{disabled:!R,width:"100%",value:z,onInput:function(){function te(fe,pe){return $(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Channel",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Dropdown,{selected:X,options:W.map(function(te){return te.name}),mb:"0",width:"100%",onSelected:function(){function te(fe){return J(fe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Divider),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,o.Input,{width:"100%",placeholder:"128 characters max.",maxLength:"128",value:ie,onInput:function(){function te(fe,pe){return me(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Story Text",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Input,{fluid:!0,multiline:!0,placeholder:"1024 characters max.",maxLength:"1024",rows:"8",width:"100%",value:re,onInput:function(){function te(fe,pe){return ae(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Photo (optional)",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Button,{icon:"image",selected:P,content:P?"Eject: "+P.name:"Insert Photo",tooltip:!P&&"Attach a photo to this story by holding the photograph in your hand.",onClick:function(){function te(){return x(P?"eject_photo":"attach_photo")}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Preview",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Section,{noTopPadding:!0,title:ie,maxHeight:"13.5rem",overflow:"auto",children:(0,e.createComponentVNode)(2,o.Box,{mt:"0.5rem",children:[!!P&&(0,e.createComponentVNode)(2,C,{name:"inserted_photo_"+P.uid+".png",float:"right"}),re.split("\n").map(function(te,fe){return(0,e.createComponentVNode)(2,o.Box,{children:te||(0,e.createVNode)(1,"br")},fe)}),(0,e.createComponentVNode)(2,o.Box,{clear:"right"})]})})}),R&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"CentComm Lock",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Button,{selected:Z,icon:Z?"lock":"lock-open",content:Z?"On":"Off",tooltip:"Locking this story will make it censorable by nobody but CentComm officers.",tooltipPosition:"top",onClick:function(){function te(){return ne(!Z)}return te}()})})]})}),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:z.trim().length===0||X.trim().length===0||ie.trim().length===0||re.trim().length===0,icon:"check",color:"good",content:"Submit",position:"absolute",right:"1rem",bottom:"-0.75rem",onClick:function(){function te(){(0,y.modalAnswer)(w,"create_story","",{author:z,channel:X,title:ie.substr(0,127),body:re.substr(0,1023),admin_locked:Z?1:0})}return te}()})]})},B=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=E.photo,D=E.wanted,M=!!L.args.is_admin,O=L.args.scanned_user,R=(0,t.useLocalState)(w,"author",(D==null?void 0:D.author)||O||"Unknown"),F=R[0],W=R[1],U=(0,t.useLocalState)(w,"name",(D==null?void 0:D.title.substr(8))||""),z=U[0],$=U[1],G=(0,t.useLocalState)(w,"description",(D==null?void 0:D.body)||""),X=G[0],J=G[1],se=(0,t.useLocalState)(w,"adminLocked",(D==null?void 0:D.admin_locked)===1||!1),ie=se[0],me=se[1];return(0,e.createComponentVNode)(2,o.Section,{m:"-1rem",pb:"1.5rem",title:"Manage Wanted Notice",children:[(0,e.createComponentVNode)(2,o.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Authority",children:(0,e.createComponentVNode)(2,o.Input,{disabled:!M,width:"100%",value:F,onInput:function(){function q(re,ae){return W(ae)}return q}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Name",children:(0,e.createComponentVNode)(2,o.Input,{width:"100%",value:z,maxLength:"128",onInput:function(){function q(re,ae){return $(ae)}return q}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Description",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Input,{multiline:!0,width:"100%",value:X,maxLength:"512",rows:"4",onInput:function(){function q(re,ae){return J(ae)}return q}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Photo (optional)",verticalAlign:"top",children:[(0,e.createComponentVNode)(2,o.Button,{icon:"image",selected:P,content:P?"Eject: "+P.name:"Insert Photo",tooltip:!P&&"Attach a photo to this wanted notice by holding the photograph in your hand.",tooltipPosition:"top",onClick:function(){function q(){return x(P?"eject_photo":"attach_photo")}return q}()}),!!P&&(0,e.createComponentVNode)(2,C,{name:"inserted_photo_"+P.uid+".png",float:"right"})]}),M&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"CentComm Lock",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Button,{selected:ie,icon:ie?"lock":"lock-open",content:ie?"On":"Off",tooltip:"Locking this wanted notice will make it editable by nobody but CentComm officers.",tooltipPosition:"top",onClick:function(){function q(){return me(!ie)}return q}()})})]})}),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:!D,icon:"eraser",color:"danger",content:"Clear",position:"absolute",right:"7.25rem",bottom:"-0.75rem",onClick:function(){function q(){x("clear_wanted_notice"),(0,y.modalClose)(w)}return q}()}),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:F.trim().length===0||z.trim().length===0||X.trim().length===0,icon:"check",color:"good",content:"Submit",position:"absolute",right:"1rem",bottom:"-0.75rem",onClick:function(){function q(){(0,y.modalAnswer)(w,L.id,"",{author:F,name:z.substr(0,127),description:X.substr(0,511),admin_locked:ie?1:0})}return q}()})]})};(0,y.modalRegisterBodyOverride)("create_channel",N),(0,y.modalRegisterBodyOverride)("manage_channel",N),(0,y.modalRegisterBodyOverride)("create_story",V),(0,y.modalRegisterBodyOverride)("wanted_notice",B)},48286:function(T,r,n){"use strict";r.__esModule=!0,r.Noticeboard=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=r.Noticeboard=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.act,c=h.data,m=c.papers;return(0,e.createComponentVNode)(2,p.Window,{width:600,height:300,theme:"noticeboard",children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:m.map(function(l){return(0,e.createComponentVNode)(2,o.Stack.Item,{align:"center",width:"22.45%",height:"85%",onClick:function(){function u(){return i("interact",{paper:l.ref})}return u}(),onContextMenu:function(){function u(s){s.preventDefault(),i("showFull",{paper:l.ref})}return u}(),children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,fontSize:.75,title:l.name,children:(0,a.decodeHtmlEntities)(l.contents)})},l.ref)})})})})}return y}()},41166:function(T,r,n){"use strict";r.__esModule=!0,r.NuclearBomb=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.NuclearBomb=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;return i.extended?(0,e.createComponentVNode)(2,o.Window,{width:350,height:290,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Authorization",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auth Disk",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.authdisk?"eject":"id-card",selected:i.authdisk,content:i.diskname?i.diskname:"-----",tooltip:i.authdisk?"Eject Disk":"Insert Disk",onClick:function(){function c(){return h("auth")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auth Code",children:(0,e.createComponentVNode)(2,t.Button,{icon:"key",disabled:!i.authdisk,selected:i.authcode,content:i.codemsg,onClick:function(){function c(){return h("code")}return c}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Arming & Disarming",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Bolted to floor",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.anchored?"check":"times",selected:i.anchored,disabled:!i.authdisk,content:i.anchored?"YES":"NO",onClick:function(){function c(){return h("toggle_anchor")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Time Left",children:(0,e.createComponentVNode)(2,t.Button,{icon:"stopwatch",content:i.time,disabled:!i.authfull,tooltip:"Set Timer",onClick:function(){function c(){return h("set_time")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Safety",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.safety?"check":"times",selected:i.safety,disabled:!i.authfull,content:i.safety?"ON":"OFF",tooltip:i.safety?"Disable Safety":"Enable Safety",onClick:function(){function c(){return h("toggle_safety")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Arm/Disarm",children:(0,e.createComponentVNode)(2,t.Button,{icon:(i.timer,"bomb"),disabled:i.safety||!i.authfull,color:"red",content:i.timer?"DISARM THE NUKE":"ARM THE NUKE",onClick:function(){function c(){return h("toggle_armed")}return c}()})})]})})]})}):(0,e.createComponentVNode)(2,o.Window,{width:350,height:115,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Deployment",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"exclamation-triangle",content:"Deploy Nuclear Device (will bolt device to floor)",onClick:function(){function c(){return h("deploy")}return c}()})})})})}return b}()},52416:function(T,r,n){"use strict";r.__esModule=!0,r.NumberInputModal=void 0;var e=n(89005),a=n(51057),t=n(19203),o=n(92986),p=n(72253),b=n(36036),y=n(98595),S=r.NumberInputModal=function(){function h(i,c){var m=(0,p.useBackend)(c),l=m.act,u=m.data,s=u.init_value,d=u.large_buttons,v=u.message,g=v===void 0?"":v,C=u.timeout,f=u.title,N=(0,p.useLocalState)(c,"input",s),V=N[0],B=N[1],I=function(){function A(x){x!==V&&B(x)}return A}(),L=function(){function A(x){x!==V&&B(x)}return A}(),w=140+Math.max(Math.ceil(g.length/3),g.length>0&&d?5:0);return(0,e.createComponentVNode)(2,y.Window,{title:f,width:270,height:w,children:[C&&(0,e.createComponentVNode)(2,a.Loader,{value:C}),(0,e.createComponentVNode)(2,y.Window.Content,{onKeyDown:function(){function A(x){var E=window.event?x.which:x.keyCode;E===o.KEY_ENTER&&l("submit",{entry:V}),E===o.KEY_ESCAPE&&l("cancel")}return A}(),children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,children:(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Box,{color:"label",children:g})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,k,{input:V,onClick:L,onChange:I})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,t.InputButtons,{input:V})})]})})})]})}return h}(),k=function(i,c){var m=(0,p.useBackend)(c),l=m.act,u=m.data,s=u.min_value,d=u.max_value,v=u.init_value,g=u.round_value,C=i.input,f=i.onClick,N=i.onChange,V=Math.round(C!==s?Math.max(C/2,s):d/2),B=C===s&&s>0||C===1;return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Button,{disabled:C===s,icon:"angle-double-left",onClick:function(){function I(){return f(s)}return I}(),tooltip:C===s?"Min":"Min ("+s+")"})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.RestrictedInput,{autoFocus:!0,autoSelect:!0,fluid:!0,allowFloats:!g,minValue:s,maxValue:d,onChange:function(){function I(L,w){return N(w)}return I}(),onEnter:function(){function I(L,w){return l("submit",{entry:w})}return I}(),value:C})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Button,{disabled:C===d,icon:"angle-double-right",onClick:function(){function I(){return f(d)}return I}(),tooltip:C===d?"Max":"Max ("+d+")"})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Button,{disabled:B,icon:"divide",onClick:function(){function I(){return f(V)}return I}(),tooltip:B?"Split":"Split ("+V+")"})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Button,{disabled:C===v,icon:"redo",onClick:function(){function I(){return f(v)}return I}(),tooltip:v?"Reset ("+v+")":"Reset"})})]})}},1218:function(T,r,n){"use strict";r.__esModule=!0,r.OperatingComputer=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(98595),p=n(36036),b=[["good","Conscious"],["average","Unconscious"],["bad","DEAD"]],y=[["Resp.","oxyLoss"],["Toxin","toxLoss"],["Brute","bruteLoss"],["Burn","fireLoss"]],S={average:[.25,.5],bad:[.5,1/0]},k=["bad","average","average","good","average","average","bad"],h=r.OperatingComputer=function(){function l(u,s){var d=(0,t.useBackend)(s),v=d.act,g=d.data,C=g.hasOccupant,f=g.choice,N;return f?N=(0,e.createComponentVNode)(2,m):N=C?(0,e.createComponentVNode)(2,i):(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,o.Window,{width:650,height:455,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Tabs,{children:[(0,e.createComponentVNode)(2,p.Tabs.Tab,{selected:!f,icon:"user",onClick:function(){function V(){return v("choiceOff")}return V}(),children:"Patient"}),(0,e.createComponentVNode)(2,p.Tabs.Tab,{selected:!!f,icon:"cog",onClick:function(){function V(){return v("choiceOn")}return V}(),children:"Options"})]})}),(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,children:N})})]})})})}return l}(),i=function(u,s){var d=(0,t.useBackend)(s),v=d.data,g=v.occupant;return(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.Section,{fill:!0,title:"Patient",children:(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Name",children:g.name}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Status",color:b[g.stat][0],children:b[g.stat][1]}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:g.maxHealth,value:g.health/g.maxHealth,ranges:{good:[.5,1/0],average:[0,.5],bad:[-1/0,0]}})}),y.map(function(C,f){return(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:C[0]+" Damage",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:"100",value:g[C[1]]/100,ranges:S,children:(0,a.round)(g[C[1]])},f)},f)}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:g.maxTemp,value:g.bodyTemperature/g.maxTemp,color:k[g.temperatureSuitability+3],children:[(0,a.round)(g.btCelsius),"\xB0C, ",(0,a.round)(g.btFaren),"\xB0F"]})}),!!g.hasBlood&&(0,e.createFragment)([(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Blood Level",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:g.bloodMax,value:g.bloodLevel/g.bloodMax,ranges:{bad:[-1/0,.6],average:[.6,.9],good:[.6,1/0]},children:[g.bloodPercent,"%, ",g.bloodLevel,"cl"]})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Pulse",children:[g.pulse," BPM"]})],4)]})})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Section,{title:"Current Procedure",level:"2",children:g.inSurgery?(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Procedure",children:g.surgeryName}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Next Step",children:g.stepName})]}):(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"No procedure ongoing."})})})]})},c=function(){return(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,align:"center",textAlign:"center",color:"label",children:[(0,e.createComponentVNode)(2,p.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No patient detected."]})})},m=function(u,s){var d=(0,t.useBackend)(s),v=d.act,g=d.data,C=g.verbose,f=g.health,N=g.healthAlarm,V=g.oxy,B=g.oxyAlarm,I=g.crit;return(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Loudspeaker",children:(0,e.createComponentVNode)(2,p.Button,{selected:C,icon:C?"toggle-on":"toggle-off",content:C?"On":"Off",onClick:function(){function L(){return v(C?"verboseOff":"verboseOn")}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Health Announcer",children:(0,e.createComponentVNode)(2,p.Button,{selected:f,icon:f?"toggle-on":"toggle-off",content:f?"On":"Off",onClick:function(){function L(){return v(f?"healthOff":"healthOn")}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Health Announcer Threshold",children:(0,e.createComponentVNode)(2,p.Knob,{bipolar:!0,minValue:-100,maxValue:100,value:N,stepPixelSize:5,ml:"0",onChange:function(){function L(w,A){return v("health_adj",{new:A})}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Oxygen Alarm",children:(0,e.createComponentVNode)(2,p.Button,{selected:V,icon:V?"toggle-on":"toggle-off",content:V?"On":"Off",onClick:function(){function L(){return v(V?"oxyOff":"oxyOn")}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Oxygen Alarm Threshold",children:(0,e.createComponentVNode)(2,p.Knob,{bipolar:!0,minValue:-100,maxValue:100,value:B,stepPixelSize:5,ml:"0",onChange:function(){function L(w,A){return v("oxy_adj",{new:A})}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Critical Alert",children:(0,e.createComponentVNode)(2,p.Button,{selected:I,icon:I?"toggle-on":"toggle-off",content:I?"On":"Off",onClick:function(){function L(){return v(I?"critOff":"critOn")}return L}()})})]})}},46892:function(T,r,n){"use strict";r.__esModule=!0,r.Orbit=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=n(35840);function y(d,v){var g=typeof Symbol!="undefined"&&d[Symbol.iterator]||d["@@iterator"];if(g)return(g=g.call(d)).next.bind(g);if(Array.isArray(d)||(g=S(d))||v&&d&&typeof d.length=="number"){g&&(d=g);var C=0;return function(){return C>=d.length?{done:!0}:{done:!1,value:d[C++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function S(d,v){if(d){if(typeof d=="string")return k(d,v);var g={}.toString.call(d).slice(8,-1);return g==="Object"&&d.constructor&&(g=d.constructor.name),g==="Map"||g==="Set"?Array.from(d):g==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(g)?k(d,v):void 0}}function k(d,v){(v==null||v>d.length)&&(v=d.length);for(var g=0,C=Array(v);gg},m=function(v,g){var C=v.name,f=g.name;if(!C||!f)return 0;var N=C.match(h),V=f.match(h);if(N&&V&&C.replace(h,"")===f.replace(h,"")){var B=parseInt(N[1],10),I=parseInt(V[1],10);return B-I}return c(C,f)},l=function(v,g){var C=v.searchText,f=v.source,N=v.title,V=v.color,B=v.sorted,I=f.filter(i(C));return B&&I.sort(m),f.length>0&&(0,e.createComponentVNode)(2,o.Section,{title:N+" - ("+f.length+")",children:I.map(function(L){return(0,e.createComponentVNode)(2,u,{thing:L,color:V},L.name)})})},u=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=v.color,V=v.thing;return(0,e.createComponentVNode)(2,o.Button,{color:N,tooltip:V.assigned_role?(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Box,{as:"img",mr:"0.5em",className:(0,b.classes)(["job_icons16x16",V.assigned_role_sprite])})," ",V.assigned_role]}):"",tooltipPosition:"bottom",onClick:function(){function B(){return f("orbit",{ref:V.ref})}return B}(),children:[V.name,V.orbiters&&(0,e.createComponentVNode)(2,o.Box,{inline:!0,ml:1,children:["(",V.orbiters," ",(0,e.createComponentVNode)(2,o.Icon,{name:"eye"}),")"]})]})},s=r.Orbit=function(){function d(v,g){for(var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.alive,B=N.antagonists,I=N.highlights,L=N.response_teams,w=N.tourist,A=N.auto_observe,x=N.dead,E=N.ssd,P=N.ghosts,D=N.misc,M=N.npcs,O=(0,t.useLocalState)(g,"searchText",""),R=O[0],F=O[1],W={},U=y(B),z;!(z=U()).done;){var $=z.value;W[$.antag]===void 0&&(W[$.antag]=[]),W[$.antag].push($)}var G=Object.entries(W);G.sort(function(J,se){return c(J[0],se[0])});var X=function(){function J(se){for(var ie=0,me=[G.map(function(ae){var le=ae[0],Z=ae[1];return Z}),w,I,V,P,E,x,M,D];ie0&&(0,e.createComponentVNode)(2,o.Section,{title:"Antagonists",children:G.map(function(J){var se=J[0],ie=J[1];return(0,e.createComponentVNode)(2,o.Section,{title:se+" - ("+ie.length+")",level:2,children:ie.filter(i(R)).sort(m).map(function(me){return(0,e.createComponentVNode)(2,u,{color:"bad",thing:me},me.name)})},se)})}),I.length>0&&(0,e.createComponentVNode)(2,l,{title:"Highlights",source:I,searchText:R,color:"teal"}),(0,e.createComponentVNode)(2,l,{title:"Response Teams",source:L,searchText:R,color:"purple"}),(0,e.createComponentVNode)(2,l,{title:"Tourists",source:w,searchText:R,color:"violet"}),(0,e.createComponentVNode)(2,l,{title:"Alive",source:V,searchText:R,color:"good"}),(0,e.createComponentVNode)(2,l,{title:"Ghosts",source:P,searchText:R,color:"grey"}),(0,e.createComponentVNode)(2,l,{title:"SSD",source:E,searchText:R,color:"grey"}),(0,e.createComponentVNode)(2,l,{title:"Dead",source:x,searchText:R,sorted:!1}),(0,e.createComponentVNode)(2,l,{title:"NPCs",source:M,searchText:R,sorted:!1}),(0,e.createComponentVNode)(2,l,{title:"Misc",source:D,searchText:R,sorted:!1})]})})}return d}()},15421:function(T,r,n){"use strict";r.__esModule=!0,r.OreRedemption=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=n(98595),b=n(9394);function y(d){if(d==null)throw new TypeError("Cannot destructure "+d)}var S=(0,b.createLogger)("OreRedemption"),k=function(v){return v.toLocaleString("en-US")+" pts"},h=r.OreRedemption=function(){function d(v,g){return(0,e.createComponentVNode)(2,p.Window,{width:490,height:750,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,i,{height:"100%"})}),(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,m)]})})})}return d}(),i=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.id,B=N.points,I=N.disk,L=Object.assign({},(y(v),v));return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({},L,{children:[(0,e.createComponentVNode)(2,o.Box,{color:"average",textAlign:"center",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-triangle",mr:"0.5rem"}),"This machine only accepts ore. Gibtonite is not accepted."]}),(0,e.createComponentVNode)(2,o.Divider),(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Unclaimed Points",color:B>0?"good":"grey",bold:B>0&&"good",children:k(B)})}),(0,e.createComponentVNode)(2,o.Divider),I?(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Design disk",children:[(0,e.createComponentVNode)(2,o.Button,{selected:!0,bold:!0,icon:"eject",content:I.name,tooltip:"Ejects the design disk.",onClick:function(){function w(){return f("eject_disk")}return w}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:!I.design||!I.compatible,icon:"upload",content:"Download",tooltip:"Downloads the design on the disk into the machine.",onClick:function(){function w(){return f("download")}return w}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Stored design",children:(0,e.createComponentVNode)(2,o.Box,{color:I.design&&(I.compatible?"good":"bad"),children:I.design||"N/A"})})]}):(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No design disk inserted."})]})))},c=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.sheets,B=Object.assign({},(y(v),v));return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,height:"20%",children:(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({fill:!0,scrollable:!0,className:"OreRedemption__Ores",p:"0"},B,{children:[(0,e.createComponentVNode)(2,l,{title:"Sheets",columns:[["Available","25%"],["Ore Value","15%"],["Smelt","20%"]]}),V.map(function(I){return(0,e.createComponentVNode)(2,u,{ore:I},I.id)})]})))})},m=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.alloys,B=Object.assign({},(y(v),v));return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({fill:!0,scrollable:!0,className:"OreRedemption__Ores",p:"0"},B,{children:[(0,e.createComponentVNode)(2,l,{title:"Alloys",columns:[["Recipe","50%"],["Available","11%"],["Smelt","20%"]]}),V.map(function(I){return(0,e.createComponentVNode)(2,s,{ore:I},I.id)})]})))})},l=function(v,g){var C;return(0,e.createComponentVNode)(2,o.Box,{className:"OreHeader",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:v.title}),(C=v.columns)==null?void 0:C.map(function(f){return(0,e.createComponentVNode)(2,o.Stack.Item,{basis:f[1],textAlign:"center",color:"label",bold:!0,children:f[0]},f)})]})})},u=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=v.ore;if(!(N.value&&N.amount<=0&&!(["metal","glass"].indexOf(N.id)>-1)))return(0,e.createComponentVNode)(2,o.Box,{className:"SheetLine",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"45%",align:"middle",children:(0,e.createComponentVNode)(2,o.Stack,{align:"center",children:[(0,e.createComponentVNode)(2,o.Stack.Item,{className:(0,a.classes)(["materials32x32",N.id])}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:N.name})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"20%",textAlign:"center",color:N.amount>=1?"good":"gray",bold:N.amount>=1,align:"center",children:N.amount.toLocaleString("en-US")}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"20%",textAlign:"center",align:"center",children:N.value}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"20%",textAlign:"center",align:"center",lineHeight:"32px",children:(0,e.createComponentVNode)(2,o.NumberInput,{width:"40%",value:0,minValue:0,maxValue:Math.min(N.amount,50),stepPixelSize:6,onChange:function(){function V(B,I){return f(N.value?"sheet":"alloy",{id:N.id,amount:I})}return V}()})})]})})},s=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=v.ore;return(0,e.createComponentVNode)(2,o.Box,{className:"SheetLine",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"7%",align:"middle",children:(0,e.createComponentVNode)(2,o.Box,{className:(0,a.classes)(["alloys32x32",N.id])})}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"30%",textAlign:"middle",align:"center",children:N.name}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"35%",textAlign:"middle",color:N.amount>=1?"good":"gray",align:"center",children:N.description}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"10%",textAlign:"center",color:N.amount>=1?"good":"gray",bold:N.amount>=1,align:"center",children:N.amount.toLocaleString("en-US")}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"20%",textAlign:"center",align:"center",lineHeight:"32px",children:(0,e.createComponentVNode)(2,o.NumberInput,{width:"40%",value:0,minValue:0,maxValue:Math.min(N.amount,50),stepPixelSize:6,onChange:function(){function V(B,I){return f(N.value?"sheet":"alloy",{id:N.id,amount:I})}return V}()})})]})})}},52754:function(T,r,n){"use strict";r.__esModule=!0,r.PAI=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(71253),b=n(70752),y=function(h){var i;try{i=b("./"+h+".js")}catch(m){if(m.code==="MODULE_NOT_FOUND")return(0,p.routingError)("notFound",h);throw m}var c=i[h];return c||(0,p.routingError)("missingExport",h)},S=r.PAI=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.app_template,s=l.app_icon,d=l.app_title,v=y(u);return(0,e.createComponentVNode)(2,o.Window,{width:600,height:650,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{p:1,fill:!0,scrollable:!0,title:(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:s,mr:1}),d,u!=="pai_main_menu"&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{ml:2,mb:0,content:"Back",icon:"arrow-left",onClick:function(){function g(){return m("Back")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Home",icon:"arrow-up",onClick:function(){function g(){return m("MASTER_back")}return g}()})],4)]}),children:(0,e.createComponentVNode)(2,v)})})})})})}return k}()},85175:function(T,r,n){"use strict";r.__esModule=!0,r.PDA=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(71253),b=n(59395),y=function(c){var m;try{m=b("./"+c+".js")}catch(u){if(u.code==="MODULE_NOT_FOUND")return(0,p.routingError)("notFound",c);throw u}var l=m[c];return l||(0,p.routingError)("missingExport",c)},S=r.PDA=function(){function i(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.app,v=s.owner;if(!v)return(0,e.createComponentVNode)(2,o.Window,{width:350,height:105,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Error",children:"No user data found. Please swipe an ID card."})})});var g=y(d.template);return(0,e.createComponentVNode)(2,o.Window,{width:600,height:650,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,k)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,p:1,pb:0,title:(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:d.icon,mr:1}),d.name]}),children:(0,e.createComponentVNode)(2,g)})}),(0,e.createComponentVNode)(2,t.Stack.Item,{mt:7.5,children:(0,e.createComponentVNode)(2,h)})]})})})}return i}(),k=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.idInserted,v=s.idLink,g=s.stationTime,C=s.cartridge_name;return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{ml:.5,children:(0,e.createComponentVNode)(2,t.Button,{icon:"id-card",color:"transparent",onClick:function(){function f(){return u("Authenticate")}return f}(),content:d?v:"No ID Inserted"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"sd-card",color:"transparent",onClick:function(){function f(){return u("Eject")}return f}(),content:C?["Eject "+C]:"No Cartridge Inserted"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"right",bold:!0,mr:1,mt:.5,children:g})]})},h=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.app;return(0,e.createComponentVNode)(2,t.Box,{height:"45px",className:"PDA__footer",backgroundColor:"#1b1b1b",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[!!d.has_back&&(0,e.createComponentVNode)(2,t.Stack.Item,{basis:"33%",mr:-.5,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,className:"PDA__footer__button",color:"transparent",iconColor:d.has_back?"white":"disabled",icon:"arrow-alt-circle-left-o",onClick:function(){function v(){return u("Back")}return v}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{basis:d.has_back?"33%":"100%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,className:"PDA__footer__button",color:"transparent",iconColor:d.is_home?"disabled":"white",icon:"home",onClick:function(){function v(){u("Home")}return v}()})})]})})}},68654:function(T,r,n){"use strict";r.__esModule=!0,r.Pacman=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(49968),b=r.Pacman=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.active,l=c.anchored,u=c.broken,s=c.emagged,d=c.fuel_type,v=c.fuel_usage,g=c.fuel_stored,C=c.fuel_cap,f=c.is_ai,N=c.tmp_current,V=c.tmp_max,B=c.tmp_overheat,I=c.output_max,L=c.power_gen,w=c.output_set,A=c.has_fuel,x=g/C,E=N/V,P=w*L,D=Math.round(g/v*2),M=Math.round(D/60),O=D>120?M+" minutes":D+" seconds";return(0,e.createComponentVNode)(2,o.Window,{width:500,height:225,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(u||!l)&&(0,e.createComponentVNode)(2,t.Section,{title:"Status",children:[!!u&&(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"The generator is malfunctioning!"}),!u&&!l&&(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"The generator needs to be anchored to the floor with a wrench."})]}),!u&&!!l&&(0,e.createVNode)(1,"div",null,[(0,e.createComponentVNode)(2,t.Section,{title:"Status",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:m?"power-off":"times",content:m?"On":"Off",tooltip:"Toggles the generator on/off. Requires fuel.",tooltipPosition:"left",disabled:!A,selected:m,onClick:function(){function R(){return i("toggle_power")}return R}()}),children:(0,e.createComponentVNode)(2,t.Flex,{direction:"row",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{width:"50%",className:"ml-1",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power setting",children:[(0,e.createComponentVNode)(2,t.NumberInput,{value:w,minValue:1,maxValue:I*(s?2.5:1),step:1,className:"mt-1",onDrag:function(){function R(F,W){return i("change_power",{change_power:W})}return R}()}),"(",(0,p.formatPower)(P),")"]})})}),(0,e.createComponentVNode)(2,t.Flex.Item,{width:"50%",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:E,ranges:{green:[-1/0,.33],orange:[.33,.66],red:[.66,1/0]},children:[N," \u2103"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:[B>50&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"CRITICAL OVERHEAT!"}),B>20&&B<=50&&(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"WARNING: Overheating!"}),B>1&&B<=20&&(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"Temperature High"}),B===0&&(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Optimal"})]})]})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Fuel",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:"Eject Fuel",tooltip:"Ejects fuel. Generator needs to be offline.",tooltipPosition:"left",disabled:m||f||!A,onClick:function(){function R(){return i("eject_fuel")}return R}()}),children:(0,e.createComponentVNode)(2,t.Grid,{children:[(0,e.createComponentVNode)(2,t.Grid.Column,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Type",children:d}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fuel level",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:x,ranges:{red:[-1/0,.33],orange:[.33,.66],green:[.66,1/0]},children:[Math.round(g/1e3)," dm\xB3"]})})]})}),(0,e.createComponentVNode)(2,t.Grid.Column,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fuel usage",children:[v/1e3," dm\xB3/s"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fuel depletion",children:[!!A&&(v?O:"N/A"),!A&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Out of fuel"})]})]})})]})})],4)]})})}return y}()},1701:function(T,r,n){"use strict";r.__esModule=!0,r.PanDEMIC=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.PanDEMIC=function(){function l(u,s){var d=(0,a.useBackend)(s),v=d.data,g=v.beakerLoaded,C=v.beakerContainsBlood,f=v.beakerContainsVirus,N=v.resistances,V=N===void 0?[]:N,B;return g?C?C&&!f&&(B=(0,e.createFragment)([(0,e.createTextVNode)("No disease detected in provided blood sample.")],4)):B=(0,e.createFragment)([(0,e.createTextVNode)("No blood sample found in the loaded container.")],4):B=(0,e.createFragment)([(0,e.createTextVNode)("No container loaded.")],4),(0,e.createComponentVNode)(2,o.Window,{width:575,height:510,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[B&&!f?(0,e.createComponentVNode)(2,t.Section,{title:"Container Information",buttons:(0,e.createComponentVNode)(2,b,{fill:!0,vertical:!0}),children:(0,e.createComponentVNode)(2,t.NoticeBox,{children:B})}):(0,e.createComponentVNode)(2,k),(V==null?void 0:V.length)>0&&(0,e.createComponentVNode)(2,m,{align:"bottom"})]})})})}return l}(),b=function(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.beakerLoaded;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:"Eject",disabled:!C,onClick:function(){function f(){return v("eject_beaker")}return f}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"trash-alt",confirmIcon:"eraser",content:"Destroy",confirmContent:"Destroy",disabled:!C,onClick:function(){function f(){return v("destroy_eject_beaker")}return f}()})],4)},y=function(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.beakerContainsVirus,f=u.strain,N=f.commonName,V=f.description,B=f.diseaseAgent,I=f.bloodDNA,L=f.bloodType,w=f.possibleTreatments,A=f.transmissionRoute,x=f.isAdvanced,E=(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood DNA",children:I?(0,e.createVNode)(1,"span",null,I,0,{style:{"font-family":"'Courier New', monospace"}}):"Undetectable"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood Type",children:(0,e.createVNode)(1,"div",null,null,1,{dangerouslySetInnerHTML:{__html:L!=null?L:"Undetectable"}})})],4);if(!C)return(0,e.createComponentVNode)(2,t.LabeledList,{children:E});var P;return x&&(N!=null&&N!=="Unknown"?P=(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:"Print Release Forms",onClick:function(){function D(){return v("print_release_forms",{strain_index:u.strainIndex})}return D}(),style:{"margin-left":"auto"}}):P=(0,e.createComponentVNode)(2,t.Button,{icon:"pen",content:"Name Disease",onClick:function(){function D(){return v("name_strain",{strain_index:u.strainIndex})}return D}(),style:{"margin-left":"auto"}})),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Common Name",className:"common-name-label",children:(0,e.createComponentVNode)(2,t.Stack,{horizontal:!0,align:"center",children:[N!=null?N:"Unknown",P]})}),V&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:V}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Disease Agent",children:B}),E,(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Spread Vector",children:A!=null?A:"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Possible Cures",children:w!=null?w:"None"})]})},S=function(u,s){var d,v=(0,a.useBackend)(s),g=v.act,C=v.data,f=!!C.synthesisCooldown,N=(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:f?"spinner":"clone",iconSpin:f,content:"Clone",disabled:f,onClick:function(){function V(){return g("clone_strain",{strain_index:u.strainIndex})}return V}()}),u.sectionButtons],0);return(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:(d=u.sectionTitle)!=null?d:"Strain Information",buttons:N,children:(0,e.createComponentVNode)(2,y,{strain:u.strain,strainIndex:u.strainIndex})})})},k=function(u,s){var d,v=(0,a.useBackend)(s),g=v.act,C=v.data,f=C.selectedStrainIndex,N=C.strains,V=N[f-1];if(N.length===0)return(0,e.createComponentVNode)(2,t.Section,{title:"Container Information",buttons:(0,e.createComponentVNode)(2,b),children:(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No disease detected in provided blood sample."})});if(N.length===1){var B;return(0,e.createFragment)([(0,e.createComponentVNode)(2,S,{strain:N[0],strainIndex:1,sectionButtons:(0,e.createComponentVNode)(2,b)}),((B=N[0].symptoms)==null?void 0:B.length)>0&&(0,e.createComponentVNode)(2,i,{strain:N[0]})],0)}var I=(0,e.createComponentVNode)(2,b);return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Culture Information",fill:!0,buttons:I,children:(0,e.createComponentVNode)(2,t.Flex,{direction:"column",style:{height:"100%"},children:[(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Tabs,{children:N.map(function(L,w){var A;return(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"virus",selected:f-1===w,onClick:function(){function x(){return g("switch_strain",{strain_index:w+1})}return x}(),children:(A=L.commonName)!=null?A:"Unknown"},w)})})}),(0,e.createComponentVNode)(2,S,{strain:V,strainIndex:f}),((d=V.symptoms)==null?void 0:d.length)>0&&(0,e.createComponentVNode)(2,i,{className:"remove-section-bottom-padding",strain:V})]})})})},h=function(u){return u.reduce(function(s,d){return s+d},0)},i=function(u){var s=u.strain.symptoms;return(0,e.createComponentVNode)(2,t.Flex.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Infection Symptoms",fill:!0,className:u.className,children:(0,e.createComponentVNode)(2,t.Table,{className:"symptoms-table",children:[(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Stealth"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Resistance"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Stage Speed"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Transmissibility"})]}),s.map(function(d,v){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.stealth}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.resistance}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.stageSpeed}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.transmissibility})]},v)}),(0,e.createComponentVNode)(2,t.Table.Row,{className:"table-spacer"}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{style:{"font-weight":"bold"},children:"Total"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h(s.map(function(d){return d.stealth}))}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h(s.map(function(d){return d.resistance}))}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h(s.map(function(d){return d.stageSpeed}))}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h(s.map(function(d){return d.transmissibility}))})]})]})})})},c=["flask","vial","eye-dropper"],m=function(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.synthesisCooldown,f=g.beakerContainsVirus,N=g.resistances;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Antibodies",fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{horizontal:!0,wrap:!0,children:N.map(function(V,B){return(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:c[B%c.length],disabled:!!C,onClick:function(){function I(){return v("clone_vaccine",{resistance_index:B+1})}return I}(),mr:"0.5em"}),V]},B)})})})})}},67921:function(T,r,n){"use strict";r.__esModule=!0,r.ParticleAccelerator=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(25328),p=n(79646),b=n(36352),y=n(98595),S=n(35840),k=n(38307),h=function(u){switch(u){case 1:return"north";case 2:return"south";case 4:return"east";case 8:return"west";case 5:return"northeast";case 6:return"southeast";case 9:return"northwest";case 10:return"southwest"}return""},i=r.ParticleAccelerator=function(){function l(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.assembled,f=g.power,N=g.strength,V=g.max_strength,B=g.icon,I=g.layout_1,L=g.layout_2,w=g.layout_3,A=g.orientation;return(0,e.createComponentVNode)(2,y.Window,{width:395,height:C?160:A==="north"||A==="south"?540:465,children:(0,e.createComponentVNode)(2,y.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Control Panel",buttons:(0,e.createComponentVNode)(2,t.Button,{dmIcon:"sync",content:"Connect",onClick:function(){function x(){return v("scan")}return x}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",mb:"5px",children:(0,e.createComponentVNode)(2,t.Box,{color:C?"good":"bad",children:C?"Operational":"Error: Verify Configuration"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:f?"power-off":"times",content:f?"On":"Off",selected:f,disabled:!C,onClick:function(){function x(){return v("power")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Strength",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"backward",disabled:!C||N===0,onClick:function(){function x(){return v("remove_strength")}return x}(),mr:"4px"}),N,(0,e.createComponentVNode)(2,t.Button,{icon:"forward",disabled:!C||N===V,onClick:function(){function x(){return v("add_strength")}return x}(),ml:"4px"})]})]})}),C?"":(0,e.createComponentVNode)(2,t.Section,{title:A?"EM Acceleration Chamber Orientation: "+(0,o.capitalize)(A):"Place EM Acceleration Chamber Next To Console",children:A===0?"":A==="north"||A==="south"?(0,e.createComponentVNode)(2,m):(0,e.createComponentVNode)(2,c)})]})})}return l}(),c=function(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.assembled,f=g.power,N=g.strength,V=g.max_strength,B=g.icon,I=g.layout_1,L=g.layout_2,w=g.layout_3,A=g.orientation;return(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,b.TableRow,{width:"40px",children:(A==="east"?I:w).slice().map(function(x){return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})}),(0,e.createComponentVNode)(2,b.TableRow,{width:"40px",children:L.slice().map(function(x){return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})}),(0,e.createComponentVNode)(2,b.TableRow,{width:"40px",children:(A==="east"?w:I).slice().map(function(x){return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})})]})},m=function(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.assembled,f=g.power,N=g.strength,V=g.max_strength,B=g.icon,I=g.layout_1,L=g.layout_2,w=g.layout_3,A=g.orientation;return(0,e.createComponentVNode)(2,t.Grid,{children:[(0,e.createComponentVNode)(2,p.GridColumn,{width:"40px",children:(A==="north"?I:w).slice().map(function(x){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})}),(0,e.createComponentVNode)(2,p.GridColumn,{children:L.slice().map(function(x){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})}),(0,e.createComponentVNode)(2,p.GridColumn,{width:"40px",children:(A==="north"?w:I).slice().map(function(x){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,tooltip:x.status,children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})})]})}},71432:function(T,r,n){"use strict";r.__esModule=!0,r.PdaPainter=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.PdaPainter=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.has_pda;return(0,e.createComponentVNode)(2,o.Window,{width:510,height:505,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:l?(0,e.createComponentVNode)(2,y):(0,e.createComponentVNode)(2,b)})})}return k}(),b=function(h,i){var c=(0,a.useBackend)(i),m=c.act;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"silver",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"download",size:5,mb:"10px"}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{width:"160px",textAlign:"center",content:"Insert PDA",onClick:function(){function l(){return m("insert_pda")}return l}()})]})})})},y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.pda_colors;return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,horizontal:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,S)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,t.Table,{className:"PdaPainter__list",children:Object.keys(u).map(function(s){return(0,e.createComponentVNode)(2,t.Table.Row,{onClick:function(){function d(){return m("choose_pda",{selectedPda:s})}return d}(),children:[(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,children:(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/png;base64,"+u[s][0],style:{"vertical-align":"middle",width:"32px",margin:"0px","margin-left":"0px","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:s})]},s)})})})})]})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.current_appearance,s=l.preview_appearance;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Current PDA",children:[(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+u,style:{"vertical-align":"middle",width:"160px",margin:"0px","margin-left":"0px","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"eject",content:"Eject",color:"green",onClick:function(){function d(){return m("eject_pda")}return d}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"paint-roller",content:"Paint PDA",onClick:function(){function d(){return m("paint_pda")}return d}()})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Preview",children:(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+s,style:{"vertical-align":"middle",width:"160px",margin:"0px","margin-left":"0px","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}})})]})}},33388:function(T,r,n){"use strict";r.__esModule=!0,r.PersonalCrafting=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.PersonalCrafting=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.busy,u=m.category,s=m.display_craftable_only,d=m.display_compact,v=m.prev_cat,g=m.next_cat,C=m.subcategory,f=m.prev_subcat,N=m.next_subcat;return(0,e.createComponentVNode)(2,o.Window,{width:700,height:800,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[!!l&&(0,e.createComponentVNode)(2,t.Dimmer,{fontSize:"32px",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"cog",spin:1})," Crafting..."]}),(0,e.createComponentVNode)(2,t.Section,{title:u,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"Show Craftable Only",icon:s?"check-square-o":"square-o",selected:s,onClick:function(){function V(){return c("toggle_recipes")}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Compact Mode",icon:d?"check-square-o":"square-o",selected:d,onClick:function(){function V(){return c("toggle_compact")}return V}()})],4),children:[(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{content:v,icon:"arrow-left",onClick:function(){function V(){return c("backwardCat")}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:g,icon:"arrow-right",onClick:function(){function V(){return c("forwardCat")}return V}()})]}),C&&(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{content:f,icon:"arrow-left",onClick:function(){function V(){return c("backwardSubCat")}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:N,icon:"arrow-right",onClick:function(){function V(){return c("forwardSubCat")}return V}()})]}),d?(0,e.createComponentVNode)(2,b):(0,e.createComponentVNode)(2,y)]})]})})}return S}(),b=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.display_craftable_only,u=m.can_craft,s=m.cant_craft;return(0,e.createComponentVNode)(2,t.Box,{mt:1,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[u.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.name,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"hammer",content:"Craft",onClick:function(){function v(){return c("make",{make:d.ref})}return v}()}),d.catalyst_text&&(0,e.createComponentVNode)(2,t.Button,{tooltip:d.catalyst_text,content:"Catalysts",color:"transparent"}),(0,e.createComponentVNode)(2,t.Button,{tooltip:d.req_text,content:"Requirements",color:"transparent"}),d.tool_text&&(0,e.createComponentVNode)(2,t.Button,{tooltip:d.tool_text,content:"Tools",color:"transparent"})]},d.name)}),!l&&s.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.name,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"hammer",content:"Craft",disabled:!0}),d.catalyst_text&&(0,e.createComponentVNode)(2,t.Button,{tooltip:d.catalyst_text,content:"Catalysts",color:"transparent"}),(0,e.createComponentVNode)(2,t.Button,{tooltip:d.req_text,content:"Requirements",color:"transparent"}),d.tool_text&&(0,e.createComponentVNode)(2,t.Button,{tooltip:d.tool_text,content:"Tools",color:"transparent"})]},d.name)})]})})},y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.display_craftable_only,u=m.can_craft,s=m.cant_craft;return(0,e.createComponentVNode)(2,t.Box,{mt:1,children:[u.map(function(d){return(0,e.createComponentVNode)(2,t.Section,{title:d.name,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"hammer",content:"Craft",onClick:function(){function v(){return c("make",{make:d.ref})}return v}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[d.catalyst_text&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Catalysts",children:d.catalyst_text}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Requirements",children:d.req_text}),d.tool_text&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tools",children:d.tool_text})]})},d.name)}),!l&&s.map(function(d){return(0,e.createComponentVNode)(2,t.Section,{title:d.name,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"hammer",content:"Craft",disabled:!0}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[d.catalyst_text&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Catalysts",children:d.catalyst_text}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Requirements",children:d.req_text}),d.tool_text&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tools",children:d.tool_text})]})},d.name)})]})}},56150:function(T,r,n){"use strict";r.__esModule=!0,r.Photocopier=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Photocopier=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:440,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Photocopier",color:"silver",children:[(0,e.createComponentVNode)(2,t.Stack,{mb:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:12,children:"Copies:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"2em",bold:!0,children:m.copynumber}),(0,e.createComponentVNode)(2,t.Stack.Item,{float:"right",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"minus",textAlign:"center",content:"",onClick:function(){function l(){return c("minus")}return l}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"plus",textAlign:"center",content:"",onClick:function(){function l(){return c("add")}return l}()})]})]}),(0,e.createComponentVNode)(2,t.Stack,{mb:2,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:12,children:"Toner:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,children:m.toner})]}),(0,e.createComponentVNode)(2,t.Stack,{mb:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:12,children:"Inserted Document:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",disabled:!m.copyitem&&!m.mob,content:m.copyitem?m.copyitem:m.mob?m.mob+"'s ass!":"document",onClick:function(){function l(){return c("removedocument")}return l}()})})]}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:12,children:"Inserted Folder:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",disabled:!m.folder,content:m.folder?m.folder:"folder",onClick:function(){function l(){return c("removefolder")}return l}()})})]})]}),(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,b)}),(0,e.createComponentVNode)(2,y)]})})})}return S}(),b=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.issilicon;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"copy",float:"center",textAlign:"center",content:"Copy",onClick:function(){function u(){return c("copy")}return u}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"file-import",float:"center",textAlign:"center",content:"Scan",onClick:function(){function u(){return c("scandocument")}return u}()}),!!l&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"file",color:"green",float:"center",textAlign:"center",content:"Print Text",onClick:function(){function u(){return c("ai_text")}return u}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"image",color:"green",float:"center",textAlign:"center",content:"Print Image",onClick:function(){function u(){return c("ai_pic")}return u}()})],4)],0)},y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Scanned Files",children:m.files.map(function(l){return(0,e.createComponentVNode)(2,t.Section,{title:l.name,buttons:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:"Print",disabled:m.toner<=0,onClick:function(){function u(){return c("filecopy",{uid:l.uid})}return u}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"trash-alt",content:"Delete",color:"bad",onClick:function(){function u(){return c("deletefile",{uid:l.uid})}return u}()})]})},l.name)})})}},84676:function(T,r,n){"use strict";r.__esModule=!0,r.PoolController=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=["tempKey"];function b(h,i){if(h==null)return{};var c={};for(var m in h)if({}.hasOwnProperty.call(h,m)){if(i.includes(m))continue;c[m]=h[m]}return c}var y={scalding:{label:"Scalding",color:"#FF0000",icon:"fa fa-arrow-circle-up",requireEmag:!0},warm:{label:"Warm",color:"#990000",icon:"fa fa-arrow-circle-up"},normal:{label:"Normal",color:null,icon:"fa fa-arrow-circle-right"},cool:{label:"Cool",color:"#009999",icon:"fa fa-arrow-circle-down"},frigid:{label:"Frigid",color:"#00CCCC",icon:"fa fa-arrow-circle-down",requireEmag:!0}},S=function(i,c){var m=i.tempKey,l=b(i,p),u=y[m];if(!u)return null;var s=(0,a.useBackend)(c),d=s.data,v=s.act,g=d.currentTemp,C=u.label,f=u.icon,N=m===g,V=function(){v("setTemp",{temp:m})};return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Button,Object.assign({color:"transparent",selected:N,onClick:V},l,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:f}),C]})))},k=r.PoolController=function(){function h(i,c){for(var m=(0,a.useBackend)(c),l=m.data,u=l.emagged,s=l.currentTemp,d=y[s]||y.normal,v=d.label,g=d.color,C=[],f=0,N=Object.entries(y);f50?"battery-half":"battery-quarter")||g==="C"&&"bolt"||g==="F"&&"battery-full"||g==="M"&&"slash",color:g==="N"&&(C>50?"yellow":"red")||g==="C"&&"yellow"||g==="F"&&"green"||g==="M"&&"orange"}),(0,e.createComponentVNode)(2,S.Box,{inline:!0,width:"36px",textAlign:"right",children:(0,o.toFixed)(C)+"%"})],4)};u.defaultHooks=p.pureComponentHooks;var s=function(v){var g,C,f=v.status;switch(f){case"AOn":g=!0,C=!0;break;case"AOff":g=!0,C=!1;break;case"On":g=!1,C=!0;break;case"Off":g=!1,C=!1;break}var N=(C?"On":"Off")+(" ["+(g?"auto":"manual")+"]");return(0,e.createComponentVNode)(2,S.ColorBox,{color:C?"good":"bad",content:g?void 0:"M",title:N})};s.defaultHooks=p.pureComponentHooks},50992:function(T,r,n){"use strict";r.__esModule=!0,r.PrisonerImplantManager=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(29319),p=n(3939),b=n(321),y=n(5485),S=n(98595),k=r.PrisonerImplantManager=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.loginState,d=u.prisonerInfo,v=u.chemicalInfo,g=u.trackingInfo,C;if(!s.logged_in)return(0,e.createComponentVNode)(2,S.Window,{theme:"security",width:500,height:850,children:(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,y.LoginScreen)})});var f=[1,5,10];return(0,e.createComponentVNode)(2,S.Window,{theme:"security",width:500,height:850,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.LoginInfo),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Prisoner Points Manager System",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Prisoner",children:(0,e.createComponentVNode)(2,t.Button,{icon:d.name?"eject":"id-card",selected:d.name,content:d.name?d.name:"-----",tooltip:d.name?"Eject ID":"Insert ID",onClick:function(){function N(){return l("id_card")}return N}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Points",children:[d.points!==null?d.points:"-/-",(0,e.createComponentVNode)(2,t.Button,{ml:2,icon:"minus-square",disabled:d.points===null,content:"Reset",onClick:function(){function N(){return l("reset_points")}return N}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Point Goal",children:[d.goal!==null?d.goal:"-/-",(0,e.createComponentVNode)(2,t.Button,{ml:2,icon:"pen",disabled:d.goal===null,content:"Edit",onClick:function(){function N(){return(0,p.modalOpen)(c,"set_points")}return N}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{children:(0,e.createVNode)(1,"box",null,[(0,e.createTextVNode)("1 minute of prison time should roughly equate to 150 points."),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Sentences should not exceed 5000 points."),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Permanent prisoners should not be given a point goal."),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Prisoners who meet their point goal will be able to automatically access their locker and return to the station using the shuttle.")],4,{hidden:d.goal===null})})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Tracking Implants",children:g.map(function(N){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{p:1,backgroundColor:"rgba(255, 255, 255, 0.05)",children:[(0,e.createComponentVNode)(2,t.Box,{bold:!0,children:["Subject: ",N.subject]}),(0,e.createComponentVNode)(2,t.Box,{children:[" ",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Location",children:N.location}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Health",children:N.health}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Prisoner",children:(0,e.createComponentVNode)(2,t.Button,{icon:"exclamation-triangle",content:"Warn",tooltip:"Broadcast a message to this poor sod",onClick:function(){function V(){return(0,p.modalOpen)(c,"warn",{uid:N.uid})}return V}()})})]})]},N.subject)]}),(0,e.createVNode)(1,"br")],4)})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Chemical Implants",children:v.map(function(N){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{p:1,backgroundColor:"rgba(255, 255, 255, 0.05)",children:[(0,e.createComponentVNode)(2,t.Box,{bold:!0,children:["Subject: ",N.name]}),(0,e.createComponentVNode)(2,t.Box,{children:[" ",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Remaining Reagents",children:N.volume})}),f.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{mt:2,disabled:N.volumec;return(0,e.createComponentVNode)(2,t.ImageButton,{fluid:!0,title:N.name,dmIcon:N.icon,dmIconState:N.icon_state,buttonsAlt:(0,e.createComponentVNode)(2,t.Button,{bold:!0,translucent:!0,fontSize:1.5,tooltip:V&&"Not enough tickets",disabled:V,onClick:function(){function B(){return h("purchase",{purchase:N.itemID})}return B}(),children:[N.cost,(0,e.createComponentVNode)(2,t.Icon,{m:0,mt:.25,name:"ticket",color:V?"bad":"good",size:1.6})]}),children:N.desc},N.name)})})})})})})}return b}()},94813:function(T,r,n){"use strict";r.__esModule=!0,r.RCD=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=n(49148),y=r.RCD=function(){function l(u,s){return(0,e.createComponentVNode)(2,o.Window,{width:480,height:670,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c)]})})]})}return l}(),S=function(u,s){var d=(0,a.useBackend)(s),v=d.data,g=v.matter,C=v.max_matter,f=C*.7,N=C*.25;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Matter Storage",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ranges:{good:[f,1/0],average:[N,f],bad:[-1/0,N]},value:g,maxValue:C,children:(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"center",children:g+" / "+C+" units"})})})})},k=function(){return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Construction Type",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,h,{mode_type:"Floors and Walls"}),(0,e.createComponentVNode)(2,h,{mode_type:"Airlocks"}),(0,e.createComponentVNode)(2,h,{mode_type:"Windows"}),(0,e.createComponentVNode)(2,h,{mode_type:"Deconstruction"})]})})})},h=function(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=u.mode_type,f=g.mode;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,color:"transparent",content:C,selected:f===C?1:0,onClick:function(){function N(){return v("mode",{mode:C})}return N}()})})},i=function(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.door_name,f=g.electrochromic,N=g.airlock_glass;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Airlock Settings",children:(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,color:"transparent",icon:"pen-alt",content:(0,e.createFragment)([(0,e.createTextVNode)("Rename: "),(0,e.createVNode)(1,"b",null,C,0)],0),onClick:function(){function V(){return(0,p.modalOpen)(s,"renameAirlock")}return V}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:N===1&&(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:f?"toggle-on":"toggle-off",content:"Electrochromic",selected:f,onClick:function(){function V(){return v("electrochromic")}return V}()})})]})})})},c=function(u,s){var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.tab,f=g.locked,N=g.one_access,V=g.selected_accesses,B=g.regions;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Tabs,{fluid:!0,children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"cog",selected:C===1,onClick:function(){function I(){return v("set_tab",{tab:1})}return I}(),children:"Airlock Types"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:C===2,icon:"list",onClick:function(){function I(){return v("set_tab",{tab:2})}return I}(),children:"Airlock Access"})]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:C===1?(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Types",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,m,{check_number:0})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,m,{check_number:1})})]})}):C===2&&f?(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Access",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"lock-open",content:"Unlock",onClick:function(){function I(){return v("set_lock",{new_lock:"unlock"})}return I}()}),children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"lock",size:"5",mb:3}),(0,e.createVNode)(1,"br"),"Airlock access selection is currently locked."]})})}):(0,e.createComponentVNode)(2,b.AccessList,{sectionButtons:(0,e.createComponentVNode)(2,t.Button,{icon:"lock",content:"Lock",onClick:function(){function I(){return v("set_lock",{new_lock:"lock"})}return I}()}),usedByRcd:1,rcdButtons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:N,content:"One",onClick:function(){function I(){return v("set_one_access",{access:"one"})}return I}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!N,width:4,content:"All",onClick:function(){function I(){return v("set_one_access",{access:"all"})}return I}()})],4),accesses:B,selectedList:V,accessMod:function(){function I(L){return v("set",{access:L})}return I}(),grantAll:function(){function I(){return v("grant_all")}return I}(),denyAll:function(){function I(){return v("clear_all")}return I}(),grantDep:function(){function I(L){return v("grant_region",{region:L})}return I}(),denyDep:function(){function I(L){return v("deny_region",{region:L})}return I}()})})],4)},m=function(u,s){for(var d=(0,a.useBackend)(s),v=d.act,g=d.data,C=g.door_types_ui_list,f=g.door_type,N=u.check_number,V=[],B=0;Bp?w=(0,e.createComponentVNode)(2,t.Box,{color:"red",bold:!0,mb:1,children:"There are new messages"}):w=(0,e.createComponentVNode)(2,t.Box,{color:"label",mb:1,children:"There are no new messages"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Main Menu",buttons:(0,e.createComponentVNode)(2,t.Button,{width:9,content:L?"Speaker Off":"Speaker On",selected:!L,icon:L?"volume-mute":"volume-up",onClick:function(){function A(){return N("toggleSilent")}return A}()}),children:[w,(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"View Messages",icon:B>p?"envelope-open-text":"envelope",onClick:function(){function A(){return N("setScreen",{setScreen:6})}return A}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{mt:1,children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Request Assistance",icon:"hand-paper",onClick:function(){function A(){return N("setScreen",{setScreen:1})}return A}()}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Request Supplies",icon:"box",onClick:function(){function A(){return N("setScreen",{setScreen:2})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Request Secondary Goal",icon:"clipboard-list",onClick:function(){function A(){return N("setScreen",{setScreen:11})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Relay Anonymous Information",icon:"comment",onClick:function(){function A(){return N("setScreen",{setScreen:3})}return A}()})]})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{mt:1,children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Print Shipping Label",icon:"tag",onClick:function(){function A(){return N("setScreen",{setScreen:9})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"View Shipping Logs",icon:"clipboard-list",onClick:function(){function A(){return N("setScreen",{setScreen:10})}return A}()})]})}),!!I&&(0,e.createComponentVNode)(2,t.Stack.Item,{mt:1,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Send Station-Wide Announcement",icon:"bullhorn",onClick:function(){function A(){return N("setScreen",{setScreen:8})}return A}()})})]})})},i=function(g,C){var f=(0,a.useBackend)(C),N=f.act,V=f.data,B=V.department,I=[],L;switch(g.purpose){case"ASSISTANCE":I=V.assist_dept,L="Request assistance from another department";break;case"SUPPLIES":I=V.supply_dept,L="Request supplies from another department";break;case"INFO":I=V.info_dept,L="Relay information to another department";break}return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:L,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function w(){return N("setScreen",{setScreen:0})}return w}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:I.filter(function(w){return w!==B}).map(function(w){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:w,textAlign:"right",className:"candystripe",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Message",icon:"envelope",onClick:function(){function A(){return N("writeInput",{write:w,priority:y})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{content:"High Priority",icon:"exclamation-circle",onClick:function(){function A(){return N("writeInput",{write:w,priority:S})}return A}()})]},w)})})})})},c=function(g,C){var f=(0,a.useBackend)(C),N=f.act,V=f.data,B;switch(g.type){case"SUCCESS":B="Message sent successfully";break;case"FAIL":B="Unable to contact messaging server";break}return(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:B,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function I(){return N("setScreen",{setScreen:0})}return I}()})})},m=function(g,C){var f=(0,a.useBackend)(C),N=f.act,V=f.data,B,I;switch(g.type){case"MESSAGES":B=V.message_log,I="Message Log";break;case"SHIPPING":B=V.shipping_log,I="Shipping label print log";break}return B.reverse(),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:I,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function L(){return N("setScreen",{setScreen:0})}return L}()}),children:B.map(function(L){return(0,e.createComponentVNode)(2,t.Box,{textAlign:"left",children:[L.map(function(w,A){return(0,e.createVNode)(1,"div",null,w,0,null,A)}),(0,e.createVNode)(1,"hr")]},L)})})})},l=function(g,C){var f=(0,a.useBackend)(C),N=f.act,V=f.data,B=V.recipient,I=V.message,L=V.msgVerified,w=V.msgStamped;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Message Authentication",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function A(){return N("setScreen",{setScreen:0})}return A}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Recipient",children:B}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Message",children:I}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Validated by",color:"green",children:L}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Stamped by",color:"blue",children:w})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",content:"Send Message",icon:"envelope",onClick:function(){function A(){return N("department",{department:B})}return A}()})})})],4)},u=function(g,C){var f=(0,a.useBackend)(C),N=f.act,V=f.data,B=V.message,I=V.announceAuth;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Station-Wide Announcement",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function L(){return N("setScreen",{setScreen:0})}return L}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Edit Message",icon:"edit",onClick:function(){function L(){return N("writeAnnouncement")}return L}()})],4),children:B})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{children:[I?(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"green",children:"ID verified. Authentication accepted."}):(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"label",children:"Swipe your ID card to authenticate yourself"}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,mt:2,textAlign:"center",content:"Send Announcement",icon:"bullhorn",disabled:!(I&&B),onClick:function(){function L(){return N("sendAnnouncement")}return L}()})]})})],4)},s=function(g,C){var f=(0,a.useBackend)(C),N=f.act,V=f.data,B=V.shipDest,I=V.msgVerified,L=V.ship_dept;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Section,{title:"Print Shipping Label",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function w(){return N("setScreen",{setScreen:0})}return w}()}),children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Destination",children:B}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Validated by",children:I})]}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,mt:1,textAlign:"center",content:"Print Label",icon:"print",disabled:!(B&&I),onClick:function(){function w(){return N("printLabel")}return w}()})]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Destinations",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:L.map(function(w){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:w,textAlign:"right",className:"candystripe",children:(0,e.createComponentVNode)(2,t.Button,{content:B===w?"Selected":"Select",selected:B===w,onClick:function(){function A(){return N("shipSelect",{shipSelect:w})}return A}()})},w)})})})})],4)},d=function(g,C){var f=(0,a.useBackend)(C),N=f.act,V=f.data,B=V.secondaryGoalAuth,I=V.secondaryGoalEnabled;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Request Secondary Goal",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function L(){return N("setScreen",{setScreen:0})}return L}()})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{children:[I?B?(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"green",children:"ID verified. Authentication accepted."}):(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"label",children:"Swipe your ID card to authenticate yourself"}):(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"label",children:"Complete your current goal first!"}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,mt:2,textAlign:"center",content:"Request Secondary Goal",icon:"clipboard-list",disabled:!(B&&I),onClick:function(){function L(){return N("requestSecondaryGoal")}return L}()})]})})],4)}},9861:function(T,r,n){"use strict";r.__esModule=!0,r.RndBackupConsole=r.LinkMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.RndBackupConsole=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.network_name,l=c.has_disk,u=c.disk_name,s=c.linked,d=c.techs,v=c.last_timestamp;return(0,e.createComponentVNode)(2,o.Window,{width:900,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Device Info",children:[(0,e.createComponentVNode)(2,t.Box,{mb:2,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Network",children:s?(0,e.createComponentVNode)(2,t.Button,{content:m,icon:"unlink",selected:1,onClick:function(){function g(){return i("unlink")}return g}()}):"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Loaded Disk",children:l?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:u+" (Last backup: "+v+")",icon:"save",selected:1,onClick:function(){function g(){return i("eject_disk")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"Save all",onClick:function(){function g(){return i("saveall2disk")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-out-alt",content:"Load all",onClick:function(){function g(){return i("saveall2network")}return g}()})],4):"None"})]})}),!!s||(0,e.createComponentVNode)(2,b)]}),(0,e.createComponentVNode)(2,t.Box,{mt:2,children:(0,e.createComponentVNode)(2,t.Section,{title:"Tech Info",children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Tech Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network Level"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Disk Level"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Actions"})]}),Object.keys(d).map(function(g){return!(d[g].network_level>0||d[g].disk_level>0)||(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:d[g].name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d[g].network_level||"None"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d[g].disk_level||"None"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"Load to network",disabled:!l||!s,onClick:function(){function C(){return i("savetech2network",{tech:g})}return C}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-out-alt",content:"Load to disk",disabled:!l||!s,onClick:function(){function C(){return i("savetech2disk",{tech:g})}return C}()})]})]},g)})]})})})]})})}return y}(),b=r.LinkMenu=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.controllers;return(0,e.createComponentVNode)(2,t.Section,{title:"Setup Linkage",children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Link"})]}),m.map(function(l){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:l.addr}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:l.net_id}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Link",icon:"link",onClick:function(){function u(){return i("linktonetworkcontroller",{target_controller:l.addr})}return u}()})})]},l.addr)})]})})}return y}()},37556:function(T,r,n){"use strict";r.__esModule=!0,r.DataDiskMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o="design",p="tech",b=function(c,m){var l=(0,a.useBackend)(m),u=l.data,s=l.act,d=u.disk_data;return d?(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:d.name}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Level",children:d.level}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:d.desc})]}),(0,e.createComponentVNode)(2,t.Box,{mt:"10px",children:(0,e.createComponentVNode)(2,t.Button,{content:"Upload to Database",icon:"arrow-up",onClick:function(){function v(){return s("updt_tech")}return v}()})})]}):null},y=function(c,m){var l=(0,a.useBackend)(m),u=l.data,s=l.act,d=u.disk_data;if(!d)return null;var v=d.name,g=d.lathe_types,C=d.materials,f=g.join(", ");return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:v}),f?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Lathe Types",children:f}):null,(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Required Materials"})]}),C.map(function(N){return(0,e.createComponentVNode)(2,t.Box,{children:["- ",(0,e.createVNode)(1,"span",null,N.name,0,{style:{"text-transform":"capitalize"}})," x ",N.amount]},N.name)}),(0,e.createComponentVNode)(2,t.Box,{mt:"10px",children:(0,e.createComponentVNode)(2,t.Button,{content:"Upload to Database",icon:"arrow-up",onClick:function(){function N(){return s("updt_design")}return N}()})})]})},S=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.disk_data;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Section,Object.assign({buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Erase",icon:"eraser",disabled:!d,onClick:function(){function v(){return u("erase_disk")}return v}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Eject",icon:"eject",onClick:function(){function v(){u("eject_disk")}return v}()})],4)},c)))},k=function(c,m){var l=(0,a.useBackend)(m),u=l.data,s=l.act,d=u.disk_type,v=u.to_copy,g=c.title;return(0,e.createComponentVNode)(2,S,{title:g,children:(0,e.createComponentVNode)(2,t.Box,{overflowY:"auto",overflowX:"hidden",maxHeight:"450px",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:v.sort(function(C,f){return C.name.localeCompare(f.name)}).map(function(C){var f=C.name,N=C.id;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{noColon:!0,label:f,children:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-down",content:"Copy to Disk",onClick:function(){function V(){d===p?s("copy_tech",{id:N}):s("copy_design",{id:N})}return V}()})},N)})})})})},h=r.DataDiskMenu=function(){function i(c,m){var l=(0,a.useBackend)(m),u=l.data,s=u.disk_type,d=u.disk_data;if(!s)return(0,e.createComponentVNode)(2,t.Section,{title:"Data Disk",children:"No disk loaded."});switch(s){case o:return d?(0,e.createComponentVNode)(2,S,{title:"Design Disk",children:(0,e.createComponentVNode)(2,y)}):(0,e.createComponentVNode)(2,k,{title:"Design Disk"});case p:return d?(0,e.createComponentVNode)(2,S,{title:"Technology Disk",children:(0,e.createComponentVNode)(2,b)}):(0,e.createComponentVNode)(2,k,{title:"Technology Disk"});default:return(0,e.createFragment)([(0,e.createTextVNode)("UNRECOGNIZED DISK TYPE")],4)}}return i}()},58147:function(T,r,n){"use strict";r.__esModule=!0,r.DeconstructionMenu=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=r.DeconstructionMenu=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.data,c=h.act,m=i.tech_levels,l=i.loaded_item,u=i.linked_destroy;return u?l?(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Section,{title:"Object Analysis",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{content:"Deconstruct",icon:"microscope",onClick:function(){function s(){c("deconstruct")}return s}()}),(0,e.createComponentVNode)(2,o.Button,{content:"Eject",icon:"eject",onClick:function(){function s(){c("eject_item")}return s}()})],4),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Name",children:l.name})})}),(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.Table,{id:"research-levels",children:[(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Research Field"}),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Current Level"}),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Object Level"}),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"New Level"})]}),m.map(function(s){return(0,e.createComponentVNode)(2,b,{techLevel:s},s.id)})]})})],4):(0,e.createComponentVNode)(2,o.Section,{title:"Deconstruction Menu",children:"No item loaded. Standing by..."}):(0,e.createComponentVNode)(2,o.Section,{title:"Deconstruction Menu",children:"NO DESTRUCTIVE ANALYZER LINKED TO CONSOLE"})}return y}(),b=function(S,k){var h=S.techLevel,i=h.name,c=h.desc,m=h.level,l=h.object_level,u=h.ui_icon,s=l!=null,d=s&&l>=m?Math.max(l,m+1):m;return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{icon:"circle-info",tooltip:c})}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:u})," ",i]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:m}),s?(0,e.createComponentVNode)(2,o.Table.Cell,{children:l}):(0,e.createComponentVNode)(2,o.Table.Cell,{className:"research-level-no-effect",children:"-"}),(0,e.createComponentVNode)(2,o.Table.Cell,{className:(0,a.classes)([d!==m&&"upgraded-level"]),children:d})]})}},16830:function(T,r,n){"use strict";r.__esModule=!0,r.LatheCategory=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(52662),p=r.LatheCategory=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.data,i=k.act,c=h.category,m=h.matching_designs,l=h.menu,u=l===4,s=u?"build":"imprint";return(0,e.createComponentVNode)(2,t.Section,{title:c,children:[(0,e.createComponentVNode)(2,o.LatheMaterials),(0,e.createComponentVNode)(2,t.Table,{className:"RndConsole__LatheCategory__MatchingDesigns",children:m.map(function(d){var v=d.id,g=d.name,C=d.can_build,f=d.materials;return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:g,disabled:C<1,onClick:function(){function N(){return i(s,{id:v,amount:1})}return N}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:C>=5?(0,e.createComponentVNode)(2,t.Button,{content:"x5",onClick:function(){function N(){return i(s,{id:v,amount:5})}return N}()}):null}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:C>=10?(0,e.createComponentVNode)(2,t.Button,{content:"x10",onClick:function(){function N(){return i(s,{id:v,amount:10})}return N}()}):null}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.map(function(N){return(0,e.createFragment)([" | ",(0,e.createVNode)(1,"span",N.is_red?"color-red":null,[N.amount,(0,e.createTextVNode)(" "),N.name],0)],0)})})]},v)})})]})}return b}()},70497:function(T,r,n){"use strict";r.__esModule=!0,r.LatheChemicalStorage=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LatheChemicalStorage=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data,h=S.act,i=k.loaded_chemicals,c=k.menu===4;return(0,e.createComponentVNode)(2,t.Section,{title:"Chemical Storage",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Purge All",icon:"trash",onClick:function(){function m(){var l=c?"disposeallP":"disposeallI";h(l)}return m}()}),(0,e.createComponentVNode)(2,t.LabeledList,{children:i.map(function(m){var l=m.volume,u=m.name,s=m.id;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"* "+l+" of "+u,children:(0,e.createComponentVNode)(2,t.Button,{content:"Purge",icon:"trash",onClick:function(){function d(){var v=c?"disposeP":"disposeI";h(v,{id:s})}return d}()})},s)})})]})}return p}()},70864:function(T,r,n){"use strict";r.__esModule=!0,r.LatheMainMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(52662),p=n(68198),b=r.LatheMainMenu=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.data,c=h.act,m=i.menu,l=i.categories,u=m===4?"Protolathe":"Circuit Imprinter";return(0,e.createComponentVNode)(2,t.Section,{title:u+" Menu",children:[(0,e.createComponentVNode)(2,o.LatheMaterials),(0,e.createComponentVNode)(2,p.LatheSearch),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.Flex,{wrap:"wrap",children:l.map(function(s){return(0,e.createComponentVNode)(2,t.Flex,{style:{"flex-basis":"50%","margin-bottom":"6px"},children:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-right",content:s,onClick:function(){function d(){c("setCategory",{category:s})}return d}()})},s)})})]})}return y}()},42878:function(T,r,n){"use strict";r.__esModule=!0,r.LatheMaterialStorage=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LatheMaterialStorage=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data,h=S.act,i=k.loaded_materials;return(0,e.createComponentVNode)(2,t.Section,{className:"RndConsole__LatheMaterialStorage",title:"Material Storage",children:(0,e.createComponentVNode)(2,t.Table,{children:i.map(function(c){var m=c.id,l=c.amount,u=c.name,s=function(){function C(f){var N=k.menu===4?"lathe_ejectsheet":"imprinter_ejectsheet";h(N,{id:m,amount:f})}return C}(),d=Math.floor(l/2e3),v=l<1,g=d===1?"":"s";return(0,e.createComponentVNode)(2,t.Table.Row,{className:v?"color-grey":"color-yellow",children:[(0,e.createComponentVNode)(2,t.Table.Cell,{minWidth:"210px",children:["* ",l," of ",u]}),(0,e.createComponentVNode)(2,t.Table.Cell,{minWidth:"110px",children:["(",d," sheet",g,")"]}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:l>=2e3?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"1x",icon:"eject",onClick:function(){function C(){return s(1)}return C}()}),(0,e.createComponentVNode)(2,t.Button,{content:"C",icon:"eject",onClick:function(){function C(){return s("custom")}return C}()}),l>=2e3*5?(0,e.createComponentVNode)(2,t.Button,{content:"5x",icon:"eject",onClick:function(){function C(){return s(5)}return C}()}):null,(0,e.createComponentVNode)(2,t.Button,{content:"All",icon:"eject",onClick:function(){function C(){return s(50)}return C}()})],0):null})]},m)})})})}return p}()},52662:function(T,r,n){"use strict";r.__esModule=!0,r.LatheMaterials=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LatheMaterials=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data,h=k.total_materials,i=k.max_materials,c=k.max_chemicals,m=k.total_chemicals;return(0,e.createComponentVNode)(2,t.Box,{className:"RndConsole__LatheMaterials",mb:"10px",children:(0,e.createComponentVNode)(2,t.Table,{width:"auto",children:[(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Material Amount:"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h}),i?(0,e.createComponentVNode)(2,t.Table.Cell,{children:" / "+i}):null]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Chemical Amount:"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:m}),c?(0,e.createComponentVNode)(2,t.Table.Cell,{children:" / "+c}):null]})]})})}return p}()},9681:function(T,r,n){"use strict";r.__esModule=!0,r.LatheMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(12644),p=n(70864),b=n(16830),y=n(42878),S=n(70497),k=["menu"];function h(u,s){if(u==null)return{};var d={};for(var v in u)if({}.hasOwnProperty.call(u,v)){if(s.includes(v))continue;d[v]=u[v]}return d}var i=t.Tabs.Tab,c=function(s,d){var v=(0,a.useBackend)(d),g=v.act,C=v.data,f=C.menu===o.MENU.LATHE?["nav_protolathe",C.submenu_protolathe]:["nav_imprinter",C.submenu_imprinter],N=f[0],V=f[1],B=s.menu,I=h(s,k);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,i,Object.assign({selected:V===B,onClick:function(){function L(){return g(N,{menu:B})}return L}()},I)))},m=function(s){switch(s){case o.PRINTER_MENU.MAIN:return(0,e.createComponentVNode)(2,p.LatheMainMenu);case o.PRINTER_MENU.SEARCH:return(0,e.createComponentVNode)(2,b.LatheCategory);case o.PRINTER_MENU.MATERIALS:return(0,e.createComponentVNode)(2,y.LatheMaterialStorage);case o.PRINTER_MENU.CHEMICALS:return(0,e.createComponentVNode)(2,S.LatheChemicalStorage)}},l=r.LatheMenu=function(){function u(s,d){var v=(0,a.useBackend)(d),g=v.data,C=g.menu,f=g.linked_lathe,N=g.linked_imprinter;return C===o.MENU.LATHE&&!f?(0,e.createComponentVNode)(2,t.Box,{children:"NO PROTOLATHE LINKED TO CONSOLE"}):C===o.MENU.IMPRINTER&&!N?(0,e.createComponentVNode)(2,t.Box,{children:"NO CIRCUIT IMPRITER LINKED TO CONSOLE"}):(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,c,{menu:o.PRINTER_MENU.MAIN,icon:"bars",children:"Main Menu"}),(0,e.createComponentVNode)(2,c,{menu:o.PRINTER_MENU.MATERIALS,icon:"layer-group",children:"Materials"}),(0,e.createComponentVNode)(2,c,{menu:o.PRINTER_MENU.CHEMICALS,icon:"flask-vial",children:"Chemicals"})]}),m(g.menu===o.MENU.LATHE?g.submenu_protolathe:g.submenu_imprinter)]})}return u}()},68198:function(T,r,n){"use strict";r.__esModule=!0,r.LatheSearch=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LatheSearch=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act;return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Input,{placeholder:"Search...",onEnter:function(){function h(i,c){return k("search",{to_search:c})}return h}()})})}return p}()},81421:function(T,r,n){"use strict";r.__esModule=!0,r.LinkMenu=void 0;var e=n(89005),a=n(72253),t=n(98595),o=n(36036),p=r.LinkMenu=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.controllers;return(0,e.createComponentVNode)(2,t.Window,{width:800,height:550,children:(0,e.createComponentVNode)(2,t.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{title:"Setup Linkage",children:(0,e.createComponentVNode)(2,o.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Link"})]}),c.map(function(m){return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:m.addr}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:m.net_id}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{content:"Link",icon:"link",onClick:function(){function l(){return h("linktonetworkcontroller",{target_controller:m.addr})}return l}()})})]},m.addr)})]})})})})}return b}()},6256:function(T,r,n){"use strict";r.__esModule=!0,r.SettingsMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.SettingsMenu=function(){function y(S,k){return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,p),(0,e.createComponentVNode)(2,b)]})}return y}(),p=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.sync,l=c.admin;return(0,e.createComponentVNode)(2,t.Section,{title:"Settings",children:(0,e.createComponentVNode)(2,t.Flex,{direction:"column",align:"flex-start",children:(0,e.createComponentVNode)(2,t.Button,{color:"red",icon:"unlink",content:"Disconnect from Research Network",onClick:function(){function u(){i("unlink")}return u}()})})})},b=function(S,k){var h=(0,a.useBackend)(k),i=h.data,c=h.act,m=i.linked_destroy,l=i.linked_lathe,u=i.linked_imprinter;return(0,e.createComponentVNode)(2,t.Section,{title:"Linked Devices",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"link",content:"Re-sync with Nearby Devices",onClick:function(){function s(){return c("find_device")}return s}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Destructive Analyzer",children:(0,e.createComponentVNode)(2,t.Button,{icon:"unlink",disabled:!m,content:m?"Unlink":"Undetected",onClick:function(){function s(){return c("disconnect",{item:"destroy"})}return s}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Protolathe",children:(0,e.createComponentVNode)(2,t.Button,{icon:"unlink",disabled:!l,content:l?"Unlink":"Undetected",onClick:function(){function s(){c("disconnect",{item:"lathe"})}return s}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Circuit Imprinter",children:(0,e.createComponentVNode)(2,t.Button,{icon:"unlink",disabled:!u,content:u?"Unlink":"Undetected",onClick:function(){function s(){return c("disconnect",{item:"imprinter"})}return s}()})})]})})}},12644:function(T,r,n){"use strict";r.__esModule=!0,r.RndConsole=r.PRINTER_MENU=r.MENU=void 0;var e=n(89005),a=n(72253),t=n(98595),o=n(36036),p=n(35840),b=n(37556),y=n(9681),S=n(81421),k=n(6256),h=n(58147),i=["menu"];function c(f,N){if(f==null)return{};var V={};for(var B in f)if({}.hasOwnProperty.call(f,B)){if(N.includes(B))continue;V[B]=f[B]}return V}var m=o.Tabs.Tab,l=r.MENU={MAIN:0,DISK:2,DESTROY:3,LATHE:4,IMPRINTER:5,SETTINGS:6},u=r.PRINTER_MENU={MAIN:0,SEARCH:1,MATERIALS:2,CHEMICALS:3},s=function(N){switch(N){case l.MAIN:return(0,e.createComponentVNode)(2,C);case l.DISK:return(0,e.createComponentVNode)(2,b.DataDiskMenu);case l.DESTROY:return(0,e.createComponentVNode)(2,h.DeconstructionMenu);case l.LATHE:case l.IMPRINTER:return(0,e.createComponentVNode)(2,y.LatheMenu);case l.SETTINGS:return(0,e.createComponentVNode)(2,k.SettingsMenu);default:return"UNKNOWN MENU"}},d=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.menu,A=N.menu,x=c(N,i);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,m,Object.assign({selected:w===A,onClick:function(){function E(){return I("nav",{menu:A})}return E}()},x)))},v=r.RndConsole=function(){function f(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data;if(!L.linked)return(0,e.createComponentVNode)(2,S.LinkMenu);var w=L.menu,A=L.linked_destroy,x=L.linked_lathe,E=L.linked_imprinter,P=L.wait_message;return(0,e.createComponentVNode)(2,t.Window,{width:800,height:550,children:(0,e.createComponentVNode)(2,t.Window.Content,{children:(0,e.createComponentVNode)(2,o.Box,{className:"RndConsole",children:[(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,d,{icon:"flask",menu:l.MAIN,children:"Research"}),!!A&&(0,e.createComponentVNode)(2,d,{icon:"microscope",menu:l.DESTROY,children:"Analyze"}),!!x&&(0,e.createComponentVNode)(2,d,{icon:"print",menu:l.LATHE,children:"Protolathe"}),!!E&&(0,e.createComponentVNode)(2,d,{icon:"memory",menu:l.IMPRINTER,children:"Imprinter"}),(0,e.createComponentVNode)(2,d,{icon:"floppy-disk",menu:l.DISK,children:"Disk"}),(0,e.createComponentVNode)(2,d,{icon:"cog",menu:l.SETTINGS,children:"Settings"})]}),s(w),(0,e.createComponentVNode)(2,g)]})})})}return f}(),g=function(N,V){var B=(0,a.useBackend)(V),I=B.data,L=I.wait_message;return L?(0,e.createComponentVNode)(2,o.Box,{className:"RndConsole__Overlay",children:(0,e.createComponentVNode)(2,o.Box,{className:"RndConsole__Overlay__Wrapper",children:(0,e.createComponentVNode)(2,o.NoticeBox,{color:"black",children:L})})}):null},C=function(N,V){var B=(0,a.useBackend)(V),I=B.data,L=I.tech_levels;return(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.Table,{id:"research-levels",children:[(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Research Field"}),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Level"})]}),L.map(function(w){var A=w.id,x=w.name,E=w.desc,P=w.level,D=w.ui_icon;return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{icon:"circle-info",tooltip:E})}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:D})," ",x]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:P})]},A)})]})})}},29205:function(T,r,n){"use strict";r.__esModule=!0,r.RndNetController=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=r.RndNetController=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=l.ion,s=(0,t.useLocalState)(i,"mainTabIndex",0),d=s[0],v=s[1],g=function(){function C(f){switch(f){case 0:return(0,e.createComponentVNode)(2,y);case 1:return(0,e.createComponentVNode)(2,S);default:return"SOMETHING WENT VERY WRONG PLEASE AHELP"}}return C}();return(0,e.createComponentVNode)(2,p.Window,{width:900,height:600,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"wrench",selected:d===0,onClick:function(){function C(){return v(0)}return C}(),children:"Network Management"},"ConfigPage"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"floppy-disk",selected:d===1,onClick:function(){function C(){return v(1)}return C}(),children:"Design Management"},"DesignPage")]}),g(d)]})})}return k}(),y=function(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=(0,t.useLocalState)(i,"filterType","ALL"),s=u[0],d=u[1],v=l.network_password,g=l.network_name,C=l.devices,f=[];f.push(s),s==="MSC"&&(f.push("BCK"),f.push("PGN"));var N=s==="ALL"?C:C.filter(function(V){return f.indexOf(V.dclass)>-1});return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Section,{title:"Network Configuration",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Network Name",children:(0,e.createComponentVNode)(2,o.Button,{content:g||"Unset",selected:g,icon:"edit",onClick:function(){function V(){return m("network_name")}return V}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Network Password",children:(0,e.createComponentVNode)(2,o.Button,{content:v||"Unset",selected:v,icon:"lock",onClick:function(){function V(){return m("network_password")}return V}()})})]})}),(0,e.createComponentVNode)(2,o.Section,{title:"Connected Devices",children:[(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="ALL",onClick:function(){function V(){return d("ALL")}return V}(),icon:"network-wired",children:"All Devices"},"AllDevices"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="SRV",onClick:function(){function V(){return d("SRV")}return V}(),icon:"server",children:"R&D Servers"},"RNDServers"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="RDC",onClick:function(){function V(){return d("RDC")}return V}(),icon:"desktop",children:"R&D Consoles"},"RDConsoles"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="MFB",onClick:function(){function V(){return d("MFB")}return V}(),icon:"industry",children:"Exosuit Fabricators"},"Mechfabs"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="MSC",onClick:function(){function V(){return d("MSC")}return V}(),icon:"microchip",children:"Miscellaneous Devices"},"Misc")]}),(0,e.createComponentVNode)(2,o.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Device Name"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Device ID"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Unlink"})]}),N.map(function(V){return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:V.name}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:V.id}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{content:"Unlink",icon:"unlink",color:"red",onClick:function(){function B(){return m("unlink_device",{dclass:V.dclass,uid:V.id})}return B}()})})]},V.id)})]})]})],4)},S=function(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=l.designs,s=(0,t.useLocalState)(i,"searchText",""),d=s[0],v=s[1];return(0,e.createComponentVNode)(2,o.Section,{title:"Design Management",children:[(0,e.createComponentVNode)(2,o.Input,{fluid:!0,placeholder:"Search for designs",mb:2,onInput:function(){function g(C,f){return v(f)}return g}()}),u.filter((0,a.createSearch)(d,function(g){return g.name})).map(function(g){return(0,e.createComponentVNode)(2,o.Button.Checkbox,{fluid:!0,content:g.name,checked:!g.blacklisted,onClick:function(){function C(){return m(g.blacklisted?"unblacklist_design":"blacklist_design",{d_uid:g.uid})}return C}()},g.name)})]})}},63315:function(T,r,n){"use strict";r.__esModule=!0,r.RndServer=void 0;var e=n(89005),a=n(72253),t=n(44879),o=n(36036),p=n(98595),b=r.RndServer=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.active,s=l.network_name;return(0,e.createComponentVNode)(2,p.Window,{width:600,height:500,resizable:!0,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,o.Section,{title:"Server Configuration",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Machine power",children:(0,e.createComponentVNode)(2,o.Button,{content:u?"On":"Off",selected:u,icon:"power-off",onClick:function(){function d(){return m("toggle_active")}return d}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Link status",children:s===null?(0,e.createComponentVNode)(2,o.Box,{color:"red",children:"Unlinked"}):(0,e.createComponentVNode)(2,o.Box,{color:"green",children:"Linked"})})]})}),s===null?(0,e.createComponentVNode)(2,S):(0,e.createComponentVNode)(2,y)]})})}return k}(),y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.network_name;return(0,e.createComponentVNode)(2,o.Section,{title:"Network Info",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Connected network ID",children:u}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Unlink",children:(0,e.createComponentVNode)(2,o.Button,{content:"Unlink",icon:"unlink",color:"red",onClick:function(){function s(){return m("unlink")}return s}()})})]})})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.controllers;return(0,e.createComponentVNode)(2,o.Section,{title:"Detected Cores",children:(0,e.createComponentVNode)(2,o.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Link"})]}),u.map(function(s){return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:s.netname}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{content:"Link",icon:"link",onClick:function(){function d(){return m("link",{addr:s.addr})}return d}()})})]},s.addr)})]})})}},26109:function(T,r,n){"use strict";r.__esModule=!0,r.RobotSelfDiagnosis=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(25328),b=function(k,h){var i=k/h;return i<=.2?"good":i<=.5?"average":"bad"},y=r.RobotSelfDiagnosis=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.data,m=c.component_data;return(0,e.createComponentVNode)(2,o.Window,{width:280,height:480,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:m.map(function(l,u){return(0,e.createComponentVNode)(2,t.Section,{title:(0,p.capitalize)(l.name),children:l.installed<=0?(0,e.createComponentVNode)(2,t.NoticeBox,{m:-.5,height:3.5,color:"red",style:{"font-style":"normal"},children:(0,e.createComponentVNode)(2,t.Flex,{height:"100%",children:(0,e.createComponentVNode)(2,t.Flex.Item,{grow:1,textAlign:"center",align:"center",color:"#e8e8e8",children:l.installed===-1?"Destroyed":"Missing"})})}):(0,e.createComponentVNode)(2,t.Flex,{children:[(0,e.createComponentVNode)(2,t.Flex.Item,{width:"72%",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Brute Damage",color:b(l.brute_damage,l.max_damage),children:l.brute_damage}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Burn Damage",color:b(l.electronic_damage,l.max_damage),children:l.electronic_damage})]})}),(0,e.createComponentVNode)(2,t.Flex.Item,{width:"50%",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Powered",color:l.powered?"good":"bad",children:l.powered?"Yes":"No"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Enabled",color:l.status?"good":"bad",children:l.status?"Yes":"No"})]})})]})},u)})})})}return S}()},97997:function(T,r,n){"use strict";r.__esModule=!0,r.RoboticsControlConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.RoboticsControlConsole=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.can_hack,l=c.safety,u=c.show_lock_all,s=c.cyborgs,d=s===void 0?[]:s;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:460,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[!!u&&(0,e.createComponentVNode)(2,t.Section,{title:"Emergency Lock Down",children:[(0,e.createComponentVNode)(2,t.Button,{icon:l?"lock":"unlock",content:l?"Disable Safety":"Enable Safety",selected:l,onClick:function(){function v(){return i("arm",{})}return v}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"lock",disabled:l,content:"Lock ALL Cyborgs",color:"bad",onClick:function(){function v(){return i("masslock",{})}return v}()})]}),(0,e.createComponentVNode)(2,b,{cyborgs:d,can_hack:m})]})})}return y}(),b=function(S,k){var h=S.cyborgs,i=S.can_hack,c=(0,a.useBackend)(k),m=c.act,l=c.data,u="Detonate";return l.detonate_cooldown>0&&(u+=" ("+l.detonate_cooldown+"s)"),h.length?h.map(function(s){return(0,e.createComponentVNode)(2,t.Section,{title:s.name,buttons:(0,e.createFragment)([!!s.hackable&&!s.emagged&&(0,e.createComponentVNode)(2,t.Button,{icon:"terminal",content:"Hack",color:"bad",onClick:function(){function d(){return m("hackbot",{uid:s.uid})}return d}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:s.locked_down?"unlock":"lock",color:s.locked_down?"good":"default",content:s.locked_down?"Release":"Lockdown",disabled:!l.auth,onClick:function(){function d(){return m("stopbot",{uid:s.uid})}return d}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"bomb",content:u,disabled:!l.auth||l.detonate_cooldown>0,color:"bad",onClick:function(){function d(){return m("killbot",{uid:s.uid})}return d}()})],0),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:(0,e.createComponentVNode)(2,t.Box,{color:s.status?"bad":s.locked_down?"average":"good",children:s.status?"Not Responding":s.locked_down?"Locked Down":"Nominal"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Location",children:(0,e.createComponentVNode)(2,t.Box,{children:s.locstring})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Integrity",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:s.health>50?"good":"bad",value:s.health/100})}),typeof s.charge=="number"&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cell Charge",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:s.charge>30?"good":"bad",value:s.charge/100})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cell Capacity",children:(0,e.createComponentVNode)(2,t.Box,{color:s.cell_capacity<3e4?"average":"good",children:s.cell_capacity})})],4)||(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cell",children:(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"No Power Cell"})}),!!s.is_hacked&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Safeties",children:(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"DISABLED"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Module",children:s.module}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Master AI",children:(0,e.createComponentVNode)(2,t.Box,{color:s.synchronization?"default":"average",children:s.synchronization||"None"})})]})},s.uid)}):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No cyborg units detected within access parameters."})}},54431:function(T,r,n){"use strict";r.__esModule=!0,r.Safe=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Safe=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.dial,s=l.open,d=l.locked,v=l.contents;return(0,e.createComponentVNode)(2,o.Window,{theme:"safe",width:600,height:800,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Box,{className:"Safe--engraving",children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Box,{className:"Safe--engraving--hinge",top:"25%"}),(0,e.createComponentVNode)(2,t.Box,{className:"Safe--engraving--hinge",top:"75%"})]}),(0,e.createComponentVNode)(2,t.Icon,{className:"Safe--engraving--arrow",name:"long-arrow-alt-down",size:"3"}),(0,e.createVNode)(1,"br"),s?(0,e.createComponentVNode)(2,y):(0,e.createComponentVNode)(2,t.Box,{as:"img",className:"Safe--dial",src:"safe_dial.png",style:{transform:"rotate(-"+3.6*u+"deg)","z-index":0}})]}),!s&&(0,e.createComponentVNode)(2,S)]})})}return k}(),b=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.dial,s=l.open,d=l.locked,v=function(C,f){return(0,e.createComponentVNode)(2,t.Button,{disabled:s||f&&!d,icon:"arrow-"+(f?"right":"left"),content:(f?"Right":"Left")+" "+C,iconRight:f,onClick:function(){function N(){return m(f?"turnleft":"turnright",{num:C})}return N}(),style:{"z-index":10}})};return(0,e.createComponentVNode)(2,t.Box,{className:"Safe--dialer",children:[(0,e.createComponentVNode)(2,t.Button,{disabled:d,icon:s?"lock":"lock-open",content:s?"Close":"Open",mb:"0.5rem",onClick:function(){function g(){return m("open")}return g}()}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Box,{position:"absolute",children:[v(50),v(10),v(1)]}),(0,e.createComponentVNode)(2,t.Box,{className:"Safe--dialer--right",position:"absolute",right:"5px",children:[v(1,!0),v(10,!0),v(50,!0)]}),(0,e.createComponentVNode)(2,t.Box,{className:"Safe--dialer--number",children:u})]})},y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.contents;return(0,e.createComponentVNode)(2,t.Box,{className:"Safe--contents",overflow:"auto",children:u.map(function(s,d){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{mb:"0.5rem",onClick:function(){function v(){return m("retrieve",{index:d+1})}return v}(),children:[(0,e.createComponentVNode)(2,t.Box,{as:"img",src:s.sprite+".png",verticalAlign:"middle",ml:"-6px",mr:"0.5rem"}),s.name]}),(0,e.createVNode)(1,"br")],4,s)})})},S=function(h,i){return(0,e.createComponentVNode)(2,t.Section,{className:"Safe--help",title:"Safe opening instructions (because you all keep forgetting)",children:[(0,e.createComponentVNode)(2,t.Box,{children:["1. Turn the dial left to the first number.",(0,e.createVNode)(1,"br"),"2. Turn the dial right to the second number.",(0,e.createVNode)(1,"br"),"3. Continue repeating this process for each number, switching between left and right each time.",(0,e.createVNode)(1,"br"),"4. Open the safe."]}),(0,e.createComponentVNode)(2,t.Box,{bold:!0,children:"To lock fully, turn the dial to the left after closing the safe."})]})}},29740:function(T,r,n){"use strict";r.__esModule=!0,r.SatelliteControl=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SatelliteControl=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.satellites,m=i.notice,l=i.meteor_shield,u=i.meteor_shield_coverage,s=i.meteor_shield_coverage_max,d=i.meteor_shield_coverage_percentage;return(0,e.createComponentVNode)(2,o.Window,{width:475,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[l&&(0,e.createComponentVNode)(2,t.Section,{title:"Station Shield Coverage",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:d>=100?"good":"average",value:u,maxValue:s,children:[d," %"]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Satellite Network Control",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[m&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Alert",color:"red",children:i.notice}),c.map(function(v){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"#"+v.id,children:[v.mode," ",(0,e.createComponentVNode)(2,t.Button,{content:v.active?"Deactivate":"Activate",icon:"arrow-circle-right",onClick:function(){function g(){return h("toggle",{id:v.id})}return g}()})]},v.id)})]})})]})})}return b}()},44162:function(T,r,n){"use strict";r.__esModule=!0,r.SecureStorage=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=n(98595),b=n(36352),y=n(92986),S=r.SecureStorage=function(){function c(m,l){return(0,e.createComponentVNode)(2,p.Window,{theme:"securestorage",height:500,width:280,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,h)})})})})}return c}(),k=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=window.event?m.which:m.keyCode;if(d===y.KEY_ENTER){m.preventDefault(),s("keypad",{digit:"E"});return}if(d===y.KEY_ESCAPE){m.preventDefault(),s("keypad",{digit:"C"});return}if(d===y.KEY_BACKSPACE){m.preventDefault(),s("backspace");return}if(d>=y.KEY_0&&d<=y.KEY_9){m.preventDefault(),s("keypad",{digit:d-y.KEY_0});return}if(d>=y.KEY_NUMPAD_0&&d<=y.KEY_NUMPAD_9){m.preventDefault(),s("keypad",{digit:d-y.KEY_NUMPAD_0});return}},h=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=d.locked,g=d.no_passcode,C=d.emagged,f=d.user_entered_code,N=[["1","2","3"],["4","5","6"],["7","8","9"],["C","0","E"]],V=g?"":v?"bad":"good";return(0,e.createComponentVNode)(2,o.Section,{fill:!0,onKeyDown:function(){function B(I){return k(I,l)}return B}(),children:[(0,e.createComponentVNode)(2,o.Stack.Item,{height:7.3,children:(0,e.createComponentVNode)(2,o.Box,{className:(0,a.classes)(["SecureStorage__displayBox","SecureStorage__displayBox--"+V]),height:"100%",children:C?"ERROR":f})}),(0,e.createComponentVNode)(2,o.Table,{children:N.map(function(B){return(0,e.createComponentVNode)(2,b.TableRow,{children:B.map(function(I){return(0,e.createComponentVNode)(2,b.TableCell,{children:(0,e.createComponentVNode)(2,i,{number:I})},I)})},B[0])})})]})},i=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,v=m.number;return(0,e.createComponentVNode)(2,o.Button,{fluid:!0,bold:!0,mb:"6px",content:v,textAlign:"center",fontSize:"60px",lineHeight:1.25,width:"80px",className:(0,a.classes)(["SecureStorage__Button","SecureStorage__Button--keypad","SecureStorage__Button--"+v]),onClick:function(){function g(){return s("keypad",{digit:v})}return g}()})}},6272:function(T,r,n){"use strict";r.__esModule=!0,r.SecurityRecords=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=n(3939),y=n(321),S=n(5485),k=n(22091),h={"*Execute*":"execute","*Arrest*":"arrest",Incarcerated:"incarcerated",Parolled:"parolled",Released:"released",Demote:"demote",Search:"search",Monitor:"monitor"},i=function(f,N){(0,b.modalOpen)(f,"edit",{field:N.edit,value:N.value})},c=r.SecurityRecords=function(){function C(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.loginState,w=I.currentPage,A;if(L.logged_in)w===1?A=(0,e.createComponentVNode)(2,l):w===2&&(A=(0,e.createComponentVNode)(2,d));else return(0,e.createComponentVNode)(2,p.Window,{theme:"security",width:800,height:900,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,S.LoginScreen)})});return(0,e.createComponentVNode)(2,p.Window,{theme:"security",width:800,height:900,children:[(0,e.createComponentVNode)(2,b.ComplexModal),(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y.LoginInfo),(0,e.createComponentVNode)(2,k.TemporaryNotice),(0,e.createComponentVNode)(2,m),A]})})]})}return C}(),m=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.currentPage,w=I.general;return(0,e.createComponentVNode)(2,o.Stack.Item,{m:0,children:(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"list",selected:L===1,onClick:function(){function A(){return B("page",{page:1})}return A}(),children:"List Records"}),L===2&&w&&!w.empty&&(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"file",selected:L===2,children:["Record: ",w.fields[0].value]})]})})},l=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.records,w=(0,t.useLocalState)(N,"searchText",""),A=w[0],x=w[1],E=(0,t.useLocalState)(N,"sortId","name"),P=E[0],D=E[1],M=(0,t.useLocalState)(N,"sortOrder",!0),O=M[0],R=M[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,s)}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,mt:.5,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"SecurityRecords__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,u,{id:"name",children:"Name"}),(0,e.createComponentVNode)(2,u,{id:"id",children:"ID"}),(0,e.createComponentVNode)(2,u,{id:"rank",children:"Assignment"}),(0,e.createComponentVNode)(2,u,{id:"fingerprint",children:"Fingerprint"}),(0,e.createComponentVNode)(2,u,{id:"status",children:"Criminal Status"})]}),L.filter((0,a.createSearch)(A,function(F){return F.name+"|"+F.id+"|"+F.rank+"|"+F.fingerprint+"|"+F.status})).sort(function(F,W){var U=O?1:-1;return F[P].localeCompare(W[P])*U}).map(function(F){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"SecurityRecords__listRow--"+h[F.status],onClick:function(){function W(){return B("view",{uid_gen:F.uid_gen,uid_sec:F.uid_sec})}return W}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user"})," ",F.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:F.id}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:F.rank}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:F.fingerprint}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:F.status})]},F.id)})]})})})],4)},u=function(f,N){var V=(0,t.useLocalState)(N,"sortId","name"),B=V[0],I=V[1],L=(0,t.useLocalState)(N,"sortOrder",!0),w=L[0],A=L[1],x=f.id,E=f.children;return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{color:B!==x&&"transparent",fluid:!0,onClick:function(){function P(){B===x?A(!w):(I(x),A(!0))}return P}(),children:[E,B===x&&(0,e.createComponentVNode)(2,o.Icon,{name:w?"sort-up":"sort-down",ml:"0.25rem;"})]})})})},s=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.isPrinting,w=(0,t.useLocalState)(N,"searchText",""),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{ml:"0.25rem",content:"New Record",icon:"plus",onClick:function(){function E(){return B("new_general")}return E}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{disabled:L,icon:L?"spinner":"print",iconSpin:!!L,content:"Print Cell Log",onClick:function(){function E(){return(0,b.modalOpen)(N,"print_cell_log")}return E}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"Search by Name, ID, Assignment, Fingerprint, Status",fluid:!0,onInput:function(){function E(P,D){return x(D)}return E}()})})]})},d=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.isPrinting,w=I.general,A=I.security;return!w||!w.fields?(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:"General records lost!"}):(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"General Data",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{disabled:L,icon:L?"spinner":"print",iconSpin:!!L,content:"Print Record",onClick:function(){function x(){return B("print_record")}return x}()}),(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",tooltip:"WARNING: This will also delete the Security and Medical records associated with this crew member!",tooltipPosition:"bottom-start",content:"Delete Record",onClick:function(){function x(){return B("delete_general")}return x}()})],4),children:(0,e.createComponentVNode)(2,v)})}),!A||!A.fields?(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Security Data",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"pen",content:"Create New Record",onClick:function(){function x(){return B("new_security")}return x}()}),children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{bold:!0,grow:!0,textAlign:"center",fontSize:1.75,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon.Stack,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"scroll",size:5,color:"gray"}),(0,e.createComponentVNode)(2,o.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"Security records lost!"]})})})}):(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Security Data",buttons:(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",disabled:A.empty,content:"Delete Record",onClick:function(){function x(){return B("delete_security")}return x}()}),children:(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:A.fields.map(function(x,E){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:x.field,preserveWhitespace:!0,children:[(0,a.decodeHtmlEntities)(x.value),!!x.edit&&(0,e.createComponentVNode)(2,o.Button,{icon:"pen",ml:"0.5rem",mb:x.line_break?"1rem":"initial",onClick:function(){function P(){return i(N,x)}return P}()})]},E)})})})})}),(0,e.createComponentVNode)(2,g)],4)],0)},v=function(f,N){var V=(0,t.useBackend)(N),B=V.data,I=B.general;return!I||!I.fields?(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:"General records lost!"})})}):(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:I.fields.map(function(L,w){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:L.field,preserveWhitespace:!0,children:[(0,a.decodeHtmlEntities)(""+L.value),!!L.edit&&(0,e.createComponentVNode)(2,o.Button,{icon:"pen",ml:"0.5rem",mb:L.line_break?"1rem":"initial",onClick:function(){function A(){return i(N,L)}return A}()})]},w)})})}),!!I.has_photos&&I.photos.map(function(L,w){return(0,e.createComponentVNode)(2,o.Stack.Item,{inline:!0,textAlign:"center",color:"label",ml:0,children:[(0,e.createVNode)(1,"img",null,null,1,{src:L,style:{width:"96px","margin-top":"5rem","margin-bottom":"0.5rem","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}}),(0,e.createVNode)(1,"br"),"Photo #",w+1]},w)})]})},g=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.security;return(0,e.createComponentVNode)(2,o.Stack.Item,{height:"150px",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Comments/Log",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"comment",content:"Add Entry",onClick:function(){function w(){return(0,b.modalOpen)(N,"comment_add")}return w}()}),children:L.comments.length===0?(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No comments found."}):L.comments.map(function(w,A){return(0,e.createComponentVNode)(2,o.Box,{preserveWhitespace:!0,children:[(0,e.createComponentVNode)(2,o.Box,{color:"label",inline:!0,children:w.header||"Auto-generated"}),(0,e.createVNode)(1,"br"),w.text||w,(0,e.createComponentVNode)(2,o.Button,{icon:"comment-slash",color:"bad",ml:"0.5rem",onClick:function(){function x(){return B("comment_delete",{id:A+1})}return x}()})]},A)})})})}},5099:function(T,r,n){"use strict";r.__esModule=!0,r.SeedExtractor=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=n(3939);function y(u,s){var d=typeof Symbol!="undefined"&&u[Symbol.iterator]||u["@@iterator"];if(d)return(d=d.call(u)).next.bind(d);if(Array.isArray(u)||(d=S(u))||s&&u&&typeof u.length=="number"){d&&(u=d);var v=0;return function(){return v>=u.length?{done:!0}:{done:!1,value:u[v++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function S(u,s){if(u){if(typeof u=="string")return k(u,s);var d={}.toString.call(u).slice(8,-1);return d==="Object"&&u.constructor&&(d=u.constructor.name),d==="Map"||d==="Set"?Array.from(u):d==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(d)?k(u,s):void 0}}function k(u,s){(s==null||s>u.length)&&(s=u.length);for(var d=0,v=Array(s);d=A},g=function(w,A){return w<=A},C=s.split(" "),f=[],N=function(){var w=I.value,A=w.split(":");if(A.length===0)return 0;if(A.length===1)return f.push(function(P){return(P.name+" ("+P.variant+")").toLocaleLowerCase().includes(A[0].toLocaleLowerCase())}),0;if(A.length>2)return{v:function(){function P(D){return!1}return P}()};var x,E=d;if(A[1][A[1].length-1]==="-"?(E=g,x=Number(A[1].substring(0,A[1].length-1))):A[1][A[1].length-1]==="+"?(E=v,x=Number(A[1].substring(0,A[1].length-1))):x=Number(A[1]),isNaN(x))return{v:function(){function P(D){return!1}return P}()};switch(A[0].toLocaleLowerCase()){case"l":case"life":case"lifespan":f.push(function(P){return E(P.lifespan,x)});break;case"e":case"end":case"endurance":f.push(function(P){return E(P.endurance,x)});break;case"m":case"mat":case"maturation":f.push(function(P){return E(P.maturation,x)});break;case"pr":case"prod":case"production":f.push(function(P){return E(P.production,x)});break;case"y":case"yield":f.push(function(P){return E(P.yield,x)});break;case"po":case"pot":case"potency":f.push(function(P){return E(P.potency,x)});break;case"s":case"stock":case"c":case"count":case"a":case"amount":f.push(function(P){return E(P.amount,x)});break;default:return{v:function(){function P(D){return!1}return P}()}}},V,B=y(C),I;!(I=B()).done;)if(V=N(),V!==0&&V)return V.v;return function(L){for(var w=0,A=f;w=1?Number(E):1)}return A}()})]})]})}},2916:function(T,r,n){"use strict";r.__esModule=!0,r.ShuttleConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ShuttleConsole=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;return(0,e.createComponentVNode)(2,o.Window,{width:350,height:150,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Location",children:i.status?i.status:(0,e.createComponentVNode)(2,t.NoticeBox,{color:"red",children:"Shuttle Missing"})}),!!i.shuttle&&(!!i.docking_ports_len&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Send to ",children:i.docking_ports.map(function(c){return(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-right",content:c.name,onClick:function(){function m(){return h("move",{move:c.id})}return m}()},c.name)})})||(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:"red",children:(0,e.createComponentVNode)(2,t.NoticeBox,{color:"red",children:"Shuttle Locked"})}),!!i.admin_controlled&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Authorization",children:(0,e.createComponentVNode)(2,t.Button,{icon:"exclamation-circle",content:"Request Authorization",disabled:!i.status,onClick:function(){function c(){return h("request")}return c}()})})],0))]})})})})}return b}()},39401:function(T,r,n){"use strict";r.__esModule=!0,r.ShuttleManipulator=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ShuttleManipulator=function(){function k(h,i){var c=(0,a.useLocalState)(i,"tabIndex",0),m=c[0],l=c[1],u=function(){function s(d){switch(d){case 0:return(0,e.createComponentVNode)(2,b);case 1:return(0,e.createComponentVNode)(2,y);case 2:return(0,e.createComponentVNode)(2,S);default:return"WE SHOULDN'T BE HERE!"}}return s}();return(0,e.createComponentVNode)(2,o.Window,{width:650,height:700,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Box,{fillPositionedParent:!0,children:[(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:m===0,onClick:function(){function s(){return l(0)}return s}(),icon:"info-circle",children:"Status"},"Status"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:m===1,onClick:function(){function s(){return l(1)}return s}(),icon:"file-import",children:"Templates"},"Templates"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:m===2,onClick:function(){function s(){return l(2)}return s}(),icon:"tools",children:"Modification"},"Modification")]}),u(m)]})})})}return k}(),b=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.shuttles;return(0,e.createComponentVNode)(2,t.Box,{children:u.map(function(s){return(0,e.createComponentVNode)(2,t.Section,{title:s.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID",children:s.id}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Shuttle Timer",children:s.timeleft}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Shuttle Mode",children:s.mode}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Shuttle Status",children:s.status}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Jump To",icon:"location-arrow",onClick:function(){function d(){return m("jump_to",{type:"mobile",id:s.id})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Fast Travel",icon:"fast-forward",onClick:function(){function d(){return m("fast_travel",{id:s.id})}return d}()})]})]})},s.name)})})},y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.templates_tabs,s=l.existing_shuttle,d=l.templates;return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Tabs,{children:u.map(function(v){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:v===s.id,icon:"file",onClick:function(){function g(){return m("select_template_category",{cat:v})}return g}(),children:v},v)})}),!!s&&d[s.id].templates.map(function(v){return(0,e.createComponentVNode)(2,t.Section,{title:v.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[v.description&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:v.description}),v.admin_notes&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Admin Notes",children:v.admin_notes}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:(0,e.createComponentVNode)(2,t.Button,{content:"Load Template",icon:"download",onClick:function(){function g(){return m("select_template",{shuttle_id:v.shuttle_id})}return g}()})})]})},v.name)})]})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.existing_shuttle,s=l.selected;return(0,e.createComponentVNode)(2,t.Box,{children:[u?(0,e.createComponentVNode)(2,t.Section,{title:"Selected Shuttle: "+u.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:u.status}),u.timer&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Timer",children:u.timeleft}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:(0,e.createComponentVNode)(2,t.Button,{content:"Jump To",icon:"location-arrow",onClick:function(){function d(){return m("jump_to",{type:"mobile",id:u.id})}return d}()})})]})}):(0,e.createComponentVNode)(2,t.Section,{title:"Selected Shuttle: None"}),s?(0,e.createComponentVNode)(2,t.Section,{title:"Selected Template: "+s.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[s.description&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:s.description}),s.admin_notes&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Admin Notes",children:s.admin_notes}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Preview",icon:"eye",onClick:function(){function d(){return m("preview",{shuttle_id:s.shuttle_id})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Load",icon:"download",onClick:function(){function d(){return m("load",{shuttle_id:s.shuttle_id})}return d}()})]})]})}):(0,e.createComponentVNode)(2,t.Section,{title:"Selected Template: None"})]})}},88284:function(T,r,n){"use strict";r.__esModule=!0,r.Sleeper=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=[["good","Alive"],["average","Critical"],["bad","DEAD"]],y=[["Resp.","oxyLoss"],["Toxin","toxLoss"],["Brute","bruteLoss"],["Burn","fireLoss"]],S={average:[.25,.5],bad:[.5,1/0]},k=["bad","average","average","good","average","average","bad"],h=r.Sleeper=function(){function d(v,g){var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.hasOccupant,B=V?(0,e.createComponentVNode)(2,i):(0,e.createComponentVNode)(2,s);return(0,e.createComponentVNode)(2,p.Window,{width:550,height:760,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:B}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,l)})]})})})}return d}(),i=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.occupant;return(0,e.createFragment)([(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,m),(0,e.createComponentVNode)(2,u)],4)},c=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.occupant,B=N.auto_eject_dead;return(0,e.createComponentVNode)(2,o.Section,{title:"Occupant",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Box,{color:"label",inline:!0,children:"Auto-eject if dead:\xA0"}),(0,e.createComponentVNode)(2,o.Button,{icon:B?"toggle-on":"toggle-off",selected:B,content:B?"On":"Off",onClick:function(){function I(){return f("auto_eject_dead_"+(B?"off":"on"))}return I}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"user-slash",content:"Eject",onClick:function(){function I(){return f("ejectify")}return I}()})],4),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Name",children:V.name}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:V.maxHealth,value:V.health/V.maxHealth,ranges:{good:[.5,1/0],average:[0,.5],bad:[-1/0,0]},children:(0,a.round)(V.health,0)})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Status",color:b[V.stat][0],children:b[V.stat][1]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:V.maxTemp,value:V.bodyTemperature/V.maxTemp,color:k[V.temperatureSuitability+3],children:[(0,a.round)(V.btCelsius,0),"\xB0C,",(0,a.round)(V.btFaren,0),"\xB0F"]})}),!!V.hasBlood&&(0,e.createFragment)([(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Blood Level",children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:V.bloodMax,value:V.bloodLevel/V.bloodMax,ranges:{bad:[-1/0,.6],average:[.6,.9],good:[.6,1/0]},children:[V.bloodPercent,"%, ",V.bloodLevel,"cl"]})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Pulse",verticalAlign:"middle",children:[V.pulse," BPM"]})],4)]})})},m=function(v,g){var C=(0,t.useBackend)(g),f=C.data,N=f.occupant;return(0,e.createComponentVNode)(2,o.Section,{title:"Occupant Damage",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:y.map(function(V,B){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:V[0],children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:"100",value:N[V[1]]/100,ranges:S,children:(0,a.round)(N[V[1]],0)},B)},B)})})})},l=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.hasOccupant,B=N.isBeakerLoaded,I=N.beakerMaxSpace,L=N.beakerFreeSpace,w=N.dialysis,A=w&&L>0;return(0,e.createComponentVNode)(2,o.Section,{title:"Dialysis",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{disabled:!B||L<=0||!V,selected:A,icon:A?"toggle-on":"toggle-off",content:A?"Active":"Inactive",onClick:function(){function x(){return f("togglefilter")}return x}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:!B,icon:"eject",content:"Eject",onClick:function(){function x(){return f("removebeaker")}return x}()})],4),children:B?(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Remaining Space",children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:I,value:L/I,ranges:{good:[.5,1/0],average:[.25,.5],bad:[-1/0,.25]},children:[L,"u"]})})}):(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No beaker loaded."})})},u=function(v,g){var C=(0,t.useBackend)(g),f=C.act,N=C.data,V=N.occupant,B=N.chemicals,I=N.maxchem,L=N.amounts;return(0,e.createComponentVNode)(2,o.Section,{title:"Occupant Chemicals",children:B.map(function(w,A){var x="",E;return w.overdosing?(x="bad",E=(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-circle"}),"\xA0 Overdosing!"]})):w.od_warning&&(x="average",E=(0,e.createComponentVNode)(2,o.Box,{color:"average",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-triangle"}),"\xA0 Close to overdosing"]})),(0,e.createComponentVNode)(2,o.Box,{backgroundColor:"rgba(0, 0, 0, 0.33)",mb:"0.5rem",children:(0,e.createComponentVNode)(2,o.Section,{title:w.title,level:"3",mx:"0",lineHeight:"18px",buttons:E,children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:I,value:w.occ_amount/I,color:x,title:"Amount of chemicals currently inside the occupant / Total amount injectable by this machine",mr:"0.5rem",children:[w.pretty_amount,"/",I,"u"]}),L.map(function(P,D){return(0,e.createComponentVNode)(2,o.Button,{disabled:!w.injectable||w.occ_amount+P>I||V.stat===2,icon:"syringe",content:"Inject "+P+"u",title:"Inject "+P+"u of "+w.title+" into the occupant",mb:"0",height:"19px",onClick:function(){function M(){return f("chemical",{chemid:w.id,amount:P})}return M}()},D)})]})})},A)})})},s=function(v,g){return(0,e.createComponentVNode)(2,o.Section,{fill:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No occupant detected."]})})})}},21597:function(T,r,n){"use strict";r.__esModule=!0,r.SlotMachine=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SlotMachine=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;if(i.money===null)return(0,e.createComponentVNode)(2,o.Window,{width:350,height:90,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{children:"Could not scan your card or could not find account!"}),(0,e.createComponentVNode)(2,t.Box,{children:"Please wear or hold your ID and try again."})]})})});var c;return i.plays===1?c=i.plays+" player has tried their luck today!":c=i.plays+" players have tried their luck today!",(0,e.createComponentVNode)(2,o.Window,{width:300,height:151,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{lineHeight:2,children:c}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Credits Remaining",children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:i.money})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"10 credits to spin",children:(0,e.createComponentVNode)(2,t.Button,{icon:"coins",disabled:i.working,content:i.working?"Spinning...":"Spin",onClick:function(){function m(){return h("spin")}return m}()})})]}),(0,e.createComponentVNode)(2,t.Box,{bold:!0,lineHeight:2,color:i.resultlvl,children:i.result})]})})})}return b}()},46348:function(T,r,n){"use strict";r.__esModule=!0,r.Smartfridge=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Smartfridge=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.secure,m=i.can_dry,l=i.drying,u=i.contents;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[!!c&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"Secure Access: Please have your identification ready."}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:m?"Drying rack":"Contents",buttons:!!m&&(0,e.createComponentVNode)(2,t.Button,{width:4,icon:l?"power-off":"times",content:l?"On":"Off",selected:l,onClick:function(){function s(){return h("drying")}return s}()}),children:[!u&&(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"average",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"cookie-bite",size:5,color:"brown"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"No products loaded."]})}),!!u&&u.slice().sort(function(s,d){return s.display_name.localeCompare(d.display_name)}).map(function(s){return(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"55%",children:s.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"25%",children:["(",s.quantity," in stock)"]}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:13,children:[(0,e.createComponentVNode)(2,t.Button,{width:3,icon:"arrow-down",tooltip:"Dispense one.",content:"1",onClick:function(){function d(){return h("vend",{index:s.vend,amount:1})}return d}()}),(0,e.createComponentVNode)(2,t.NumberInput,{width:"40px",minValue:0,value:0,maxValue:s.quantity,step:1,stepPixelSize:3,onChange:function(){function d(v,g){return h("vend",{index:s.vend,amount:g})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{width:4,icon:"arrow-down",content:"All",tooltip:"Dispense all.",tooltipPosition:"bottom-start",onClick:function(){function d(){return h("vend",{index:s.vend,amount:s.quantity})}return d}()})]})]},s)})]})]})})})}return b}()},86162:function(T,r,n){"use strict";r.__esModule=!0,r.Smes=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(49968),p=n(98595),b=1e3,y=r.Smes=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.capacityPercent,u=m.capacity,s=m.charge,d=m.inputAttempt,v=m.inputting,g=m.inputLevel,C=m.inputLevelMax,f=m.inputAvailable,N=m.outputPowernet,V=m.outputAttempt,B=m.outputting,I=m.outputLevel,L=m.outputLevelMax,w=m.outputUsed,A=l>=100&&"good"||v&&"average"||"bad",x=B&&"good"||s>0&&"average"||"bad";return(0,e.createComponentVNode)(2,p.Window,{width:340,height:345,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Stored Energy",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:l*.01,ranges:{good:[.5,1/0],average:[.15,.5],bad:[-1/0,.15]}})}),(0,e.createComponentVNode)(2,t.Section,{title:"Input",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Charge Mode",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:d?"sync-alt":"times",selected:d,onClick:function(){function E(){return c("tryinput")}return E}(),children:d?"Auto":"Off"}),children:(0,e.createComponentVNode)(2,t.Box,{color:A,children:l>=100&&"Fully Charged"||v&&"Charging"||"Not Charging"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target Input",children:(0,e.createComponentVNode)(2,t.Stack,{inline:!0,width:"100%",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",disabled:g===0,onClick:function(){function E(){return c("input",{target:"min"})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"backward",disabled:g===0,onClick:function(){function E(){return c("input",{adjust:-1e4})}return E}()})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Slider,{value:g/b,fillValue:f/b,minValue:0,maxValue:C/b,step:5,stepPixelSize:4,format:function(){function E(P){return(0,o.formatPower)(P*b,1)}return E}(),onChange:function(){function E(P,D){return c("input",{target:D*b})}return E}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"forward",disabled:g===C,onClick:function(){function E(){return c("input",{adjust:1e4})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",disabled:g===C,onClick:function(){function E(){return c("input",{target:"max"})}return E}()})]})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Available",children:(0,o.formatPower)(f)})]})}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Output",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Output Mode",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:V?"power-off":"times",selected:V,onClick:function(){function E(){return c("tryoutput")}return E}(),children:V?"On":"Off"}),children:(0,e.createComponentVNode)(2,t.Box,{color:x,children:N?B?"Sending":s>0?"Not Sending":"No Charge":"Not Connected"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target Output",children:(0,e.createComponentVNode)(2,t.Stack,{inline:!0,width:"100%",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",disabled:I===0,onClick:function(){function E(){return c("output",{target:"min"})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"backward",disabled:I===0,onClick:function(){function E(){return c("output",{adjust:-1e4})}return E}()})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Slider,{value:I/b,minValue:0,maxValue:L/b,step:5,stepPixelSize:4,format:function(){function E(P){return(0,o.formatPower)(P*b,1)}return E}(),onChange:function(){function E(P,D){return c("output",{target:D*b})}return E}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"forward",disabled:I===L,onClick:function(){function E(){return c("output",{adjust:1e4})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",disabled:I===L,onClick:function(){function E(){return c("output",{target:"max"})}return E}()})]})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Outputting",children:(0,o.formatPower)(w)})]})})]})})})}return S}()},63584:function(T,r,n){"use strict";r.__esModule=!0,r.SolarControl=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SolarControl=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=0,m=1,l=2,u=i.generated,s=i.generated_ratio,d=i.tracking_state,v=i.tracking_rate,g=i.connected_panels,C=i.connected_tracker,f=i.cdir,N=i.direction,V=i.rotating_direction;return(0,e.createComponentVNode)(2,o.Window,{width:490,height:277,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Status",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"sync",content:"Scan for new hardware",onClick:function(){function B(){return h("refresh")}return B}()}),children:(0,e.createComponentVNode)(2,t.Grid,{children:[(0,e.createComponentVNode)(2,t.Grid.Column,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Solar tracker",color:C?"good":"bad",children:C?"OK":"N/A"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Solar panels",color:g>0?"good":"bad",children:g})]})}),(0,e.createComponentVNode)(2,t.Grid.Column,{size:2,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power output",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ranges:{good:[.66,1/0],average:[.33,.66],bad:[-1/0,.33]},minValue:0,maxValue:1,value:s,children:u+" W"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Panel orientation",children:[f,"\xB0 (",N,")"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tracker rotation",children:[d===l&&(0,e.createComponentVNode)(2,t.Box,{children:" Automated "}),d===m&&(0,e.createComponentVNode)(2,t.Box,{children:[" ",v,"\xB0/h (",V,")"," "]}),d===c&&(0,e.createComponentVNode)(2,t.Box,{children:" Tracker offline "})]})]})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Controls",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Panel orientation",children:[d!==l&&(0,e.createComponentVNode)(2,t.NumberInput,{unit:"\xB0",step:1,stepPixelSize:1,minValue:0,maxValue:359,value:f,onDrag:function(){function B(I,L){return h("cdir",{cdir:L})}return B}()}),d===l&&(0,e.createComponentVNode)(2,t.Box,{lineHeight:"19px",children:" Automated "})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tracker status",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Off",selected:d===c,onClick:function(){function B(){return h("track",{track:c})}return B}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"clock-o",content:"Timed",selected:d===m,onClick:function(){function B(){return h("track",{track:m})}return B}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sync",content:"Auto",selected:d===l,disabled:!C,onClick:function(){function B(){return h("track",{track:l})}return B}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tracker rotation",children:[d===m&&(0,e.createComponentVNode)(2,t.NumberInput,{unit:"\xB0/h",step:1,stepPixelSize:1,minValue:-7200,maxValue:7200,value:v,format:function(){function B(I){var L=Math.sign(I)>0?"+":"-";return L+Math.abs(I)}return B}(),onDrag:function(){function B(I,L){return h("tdir",{tdir:L})}return B}()}),d===c&&(0,e.createComponentVNode)(2,t.Box,{lineHeight:"19px",children:" Tracker offline "}),d===l&&(0,e.createComponentVNode)(2,t.Box,{lineHeight:"19px",children:" Automated "})]})]})})]})})}return b}()},38096:function(T,r,n){"use strict";r.__esModule=!0,r.SpawnersMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SpawnersMenu=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.spawners||[];return(0,e.createComponentVNode)(2,o.Window,{width:700,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{children:c.map(function(m){return(0,e.createComponentVNode)(2,t.Section,{mb:.5,title:m.name+" ("+m.amount_left+" left)",level:2,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-circle-right",content:"Jump",onClick:function(){function l(){return h("jump",{ID:m.uids})}return l}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-circle-right",content:"Spawn",onClick:function(){function l(){return h("spawn",{ID:m.uids})}return l}()})],4),children:[(0,e.createComponentVNode)(2,t.Box,{style:{"white-space":"pre-wrap"},mb:1,fontSize:"16px",children:m.desc}),!!m.fluff&&(0,e.createComponentVNode)(2,t.Box,{style:{"white-space":"pre-wrap"},textColor:"#878787",fontSize:"14px",children:m.fluff}),!!m.important_info&&(0,e.createComponentVNode)(2,t.Box,{style:{"white-space":"pre-wrap"},mt:1,bold:!0,color:"red",fontSize:"18px",children:m.important_info})]},m.name)})})})})}return b}()},30586:function(T,r,n){"use strict";r.__esModule=!0,r.SpecMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SpecMenu=function(){function h(i,c){return(0,e.createComponentVNode)(2,o.Window,{width:1100,height:600,theme:"nologo",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,y),(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k)]})})})}return h}(),b=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.subclasses;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Hemomancer",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Choose",onClick:function(){function d(){return l("hemomancer")}return d}()}),children:[(0,e.createVNode)(1,"h3",null,"Focuses on blood magic and the manipulation of blood around you.",16),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Vampiric claws",16),(0,e.createTextVNode)(": Unlocked at 150 blood, allows you to summon a robust pair of claws that attack rapidly, drain a targets blood, and heal you.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood Barrier",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to select two turfs and create a wall between them.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood tendrils",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to slow everyone in a targeted 3x3 area after a short delay.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Sanguine pool",16),(0,e.createTextVNode)(": Unlocked at 400 blood, allows you to travel at high speeds for a short duration. Doing this leaves behind blood splatters. You can move through anything but walls and space when doing this.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Predator senses",16),(0,e.createTextVNode)(": Unlocked at 600 blood, allows you to sniff out anyone within the same sector as you.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood eruption",16),(0,e.createTextVNode)(": Unlocked at 800 blood, allows you to manipulate all nearby blood splatters, in 4 tiles around you, into spikes that impale anyone stood ontop of them.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Full power",16),(0,e.createComponentVNode)(2,t.Divider),(0,e.createVNode)(1,"b",null,"The blood bringers rite",16),(0,e.createTextVNode)(": When toggled you will rapidly drain the blood of everyone who is nearby and use it to heal yourself slightly and remove any incapacitating effects rapidly.")],4)]})})},y=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.subclasses;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Umbrae",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Choose",onClick:function(){function d(){return l("umbrae")}return d}()}),children:[(0,e.createVNode)(1,"h3",null,"Focuses on darkness, stealth ambushing and mobility.",16),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Cloak of darkness",16),(0,e.createTextVNode)(": Unlocked at 150 blood, when toggled, allows you to become nearly invisible and move rapidly when in dark regions. While active, burn damage is more effective against you.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Shadow anchor",16),(0,e.createTextVNode)(": Unlocked at 250 blood, casting it will create an anchor at the cast location after a short delay. If you then cast the ability again, you are teleported back to the anchor. If you do not cast again within 2 minutes, you will do a fake recall, causing a clone to appear at the anchor and making yourself invisible. It will not teleport you between Z levels.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Shadow snare",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to summon a trap that when crossed blinds and ensnares the victim. This trap is hard to see, but withers in the light.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Dark passage",16),(0,e.createTextVNode)(": Unlocked at 400 blood, allows you to target a turf on screen, you will then teleport to that turf.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Extinguish",16),(0,e.createTextVNode)(": Unlocked at 600 blood, allows you to snuff out nearby electronic light sources and glowshrooms.")],4),(0,e.createVNode)(1,"b",null,"Shadow boxing",16),": Unlocked at 800 blood, sends out shadow clones towards a target, damaging them while you remain in range.",(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Full power",16),(0,e.createComponentVNode)(2,t.Divider),(0,e.createVNode)(1,"b",null,"Eternal darkness",16),(0,e.createTextVNode)(": When toggled, you consume yourself in unholy darkness, only the strongest of lights will be able to see through it. Inside the radius, nearby creatures will freeze and energy projectiles will deal less damage.")],4),(0,e.createVNode)(1,"p",null,"In addition, you also gain permanent X-ray vision.",16)]})})},S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.subclasses;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Gargantua",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Choose",onClick:function(){function d(){return l("gargantua")}return d}()}),children:[(0,e.createVNode)(1,"h3",null,"Focuses on tenacity and melee damage.",16),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Rejuvenate",16),(0,e.createTextVNode)(": Will heal you at an increased rate based on how much damage you have taken.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood swell",16),(0,e.createTextVNode)(": Unlocked at 150 blood, increases your resistance to physical damage, stuns and stamina for 30 seconds. While it is active you cannot fire guns.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Seismic stomp",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to stomp the ground to send out a shockwave, knocking people back.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood rush",16),(0,e.createTextVNode)(": Unlocked at 250 blood, gives you a short speed boost when cast.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood swell II",16),(0,e.createTextVNode)(": Unlocked at 400 blood, increases all melee damage by 10.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Overwhelming force",16),(0,e.createTextVNode)(": Unlocked at 600 blood, when toggled, if you bump into a door that you do not have access to, it will force it open. In addition, you cannot be pushed or pulled while it is active.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Demonic grasp",16),(0,e.createTextVNode)(": Unlocked at 800 blood, allows you to send out a demonic hand to snare someone. If you are on disarm/grab intent you will push/pull the target, respectively.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Charge",16),(0,e.createTextVNode)(": Unlocked at 800 blood, you gain the ability to charge at a target. Destroying and knocking back pretty much anything you collide with.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Full Power",16),(0,e.createComponentVNode)(2,t.Divider),(0,e.createVNode)(1,"b",null,"Desecrated Duel",16),(0,e.createTextVNode)(": Leap towards a visible enemy, creating an arena upon landing, infusing you with increased regeneration, and granting you resistance to internal damages.")],4)]})})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.subclasses;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Dantalion",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Choose",onClick:function(){function d(){return l("dantalion")}return d}()}),children:[(0,e.createVNode)(1,"h3",null,"Focuses on thralling and illusions.",16),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Enthrall",16),(0,e.createTextVNode)(": Unlocked at 150 blood, Thralls your target to your will, requires you to stand still. Does not work on mindshielded or already enthralled/mindslaved people.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Thrall cap",16),(0,e.createTextVNode)(": You can only thrall a max of 1 person at a time. This can be increased at 400 blood, 600 blood and at full power to a max of 4 thralls.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Thrall commune",16),(0,e.createTextVNode)(": Unlocked at 150 blood, Allows you to talk to your thralls, your thralls can talk back in the same way.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Subspace swap",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to swap positions with a target.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Pacify",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to pacify a target, preventing them from causing harm for 40 seconds.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Decoy",16),(0,e.createTextVNode)(": Unlocked at 400 blood, briefly turn invisible and send out an illusion to fool everyone nearby.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Rally thralls",16),(0,e.createTextVNode)(": Unlocked at 600 blood, removes all incapacitating effects from nearby thralls.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood bond",16),(0,e.createTextVNode)(": Unlocked at 800 blood, when cast, all nearby thralls become linked to you. If anyone in the network takes damage, it is shared equally between everyone in the network. If a thrall goes out of range, they will be removed from the network.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Full Power",16),(0,e.createComponentVNode)(2,t.Divider),(0,e.createVNode)(1,"b",null,"Mass Hysteria",16),(0,e.createTextVNode)(": Casts a powerful illusion that blinds and then makes everyone nearby perceive others as random animals.")],4)]})})}},95152:function(T,r,n){"use strict";r.__esModule=!0,r.StackCraft=void 0;var e=n(89005),a=n(72253),t=n(88510),o=n(64795),p=n(25328),b=n(98595),y=n(36036),S=r.StackCraft=function(){function s(){return(0,e.createComponentVNode)(2,b.Window,{width:350,height:500,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,k)})})}return s}(),k=function(d,v){var g=(0,a.useBackend)(v),C=g.data,f=C.amount,N=C.recipes,V=(0,a.useLocalState)(v,"searchText",""),B=V[0],I=V[1],L=h(N,(0,p.createSearch)(B)),w=(0,a.useLocalState)(v,"",!1),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,y.Section,{fill:!0,scrollable:!0,title:"Amount: "+f,buttons:(0,e.createFragment)([A&&(0,e.createComponentVNode)(2,y.Input,{width:12.5,value:B,placeholder:"Find recipe",onInput:function(){function E(P,D){return I(D)}return E}()}),(0,e.createComponentVNode)(2,y.Button,{ml:.5,tooltip:"Search",tooltipPosition:"bottom-end",icon:"magnifying-glass",selected:A,onClick:function(){function E(){return x(!A)}return E}()})],0),children:L?(0,e.createComponentVNode)(2,l,{recipes:L}):(0,e.createComponentVNode)(2,y.NoticeBox,{children:"No recipes found!"})})},h=function s(d,v){var g=(0,o.flow)([(0,t.map)(function(C){var f=C[0],N=C[1];return i(N)?v(f)?C:[f,s(N,v)]:v(f)?C:[f,void 0]}),(0,t.filter)(function(C){var f=C[0],N=C[1];return N!==void 0}),(0,t.sortBy)(function(C){var f=C[0],N=C[1];return f}),(0,t.sortBy)(function(C){var f=C[0],N=C[1];return!i(N)}),(0,t.reduce)(function(C,f){var N=f[0],V=f[1];return C[N]=V,C},{})])(Object.entries(d));return Object.keys(g).length?g:void 0},i=function(d){return d.uid===void 0},c=function(d,v){return d.required_amount>v?0:Math.floor(v/d.required_amount)},m=function(d,v){for(var g=(0,a.useBackend)(v),C=g.act,f=d.recipe,N=d.max_possible_multiplier,V=Math.min(N,Math.floor(f.max_result_amount/f.result_amount)),B=[5,10,25],I=[],L=function(){var E=A[w];V>=E&&I.push((0,e.createComponentVNode)(2,y.Button,{bold:!0,translucent:!0,fontSize:.85,width:"32px",content:E*f.result_amount+"x",onClick:function(){function P(){return C("make",{recipe_uid:f.uid,multiplier:E})}return P}()}))},w=0,A=B;w1?I+"x ":"",M=L>1?"s":"",O=""+D+V,R=L+" sheet"+M,F=c(B,N);return(0,e.createComponentVNode)(2,y.ImageButton,{fluid:!0,base64:P,dmIcon:x,dmIconState:E,imageSize:32,disabled:!F,tooltip:R,buttons:w>1&&F>1&&(0,e.createComponentVNode)(2,m,{recipe:B,max_possible_multiplier:F}),onClick:function(){function W(){return C("make",{recipe_uid:A,multiplier:1})}return W}(),children:O})}},38307:function(T,r,n){"use strict";r.__esModule=!0,r.StationAlertConsoleContent=r.StationAlertConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.StationAlertConsole=function(){function y(){return(0,e.createComponentVNode)(2,o.Window,{width:325,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,b)})})}return y}(),b=r.StationAlertConsoleContent=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.data,c=i.alarms||[],m=c.Fire||[],l=c.Atmosphere||[],u=c.Power||[];return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"Fire Alarms",children:(0,e.createVNode)(1,"ul",null,[m.length===0&&(0,e.createVNode)(1,"li","color-good","Systems Nominal",16),m.map(function(s){return(0,e.createVNode)(1,"li","color-average",s,0,null,s)})],0)}),(0,e.createComponentVNode)(2,t.Section,{title:"Atmospherics Alarms",children:(0,e.createVNode)(1,"ul",null,[l.length===0&&(0,e.createVNode)(1,"li","color-good","Systems Nominal",16),l.map(function(s){return(0,e.createVNode)(1,"li","color-average",s,0,null,s)})],0)}),(0,e.createComponentVNode)(2,t.Section,{title:"Power Alarms",children:(0,e.createVNode)(1,"ul",null,[u.length===0&&(0,e.createVNode)(1,"li","color-good","Systems Nominal",16),u.map(function(s){return(0,e.createVNode)(1,"li","color-average",s,0,null,s)})],0)})],4)}return y}()},96091:function(T,r,n){"use strict";r.__esModule=!0,r.StationTraitsPanel=void 0;var e=n(89005),a=n(88510),t=n(42127),o=n(72253),p=n(36036),b=n(98595),y=function(i){return i[i.SetupFutureStationTraits=0]="SetupFutureStationTraits",i[i.ViewStationTraits=1]="ViewStationTraits",i}(y||{}),S=function(c,m){var l=(0,o.useBackend)(m),u=l.act,s=l.data,d=s.future_station_traits,v=(0,o.useLocalState)(m,"selectedFutureTrait",null),g=v[0],C=v[1],f=Object.fromEntries(s.valid_station_traits.map(function(V){return[V.name,V.path]})),N=Object.keys(f);return N.sort(),(0,e.createComponentVNode)(2,p.Box,{children:[(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.Dropdown,{displayText:!g&&"Select trait to add...",onSelected:C,options:N,selected:g,width:"100%"})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button,{color:"green",icon:"plus",onClick:function(){function V(){if(g){var B=f[g],I=[B];if(d){var L,w=d.map(function(A){return A.path});if(w.indexOf(B)!==-1)return;I=(L=I).concat.apply(L,w)}u("setup_future_traits",{station_traits:I})}}return V}(),children:"Add"})})]}),(0,e.createComponentVNode)(2,p.Divider),Array.isArray(d)?d.length>0?(0,e.createComponentVNode)(2,p.Stack,{vertical:!0,fill:!0,children:d.map(function(V){return(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:V.name}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button,{color:"red",icon:"times",onClick:function(){function B(){u("setup_future_traits",{station_traits:(0,a.filterMap)(d,function(I){if(I.path!==V.path)return I.path})})}return B}(),children:"Delete"})})]})},V.path)})}):(0,e.createComponentVNode)(2,p.Box,{textAlign:"center",children:[(0,e.createComponentVNode)(2,p.Box,{children:"No station traits will run next round."}),(0,e.createComponentVNode)(2,p.Button,{mt:1,fluid:!0,color:"good",icon:"times",tooltip:"The next round will roll station traits randomly, just like normal",onClick:function(){function V(){return u("clear_future_traits")}return V}(),children:"Run Station Traits Normally"})]}):(0,e.createComponentVNode)(2,p.Box,{textAlign:"center",children:[(0,e.createComponentVNode)(2,p.Box,{children:"No future station traits are planned."}),(0,e.createComponentVNode)(2,p.Button,{mt:1,fluid:!0,color:"red",icon:"times",onClick:function(){function V(){return u("setup_future_traits",{station_traits:[]})}return V}(),children:"Prevent station traits from running next round"})]})]})},k=function(c,m){var l=(0,o.useBackend)(m),u=l.act,s=l.data;return s.current_traits.length>0?(0,e.createComponentVNode)(2,p.Stack,{vertical:!0,fill:!0,children:s.current_traits.map(function(d){return(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:d.name}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button.Confirm,{content:"Revert",color:"red",disabled:s.too_late_to_revert||!d.can_revert,tooltip:!d.can_revert&&"This trait is not revertable."||s.too_late_to_revert&&"It's too late to revert station traits, the round has already started.",icon:"times",onClick:function(){function v(){return u("revert",{ref:d.ref})}return v}()})})]})},d.ref)})}):(0,e.createComponentVNode)(2,p.Box,{textAlign:"center",children:"There are no active station traits."})},h=r.StationTraitsPanel=function(){function i(c,m){var l=(0,o.useLocalState)(m,"station_traits_tab",y.ViewStationTraits),u=l[0],s=l[1],d;switch(u){case y.SetupFutureStationTraits:d=(0,e.createComponentVNode)(2,S);break;case y.ViewStationTraits:d=(0,e.createComponentVNode)(2,k);break;default:(0,t.exhaustiveCheck)(u)}return(0,e.createComponentVNode)(2,b.Window,{title:"Modify Station Traits",height:350,width:350,children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Tabs,{children:[(0,e.createComponentVNode)(2,p.Tabs.Tab,{icon:"eye",selected:u===y.ViewStationTraits,onClick:function(){function v(){return s(y.ViewStationTraits)}return v}(),children:"View"}),(0,e.createComponentVNode)(2,p.Tabs.Tab,{icon:"edit",selected:u===y.SetupFutureStationTraits,onClick:function(){function v(){return s(y.SetupFutureStationTraits)}return v}(),children:"Edit"})]})}),(0,e.createComponentVNode)(2,p.Stack.Item,{m:0,children:[(0,e.createComponentVNode)(2,p.Divider),d]})]})})})}return i}()},39409:function(T,r,n){"use strict";r.__esModule=!0,r.StripMenu=void 0;var e=n(89005),a=n(88510),t=n(79140),o=n(72253),p=n(36036),b=n(98595),y=5,S=9,k=function(g){return g===0?5:9},h="64px",i=function(g){return g[0]+"/"+g[1]},c=function(g){var C=g.align,f=g.children;return(0,e.createComponentVNode)(2,p.Box,{style:{position:"absolute",left:C==="left"?"6px":"48px","text-align":C,"text-shadow":"2px 2px 2px #000",top:"2px"},children:f})},m={enable_internals:{icon:"lungs",text:"Enable internals"},disable_internals:{icon:"lungs",text:"Disable internals"},enable_lock:{icon:"lock",text:"Enable lock"},disable_lock:{icon:"unlock",text:"Disable lock"},suit_sensors:{icon:"tshirt",text:"Adjust suit sensors"},remove_accessory:{icon:"medal",text:"Remove accessory"},dislodge_headpocket:{icon:"head-side-virus",text:"Dislodge headpocket"}},l={eyes:{displayName:"eyewear",gridSpot:i([0,0]),image:"inventory-glasses.png"},head:{displayName:"headwear",gridSpot:i([0,1]),image:"inventory-head.png"},mask:{displayName:"mask",gridSpot:i([1,1]),image:"inventory-mask.png"},neck:{displayName:"neck",gridSpot:i([1,0]),image:"inventory-neck.png"},pet_collar:{displayName:"collar",gridSpot:i([1,1]),image:"inventory-collar.png"},right_ear:{displayName:"right ear",gridSpot:i([0,2]),image:"inventory-ears.png"},left_ear:{displayName:"left ear",gridSpot:i([1,2]),image:"inventory-ears.png"},parrot_headset:{displayName:"headset",gridSpot:i([1,2]),image:"inventory-ears.png"},handcuffs:{displayName:"handcuffs",gridSpot:i([1,3])},legcuffs:{displayName:"legcuffs",gridSpot:i([1,4])},jumpsuit:{displayName:"uniform",gridSpot:i([2,0]),image:"inventory-uniform.png"},suit:{displayName:"suit",gridSpot:i([2,1]),image:"inventory-suit.png"},gloves:{displayName:"gloves",gridSpot:i([2,2]),image:"inventory-gloves.png"},right_hand:{displayName:"right hand",gridSpot:i([2,3]),image:"inventory-hand_r.png",additionalComponent:(0,e.createComponentVNode)(2,c,{align:"left",children:"R"})},left_hand:{displayName:"left hand",gridSpot:i([2,4]),image:"inventory-hand_l.png",additionalComponent:(0,e.createComponentVNode)(2,c,{align:"right",children:"L"})},shoes:{displayName:"shoes",gridSpot:i([3,1]),image:"inventory-shoes.png"},suit_storage:{displayName:"suit storage",gridSpot:i([4,0]),image:"inventory-suit_storage.png"},id:{displayName:"ID",gridSpot:i([4,1]),image:"inventory-id.png"},belt:{displayName:"belt",gridSpot:i([4,2]),image:"inventory-belt.png"},back:{displayName:"backpack",gridSpot:i([4,3]),image:"inventory-back.png"},left_pocket:{displayName:"left pocket",gridSpot:i([3,4]),image:"inventory-pocket.png"},right_pocket:{displayName:"right pocket",gridSpot:i([3,3]),image:"inventory-pocket.png"},pda:{displayName:"PDA",gridSpot:i([4,4]),image:"inventory-pda.png"}},u={eyes:{displayName:"eyewear",gridSpot:i([0,0]),image:"inventory-glasses.png"},head:{displayName:"headwear",gridSpot:i([0,1]),image:"inventory-head.png"},mask:{displayName:"mask",gridSpot:i([1,1]),image:"inventory-mask.png"},neck:{displayName:"neck",gridSpot:i([1,0]),image:"inventory-neck.png"},pet_collar:{displayName:"collar",gridSpot:i([1,1]),image:"inventory-collar.png"},right_ear:{displayName:"right ear",gridSpot:i([0,2]),image:"inventory-ears.png"},left_ear:{displayName:"left ear",gridSpot:i([1,2]),image:"inventory-ears.png"},parrot_headset:{displayName:"headset",gridSpot:i([1,2]),image:"inventory-ears.png"},handcuffs:{displayName:"handcuffs",gridSpot:i([1,3])},legcuffs:{displayName:"legcuffs",gridSpot:i([1,4])},jumpsuit:{displayName:"uniform",gridSpot:i([2,0]),image:"inventory-uniform.png"},suit:{displayName:"suit",gridSpot:i([2,1]),image:"inventory-suit.png"},gloves:{displayName:"gloves",gridSpot:i([2,2]),image:"inventory-gloves.png"},right_hand:{displayName:"right hand",gridSpot:i([4,4]),image:"inventory-hand_r.png",additionalComponent:(0,e.createComponentVNode)(2,c,{align:"left",children:"R"})},left_hand:{displayName:"left hand",gridSpot:i([4,5]),image:"inventory-hand_l.png",additionalComponent:(0,e.createComponentVNode)(2,c,{align:"right",children:"L"})},shoes:{displayName:"shoes",gridSpot:i([3,1]),image:"inventory-shoes.png"},suit_storage:{displayName:"suit storage",gridSpot:i([4,0]),image:"inventory-suit_storage.png"},id:{displayName:"ID",gridSpot:i([4,1]),image:"inventory-id.png"},belt:{displayName:"belt",gridSpot:i([4,2]),image:"inventory-belt.png"},back:{displayName:"backpack",gridSpot:i([4,3]),image:"inventory-back.png"},left_pocket:{displayName:"left pocket",gridSpot:i([4,7]),image:"inventory-pocket.png"},right_pocket:{displayName:"right pocket",gridSpot:i([4,6]),image:"inventory-pocket.png"},pda:{displayName:"PDA",gridSpot:i([4,8]),image:"inventory-pda.png"}},s=function(v){return v[v.Completely=1]="Completely",v[v.Hidden=2]="Hidden",v}(s||{}),d=r.StripMenu=function(){function v(g,C){var f=(0,o.useBackend)(C),N=f.act,V=f.data,B=new Map;if(V.show_mode===0)for(var I=0,L=Object.keys(V.items);I=.01})},(0,a.sortBy)(function(w){return-w.amount})])(g.gases||[]),L=Math.max.apply(Math,[1].concat(I.map(function(w){return w.amount})));return(0,e.createComponentVNode)(2,S.Window,{width:550,height:185,children:(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,b.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{width:"270px",children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Metrics",children:(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Integrity",children:(0,e.createComponentVNode)(2,b.ProgressBar,{value:f/100,ranges:{good:[.9,1/0],average:[.5,.9],bad:[-1/0,.5]}})}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Relative EER",children:(0,e.createComponentVNode)(2,b.ProgressBar,{value:N,minValue:0,maxValue:5e3,ranges:{good:[-1/0,5e3],average:[5e3,7e3],bad:[7e3,1/0]},children:(0,o.toFixed)(N)+" MeV/cm3"})}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,b.ProgressBar,{value:i(V),minValue:0,maxValue:i(1e4),ranges:{teal:[-1/0,i(80)],good:[i(80),i(373)],average:[i(373),i(1e3)],bad:[i(1e3),1/0]},children:(0,o.toFixed)(V)+" K"})}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Pressure",children:(0,e.createComponentVNode)(2,b.ProgressBar,{value:i(B),minValue:0,maxValue:i(5e4),ranges:{good:[i(1),i(300)],average:[-1/0,i(1e3)],bad:[i(1e3),1/0]},children:(0,o.toFixed)(B)+" kPa"})})]})})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,basis:0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Gases",buttons:(0,e.createComponentVNode)(2,b.Button,{icon:"arrow-left",content:"Back",onClick:function(){function w(){return v("back")}return w}()}),children:(0,e.createComponentVNode)(2,b.LabeledList,{children:I.map(function(w){return(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:(0,y.getGasLabel)(w.name),children:(0,e.createComponentVNode)(2,b.ProgressBar,{color:(0,y.getGasColor)(w.name),value:w.amount,minValue:0,maxValue:L,children:(0,o.toFixed)(w.amount,2)+"%"})},w.name)})})})})]})})})}},46029:function(T,r,n){"use strict";r.__esModule=!0,r.SyndicateComputerSimple=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SyndicateComputerSimple=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;return(0,e.createComponentVNode)(2,o.Window,{theme:"syndicate",width:400,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:i.rows.map(function(c){return(0,e.createComponentVNode)(2,t.Section,{title:c.title,buttons:(0,e.createComponentVNode)(2,t.Button,{content:c.buttontitle,disabled:c.buttondisabled,tooltip:c.buttontooltip,tooltipPosition:"left",onClick:function(){function m(){return h(c.buttonact)}return m}()}),children:[c.status,!!c.bullets&&(0,e.createComponentVNode)(2,t.Box,{children:c.bullets.map(function(m){return(0,e.createComponentVNode)(2,t.Box,{children:m},m)})})]},c.title)})})})}return b}()},36372:function(T,r,n){"use strict";r.__esModule=!0,r.TEG=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(S){return S.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,")},b=r.TEG=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data;return c.error?(0,e.createComponentVNode)(2,o.Window,{width:500,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Error",children:[c.error,(0,e.createComponentVNode)(2,t.Button,{icon:"circle",content:"Recheck",onClick:function(){function m(){return i("check")}return m}()})]})})}):(0,e.createComponentVNode)(2,o.Window,{width:500,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Cold Loop ("+c.cold_dir+")",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cold Inlet",children:[p(c.cold_inlet_temp)," K, ",p(c.cold_inlet_pressure)," kPa"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cold Outlet",children:[p(c.cold_outlet_temp)," K, ",p(c.cold_outlet_pressure)," kPa"]})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Hot Loop ("+c.hot_dir+")",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hot Inlet",children:[p(c.hot_inlet_temp)," K, ",p(c.hot_inlet_pressure)," kPa"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hot Outlet",children:[p(c.hot_outlet_temp)," K, ",p(c.hot_outlet_pressure)," kPa"]})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Power Output",children:[p(c.output_power)," W",!!c.warning_switched&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Warning: Cold inlet temperature exceeds hot inlet temperature."}),!!c.warning_cold_pressure&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Warning: Cold circulator inlet pressure is under 1,000 kPa."}),!!c.warning_hot_pressure&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Warning: Hot circulator inlet pressure is under 1,000 kPa."})]})]})})}return y}()},56441:function(T,r,n){"use strict";r.__esModule=!0,r.TachyonArrayContent=r.TachyonArray=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TachyonArray=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.records,l=m===void 0?[]:m,u=c.explosion_target,s=c.toxins_tech,d=c.printing;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Shift's Target",children:u}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Toxins Level",children:s}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Administration",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:"Print All Logs",disabled:!l.length||d,align:"center",onClick:function(){function v(){return i("print_logs")}return v}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"trash",content:"Delete All Logs",disabled:!l.length,color:"bad",align:"center",onClick:function(){function v(){return i("delete_logs")}return v}()})]})]})}),l.length?(0,e.createComponentVNode)(2,b):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No Records"})]})})}return y}(),b=r.TachyonArrayContent=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.records,l=m===void 0?[]:m;return(0,e.createComponentVNode)(2,t.Section,{title:"Logged Explosions",children:(0,e.createComponentVNode)(2,t.Flex,{children:(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Time"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Epicenter"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Actual Size"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Theoretical Size"})]}),l.map(function(u){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.logged_time}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.epicenter}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.actual_size_message}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.theoretical_size_message}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"trash",content:"Delete",color:"bad",onClick:function(){function s(){return i("delete_record",{index:u.index})}return s}()})})]},u.index)})]})})})})}return y}()},1754:function(T,r,n){"use strict";r.__esModule=!0,r.Tank=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Tank=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c;return i.has_mask?c=(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mask",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,width:"76%",icon:i.connected?"check":"times",content:i.connected?"Internals On":"Internals Off",selected:i.connected,onClick:function(){function m(){return h("internals")}return m}()})}):c=(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mask",color:"red",children:"No Mask Equipped"}),(0,e.createComponentVNode)(2,o.Window,{width:325,height:135,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tank Pressure",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:i.tankPressure/1013,ranges:{good:[.35,1/0],average:[.15,.35],bad:[-1/0,.15]},children:i.tankPressure+" kPa"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Release Pressure",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",disabled:i.ReleasePressure===i.minReleasePressure,tooltip:"Min",onClick:function(){function m(){return h("pressure",{pressure:"min"})}return m}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,value:parseFloat(i.releasePressure),width:"65px",unit:"kPa",minValue:i.minReleasePressure,maxValue:i.maxReleasePressure,onChange:function(){function m(l,u){return h("pressure",{pressure:u})}return m}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",disabled:i.ReleasePressure===i.maxReleasePressure,tooltip:"Max",onClick:function(){function m(){return h("pressure",{pressure:"max"})}return m}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"undo",content:"",disabled:i.ReleasePressure===i.defaultReleasePressure,tooltip:"Reset",onClick:function(){function m(){return h("pressure",{pressure:"reset"})}return m}()})]}),c]})})})})}return b}()},7579:function(T,r,n){"use strict";r.__esModule=!0,r.TankDispenser=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TankDispenser=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.o_tanks,m=i.p_tanks;return(0,e.createComponentVNode)(2,o.Window,{width:250,height:105,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:"Dispense Oxygen Tank ("+c+")",disabled:c===0,icon:"arrow-circle-down",onClick:function(){function l(){return h("oxygen")}return l}()})}),(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{mt:1,fluid:!0,content:"Dispense Plasma Tank ("+m+")",disabled:m===0,icon:"arrow-circle-down",onClick:function(){function l(){return h("plasma")}return l}()})})]})})})}return b}()},16136:function(T,r,n){"use strict";r.__esModule=!0,r.TcommsCore=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TcommsCore=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.ion,d=(0,a.useLocalState)(c,"tabIndex",0),v=d[0],g=d[1],C=function(){function f(N){switch(N){case 0:return(0,e.createComponentVNode)(2,y);case 1:return(0,e.createComponentVNode)(2,S);case 2:return(0,e.createComponentVNode)(2,k);default:return"SOMETHING WENT VERY WRONG PLEASE AHELP"}}return f}();return(0,e.createComponentVNode)(2,o.Window,{width:900,height:520,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[s===1&&(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"wrench",selected:v===0,onClick:function(){function f(){return g(0)}return f}(),children:"Configuration"},"ConfigPage"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"link",selected:v===1,onClick:function(){function f(){return g(1)}return f}(),children:"Device Linkage"},"LinkagePage"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"user-times",selected:v===2,onClick:function(){function f(){return g(2)}return f}(),children:"User Filtering"},"FilterPage")]}),C(v)]})})}return h}(),b=function(){return(0,e.createComponentVNode)(2,t.NoticeBox,{children:"ERROR: An Ionospheric overload has occured. Please wait for the machine to reboot. This cannot be manually done."})},y=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.active,d=u.sectors_available,v=u.nttc_toggle_jobs,g=u.nttc_toggle_job_color,C=u.nttc_toggle_name_color,f=u.nttc_toggle_command_bold,N=u.nttc_job_indicator_type,V=u.nttc_setting_language,B=u.network_id;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"Status",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Machine Power",children:(0,e.createComponentVNode)(2,t.Button,{content:s?"On":"Off",selected:s,icon:"power-off",onClick:function(){function I(){return l("toggle_active")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Sector Coverage",children:d})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Radio Configuration",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Job Announcements",children:(0,e.createComponentVNode)(2,t.Button,{content:v?"On":"Off",selected:v,icon:"user-tag",onClick:function(){function I(){return l("nttc_toggle_jobs")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Job Departmentalisation",children:(0,e.createComponentVNode)(2,t.Button,{content:g?"On":"Off",selected:g,icon:"clipboard-list",onClick:function(){function I(){return l("nttc_toggle_job_color")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name Departmentalisation",children:(0,e.createComponentVNode)(2,t.Button,{content:C?"On":"Off",selected:C,icon:"user-tag",onClick:function(){function I(){return l("nttc_toggle_name_color")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Command Amplification",children:(0,e.createComponentVNode)(2,t.Button,{content:f?"On":"Off",selected:f,icon:"volume-up",onClick:function(){function I(){return l("nttc_toggle_command_bold")}return I}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Advanced",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Job Announcement Format",children:(0,e.createComponentVNode)(2,t.Button,{content:N||"Unset",selected:N,icon:"pencil-alt",onClick:function(){function I(){return l("nttc_job_indicator_type")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Language Conversion",children:(0,e.createComponentVNode)(2,t.Button,{content:V||"Unset",selected:V,icon:"globe",onClick:function(){function I(){return l("nttc_setting_language")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Network ID",children:(0,e.createComponentVNode)(2,t.Button,{content:B||"Unset",selected:B,icon:"server",onClick:function(){function I(){return l("network_id")}return I}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Maintenance",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Import Configuration",icon:"file-import",onClick:function(){function I(){return l("import")}return I}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Export Configuration",icon:"file-export",onClick:function(){function I(){return l("export")}return I}()})]})],4)},S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.link_password,d=u.relay_entries;return(0,e.createComponentVNode)(2,t.Section,{title:"Device Linkage",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Linkage Password",children:(0,e.createComponentVNode)(2,t.Button,{content:s||"Unset",selected:s,icon:"lock",onClick:function(){function v(){return l("change_password")}return v}()})})}),(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Sector"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Unlink"})]}),d.map(function(v){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:v.addr}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:v.net_id}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:v.sector}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:v.status===1?(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Online"}):(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Offline"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Unlink",icon:"unlink",onClick:function(){function g(){return l("unlink",{addr:v.addr})}return g}()})})]},v.addr)})]})]})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.filtered_users;return(0,e.createComponentVNode)(2,t.Section,{title:"User Filtering",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Add User",icon:"user-plus",onClick:function(){function d(){return l("add_filter")}return d}()}),children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{style:{width:"90%"},children:"User"}),(0,e.createComponentVNode)(2,t.Table.Cell,{style:{width:"10%"},children:"Actions"})]}),s.map(function(d){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:d}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Remove",icon:"user-times",onClick:function(){function v(){return l("remove_filter",{user:d})}return v}()})})]},d)})]})})}},88046:function(T,r,n){"use strict";r.__esModule=!0,r.TcommsRelay=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TcommsRelay=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.linked,u=m.active,s=m.network_id;return(0,e.createComponentVNode)(2,o.Window,{width:600,height:292,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Relay Configuration",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Machine Power",children:(0,e.createComponentVNode)(2,t.Button,{content:u?"On":"Off",selected:u,icon:"power-off",onClick:function(){function d(){return c("toggle_active")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Network ID",children:(0,e.createComponentVNode)(2,t.Button,{content:s||"Unset",selected:s,icon:"server",onClick:function(){function d(){return c("network_id")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Link Status",children:l===1?(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Linked"}):(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Unlinked"})})]})}),l===1?(0,e.createComponentVNode)(2,b):(0,e.createComponentVNode)(2,y)]})})}return S}(),b=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.linked_core_id,u=m.linked_core_addr,s=m.hidden_link;return(0,e.createComponentVNode)(2,t.Section,{title:"Link Status",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Linked Core ID",children:l}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Linked Core Address",children:u}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hidden Link",children:(0,e.createComponentVNode)(2,t.Button,{content:s?"Yes":"No",icon:s?"eye-slash":"eye",selected:s,onClick:function(){function d(){return c("toggle_hidden_link")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Unlink",children:(0,e.createComponentVNode)(2,t.Button,{content:"Unlink",icon:"unlink",color:"red",onClick:function(){function d(){return c("unlink")}return d}()})})]})})},y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.cores;return(0,e.createComponentVNode)(2,t.Section,{title:"Detected Cores",children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Sector"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Link"})]}),l.map(function(u){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.addr}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.net_id}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.sector}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Link",icon:"link",onClick:function(){function s(){return c("link",{addr:u.addr})}return s}()})})]},u.addr)})]})})}},20802:function(T,r,n){"use strict";r.__esModule=!0,r.Teleporter=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Teleporter=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.targetsTeleport?i.targetsTeleport:{},m=0,l=1,u=2,s=i.calibrated,d=i.calibrating,v=i.powerstation,g=i.regime,C=i.teleporterhub,f=i.target,N=i.locked,V=i.adv_beacon_allowed,B=i.advanced_beacon_locking;return(0,e.createComponentVNode)(2,o.Window,{width:350,height:270,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:[(!v||!C)&&(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Error",children:[C,!v&&(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:" Powerstation not linked "}),v&&!C&&(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:" Teleporter hub not linked "})]}),v&&C&&(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Status",buttons:(0,e.createFragment)(!!V&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:"label",children:"Advanced Beacon Locking:\xA0"}),(0,e.createComponentVNode)(2,t.Button,{selected:B,icon:B?"toggle-on":"toggle-off",content:B?"Enabled":"Disabled",onClick:function(){function I(){return h("advanced_beacon_locking",{on:B?0:1})}return I}()})],4),0),children:[(0,e.createComponentVNode)(2,t.Stack,{mb:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:8.5,color:"label",children:"Teleport target:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[g===m&&(0,e.createComponentVNode)(2,t.Dropdown,{width:18.2,selected:f,disabled:d,options:Object.keys(c),color:f!=="None"?"default":"bad",onSelected:function(){function I(L){return h("settarget",{x:c[L].x,y:c[L].y,z:c[L].z,tptarget:c[L].pretarget})}return I}()}),g===l&&(0,e.createComponentVNode)(2,t.Dropdown,{width:18.2,selected:f,disabled:d,options:Object.keys(c),color:f!=="None"?"default":"bad",onSelected:function(){function I(L){return h("settarget",{x:c[L].x,y:c[L].y,z:c[L].z,tptarget:c[L].pretarget})}return I}()}),g===u&&(0,e.createComponentVNode)(2,t.Box,{children:f})]})]}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:8.5,color:"label",children:"Regime:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:"Gate",tooltip:"Teleport to another teleport hub.",tooltipPosition:"top",color:g===l?"good":null,onClick:function(){function I(){return h("setregime",{regime:l})}return I}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:"Teleporter",tooltip:"One-way teleport.",tooltipPosition:"top",color:g===m?"good":null,onClick:function(){function I(){return h("setregime",{regime:m})}return I}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:"GPS",tooltip:"Teleport to a location stored in a GPS device.",tooltipPosition:"top-end",color:g===u?"good":null,disabled:!N,onClick:function(){function I(){return h("setregime",{regime:u})}return I}()})})]}),(0,e.createComponentVNode)(2,t.Stack,{label:"Calibration",mt:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:8.5,color:"label",children:"Calibration:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[f!=="None"&&(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:15.8,textAlign:"center",mt:.5,children:d&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"In Progress"})||s&&(0,e.createComponentVNode)(2,t.Box,{color:"good",children:"Optimal"})||(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"Sub-Optimal"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{icon:"sync-alt",tooltip:"Calibrates the hub. Accidents may occur when the calibration is not optimal.",tooltipPosition:"bottom-end",disabled:!!(s||d),onClick:function(){function I(){return h("calibrate")}return I}()})})]}),f==="None"&&(0,e.createComponentVNode)(2,t.Box,{lineHeight:"21px",children:"No target set"})]})]})]}),!!(N&&v&&C&&g===u)&&(0,e.createComponentVNode)(2,t.Section,{title:"GPS",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Upload GPS data",tooltip:"Loads the GPS data from the device.",icon:"upload",onClick:function(){function I(){return h("load")}return I}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Eject",tooltip:"Ejects the GPS device",icon:"eject",onClick:function(){function I(){return h("eject")}return I}()})]})})]})})})})}return b}()},48517:function(T,r,n){"use strict";r.__esModule=!0,r.TelescienceConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TelescienceConsole=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.last_msg,m=i.linked_pad,l=i.held_gps,u=i.lastdata,s=i.power_levels,d=i.current_max_power,v=i.current_power,g=i.current_bearing,C=i.current_elevation,f=i.current_sector,N=i.working,V=i.max_z,B=(0,a.useLocalState)(S,"dummyrot",g),I=B[0],L=B[1];return(0,e.createComponentVNode)(2,o.Window,{width:400,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Status",children:(0,e.createFragment)([c,!(u.length>0)||(0,e.createVNode)(1,"ul",null,u.map(function(w){return(0,e.createVNode)(1,"li",null,w,0,null,w)}),0)],0)}),(0,e.createComponentVNode)(2,t.Section,{title:"Telepad Status",children:m===1?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Bearing",children:(0,e.createComponentVNode)(2,t.Box,{inline:!0,position:"relative",children:[(0,e.createComponentVNode)(2,t.NumberInput,{unit:"\xB0",width:6.1,lineHeight:1.5,step:.1,minValue:0,maxValue:360,disabled:N,value:g,onDrag:function(){function w(A,x){return L(x)}return w}(),onChange:function(){function w(A,x){return h("setbear",{bear:x})}return w}()}),(0,e.createComponentVNode)(2,t.Icon,{ml:1,size:1,name:"arrow-up",rotation:I})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Elevation",children:(0,e.createComponentVNode)(2,t.NumberInput,{width:6.1,lineHeight:1.5,step:.1,minValue:0,maxValue:100,disabled:N,value:C,onChange:function(){function w(A,x){return h("setelev",{elev:x})}return w}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power Level",children:s.map(function(w,A){return(0,e.createComponentVNode)(2,t.Button,{content:w,selected:v===w,disabled:A>=d-1||N,onClick:function(){function x(){return h("setpwr",{pwr:A+1})}return x}()},w)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target Sector",children:(0,e.createComponentVNode)(2,t.NumberInput,{width:6.1,lineHeight:1.5,step:1,minValue:2,maxValue:V,value:f,disabled:N,onChange:function(){function w(A,x){return h("setz",{newz:x})}return w}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Telepad Actions",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Send",disabled:N,onClick:function(){function w(){return h("pad_send")}return w}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Receive",disabled:N,onClick:function(){function w(){return h("pad_receive")}return w}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Crystal Maintenance",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Recalibrate Crystals",disabled:N,onClick:function(){function w(){return h("recal_crystals")}return w}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Eject Crystals",disabled:N,onClick:function(){function w(){return h("eject_crystals")}return w}()})]})]}):(0,e.createFragment)([(0,e.createTextVNode)("No pad linked to console. Please use a multitool to link a pad.")],4)}),(0,e.createComponentVNode)(2,t.Section,{title:"GPS Actions",children:l===1?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{disabled:l===0||N,content:"Eject GPS",onClick:function(){function w(){return h("eject_gps")}return w}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:l===0||N,content:"Store Coordinates",onClick:function(){function w(){return h("store_to_gps")}return w}()})],4):(0,e.createFragment)([(0,e.createTextVNode)("Please insert a GPS to store coordinates to it.")],4)})]})})}return b}()},21800:function(T,r,n){"use strict";r.__esModule=!0,r.TempGun=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.TempGun=function(){function h(i,c){var m=(0,t.useBackend)(c),l=m.act,u=m.data,s=u.target_temperature,d=u.temperature,v=u.max_temp,g=u.min_temp;return(0,e.createComponentVNode)(2,p.Window,{width:250,height:121,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Target Temperature",children:[(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:10,stepPixelSize:6,minValue:g,maxValue:v,value:s,format:function(){function C(f){return(0,a.toFixed)(f,2)}return C}(),width:"50px",onDrag:function(){function C(f,N){return l("target_temperature",{target_temperature:N})}return C}()}),"\xB0C"]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Current Temperature",children:(0,e.createComponentVNode)(2,o.Box,{color:y(d),bold:d>500-273.15,children:[(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:(0,a.round)(d,2)}),"\xB0C"]})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Power Cost",children:(0,e.createComponentVNode)(2,o.Box,{color:k(d),children:S(d)})})]})})})})}return h}(),y=function(i){return i<=-100?"blue":i<=0?"teal":i<=100?"green":i<=200?"orange":"red"},S=function(i){return i<=100-273.15?"High":i<=250-273.15?"Medium":i<=300-273.15?"Low":i<=400-273.15?"Medium":"High"},k=function(i){return i<=100-273.15?"red":i<=250-273.15?"orange":i<=300-273.15?"green":i<=400-273.15?"orange":"red"}},24410:function(T,r,n){"use strict";r.__esModule=!0,r.sanitizeMultiline=r.removeAllSkiplines=r.TextInputModal=void 0;var e=n(89005),a=n(51057),t=n(19203),o=n(72253),p=n(92986),b=n(36036),y=n(98595),S=r.sanitizeMultiline=function(){function c(m){return m.replace(/(\n|\r\n){3,}/,"\n\n")}return c}(),k=r.removeAllSkiplines=function(){function c(m){return m.replace(/[\r\n]+/,"")}return c}(),h=r.TextInputModal=function(){function c(m,l){var u=(0,o.useBackend)(l),s=u.act,d=u.data,v=d.max_length,g=d.message,C=g===void 0?"":g,f=d.multiline,N=d.placeholder,V=d.timeout,B=d.title,I=(0,o.useLocalState)(l,"input",N||""),L=I[0],w=I[1],A=function(){function P(D){if(D!==L){var M=f?S(D):k(D);w(M)}}return P}(),x=f||L.length>=40,E=130+(C.length>40?Math.ceil(C.length/4):0)+(x?80:0);return(0,e.createComponentVNode)(2,y.Window,{title:B,width:325,height:E,children:[V&&(0,e.createComponentVNode)(2,a.Loader,{value:V}),(0,e.createComponentVNode)(2,y.Window.Content,{onKeyDown:function(){function P(D){var M=window.event?D.which:D.keyCode;M===p.KEY_ENTER&&(!x||!D.shiftKey)&&s("submit",{entry:L}),M===p.KEY_ESCAPE&&s("cancel")}return P}(),children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,children:(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Box,{color:"label",children:C})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,i,{input:L,onType:A})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,t.InputButtons,{input:L,message:L.length+"/"+v})})]})})})]})}return c}(),i=function(m,l){var u=(0,o.useBackend)(l),s=u.act,d=u.data,v=d.max_length,g=d.multiline,C=m.input,f=m.onType,N=g||C.length>=40;return(0,e.createComponentVNode)(2,b.TextArea,{autoFocus:!0,autoSelect:!0,height:g||C.length>=40?"100%":"1.8rem",maxLength:v,onEscape:function(){function V(){return s("cancel")}return V}(),onEnter:function(){function V(B){N&&B.shiftKey||(B.preventDefault(),s("submit",{entry:C}))}return V}(),onInput:function(){function V(B,I){return f(I)}return V}(),placeholder:"Type something...",value:C})}},25036:function(T,r,n){"use strict";r.__esModule=!0,r.ThermoMachine=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.ThermoMachine=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.act,c=h.data;return(0,e.createComponentVNode)(2,p.Window,{width:300,height:225,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:[(0,e.createComponentVNode)(2,o.Section,{title:"Status",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Temperature",children:[(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:c.temperature,format:function(){function m(l){return(0,a.toFixed)(l,2)}return m}()})," K"]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Pressure",children:[(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:c.pressure,format:function(){function m(l){return(0,a.toFixed)(l,2)}return m}()})," kPa"]})]})}),(0,e.createComponentVNode)(2,o.Section,{title:"Controls",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:c.on?"power-off":"times",content:c.on?"On":"Off",selected:c.on,onClick:function(){function m(){return i("power")}return m}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Setting",textAlign:"center",children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,icon:c.cooling?"temperature-low":"temperature-high",content:c.cooling?"Cooling":"Heating",selected:c.cooling,onClick:function(){function m(){return i("cooling")}return m}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Target Temperature",children:[(0,e.createComponentVNode)(2,o.Button,{icon:"fast-backward",disabled:c.target===c.min,title:"Minimum temperature",onClick:function(){function m(){return i("target",{target:c.min})}return m}()}),(0,e.createComponentVNode)(2,o.NumberInput,{animated:!0,value:Math.round(c.target),unit:"K",width:5.4,lineHeight:1.4,minValue:Math.round(c.min),maxValue:Math.round(c.max),step:5,stepPixelSize:3,onDrag:function(){function m(l,u){return i("target",{target:u})}return m}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"fast-forward",disabled:c.target===c.max,title:"Maximum Temperature",onClick:function(){function m(){return i("target",{target:c.max})}return m}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"sync",disabled:c.target===c.initial,title:"Room Temperature",onClick:function(){function m(){return i("target",{target:c.initial})}return m}()})]})]})})]})})}return y}()},20035:function(T,r,n){"use strict";r.__esModule=!0,r.TransferValve=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TransferValve=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.tank_one,m=i.tank_two,l=i.attached_device,u=i.valve;return(0,e.createComponentVNode)(2,o.Window,{width:460,height:285,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Valve Status",children:(0,e.createComponentVNode)(2,t.Button,{icon:u?"unlock":"lock",content:u?"Open":"Closed",disabled:!c||!m,onClick:function(){function s(){return h("toggle")}return s}()})})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Assembly",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"cog",content:"Configure Assembly",disabled:!l,onClick:function(){function s(){return h("device")}return s}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Attachment",children:l?(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:l,disabled:!l,onClick:function(){function s(){return h("remove_device")}return s}()}):(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"No Assembly"})})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Attachment One",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Attachment",children:c?(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:c,disabled:!c,onClick:function(){function s(){return h("tankone")}return s}()}):(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"No Tank"})})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Attachment Two",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Attachment",children:m?(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:m,disabled:!m,onClick:function(){function s(){return h("tanktwo")}return s}()}):(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"No Tank"})})})})]})})}return b}()},78166:function(T,r,n){"use strict";r.__esModule=!0,r.TurbineComputer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(44879),b=r.TurbineComputer=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.compressor,s=l.compressor_broken,d=l.turbine,v=l.turbine_broken,g=l.online,C=!!(u&&!s&&d&&!v);return(0,e.createComponentVNode)(2,o.Window,{width:400,height:200,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Status",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:g?"power-off":"times",content:g?"Online":"Offline",selected:g,disabled:!C,onClick:function(){function f(){return m("toggle_power")}return f}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Disconnect",onClick:function(){function f(){return m("disconnect")}return f}()})],4),children:C?(0,e.createComponentVNode)(2,S):(0,e.createComponentVNode)(2,y)})})})}return k}(),y=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.compressor,u=m.compressor_broken,s=m.turbine,d=m.turbine_broken,v=m.online;return(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Compressor Status",color:!l||u?"bad":"good",children:u?l?"Offline":"Missing":"Online"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Turbine Status",color:!s||d?"bad":"good",children:d?s?"Offline":"Missing":"Online"})]})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.rpm,u=m.temperature,s=m.power,d=m.bearing_heat;return(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Turbine Speed",children:[l," RPM"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Internal Temp",children:[u," K"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Generated Power",children:[s," W"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Bearing Heat",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:d,minValue:0,maxValue:100,ranges:{good:[-1/0,60],average:[60,90],bad:[90,1/0]},children:(0,p.toFixed)(d)+"%"})})]})}},52847:function(T,r,n){"use strict";r.__esModule=!0,r.Uplink=void 0;var e=n(89005),a=n(88510),t=n(64795),o=n(25328),p=n(72253),b=n(36036),y=n(98595),S=n(3939),k=function(g){switch(g){case 0:return(0,e.createComponentVNode)(2,i);case 1:return(0,e.createComponentVNode)(2,c);case 2:return(0,e.createComponentVNode)(2,d);default:return"SOMETHING WENT VERY WRONG PLEASE AHELP"}},h=r.Uplink=function(){function v(g,C){var f=(0,p.useBackend)(C),N=f.act,V=f.data,B=V.cart,I=(0,p.useLocalState)(C,"tabIndex",0),L=I[0],w=I[1],A=(0,p.useLocalState)(C,"searchText",""),x=A[0],E=A[1];return(0,e.createComponentVNode)(2,y.Window,{width:900,height:600,theme:"syndicate",children:[(0,e.createComponentVNode)(2,S.ComplexModal),(0,e.createComponentVNode)(2,y.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Tabs,{children:[(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:L===0,onClick:function(){function P(){w(0),E("")}return P}(),icon:"store",children:"View Market"},"PurchasePage"),(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:L===1,onClick:function(){function P(){w(1),E("")}return P}(),icon:"shopping-cart",children:["View Shopping Cart ",B&&B.length?"("+B.length+")":""]},"Cart"),(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:L===2,onClick:function(){function P(){w(2),E("")}return P}(),icon:"user",children:"Exploitable Information"},"ExploitableInfo"),(0,e.createComponentVNode)(2,b.Tabs.Tab,{onClick:function(){function P(){return N("lock")}return P}(),icon:"lock",children:"Lock Uplink"},"LockUplink")]})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:k(L)})]})})]})}return v}(),i=function(g,C){var f=(0,p.useBackend)(C),N=f.act,V=f.data,B=V.crystals,I=V.cats,L=(0,p.useLocalState)(C,"uplinkItems",I[0].items),w=L[0],A=L[1],x=(0,p.useLocalState)(C,"searchText",""),E=x[0],P=x[1],D=function(U,z){z===void 0&&(z="");var $=(0,o.createSearch)(z,function(G){var X=G.hijack_only===1?"|hijack":"";return G.name+"|"+G.desc+"|"+G.cost+"tc"+X});return(0,t.flow)([(0,a.filter)(function(G){return G==null?void 0:G.name}),z&&(0,a.filter)($),(0,a.sortBy)(function(G){return G==null?void 0:G.name})])(U)},M=function(U){if(P(U),U==="")return A(I[0].items);A(D(I.map(function(z){return z.items}).flat(),U))},O=(0,p.useLocalState)(C,"showDesc",1),R=O[0],F=O[1];return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack,{vertical:!0,children:(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Section,{title:"Current Balance: "+B+"TC",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,b.Button.Checkbox,{content:"Show Descriptions",checked:R,onClick:function(){function W(){return F(!R)}return W}()}),(0,e.createComponentVNode)(2,b.Button,{content:"Random Item",icon:"question",onClick:function(){function W(){return N("buyRandom")}return W}()}),(0,e.createComponentVNode)(2,b.Button,{content:"Refund Currently Held Item",icon:"undo",onClick:function(){function W(){return N("refund")}return W}()})],4),children:(0,e.createComponentVNode)(2,b.Input,{fluid:!0,placeholder:"Search Equipment",onInput:function(){function W(U,z){M(z)}return W}(),value:E})})})}),(0,e.createComponentVNode)(2,b.Stack,{fill:!0,mt:.3,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,b.Tabs,{vertical:!0,children:I.map(function(W){return(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:E!==""?!1:W.items===w,onClick:function(){function U(){A(W.items),P("")}return U}(),children:W.cat},W)})})})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,b.Stack,{vertical:!0,children:w.map(function(W){return(0,e.createComponentVNode)(2,b.Stack.Item,{p:1,backgroundColor:"rgba(255, 0, 0, 0.1)",children:(0,e.createComponentVNode)(2,l,{i:W,showDecription:R},(0,o.decodeHtmlEntities)(W.name))},(0,o.decodeHtmlEntities)(W.name))})})})})]})]})},c=function(g,C){var f=(0,p.useBackend)(C),N=f.act,V=f.data,B=V.cart,I=V.crystals,L=V.cart_price,w=(0,p.useLocalState)(C,"showDesc",0),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Current Balance: "+I+"TC",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,b.Button.Checkbox,{content:"Show Descriptions",checked:A,onClick:function(){function E(){return x(!A)}return E}()}),(0,e.createComponentVNode)(2,b.Button,{content:"Empty Cart",icon:"trash",onClick:function(){function E(){return N("empty_cart")}return E}(),disabled:!B}),(0,e.createComponentVNode)(2,b.Button,{content:"Purchase Cart ("+L+"TC)",icon:"shopping-cart",onClick:function(){function E(){return N("purchase_cart")}return E}(),disabled:!B||L>I})],4),children:(0,e.createComponentVNode)(2,b.Stack,{vertical:!0,children:B?B.map(function(E){return(0,e.createComponentVNode)(2,b.Stack.Item,{p:1,mr:1,backgroundColor:"rgba(255, 0, 0, 0.1)",children:(0,e.createComponentVNode)(2,l,{i:E,showDecription:A,buttons:(0,e.createComponentVNode)(2,s,{i:E})})},(0,o.decodeHtmlEntities)(E.name))}):(0,e.createComponentVNode)(2,b.Box,{italic:!0,children:"Your Shopping Cart is empty!"})})})}),(0,e.createComponentVNode)(2,m)]})},m=function(g,C){var f=(0,p.useBackend)(C),N=f.act,V=f.data,B=V.cats,I=V.lucky_numbers;return(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Suggested Purchases",buttons:(0,e.createComponentVNode)(2,b.Button,{icon:"dice",content:"See more suggestions",onClick:function(){function L(){return N("shuffle_lucky_numbers")}return L}()}),children:(0,e.createComponentVNode)(2,b.Stack,{wrap:!0,children:I.map(function(L){return B[L.cat].items[L.item]}).filter(function(L){return L!=null}).map(function(L,w){return(0,e.createComponentVNode)(2,b.Stack.Item,{p:1,mb:1,ml:1,width:34,backgroundColor:"rgba(255, 0, 0, 0.15)",children:(0,e.createComponentVNode)(2,l,{grow:!0,i:L})},w)})})})})},l=function(g,C){var f=g.i,N=g.showDecription,V=N===void 0?1:N,B=g.buttons,I=B===void 0?(0,e.createComponentVNode)(2,u,{i:f}):B;return(0,e.createComponentVNode)(2,b.Section,{title:(0,o.decodeHtmlEntities)(f.name),showBottom:V,buttons:I,children:V?(0,e.createComponentVNode)(2,b.Box,{italic:!0,children:(0,o.decodeHtmlEntities)(f.desc)}):null})},u=function(g,C){var f=(0,p.useBackend)(C),N=f.act,V=f.data,B=g.i,I=V.crystals;return(0,e.createFragment)([(0,e.createComponentVNode)(2,b.Button,{icon:"shopping-cart",color:B.hijack_only===1&&"red",tooltip:"Add to cart.",tooltipPosition:"left",onClick:function(){function L(){return N("add_to_cart",{item:B.obj_path})}return L}(),disabled:B.cost>I}),(0,e.createComponentVNode)(2,b.Button,{content:"Buy ("+B.cost+"TC)"+(B.refundable?" [Refundable]":""),color:B.hijack_only===1&&"red",tooltip:B.hijack_only===1&&"Hijack Agents Only!",tooltipPosition:"left",onClick:function(){function L(){return N("buyItem",{item:B.obj_path})}return L}(),disabled:B.cost>I})],4)},s=function(g,C){var f=(0,p.useBackend)(C),N=f.act,V=f.data,B=g.i,I=V.exploitable;return(0,e.createComponentVNode)(2,b.Stack,{children:[(0,e.createComponentVNode)(2,b.Button,{icon:"times",content:"("+B.cost*B.amount+"TC)",tooltip:"Remove from cart.",tooltipPosition:"left",onClick:function(){function L(){return N("remove_from_cart",{item:B.obj_path})}return L}()}),(0,e.createComponentVNode)(2,b.Button,{icon:"minus",tooltip:B.limit===0&&"Discount already redeemed!",ml:"5px",onClick:function(){function L(){return N("set_cart_item_quantity",{item:B.obj_path,quantity:--B.amount})}return L}(),disabled:B.amount<=0}),(0,e.createComponentVNode)(2,b.Button.Input,{content:B.amount,width:"45px",tooltipPosition:"bottom-end",tooltip:B.limit===0&&"Discount already redeemed!",onCommit:function(){function L(w,A){return N("set_cart_item_quantity",{item:B.obj_path,quantity:A})}return L}(),disabled:B.limit!==-1&&B.amount>=B.limit&&B.amount<=0}),(0,e.createComponentVNode)(2,b.Button,{mb:.3,icon:"plus",tooltipPosition:"bottom-start",tooltip:B.limit===0&&"Discount already redeemed!",onClick:function(){function L(){return N("set_cart_item_quantity",{item:B.obj_path,quantity:++B.amount})}return L}(),disabled:B.limit!==-1&&B.amount>=B.limit})]})},d=function(g,C){var f=(0,p.useBackend)(C),N=f.act,V=f.data,B=V.exploitable,I=(0,p.useLocalState)(C,"selectedRecord",B[0]),L=I[0],w=I[1],A=(0,p.useLocalState)(C,"searchText",""),x=A[0],E=A[1],P=function(O,R){R===void 0&&(R="");var F=(0,o.createSearch)(R,function(W){return W.name});return(0,t.flow)([(0,a.filter)(function(W){return W==null?void 0:W.name}),R&&(0,a.filter)(F),(0,a.sortBy)(function(W){return W.name})])(O)},D=P(B,x);return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Exploitable Records",children:[(0,e.createComponentVNode)(2,b.Input,{fluid:!0,mb:1,placeholder:"Search Crew",onInput:function(){function M(O,R){return E(R)}return M}()}),(0,e.createComponentVNode)(2,b.Tabs,{vertical:!0,children:D.map(function(M){return(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:M===L,onClick:function(){function O(){return w(M)}return O}(),children:M.name},M)})})]})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:L.name,children:(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Age",children:L.age}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Fingerprint",children:L.fingerprint}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Rank",children:L.rank}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Sex",children:L.sex}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Species",children:L.species})]})})})]})}},12261:function(T,r,n){"use strict";r.__esModule=!0,r.Vending=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=S.product,l=S.productStock,u=S.productIcon,s=S.productIconState,d=c.chargesMoney,v=c.user,g=c.usermoney,C=c.inserted_cash,f=c.vend_ready,N=c.inserted_item_name,V=!d||m.price===0,B="ERROR!",I="";V?(B="FREE",I="arrow-circle-down"):(B=m.price,I="shopping-cart");var L=!f||l===0||!V&&m.price>g&&m.price>C;return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,children:(0,e.createComponentVNode)(2,t.DmIcon,{verticalAlign:"middle",icon:u,icon_state:s,fallback:(0,e.createComponentVNode)(2,t.Icon,{p:.66,name:"spinner",size:2,spin:!0})})}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:m.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Box,{color:l<=0&&"bad"||l<=m.max_amount/2&&"average"||"good",children:[l," in stock"]})}),(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,disabled:L,icon:I,content:B,textAlign:"left",onClick:function(){function w(){return i("vend",{inum:m.inum})}return w}()})})]})},b=r.Vending=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.user,l=c.usermoney,u=c.inserted_cash,s=c.chargesMoney,d=c.product_records,v=d===void 0?[]:d,g=c.hidden_records,C=g===void 0?[]:g,f=c.stock,N=c.vend_ready,V=c.inserted_item_name,B=c.panel_open,I=c.speaker,L;return L=[].concat(v),c.extended_inventory&&(L=[].concat(L,C)),L=L.filter(function(w){return!!w}),(0,e.createComponentVNode)(2,o.Window,{title:"Vending Machine",width:450,height:Math.min((s?171:89)+L.length*32,585),children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[!!s&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"User",buttons:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:!!V&&(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"eject",content:(0,e.createVNode)(1,"span",null,V,0,{style:{"text-transform":"capitalize"}}),onClick:function(){function w(){return i("eject_item",{})}return w}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{disabled:!u,icon:"money-bill-wave-alt",content:u?(0,e.createFragment)([(0,e.createVNode)(1,"b",null,u,0),(0,e.createTextVNode)(" credits")],0):"Dispense Change",tooltip:u?"Dispense Change":null,textAlign:"left",onClick:function(){function w(){return i("change")}return w}()})})]}),children:m&&(0,e.createComponentVNode)(2,t.Box,{children:["Welcome, ",(0,e.createVNode)(1,"b",null,m.name,0),", ",(0,e.createVNode)(1,"b",null,m.job||"Unemployed",0),"!",(0,e.createVNode)(1,"br"),"Your balance is ",(0,e.createVNode)(1,"b",null,[l,(0,e.createTextVNode)(" credits")],0),".",(0,e.createVNode)(1,"br")]})})}),!!B&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Maintenance",children:(0,e.createComponentVNode)(2,t.Button,{icon:I?"check":"volume-mute",selected:I,content:"Speaker",textAlign:"left",onClick:function(){function w(){return i("toggle_voice",{})}return w}()})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Products",children:(0,e.createComponentVNode)(2,t.Table,{children:L.map(function(w){return(0,e.createComponentVNode)(2,p,{product:w,productStock:f[w.name],productIcon:w.icon,productIconState:w.icon_state},w.name)})})})})]})})})}return y}()},68971:function(T,r,n){"use strict";r.__esModule=!0,r.VolumeMixer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.VolumeMixer=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.channels;return(0,e.createComponentVNode)(2,o.Window,{width:350,height:Math.min(95+c.length*50,565),children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:c.map(function(m,l){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.25rem",color:"label",mt:l>0&&"0.5rem",children:m.name}),(0,e.createComponentVNode)(2,t.Box,{mt:"0.5rem",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{mr:.5,children:(0,e.createComponentVNode)(2,t.Button,{width:"24px",color:"transparent",children:(0,e.createComponentVNode)(2,t.Icon,{name:"volume-off",size:"1.5",mt:"0.1rem",onClick:function(){function u(){return h("volume",{channel:m.num,volume:0})}return u}()})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,mx:"0.5rem",children:(0,e.createComponentVNode)(2,t.Slider,{minValue:0,maxValue:100,stepPixelSize:3.13,value:m.volume,onChange:function(){function u(s,d){return h("volume",{channel:m.num,volume:d})}return u}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{width:"24px",color:"transparent",children:(0,e.createComponentVNode)(2,t.Icon,{name:"volume-up",size:"1.5",mt:"0.1rem",onClick:function(){function u(){return h("volume",{channel:m.num,volume:100})}return u}()})})})]})})],4,m.num)})})})})}return b}()},2510:function(T,r,n){"use strict";r.__esModule=!0,r.VotePanel=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.VotePanel=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.remaining,m=i.question,l=i.choices,u=i.user_vote,s=i.counts,d=i.show_counts;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:360,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:m,children:[(0,e.createComponentVNode)(2,t.Box,{mb:1.5,ml:.5,children:["Time remaining: ",Math.round(c/10),"s"]}),l.map(function(v){return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{mb:1,fluid:!0,translucent:!0,lineHeight:3,multiLine:v,content:v+(d?" ("+(s[v]||0)+")":""),onClick:function(){function g(){return h("vote",{target:v})}return g}(),selected:v===u})},v)})]})})})}return b}()},30138:function(T,r,n){"use strict";r.__esModule=!0,r.Wires=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Wires=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.wires||[],m=i.status||[],l=56+c.length*23+(status?0:15+m.length*17);return(0,e.createComponentVNode)(2,o.Window,{width:350,height:l,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:c.map(function(u){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{className:"candystripe",label:u.color_name,labelColor:u.seen_color,color:u.seen_color,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:u.cut?"Mend":"Cut",onClick:function(){function s(){return h("cut",{wire:u.color})}return s}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Pulse",onClick:function(){function s(){return h("pulse",{wire:u.color})}return s}()}),(0,e.createComponentVNode)(2,t.Button,{content:u.attached?"Detach":"Attach",onClick:function(){function s(){return h("attach",{wire:u.color})}return s}()})],4),children:!!u.wire&&(0,e.createVNode)(1,"i",null,[(0,e.createTextVNode)("("),u.wire,(0,e.createTextVNode)(")")],0)},u.seen_color)})})})}),!!m.length&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{children:m.map(function(u){return(0,e.createComponentVNode)(2,t.Box,{color:"lightgray",children:u},u)})})})]})})})}return b}()},21400:function(T,r,n){"use strict";r.__esModule=!0,r.WizardApprenticeContract=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.WizardApprenticeContract=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.used;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:555,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Contract of Apprenticeship",children:["Using this contract, you may summon an apprentice to aid you on your mission.",(0,e.createVNode)(1,"p",null,"If you are unable to establish contact with your apprentice, you can feed the contract back to the spellbook to refund your points.",16),c?(0,e.createComponentVNode)(2,t.Box,{bold:!0,color:"red",children:"You've already summoned an apprentice or you are in process of summoning one."}):""]}),(0,e.createComponentVNode)(2,t.Section,{title:"Which school of magic is your apprentice studying?",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fire",children:["Your apprentice is skilled in bending fire. ",(0,e.createVNode)(1,"br"),"They know Fireball, Sacred Flame, and Ethereal Jaunt.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("fire")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Translocation",children:["Your apprentice is able to defy physics, learning how to move through bluespace. ",(0,e.createVNode)(1,"br"),"They know Teleport, Blink and Ethereal Jaunt.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("translocation")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Restoration",children:["Your apprentice is dedicated to supporting your magical prowess.",(0,e.createVNode)(1,"br"),"They come equipped with a Staff of Healing, have the unique ability to teleport back to you, and know Charge and Knock.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("restoration")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Stealth",children:["Your apprentice is learning the art of infiltrating mundane facilities. ",(0,e.createVNode)(1,"br"),"They know Mindswap, Knock, Homing Toolbox, and Disguise Self, all of which can be cast without robes. They also join you in a Maintenance Dweller disguise, complete with Gloves of Shock Immunity and a Belt of Tools.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("stealth")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Honk",children:["Your apprentice is here to spread the Honkmother's blessings.",(0,e.createVNode)(1,"br"),"They know Banana Touch, Instant Summons, Ethereal Jaunt, and come equipped with a Staff of Slipping."," ",(0,e.createVNode)(1,"br"),"While under your tutelage, they have been 'blessed' with clown shoes that are impossible to remove.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("honk")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider)]})})]})})}return b}()},49148:function(T,r,n){"use strict";r.__esModule=!0,r.AccessList=void 0;var e=n(89005),a=n(88510),t=n(72253),o=n(36036);function p(h,i){var c=typeof Symbol!="undefined"&&h[Symbol.iterator]||h["@@iterator"];if(c)return(c=c.call(h)).next.bind(c);if(Array.isArray(h)||(c=b(h))||i&&h&&typeof h.length=="number"){c&&(h=c);var m=0;return function(){return m>=h.length?{done:!0}:{done:!1,value:h[m++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function b(h,i){if(h){if(typeof h=="string")return y(h,i);var c={}.toString.call(h).slice(8,-1);return c==="Object"&&h.constructor&&(c=h.constructor.name),c==="Map"||c==="Set"?Array.from(h):c==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(c)?y(h,i):void 0}}function y(h,i){(i==null||i>h.length)&&(i=h.length);for(var c=0,m=Array(i);c0&&!V.includes(R.ref)&&!f.includes(R.ref),checked:f.includes(R.ref),onClick:function(){function F(){return B(R.ref)}return F}()},R.desc)})]})]})})}return h}()},26991:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosScan=void 0;var e=n(89005),a=n(88510),t=n(72253),o=n(36036),p=function(S,k,h,i,c){return Si?"average":S>c?"bad":"good"},b=r.AtmosScan=function(){function y(S,k){var h=S.data.aircontents;return(0,e.createComponentVNode)(2,o.Box,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,a.filter)(function(i){return i.val!=="0"||i.entry==="Pressure"||i.entry==="Temperature"})(h).map(function(i){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:i.entry,color:p(i.val,i.bad_low,i.poor_low,i.poor_high,i.bad_high),children:[i.val,i.units]},i.entry)})})})}return y}()},85870:function(T,r,n){"use strict";r.__esModule=!0,r.BeakerContents=void 0;var e=n(89005),a=n(36036),t=n(15964),o=function(y){return y+" unit"+(y===1?"":"s")},p=r.BeakerContents=function(){function b(y){var S=y.beakerLoaded,k=y.beakerContents,h=k===void 0?[]:k,i=y.buttons;return(0,e.createComponentVNode)(2,a.Stack,{vertical:!0,children:[!S&&(0,e.createComponentVNode)(2,a.Stack.Item,{color:"label",children:"No beaker loaded."})||h.length===0&&(0,e.createComponentVNode)(2,a.Stack.Item,{color:"label",children:"Beaker is empty."}),h.map(function(c,m){return(0,e.createComponentVNode)(2,a.Stack,{children:[(0,e.createComponentVNode)(2,a.Stack.Item,{color:"label",grow:!0,children:[o(c.volume)," of ",c.name]},c.name),!!i&&(0,e.createComponentVNode)(2,a.Stack.Item,{children:i(c,m)})]},c.name)})]})}return b}();p.propTypes={beakerLoaded:t.bool,beakerContents:t.array,buttons:t.arrayOf(t.element)}},92963:function(T,r,n){"use strict";r.__esModule=!0,r.BotStatus=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.BotStatus=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.locked,c=h.noaccess,m=h.maintpanel,l=h.on,u=h.autopatrol,s=h.canhack,d=h.emagged,v=h.remote_disabled;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.NoticeBox,{children:["Swipe an ID card to ",i?"unlock":"lock"," this interface."]}),(0,e.createComponentVNode)(2,t.Section,{title:"General Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:(0,e.createComponentVNode)(2,t.Button,{icon:l?"power-off":"times",content:l?"On":"Off",selected:l,disabled:c,onClick:function(){function g(){return k("power")}return g}()})}),u!==null&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Patrol",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:u,content:"Auto Patrol",disabled:c,onClick:function(){function g(){return k("autopatrol")}return g}()})}),!!m&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Maintenance Panel",children:(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"Panel Open!"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Safety System",children:(0,e.createComponentVNode)(2,t.Box,{color:d?"bad":"good",children:d?"DISABLED!":"Enabled"})}),!!s&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hacking",children:(0,e.createComponentVNode)(2,t.Button,{icon:"terminal",content:d?"Restore Safties":"Hack",disabled:c,color:"bad",onClick:function(){function g(){return k("hack")}return g}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Remote Access",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:!v,content:"AI Remote Control",disabled:c,onClick:function(){function g(){return k("disableremote")}return g}()})})]})})],4)}return p}()},3939:function(T,r,n){"use strict";r.__esModule=!0,r.modalRegisterBodyOverride=r.modalOpen=r.modalClose=r.modalAnswer=r.ComplexModal=void 0;var e=n(89005),a=n(72253),t=n(36036),o={},p=r.modalOpen=function(){function h(i,c,m){var l=(0,a.useBackend)(i),u=l.act,s=l.data,d=Object.assign(s.modal?s.modal.args:{},m||{});u("modal_open",{id:c,arguments:JSON.stringify(d)})}return h}(),b=r.modalRegisterBodyOverride=function(){function h(i,c){o[i]=c}return h}(),y=r.modalAnswer=function(){function h(i,c,m,l){var u=(0,a.useBackend)(i),s=u.act,d=u.data;if(d.modal){var v=Object.assign(d.modal.args||{},l||{});s("modal_answer",{id:c,answer:m,arguments:JSON.stringify(v)})}}return h}(),S=r.modalClose=function(){function h(i,c){var m=(0,a.useBackend)(i),l=m.act;l("modal_close",{id:c})}return h}(),k=r.ComplexModal=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.data;if(l.modal){var u=l.modal,s=u.id,d=u.text,v=u.type,g,C=(0,e.createComponentVNode)(2,t.Button,{className:"Button--modal",icon:"arrow-left",content:"Cancel",onClick:function(){function L(){return S(c)}return L}()}),f,N,V="auto";if(o[s])f=o[s](l.modal,c);else if(v==="input"){var B=l.modal.value;g=function(){function L(w){return y(c,s,B)}return L}(),f=(0,e.createComponentVNode)(2,t.Input,{value:l.modal.value,placeholder:"ENTER to submit",width:"100%",my:"0.5rem",autofocus:!0,onChange:function(){function L(w,A){B=A}return L}()}),N=(0,e.createComponentVNode)(2,t.Box,{mt:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-left",content:"Cancel",color:"grey",onClick:function(){function L(){return S(c)}return L}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"check",content:"Confirm",color:"good",float:"right",m:"0",onClick:function(){function L(){return y(c,s,B)}return L}()}),(0,e.createComponentVNode)(2,t.Box,{clear:"both"})]})}else if(v==="choice"){var I=typeof l.modal.choices=="object"?Object.values(l.modal.choices):l.modal.choices;f=(0,e.createComponentVNode)(2,t.Dropdown,{options:I,selected:l.modal.value,width:"100%",my:"0.5rem",onSelected:function(){function L(w){return y(c,s,w)}return L}()}),V="initial"}else v==="bento"?f=(0,e.createComponentVNode)(2,t.Stack,{spacingPrecise:"1",wrap:"wrap",my:"0.5rem",maxHeight:"1%",children:l.modal.choices.map(function(L,w){return(0,e.createComponentVNode)(2,t.Stack.Item,{flex:"1 1 auto",children:(0,e.createComponentVNode)(2,t.Button,{selected:w+1===parseInt(l.modal.value,10),onClick:function(){function A(){return y(c,s,w+1)}return A}(),children:(0,e.createVNode)(1,"img",null,null,1,{src:L})})},w)})}):v==="boolean"&&(N=(0,e.createComponentVNode)(2,t.Box,{mt:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:l.modal.no_text,color:"bad",float:"left",mb:"0",onClick:function(){function L(){return y(c,s,0)}return L}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"check",content:l.modal.yes_text,color:"good",float:"right",m:"0",onClick:function(){function L(){return y(c,s,1)}return L}()}),(0,e.createComponentVNode)(2,t.Box,{clear:"both"})]}));return(0,e.createComponentVNode)(2,t.Modal,{maxWidth:i.maxWidth||window.innerWidth/2+"px",maxHeight:i.maxHeight||window.innerHeight/2+"px",onEnter:g,mx:"auto",overflowY:V,"padding-bottom":"5px",children:[d&&(0,e.createComponentVNode)(2,t.Box,{inline:!0,children:d}),o[s]&&C,f,N]})}}return h}()},41874:function(T,r,n){"use strict";r.__esModule=!0,r.CrewManifest=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(25328),p=n(76910),b=p.COLORS.department,y=["Captain","Head of Security","Chief Engineer","Chief Medical Officer","Research Director","Head of Personnel","Quartermaster"],S=function(m){return y.indexOf(m)!==-1?"green":"orange"},k=function(m){if(y.indexOf(m)!==-1)return!0},h=function(m){return m.length>0&&(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,color:"white",children:[(0,e.createComponentVNode)(2,t.Table.Cell,{width:"50%",children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"35%",children:"Rank"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"15%",children:"Active"})]}),m.map(function(l){return(0,e.createComponentVNode)(2,t.Table.Row,{color:S(l.rank),bold:k(l.rank),children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,o.decodeHtmlEntities)(l.name)}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,o.decodeHtmlEntities)(l.rank)}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:l.active})]},l.name+l.rank)})]})},i=r.CrewManifest=function(){function c(m,l){var u=(0,a.useBackend)(l),s=u.act,d;if(m.data)d=m.data;else{var v=(0,a.useBackend)(l),g=v.data;d=g}var C=d,f=C.manifest,N=f.heads,V=f.sec,B=f.eng,I=f.med,L=f.sci,w=f.ser,A=f.sup,x=f.misc;return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.command,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Command"})}),level:2,children:h(N)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.security,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Security"})}),level:2,children:h(V)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.engineering,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Engineering"})}),level:2,children:h(B)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.medical,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Medical"})}),level:2,children:h(I)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.science,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Science"})}),level:2,children:h(L)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.service,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Service"})}),level:2,children:h(w)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.supply,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Supply"})}),level:2,children:h(A)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Misc"})}),level:2,children:h(x)})]})}return c}()},19203:function(T,r,n){"use strict";r.__esModule=!0,r.InputButtons=void 0;var e=n(89005),a=n(36036),t=n(72253),o=r.InputButtons=function(){function p(b,y){var S=(0,t.useBackend)(y),k=S.act,h=S.data,i=h.large_buttons,c=h.swapped_buttons,m=b.input,l=b.message,u=b.disabled,s=(0,e.createComponentVNode)(2,a.Button,{color:"good",content:"Submit",bold:!!i,fluid:!!i,onClick:function(){function v(){return k("submit",{entry:m})}return v}(),textAlign:"center",tooltip:i&&l,disabled:u,width:!i&&6}),d=(0,e.createComponentVNode)(2,a.Button,{color:"bad",content:"Cancel",bold:!!i,fluid:!!i,onClick:function(){function v(){return k("cancel")}return v}(),textAlign:"center",width:!i&&6});return(0,e.createComponentVNode)(2,a.Flex,{fill:!0,align:"center",direction:c?"row-reverse":"row",justify:"space-around",children:[i?(0,e.createComponentVNode)(2,a.Flex.Item,{grow:!0,ml:c?.5:0,mr:c?0:.5,children:d}):(0,e.createComponentVNode)(2,a.Flex.Item,{children:d}),!i&&l&&(0,e.createComponentVNode)(2,a.Flex.Item,{children:(0,e.createComponentVNode)(2,a.Box,{color:"label",textAlign:"center",children:l})}),i?(0,e.createComponentVNode)(2,a.Flex.Item,{grow:!0,mr:c?.5:0,ml:c?0:.5,children:s}):(0,e.createComponentVNode)(2,a.Flex.Item,{children:s})]})}return p}()},195:function(T,r,n){"use strict";r.__esModule=!0,r.InterfaceLockNoticeBox=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.InterfaceLockNoticeBox=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=b.siliconUser,c=i===void 0?h.siliconUser:i,m=b.locked,l=m===void 0?h.locked:m,u=b.normallyLocked,s=u===void 0?h.normallyLocked:u,d=b.onLockStatusChange,v=d===void 0?function(){return k("lock")}:d,g=b.accessText,C=g===void 0?"an ID card":g;return c?(0,e.createComponentVNode)(2,t.NoticeBox,{color:c&&"grey",children:(0,e.createComponentVNode)(2,t.Flex,{align:"center",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{children:"Interface lock status:"}),(0,e.createComponentVNode)(2,t.Flex.Item,{grow:"1"}),(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Button,{m:"0",color:s?"red":"green",icon:s?"lock":"unlock",content:s?"Locked":"Unlocked",onClick:function(){function f(){v&&v(!l)}return f}()})})]})}):(0,e.createComponentVNode)(2,t.NoticeBox,{children:["Swipe ",C," to ",l?"unlock":"lock"," this interface."]})}return p}()},51057:function(T,r,n){"use strict";r.__esModule=!0,r.Loader=void 0;var e=n(89005),a=n(44879),t=n(36036),o=r.Loader=function(){function p(b){var y=b.value;return(0,e.createVNode)(1,"div","AlertModal__Loader",(0,e.createComponentVNode)(2,t.Box,{className:"AlertModal__LoaderProgress",style:{width:(0,a.clamp01)(y)*100+"%"}}),2)}return p}()},321:function(T,r,n){"use strict";r.__esModule=!0,r.LoginInfo=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LoginInfo=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.loginState;if(h)return(0,e.createComponentVNode)(2,t.NoticeBox,{info:!0,children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,mt:.5,children:["Logged in as: ",i.name," (",i.rank,")"]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"eject",disabled:!i.id,content:"Eject ID",color:"good",onClick:function(){function c(){return k("login_eject")}return c}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-out-alt",content:"Logout",color:"good",onClick:function(){function c(){return k("login_logout")}return c}()})]})]})})}return p}()},5485:function(T,r,n){"use strict";r.__esModule=!0,r.LoginScreen=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LoginScreen=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.loginState,c=h.isAI,m=h.isRobot,l=h.isAdmin;return(0,e.createComponentVNode)(2,t.Section,{title:"Welcome",fill:!0,stretchContents:!0,children:(0,e.createComponentVNode)(2,t.Flex,{height:"100%",align:"center",justify:"center",children:(0,e.createComponentVNode)(2,t.Flex.Item,{textAlign:"center",mt:"-2rem",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.5rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-circle",verticalAlign:"middle",size:3,mr:"1rem"}),"Guest"]}),(0,e.createComponentVNode)(2,t.Box,{color:"label",my:"1rem",children:["ID:",(0,e.createComponentVNode)(2,t.Button,{icon:"id-card",content:i.id?i.id:"----------",ml:"0.5rem",onClick:function(){function u(){return k("login_insert")}return u}()})]}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",disabled:!i.id,content:"Login",onClick:function(){function u(){return k("login_login",{login_type:1})}return u}()}),!!c&&(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"Login as AI",onClick:function(){function u(){return k("login_login",{login_type:2})}return u}()}),!!m&&(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"Login as Cyborg",onClick:function(){function u(){return k("login_login",{login_type:3})}return u}()}),!!l&&(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"CentComm Secure Login",onClick:function(){function u(){return k("login_login",{login_type:4})}return u}()})]})})})}return p}()},62411:function(T,r,n){"use strict";r.__esModule=!0,r.Operating=void 0;var e=n(89005),a=n(36036),t=n(15964),o=r.Operating=function(){function p(b){var y=b.operating,S=b.name;if(y)return(0,e.createComponentVNode)(2,a.Dimmer,{children:(0,e.createComponentVNode)(2,a.Flex,{mb:"30px",children:(0,e.createComponentVNode)(2,a.Flex.Item,{bold:!0,color:"silver",textAlign:"center",children:[(0,e.createComponentVNode)(2,a.Icon,{name:"spinner",spin:!0,size:4,mb:"15px"}),(0,e.createVNode)(1,"br"),"The ",S," is processing..."]})})})}return p}();o.propTypes={operating:t.bool,name:t.string}},13545:function(T,r,n){"use strict";r.__esModule=!0,r.Signaler=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=r.Signaler=function(){function b(y,S){var k=(0,t.useBackend)(S),h=k.act,i=y.data,c=i.code,m=i.frequency,l=i.minFrequency,u=i.maxFrequency;return(0,e.createComponentVNode)(2,o.Section,{children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Frequency",children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:.2,stepPixelSize:6,minValue:l/10,maxValue:u/10,value:m/10,format:function(){function s(d){return(0,a.toFixed)(d,1)}return s}(),width:"80px",onDrag:function(){function s(d,v){return h("freq",{freq:v})}return s}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Code",children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:1,stepPixelSize:6,minValue:1,maxValue:100,value:c,width:"80px",onDrag:function(){function s(d,v){return h("code",{code:v})}return s}()})})]}),(0,e.createComponentVNode)(2,o.Button,{mt:1,fluid:!0,icon:"arrow-up",content:"Send Signal",textAlign:"center",onClick:function(){function s(){return h("signal")}return s}()})]})}return b}()},41984:function(T,r,n){"use strict";r.__esModule=!0,r.SimpleRecords=void 0;var e=n(89005),a=n(72253),t=n(25328),o=n(64795),p=n(88510),b=n(36036),y=r.SimpleRecords=function(){function h(i,c){var m=i.data.records;return(0,e.createComponentVNode)(2,b.Box,{children:m?(0,e.createComponentVNode)(2,k,{data:i.data,recordType:i.recordType}):(0,e.createComponentVNode)(2,S,{data:i.data})})}return h}(),S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=i.data.recordsList,s=(0,a.useLocalState)(c,"searchText",""),d=s[0],v=s[1],g=function(N,V){V===void 0&&(V="");var B=(0,t.createSearch)(V,function(I){return I.Name});return(0,o.flow)([(0,p.filter)(function(I){return I==null?void 0:I.Name}),V&&(0,p.filter)(B),(0,p.sortBy)(function(I){return I.Name})])(u)},C=g(u,d);return(0,e.createComponentVNode)(2,b.Box,{children:[(0,e.createComponentVNode)(2,b.Input,{fluid:!0,mb:1,placeholder:"Search records...",onInput:function(){function f(N,V){return v(V)}return f}()}),C.map(function(f){return(0,e.createComponentVNode)(2,b.Box,{children:(0,e.createComponentVNode)(2,b.Button,{mb:.5,content:f.Name,icon:"user",onClick:function(){function N(){return l("Records",{target:f.uid})}return N}()})},f)})]})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=i.data.records,s=u.general,d=u.medical,v=u.security,g;switch(i.recordType){case"MED":g=(0,e.createComponentVNode)(2,b.Section,{level:2,title:"Medical Data",children:d?(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Blood Type",children:d.blood_type}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Minor Disabilities",children:d.mi_dis}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:d.mi_dis_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Major Disabilities",children:d.ma_dis}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:d.ma_dis_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Allergies",children:d.alg}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:d.alg_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Current Diseases",children:d.cdi}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:d.cdi_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Important Notes",preserveWhitespace:!0,children:d.notes})]}):(0,e.createComponentVNode)(2,b.Box,{color:"red",bold:!0,children:"Medical record lost!"})});break;case"SEC":g=(0,e.createComponentVNode)(2,b.Section,{level:2,title:"Security Data",children:v?(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Criminal Status",children:v.criminal}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Minor Crimes",children:v.mi_crim}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:v.mi_crim_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Major Crimes",children:v.ma_crim}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:v.ma_crim_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Important Notes",preserveWhitespace:!0,children:v.notes})]}):(0,e.createComponentVNode)(2,b.Box,{color:"red",bold:!0,children:"Security record lost!"})});break}return(0,e.createComponentVNode)(2,b.Box,{children:[(0,e.createComponentVNode)(2,b.Section,{title:"General Data",children:s?(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Name",children:s.name}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Sex",children:s.sex}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Species",children:s.species}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Age",children:s.age}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Rank",children:s.rank}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Fingerprint",children:s.fingerprint}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Physical Status",children:s.p_stat}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Mental Status",children:s.m_stat})]}):(0,e.createComponentVNode)(2,b.Box,{color:"red",bold:!0,children:"General record lost!"})}),g]})}},22091:function(T,r,n){"use strict";r.__esModule=!0,r.TemporaryNotice=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.TemporaryNotice=function(){function p(b,y){var S,k=(0,a.useBackend)(y),h=k.act,i=k.data,c=i.temp;if(c){var m=(S={},S[c.style]=!0,S);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.NoticeBox,Object.assign({},m,{children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,mt:.5,children:c.text}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"times-circle",onClick:function(){function l(){return h("cleartemp")}return l}()})})]})})))}}return p}()},95213:function(T,r,n){"use strict";r.__esModule=!0,r.goonstation_PTL=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(49968),p=n(98595);/**
+ */function m(w,A){w.prototype=Object.create(A.prototype),w.prototype.constructor=w,l(w,A)}function l(w,A){return l=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(x,E){return x.__proto__=E,x},l(w,A)}function u(w,A){if(w==null)return{};var x={};for(var E in w)if({}.hasOwnProperty.call(w,E)){if(A.includes(E))continue;x[E]=w[E]}return x}var s=r.ColorPickerModal=function(){function w(A,x){var E=(0,t.useBackend)(x),P=E.data,D=P.timeout,M=P.message,O=P.title,R=P.autofocus,F=P.default_color,W=F===void 0?"#000000":F,U=(0,t.useLocalState)(x,"color_picker_choice",(0,y.hexToHsva)(W)),z=U[0],$=U[1];return(0,e.createComponentVNode)(2,p.Window,{height:400,title:O,width:600,theme:"generic",children:[!!D&&(0,e.createComponentVNode)(2,a.Loader,{value:D}),(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[M&&(0,e.createComponentVNode)(2,o.Stack.Item,{m:1,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:(0,e.createComponentVNode)(2,o.Box,{color:"label",overflow:"hidden",children:M})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:[!!R&&(0,e.createComponentVNode)(2,o.Autofocus),(0,e.createComponentVNode)(2,d,{color:z,setColor:$,defaultColor:W})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,i.InputButtons,{input:(0,y.hsvaToHex)(z)})})]})})]})}return w}(),d=r.ColorSelector=function(){function w(A,x){var E=A.color,P=A.setColor,D=A.defaultColor,M=function(){function F(W){P(function(U){return Object.assign({},U,W)})}return F}(),O=(0,y.hsvaToRgba)(E),R=(0,y.hsvaToHex)(E);return(0,e.createComponentVNode)(2,o.Flex,{direction:"row",children:[(0,e.createComponentVNode)(2,o.Flex.Item,{mr:2,children:(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createVNode)(1,"div","react-colorful",[(0,e.createComponentVNode)(2,N,{hsva:E,onChange:M}),(0,e.createComponentVNode)(2,V,{hue:E.h,onChange:M,className:"react-colorful__last-control"})],4)}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:[(0,e.createComponentVNode)(2,o.Box,{inline:!0,width:"100px",height:"20px",textAlign:"center",children:"Current"}),(0,e.createComponentVNode)(2,o.Box,{inline:!0,width:"100px",height:"20px",textAlign:"center",children:"Previous"}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Tooltip,{content:R,position:"bottom",children:(0,e.createComponentVNode)(2,o.Box,{inline:!0,width:"100px",height:"30px",backgroundColor:R})}),(0,e.createComponentVNode)(2,o.Tooltip,{content:D,position:"bottom",children:(0,e.createComponentVNode)(2,o.Box,{inline:!0,width:"100px",height:"30px",backgroundColor:D})})]})]})}),(0,e.createComponentVNode)(2,o.Flex.Item,{grow:!0,fontSize:"15px",lineHeight:"24px",children:(0,e.createComponentVNode)(2,o.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"Hex:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,height:"24px",children:(0,e.createComponentVNode)(2,v,{fluid:!0,color:(0,y.hsvaToHex)(E).substring(1),onChange:function(){function F(W){h.logger.info(W),P((0,y.hexToHsva)(W))}return F}(),prefixed:!0})})]})}),(0,e.createComponentVNode)(2,o.Stack.Divider),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"H:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,V,{hue:E.h,onChange:M})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,C,{value:E.h,callback:function(){function F(W,U){return M({h:U})}return F}(),max:360,unit:"\xB0"})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"S:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,B,{color:E,onChange:M})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,C,{value:E.s,callback:function(){function F(W,U){return M({s:U})}return F}(),unit:"%"})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"V:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,I,{color:E,onChange:M})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,C,{value:E.v,callback:function(){function F(W,U){return M({v:U})}return F}(),unit:"%"})})]})}),(0,e.createComponentVNode)(2,o.Stack.Divider),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"R:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,L,{color:E,onChange:M,target:"r"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,C,{value:O.r,callback:function(){function F(W,U){O.r=U,M((0,y.rgbaToHsva)(O))}return F}(),max:255})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"G:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,L,{color:E,onChange:M,target:"g"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,C,{value:O.g,callback:function(){function F(W,U){O.g=U,M((0,y.rgbaToHsva)(O))}return F}(),max:255})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{width:"25px",children:(0,e.createComponentVNode)(2,o.Box,{textColor:"label",children:"B:"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,L,{color:E,onChange:M,target:"b"})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,C,{value:O.b,callback:function(){function F(W,U){O.b=U,M((0,y.rgbaToHsva)(O))}return F}(),max:255})})]})})]})})]})}return w}(),C=function(A){var x=A.value,E=A.callback,P=A.min,D=P===void 0?0:P,M=A.max,O=M===void 0?100:M,R=A.unit;return(0,e.createComponentVNode)(2,o.NumberInput,{width:"70px",value:Math.round(x),step:1,minValue:D,maxValue:O,onChange:E,unit:R})},g=function(A){return"#"+A},v=r.HexColorInput=function(){function w(A){var x=A.prefixed,E=A.alpha,P=A.color,D=A.fluid,M=A.onChange,O=u(A,c),R=function(){function W(U){return U.replace(/([^0-9A-F]+)/gi,"").substring(0,E?8:6)}return W}(),F=function(){function W(U){return(0,y.validHex)(U,E)}return W}();return(0,e.normalizeProps)((0,e.createComponentVNode)(2,f,Object.assign({},O,{fluid:D,color:P,onChange:M,escape:R,format:x?g:void 0,validate:F})))}return w}(),f=r.ColorInput=function(w){function A(E){var P;return P=w.call(this)||this,P.props=void 0,P.state=void 0,P.handleInput=function(D){var M=P.props.escape(D.currentTarget.value);P.setState({localValue:M})},P.handleBlur=function(D){D.currentTarget&&(P.props.validate(D.currentTarget.value)?P.props.onChange(P.props.escape?P.props.escape(D.currentTarget.value):D.currentTarget.value):P.setState({localValue:P.props.escape(P.props.color)}))},P.props=E,P.state={localValue:P.props.escape(P.props.color)},P}m(A,w);var x=A.prototype;return x.componentDidUpdate=function(){function E(P,D){P.color!==this.props.color&&this.setState({localValue:this.props.escape(this.props.color)})}return E}(),x.render=function(){function E(){return(0,e.createComponentVNode)(2,o.Box,{className:(0,k.classes)(["Input",this.props.fluid&&"Input--fluid"]),children:[(0,e.createVNode)(1,"div","Input__baseline",".",16),(0,e.createVNode)(64,"input","Input__input",null,1,{value:this.props.format?this.props.format(this.state.localValue):this.state.localValue,spellCheck:"false",onInput:this.handleInput,onBlur:this.handleBlur})]})}return E}(),A}(e.Component),N=function(A){var x=A.hsva,E=A.onChange,P=function(R){E({s:R.left*100,v:100-R.top*100})},D=function(R){E({s:(0,b.clamp)(x.s+R.left*100,0,100),v:(0,b.clamp)(x.v-R.top*100,0,100)})},M={"background-color":(0,y.hsvaToHslString)({h:x.h,s:100,v:100,a:1})+" !important"};return(0,e.createVNode)(1,"div","react-colorful__saturation_value",(0,e.createComponentVNode)(2,S.Interactive,{onMove:P,onKey:D,"aria-label":"Color","aria-valuetext":"Saturation "+Math.round(x.s)+"%, Brightness "+Math.round(x.v)+"%",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__saturation_value-pointer",top:1-x.v/100,left:x.s/100,color:(0,y.hsvaToHslString)(x)})}),2,{style:M})},V=function(A){var x=A.className,E=A.hue,P=A.onChange,D=function(F){P({h:360*F.left})},M=function(F){P({h:(0,b.clamp)(E+F.left*360,0,360)})},O=(0,k.classes)(["react-colorful__hue",x]);return(0,e.createVNode)(1,"div",O,(0,e.createComponentVNode)(2,S.Interactive,{onMove:D,onKey:M,"aria-label":"Hue","aria-valuenow":Math.round(E),"aria-valuemax":"360","aria-valuemin":"0",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__hue-pointer",left:E/360,color:(0,y.hsvaToHslString)({h:E,s:100,v:100,a:1})})}),2)},B=function(A){var x=A.className,E=A.color,P=A.onChange,D=function(F){P({s:100*F.left})},M=function(F){P({s:(0,b.clamp)(E.s+F.left*100,0,100)})},O=(0,k.classes)(["react-colorful__saturation",x]);return(0,e.createVNode)(1,"div",O,(0,e.createComponentVNode)(2,S.Interactive,{style:{background:"linear-gradient(to right, "+(0,y.hsvaToHslString)({h:E.h,s:0,v:E.v,a:1})+", "+(0,y.hsvaToHslString)({h:E.h,s:100,v:E.v,a:1})+")"},onMove:D,onKey:M,"aria-label":"Saturation","aria-valuenow":Math.round(E.s),"aria-valuemax":"100","aria-valuemin":"0",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__saturation-pointer",left:E.s/100,color:(0,y.hsvaToHslString)({h:E.h,s:E.s,v:E.v,a:1})})}),2)},I=function(A){var x=A.className,E=A.color,P=A.onChange,D=function(F){P({v:100*F.left})},M=function(F){P({v:(0,b.clamp)(E.v+F.left*100,0,100)})},O=(0,k.classes)(["react-colorful__value",x]);return(0,e.createVNode)(1,"div",O,(0,e.createComponentVNode)(2,S.Interactive,{style:{background:"linear-gradient(to right, "+(0,y.hsvaToHslString)({h:E.h,s:E.s,v:0,a:1})+", "+(0,y.hsvaToHslString)({h:E.h,s:E.s,v:100,a:1})+")"},onMove:D,onKey:M,"aria-label":"Value","aria-valuenow":Math.round(E.s),"aria-valuemax":"100","aria-valuemin":"0",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__value-pointer",left:E.v/100,color:(0,y.hsvaToHslString)({h:E.h,s:E.s,v:E.v,a:1})})}),2)},L=function(A){var x=A.className,E=A.color,P=A.onChange,D=A.target,M=(0,y.hsvaToRgba)(E),O=function($){M[D]=$,P((0,y.rgbaToHsva)(M))},R=function($){O(255*$.left)},F=function($){O((0,b.clamp)(M[D]+$.left*255,0,255))},W=(0,k.classes)(["react-colorful__"+D,x]),U=D==="r"?"rgb("+Math.round(M.r)+",0,0)":D==="g"?"rgb(0,"+Math.round(M.g)+",0)":"rgb(0,0,"+Math.round(M.b)+")";return(0,e.createVNode)(1,"div",W,(0,e.createComponentVNode)(2,S.Interactive,{onMove:R,onKey:F,"aria-valuenow":M[D],"aria-valuemax":"100","aria-valuemin":"0",children:(0,e.createComponentVNode)(2,o.Pointer,{className:"react-colorful__"+D+"-pointer",left:M[D]/255,color:U})}),2)}},8444:function(T,r,n){"use strict";r.__esModule=!0,r.ColourMatrixTester=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ColourMatrixTester=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.colour_data,m=[[{name:"RR",idx:0},{name:"RG",idx:1},{name:"RB",idx:2},{name:"RA",idx:3}],[{name:"GR",idx:4},{name:"GG",idx:5},{name:"GB",idx:6},{name:"GA",idx:7}],[{name:"BR",idx:8},{name:"BG",idx:9},{name:"BB",idx:10},{name:"BA",idx:11}],[{name:"AR",idx:12},{name:"AG",idx:13},{name:"AB",idx:14},{name:"AA",idx:15}]];return(0,e.createComponentVNode)(2,o.Window,{width:360,height:190,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Modify Matrix",children:m.map(function(l){return(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",textColor:"label",children:l.map(function(u){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,mt:1,children:[u.name,":\xA0",(0,e.createComponentVNode)(2,t.NumberInput,{width:4,value:c[u.idx],step:.05,minValue:-5,maxValue:5,stepPixelSize:5,onChange:function(){function s(d,C){return h("setvalue",{idx:u.idx+1,value:C})}return s}()})]},u.name)})},l)})})})})})}return b}()},63818:function(T,r,n){"use strict";r.__esModule=!0,r.CommunicationsComputer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(s){switch(s){case 1:return(0,e.createComponentVNode)(2,S);case 2:return(0,e.createComponentVNode)(2,i);case 3:return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,c)})});case 4:return(0,e.createComponentVNode)(2,l);default:return"ERROR. Unknown menu_state. Please contact NT Technical Support."}},b=r.CommunicationsComputer=function(){function u(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.menu_state;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y),p(f)]})})})}return u}(),y=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.authenticated,N=v.noauthbutton,V=v.esc_section,B=v.esc_callable,I=v.esc_recallable,L=v.esc_status,w=v.authhead,A=v.is_ai,x=v.lastCallLoc,E=!1,P;return f?f===1?P="Command":f===2?P="Captain":f===3?P="CentComm Officer":f===4?(P="CentComm Secure Connection",E=!0):P="ERROR: Report This Bug!":P="Not Logged In",(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Authentication",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:E&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Access",children:P})||(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:(0,e.createComponentVNode)(2,t.Button,{icon:f?"sign-out-alt":"id-card",selected:f,disabled:N,content:f?"Log Out ("+P+")":"Log In",onClick:function(){function D(){return g("auth")}return D}()})})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:!!V&&(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Escape Shuttle",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[!!L&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:L}),!!B&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Options",children:(0,e.createComponentVNode)(2,t.Button,{icon:"rocket",content:"Call Shuttle",disabled:!w,onClick:function(){function D(){return g("callshuttle")}return D}()})}),!!I&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Options",children:(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Recall Shuttle",disabled:!w||A,onClick:function(){function D(){return g("cancelshuttle")}return D}()})}),!!x&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Last Call/Recall From",children:x})]})})})],4)},S=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.is_admin;return f?(0,e.createComponentVNode)(2,k):(0,e.createComponentVNode)(2,h)},k=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.is_admin,N=v.gamma_armory_location,V=v.admin_levels,B=v.authenticated,I=v.ert_allowed;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"CentComm Actions",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Change Alert",children:(0,e.createComponentVNode)(2,m,{levels:V,required_access:f,use_confirm:1})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Announcement",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"bullhorn",content:"Make Central Announcement",disabled:!f,onClick:function(){function L(){return g("send_to_cc_announcement_page")}return L}()}),B===4&&(0,e.createComponentVNode)(2,t.Button,{icon:"plus",content:"Make Other Announcement",disabled:!f,onClick:function(){function L(){return g("make_other_announcement")}return L}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Response Team",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"ambulance",content:"Dispatch ERT",disabled:!f,onClick:function(){function L(){return g("dispatch_ert")}return L}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:I,content:I?"ERT calling enabled":"ERT calling disabled",tooltip:I?"Command can request an ERT":"ERTs cannot be requested",disabled:!f,onClick:function(){function L(){return g("toggle_ert_allowed")}return L}(),selected:null})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Nuclear Device",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"bomb",content:"Get Authentication Codes",disabled:!f,onClick:function(){function L(){return g("send_nuke_codes")}return L}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Gamma Armory",children:(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"biohazard",content:N?"Send Gamma Armory":"Recall Gamma Armory",disabled:!f,onClick:function(){function L(){return g("move_gamma_armory")}return L}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Other",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"coins",content:"View Economy",disabled:!f,onClick:function(){function L(){return g("view_econ")}return L}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fax",content:"Fax Manager",disabled:!f,onClick:function(){function L(){return g("view_fax")}return L}()})]})]})}),(0,e.createComponentVNode)(2,t.Collapsible,{title:"View Command accessible controls",children:(0,e.createComponentVNode)(2,h)})]})},h=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.msg_cooldown,N=v.emagged,V=v.cc_cooldown,B=v.security_level_color,I=v.str_security_level,L=v.levels,w=v.authcapt,A=v.authhead,x=v.messages,E="Make Priority Announcement";f>0&&(E+=" ("+f+"s)");var P=N?"Message [UNKNOWN]":"Message CentComm",D="Request Authentication Codes";return V>0&&(P+=" ("+V+"s)",D+=" ("+V+"s)"),(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Captain-Only Actions",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Alert",color:B,children:I}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Change Alert",children:(0,e.createComponentVNode)(2,m,{levels:L,required_access:w})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Announcement",children:(0,e.createComponentVNode)(2,t.Button,{icon:"bullhorn",content:E,disabled:!w||f>0,onClick:function(){function M(){return g("announce")}return M}()})}),!!N&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Transmit",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"broadcast-tower",color:"red",content:P,disabled:!w||V>0,onClick:function(){function M(){return g("MessageSyndicate")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sync-alt",content:"Reset Relays",disabled:!w,onClick:function(){function M(){return g("RestoreBackup")}return M}()})]})||(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Transmit",children:(0,e.createComponentVNode)(2,t.Button,{icon:"broadcast-tower",content:P,disabled:!w||V>0,onClick:function(){function M(){return g("MessageCentcomm")}return M}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Nuclear Device",children:(0,e.createComponentVNode)(2,t.Button,{icon:"bomb",content:D,disabled:!w||V>0,onClick:function(){function M(){return g("nukerequest")}return M}()})})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Command Staff Actions",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Displays",children:(0,e.createComponentVNode)(2,t.Button,{icon:"tv",content:"Change Status Displays",disabled:!A,onClick:function(){function M(){return g("status")}return M}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Incoming Messages",children:(0,e.createComponentVNode)(2,t.Button,{icon:"folder-open",content:"View ("+x.length+")",disabled:!A,onClick:function(){function M(){return g("messagelist")}return M}()})})]})})})],4)},i=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.stat_display,N=v.authhead,V=v.current_message_title,B=f.presets.map(function(L){return(0,e.createComponentVNode)(2,t.Button,{content:L.label,selected:L.name===f.type,disabled:!N,onClick:function(){function w(){return g("setstat",{statdisp:L.name})}return w}()},L.name)}),I=f.alerts.map(function(L){return(0,e.createComponentVNode)(2,t.Button,{content:L.label,selected:L.alert===f.icon,disabled:!N,onClick:function(){function w(){return g("setstat",{statdisp:3,alert:L.alert})}return w}()},L.alert)});return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Modify Status Screens",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-left",content:"Back To Main Menu",onClick:function(){function L(){return g("main")}return L}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Presets",children:B}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Alerts",children:I}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Message Line 1",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:f.line_1,disabled:!N,onClick:function(){function L(){return g("setmsg1")}return L}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Message Line 2",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:f.line_2,disabled:!N,onClick:function(){function L(){return g("setmsg2")}return L}()})})]})})})},c=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.authhead,N=v.current_message_title,V=v.current_message,B=v.messages,I=v.security_level,L;if(N)L=(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:N,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Return To Message List",disabled:!f,onClick:function(){function A(){return g("messagelist")}return A}()}),children:(0,e.createComponentVNode)(2,t.Box,{children:V})})});else{var w=B.map(function(A){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:A.title,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"eye",content:"View",disabled:!f||N===A.title,onClick:function(){function x(){return g("messagelist",{msgid:A.id})}return x}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"times",content:"Delete",disabled:!f,onClick:function(){function x(){return g("delmessage",{msgid:A.id})}return x}()})]},A.id)});L=(0,e.createComponentVNode)(2,t.Section,{title:"Messages Received",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-left",content:"Back To Main Menu",onClick:function(){function A(){return g("main")}return A}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:w})})}return(0,e.createComponentVNode)(2,t.Box,{children:L})},m=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=s.levels,N=s.required_access,V=s.use_confirm,B=v.security_level;return V?f.map(function(I){return(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:I.icon,content:I.name,disabled:!N||I.id===B,tooltip:I.tooltip,onClick:function(){function L(){return g("newalertlevel",{level:I.id})}return L}()},I.name)}):f.map(function(I){return(0,e.createComponentVNode)(2,t.Button,{icon:I.icon,content:I.name,disabled:!N||I.id===B,tooltip:I.tooltip,onClick:function(){function L(){return g("newalertlevel",{level:I.id})}return L}()},I.name)})},l=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.is_admin,N=v.possible_cc_sounds;if(!f)return g("main");var V=(0,a.useLocalState)(d,"subtitle",""),B=V[0],I=V[1],L=(0,a.useLocalState)(d,"text",""),w=L[0],A=L[1],x=(0,a.useLocalState)(d,"classified",0),E=x[0],P=x[1],D=(0,a.useLocalState)(d,"beepsound","Beep"),M=D[0],O=D[1];return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Central Command Report",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-left",content:"Back To Main Menu",onClick:function(){function R(){return g("main")}return R}()}),children:[(0,e.createComponentVNode)(2,t.Input,{placeholder:"Enter Subtitle here.",fluid:!0,value:B,onChange:function(){function R(F,W){return I(W)}return R}(),mb:"5px"}),(0,e.createComponentVNode)(2,t.Input,{placeholder:"Enter Announcement here,\nMultiline input is accepted.",rows:10,fluid:!0,multiline:1,value:w,onChange:function(){function R(F,W){return A(W)}return R}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Send Announcement",fluid:!0,icon:"paper-plane",center:!0,mt:"5px",textAlign:"center",onClick:function(){function R(){return g("make_cc_announcement",{subtitle:B,text:w,classified:E,beepsound:M})}return R}()}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Dropdown,{width:"260px",height:"20px",options:N,selected:M,onSelected:function(){function R(F){return O(F)}return R}(),disabled:E})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"volume-up",mx:"5px",disabled:E,tooltip:"Test sound",onClick:function(){function R(){return g("test_sound",{sound:M})}return R}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:E,content:"Classified",fluid:!0,tooltip:E?"Sent to station communications consoles":"Publically announced",onClick:function(){function R(){return P(!E)}return R}()})})]})]})})}},20562:function(T,r,n){"use strict";r.__esModule=!0,r.CompostBin=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.CompostBin=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.biomass,m=i.compost,l=i.biomass_capacity,u=i.compost_capacity,s=i.potassium,d=i.potassium_capacity,C=i.potash,g=i.potash_capacity,v=(0,a.useSharedState)(S,"vendAmount",1),f=v[0],N=v[1];return(0,e.createComponentVNode)(2,o.Window,{width:360,height:250,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Section,{label:"Resources",children:(0,e.createComponentVNode)(2,t.Stack,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Biomass",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ml:.5,mt:1,width:20,value:c,minValue:0,maxValue:l,ranges:{good:[l*.5,1/0],average:[l*.25,l*.5],bad:[-1/0,l*.25]},children:[c," / ",l," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Compost",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ml:.5,mt:1,width:20,value:m,minValue:0,maxValue:u,ranges:{good:[u*.5,1/0],average:[u*.25,u*.5],bad:[-1/0,u*.25]},children:[m," / ",u," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Potassium",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ml:.5,mt:1,width:20,value:s,minValue:0,maxValue:d,ranges:{good:[d*.5,1/0],average:[d*.25,d*.5],bad:[-1/0,d*.25]},children:[s," / ",d," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Potash",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ml:.5,mt:1,width:20,value:C,minValue:0,maxValue:g,ranges:{good:[g*.5,1/0],average:[g*.25,g*.5],bad:[-1/0,g*.25]},children:[C," / ",g," Units"]})})]})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Controls",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{inline:!0,mr:"5px",color:"silver",children:"Soil clumps to make:"}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,value:f,width:"32px",minValue:1,maxValue:10,stepPixelSize:7,onChange:function(){function V(B,I){return N(I)}return V}()})],4),children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,align:"center",content:"Make Soil",disabled:m<25*f,icon:"arrow-circle-down",onClick:function(){function V(){return h("create",{amount:f})}return V}()})})})]})})})}return b}()},21813:function(T,r,n){"use strict";r.__esModule=!0,r.Contractor=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(73379),b=n(98595);function y(g,v){g.prototype=Object.create(v.prototype),g.prototype.constructor=g,S(g,v)}function S(g,v){return S=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,N){return f.__proto__=N,f},S(g,v)}var k={1:["ACTIVE","good"],2:["COMPLETED","good"],3:["FAILED","bad"]},h=["Recording biometric data...","Analyzing embedded syndicate info...","STATUS CONFIRMED","Contacting Syndicate database...","Awaiting response...","Awaiting response...","Awaiting response...","Awaiting response...","Awaiting response...","Awaiting response...","Response received, ack 4851234...","CONFIRM ACC "+Math.round(Math.random()*2e4),"Setting up private accounts...","CONTRACTOR ACCOUNT CREATED","Searching for available contracts...","Searching for available contracts...","Searching for available contracts...","Searching for available contracts...","CONTRACTS FOUND","WELCOME, AGENT"],i=r.Contractor=function(){function g(v,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I;B.unauthorized?I=(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",backgroundColor:"rgba(0, 0, 0, 0.8)",children:(0,e.createComponentVNode)(2,d,{height:"100%",allMessages:["ERROR: UNAUTHORIZED USER"],finishedTimeout:100,onFinished:function(){function x(){}return x}()})}):B.load_animation_completed?I=(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Flex.Item,{basis:"content",children:(0,e.createComponentVNode)(2,c)}),(0,e.createComponentVNode)(2,o.Flex.Item,{basis:"content",mt:"0.5rem",children:(0,e.createComponentVNode)(2,m)}),(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",overflow:"hidden",children:B.page===1?(0,e.createComponentVNode)(2,l,{height:"100%"}):(0,e.createComponentVNode)(2,s,{height:"100%"})})],4):I=(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",backgroundColor:"rgba(0, 0, 0, 0.8)",children:(0,e.createComponentVNode)(2,d,{height:"100%",allMessages:h,finishedTimeout:3e3,onFinished:function(){function x(){return V("complete_load_animation")}return x}()})});var L=(0,t.useLocalState)(f,"viewingPhoto",""),w=L[0],A=L[1];return(0,e.createComponentVNode)(2,b.Window,{theme:"syndicate",width:500,height:600,children:[w&&(0,e.createComponentVNode)(2,C),(0,e.createComponentVNode)(2,b.Window.Content,{className:"Contractor",children:(0,e.createComponentVNode)(2,o.Flex,{direction:"column",height:"100%",children:I})})]})}return g}(),c=function(v,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I=B.tc_available,L=B.tc_paid_out,w=B.completed_contracts,A=B.rep;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({title:"Summary",buttons:(0,e.createComponentVNode)(2,o.Box,{verticalAlign:"middle",mt:"0.25rem",children:[A," Rep"]})},v,{children:(0,e.createComponentVNode)(2,o.Flex,{children:[(0,e.createComponentVNode)(2,o.Box,{flexBasis:"50%",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"TC Available",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,o.Flex,{align:"center",children:[(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",children:[I," TC"]}),(0,e.createComponentVNode)(2,o.Button,{disabled:I<=0,content:"Claim",mx:"0.75rem",mb:"0",flexBasis:"content",onClick:function(){function x(){return V("claim")}return x}()})]})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"TC Earned",children:[L," TC"]})]})}),(0,e.createComponentVNode)(2,o.Box,{flexBasis:"50%",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Contracts Completed",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,o.Box,{height:"20px",lineHeight:"20px",inline:!0,children:w})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Contractor Status",verticalAlign:"middle",children:"ACTIVE"})]})})]})})))},m=function(v,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I=B.page;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Tabs,Object.assign({},v,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:I===1,onClick:function(){function L(){return V("page",{page:1})}return L}(),children:[(0,e.createComponentVNode)(2,o.Icon,{name:"suitcase"}),"Contracts"]}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:I===2,onClick:function(){function L(){return V("page",{page:2})}return L}(),children:[(0,e.createComponentVNode)(2,o.Icon,{name:"shopping-cart"}),"Hub"]})]})))},l=function(v,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I=B.contracts,L=B.contract_active,w=B.can_extract,A=!!L&&I.filter(function(M){return M.status===1})[0],x=A&&A.time_left>0,E=(0,t.useLocalState)(f,"viewingPhoto",""),P=E[0],D=E[1];return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({title:"Available Contracts",overflow:"auto",buttons:(0,e.createComponentVNode)(2,o.Button,{disabled:!w||x,icon:"parachute-box",content:["Call Extraction",x&&(0,e.createComponentVNode)(2,p.Countdown,{timeLeft:A.time_left,format:function(){function M(O,R){return" ("+R.substr(3)+")"}return M}()})],onClick:function(){function M(){return V("extract")}return M}()})},v,{children:I.slice().sort(function(M,O){return M.status===1?-1:O.status===1?1:M.status-O.status}).map(function(M){var O;return(0,e.createComponentVNode)(2,o.Section,{title:(0,e.createComponentVNode)(2,o.Flex,{children:[(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"1",color:M.status===1&&"good",children:M.target_name}),(0,e.createComponentVNode)(2,o.Flex.Item,{basis:"content",children:M.has_photo&&(0,e.createComponentVNode)(2,o.Button,{icon:"camera",mb:"-0.5rem",ml:"0.5rem",onClick:function(){function R(){return D("target_photo_"+M.uid+".png")}return R}()})})]}),className:"Contractor__Contract",buttons:(0,e.createComponentVNode)(2,o.Box,{width:"100%",children:[!!k[M.status]&&(0,e.createComponentVNode)(2,o.Box,{color:k[M.status][1],inline:!0,mt:M.status!==1&&"0.125rem",mr:"0.25rem",lineHeight:"20px",children:k[M.status][0]}),M.status===1&&(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"ban",color:"bad",content:"Abort",ml:"0.5rem",onClick:function(){function R(){return V("abort")}return R}()})]}),children:(0,e.createComponentVNode)(2,o.Flex,{children:[(0,e.createComponentVNode)(2,o.Flex.Item,{grow:"2",mr:"0.5rem",children:[M.fluff_message,!!M.completed_time&&(0,e.createComponentVNode)(2,o.Box,{color:"good",children:[(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Icon,{name:"check",mr:"0.5rem"}),"Contract completed at ",M.completed_time]}),!!M.dead_extraction&&(0,e.createComponentVNode)(2,o.Box,{color:"bad",mt:"0.5rem",bold:!0,children:[(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-triangle",mr:"0.5rem"}),"Telecrystals reward reduced drastically as the target was dead during extraction."]}),!!M.fail_reason&&(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:[(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Icon,{name:"times",mr:"0.5rem"}),"Contract failed: ",M.fail_reason]})]}),(0,e.createComponentVNode)(2,o.Flex.Item,{flexBasis:"100%",children:[(0,e.createComponentVNode)(2,o.Flex,{mb:"0.5rem",color:"label",children:["Extraction Zone:\xA0",u(M)]}),(O=M.difficulties)==null?void 0:O.map(function(R,F){return(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:!!L,content:R.name+" ("+R.reward+" TC)",onClick:function(){function W(){return V("activate",{uid:M.uid,difficulty:F+1})}return W}()},F)}),!!M.objective&&(0,e.createComponentVNode)(2,o.Box,{color:"white",bold:!0,children:[M.objective.extraction_name,(0,e.createVNode)(1,"br"),"(",(M.objective.rewards.tc||0)+" TC",",\xA0",(M.objective.rewards.credits||0)+" Credits",")"]})]})]})},M.uid)})})))},u=function(v){if(!(!v.objective||v.status>1)){var f=v.objective.locs.user_area_id,N=v.objective.locs.user_coords,V=v.objective.locs.target_area_id,B=v.objective.locs.target_coords,I=f===V;return(0,e.createComponentVNode)(2,o.Flex.Item,{children:(0,e.createComponentVNode)(2,o.Icon,{name:I?"dot-circle-o":"arrow-alt-circle-right-o",color:I?"green":"yellow",rotation:I?null:-(0,a.rad2deg)(Math.atan2(B[1]-N[1],B[0]-N[0])),lineHeight:I?null:"0.85",size:"1.5"})})}},s=function(v,f){var N=(0,t.useBackend)(f),V=N.act,B=N.data,I=B.rep,L=B.buyables;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({title:"Available Purchases",overflow:"auto"},v,{children:L.map(function(w){return(0,e.createComponentVNode)(2,o.Section,{title:w.name,children:[w.description,(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:I-1&&(0,e.createComponentVNode)(2,o.Box,{as:"span",color:w.stock===0?"bad":"good",ml:"0.5rem",children:[w.stock," in stock"]})]},w.uid)})})))},d=function(g){function v(N){var V;return V=g.call(this,N)||this,V.timer=null,V.state={currentIndex:0,currentDisplay:[]},V}y(v,g);var f=v.prototype;return f.tick=function(){function N(){var V=this.props,B=this.state;if(B.currentIndex<=V.allMessages.length){this.setState(function(L){return{currentIndex:L.currentIndex+1}});var I=B.currentDisplay;I.push(V.allMessages[B.currentIndex])}else clearTimeout(this.timer),setTimeout(V.onFinished,V.finishedTimeout)}return N}(),f.componentDidMount=function(){function N(){var V=this,B=this.props.linesPerSecond,I=B===void 0?2.5:B;this.timer=setInterval(function(){return V.tick()},1e3/I)}return N}(),f.componentWillUnmount=function(){function N(){clearTimeout(this.timer)}return N}(),f.render=function(){function N(){return(0,e.createComponentVNode)(2,o.Box,{m:1,children:this.state.currentDisplay.map(function(V){return(0,e.createFragment)([V,(0,e.createVNode)(1,"br")],0,V)})})}return N}(),v}(e.Component),C=function(v,f){var N=(0,t.useLocalState)(f,"viewingPhoto",""),V=N[0],B=N[1];return(0,e.createComponentVNode)(2,o.Modal,{className:"Contractor__photoZoom",children:[(0,e.createComponentVNode)(2,o.Box,{as:"img",src:V}),(0,e.createComponentVNode)(2,o.Button,{icon:"times",content:"Close",color:"grey",mt:"1rem",onClick:function(){function I(){return B("")}return I}()})]})}},54151:function(T,r,n){"use strict";r.__esModule=!0,r.ConveyorSwitch=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ConveyorSwitch=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.slowFactor,m=i.oneWay,l=i.position;return(0,e.createComponentVNode)(2,o.Window,{width:350,height:135,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Lever position",children:l>0?"forward":l<0?"reverse":"neutral"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Allow reverse",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!m,onClick:function(){function u(){return h("toggleOneWay")}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Slowdown factor",children:(0,e.createComponentVNode)(2,t.Flex,{children:[(0,e.createComponentVNode)(2,t.Flex.Item,{mx:"1px",children:[" ",(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-left",onClick:function(){function u(){return h("slowFactor",{value:c-5})}return u}()})," "]}),(0,e.createComponentVNode)(2,t.Flex.Item,{mx:"1px",children:[" ",(0,e.createComponentVNode)(2,t.Button,{icon:"angle-left",onClick:function(){function u(){return h("slowFactor",{value:c-1})}return u}()})," "]}),(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Slider,{width:"100px",mx:"1px",value:c,fillValue:c,minValue:1,maxValue:50,step:1,format:function(){function u(s){return s+"x"}return u}(),onChange:function(){function u(s,d){return h("slowFactor",{value:d})}return u}()})}),(0,e.createComponentVNode)(2,t.Flex.Item,{mx:"1px",children:[" ",(0,e.createComponentVNode)(2,t.Button,{icon:"angle-right",onClick:function(){function u(){return h("slowFactor",{value:c+1})}return u}()})," "]}),(0,e.createComponentVNode)(2,t.Flex.Item,{mx:"1px",children:[" ",(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-right",onClick:function(){function u(){return h("slowFactor",{value:c+5})}return u}()})," "]})]})})]})})})})}return b}()},73169:function(T,r,n){"use strict";r.__esModule=!0,r.CrewMonitor=void 0;var e=n(89005),a=n(88510),t=n(25328),o=n(72253),p=n(36036),b=n(36352),y=n(76910),S=n(98595),k=n(96184),h=["color"];function i(C,g){if(C==null)return{};var v={};for(var f in C)if({}.hasOwnProperty.call(C,f)){if(g.includes(f))continue;v[f]=C[f]}return v}var c=function(g,v){return g.dead?"Deceased":parseInt(g.health,10)<=v?"Critical":parseInt(g.stat,10)===1?"Unconscious":"Living"},m=function(g,v){return g.dead?"red":parseInt(g.health,10)<=v?"orange":parseInt(g.stat,10)===1?"blue":"green"},l=r.CrewMonitor=function(){function C(g,v){var f=(0,o.useBackend)(v),N=f.act,V=f.data,B=(0,o.useLocalState)(v,"tabIndex",V.tabIndex),I=B[0],L=B[1],w=function(){function x(E){L(E),N("set_tab_index",{tab_index:E})}return x}(),A=function(){function x(E){switch(E){case 0:return(0,e.createComponentVNode)(2,u);case 1:return(0,e.createComponentVNode)(2,d);default:return"WE SHOULDN'T BE HERE!"}}return x}();return(0,e.createComponentVNode)(2,S.Window,{width:800,height:600,children:(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,fillPositionedParent:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Tabs,{children:[(0,e.createComponentVNode)(2,p.Tabs.Tab,{icon:"table",selected:I===0,onClick:function(){function x(){return w(0)}return x}(),children:"Data View"},"DataView"),(0,e.createComponentVNode)(2,p.Tabs.Tab,{icon:"map-marked-alt",selected:I===1,onClick:function(){function x(){return w(1)}return x}(),children:"Map View"},"MapView")]})}),A(I)]})})})}return C}(),u=function(g,v){var f=(0,o.useBackend)(v),N=f.act,V=f.data,B=V.possible_levels,I=V.viewing_current_z_level,L=V.is_advanced,w=V.highlightedNames,A=(0,a.sortBy)(function(M){return!w.includes(M.name)},function(M){return M.name})(V.crewmembers||[]),x=(0,o.useLocalState)(v,"search",""),E=x[0],P=x[1],D=(0,t.createSearch)(E,function(M){return M.name+"|"+M.assignment+"|"+M.area});return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,backgroundColor:"transparent",children:[(0,e.createComponentVNode)(2,p.Stack,{children:[(0,e.createComponentVNode)(2,p.Stack.Item,{width:"100%",ml:"5px",children:(0,e.createComponentVNode)(2,p.Input,{placeholder:"Search by name, assignment or location..",width:"100%",onInput:function(){function M(O,R){return P(R)}return M}()})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:L?(0,e.createComponentVNode)(2,p.Dropdown,{mr:"5px",width:"50px",options:B,selected:I,onSelected:function(){function M(O){return N("switch_level",{new_level:O})}return M}()}):null})]}),(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,p.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:(0,e.createComponentVNode)(2,p.Button,{tooltip:"Clear highlights",icon:"square-xmark",onClick:function(){function M(){return N("clear_highlighted_names")}return M}()})}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Location"})]}),A.filter(D).map(function(M){var O=w.includes(M.name);return(0,e.createComponentVNode)(2,p.Table.Row,{bold:!!M.is_command,children:[(0,e.createComponentVNode)(2,b.TableCell,{children:(0,e.createComponentVNode)(2,k.ButtonCheckbox,{checked:O,tooltip:"Mark on map",onClick:function(){function R(){return N(O?"remove_highlighted_name":"add_highlighted_name",{name:M.name})}return R}()})}),(0,e.createComponentVNode)(2,b.TableCell,{children:[M.name," (",M.assignment,")"]}),(0,e.createComponentVNode)(2,b.TableCell,{children:[(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:m(M,V.critThreshold),children:c(M,V.critThreshold)}),M.sensor_type>=2||V.ignoreSensors?(0,e.createComponentVNode)(2,p.Box,{inline:!0,ml:1,children:["(",(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:y.COLORS.damageType.oxy,children:M.oxy}),"|",(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:y.COLORS.damageType.toxin,children:M.tox}),"|",(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:y.COLORS.damageType.burn,children:M.fire}),"|",(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:y.COLORS.damageType.brute,children:M.brute}),")"]}):null]}),(0,e.createComponentVNode)(2,b.TableCell,{children:M.sensor_type===3||V.ignoreSensors?V.isAI||V.isObserver?(0,e.createComponentVNode)(2,p.Button,{fluid:!0,icon:"location-arrow",content:M.area+" ("+M.x+", "+M.y+")",onClick:function(){function R(){return N("track",{track:M.ref})}return R}()}):M.area+" ("+M.x+", "+M.y+")":(0,e.createComponentVNode)(2,p.Box,{inline:!0,color:"grey",children:"Not Available"})})]},M.name)})]})]})},s=function(g,v){var f=g.color,N=i(g,h);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.NanoMap.Marker,Object.assign({},N,{children:(0,e.createVNode)(1,"span","highlighted-marker color-border-"+f)})))},d=function(g,v){var f=(0,o.useBackend)(v),N=f.act,V=f.data,B=V.highlightedNames;return(0,e.createComponentVNode)(2,p.Box,{height:"100vh",mb:"0.5rem",overflow:"hidden",children:(0,e.createComponentVNode)(2,p.NanoMap,{zoom:V.zoom,offsetX:V.offsetX,offsetY:V.offsetY,onZoom:function(){function I(L){return N("set_zoom",{zoom:L})}return I}(),onOffsetChange:function(){function I(L,w){return N("set_offset",{offset_x:w.offsetX,offset_y:w.offsetY})}return I}(),children:V.crewmembers.filter(function(I){return I.sensor_type===3||V.ignoreSensors}).map(function(I){var L=m(I,V.critThreshold),w=B.includes(I.name),A=function(){return V.isObserver?N("track",{track:I.ref}):null},x=function(){return N(w?"remove_highlighted_name":"add_highlighted_name",{name:I.name})},E=I.name+" ("+I.assignment+")";return w?(0,e.createComponentVNode)(2,s,{x:I.x,y:I.y,tooltip:E,color:L,onClick:A,onDblClick:x},I.ref):(0,e.createComponentVNode)(2,p.NanoMap.MarkerIcon,{x:I.x,y:I.y,icon:"circle",tooltip:E,color:L,onClick:A,onDblClick:x},I.ref)})})})}},63987:function(T,r,n){"use strict";r.__esModule=!0,r.Cryo=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=[{label:"Resp.",type:"oxyLoss"},{label:"Toxin",type:"toxLoss"},{label:"Brute",type:"bruteLoss"},{label:"Burn",type:"fireLoss"}],b=[["good","Conscious"],["average","Unconscious"],["bad","DEAD"]],y=r.Cryo=function(){function h(i,c){return(0,e.createComponentVNode)(2,o.Window,{width:520,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,S)})})})}return h}(),S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.isOperating,d=u.hasOccupant,C=u.occupant,g=C===void 0?[]:C,v=u.cellTemperature,f=u.cellTemperatureStatus,N=u.isBeakerLoaded,V=u.cooldownProgress,B=u.auto_eject_healthy,I=u.auto_eject_dead;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Occupant",fill:!0,scrollable:!0,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"user-slash",onClick:function(){function L(){return l("ejectOccupant")}return L}(),disabled:!d,children:"Eject"}),children:d?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Occupant",children:g.name||"Unknown"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,t.ProgressBar,{min:g.health,max:g.maxHealth,value:g.health/g.maxHealth,color:g.health>0?"good":"average",children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:Math.round(g.health)})})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:b[g.stat][0],children:b[g.stat][1]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:Math.round(g.bodyTemperature)})," K"]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),p.map(function(L){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:L.label,children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:g[L.type]/100,ranges:{bad:[.01,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:Math.round(g[L.type])})})},L.id)})]}):(0,e.createComponentVNode)(2,t.Stack,{fill:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No occupant detected."]})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Cell",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"eject",onClick:function(){function L(){return l("ejectBeaker")}return L}(),disabled:!N,children:"Eject Beaker"}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",onClick:function(){function L(){return l(s?"switchOff":"switchOn")}return L}(),selected:s,children:s?"On":"Off"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",color:f,children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:v})," K"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Beaker",children:(0,e.createComponentVNode)(2,k)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Dosage interval",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ranges:{average:[-1/0,99],good:[99,1/0]},color:!N&&"average",value:V,minValue:0,maxValue:100})}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auto-eject healthy occupants",children:(0,e.createComponentVNode)(2,t.Button,{icon:B?"toggle-on":"toggle-off",selected:B,onClick:function(){function L(){return l(B?"auto_eject_healthy_off":"auto_eject_healthy_on")}return L}(),children:B?"On":"Off"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auto-eject dead occupants",children:(0,e.createComponentVNode)(2,t.Button,{icon:I?"toggle-on":"toggle-off",selected:I,onClick:function(){function L(){return l(I?"auto_eject_dead_off":"auto_eject_dead_on")}return L}(),children:I?"On":"Off"})})]})})})],4)},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.isBeakerLoaded,d=u.beakerLabel,C=u.beakerVolume;return s?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:!d&&"average",children:[d||"No label",":"]}),(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:!C&&"bad",ml:1,children:C?(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:C,format:function(){function g(v){return Math.round(v)+" units remaining"}return g}()}):"Beaker is empty"})],4):(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:"bad",children:"No beaker loaded"})}},86099:function(T,r,n){"use strict";r.__esModule=!0,r.CryopodConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(25328),b=r.CryopodConsole=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.account_name,u=m.allow_items;return(0,e.createComponentVNode)(2,o.Window,{title:"Cryopod Console",width:400,height:480,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Hello, "+(l||"[REDACTED]")+"!",children:"This automated cryogenic freezing unit will safely store your corporeal form until your next assignment."}),(0,e.createComponentVNode)(2,y),!!u&&(0,e.createComponentVNode)(2,S)]})})}return k}(),y=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.frozen_crew;return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Stored Crew",children:l.length?(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:l.map(function(u,s){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:u.name,children:u.rank},s)})})}):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No stored crew!"})})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.frozen_items,s=function(C){var g=C.toString();return g.startsWith("the ")&&(g=g.slice(4,g.length)),(0,p.toTitleCase)(g)};return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Stored Items",children:u.length?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:u.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:s(d.name),buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-down",content:"Drop",mr:1,onClick:function(){function C(){return m("one_item",{item:d.uid})}return C}()})},d)})})}),(0,e.createComponentVNode)(2,t.Button,{content:"Drop All Items",color:"red",onClick:function(){function d(){return m("all_items")}return d}()})],4):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No stored items!"})})}},12692:function(T,r,n){"use strict";r.__esModule=!0,r.DNAModifier=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=[["good","Alive"],["average","Critical"],["bad","DEAD"]],y=[["ui","Modify U.I.","dna"],["se","Modify S.E.","dna"],["buffer","Transfer Buffers","syringe"],["rejuvenators","Rejuvenators","flask"]],S=[5,10,20,30,50],k=r.DNAModifier=function(){function f(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.irradiating,A=L.dnaBlockSize,x=L.occupant;V.dnaBlockSize=A,V.isDNAInvalid=!x.isViableSubject||!x.uniqueIdentity||!x.structuralEnzymes;var E;return w&&(E=(0,e.createComponentVNode)(2,g,{duration:w})),(0,e.createComponentVNode)(2,o.Window,{width:660,height:775,children:[(0,e.createComponentVNode)(2,p.ComplexModal),E,(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,h)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,i)})]})})]})}return f}(),h=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.locked,A=L.hasOccupant,x=L.occupant;return(0,e.createComponentVNode)(2,t.Section,{title:"Occupant",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{color:"label",inline:!0,mr:"0.5rem",children:"Door Lock:"}),(0,e.createComponentVNode)(2,t.Button,{disabled:!A,selected:w,icon:w?"toggle-on":"toggle-off",content:w?"Engaged":"Disengaged",onClick:function(){function E(){return I("toggleLock")}return E}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!A||w,icon:"user-slash",content:"Eject",onClick:function(){function E(){return I("ejectOccupant")}return E}()})],4),children:A?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:x.name}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,t.ProgressBar,{min:x.minHealth,max:x.maxHealth,value:x.health/x.maxHealth,ranges:{good:[.5,1/0],average:[0,.5],bad:[-1/0,0]}})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:b[x.stat][0],children:b[x.stat][1]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider)]})}),V.isDNAInvalid?(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-circle"}),"\xA0 The occupant's DNA structure is ruined beyond recognition, please insert a subject with an intact DNA structure."]}):(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Radiation",children:(0,e.createComponentVNode)(2,t.ProgressBar,{min:"0",max:"100",value:x.radiationLevel/100,color:"average"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Unique Enzymes",children:L.occupant.uniqueEnzymes?L.occupant.uniqueEnzymes:(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"exclamation-circle"}),"\xA0 Unknown"]})})]})],0):(0,e.createComponentVNode)(2,t.Box,{color:"label",children:"Cell unoccupied."})})},i=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.selectedMenuKey,A=L.hasOccupant,x=L.occupant;if(A){if(V.isDNAInvalid)return(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,align:"center",textAlign:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No operation possible on this subject."]})})})}else return(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,align:"center",textAlign:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No occupant in DNA modifier."]})})});var E;return w==="ui"?E=(0,e.createFragment)([(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,l)],4):w==="se"?E=(0,e.createFragment)([(0,e.createComponentVNode)(2,m),(0,e.createComponentVNode)(2,l)],4):w==="buffer"?E=(0,e.createComponentVNode)(2,u):w==="rejuvenators"&&(E=(0,e.createComponentVNode)(2,C)),(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Tabs,{children:y.map(function(P,D){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:P[2],selected:w===P[0],onClick:function(){function M(){return I("selectMenuKey",{key:P[0]})}return M}(),children:P[1]},D)})}),E]})},c=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.selectedUIBlock,A=L.selectedUISubBlock,x=L.selectedUITarget,E=L.occupant;return(0,e.createComponentVNode)(2,t.Section,{title:"Modify Unique Identifier",children:[(0,e.createComponentVNode)(2,v,{dnaString:E.uniqueIdentity,selectedBlock:w,selectedSubblock:A,blockSize:V.dnaBlockSize,action:"selectUIBlock"}),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target",children:(0,e.createComponentVNode)(2,t.Knob,{minValue:1,maxValue:15,stepPixelSize:"20",value:x,format:function(){function P(D){return D.toString(16).toUpperCase()}return P}(),ml:"0",onChange:function(){function P(D,M){return I("changeUITarget",{value:M})}return P}()})})}),(0,e.createComponentVNode)(2,t.Button,{icon:"radiation",content:"Irradiate Block",mt:"0.5rem",onClick:function(){function P(){return I("pulseUIRadiation")}return P}()})]})},m=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.selectedSEBlock,A=L.selectedSESubBlock,x=L.occupant;return(0,e.createComponentVNode)(2,t.Section,{title:"Modify Structural Enzymes",children:[(0,e.createComponentVNode)(2,v,{dnaString:x.structuralEnzymes,selectedBlock:w,selectedSubblock:A,blockSize:V.dnaBlockSize,action:"selectSEBlock"}),(0,e.createComponentVNode)(2,t.Button,{icon:"radiation",content:"Irradiate Block",onClick:function(){function E(){return I("pulseSERadiation")}return E}()})]})},l=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.radiationIntensity,A=L.radiationDuration;return(0,e.createComponentVNode)(2,t.Section,{title:"Radiation Emitter",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Intensity",children:(0,e.createComponentVNode)(2,t.Knob,{minValue:1,maxValue:10,stepPixelSize:20,value:w,popUpPosition:"right",ml:"0",onChange:function(){function x(E,P){return I("radiationIntensity",{value:P})}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Duration",children:(0,e.createComponentVNode)(2,t.Knob,{minValue:1,maxValue:20,stepPixelSize:10,unit:"s",value:A,popUpPosition:"right",ml:"0",onChange:function(){function x(E,P){return I("radiationDuration",{value:P})}return x}()})})]}),(0,e.createComponentVNode)(2,t.Button,{icon:"radiation",content:"Pulse Radiation",tooltip:"Mutates a random block of either the occupant's UI or SE.",tooltipPosition:"top-start",mt:"0.5rem",onClick:function(){function x(){return I("pulseRadiation")}return x}()})]})},u=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.buffers,A=w.map(function(x,E){return(0,e.createComponentVNode)(2,s,{id:E+1,name:"Buffer "+(E+1),buffer:x},E)});return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{height:"75%",mt:1,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Buffers",children:A})}),(0,e.createComponentVNode)(2,t.Stack.Item,{height:"25%",children:(0,e.createComponentVNode)(2,d)})]})},s=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=N.id,A=N.name,x=N.buffer,E=L.isInjectorReady,P=A+(x.data?" - "+x.label:"");return(0,e.createComponentVNode)(2,t.Box,{backgroundColor:"rgba(0, 0, 0, 0.33)",mb:"0.5rem",children:(0,e.createComponentVNode)(2,t.Section,{title:P,mx:"0",lineHeight:"18px",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Confirm,{disabled:!x.data,icon:"trash",content:"Clear",onClick:function(){function D(){return I("bufferOption",{option:"clear",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!x.data,icon:"pen",content:"Rename",onClick:function(){function D(){return I("bufferOption",{option:"changeLabel",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!x.data||!L.hasDisk,icon:"save",content:"Export",tooltip:"Exports this buffer to the currently loaded data disk.",tooltipPosition:"bottom-start",onClick:function(){function D(){return I("bufferOption",{option:"saveDisk",id:w})}return D}()})],4),children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Write",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-down",content:"Subject U.I",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"saveUI",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-down",content:"Subject U.I and U.E.",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"saveUIAndUE",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-down",content:"Subject S.E.",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"saveSE",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!L.hasDisk||!L.disk.data,icon:"arrow-circle-down",content:"From Disk",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"loadDisk",id:w})}return D}()})]}),!!x.data&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Subject",children:x.owner||(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Unknown"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Data Type",children:[x.type==="ui"?"Unique Identifiers":"Structural Enzymes",!!x.ue&&" and Unique Enzymes"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Transfer to",children:[(0,e.createComponentVNode)(2,t.Button,{disabled:!E,icon:E?"syringe":"spinner",iconSpin:!E,content:"Injector",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"createInjector",id:w})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!E,icon:E?"syringe":"spinner",iconSpin:!E,content:"Block Injector",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"createInjector",id:w,block:1})}return D}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"user",content:"Subject",mb:"0",onClick:function(){function D(){return I("bufferOption",{option:"transfer",id:w})}return D}()})]})],4)]}),!x.data&&(0,e.createComponentVNode)(2,t.Box,{color:"label",mt:"0.5rem",children:"This buffer is empty."})]})})},d=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.hasDisk,A=L.disk;return(0,e.createComponentVNode)(2,t.Section,{title:"Data Disk",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Confirm,{disabled:!w||!A.data,icon:"trash",content:"Wipe",onClick:function(){function x(){return I("wipeDisk")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:!w,icon:"eject",content:"Eject",onClick:function(){function x(){return I("ejectDisk")}return x}()})],4),children:w?A.data?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Label",children:A.label?A.label:"No label"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Subject",children:A.owner?A.owner:(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"Unknown"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Data Type",children:[A.type==="ui"?"Unique Identifiers":"Structural Enzymes",!!A.ue&&" and Unique Enzymes"]})]}):(0,e.createComponentVNode)(2,t.Box,{color:"label",children:"Disk is blank."}):(0,e.createComponentVNode)(2,t.Box,{color:"label",textAlign:"center",my:"1rem",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"save-o",size:"4"}),(0,e.createVNode)(1,"br"),"No disk inserted."]})})},C=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.isBeakerLoaded,A=L.beakerVolume,x=L.beakerLabel;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Rejuvenators and Beaker",buttons:(0,e.createComponentVNode)(2,t.Button,{disabled:!w,icon:"eject",content:"Eject",onClick:function(){function E(){return I("ejectBeaker")}return E}()}),children:w?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Inject",children:[S.map(function(E,P){return(0,e.createComponentVNode)(2,t.Button,{disabled:E>A,icon:"syringe",content:E,onClick:function(){function D(){return I("injectRejuvenators",{amount:E})}return D}()},P)}),(0,e.createComponentVNode)(2,t.Button,{disabled:A<=0,icon:"syringe",content:"All",onClick:function(){function E(){return I("injectRejuvenators",{amount:A})}return E}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Beaker",children:[(0,e.createComponentVNode)(2,t.Box,{mb:"0.5rem",children:x||"No label"}),A?(0,e.createComponentVNode)(2,t.Box,{color:"good",children:[A," unit",A===1?"":"s"," remaining"]}):(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"Empty"})]})]}):(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"flask",size:5,color:"silver"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"h3",null,"No beaker loaded.",16)]})})})},g=function(N,V){return(0,e.createComponentVNode)(2,t.Dimmer,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"spinner",size:"5",spin:!0}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Box,{color:"average",children:(0,e.createVNode)(1,"h1",null,[(0,e.createComponentVNode)(2,t.Icon,{name:"radiation"}),(0,e.createTextVNode)("\xA0Irradiating occupant\xA0"),(0,e.createComponentVNode)(2,t.Icon,{name:"radiation"})],4)}),(0,e.createComponentVNode)(2,t.Box,{color:"label",children:(0,e.createVNode)(1,"h3",null,[(0,e.createTextVNode)("For "),N.duration,(0,e.createTextVNode)(" second"),N.duration===1?"":"s"],0)})]})},v=function(N,V){for(var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=N.dnaString,A=N.selectedBlock,x=N.selectedSubblock,E=N.blockSize,P=N.action,D=w.split(""),M=0,O=[],R=function(){for(var U=F/E+1,z=[],$=function(){var J=G+1;z.push((0,e.createComponentVNode)(2,t.Button,{selected:A===U&&x===J,content:D[F+G],mb:"0",onClick:function(){function se(){return I(P,{block:U,subblock:J})}return se}()}))},G=0;Gd.spawnpoints?"red":"green",children:[d.total," total, versus ",d.spawnpoints," spawnpoints"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Dispatch",children:(0,e.createComponentVNode)(2,t.Button,{width:10.5,textAlign:"center",icon:"ambulance",content:"Send ERT",onClick:function(){function N(){return s("dispatch_ert",{silent:v})}return N}()})})]})})})},h=function(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,C=d.ert_request_messages;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:C&&C.length?C.map(function(g){return(0,e.createComponentVNode)(2,t.Section,{title:g.time,buttons:(0,e.createComponentVNode)(2,t.Button,{content:g.sender_real_name,onClick:function(){function v(){return s("view_player_panel",{uid:g.sender_uid})}return v}(),tooltip:"View player panel"}),children:g.message},(0,p.decodeHtmlEntities)(g.time))}):(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"average",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"broadcast-tower",size:5,color:"gray"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"No ERT requests."]})})})})},i=function(m,l){var u=(0,a.useBackend)(l),s=u.act,d=u.data,C=(0,a.useLocalState)(l,"text",""),g=C[0],v=C[1];return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Input,{placeholder:"Enter ERT denial reason here,\nMultiline input is accepted.",rows:19,fluid:!0,multiline:1,value:g,onChange:function(){function f(N,V){return v(V)}return f}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Deny ERT",fluid:!0,icon:"times",center:!0,mt:2,textAlign:"center",onClick:function(){function f(){return s("deny_ert",{reason:g})}return f}()})]})})}},90217:function(T,r,n){"use strict";r.__esModule=!0,r.EconomyManager=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=r.EconomyManager=function(){function S(k,h){return(0,e.createComponentVNode)(2,o.Window,{width:600,height:325,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,className:"Layout__content--flexColumn",children:(0,e.createComponentVNode)(2,y)})]})}return S}(),y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.next_payroll_time;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.4rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"coins",verticalAlign:"middle",size:3,mr:"1rem"}),"Economy Manager"]}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.LabeledList,{label:"Pay Bonuses and Deductions",children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Global",children:(0,e.createComponentVNode)(2,t.Button,{icon:"dollar-sign",width:"auto",content:"Global Payroll Modification",onClick:function(){function u(){return c("payroll_modification",{mod_type:"global"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Department Accounts",children:(0,e.createComponentVNode)(2,t.Button,{icon:"dollar-sign",width:"auto",content:"Department Account Payroll Modification",onClick:function(){function u(){return c("payroll_modification",{mod_type:"department"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Department Members",children:(0,e.createComponentVNode)(2,t.Button,{icon:"dollar-sign",width:"auto",content:"Department Members Payroll Modification",onClick:function(){function u(){return c("payroll_modification",{mod_type:"department_members"})}return u}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Single Accounts",children:(0,e.createComponentVNode)(2,t.Button,{icon:"dollar-sign",width:"auto",content:"Crew Member Payroll Modification",onClick:function(){function u(){return c("payroll_modification",{mod_type:"crew_member"})}return u}()})})]}),(0,e.createVNode)(1,"hr"),(0,e.createComponentVNode)(2,t.Box,{mb:.5,children:["Next Payroll in: ",l," Minutes"]}),(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-left",width:"auto",color:"bad",content:"Delay Payroll",onClick:function(){function u(){return c("delay_payroll")}return u}()}),(0,e.createComponentVNode)(2,t.Button,{width:"auto",content:"Set Payroll Time",onClick:function(){function u(){return c("set_payroll")}return u}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-right",width:"auto",color:"good",content:"Accelerate Payroll",onClick:function(){function u(){return c("accelerate_payroll")}return u}()})]}),(0,e.createComponentVNode)(2,t.NoticeBox,{children:[(0,e.createVNode)(1,"b",null,"WARNING:",16)," You take full responsibility for unbalancing the economy with these buttons!"]})],4)}},82565:function(T,r,n){"use strict";r.__esModule=!0,r.Electropack=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.Electropack=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.act,c=h.data,m=c.power,l=c.code,u=c.frequency,s=c.minFrequency,d=c.maxFrequency;return(0,e.createComponentVNode)(2,p.Window,{width:360,height:135,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,o.Button,{icon:m?"power-off":"times",content:m?"On":"Off",selected:m,onClick:function(){function C(){return i("power")}return C}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Frequency",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"sync",content:"Reset",onClick:function(){function C(){return i("reset",{reset:"freq"})}return C}()}),children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,unit:"kHz",step:.2,stepPixelSize:6,minValue:s/10,maxValue:d/10,value:u/10,format:function(){function C(g){return(0,a.toFixed)(g,1)}return C}(),width:"80px",onChange:function(){function C(g,v){return i("freq",{freq:v})}return C}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Code",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"sync",content:"Reset",onClick:function(){function C(){return i("reset",{reset:"code"})}return C}()}),children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:1,stepPixelSize:6,minValue:1,maxValue:100,value:l,width:"80px",onChange:function(){function C(g,v){return i("code",{code:v})}return C}()})})]})})})})}return y}()},11243:function(T,r,n){"use strict";r.__esModule=!0,r.Emojipedia=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=n(98595),b=r.Emojipedia=function(){function S(k,h){var i=(0,t.useBackend)(h),c=i.data,m=c.emoji_list,l=(0,t.useLocalState)(h,"searchText",""),u=l[0],s=l[1],d=m.filter(function(C){return C.name.toLowerCase().includes(u.toLowerCase())});return(0,e.createComponentVNode)(2,p.Window,{width:325,height:400,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Emojipedia v1.0.1",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Input,{placeholder:"Search by name",value:u,onInput:function(){function C(g,v){return s(v)}return C}()}),(0,e.createComponentVNode)(2,o.Button,{tooltip:"Click on an emoji to copy its tag!",tooltipPosition:"bottom",icon:"circle-question"})],4),children:d.map(function(C){return(0,e.createComponentVNode)(2,o.Button,{m:1,color:"transparent",className:(0,a.classes)(["emoji16x16","emoji-"+C.name]),style:{transform:"scale(1.5)"},tooltip:C.name,onClick:function(){function g(){y(C.name)}return g}()},C.name)})})})})}return S}(),y=function(k){var h=document.createElement("input"),i=":"+k+":";h.value=i,document.body.appendChild(h),h.select(),document.execCommand("copy"),document.body.removeChild(h)}},36730:function(T,r,n){"use strict";r.__esModule=!0,r.EvolutionMenu=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=n(64795),y=n(88510),S=r.EvolutionMenu=function(){function i(c,m){return(0,e.createComponentVNode)(2,p.Window,{width:480,height:580,theme:"changeling",children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,h)]})})})}return i}(),k=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.evo_points,C=s.can_respec;return(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:"Evolution Points",height:5.5,children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{mt:.5,color:"label",children:"Points remaining:"}),(0,e.createComponentVNode)(2,o.Stack.Item,{mt:.5,ml:2,bold:!0,color:"#1b945c",children:d}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:[(0,e.createComponentVNode)(2,o.Button,{ml:2.5,disabled:!C,content:"Readapt",icon:"sync",onClick:function(){function g(){return u("readapt")}return g}()}),(0,e.createComponentVNode)(2,o.Button,{tooltip:"By transforming a humanoid into a husk, we gain the ability to readapt our chosen evolutions.",tooltipPosition:"bottom",icon:"question-circle"})]})]})})})},h=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.evo_points,C=s.ability_tabs,g=s.purchased_abilities,v=s.view_mode,f=(0,t.useLocalState)(m,"selectedTab",C[0]),N=f[0],V=f[1],B=(0,t.useLocalState)(m,"searchText",""),I=B[0],L=B[1],w=(0,t.useLocalState)(m,"ability_tabs",C[0].abilities),A=w[0],x=w[1],E=function(O,R){if(R===void 0&&(R=""),!O||O.length===0)return[];var F=(0,a.createSearch)(R,function(W){return W.name+"|"+W.description});return(0,b.flow)([(0,y.filter)(function(W){return W==null?void 0:W.name}),(0,y.filter)(F),(0,y.sortBy)(function(W){return W==null?void 0:W.name})])(O)},P=function(O){if(L(O),O==="")return x(N.abilities);x(E(C.map(function(R){return R.abilities}).flat(),O))},D=function(O){V(O),x(O.abilities),L("")};return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Abilities",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Input,{width:"200px",placeholder:"Search Abilities",onInput:function(){function M(O,R){P(R)}return M}(),value:I}),(0,e.createComponentVNode)(2,o.Button,{icon:v?"square-o":"check-square-o",selected:!v,content:"Compact",onClick:function(){function M(){return u("set_view_mode",{mode:0})}return M}()}),(0,e.createComponentVNode)(2,o.Button,{icon:v?"check-square-o":"square-o",selected:v,content:"Expanded",onClick:function(){function M(){return u("set_view_mode",{mode:1})}return M}()})],4),children:[(0,e.createComponentVNode)(2,o.Tabs,{children:C.map(function(M){return(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:I===""&&N===M,onClick:function(){function O(){D(M)}return O}(),children:M.category},M)})}),A.map(function(M,O){return(0,e.createComponentVNode)(2,o.Box,{p:.5,mx:-1,className:"candystripe",children:[(0,e.createComponentVNode)(2,o.Stack,{align:"center",children:[(0,e.createComponentVNode)(2,o.Stack.Item,{ml:.5,color:"#dedede",children:M.name}),g.includes(M.power_path)&&(0,e.createComponentVNode)(2,o.Stack.Item,{ml:2,bold:!0,color:"#1b945c",children:"(Purchased)"}),(0,e.createComponentVNode)(2,o.Stack.Item,{mr:3,textAlign:"right",grow:1,children:[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:["Cost:"," "]}),(0,e.createComponentVNode)(2,o.Box,{as:"span",bold:!0,color:"#1b945c",children:M.cost})]}),(0,e.createComponentVNode)(2,o.Stack.Item,{textAlign:"right",children:(0,e.createComponentVNode)(2,o.Button,{mr:.5,disabled:M.cost>d||g.includes(M.power_path),content:"Evolve",onClick:function(){function R(){return u("purchase",{power_path:M.power_path})}return R}()})})]}),!!v&&(0,e.createComponentVNode)(2,o.Stack,{color:"#8a8a8a",my:1,ml:1.5,width:"95%",children:M.description+" "+M.helptext})]},O)})]})})}},17370:function(T,r,n){"use strict";r.__esModule=!0,r.ExosuitFabricator=void 0;var e=n(89005),a=n(35840),t=n(25328),o=n(72253),p=n(36036),b=n(73379),y=n(98595),S=["id","amount","lineDisplay","onClick"];function k(f,N){if(f==null)return{};var V={};for(var B in f)if({}.hasOwnProperty.call(f,B)){if(N.includes(B))continue;V[B]=f[B]}return V}var h=2e3,i={bananium:"clown",tranquillite:"mime"},c=r.ExosuitFabricator=function(){function f(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.building,A=L.linked;return A?(0,e.createComponentVNode)(2,y.Window,{width:950,height:625,children:(0,e.createComponentVNode)(2,y.Window.Content,{className:"Exofab",children:[(0,e.createComponentVNode)(2,v),(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,l)}),w&&(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,u)})]})}),(0,e.createComponentVNode)(2,p.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,m)}),(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,s)})]})})]})]})}):(0,e.createComponentVNode)(2,g)}return f}(),m=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.materials,A=L.capacity,x=Object.values(w).reduce(function(E,P){return E+P},0);return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,title:"Materials",className:"Exofab__materials",buttons:(0,e.createComponentVNode)(2,p.Box,{color:"label",mt:"0.25rem",children:[(x/A*100).toPrecision(3),"% full"]}),children:["metal","glass","silver","gold","uranium","titanium","plasma","diamond","bluespace","bananium","tranquillite","plastic"].map(function(E){return(0,e.createComponentVNode)(2,d,{mt:-2,id:E,bold:E==="metal"||E==="glass",onClick:function(){function P(){return I("withdraw",{id:E})}return P}()},E)})})},l=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.curCategory,A=L.categories,x=L.designs,E=L.syncing,P=(0,o.useLocalState)(V,"searchText",""),D=P[0],M=P[1],O=(0,t.createSearch)(D,function(z){return z.name}),R=x.filter(O),F=(0,o.useLocalState)(V,"levelsModal",!1),W=F[0],U=F[1];return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,className:"Exofab__designs",title:(0,e.createComponentVNode)(2,p.Dropdown,{width:"19rem",className:"Exofab__dropdown",selected:w,options:A,onSelected:function(){function z($){return I("category",{cat:$})}return z}()}),buttons:(0,e.createComponentVNode)(2,p.Box,{mt:"2px",children:[(0,e.createComponentVNode)(2,p.Button,{icon:"plus",content:"Queue all",onClick:function(){function z(){return I("queueall")}return z}()}),(0,e.createComponentVNode)(2,p.Button,{icon:"info",content:"Show current tech levels",onClick:function(){function z(){return U(!0)}return z}()}),(0,e.createComponentVNode)(2,p.Button,{icon:"unlink",color:"red",tooltip:"Disconnect from R&D network",onClick:function(){function z(){return I("unlink")}return z}()})]}),children:[(0,e.createComponentVNode)(2,p.Input,{placeholder:"Search by name...",mb:"0.5rem",width:"100%",onInput:function(){function z($,G){return M(G)}return z}()}),R.map(function(z){return(0,e.createComponentVNode)(2,C,{design:z},z.id)}),R.length===0&&(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"No designs found."})]})},u=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.building,A=L.buildStart,x=L.buildEnd,E=L.worldTime;return(0,e.createComponentVNode)(2,p.Section,{className:"Exofab__building",stretchContents:!0,children:(0,e.createComponentVNode)(2,p.ProgressBar.Countdown,{start:A,current:E,end:x,children:(0,e.createComponentVNode)(2,p.Stack,{children:[(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Icon,{name:"cog",spin:!0})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:["Building ",w,"\xA0(",(0,e.createComponentVNode)(2,b.Countdown,{current:E,timeLeft:x-E,format:function(){function P(D,M){return M.substr(3)}return P}()}),")"]})]})})})},s=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.queue,A=L.processingQueue,x=Object.entries(L.queueDeficit).filter(function(P){return P[1]<0}),E=w.reduce(function(P,D){return P+D.time},0);return(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,className:"Exofab__queue",title:"Queue",buttons:(0,e.createComponentVNode)(2,p.Box,{children:[(0,e.createComponentVNode)(2,p.Button,{selected:A,icon:A?"toggle-on":"toggle-off",content:"Process",onClick:function(){function P(){return I("process")}return P}()}),(0,e.createComponentVNode)(2,p.Button,{disabled:w.length===0,icon:"eraser",content:"Clear",onClick:function(){function P(){return I("unqueueall")}return P}()})]}),children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:w.length===0?(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"The queue is empty."}):(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Stack.Item,{className:"Exofab__queue--queue",grow:!0,overflow:"auto",children:w.map(function(P,D){return(0,e.createComponentVNode)(2,p.Box,{color:P.notEnough&&"bad",children:[D+1,". ",P.name,D>0&&(0,e.createComponentVNode)(2,p.Button,{icon:"arrow-up",onClick:function(){function M(){return I("queueswap",{from:D+1,to:D})}return M}()}),D0&&(0,e.createComponentVNode)(2,p.Stack.Item,{className:"Exofab__queue--time",children:[(0,e.createComponentVNode)(2,p.Divider),"Processing time:",(0,e.createComponentVNode)(2,p.Icon,{name:"clock",mx:"0.5rem"}),(0,e.createComponentVNode)(2,p.Box,{inline:!0,bold:!0,children:new Date(E/10*1e3).toISOString().substr(14,5)})]}),Object.keys(x).length>0&&(0,e.createComponentVNode)(2,p.Stack.Item,{className:"Exofab__queue--deficit",shrink:"0",children:[(0,e.createComponentVNode)(2,p.Divider),"Lacking materials to complete:",x.map(function(P){return(0,e.createComponentVNode)(2,p.Box,{children:(0,e.createComponentVNode)(2,d,{id:P[0],amount:-P[1],lineDisplay:!0})},P[0])})]})],0)})})},d=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=N.id,A=N.amount,x=N.lineDisplay,E=N.onClick,P=k(N,S),D=L.materials[w]||0,M=A||D;if(!(M<=0&&!(w==="metal"||w==="glass"))){var O=A&&A>D;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,p.Stack,Object.assign({align:"center",className:(0,a.classes)(["Exofab__material",x&&"Exofab__material--line"])},P,{children:x?(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Stack.Item,{className:(0,a.classes)(["materials32x32",w])}),(0,e.createComponentVNode)(2,p.Stack.Item,{className:"Exofab__material--amount",color:O&&"bad",ml:0,mr:1,children:M.toLocaleString("en-US")})],4):(0,e.createFragment)([(0,e.createComponentVNode)(2,p.Stack.Item,{basis:"content",children:(0,e.createComponentVNode)(2,p.Button,{width:"85%",color:"transparent",onClick:E,children:(0,e.createComponentVNode)(2,p.Box,{mt:1,className:(0,a.classes)(["materials32x32",w])})})}),(0,e.createComponentVNode)(2,p.Stack.Item,{grow:"1",children:[(0,e.createComponentVNode)(2,p.Box,{className:"Exofab__material--name",children:w}),(0,e.createComponentVNode)(2,p.Box,{className:"Exofab__material--amount",children:[M.toLocaleString("en-US")," cm\xB3 (",Math.round(M/h*10)/10," ","sheets)"]})]})],4)})))}},C=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=N.design;return(0,e.createComponentVNode)(2,p.Box,{className:"Exofab__design",children:[(0,e.createComponentVNode)(2,p.Button,{disabled:w.notEnough||L.building,icon:"cog",content:w.name,onClick:function(){function A(){return I("build",{id:w.id})}return A}()}),(0,e.createComponentVNode)(2,p.Button,{icon:"plus-circle",onClick:function(){function A(){return I("queue",{id:w.id})}return A}()}),(0,e.createComponentVNode)(2,p.Box,{className:"Exofab__design--cost",children:Object.entries(w.cost).map(function(A){return(0,e.createComponentVNode)(2,p.Box,{children:(0,e.createComponentVNode)(2,d,{id:A[0],amount:A[1],lineDisplay:!0})},A[0])})}),(0,e.createComponentVNode)(2,p.Stack,{className:"Exofab__design--time",children:(0,e.createComponentVNode)(2,p.Stack.Item,{children:[(0,e.createComponentVNode)(2,p.Icon,{name:"clock"}),w.time>0?(0,e.createFragment)([w.time/10,(0,e.createTextVNode)(" seconds")],0):"Instant"]})})]})},g=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.controllers;return(0,e.createComponentVNode)(2,y.Window,{children:(0,e.createComponentVNode)(2,y.Window.Content,{children:(0,e.createComponentVNode)(2,p.Section,{title:"Setup Linkage",children:(0,e.createComponentVNode)(2,p.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,p.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:"Link"})]}),w.map(function(A){return(0,e.createComponentVNode)(2,p.Table.Row,{children:[(0,e.createComponentVNode)(2,p.Table.Cell,{children:A.addr}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:A.net_id}),(0,e.createComponentVNode)(2,p.Table.Cell,{children:(0,e.createComponentVNode)(2,p.Button,{content:"Link",icon:"link",onClick:function(){function x(){return I("linktonetworkcontroller",{target_controller:A.addr})}return x}()})})]},A.addr)})]})})})})},v=function(N,V){var B=(0,o.useBackend)(V),I=B.act,L=B.data,w=L.tech_levels,A=(0,o.useLocalState)(V,"levelsModal",!1),x=A[0],E=A[1];return x?(0,e.createComponentVNode)(2,p.Modal,{maxWidth:"75%",width:window.innerWidth+"px",maxHeight:window.innerHeight*.75+"px",mx:"auto",children:(0,e.createComponentVNode)(2,p.Section,{title:"Current tech levels",buttons:(0,e.createComponentVNode)(2,p.Button,{content:"Close",onClick:function(){function P(){E(!1)}return P}()}),children:(0,e.createComponentVNode)(2,p.LabeledList,{children:w.map(function(P){var D=P.name,M=P.level;return(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:D,children:M},D)})})})}):null}},59128:function(T,r,n){"use strict";r.__esModule=!0,r.ExperimentConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=new Map([[0,{text:"Conscious",color:"good"}],[1,{text:"Unconscious",color:"average"}],[2,{text:"Deceased",color:"bad"}]]),b=new Map([[0,{label:"Probe",icon:"thermometer"}],[1,{label:"Dissect",icon:"brain"}],[2,{label:"Analyze",icon:"search"}]]),y=r.ExperimentConsole=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.open,u=m.feedback,s=m.occupant,d=m.occupant_name,C=m.occupant_status,g=function(){function f(){if(!s)return(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No specimen detected."});var N=function(){function B(){return p.get(C)}return B}(),V=N();return(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:d}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:V.color,children:V.text}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Experiments",children:[0,1,2].map(function(B){return(0,e.createComponentVNode)(2,t.Button,{icon:b.get(B).icon,content:b.get(B).label,onClick:function(){function I(){return c("experiment",{experiment_type:B})}return I}()},B)})})]})}return f}(),v=g();return(0,e.createComponentVNode)(2,o.Window,{theme:"abductor",width:350,height:200,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:u})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Scanner",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:"Eject",disabled:!l,onClick:function(){function f(){return c("door")}return f}()}),children:v})]})})}return S}()},97086:function(T,r,n){"use strict";r.__esModule=!0,r.ExternalAirlockController=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=0,b=1013,y=function(h){var i="good",c=80,m=95,l=110,u=120;return hl?i="average":h>u&&(i="bad"),i},S=r.ExternalAirlockController=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.chamber_pressure,s=l.exterior_status,d=l.interior_status,C=l.processing;return(0,e.createComponentVNode)(2,o.Window,{width:330,height:205,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Information",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Chamber Pressure",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:y(u),value:u,minValue:p,maxValue:b,children:[u," kPa"]})})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Actions",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Abort",icon:"ban",color:"red",disabled:!C,onClick:function(){function g(){return m("abort")}return g}()}),children:[(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{width:"49%",content:"Cycle to Exterior",icon:"arrow-circle-left",disabled:C,onClick:function(){function g(){return m("cycle_ext")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{width:"50%",content:"Cycle to Interior",icon:"arrow-circle-right",disabled:C,onClick:function(){function g(){return m("cycle_int")}return g}()})]}),(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{width:"49%",content:"Force Exterior Door",icon:"exclamation-triangle",color:d==="open"?"red":C?"yellow":null,onClick:function(){function g(){return m("force_ext")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{width:"50%",content:"Force Interior Door",icon:"exclamation-triangle",color:d==="open"?"red":C?"yellow":null,onClick:function(){function g(){return m("force_int")}return g}()})]})]})]})})}return k}()},96142:function(T,r,n){"use strict";r.__esModule=!0,r.FaxMachine=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.FaxMachine=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;return(0,e.createComponentVNode)(2,o.Window,{width:540,height:295,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Authorization",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID Card",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.scan_name?"eject":"id-card",selected:i.scan_name,content:i.scan_name?i.scan_name:"-----",tooltip:i.scan_name?"Eject ID":"Insert ID",onClick:function(){function c(){return h("scan")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Authorize",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.authenticated?"sign-out-alt":"id-card",selected:i.authenticated,disabled:i.nologin,content:i.realauth?"Log Out":"Log In",onClick:function(){function c(){return h("auth")}return c}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Fax Menu",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Network",children:i.network}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Document",children:[(0,e.createComponentVNode)(2,t.Button,{icon:i.paper?"eject":"paperclip",disabled:!i.authenticated&&!i.paper,content:i.paper?i.paper:"-----",onClick:function(){function c(){return h("paper")}return c}()}),!!i.paper&&(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:"Rename",onClick:function(){function c(){return h("rename")}return c}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Sending To",children:(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:i.destination?i.destination:"-----",disabled:!i.authenticated,onClick:function(){function c(){return h("dept")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Action",children:(0,e.createComponentVNode)(2,t.Button,{icon:"envelope",content:i.sendError?i.sendError:"Send",disabled:!i.paper||!i.destination||!i.authenticated||i.sendError,onClick:function(){function c(){return h("send")}return c}()})})]})})]})})}return b}()},74123:function(T,r,n){"use strict";r.__esModule=!0,r.FilingCabinet=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.FilingCabinet=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=k.config,m=i.contents,l=c.title;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:300,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Contents",children:[!m&&(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"average",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"folder-open",size:5,color:"gray"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"The ",l," is empty."]})}),!!m&&m.slice().map(function(u){return(0,e.createComponentVNode)(2,t.Stack,{mt:.5,className:"candystripe",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"80%",children:u.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-down",content:"Retrieve",onClick:function(){function s(){return h("retrieve",{index:u.index})}return s}()})})]},u)})]})})})})}return b}()},83767:function(T,r,n){"use strict";r.__esModule=!0,r.FloorPainter=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=k.icon_state,u=k.direction,s=k.isSelected,d=k.onSelect;return(0,e.createComponentVNode)(2,t.DmIcon,{icon:m.icon,icon_state:l,direction:u,onClick:d,style:{"border-style":s&&"solid"||"none","border-width":"2px","border-color":"orange",padding:s&&"0px"||"2px"}})},b={NORTH:1,SOUTH:2,EAST:4,WEST:8},y=r.FloorPainter=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.availableStyles,u=m.selectedStyle,s=m.selectedDir;return(0,e.createComponentVNode)(2,o.Window,{width:405,height:475,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Decal setup",children:[(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-left",onClick:function(){function d(){return c("cycle_style",{offset:-1})}return d}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Dropdown,{options:l,selected:u,width:"150px",nochevron:!0,onSelected:function(){function d(C){return c("select_style",{style:C})}return d}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-right",onClick:function(){function d(){return c("cycle_style",{offset:1})}return d}()})})]}),(0,e.createComponentVNode)(2,t.Box,{mt:"5px",mb:"5px",children:(0,e.createComponentVNode)(2,t.Flex,{overflowY:"auto",maxHeight:"239px",wrap:"wrap",children:l.map(function(d){return(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,p,{icon_state:d,isSelected:u===d,onSelect:function(){function C(){return c("select_style",{style:d})}return C}()})},d)})})}),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Direction",children:(0,e.createComponentVNode)(2,t.Table,{style:{display:"inline"},children:[b.NORTH,null,b.SOUTH].map(function(d){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[d+b.WEST,d,d+b.EAST].map(function(C){return(0,e.createComponentVNode)(2,t.Table.Cell,{style:{"vertical-align":"middle","text-align":"center"},children:C===null?(0,e.createComponentVNode)(2,t.Icon,{name:"arrows-alt",size:3}):(0,e.createComponentVNode)(2,p,{icon_state:u,direction:C,isSelected:C===s,onSelect:function(){function g(){return c("select_direction",{direction:C})}return g}()})},C)})},d)})})})})]})})})}return S}()},53424:function(T,r,n){"use strict";r.__esModule=!0,r.GPS=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=function(l){return l?"("+l.join(", ")+")":"ERROR"},y=function(l,u){if(!(!l||!u)){if(l[2]!==u[2])return null;var s=Math.atan2(u[1]-l[1],u[0]-l[0]),d=Math.sqrt(Math.pow(u[1]-l[1],2)+Math.pow(u[0]-l[0],2));return{angle:(0,a.rad2deg)(s),distance:d}}},S=r.GPS=function(){function m(l,u){var s=(0,t.useBackend)(u),d=s.data,C=d.emped,g=d.active,v=d.area,f=d.position,N=d.saved;return(0,e.createComponentVNode)(2,p.Window,{width:400,height:600,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:C?(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,basis:"0",children:(0,e.createComponentVNode)(2,k,{emp:!0})}):(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,h)}),g?(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,i,{area:v,position:f})}),N&&(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,i,{title:"Saved Position",position:N})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,basis:"0",children:(0,e.createComponentVNode)(2,c,{height:"100%"})})],0):(0,e.createComponentVNode)(2,k)],0)})})})}return m}(),k=function(l,u){var s=l.emp;return(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:(0,e.createComponentVNode)(2,o.Box,{width:"100%",height:"100%",color:"label",textAlign:"center",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon,{name:s?"ban":"power-off",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),s?"ERROR: Device temporarily lost signal.":"Device is disabled."]})})})})},h=function(l,u){var s=(0,t.useBackend)(u),d=s.act,C=s.data,g=C.active,v=C.tag,f=C.same_z,N=(0,t.useLocalState)(u,"newTag",v),V=N[0],B=N[1];return(0,e.createComponentVNode)(2,o.Section,{title:"Settings",buttons:(0,e.createComponentVNode)(2,o.Button,{selected:g,icon:g?"toggle-on":"toggle-off",content:g?"On":"Off",onClick:function(){function I(){return d("toggle")}return I}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Tag",children:[(0,e.createComponentVNode)(2,o.Input,{width:"5rem",value:v,onEnter:function(){function I(){return d("tag",{newtag:V})}return I}(),onInput:function(){function I(L,w){return B(w)}return I}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:v===V,width:"20px",mb:"0",ml:"0.25rem",onClick:function(){function I(){return d("tag",{newtag:V})}return I}(),children:(0,e.createComponentVNode)(2,o.Icon,{name:"pen"})})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Range",children:(0,e.createComponentVNode)(2,o.Button,{selected:!f,icon:f?"compress":"expand",content:f?"Local Sector":"Global",onClick:function(){function I(){return d("same_z")}return I}()})})]})})},i=function(l,u){var s=l.title,d=l.area,C=l.position;return(0,e.createComponentVNode)(2,o.Section,{title:s||"Position",children:(0,e.createComponentVNode)(2,o.Box,{fontSize:"1.5rem",children:[d&&(0,e.createFragment)([d,(0,e.createVNode)(1,"br")],0),b(C)]})})},c=function(l,u){var s=(0,t.useBackend)(u),d=s.data,C=d.position,g=d.signals;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({fill:!0,scrollable:!0,title:"Signals"},l,{children:(0,e.createComponentVNode)(2,o.Table,{children:g.map(function(v){return Object.assign({},v,y(C,v.position))}).map(function(v,f){return(0,e.createComponentVNode)(2,o.Table.Row,{backgroundColor:f%2===0&&"rgba(255, 255, 255, 0.05)",children:[(0,e.createComponentVNode)(2,o.Table.Cell,{width:"30%",verticalAlign:"middle",color:"label",p:"0.25rem",bold:!0,children:v.tag}),(0,e.createComponentVNode)(2,o.Table.Cell,{verticalAlign:"middle",color:"grey",children:v.area}),(0,e.createComponentVNode)(2,o.Table.Cell,{verticalAlign:"middle",collapsing:!0,children:v.distance!==void 0&&(0,e.createComponentVNode)(2,o.Box,{opacity:Math.max(1-Math.min(v.distance,100)/100,.5),children:[(0,e.createComponentVNode)(2,o.Icon,{name:v.distance>0?"arrow-right":"circle",rotation:-v.angle}),"\xA0",Math.floor(v.distance)+"m"]})}),(0,e.createComponentVNode)(2,o.Table.Cell,{verticalAlign:"middle",pr:"0.25rem",collapsing:!0,children:b(v.position)})]},f)})})})))}},89124:function(T,r,n){"use strict";r.__esModule=!0,r.GeneModder=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(3939),p=n(98595),b=r.GeneModder=function(){function u(s,d){var C=(0,a.useBackend)(d),g=C.data,v=g.has_seed;return(0,e.createComponentVNode)(2,p.Window,{width:950,height:650,children:[(0,e.createVNode)(1,"div","GeneModder__left",(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,l,{scrollable:!0})}),2),(0,e.createVNode)(1,"div","GeneModder__right",(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:[(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,o.ComplexModal,{maxWidth:"75%",maxHeight:"75%"}),v===0?(0,e.createComponentVNode)(2,S):(0,e.createComponentVNode)(2,y)]})}),2)]})}return u}(),y=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.disk;return(0,e.createComponentVNode)(2,t.Section,{title:"Genes",fill:!0,scrollable:!0,children:[(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c)]})},S=function(s,d){return(0,e.createComponentVNode)(2,t.Section,{fill:!0,height:"85%",children:(0,e.createComponentVNode)(2,t.Stack,{height:"100%",children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:"1",textAlign:"center",align:"center",color:"green",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"leaf",size:5,mb:"10px"}),(0,e.createVNode)(1,"br"),"The plant DNA manipulator is missing a seed."]})})})},k=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.has_seed,N=v.seed,V=v.has_disk,B=v.disk,I,L;return f?I=(0,e.createComponentVNode)(2,t.Stack.Item,{mb:"-6px",mt:"-4px",children:[(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+N.image,style:{"vertical-align":"middle",width:"32px",margin:"-1px","margin-left":"-11px"}}),(0,e.createComponentVNode)(2,t.Button,{content:N.name,onClick:function(){function w(){return g("eject_seed")}return w}()}),(0,e.createComponentVNode)(2,t.Button,{ml:"3px",icon:"pen",tooltip:"Name Variant",onClick:function(){function w(){return g("variant_name")}return w}()})]}):I=(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{ml:3.3,content:"None",onClick:function(){function w(){return g("eject_seed")}return w}()})}),V?L=B.name:L="None",(0,e.createComponentVNode)(2,t.Section,{title:"Storage",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Plant Sample",children:I}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Data Disk",children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{ml:3.3,content:L,tooltip:"Select Empty Disk",onClick:function(){function w(){return g("select_empty_disk")}return w}()})})})]})})},h=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.disk,N=v.core_genes;return(0,e.createComponentVNode)(2,t.Collapsible,{title:"Core Genes",open:!0,children:[N.map(function(V){return(0,e.createComponentVNode)(2,t.Stack,{py:"2px",className:"candystripe",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"100%",ml:"2px",children:V.name}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Extract",disabled:!(f!=null&&f.can_extract),icon:"save",onClick:function(){function B(){return g("extract",{id:V.id})}return B}()})})]},V)})," ",(0,e.createComponentVNode)(2,t.Stack,{children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Extract All",disabled:!(f!=null&&f.can_extract),icon:"save",onClick:function(){function V(){return g("bulk_extract_core")}return V}()})})})]},"Core Genes")},i=function(s,d){var C=(0,a.useBackend)(d),g=C.data,v=g.reagent_genes,f=g.has_reagent;return(0,e.createComponentVNode)(2,m,{title:"Reagent Genes",gene_set:v,do_we_show:f})},c=function(s,d){var C=(0,a.useBackend)(d),g=C.data,v=g.trait_genes,f=g.has_trait;return(0,e.createComponentVNode)(2,m,{title:"Trait Genes",gene_set:v,do_we_show:f})},m=function(s,d){var C=s.title,g=s.gene_set,v=s.do_we_show,f=(0,a.useBackend)(d),N=f.act,V=f.data,B=V.disk;return(0,e.createComponentVNode)(2,t.Collapsible,{title:C,open:!0,children:v?g.map(function(I){return(0,e.createComponentVNode)(2,t.Stack,{py:"2px",className:"candystripe",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"100%",ml:"2px",children:I.name}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Extract",disabled:!(B!=null&&B.can_extract),icon:"save",onClick:function(){function L(){return N("extract",{id:I.id})}return L}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Remove",icon:"times",onClick:function(){function L(){return N("remove",{id:I.id})}return L}()})})]},I)}):(0,e.createComponentVNode)(2,t.Stack.Item,{children:"No Genes Detected"})},C)},l=function(s,d){var C=s.title,g=s.gene_set,v=s.do_we_show,f=(0,a.useBackend)(d),N=f.act,V=f.data,B=V.has_seed,I=V.empty_disks,L=V.stat_disks,w=V.trait_disks,A=V.reagent_disks;return(0,e.createComponentVNode)(2,t.Section,{title:"Disks",children:[(0,e.createVNode)(1,"br"),"Empty Disks: ",I,(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{width:12,icon:"arrow-down",tooltip:"Eject an Empty disk",content:"Eject Empty Disk",onClick:function(){function x(){return N("eject_empty_disk")}return x}()}),(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Stats",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:[L.slice().sort(function(x,E){return x.display_name.localeCompare(E.display_name)}).map(function(x){return(0,e.createComponentVNode)(2,t.Stack,{mr:2,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"49%",children:x.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:25,children:[x.stat==="All"?(0,e.createComponentVNode)(2,t.Button,{content:"Replace All",tooltip:"Write disk stats to seed",disabled:!(x!=null&&x.ready)||!B,icon:"arrow-circle-down",onClick:function(){function E(){return N("bulk_replace_core",{index:x.index})}return E}()}):(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-circle-down",tooltip:"Write disk stat to seed",disabled:!x||!B,content:"Replace",onClick:function(){function E(){return N("replace",{index:x.index,stat:x.stat})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-right",content:"Select",tooltip:"Choose as target for extracted genes",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("select",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:5,icon:"arrow-down",content:"Eject",tooltip:"Eject Disk",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("eject_disk",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:2,icon:x.read_only?"lock":"lock-open",content:"",tool_tip:"Set/unset Read Only",onClick:function(){function E(){return N("set_read_only",{index:x.index,read_only:x.read_only})}return E}()})]})]},x)}),(0,e.createComponentVNode)(2,t.Button)]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Traits",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:[w.slice().sort(function(x,E){return x.display_name.localeCompare(E.display_name)}).map(function(x){return(0,e.createComponentVNode)(2,t.Stack,{mr:2,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"49%",children:x.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:25,children:[(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-circle-down",disabled:!x||!x.can_insert,tooltip:"Add disk trait to seed",content:"Insert",onClick:function(){function E(){return N("insert",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-right",content:"Select",tooltip:"Choose as target for extracted genes",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("select",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:5,icon:"arrow-down",content:"Eject",tooltip:"Eject Disk",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("eject_disk",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:2,icon:x.read_only?"lock":"lock-open",content:"",tool_tip:"Set/unset Read Only",onClick:function(){function E(){return N("set_read_only",{index:x.index,read_only:x.read_only})}return E}()})]})]},x)}),(0,e.createComponentVNode)(2,t.Button)]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Reagents",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,scrollable:!0,children:[A.slice().sort(function(x,E){return x.display_name.localeCompare(E.display_name)}).map(function(x){return(0,e.createComponentVNode)(2,t.Stack,{mr:2,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"49%",children:x.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:25,children:[(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-circle-down",disabled:!x||!x.can_insert,tooltip:"Add disk reagent to seed",content:"Insert",onClick:function(){function E(){return N("insert",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:6,icon:"arrow-right",content:"Select",tooltip:"Choose as target for extracted genes",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("select",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:5,icon:"arrow-down",content:"Eject",tooltip:"Eject Disk",tooltipPosition:"bottom-start",onClick:function(){function E(){return N("eject_disk",{index:x.index})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{width:2,icon:x.read_only?"lock":"lock-open",content:"",tool_tip:"Set/unset Read Only",onClick:function(){function E(){return N("set_read_only",{index:x.index,read_only:x.read_only})}return E}()})]})]},x)}),(0,e.createComponentVNode)(2,t.Button)]})})]})]})}},73053:function(T,r,n){"use strict";r.__esModule=!0,r.GenericCrewManifest=void 0;var e=n(89005),a=n(36036),t=n(98595),o=n(41874),p=r.GenericCrewManifest=function(){function b(y,S){return(0,e.createComponentVNode)(2,t.Window,{theme:"nologo",width:588,height:510,children:(0,e.createComponentVNode)(2,t.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,a.Section,{noTopPadding:!0,children:(0,e.createComponentVNode)(2,o.CrewManifest)})})})}return b}()},42914:function(T,r,n){"use strict";r.__esModule=!0,r.GhostHudPanel=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.GhostHudPanel=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.data,c=i.security,m=i.medical,l=i.diagnostic,u=i.radioactivity,s=i.ahud;return(0,e.createComponentVNode)(2,o.Window,{width:250,height:207,theme:"nologo",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,b,{label:"Medical",type:"medical",is_active:m}),(0,e.createComponentVNode)(2,b,{label:"Security",type:"security",is_active:c}),(0,e.createComponentVNode)(2,b,{label:"Diagnostic",type:"diagnostic",is_active:l}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,b,{label:"Radioactivity",type:"radioactivity",is_active:u,act_on:"rads_on",act_off:"rads_off"}),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,b,{label:"Antag HUD",is_active:s,act_on:"ahud_on",act_off:"ahud_off"})]})})})}return y}(),b=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=S.label,m=S.type,l=m===void 0?null:m,u=S.is_active,s=S.act_on,d=s===void 0?"hud_on":s,C=S.act_off,g=C===void 0?"hud_off":C;return(0,e.createComponentVNode)(2,t.Flex,{pt:.3,color:"label",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{pl:.5,align:"center",width:"80%",children:c}),(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Button,{mr:.6,content:u?"On":"Off",icon:u?"toggle-on":"toggle-off",selected:u,onClick:function(){function v(){return i(u?g:d,{hud_type:l})}return v}()})})]})}},25825:function(T,r,n){"use strict";r.__esModule=!0,r.GlandDispenser=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.GlandDispenser=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.glands,m=c===void 0?[]:c;return(0,e.createComponentVNode)(2,o.Window,{width:300,height:338,theme:"abductor",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:m.map(function(l){return(0,e.createComponentVNode)(2,t.Button,{width:"60px",height:"60px",m:.75,textAlign:"center",fontSize:"17px",lineHeight:"55px",icon:"eject",backgroundColor:l.color,content:l.amount||"0",disabled:!l.amount,onClick:function(){function u(){return h("dispense",{gland_id:l.id})}return u}()},l.id)})})})})}return b}()},10270:function(T,r,n){"use strict";r.__esModule=!0,r.GravityGen=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.GravityGen=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.charging_state,m=i.charge_count,l=i.breaker,u=i.ext_power,s=function(){function C(g){return g>0?(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:"average",children:["[ ",g===1?"Charging":"Discharging"," ]"]}):(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:u?"good":"bad",children:["[ ",u?"Powered":"Unpowered"," ]"]})}return C}(),d=function(){function C(g){if(g>0)return(0,e.createComponentVNode)(2,t.NoticeBox,{danger:!0,p:1.5,children:[(0,e.createVNode)(1,"b",null,"WARNING:",16)," Radiation Detected!"]})}return C}();return(0,e.createComponentVNode)(2,o.Window,{width:350,height:170,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[d(c),(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Generator Status",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:l?"power-off":"times",content:l?"Online":"Offline",color:l?"green":"red",px:1.5,onClick:function(){function C(){return h("breaker")}return C}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power Status",color:u?"good":"bad",children:s(c)}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Gravity Charge",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:m/100,ranges:{good:[.9,1/0],average:[.5,.9],bad:[-1/0,.5]}})})]})})]})})})}return b}()},48657:function(T,r,n){"use strict";r.__esModule=!0,r.GuestPass=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(49148),b=r.GuestPass=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:690,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"id-card",selected:!c.showlogs,onClick:function(){function m(){return i("mode",{mode:0})}return m}(),children:"Issue Pass"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"scroll",selected:c.showlogs,onClick:function(){function m(){return i("mode",{mode:1})}return m}(),children:["Records (",c.issue_log.length,")"]})]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Authorization",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID Card",children:(0,e.createComponentVNode)(2,t.Button,{icon:c.scan_name?"eject":"id-card",selected:c.scan_name,content:c.scan_name?c.scan_name:"-----",tooltip:c.scan_name?"Eject ID":"Insert ID",onClick:function(){function m(){return i("scan")}return m}()})})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:!c.showlogs&&(0,e.createComponentVNode)(2,t.Section,{title:"Issue Guest Pass",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Issue To",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:c.giv_name?c.giv_name:"-----",disabled:!c.scan_name,onClick:function(){function m(){return i("giv_name")}return m}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Reason",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:c.reason?c.reason:"-----",disabled:!c.scan_name,onClick:function(){function m(){return i("reason")}return m}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Duration",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pencil-alt",content:c.duration?c.duration:"-----",disabled:!c.scan_name,onClick:function(){function m(){return i("duration")}return m}()})})]})})}),!c.showlogs&&(c.scan_name?(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.AccessList,{sectionButtons:(0,e.createComponentVNode)(2,t.Button,{icon:"id-card",content:c.printmsg,disabled:!c.canprint,onClick:function(){function m(){return i("issue")}return m}()}),grantableList:c.grantableList,accesses:c.regions,selectedList:c.selectedAccess,accessMod:function(){function m(l){return i("access",{access:l})}return m}(),grantAll:function(){function m(){return i("grant_all")}return m}(),denyAll:function(){function m(){return i("clear_all")}return m}(),grantDep:function(){function m(l){return i("grant_region",{region:l})}return m}(),denyDep:function(){function m(l){return i("deny_region",{region:l})}return m}()})}):(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,fontSize:1.5,textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"id-card",size:5,color:"gray",mb:5}),(0,e.createVNode)(1,"br"),"Please, insert ID Card"]})})})})),!!c.showlogs&&(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,m:0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Issuance Log",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:"Print",disabled:!c.scan_name,onClick:function(){function m(){return i("print")}return m}()}),children:!!c.issue_log.length&&(0,e.createComponentVNode)(2,t.LabeledList,{children:c.issue_log.map(function(m,l){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:m},l)})})||(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,fontSize:1.5,textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"scroll",size:5,color:"gray"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"No logs"]})})})})]})})})}return y}()},67834:function(T,r,n){"use strict";r.__esModule=!0,r.HandheldChemDispenser=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=[1,5,10,20,30,50],b=null,y=r.HandheldChemDispenser=function(){function h(i,c){return(0,e.createComponentVNode)(2,o.Window,{width:390,height:430,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k)]})})})}return h}(),S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.amount,d=u.energy,C=u.maxEnergy,g=u.mode;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Energy",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:d,minValue:0,maxValue:C,ranges:{good:[C*.5,1/0],average:[C*.25,C*.5],bad:[-1/0,C*.25]},children:[d," / ",C," Units"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Amount",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,t.Stack,{children:p.map(function(v,f){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,width:"15%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"cog",selected:s===v,content:v,onClick:function(){function N(){return l("amount",{amount:v})}return N}()})},f)})})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mode",verticalAlign:"middle",children:(0,e.createComponentVNode)(2,t.Stack,{justify:"space-between",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"cog",selected:g==="dispense",content:"Dispense",m:"0",width:"32%",onClick:function(){function v(){return l("mode",{mode:"dispense"})}return v}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"cog",selected:g==="remove",content:"Remove",m:"0",width:"32%",onClick:function(){function v(){return l("mode",{mode:"remove"})}return v}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"cog",selected:g==="isolate",content:"Isolate",m:"0",width:"32%",onClick:function(){function v(){return l("mode",{mode:"isolate"})}return v}()})]})})]})})})},k=function(i,c){for(var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.chemicals,d=s===void 0?[]:s,C=u.current_reagent,g=[],v=0;v<(d.length+1)%3;v++)g.push(!0);return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,height:"18%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:u.glass?"Drink Selector":"Chemical Selector",children:[d.map(function(f,N){return(0,e.createComponentVNode)(2,t.Button,{width:"32%",icon:"arrow-circle-down",overflow:"hidden",textOverflow:"ellipsis",selected:C===f.id,content:f.title,style:{"margin-left":"2px"},onClick:function(){function V(){return l("dispense",{reagent:f.id})}return V}()},N)}),g.map(function(f,N){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:"1",basis:"25%"},N)})]})})}},46098:function(T,r,n){"use strict";r.__esModule=!0,r.HealthSensor=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.HealthSensor=function(){function S(k,h){var i=(0,t.useBackend)(h),c=i.act,m=i.data,l=m.on,u=m.user_health,s=m.minHealth,d=m.maxHealth,C=m.alarm_health;return(0,e.createComponentVNode)(2,p.Window,{width:300,height:125,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Scanning",children:(0,e.createComponentVNode)(2,o.Button,{icon:"power-off",content:l?"On":"Off",color:l?null:"red",selected:l,onClick:function(){function g(){return c("scan_toggle")}return g}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Health activation",children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:2,stepPixelSize:6,minValue:s,maxValue:d,value:C,format:function(){function g(v){return(0,a.toFixed)(v,1)}return g}(),width:"80px",onDrag:function(){function g(v,f){return c("alarm_health",{alarm_health:f})}return g}()})}),u!==null&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"User health",children:(0,e.createComponentVNode)(2,o.Box,{color:y(u),bold:u>=100,children:(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:u})})})]})})})})}return S}(),y=function(k){return k>50?"green":k>0?"orange":"red"}},36771:function(T,r,n){"use strict";r.__esModule=!0,r.Holodeck=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Holodeck=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=(0,a.useLocalState)(k,"currentDeck",""),l=m[0],u=m[1],s=(0,a.useLocalState)(k,"showReload",!1),d=s[0],C=s[1],g=c.decks,v=c.ai_override,f=c.emagged,N=function(){function V(B){i("select_deck",{deck:B}),u(B),C(!0),setTimeout(function(){C(!1)},3e3)}return V}();return(0,e.createComponentVNode)(2,o.Window,{width:400,height:320,children:[d&&(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Holodeck Control System",children:(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createVNode)(1,"b",null,"Currently Loaded Program:",16)," ",l]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Available Programs",children:[g.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{width:15.5,color:"transparent",content:V,selected:V===l,onClick:function(){function B(){return N(V)}return B}()},V)}),(0,e.createVNode)(1,"hr",null,null,1,{color:"gray"}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[!!v&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Override Protocols",children:(0,e.createComponentVNode)(2,t.Button,{content:f?"Turn On":"Turn Off",color:f?"good":"bad",onClick:function(){function V(){return i("ai_override")}return V}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Safety Protocols",children:(0,e.createComponentVNode)(2,t.Box,{color:f?"bad":"good",children:[f?"Off":"On",!!f&&(0,e.createComponentVNode)(2,t.Button,{ml:9.5,width:15.5,color:"red",content:"Wildlife Simulation",onClick:function(){function V(){return i("wildlifecarp")}return V}()})]})})]})]})})]})})]})}return y}(),b=function(S,k){return(0,e.createComponentVNode)(2,t.Dimmer,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"spinner",size:"5",spin:!0}),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Box,{color:"white",children:(0,e.createVNode)(1,"h1",null,"\xA0Recalibrating projection apparatus.\xA0",16)}),(0,e.createComponentVNode)(2,t.Box,{color:"label",children:(0,e.createVNode)(1,"h3",null,"Please, wait for 3 seconds.",16)})]})}},25471:function(T,r,n){"use strict";r.__esModule=!0,r.Instrument=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.Instrument=function(){function i(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data;return(0,e.createComponentVNode)(2,p.Window,{width:600,height:505,children:[(0,e.createComponentVNode)(2,y),(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,h)]})})]})}return i}(),y=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.help;if(d)return(0,e.createComponentVNode)(2,o.Modal,{maxWidth:"75%",height:window.innerHeight*.75+"px",mx:"auto",py:"0",px:"0.5rem",children:(0,e.createComponentVNode)(2,o.Section,{height:"100%",title:"Help",level:"2",overflow:"auto",children:(0,e.createComponentVNode)(2,o.Box,{px:"0.5rem",mt:"-0.5rem",children:[(0,e.createVNode)(1,"h1",null,"Making a Song",16),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Lines are a series of chords, separated by commas\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"(,)"}),(0,e.createTextVNode)(", each with notes separated by hyphens\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"(-)"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Every note in a chord will play together, with the chord timed by the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"tempo"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("as defined above.")],0),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Notes are played by the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"names of the note"}),(0,e.createTextVNode)(", and optionally, the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"accidental"}),(0,e.createTextVNode)(", and/or the"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave number"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("By default, every note is\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"natural"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("and in\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave 3"}),(0,e.createTextVNode)(". Defining a different state for either is remembered for each"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"note"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"Example:"}),(0,e.createTextVNode)("\xA0"),(0,e.createVNode)(1,"i",null,"C,D,E,F,G,A,B",16),(0,e.createTextVNode)(" will play a\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"C"}),(0,e.createTextVNode)("\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"major"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("scale.")],0),(0,e.createVNode)(1,"li",null,[(0,e.createTextVNode)("After a note has an\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"accidental"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("or\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("placed, it will be remembered:\xA0"),(0,e.createVNode)(1,"i",null,"C,C4,C#,C3",16),(0,e.createTextVNode)(" is "),(0,e.createVNode)(1,"i",null,"C3,C4,C4#,C3#",16)],0)],4)],0),(0,e.createVNode)(1,"p",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"Chords"}),(0,e.createTextVNode)("\xA0can be played simply by seperating each note with a hyphen: "),(0,e.createVNode)(1,"i",null,"A-C#,Cn-E,E-G#,Gn-B",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("A"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"pause"}),(0,e.createTextVNode)("\xA0may be denoted by an empty chord: "),(0,e.createVNode)(1,"i",null,"C,E,,C,G",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("To make a chord be a different time, end it with /x, where the chord length will be length defined by\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"tempo / x"}),(0,e.createTextVNode)(",\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"eg:"}),(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"i",null,"C,G/2,E/4",16),(0,e.createTextVNode)(".")],0),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Combined, an example line is: "),(0,e.createVNode)(1,"i",null,"E-E4/4,F#/2,G#/8,B/8,E3-E4/4",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,"Lines may be up to 300 characters.",16),(0,e.createVNode)(1,"li",null,"A song may only contain up to 1,000 lines.",16)],4)],4),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Lines are a series of chords, separated by commas\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"(,)"}),(0,e.createTextVNode)(", each with notes separated by hyphens\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"(-)"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Every note in a chord will play together, with the chord timed by the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"tempo"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("as defined above.")],0),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Notes are played by the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"names of the note"}),(0,e.createTextVNode)(", and optionally, the\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"accidental"}),(0,e.createTextVNode)(", and/or the"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave number"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("By default, every note is\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"natural"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("and in\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave 3"}),(0,e.createTextVNode)(". Defining a different state for either is remembered for each"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"note"}),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"Example:"}),(0,e.createTextVNode)("\xA0"),(0,e.createVNode)(1,"i",null,"C,D,E,F,G,A,B",16),(0,e.createTextVNode)(" will play a\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"good",children:"C"}),(0,e.createTextVNode)("\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"major"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("scale.")],0),(0,e.createVNode)(1,"li",null,[(0,e.createTextVNode)("After a note has an\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"average",children:"accidental"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("or\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"bad",children:"octave"}),(0,e.createTextVNode)(" "),(0,e.createTextVNode)("placed, it will be remembered:\xA0"),(0,e.createVNode)(1,"i",null,"C,C4,C#,C3",16),(0,e.createTextVNode)(" is "),(0,e.createVNode)(1,"i",null,"C3,C4,C4#,C3#",16)],0)],4)],0),(0,e.createVNode)(1,"p",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"Chords"}),(0,e.createTextVNode)("\xA0can be played simply by seperating each note with a hyphen: "),(0,e.createVNode)(1,"i",null,"A-C#,Cn-E,E-G#,Gn-B",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("A"),(0,e.createTextVNode)(" "),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"pause"}),(0,e.createTextVNode)("\xA0may be denoted by an empty chord: "),(0,e.createVNode)(1,"i",null,"C,E,,C,G",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("To make a chord be a different time, end it with /x, where the chord length will be length defined by\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"tempo / x"}),(0,e.createTextVNode)(",\xA0"),(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"highlight",children:"eg:"}),(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"i",null,"C,G/2,E/4",16),(0,e.createTextVNode)(".")],0),(0,e.createVNode)(1,"p",null,[(0,e.createTextVNode)("Combined, an example line is: "),(0,e.createVNode)(1,"i",null,"E-E4/4,F#/2,G#/8,B/8,E3-E4/4",16),(0,e.createTextVNode)("."),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,"Lines may be up to 300 characters.",16),(0,e.createVNode)(1,"li",null,"A song may only contain up to 1,000 lines.",16)],4)],4),(0,e.createVNode)(1,"h1",null,"Instrument Advanced Settings",16),(0,e.createVNode)(1,"ul",null,[(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Type:"}),(0,e.createTextVNode)("\xA0Whether the instrument is legacy or synthesized."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Legacy instruments have a collection of sounds that are selectively used depending on the note to play."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Synthesized instruments use a base sound and change its pitch to match the note to play.")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Current:"}),(0,e.createTextVNode)("\xA0Which instrument sample to play. Some instruments can be tuned to play different samples. Experiment!")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Note Shift/Note Transpose:"}),(0,e.createTextVNode)("\xA0The pitch to apply to all notes of the song.")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Sustain Mode:"}),(0,e.createTextVNode)("\xA0How a played note fades out."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Linear sustain means a note will fade out at a constant rate."),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Exponential sustain means a note will fade out at an exponential rate, sounding smoother.")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Volume Dropoff Threshold:"}),(0,e.createTextVNode)("\xA0The volume threshold at which a note is fully stopped.")],4),(0,e.createVNode)(1,"li",null,[(0,e.createComponentVNode)(2,o.Box,{as:"span",color:"label",children:"Sustain indefinitely last held note:"}),(0,e.createTextVNode)("\xA0Whether the last note should be sustained indefinitely.")],4)],4),(0,e.createComponentVNode)(2,o.Button,{color:"grey",content:"Close",onClick:function(){function C(){return u("help")}return C}()})]})})})},S=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.lines,C=s.playing,g=s.repeat,v=s.maxRepeats,f=s.tempo,N=s.minTempo,V=s.maxTempo,B=s.tickLag,I=s.volume,L=s.minVolume,w=s.maxVolume,A=s.ready;return(0,e.createComponentVNode)(2,o.Section,{title:"Instrument",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{icon:"info",content:"Help",onClick:function(){function x(){return u("help")}return x}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"file",content:"New",onClick:function(){function x(){return u("newsong")}return x}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"upload",content:"Import",onClick:function(){function x(){return u("import")}return x}()})],4),children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Playback",children:[(0,e.createComponentVNode)(2,o.Button,{selected:C,disabled:d.length===0||g<0,icon:"play",content:"Play",onClick:function(){function x(){return u("play")}return x}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:!C,icon:"stop",content:"Stop",onClick:function(){function x(){return u("stop")}return x}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Repeat",children:(0,e.createComponentVNode)(2,o.Slider,{animated:!0,minValue:0,maxValue:v,value:g,stepPixelSize:59,onChange:function(){function x(E,P){return u("repeat",{new:P})}return x}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Tempo",children:(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,o.Button,{disabled:f>=V,content:"-",as:"span",mr:"0.5rem",onClick:function(){function x(){return u("tempo",{new:f+B})}return x}()}),(0,a.round)(600/f)," BPM",(0,e.createComponentVNode)(2,o.Button,{disabled:f<=N,content:"+",as:"span",ml:"0.5rem",onClick:function(){function x(){return u("tempo",{new:f-B})}return x}()})]})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Volume",children:(0,e.createComponentVNode)(2,o.Slider,{animated:!0,minValue:L,maxValue:w,value:I,stepPixelSize:6,onDrag:function(){function x(E,P){return u("setvolume",{new:P})}return x}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Status",children:A?(0,e.createComponentVNode)(2,o.Box,{color:"good",children:"Ready"}):(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:"Instrument Definition Error!"})})]}),(0,e.createComponentVNode)(2,k)]})},k=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.allowedInstrumentNames,C=s.instrumentLoaded,g=s.instrument,v=s.canNoteShift,f=s.noteShift,N=s.noteShiftMin,V=s.noteShiftMax,B=s.sustainMode,I=s.sustainLinearDuration,L=s.sustainExponentialDropoff,w=s.legacy,A=s.sustainDropoffVolume,x=s.sustainHeldNote,E,P;return B===1?(E="Linear",P=(0,e.createComponentVNode)(2,o.Slider,{minValue:.1,maxValue:5,value:I,step:.5,stepPixelSize:85,format:function(){function D(M){return(0,a.round)(M*100)/100+" seconds"}return D}(),onChange:function(){function D(M,O){return u("setlinearfalloff",{new:O/10})}return D}()})):B===2&&(E="Exponential",P=(0,e.createComponentVNode)(2,o.Slider,{minValue:1.025,maxValue:10,value:L,step:.01,format:function(){function D(M){return(0,a.round)(M*1e3)/1e3+"% per decisecond"}return D}(),onChange:function(){function D(M,O){return u("setexpfalloff",{new:O})}return D}()})),d.sort(),(0,e.createComponentVNode)(2,o.Box,{my:-1,children:(0,e.createComponentVNode)(2,o.Collapsible,{mt:"1rem",mb:"0",title:"Advanced",children:(0,e.createComponentVNode)(2,o.Section,{mt:-1,children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Type",children:w?"Legacy":"Synthesized"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Current",children:C?(0,e.createComponentVNode)(2,o.Dropdown,{options:d,selected:g,width:"50%",onSelected:function(){function D(M){return u("switchinstrument",{name:M})}return D}()}):(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:"None!"})}),!!(!w&&v)&&(0,e.createFragment)([(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Note Shift/Note Transpose",children:(0,e.createComponentVNode)(2,o.Slider,{minValue:N,maxValue:V,value:f,stepPixelSize:2,format:function(){function D(M){return M+" keys / "+(0,a.round)(M/12*100)/100+" octaves"}return D}(),onChange:function(){function D(M,O){return u("setnoteshift",{new:O})}return D}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Sustain Mode",children:[(0,e.createComponentVNode)(2,o.Dropdown,{options:["Linear","Exponential"],selected:E,mb:"0.4rem",onSelected:function(){function D(M){return u("setsustainmode",{new:M})}return D}()}),P]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Volume Dropoff Threshold",children:(0,e.createComponentVNode)(2,o.Slider,{animated:!0,minValue:.01,maxValue:100,value:A,stepPixelSize:6,onChange:function(){function D(M,O){return u("setdropoffvolume",{new:O})}return D}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Sustain indefinitely last held note",children:(0,e.createComponentVNode)(2,o.Button,{selected:x,icon:x?"toggle-on":"toggle-off",content:x?"Yes":"No",onClick:function(){function D(){return u("togglesustainhold")}return D}()})})],4)]}),(0,e.createComponentVNode)(2,o.Button,{icon:"redo",content:"Reset to Default",mt:"0.5rem",onClick:function(){function D(){return u("reset")}return D}()})]})})})},h=function(c,m){var l=(0,t.useBackend)(m),u=l.act,s=l.data,d=s.playing,C=s.lines,g=s.editing;return(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Editor",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{disabled:!g||d,icon:"plus",content:"Add Line",onClick:function(){function v(){return u("newline",{line:C.length+1})}return v}()}),(0,e.createComponentVNode)(2,o.Button,{selected:!g,icon:g?"chevron-up":"chevron-down",onClick:function(){function v(){return u("edit")}return v}()})],4),children:!!g&&(C.length>0?(0,e.createComponentVNode)(2,o.LabeledList,{children:C.map(function(v,f){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:f+1,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{disabled:d,icon:"pen",onClick:function(){function N(){return u("modifyline",{line:f+1})}return N}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:d,icon:"trash",onClick:function(){function N(){return u("deleteline",{line:f+1})}return N}()})],4),children:v},f)})}):(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"Song is empty."}))})}},13618:function(T,r,n){"use strict";r.__esModule=!0,r.KeyComboModal=void 0;var e=n(89005),a=n(70611),t=n(72253),o=n(36036),p=n(98595),b=n(19203),y=n(51057),S=function(l){return l.key!==a.KEY.Alt&&l.key!==a.KEY.Control&&l.key!==a.KEY.Shift&&l.key!==a.KEY.Escape},k={DEL:"Delete",DOWN:"South",END:"Southwest",HOME:"Northwest",INSERT:"Insert",LEFT:"West",PAGEDOWN:"Southeast",PAGEUP:"Northeast",RIGHT:"East",SPACEBAR:"Space",UP:"North"},h=3,i=function(l){var u="";if(l.altKey&&(u+="Alt"),l.ctrlKey&&(u+="Ctrl"),l.shiftKey&&!(l.keyCode>=48&&l.keyCode<=57)&&(u+="Shift"),l.location===h&&(u+="Numpad"),S(l))if(l.shiftKey&&l.keyCode>=48&&l.keyCode<=57){var s=l.keyCode-48;u+="Shift"+s}else{var d=l.key.toUpperCase();u+=k[d]||d}return u},c=r.KeyComboModal=function(){function m(l,u){var s=(0,t.useBackend)(u),d=s.act,C=s.data,g=C.init_value,v=C.large_buttons,f=C.message,N=f===void 0?"":f,V=C.title,B=C.timeout,I=(0,t.useLocalState)(u,"input",g),L=I[0],w=I[1],A=(0,t.useLocalState)(u,"binding",!0),x=A[0],E=A[1],P=function(){function O(R){if(!x){R.key===a.KEY.Enter&&d("submit",{entry:L}),(0,a.isEscape)(R.key)&&d("cancel");return}if(R.preventDefault(),S(R)){D(i(R)),E(!1);return}else if(R.key===a.KEY.Escape){D(g),E(!1);return}}return O}(),D=function(){function O(R){R!==L&&w(R)}return O}(),M=130+(N.length>30?Math.ceil(N.length/3):0)+(N.length&&v?5:0);return(0,e.createComponentVNode)(2,p.Window,{title:V,width:240,height:M,children:[B&&(0,e.createComponentVNode)(2,y.Loader,{value:B}),(0,e.createComponentVNode)(2,p.Window.Content,{onKeyDown:function(){function O(R){P(R)}return O}(),children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Autofocus),(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Box,{color:"label",children:N})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{disabled:x,content:x&&x!==null?"Awaiting input...":""+L,width:"100%",textAlign:"center",onClick:function(){function O(){D(g),E(!0)}return O}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,b.InputButtons,{input:L})})]})]})})]})}return m}()},35655:function(T,r,n){"use strict";r.__esModule=!0,r.KeycardAuth=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.KeycardAuth=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=(0,e.createComponentVNode)(2,t.Section,{title:"Keycard Authentication Device",children:(0,e.createComponentVNode)(2,t.Box,{children:"This device is used to trigger certain high security events. It requires the simultaneous swipe of two high-level ID cards."})});if(!i.swiping&&!i.busy)return(0,e.createComponentVNode)(2,o.Window,{width:540,height:280,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[c,(0,e.createComponentVNode)(2,t.Section,{title:"Choose Action",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Red Alert",children:(0,e.createComponentVNode)(2,t.Button,{icon:"exclamation-triangle",disabled:!i.redAvailable,onClick:function(){function l(){return h("triggerevent",{triggerevent:"Red Alert"})}return l}(),content:"Red Alert"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ERT",children:(0,e.createComponentVNode)(2,t.Button,{icon:"broadcast-tower",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Emergency Response Team"})}return l}(),content:"Call ERT"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Emergency Maint Access",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"door-open",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Grant Emergency Maintenance Access"})}return l}(),content:"Grant"}),(0,e.createComponentVNode)(2,t.Button,{icon:"door-closed",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Revoke Emergency Maintenance Access"})}return l}(),content:"Revoke"})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Emergency Station-Wide Access",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"door-open",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Activate Station-Wide Emergency Access"})}return l}(),content:"Grant"}),(0,e.createComponentVNode)(2,t.Button,{icon:"door-closed",onClick:function(){function l(){return h("triggerevent",{triggerevent:"Deactivate Station-Wide Emergency Access"})}return l}(),content:"Revoke"})]})]})})]})});var m=(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Waiting for YOU to swipe your ID..."});return!i.hasSwiped&&!i.ertreason&&i.event==="Emergency Response Team"?m=(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Fill out the reason for your ERT request."}):i.hasConfirm?m=(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Request Confirmed!"}):i.isRemote?m=(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"Swipe your card to CONFIRM the remote request."}):i.hasSwiped&&(m=(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"Waiting for second person to confirm..."})),(0,e.createComponentVNode)(2,o.Window,{width:540,height:265,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[c,i.event==="Emergency Response Team"&&(0,e.createComponentVNode)(2,t.Section,{title:"Reason for ERT Call",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{color:i.ertreason?"":"red",icon:i.ertreason?"check":"pencil-alt",content:i.ertreason?i.ertreason:"-----",disabled:i.busy,onClick:function(){function l(){return h("ert")}return l}()})})}),(0,e.createComponentVNode)(2,t.Section,{title:i.event,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-circle-left",content:"Back",disabled:i.busy||i.hasConfirm,onClick:function(){function l(){return h("reset")}return l}()}),children:m})]})})}return b}()},62955:function(T,r,n){"use strict";r.__esModule=!0,r.KitchenMachine=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(62411),b=r.KitchenMachine=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.data,m=i.config,l=c.ingredients,u=c.operating,s=m.title;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:320,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Operating,{operating:u,name:s}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,y)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Ingredients",children:(0,e.createComponentVNode)(2,t.Table,{className:"Ingredient__Table",children:l.map(function(d){return(0,e.createComponentVNode)(2,t.Table.Row,{tr:5,children:[(0,e.createVNode)(1,"td",null,(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:d.name}),2),(0,e.createVNode)(1,"td",null,(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,textAlign:"center",children:[d.amount," ",d.units]}),2)]},d.name)})})})})]})})})}return S}(),y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.inactive,u=m.tooltip;return(0,e.createComponentVNode)(2,t.Section,{title:"Controls",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"50%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"power-off",disabled:l,tooltip:l?u:"",tooltipPosition:"bottom",content:"Activate",onClick:function(){function s(){return c("cook")}return s}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"50%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"eject",disabled:l,tooltip:l?u:"",tooltipPosition:"bottom",content:"Eject Contents",onClick:function(){function s(){return c("eject")}return s}()})})]})})}},9525:function(T,r,n){"use strict";r.__esModule=!0,r.LawManager=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.LawManager=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.isAdmin,s=l.isSlaved,d=l.isMalf,C=l.isAIMalf,g=l.view;return(0,e.createComponentVNode)(2,o.Window,{width:800,height:d?620:365,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[!!(u&&s)&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:["This unit is slaved to ",s,"."]}),!!(d||C)&&(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Law Management",selected:g===0,onClick:function(){function v(){return m("set_view",{set_view:0})}return v}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Lawsets",selected:g===1,onClick:function(){function v(){return m("set_view",{set_view:1})}return v}()})]}),g===0&&(0,e.createComponentVNode)(2,b),g===1&&(0,e.createComponentVNode)(2,y)]})})}return k}(),b=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.has_zeroth_laws,s=l.zeroth_laws,d=l.has_ion_laws,C=l.ion_laws,g=l.ion_law_nr,v=l.has_inherent_laws,f=l.inherent_laws,N=l.has_supplied_laws,V=l.supplied_laws,B=l.channels,I=l.channel,L=l.isMalf,w=l.isAdmin,A=l.zeroth_law,x=l.ion_law,E=l.inherent_law,P=l.supplied_law,D=l.supplied_law_position;return(0,e.createFragment)([!!u&&(0,e.createComponentVNode)(2,S,{title:"ERR_NULL_VALUE",laws:s,ctx:i}),!!d&&(0,e.createComponentVNode)(2,S,{title:g,laws:C,ctx:i}),!!v&&(0,e.createComponentVNode)(2,S,{title:"Inherent",laws:f,ctx:i}),!!N&&(0,e.createComponentVNode)(2,S,{title:"Supplied",laws:V,ctx:i}),(0,e.createComponentVNode)(2,t.Section,{title:"Statement Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Statement Channel",children:B.map(function(M){return(0,e.createComponentVNode)(2,t.Button,{content:M.channel,selected:M.channel===I,onClick:function(){function O(){return m("law_channel",{law_channel:M.channel})}return O}()},M.channel)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"State Laws",children:(0,e.createComponentVNode)(2,t.Button,{content:"State Laws",onClick:function(){function M(){return m("state_laws")}return M}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Law Notification",children:(0,e.createComponentVNode)(2,t.Button,{content:"Notify",onClick:function(){function M(){return m("notify_laws")}return M}()})})]})}),!!L&&(0,e.createComponentVNode)(2,t.Section,{title:"Add Laws",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{width:"10%",children:"Type"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"60%",children:"Law"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"10%",children:"Index"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"20%",children:"Actions"})]}),!!(w&&!u)&&(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Zero"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:A}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"N/A"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function M(){return m("change_zeroth_law")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Add",icon:"plus",onClick:function(){function M(){return m("add_zeroth_law")}return M}()})]})]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Ion"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:x}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"N/A"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function M(){return m("change_ion_law")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Add",icon:"plus",onClick:function(){function M(){return m("add_ion_law")}return M}()})]})]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Inherent"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:E}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"N/A"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function M(){return m("change_inherent_law")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Add",icon:"plus",onClick:function(){function M(){return m("add_inherent_law")}return M}()})]})]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Supplied"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:P}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:D,onClick:function(){function M(){return m("change_supplied_law_position")}return M}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function M(){return m("change_supplied_law")}return M}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Add",icon:"plus",onClick:function(){function M(){return m("add_supplied_law")}return M}()})]})]})]})})],0)},y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.law_sets;return(0,e.createComponentVNode)(2,t.Box,{children:u.map(function(s){return(0,e.createComponentVNode)(2,t.Section,{title:s.name+" - "+s.header,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Load Laws",icon:"download",onClick:function(){function d(){return m("transfer_laws",{transfer_laws:s.ref})}return d}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[s.laws.has_ion_laws>0&&s.laws.ion_laws.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.index,children:d.law},d.index)}),s.laws.has_zeroth_laws>0&&s.laws.zeroth_laws.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.index,children:d.law},d.index)}),s.laws.has_inherent_laws>0&&s.laws.inherent_laws.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.index,children:d.law},d.index)}),s.laws.has_supplied_laws>0&&s.laws.inherent_laws.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.index,children:d.law},d.index)})]})},s.name)})})},S=function(h,i){var c=(0,a.useBackend)(h.ctx),m=c.act,l=c.data,u=l.isMalf;return(0,e.createComponentVNode)(2,t.Section,{title:h.title+" Laws",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{width:"10%",children:"Index"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"69%",children:"Law"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"21%",children:"State?"})]}),h.laws.map(function(s){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:s.index}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:s.law}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{content:s.state?"Yes":"No",selected:s.state,onClick:function(){function d(){return m("state_law",{ref:s.ref,state_law:s.state?0:1})}return d}()}),!!u&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"Edit",icon:"pencil-alt",onClick:function(){function d(){return m("edit_law",{edit_law:s.ref})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Delete",icon:"trash",color:"red",onClick:function(){function d(){return m("delete_law",{delete_law:s.ref})}return d}()})],4)]})]},s.law)})]})})}},85066:function(T,r,n){"use strict";r.__esModule=!0,r.LibraryComputer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=r.LibraryComputer=function(){function g(v,f){return(0,e.createComponentVNode)(2,o.Window,{width:1050,height:600,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c)]})})]})}return g}(),y=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=v.args,L=B.user_ckey;return(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:I.title}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:I.author}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Summary",children:I.summary}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rating",children:[I.rating,(0,e.createComponentVNode)(2,t.Icon,{name:"star",color:"yellow",verticalAlign:"top"})]}),!I.isProgrammatic&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Categories",children:I.categories.join(", ")})]}),(0,e.createVNode)(1,"br"),L===I.ckey&&(0,e.createComponentVNode)(2,t.Button,{content:"Delete Book",icon:"trash",color:"red",disabled:I.isProgrammatic,onClick:function(){function w(){return V("delete_book",{bookid:I.id,user_ckey:L})}return w}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Report Book",icon:"flag",color:"red",disabled:I.isProgrammatic,onClick:function(){function w(){return(0,p.modalOpen)(f,"report_book",{bookid:I.id})}return w}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Rate Book",icon:"star",color:"caution",disabled:I.isProgrammatic,onClick:function(){function w(){return(0,p.modalOpen)(f,"rate_info",{bookid:I.id})}return w}()})]})},S=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=v.args,L=B.selected_report,w=B.report_categories,A=B.user_ckey;return(0,e.createComponentVNode)(2,t.Section,{level:2,m:"-1rem",pb:"1.5rem",title:"Report this book for Rule Violations",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:I.title}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Reasons",children:(0,e.createComponentVNode)(2,t.Box,{children:w.map(function(x,E){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:x.description,selected:x.category_id===L,onClick:function(){function P(){return V("set_report",{report_type:x.category_id})}return P}()}),(0,e.createVNode)(1,"br")],4,E)})})})]}),(0,e.createComponentVNode)(2,t.Button.Confirm,{bold:!0,icon:"paper-plane",content:"Submit Report",onClick:function(){function x(){return V("submit_report",{bookid:I.id,user_ckey:A})}return x}()})]})},k=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.selected_rating,L=Array(10).fill().map(function(w,A){return 1+A});return(0,e.createComponentVNode)(2,t.Stack,{children:[L.map(function(w,A){return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{bold:!0,icon:"star",color:I>=w?"caution":"default",onClick:function(){function x(){return V("set_rating",{rating_value:w})}return x}()})},A)}),(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,ml:2,fontSize:"150%",children:[I+"/10",(0,e.createComponentVNode)(2,t.Icon,{name:"star",color:"yellow",ml:.5,verticalAlign:"top"})]})]})},h=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=v.args,L=B.user_ckey;return(0,e.createComponentVNode)(2,t.Section,{level:2,m:"-1rem",pb:"1.5rem",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:I.title}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:I.author}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Rating",children:[I.current_rating?I.current_rating:0,(0,e.createComponentVNode)(2,t.Icon,{name:"star",color:"yellow",ml:.5,verticalAlign:"middle"})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Total Ratings",children:I.total_ratings?I.total_ratings:0})]}),(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,t.Button.Confirm,{mt:2,content:"Submit",icon:"paper-plane",onClick:function(){function w(){return V("rate_book",{bookid:I.id,user_ckey:L})}return w}()})]})},i=function(v,f){var N=(0,a.useBackend)(f),V=N.data,B=(0,a.useLocalState)(f,"tabIndex",0),I=B[0],L=B[1],w=V.login_state;return(0,e.createComponentVNode)(2,t.Stack.Item,{mb:1,children:(0,e.createComponentVNode)(2,t.Tabs,{fluid:!0,textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===0,onClick:function(){function A(){return L(0)}return A}(),children:"Book Archives"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===1,onClick:function(){function A(){return L(1)}return A}(),children:"Corporate Literature"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===2,onClick:function(){function A(){return L(2)}return A}(),children:"Upload Book"}),w===1&&(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===3,onClick:function(){function A(){return L(3)}return A}(),children:"Patron Manager"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:I===4,onClick:function(){function A(){return L(4)}return A}(),children:"Inventory"})]})})},c=function(v,f){var N=(0,a.useLocalState)(f,"tabIndex",0),V=N[0];switch(V){case 0:return(0,e.createComponentVNode)(2,l);case 1:return(0,e.createComponentVNode)(2,u);case 2:return(0,e.createComponentVNode)(2,s);case 3:return(0,e.createComponentVNode)(2,d);case 4:return(0,e.createComponentVNode)(2,C);default:return"You are somehow on a tab that doesn't exist! Please let a coder know."}},m=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.searchcontent,L=B.book_categories,w=B.user_ckey,A=[];return L.map(function(x){return A[x.description]=x.category_id}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"35%",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",m:".5em",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"edit",verticalAlign:"middle",size:1.5,mr:"1rem"}),"Search Inputs"]}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,t.Button,{textAlign:"left",icon:"pen",width:20,content:I.title||"Input Title",onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_search_title")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:(0,e.createComponentVNode)(2,t.Button,{textAlign:"left",icon:"pen",width:20,content:I.author||"Input Author",onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_search_author")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Ratings",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{mr:1,width:"min-content",content:I.ratingmin,onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_search_ratingmin")}return x}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:"To"}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{ml:1,width:"min-content",content:I.ratingmax,onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_search_ratingmax")}return x}()})})]})})]})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"40%",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",m:".5em",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"clipboard-list",verticalAlign:"middle",size:1.5,mr:"1rem"}),"Book Categories"]}),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Categories",children:(0,e.createComponentVNode)(2,t.Box,{mt:2,children:(0,e.createComponentVNode)(2,t.Dropdown,{mt:.6,width:"190px",options:L.map(function(x){return x.description}),onSelected:function(){function x(E){return V("toggle_search_category",{category_id:A[E]})}return x}()})})})}),(0,e.createVNode)(1,"br"),L.filter(function(x){return I.categories.includes(x.category_id)}).map(function(x){return(0,e.createComponentVNode)(2,t.Button,{content:x.description,selected:!0,icon:"unlink",onClick:function(){function E(){return V("toggle_search_category",{category_id:x.category_id})}return E}()},x.category_id)})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",m:".5em",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"search-plus",verticalAlign:"middle",size:1.5,mr:"1rem"}),"Search Actions"]}),(0,e.createComponentVNode)(2,t.Button,{content:"Clear Search",icon:"eraser",onClick:function(){function x(){return V("clear_search")}return x}()}),I.ckey?(0,e.createComponentVNode)(2,t.Button,{mb:.5,content:"Stop Showing My Books",color:"bad",icon:"search",onClick:function(){function x(){return V("clear_ckey_search")}return x}()}):(0,e.createComponentVNode)(2,t.Button,{content:"Find My Books",icon:"search",onClick:function(){function x(){return V("find_users_books",{user_ckey:w})}return x}()})]})]})},l=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.external_booklist,L=B.archive_pagenumber,w=B.num_pages,A=B.login_state;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Book System Access",buttons:(0,e.createVNode)(1,"div",null,[(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-left",disabled:L===1,onClick:function(){function x(){return V("deincrementpagemax")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-left",disabled:L===1,onClick:function(){function x(){return V("deincrementpage")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{bold:!0,content:L,onClick:function(){function x(){return(0,p.modalOpen)(f,"setpagenumber")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-right",disabled:L===w,onClick:function(){function x(){return V("incrementpage")}return x}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"angle-double-right",disabled:L===w,onClick:function(){function x(){return V("incrementpagemax")}return x}()})],4),children:[(0,e.createComponentVNode)(2,m),(0,e.createVNode)(1,"hr"),(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"SSID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Ratings"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Category"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"middle",children:"Actions"})]}),I.map(function(x){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:x.id}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book",mr:.5}),x.title.length>45?x.title.substr(0,45)+"...":x.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:x.author.length>30?x.author.substr(0,30)+"...":x.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[x.rating,(0,e.createComponentVNode)(2,t.Icon,{name:"star",ml:.5,color:"yellow",verticalAlign:"middle"})]}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:x.categories.join(", ").substr(0,45)}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",children:[A===1&&(0,e.createComponentVNode)(2,t.Button,{content:"Order",icon:"print",onClick:function(){function E(){return V("order_external_book",{bookid:x.id})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{content:"More...",onClick:function(){function E(){return(0,p.modalOpen)(f,"expand_info",{bookid:x.id})}return E}()})]})]},x.id)})]})]})},u=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.programmatic_booklist,L=B.login_state;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Corporate Book Catalog",children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"SSID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"middle",children:"Actions"})]}),I.map(function(w,A){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:w.id}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book",mr:2}),w.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:w.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",children:[L===1&&(0,e.createComponentVNode)(2,t.Button,{content:"Order",icon:"print",onClick:function(){function x(){return V("order_programmatic_book",{bookid:w.id})}return x}()}),(0,e.createComponentVNode)(2,t.Button,{content:"More...",onClick:function(){function x(){return(0,p.modalOpen)(f,"expand_info",{bookid:w.id})}return x}()})]})]},A)})]})})},s=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.selectedbook,L=B.book_categories,w=B.user_ckey,A=[];return L.map(function(x){return A[x.description]=x.category_id}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Book System Upload",buttons:(0,e.createComponentVNode)(2,t.Button.Confirm,{bold:!0,width:9.5,icon:"upload",disabled:I.copyright,content:"Upload Book",onClick:function(){function x(){return V("uploadbook",{user_ckey:w})}return x}()}),children:[I.copyright?(0,e.createComponentVNode)(2,t.NoticeBox,{color:"red",children:"WARNING: You cannot upload or modify the attributes of a copyrighted book"}):(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Box,{ml:15,mb:3,fontSize:"1.2rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"search-plus",verticalAlign:"middle",size:3,mr:2}),"Book Uploader"]}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,t.Button,{width:20,textAlign:"left",icon:"pen",disabled:I.copyright,content:I.title,onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_selected_title")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Author",children:(0,e.createComponentVNode)(2,t.Button,{width:20,textAlign:"left",icon:"pen",disabled:I.copyright,content:I.author,onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_selected_author")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Categories",children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Dropdown,{width:"240px",options:L.map(function(x){return x.description}),onSelected:function(){function x(E){return V("toggle_upload_category",{category_id:A[E]})}return x}()})})})]}),(0,e.createVNode)(1,"br"),L.filter(function(x){return I.categories.includes(x.category_id)}).map(function(x){return(0,e.createComponentVNode)(2,t.Button,{content:x.description,disabled:I.copyright,selected:!0,icon:"unlink",onClick:function(){function E(){return V("toggle_upload_category",{category_id:x.category_id})}return E}()},x.category_id)})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{mr:75,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Summary",children:(0,e.createComponentVNode)(2,t.Button,{icon:"pen",width:"auto",disabled:I.copyright,content:"Edit Summary",onClick:function(){function x(){return(0,p.modalOpen)(f,"edit_selected_summary")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{children:I.summary})]})})]})]})},d=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.checkout_data;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Checked Out Books",children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Patron"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Time Left"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Actions"})]}),I.map(function(L,w){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-tag"}),L.patron_name]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:L.title}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:L.timeleft>=0?L.timeleft:"LATE"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:(0,e.createComponentVNode)(2,t.Button,{content:"Mark Lost",icon:"flag",color:"bad",disabled:L.timeleft>=0,onClick:function(){function A(){return V("reportlost",{libraryid:L.libraryid})}return A}()})})]},w)})]})})},C=function(v,f){var N=(0,a.useBackend)(f),V=N.act,B=N.data,I=B.inventory_list;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Library Inventory",children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"LIB ID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Status"})]}),I.map(function(L,w){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:L.libraryid}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book"})," ",L.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:L.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:L.checked_out?"Checked Out":"Available"})]},w)})]})})};(0,p.modalRegisterBodyOverride)("expand_info",y),(0,p.modalRegisterBodyOverride)("report_book",S),(0,p.modalRegisterBodyOverride)("rate_info",h)},9516:function(T,r,n){"use strict";r.__esModule=!0,r.LibraryManager=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=r.LibraryManager=function(){function i(c,m){return(0,e.createComponentVNode)(2,o.Window,{width:600,height:600,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,className:"Layout__content--flexColumn",children:(0,e.createComponentVNode)(2,y)})]})}return i}(),y=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.pagestate;switch(d){case 1:return(0,e.createComponentVNode)(2,S);case 2:return(0,e.createComponentVNode)(2,h);case 3:return(0,e.createComponentVNode)(2,k);default:return"WE SHOULDN'T BE HERE!"}},S=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data;return(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.4rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-shield",verticalAlign:"middle",size:3,mr:"1rem"}),"Library Manager"]}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{icon:"trash",width:"auto",color:"danger",content:"Delete Book by SSID",onClick:function(){function d(){return(0,p.modalOpen)(m,"specify_ssid_delete")}return d}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"user-slash",width:"auto",color:"danger",content:"Delete All Books By CKEY",onClick:function(){function d(){return(0,p.modalOpen)(m,"specify_ckey_delete")}return d}()}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{icon:"search",width:"auto",content:"View All Books By CKEY",onClick:function(){function d(){return(0,p.modalOpen)(m,"specify_ckey_search")}return d}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"search",width:"auto",content:"View All Reported Books",onClick:function(){function d(){return u("view_reported_books")}return d}()})]})},k=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.reports;return(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-secret",verticalAlign:"middle",size:2,mr:"1rem"}),(0,e.createVNode)(1,"br"),"All Reported Books",(0,e.createVNode)(1,"br")]}),(0,e.createComponentVNode)(2,t.Button,{content:"Return to Main",icon:"arrow-alt-circle-left",onClick:function(){function C(){return u("return")}return C}()}),(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Uploader CKEY"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"SSID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Report Type"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Reporter Ckey"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"middle",children:"Administrative Actions"})]}),d.map(function(C){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:C.uploader_ckey}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:C.id}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book"}),C.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:C.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:C.report_description}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:C.reporter_ckey}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Delete",icon:"trash",onClick:function(){function g(){return u("delete_book",{bookid:C.id})}return g}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Unflag",icon:"flag",color:"caution",onClick:function(){function g(){return u("unflag_book",{bookid:C.id})}return g}()}),(0,e.createComponentVNode)(2,t.Button,{content:"View",onClick:function(){function g(){return u("view_book",{bookid:C.id})}return g}()})]})]},C.id)})]})})},h=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.ckey,C=s.booklist;return(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.Table,{className:"Library__Booklist",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.2rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user",verticalAlign:"middle",size:2,mr:"1rem"}),(0,e.createVNode)(1,"br"),"Books uploaded by ",d,(0,e.createVNode)(1,"br")]}),(0,e.createComponentVNode)(2,t.Button,{mt:1,content:"Return to Main",icon:"arrow-alt-circle-left",onClick:function(){function g(){return u("return")}return g}()}),(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"SSID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Title"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Author"}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"middle",children:"Administrative Actions"})]}),C.map(function(g){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:g.id}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"book"}),g.title]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"left",children:g.author}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"right",children:[(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Delete",icon:"trash",color:"bad",onClick:function(){function v(){return u("delete_book",{bookid:g.id})}return v}()}),(0,e.createComponentVNode)(2,t.Button,{content:"View",onClick:function(){function v(){return u("view_book",{bookid:g.id})}return v}()})]})]},g.id)})]})})}},90447:function(T,r,n){"use strict";r.__esModule=!0,r.ListInputModal=void 0;var e=n(89005),a=n(51057),t=n(19203),o=n(36036),p=n(72253),b=n(92986),y=n(98595),S=r.ListInputModal=function(){function i(c,m){var l=(0,p.useBackend)(m),u=l.act,s=l.data,d=s.items,C=d===void 0?[]:d,g=s.message,v=g===void 0?"":g,f=s.init_value,N=s.timeout,V=s.title,B=(0,p.useLocalState)(m,"selected",C.indexOf(f)),I=B[0],L=B[1],w=(0,p.useLocalState)(m,"searchBarVisible",C.length>10),A=w[0],x=w[1],E=(0,p.useLocalState)(m,"searchQuery",""),P=E[0],D=E[1],M=function(){function G(X){var J=z.length-1;if(X===b.KEY_DOWN)if(I===null||I===J){var se;L(0),(se=document.getElementById("0"))==null||se.scrollIntoView()}else{var ie;L(I+1),(ie=document.getElementById((I+1).toString()))==null||ie.scrollIntoView()}else if(X===b.KEY_UP)if(I===null||I===0){var me;L(J),(me=document.getElementById(J.toString()))==null||me.scrollIntoView()}else{var q;L(I-1),(q=document.getElementById((I-1).toString()))==null||q.scrollIntoView()}}return G}(),O=function(){function G(X){X!==I&&L(X)}return G}(),R=function(){function G(){x(!1),x(!0)}return G}(),F=function(){function G(X){var J=String.fromCharCode(X),se=C.find(function(q){return q==null?void 0:q.toLowerCase().startsWith(J==null?void 0:J.toLowerCase())});if(se){var ie,me=C.indexOf(se);L(me),(ie=document.getElementById(me.toString()))==null||ie.scrollIntoView()}}return G}(),W=function(){function G(X){var J;X!==P&&(D(X),L(0),(J=document.getElementById("0"))==null||J.scrollIntoView())}return G}(),U=function(){function G(){x(!A),D("")}return G}(),z=C.filter(function(G){return G==null?void 0:G.toLowerCase().includes(P.toLowerCase())}),$=330+Math.ceil(v.length/3);return A||setTimeout(function(){var G;return(G=document.getElementById(I.toString()))==null?void 0:G.focus()},1),(0,e.createComponentVNode)(2,y.Window,{title:V,width:325,height:$,children:[N&&(0,e.createComponentVNode)(2,a.Loader,{value:N}),(0,e.createComponentVNode)(2,y.Window.Content,{onKeyDown:function(){function G(X){var J=window.event?X.which:X.keyCode;(J===b.KEY_DOWN||J===b.KEY_UP)&&(X.preventDefault(),M(J)),J===b.KEY_ENTER&&(X.preventDefault(),u("submit",{entry:z[I]})),!A&&J>=b.KEY_A&&J<=b.KEY_Z&&(X.preventDefault(),F(J)),J===b.KEY_ESCAPE&&(X.preventDefault(),u("cancel"))}return G}(),children:(0,e.createComponentVNode)(2,o.Section,{buttons:(0,e.createComponentVNode)(2,o.Button,{compact:!0,icon:A?"search":"font",selected:!0,tooltip:A?"Search Mode. Type to search or use arrow keys to select manually.":"Hotkey Mode. Type a letter to jump to the first match. Enter to select.",tooltipPosition:"left",onClick:function(){function G(){return U()}return G}()}),className:"ListInput__Section",fill:!0,title:v,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,k,{filteredItems:z,onClick:O,onFocusSearch:R,searchBarVisible:A,selected:I})}),(0,e.createComponentVNode)(2,o.Stack.Item,{m:0,children:A&&(0,e.createComponentVNode)(2,h,{filteredItems:z,onSearch:W,searchQuery:P,selected:I})}),(0,e.createComponentVNode)(2,o.Stack.Item,{mt:.5,children:(0,e.createComponentVNode)(2,t.InputButtons,{input:z[I]})})]})})})]})}return i}(),k=function(c,m){var l=(0,p.useBackend)(m),u=l.act,s=c.filteredItems,d=c.onClick,C=c.onFocusSearch,g=c.searchBarVisible,v=c.selected;return(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,tabIndex:0,children:s.map(function(f,N){return(0,e.createComponentVNode)(2,o.Button,{fluid:!0,color:"transparent",id:N,onClick:function(){function V(){return d(N)}return V}(),onDblClick:function(){function V(B){B.preventDefault(),u("submit",{entry:s[v]})}return V}(),onKeyDown:function(){function V(B){var I=window.event?B.which:B.keyCode;g&&I>=b.KEY_A&&I<=b.KEY_Z&&(B.preventDefault(),C())}return V}(),selected:N===v,style:{animation:"none",transition:"none"},children:f.replace(/^\w/,function(V){return V.toUpperCase()})},N)})})},h=function(c,m){var l=(0,p.useBackend)(m),u=l.act,s=c.filteredItems,d=c.onSearch,C=c.searchQuery,g=c.selected;return(0,e.createComponentVNode)(2,o.Input,{width:"100%",autoFocus:!0,autoSelect:!0,onEnter:function(){function v(f){f.preventDefault(),u("submit",{entry:s[g]})}return v}(),onInput:function(){function v(f,N){return d(N)}return v}(),placeholder:"Search...",value:C})}},26826:function(T,r,n){"use strict";r.__esModule=!0,r.Loadout=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b={Default:function(){function c(m,l){return m.gear.gear_tier-l.gear.gear_tier}return c}(),Alphabetical:function(){function c(m,l){return m.gear.name.toLowerCase().localeCompare(l.gear.name.toLowerCase())}return c}(),Cost:function(){function c(m,l){return m.gear.cost-l.gear.cost}return c}()},y=r.Loadout=function(){function c(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=(0,t.useLocalState)(l,"search",!1),g=C[0],v=C[1],f=(0,t.useLocalState)(l,"searchText",""),N=f[0],V=f[1],B=(0,t.useLocalState)(l,"category",Object.keys(d.gears)[0]),I=B[0],L=B[1],w=(0,t.useLocalState)(l,"tweakedGear",""),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,p.Window,{width:975,height:650,children:[A&&(0,e.createComponentVNode)(2,i,{tweakedGear:A,setTweakedGear:x}),(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,S,{category:I,setCategory:L})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"25%",children:(0,e.createComponentVNode)(2,h,{setTweakedGear:x})}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"75%",children:(0,e.createComponentVNode)(2,k,{category:I,search:g,setSearch:v,searchText:N,setSearchText:V})})]})})]})})]})}return c}(),S=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=m.category,g=m.setCategory;return(0,e.createComponentVNode)(2,o.Tabs,{fluid:!0,textAlign:"center",style:{"flex-wrap":"wrap-reverse"},children:Object.keys(d.gears).map(function(v){return(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:v===C,style:{"white-space":"nowrap"},onClick:function(){function f(){return g(v)}return f}(),children:v},v)})})},k=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=d.user_tier,g=d.gear_slots,v=d.max_gear_slots,f=m.category,N=m.search,V=m.setSearch,B=m.searchText,I=m.setSearchText,L=(0,t.useLocalState)(l,"sortType","Default"),w=L[0],A=L[1],x=(0,t.useLocalState)(l,"sortReverse",!1),E=x[0],P=x[1],D=(0,a.createSearch)(B,function(O){return O.name}),M;return B.length>2?M=Object.entries(d.gears).reduce(function(O,R){var F=R[0],W=R[1];return O.concat(Object.entries(W).map(function(U){var z=U[0],$=U[1];return{key:z,gear:$}}))},[]).filter(function(O){var R=O.gear;return D(R)}):M=Object.entries(d.gears[f]).map(function(O){var R=O[0],F=O[1];return{key:R,gear:F}}),M.sort(b[w]),E&&(M=M.reverse()),(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:f,buttons:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Dropdown,{height:1.66,selected:w,options:Object.keys(b),onSelected:function(){function O(R){return A(R)}return O}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:E?"arrow-down-wide-short":"arrow-down-short-wide",tooltip:E?"Ascending order":"Descending order",tooltipPosition:"bottom-end",onClick:function(){function O(){return P(!E)}return O}()})}),N&&(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Input,{width:20,placeholder:"Search...",value:B,onInput:function(){function O(R){return I(R.target.value)}return O}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:"magnifying-glass",selected:N,tooltip:"Toggle search field",tooltipPosition:"bottom-end",onClick:function(){function O(){V(!N),I("")}return O}()})})]}),children:M.map(function(O){var R=O.key,F=O.gear,W=12,U=Object.keys(d.selected_gears).includes(R),z=F.cost===1?F.cost+" Point":F.cost+" Points",$=(0,e.createComponentVNode)(2,o.Box,{children:[F.name.length>W&&(0,e.createComponentVNode)(2,o.Box,{children:F.name}),F.gear_tier>C&&(0,e.createComponentVNode)(2,o.Box,{mt:F.name.length>W&&1.5,textColor:"red",children:"That gear is only available at a higher donation tier than you are on."})]}),G=(0,e.createFragment)([F.allowed_roles&&(0,e.createComponentVNode)(2,o.Button,{width:"22px",color:"transparent",icon:"user",tooltip:(0,e.createComponentVNode)(2,o.Section,{m:-1,title:"Allowed Roles",children:F.allowed_roles.map(function(J){return(0,e.createComponentVNode)(2,o.Box,{children:J},J)})}),tooltipPosition:"left"}),Object.entries(F.tweaks).map(function(J){var se=J[0],ie=J[1];return ie.map(function(me){return(0,e.createComponentVNode)(2,o.Button,{width:"22px",color:"transparent",icon:me.icon,tooltip:me.tooltip,tooltipPosition:"top"},se)})}),(0,e.createComponentVNode)(2,o.Button,{width:"22px",color:"transparent",icon:"info",tooltip:F.desc,tooltipPosition:"top"})],0),X=(0,e.createComponentVNode)(2,o.Box,{class:"Loadout-InfoBox",children:[(0,e.createComponentVNode)(2,o.Box,{style:{"flex-grow":1},fontSize:1,color:"gold",opacity:.75,children:F.gear_tier>0&&"Tier "+F.gear_tier}),(0,e.createComponentVNode)(2,o.Box,{fontSize:.75,opacity:.66,children:z})]});return(0,e.createComponentVNode)(2,o.ImageButton,{m:.5,imageSize:84,dmIcon:F.icon,dmIconState:F.icon_state,tooltip:(F.name.length>W||F.gear_tier>0)&&$,tooltipPosition:"bottom",selected:U,disabled:F.gear_tier>C||g+F.cost>v&&!U,buttons:G,buttonsAlt:X,onClick:function(){function J(){return s("toggle_gear",{gear:R})}return J}(),children:F.name},R)})})},h=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=m.setTweakedGear,g=Object.entries(d.gears).reduce(function(v,f){var N=f[0],V=f[1],B=Object.entries(V).filter(function(I){var L=I[0];return Object.keys(d.selected_gears).includes(L)}).map(function(I){var L=I[0],w=I[1];return Object.assign({key:L},w)});return v.concat(B)},[]);return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Selected Equipment",buttons:(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",tooltip:"Clear Loadout",tooltipPosition:"bottom-end",onClick:function(){function v(){return s("clear_loadout")}return v}()}),children:g.map(function(v){return(0,e.createComponentVNode)(2,o.ImageButton,{fluid:!0,imageSize:32,dmIcon:v.icon,dmIconState:v.icon_state,buttons:(0,e.createFragment)([Object.entries(v.tweaks).length>0&&(0,e.createComponentVNode)(2,o.Button,{translucent:!0,icon:"gears",iconColor:"gray",width:"33px",onClick:function(){function f(){return C(v)}return f}()}),(0,e.createComponentVNode)(2,o.Button,{translucent:!0,icon:"times",iconColor:"red",width:"32px",onClick:function(){function f(){return s("toggle_gear",{gear:v.key})}return f}()})],0),children:v.name},v.key)})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.ProgressBar,{value:d.gear_slots,maxValue:d.max_gear_slots,ranges:{bad:[d.max_gear_slots,1/0],average:[d.max_gear_slots*.66,d.max_gear_slots],good:[0,d.max_gear_slots*.66]},children:(0,e.createComponentVNode)(2,o.Box,{textAlign:"center",children:["Used points ",d.gear_slots,"/",d.max_gear_slots]})})})})]})},i=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=m.tweakedGear,g=m.setTweakedGear;return(0,e.createComponentVNode)(2,o.Dimmer,{children:(0,e.createComponentVNode)(2,o.Box,{className:"Loadout-Modal__background",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,width:20,height:20,title:C.name,buttons:(0,e.createComponentVNode)(2,o.Button,{color:"red",icon:"times",tooltip:"Close",tooltipPosition:"top",onClick:function(){function v(){return g("")}return v}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:Object.entries(C.tweaks).map(function(v){var f=v[0],N=v[1];return N.map(function(V){var B=d.selected_gears[C.key][f];return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:V.name,color:B?"":"gray",buttons:(0,e.createComponentVNode)(2,o.Button,{color:"transparent",icon:"pen",onClick:function(){function I(){return s("set_tweak",{gear:C.key,tweak:f})}return I}()}),children:[B||"Default",(0,e.createComponentVNode)(2,o.Box,{inline:!0,ml:1,width:1,height:1,verticalAlign:"middle",style:{"background-color":""+B}})]},f)})})})})})})}},77613:function(T,r,n){"use strict";r.__esModule=!0,r.MODsuitContent=r.MODsuit=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(I,L){var w=I.name,A=I.value,x=I.module_ref,E=(0,a.useBackend)(L),P=E.act;return(0,e.createComponentVNode)(2,t.NumberInput,{value:A,minValue:-50,maxValue:50,stepPixelSize:5,width:"39px",onChange:function(){function D(M,O){return P("configure",{key:w,value:O,ref:x})}return D}()})},b=function(I,L){var w=I.name,A=I.value,x=I.module_ref,E=(0,a.useBackend)(L),P=E.act;return(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:A,onClick:function(){function D(){return P("configure",{key:w,value:!A,ref:x})}return D}()})},y=function(I,L){var w=I.name,A=I.value,x=I.module_ref,E=(0,a.useBackend)(L),P=E.act;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:"paint-brush",onClick:function(){function D(){return P("configure",{key:w,ref:x})}return D}()}),(0,e.createComponentVNode)(2,t.ColorBox,{color:A,mr:.5})],4)},S=function(I,L){var w=I.name,A=I.value,x=I.values,E=I.module_ref,P=(0,a.useBackend)(L),D=P.act;return(0,e.createComponentVNode)(2,t.Dropdown,{displayText:A,options:x,onSelected:function(){function M(O){return D("configure",{key:w,value:O,ref:E})}return M}()})},k=function(I,L){var w=I.name,A=I.display_name,x=I.type,E=I.value,P=I.values,D=I.module_ref,M={number:(0,e.normalizeProps)((0,e.createComponentVNode)(2,p,Object.assign({},I))),bool:(0,e.normalizeProps)((0,e.createComponentVNode)(2,b,Object.assign({},I))),color:(0,e.normalizeProps)((0,e.createComponentVNode)(2,y,Object.assign({},I))),list:(0,e.normalizeProps)((0,e.createComponentVNode)(2,S,Object.assign({},I)))};return(0,e.createComponentVNode)(2,t.Box,{children:[A,": ",M[x]]})},h=function(I,L){var w=I.active,A=I.userradiated,x=I.usertoxins,E=I.usermaxtoxins,P=I.threatlevel;return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Radiation Level",color:w&&A?"bad":"good",children:w&&A?"IRRADIATED!":"RADIATION-FREE"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Toxins Level",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?x/E:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:x})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Hazard Level",color:w&&P?"bad":"good",bold:!0,children:w&&P?P:0})})]})},i=function(I,L){var w=I.active,A=I.userhealth,x=I.usermaxhealth,E=I.userbrute,P=I.userburn,D=I.usertoxin,M=I.useroxy;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"Health",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?A/x:0,ranges:{good:[.5,1/0],average:[.2,.5],bad:[-1/0,.2]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?A:0})})}),(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Brute",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?E/x:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?E:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Burn",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?P/x:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?P:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Toxin",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?D/x:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?D:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Suffocation",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?M/x:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?M:0})})})})]})],4)},c=function(I,L){var w=I.active,A=I.statustime,x=I.statusid,E=I.statushealth,P=I.statusmaxhealth,D=I.statusbrute,M=I.statusburn,O=I.statustoxin,R=I.statusoxy,F=I.statustemp,W=I.statusnutrition,U=I.statusfingerprints,z=I.statusdna,$=I.statusviruses;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Operation Time",children:w?A:"00:00:00"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Operation Number",children:w?x||"0":"???"})})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Health",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?E/P:0,ranges:{good:[.5,1/0],average:[.2,.5],bad:[-1/0,.2]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?E:0})})}),(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Brute",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?D/P:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?D:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Burn",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?M/P:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:w?M:0})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Toxin",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?O/P:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:O})})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Suffocation",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:w?R/P:0,ranges:{good:[-1/0,.2],average:[.2,.5],bad:[.5,1/0]},children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:R})})})})]}),(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Body Temperature",children:w?F:0})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Nutrition Status",children:w?W:0})})]}),(0,e.createComponentVNode)(2,t.Section,{title:"DNA",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fingerprints",children:w?U:"???"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Unique Enzymes",children:w?z:"???"})]})}),!!w&&!!$&&(0,e.createComponentVNode)(2,t.Section,{title:"Diseases",children:(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"signature",tooltip:"Name",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"wind",tooltip:"Type",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"bolt",tooltip:"Stage",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"flask",tooltip:"Cure",tooltipPosition:"top"})})]}),$.map(function(G){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:G.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:G.type}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:[G.stage,"/",G.maxstage]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:G.cure})]},G.name)})]})})],0)},m={rad_counter:h,health_analyzer:i,status_readout:c},l=function(){return(0,e.createComponentVNode)(2,t.Section,{align:"center",fill:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{color:"red",name:"exclamation-triangle",size:15}),(0,e.createComponentVNode)(2,t.Box,{fontSize:"30px",color:"red",children:"ERROR: INTERFACE UNRESPONSIVE"})]})},u=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data;return(0,e.createComponentVNode)(2,t.Dimmer,{children:(0,e.createComponentVNode)(2,t.Stack,{children:(0,e.createComponentVNode)(2,t.Stack.Item,{fontSize:"16px",color:"blue",children:"SUIT UNPOWERED"})})})},s=function(I,L){var w=I.configuration_data,A=I.module_ref,x=Object.keys(w);return(0,e.createComponentVNode)(2,t.Dimmer,{backgroundColor:"rgba(0, 0, 0, 0.8)",children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:[x.map(function(E){var P=w[E];return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,k,{name:E,display_name:P.display_name,type:P.type,value:P.value,values:P.values,module_ref:A})},P.key)}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:I.onExit,icon:"times",textAlign:"center",children:"Exit"})})})]})})},d=function(I){switch(I){case 1:return"Use";case 2:return"Toggle";case 3:return"Select"}},C=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.active,P=x.malfunctioning,D=x.locked,M=x.open,O=x.selected_module,R=x.complexity,F=x.complexity_max,W=x.wearer_name,U=x.wearer_job,z=P?"Malfunctioning":E?"Active":"Inactive";return(0,e.createComponentVNode)(2,t.Section,{title:"Parameters",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",content:E?"Deactivate":"Activate",onClick:function(){function $(){return A("activate")}return $}()}),children:z}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID Lock",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:D?"lock-open":"lock",content:D?"Unlock":"Lock",onClick:function(){function $(){return A("lock")}return $}()}),children:D?"Locked":"Unlocked"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cover",children:M?"Open":"Closed"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Selected Module",children:O||"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Complexity",children:[R," (",F,")"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Occupant",children:[W,", ",U]})]})})},g=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.active,P=x.control,D=x.helmet,M=x.chestplate,O=x.gauntlets,R=x.boots,F=x.core,W=x.charge;return(0,e.createComponentVNode)(2,t.Section,{title:"Hardware",children:[(0,e.createComponentVNode)(2,t.Collapsible,{title:"Parts",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Control Unit",children:P}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Helmet",children:D||"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Chestplate",children:M||"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Gauntlets",children:O||"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Boots",children:R||"None"})]})}),(0,e.createComponentVNode)(2,t.Collapsible,{title:"Core",children:F&&(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Core Type",children:F}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Core Charge",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:W/100,content:W+"%",ranges:{good:[.6,1/0],average:[.3,.6],bad:[-1/0,.3]}})})]})||(0,e.createComponentVNode)(2,t.Box,{color:"bad",textAlign:"center",children:"No Core Detected"})})]})},v=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.active,P=x.modules,D=P.filter(function(M){return!!M.id});return(0,e.createComponentVNode)(2,t.Section,{title:"Info",children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:D.length!==0&&D.map(function(M){var O=m[M.id];return(0,e.createComponentVNode)(2,t.Stack.Item,{children:[!E&&(0,e.createComponentVNode)(2,u),(0,e.normalizeProps)((0,e.createComponentVNode)(2,O,Object.assign({},M,{active:E})))]},M.ref)})||(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",children:"No Info Modules Detected"})})})},f=function(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.complexity_max,P=x.modules,D=(0,a.useLocalState)(L,"module_configuration",null),M=D[0],O=D[1];return(0,e.createComponentVNode)(2,t.Section,{title:"Modules",fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:P.length!==0&&P.map(function(R){return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Collapsible,{title:R.module_name,children:(0,e.createComponentVNode)(2,t.Section,{children:[M===R.ref&&(0,e.createComponentVNode)(2,s,{configuration_data:R.configuration_data,module_ref:R.ref,onExit:function(){function F(){return O(null)}return F}()}),(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"save",tooltip:"Complexity",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"plug",tooltip:"Idle Power Cost",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"lightbulb",tooltip:"Active Power Cost",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"bolt",tooltip:"Use Power Cost",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"hourglass-half",tooltip:"Cooldown",tooltipPosition:"top"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{color:"transparent",icon:"tasks",tooltip:"Actions",tooltipPosition:"top"})})]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:[R.module_complexity,"/",E]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:R.idle_power}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:R.active_power}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:R.use_power}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:[R.cooldown>0&&R.cooldown/10||"0","/",R.cooldown_time/10,"s"]}),(0,e.createComponentVNode)(2,t.Table.Cell,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function F(){return A("select",{ref:R.ref})}return F}(),icon:"bullseye",selected:R.module_active,tooltip:d(R.module_type),tooltipPosition:"left",disabled:!R.module_type}),(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function F(){return O(R.ref)}return F}(),icon:"cog",selected:M===R.ref,tooltip:"Configure",tooltipPosition:"left",disabled:R.configuration_data.length===0}),(0,e.createComponentVNode)(2,t.Button,{onClick:function(){function F(){return A("pin",{ref:R.ref})}return F}(),icon:"thumbtack",selected:R.pinned,tooltip:"Pin",tooltipPosition:"left",disabled:!R.module_type})]})]})]}),(0,e.createComponentVNode)(2,t.Box,{children:R.description})]})})},R.ref)})||(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",children:"No Modules Detected"})})})})},N=r.MODsuitContent=function(){function B(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.ui_theme,P=x.interface_break;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!P,children:!!P&&(0,e.createComponentVNode)(2,l)||(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,C)}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,g)}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,v)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,f)})]})})}return B}(),V=r.MODsuit=function(){function B(I,L){var w=(0,a.useBackend)(L),A=w.act,x=w.data,E=x.ui_theme,P=x.interface_break;return(0,e.createComponentVNode)(2,o.Window,{theme:E,width:400,height:620,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,N)})})})}return B}()},78624:function(T,r,n){"use strict";r.__esModule=!0,r.MagnetController=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=n(3939),y=new Map([["n",{icon:"arrow-up",tooltip:"Move North"}],["e",{icon:"arrow-right",tooltip:"Move East"}],["s",{icon:"arrow-down",tooltip:"Move South"}],["w",{icon:"arrow-left",tooltip:"Move West"}],["c",{icon:"crosshairs",tooltip:"Move to Magnet"}],["r",{icon:"dice",tooltip:"Move Randomly"}]]),S=r.MagnetController=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=l.autolink,s=l.code,d=l.frequency,C=l.linkedMagnets,g=l.magnetConfiguration,v=l.path,f=l.pathPosition,N=l.probing,V=l.powerState,B=l.speed;return(0,e.createComponentVNode)(2,p.Window,{width:400,height:600,children:[(0,e.createComponentVNode)(2,b.ComplexModal),(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:[!u&&(0,e.createComponentVNode)(2,o.Section,{buttons:(0,e.createComponentVNode)(2,o.Button,{content:"Probe",icon:N?"spinner":"sync",iconSpin:!!N,disabled:N,onClick:function(){function I(){return m("probe_magnets")}return I}()}),title:"Magnet Linking",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Frequency",children:(0,a.toFixed)(d/10,1)}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Code",children:s})]})}),(0,e.createComponentVNode)(2,o.Section,{buttons:(0,e.createComponentVNode)(2,o.Button,{icon:V?"power-off":"times",content:V?"On":"Off",selected:V,onClick:function(){function I(){return m("toggle_power")}return I}()}),title:"Controller Configuration",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Speed",children:(0,e.createComponentVNode)(2,o.Slider,{value:B.value,minValue:B.min,maxValue:B.max,onChange:function(){function I(L,w){return m("set_speed",{speed:w})}return I}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Path",children:[Array.from(y.entries()).map(function(I){var L=I[0],w=I[1],A=w.icon,x=w.tooltip;return(0,e.createComponentVNode)(2,o.Button,{icon:A,tooltip:x,onClick:function(){function E(){return m("path_add",{code:L})}return E}()},L)}),(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",confirmIcon:"trash",confirmContent:"",float:"right",tooltip:"Reset Path",tooltipPosition:"left",onClick:function(){function I(){return m("path_clear")}return I}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"file-import",float:"right",tooltip:"Manually input path",tooltipPosition:"left",onClick:function(){function I(){return(0,b.modalOpen)(i,"path_custom_input")}return I}()}),(0,e.createComponentVNode)(2,o.BlockQuote,{children:v.map(function(I,L){var w=y.get(I)||{icon:"question"},A=w.icon,x=w.tooltip;return(0,e.createComponentVNode)(2,o.Button.Confirm,{selected:L+2===f,icon:A,confirmIcon:A,confirmContent:"",tooltip:x,onClick:function(){function E(){return m("path_remove",{index:L+1,code:I})}return E}()},L)})})]})]})}),C.map(function(I,L){var w=I.uid,A=I.powerState,x=I.electricityLevel,E=I.magneticField;return(0,e.createComponentVNode)(2,o.Section,{title:"Magnet #"+(L+1)+" Configuration",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:A?"power-off":"times",content:A?"On":"Off",selected:A,onClick:function(){function P(){return m("toggle_magnet_power",{id:w})}return P}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Move Speed",children:(0,e.createComponentVNode)(2,o.Slider,{value:x,minValue:g.electricityLevel.min,maxValue:g.electricityLevel.max,onChange:function(){function P(D,M){return m("set_electricity_level",{id:w,electricityLevel:M})}return P}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Field Size",children:(0,e.createComponentVNode)(2,o.Slider,{value:E,minValue:g.magneticField.min,maxValue:g.magneticField.max,onChange:function(){function P(D,M){return m("set_magnetic_field",{id:w,magneticField:M})}return P}()})})]})},w)})]})]})}return k}()},72106:function(T,r,n){"use strict";r.__esModule=!0,r.MechBayConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.MechBayConsole=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.recharge_port,m=c&&c.mech,l=m&&m.cell,u=m&&m.name;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:155,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:u?"Mech status: "+u:"Mech status",textAlign:"center",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"sync",content:"Sync",onClick:function(){function s(){return h("reconnect")}return s}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Integrity",children:!c&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No power port detected. Please re-sync."})||!m&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No mech detected."})||(0,e.createComponentVNode)(2,t.ProgressBar,{value:m.health/m.maxhealth,ranges:{good:[.7,1/0],average:[.3,.7],bad:[-1/0,.3]}})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:!c&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No power port detected. Please re-sync."})||!m&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No mech detected."})||!l&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No cell is installed."})||(0,e.createComponentVNode)(2,t.ProgressBar,{value:l.charge/l.maxcharge,ranges:{good:[.7,1/0],average:[.3,.7],bad:[-1/0,.3]},children:[(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:l.charge})," / "+l.maxcharge]})})]})})})})}return b}()},7466:function(T,r,n){"use strict";r.__esModule=!0,r.MechaControlConsole=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=n(25328),y=r.MechaControlConsole=function(){function S(k,h){var i=(0,t.useBackend)(h),c=i.act,m=i.data,l=m.beacons,u=m.stored_data;return u.length?(0,e.createComponentVNode)(2,p.Window,{width:420,height:500,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Section,{title:"Log",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"window-close",onClick:function(){function s(){return c("clear_log")}return s}()}),children:u.map(function(s){return(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,o.Box,{color:"label",children:["(",s.time,")"]}),(0,e.createComponentVNode)(2,o.Box,{children:(0,b.decodeHtmlEntities)(s.message)})]},s.time)})})})}):(0,e.createComponentVNode)(2,p.Window,{width:420,height:500,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:l.length&&l.map(function(s){return(0,e.createComponentVNode)(2,o.Section,{title:s.name,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{icon:"comment",onClick:function(){function d(){return c("send_message",{mt:s.uid})}return d}(),children:"Message"}),(0,e.createComponentVNode)(2,o.Button,{icon:"eye",onClick:function(){function d(){return c("get_log",{mt:s.uid})}return d}(),children:"View Log"}),(0,e.createComponentVNode)(2,o.Button.Confirm,{color:"red",content:"Sabotage",icon:"bomb",onClick:function(){function d(){return c("shock",{mt:s.uid})}return d}()})],4),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,o.ProgressBar,{ranges:{good:[s.maxHealth*.75,1/0],average:[s.maxHealth*.5,s.maxHealth*.75],bad:[-1/0,s.maxHealth*.5]},value:s.health,maxValue:s.maxHealth})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Cell Charge",children:s.cell&&(0,e.createComponentVNode)(2,o.ProgressBar,{ranges:{good:[s.cellMaxCharge*.75,1/0],average:[s.cellMaxCharge*.5,s.cellMaxCharge*.75],bad:[-1/0,s.cellMaxCharge*.5]},value:s.cellCharge,maxValue:s.cellMaxCharge})||(0,e.createComponentVNode)(2,o.NoticeBox,{children:"No Cell Installed"})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Air Tank",children:[s.airtank,"kPa"]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Pilot",children:s.pilot||"Unoccupied"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Location",children:(0,b.toTitleCase)(s.location)||"Unknown"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Active Equipment",children:s.active||"None"}),s.cargoMax&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Cargo Space",children:(0,e.createComponentVNode)(2,o.ProgressBar,{ranges:{bad:[s.cargoMax*.75,1/0],average:[s.cargoMax*.5,s.cargoMax*.75],good:[-1/0,s.cargoMax*.5]},value:s.cargoUsed,maxValue:s.cargoMax})})||null]})},s.name)})||(0,e.createComponentVNode)(2,o.NoticeBox,{children:"No mecha beacons found."})})})}return S}()},79625:function(T,r,n){"use strict";r.__esModule=!0,r.MedicalRecords=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(3939),b=n(98595),y=n(321),S=n(5485),k=n(22091),h={Minor:"lightgray",Medium:"good",Harmful:"average","Dangerous!":"bad","BIOHAZARD THREAT!":"darkred"},i={"*Deceased*":"deceased","*SSD*":"ssd","Physically Unfit":"physically_unfit",Disabled:"disabled"},c=function(A,x){(0,p.modalOpen)(A,"edit",{field:x.edit,value:x.value})},m=function(A,x){var E=A.args;return(0,e.createComponentVNode)(2,o.Section,{m:"-1rem",pb:"1.5rem",title:E.name||"Virus",children:(0,e.createComponentVNode)(2,o.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Number of stages",children:E.max_stages}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Spread",children:[E.spread_text," Transmission"]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Possible cure",children:E.cure}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Notes",children:E.desc}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Severity",color:h[E.severity],children:E.severity})]})})})},l=r.MedicalRecords=function(){function w(A,x){var E=(0,t.useBackend)(x),P=E.data,D=P.loginState,M=P.screen;if(!D.logged_in)return(0,e.createComponentVNode)(2,b.Window,{width:800,height:900,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,S.LoginScreen)})});var O;return M===2?O=(0,e.createComponentVNode)(2,u):M===3?O=(0,e.createComponentVNode)(2,s):M===4?O=(0,e.createComponentVNode)(2,d):M===5?O=(0,e.createComponentVNode)(2,f):M===6?O=(0,e.createComponentVNode)(2,N):M===7&&(O=(0,e.createComponentVNode)(2,V)),(0,e.createComponentVNode)(2,b.Window,{width:800,height:900,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y.LoginInfo),(0,e.createComponentVNode)(2,k.TemporaryNotice),(0,e.createComponentVNode)(2,L),O]})})]})}return w}(),u=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.records,O=(0,t.useLocalState)(x,"searchText",""),R=O[0],F=O[1],W=(0,t.useLocalState)(x,"sortId","name"),U=W[0],z=W[1],$=(0,t.useLocalState)(x,"sortOrder",!0),G=$[0],X=$[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{content:"Manage Records",icon:"wrench",ml:"0.25rem",onClick:function(){function J(){return P("screen",{screen:3})}return J}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{fluid:!0,placeholder:"Search by Name, ID, Physical Status, or Mental Status",onInput:function(){function J(se,ie){return F(ie)}return J}()})})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,mt:.5,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"MedicalRecords__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,B,{id:"name",children:"Name"}),(0,e.createComponentVNode)(2,B,{id:"id",children:"ID"}),(0,e.createComponentVNode)(2,B,{id:"rank",children:"Assignment"}),(0,e.createComponentVNode)(2,B,{id:"p_stat",children:"Patient Status"}),(0,e.createComponentVNode)(2,B,{id:"m_stat",children:"Mental Status"})]}),M.filter((0,a.createSearch)(R,function(J){return J.name+"|"+J.id+"|"+J.rank+"|"+J.p_stat+"|"+J.m_stat})).sort(function(J,se){var ie=G?1:-1;return J[U].localeCompare(se[U])*ie}).map(function(J){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"MedicalRecords__listRow--"+i[J.p_stat],onClick:function(){function se(){return P("view_record",{view_record:J.ref})}return se}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user"})," ",J.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.id}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.rank}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.p_stat}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.m_stat})]},J.id)})]})})})],4)},s=function(A,x){var E=(0,t.useBackend)(x),P=E.act;return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,translucent:!0,lineHeight:3,icon:"download",content:"Backup to Disk",disabled:!0})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:[(0,e.createComponentVNode)(2,o.Button,{fluid:!0,translucent:!0,lineHeight:3,icon:"upload",content:"Upload from Disk",my:"0.5rem",disabled:!0})," "]}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Button.Confirm,{fluid:!0,translucent:!0,lineHeight:3,icon:"trash",content:"Delete All Medical Records",onClick:function(){function D(){return P("del_all_med_records")}return D}()})})]})})},d=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.medical,O=D.printing;return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{height:"235px",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"General Data",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:O?"spinner":"print",disabled:O,iconSpin:!!O,content:"Print Record",ml:"0.5rem",onClick:function(){function R(){return P("print_record")}return R}()}),children:(0,e.createComponentVNode)(2,C)})}),!M||!M.fields?(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Medical Data",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"pen",content:"Create New Record",onClick:function(){function R(){return P("new_med_record")}return R}()}),children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{bold:!0,grow:!0,textAlign:"center",fontSize:1.75,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon.Stack,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"scroll",size:5,color:"gray"}),(0,e.createComponentVNode)(2,o.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"Medical records lost!"]})})})}):(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Medical Data",buttons:(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",disabled:!!M.empty,content:"Delete Medical Record",onClick:function(){function R(){return P("del_med_record")}return R}()}),children:(0,e.createComponentVNode)(2,g)})}),(0,e.createComponentVNode)(2,v)],4)],0)},C=function(A,x){var E=(0,t.useBackend)(x),P=E.data,D=P.general;return!D||!D.fields?(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:"General records lost!"})})}):(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:D.fields.map(function(M,O){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:M.field,children:[(0,e.createComponentVNode)(2,o.Box,{height:"20px",inline:!0,children:M.value}),!!M.edit&&(0,e.createComponentVNode)(2,o.Button,{icon:"pen",ml:"0.5rem",onClick:function(){function R(){return c(x,M)}return R}()})]},O)})})}),!!D.has_photos&&D.photos.map(function(M,O){return(0,e.createComponentVNode)(2,o.Stack.Item,{inline:!0,textAlign:"center",color:"label",ml:0,children:[(0,e.createVNode)(1,"img",null,null,1,{src:M,style:{width:"96px","margin-top":"2.5rem","margin-bottom":"0.5rem","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}}),(0,e.createVNode)(1,"br"),"Photo #",O+1]},O)})]})},g=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.medical;return!M||!M.fields?(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:"Medical records lost!"})})}):(0,e.createComponentVNode)(2,o.Stack,{children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:M.fields.map(function(O,R){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:O.field,preserveWhitespace:!0,children:[(0,a.decodeHtmlEntities)(O.value),!!O.edit&&(0,e.createComponentVNode)(2,o.Button,{icon:"pen",ml:"0.5rem",mb:O.line_break?"1rem":"initial",onClick:function(){function F(){return c(x,O)}return F}()})]},R)})})})})},v=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.medical;return(0,e.createComponentVNode)(2,o.Stack.Item,{height:"150px",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Comments/Log",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"comment",content:"Add Entry",onClick:function(){function O(){return(0,p.modalOpen)(x,"add_comment")}return O}()}),children:M.comments.length===0?(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No comments found."}):M.comments.map(function(O,R){return(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,o.Box,{color:"label",inline:!0,children:O.header}),(0,e.createVNode)(1,"br"),O.text,(0,e.createComponentVNode)(2,o.Button,{icon:"comment-slash",color:"bad",ml:"0.5rem",onClick:function(){function F(){return P("del_comment",{del_comment:R+1})}return F}()})]},R)})})})},f=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.virus,O=(0,t.useLocalState)(x,"searchText",""),R=O[0],F=O[1],W=(0,t.useLocalState)(x,"sortId2","name"),U=W[0],z=W[1],$=(0,t.useLocalState)(x,"sortOrder2",!0),G=$[0],X=$[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{ml:"0.25rem",fluid:!0,placeholder:"Search by Name, Max Stages, or Severity",onInput:function(){function J(se,ie){return F(ie)}return J}()})}),(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,mt:.5,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"MedicalRecords__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,I,{id:"name",children:"Name"}),(0,e.createComponentVNode)(2,I,{id:"max_stages",children:"Max Stages"}),(0,e.createComponentVNode)(2,I,{id:"severity",children:"Severity"})]}),M.filter((0,a.createSearch)(R,function(J){return J.name+"|"+J.max_stages+"|"+J.severity})).sort(function(J,se){var ie=G?1:-1;return J[U].localeCompare(se[U])*ie}).map(function(J){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"MedicalRecords__listVirus--"+J.severity,onClick:function(){function se(){return P("vir",{vir:J.D})}return se}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"virus"})," ",J.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:J.max_stages}),(0,e.createComponentVNode)(2,o.Table.Cell,{color:h[J.severity],children:J.severity})]},J.id)})]})})})})],4)},N=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.goals;return(0,e.createComponentVNode)(2,o.Section,{title:"Virology Goals",fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:M.length!==0&&M.map(function(O){return(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:O.name,children:[(0,e.createComponentVNode)(2,o.Table,{children:(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:(0,e.createComponentVNode)(2,o.Table.Cell,{textAlign:"center",children:(0,e.createComponentVNode)(2,o.ProgressBar,{value:O.delivered,minValue:0,maxValue:O.deliverygoal,ranges:{good:[O.deliverygoal*.5,1/0],average:[O.deliverygoal*.25,O.deliverygoal*.5],bad:[-1/0,O.deliverygoal*.25]},children:[O.delivered," / ",O.deliverygoal," Units"]})})})}),(0,e.createComponentVNode)(2,o.Box,{children:O.report})]})},O.id)})||(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Box,{textAlign:"center",children:"No Goals Detected"})})})})},V=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.medbots;return M.length===0?(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{bold:!0,grow:!0,textAlign:"center",fontSize:1.75,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon.Stack,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"robot",size:5,color:"gray"}),(0,e.createComponentVNode)(2,o.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"There are no Medibots."]})})})}):(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"MedicalRecords__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Area"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Chemicals"})]}),M.map(function(O){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"MedicalRecords__listMedbot--"+O.on,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"medical"})," ",O.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:[O.area||"Unknown"," (",O.x,", ",O.y,")"]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:O.on?(0,e.createComponentVNode)(2,o.Box,{color:"good",children:"Online"}):(0,e.createComponentVNode)(2,o.Box,{color:"average",children:"Offline"})}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:O.use_beaker?"Reservoir: "+O.total_volume+"/"+O.maximum_volume:"Using internal synthesizer"})]},O.id)})]})})})},B=function(A,x){var E=(0,t.useLocalState)(x,"sortId","name"),P=E[0],D=E[1],M=(0,t.useLocalState)(x,"sortOrder",!0),O=M[0],R=M[1],F=A.id,W=A.children;return(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,color:P!==F&&"transparent",onClick:function(){function U(){P===F?R(!O):(D(F),R(!0))}return U}(),children:[W,P===F&&(0,e.createComponentVNode)(2,o.Icon,{name:O?"sort-up":"sort-down",ml:"0.25rem;"})]})})},I=function(A,x){var E=(0,t.useLocalState)(x,"sortId2","name"),P=E[0],D=E[1],M=(0,t.useLocalState)(x,"sortOrder2",!0),O=M[0],R=M[1],F=A.id,W=A.children;return(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,color:P!==F&&"transparent",onClick:function(){function U(){P===F?R(!O):(D(F),R(!0))}return U}(),children:[W,P===F&&(0,e.createComponentVNode)(2,o.Icon,{name:O?"sort-up":"sort-down",ml:"0.25rem;"})]})})},L=function(A,x){var E=(0,t.useBackend)(x),P=E.act,D=E.data,M=D.screen,O=D.general;return(0,e.createComponentVNode)(2,o.Stack.Item,{m:0,children:(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"list",selected:M===2,onClick:function(){function R(){P("screen",{screen:2})}return R}(),children:"List Records"}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"database",selected:M===5,onClick:function(){function R(){P("screen",{screen:5})}return R}(),children:"Virus Database"}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"vial",selected:M===6,onClick:function(){function R(){P("screen",{screen:6})}return R}(),children:"Virology Goals"}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"plus-square",selected:M===7,onClick:function(){function R(){return P("screen",{screen:7})}return R}(),children:"Medibot Tracking"}),M===3&&(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"wrench",selected:M===3,children:"Record Maintenance"}),M===4&&O&&!O.empty&&(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"file",selected:M===4,children:["Record: ",O.fields[0].value]})]})})};(0,p.modalRegisterBodyOverride)("virus",m)},54989:function(T,r,n){"use strict";r.__esModule=!0,r.MerchVendor=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=h.product,s=h.productImage,d=h.productCategory,C=l.user_money;return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,children:(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+s,style:{"vertical-align":"middle",width:"32px",margin:"0px","margin-left":"0px"}})}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:u.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{disabled:u.price>C,icon:"shopping-cart",content:u.price,textAlign:"left",onClick:function(){function g(){return m("purchase",{name:u.name,category:d})}return g}()})})]})},b=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=(0,a.useLocalState)(i,"tabIndex",1),u=l[0],s=m.products,d=m.imagelist,C=["apparel","toy","decoration"];return(0,e.createComponentVNode)(2,t.Table,{children:s[C[u]].map(function(g){return(0,e.createComponentVNode)(2,p,{product:g,productImage:d[g.path],productCategory:C[u]},g.name)})})},y=r.MerchVendor=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.user_cash,s=l.inserted_cash;return(0,e.createComponentVNode)(2,o.Window,{title:"Merch Computer",width:450,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"User",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{color:"light-grey",inline:!0,mr:"0.5rem",children:["There is ",(0,e.createVNode)(1,"b",null,s,0)," credits inserted."]}),(0,e.createComponentVNode)(2,t.Button,{disabled:!s,icon:"money-bill-wave-alt",content:"Dispense Change",textAlign:"left",onClick:function(){function d(){return m("change")}return d}()})],4),children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:["Doing your job and not getting any recognition at work? Well, welcome to the merch shop! Here, you can buy cool things in exchange for money you earn when you have completed your Job Objectives.",u!==null&&(0,e.createComponentVNode)(2,t.Box,{mt:"0.5rem",children:["Your balance is ",(0,e.createVNode)(1,"b",null,[u||0,(0,e.createTextVNode)(" credits")],0),"."]})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Products",children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,b)]})})]})})})}return k}(),S=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=(0,a.useLocalState)(i,"tabIndex",1),u=l[0],s=l[1],d=m.login_state;return(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"dice",selected:u===1,onClick:function(){function C(){return s(1)}return C}(),children:"Toys"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"flag",selected:u===2,onClick:function(){function C(){return s(2)}return C}(),children:"Decorations"})]})}},87684:function(T,r,n){"use strict";r.__esModule=!0,r.MiningVendor=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=["title","items","gridLayout"];function y(l,u){if(l==null)return{};var s={};for(var d in l)if({}.hasOwnProperty.call(l,d)){if(u.includes(d))continue;s[d]=l[d]}return s}var S={Alphabetical:function(){function l(u,s){return u-s}return l}(),Availability:function(){function l(u,s){return-(u.affordable-s.affordable)}return l}(),Price:function(){function l(u,s){return u.price-s.price}return l}()},k=r.MiningVendor=function(){function l(u,s){var d=(0,t.useLocalState)(s,"gridLayout",!1),C=d[0],g=d[1];return(0,e.createComponentVNode)(2,p.Window,{width:400,height:525,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,h),(0,e.createComponentVNode)(2,c,{gridLayout:C,setGridLayout:g}),(0,e.createComponentVNode)(2,i,{gridLayout:C})]})})})}return l}(),h=function(u,s){var d=(0,t.useBackend)(s),C=d.act,g=d.data,v=g.has_id,f=g.id;return(0,e.createComponentVNode)(2,o.NoticeBox,{success:v,children:v?(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Box,{inline:!0,verticalAlign:"middle",style:{float:"left"},children:["Logged in as ",f.name,".",(0,e.createVNode)(1,"br"),"You have ",f.points.toLocaleString("en-US")," points."]}),(0,e.createComponentVNode)(2,o.Button,{icon:"eject",content:"Eject ID",style:{float:"right"},onClick:function(){function N(){return C("logoff")}return N}()}),(0,e.createComponentVNode)(2,o.Box,{style:{clear:"both"}})],4):"Please insert an ID in order to make purchases."})},i=function(u,s){var d=(0,t.useBackend)(s),C=d.act,g=d.data,v=g.has_id,f=g.id,N=g.items,V=u.gridLayout,B=(0,t.useLocalState)(s,"search",""),I=B[0],L=B[1],w=(0,t.useLocalState)(s,"sort","Alphabetical"),A=w[0],x=w[1],E=(0,t.useLocalState)(s,"descending",!1),P=E[0],D=E[1],M=(0,a.createSearch)(I,function(F){return F[0]}),O=!1,R=Object.entries(N).map(function(F,W){var U=Object.entries(F[1]).filter(M).map(function(z){return z[1].affordable=v&&f.points>=z[1].price,z[1]}).sort(S[A]);if(U.length!==0)return P&&(U=U.reverse()),O=!0,(0,e.createComponentVNode)(2,m,{title:F[0],items:U,gridLayout:V},F[0])});return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,mt:.5,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:O?R:(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No items matching your criteria was found!"})})})},c=function(u,s){var d=u.gridLayout,C=u.setGridLayout,g=(0,t.useLocalState)(s,"search",""),v=g[0],f=g[1],N=(0,t.useLocalState)(s,"sort",""),V=N[0],B=N[1],I=(0,t.useLocalState)(s,"descending",!1),L=I[0],w=I[1];return(0,e.createComponentVNode)(2,o.Box,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{mt:.2,placeholder:"Search by item name..",width:"100%",onInput:function(){function A(x,E){return f(E)}return A}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:d?"list":"table-cells-large",height:1.75,tooltip:d?"Toggle List Layout":"Toggle Grid Layout",tooltipPosition:"bottom-start",onClick:function(){function A(){return C(!d)}return A}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"30%",children:(0,e.createComponentVNode)(2,o.Dropdown,{selected:"Alphabetical",options:Object.keys(S),width:"100%",onSelected:function(){function A(x){return B(x)}return A}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{icon:L?"arrow-down":"arrow-up",height:1.75,tooltip:L?"Descending order":"Ascending order",tooltipPosition:"bottom-start",onClick:function(){function A(){return w(!L)}return A}()})})]})})},m=function(u,s){var d=(0,t.useBackend)(s),C=d.act,g=d.data,v=u.title,f=u.items,N=u.gridLayout,V=y(u,b);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Collapsible,Object.assign({open:!0,title:v},V,{children:f.map(function(B){return N?(0,e.createComponentVNode)(2,o.ImageButton,{mb:.5,imageSize:57.5,dmIcon:B.icon,dmIconState:B.icon_state,disabled:!g.has_id||g.id.points0&&(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__menuButton--unread",children:ae>=10?"9+":ae})}),(0,e.createComponentVNode)(2,s,{icon:"briefcase",title:"Job Openings",selected:R===1,onClick:function(){function le(){return x("jobs")}return le}()}),(0,e.createComponentVNode)(2,o.Divider)]}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:F.map(function(le){return(0,e.createComponentVNode)(2,s,{icon:le.icon,title:le.name,selected:R===2&&F[U-1]===le,onClick:function(){function Z(){return x("channel",{uid:le.uid})}return Z}(),children:le.unread>0&&(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__menuButton--unread",children:le.unread>=10?"9+":le.unread})},le)})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:[(0,e.createComponentVNode)(2,o.Divider),(!!P||!!D)&&(0,e.createFragment)([(0,e.createComponentVNode)(2,s,{security:!0,icon:"exclamation-circle",title:"Edit Wanted Notice",mb:"0.5rem",onClick:function(){function le(){return(0,y.modalOpen)(w,"wanted_notice")}return le}()}),(0,e.createComponentVNode)(2,s,{security:!0,icon:me?"minus-square":"minus-square-o",title:"Censor Mode: "+(me?"On":"Off"),mb:"0.5rem",onClick:function(){function le(){return q(!me)}return le}()}),(0,e.createComponentVNode)(2,o.Divider)],4),(0,e.createComponentVNode)(2,s,{icon:"pen-alt",title:"New Story",mb:"0.5rem",onClick:function(){function le(){return(0,y.modalOpen)(w,"create_story")}return le}()}),(0,e.createComponentVNode)(2,s,{icon:"plus-circle",title:"New Channel",onClick:function(){function le(){return(0,y.modalOpen)(w,"create_channel")}return le}()}),(0,e.createComponentVNode)(2,o.Divider),(0,e.createComponentVNode)(2,s,{icon:O?"spinner":"print",iconSpin:O,title:O?"Printing...":"Print Newspaper",onClick:function(){function le(){return x("print_newspaper")}return le}()}),(0,e.createComponentVNode)(2,s,{icon:M?"volume-mute":"volume-up",title:"Mute: "+(M?"On":"Off"),onClick:function(){function le(){return x("toggle_mute")}return le}()})]})]})}),(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,width:"100%",children:[(0,e.createComponentVNode)(2,S.TemporaryNotice),re]})]})})]})}return I}(),s=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=L.icon,P=E===void 0?"":E,D=L.iconSpin,M=L.selected,O=M===void 0?!1:M,R=L.security,F=R===void 0?!1:R,W=L.onClick,U=L.title,z=L.children,$=i(L,k);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Box,Object.assign({className:(0,a.classes)(["Newscaster__menuButton",O&&"Newscaster__menuButton--selected",F&&"Newscaster__menuButton--security"]),onClick:W},$,{children:[O&&(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__menuButton--selectedBar"}),(0,e.createComponentVNode)(2,o.Icon,{name:P,spin:D,size:"2"}),(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__menuButton--title",children:U}),z]})))},d=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=E.screen,D=E.is_admin,M=E.channel_idx,O=E.channel_can_manage,R=E.channels,F=E.stories,W=E.wanted,U=(0,t.useLocalState)(w,"fullStories",[]),z=U[0],$=U[1],G=(0,t.useLocalState)(w,"censorMode",!1),X=G[0],J=G[1],se=P===2&&M>-1?R[M-1]:null;return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[!!W&&(0,e.createComponentVNode)(2,g,{story:W,wanted:!0}),(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Icon,{name:se?se.icon:"newspaper",mr:"0.5rem"}),se?se.name:"Headlines"],0),children:F.length>0?F.slice().reverse().map(function(ie){return!z.includes(ie.uid)&&ie.body.length+3>c?Object.assign({},ie,{body_short:ie.body.substr(0,c-4)+"..."}):ie}).map(function(ie,me){return(0,e.createComponentVNode)(2,g,{story:ie},me)}):(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__emptyNotice",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"times",size:"3"}),(0,e.createVNode)(1,"br"),"There are no stories at this time."]})}),!!se&&(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,height:"40%",title:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Icon,{name:"info-circle",mr:"0.5rem"}),(0,e.createTextVNode)("About")],4),buttons:(0,e.createFragment)([X&&(0,e.createComponentVNode)(2,o.Button,{disabled:!!se.admin&&!D,selected:se.censored,icon:se.censored?"comment-slash":"comment",content:se.censored?"Uncensor Channel":"Censor Channel",mr:"0.5rem",onClick:function(){function ie(){return x("censor_channel",{uid:se.uid})}return ie}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:!O,icon:"cog",content:"Manage",onClick:function(){function ie(){return(0,y.modalOpen)(w,"manage_channel",{uid:se.uid})}return ie}()})],0),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Description",children:se.description||"N/A"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Owner",children:se.author||"N/A"}),!!D&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Ckey",children:se.author_ckey}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Public",children:se.public?"Yes":"No"}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Total Views",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"eye",mr:"0.5rem"}),F.reduce(function(ie,me){return ie+me.view_count},0).toLocaleString()]})]})})]})},C=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=E.jobs,D=E.wanted,M=Object.entries(P).reduce(function(O,R){var F=R[0],W=R[1];return O+W.length},0);return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[!!D&&(0,e.createComponentVNode)(2,g,{story:D,wanted:!0}),(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Icon,{name:"briefcase",mr:"0.5rem"}),(0,e.createTextVNode)("Job Openings")],4),buttons:(0,e.createComponentVNode)(2,o.Box,{mt:"0.25rem",color:"label",children:"Work for a better future at Nanotrasen"}),children:M>0?m.map(function(O){return Object.assign({},l[O],{id:O,jobs:P[O]})}).filter(function(O){return!!O&&O.jobs.length>0}).map(function(O){return(0,e.createComponentVNode)(2,o.Section,{className:(0,a.classes)(["Newscaster__jobCategory","Newscaster__jobCategory--"+O.id]),title:O.title,buttons:(0,e.createComponentVNode)(2,o.Box,{mt:"0.25rem",color:"label",children:O.fluff_text}),children:O.jobs.map(function(R){return(0,e.createComponentVNode)(2,o.Box,{class:(0,a.classes)(["Newscaster__jobOpening",!!R.is_command&&"Newscaster__jobOpening--command"]),children:["\u2022 ",R.title]},R.title)})},O.id)}):(0,e.createComponentVNode)(2,o.Box,{className:"Newscaster__emptyNotice",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"times",size:"3"}),(0,e.createVNode)(1,"br"),"There are no openings at this time."]})}),(0,e.createComponentVNode)(2,o.Section,{height:"17%",children:["Interested in serving Nanotrasen?",(0,e.createVNode)(1,"br"),"Sign up for any of the above position now at the ",(0,e.createVNode)(1,"b",null,"Head of Personnel's Office!",16),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.Box,{as:"small",color:"label",children:"By signing up for a job at Nanotrasen, you agree to transfer your soul to the loyalty department of the omnipresent and helpful watcher of humanity."})]})]})},g=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=L.story,D=L.wanted,M=D===void 0?!1:D,O=E.is_admin,R=(0,t.useLocalState)(w,"fullStories",[]),F=R[0],W=R[1],U=(0,t.useLocalState)(w,"censorMode",!1),z=U[0],$=U[1];return(0,e.createComponentVNode)(2,o.Section,{className:(0,a.classes)(["Newscaster__story",M&&"Newscaster__story--wanted"]),title:(0,e.createFragment)([M&&(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-circle",mr:"0.5rem"}),P.censor_flags&2&&"[REDACTED]"||P.title||"News from "+P.author],0),buttons:(0,e.createComponentVNode)(2,o.Box,{mt:"0.25rem",children:(0,e.createComponentVNode)(2,o.Box,{color:"label",children:[!M&&z&&(0,e.createComponentVNode)(2,o.Box,{inline:!0,children:(0,e.createComponentVNode)(2,o.Button,{enabled:P.censor_flags&2,icon:P.censor_flags&2?"comment-slash":"comment",content:P.censor_flags&2?"Uncensor":"Censor",mr:"0.5rem",mt:"-0.25rem",onClick:function(){function G(){return x("censor_story",{uid:P.uid})}return G}()})}),(0,e.createComponentVNode)(2,o.Box,{inline:!0,children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user"})," ",P.author," |\xA0",!!O&&(0,e.createFragment)([(0,e.createTextVNode)("ckey: "),P.author_ckey,(0,e.createTextVNode)(" |\xA0")],0),!M&&(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Icon,{name:"eye"}),(0,e.createTextVNode)(" "),P.view_count.toLocaleString(),(0,e.createTextVNode)(" |\xA0")],0),(0,e.createComponentVNode)(2,o.Icon,{name:"clock"})," ",(0,p.timeAgo)(P.publish_time,E.world_time)]})]})}),children:(0,e.createComponentVNode)(2,o.Box,{children:P.censor_flags&2?"[REDACTED]":(0,e.createFragment)([!!P.has_photo&&(0,e.createComponentVNode)(2,v,{name:"story_photo_"+P.uid+".png",float:"right",ml:"0.5rem"}),(P.body_short||P.body).split("\n").map(function(G,X){return(0,e.createComponentVNode)(2,o.Box,{children:G||(0,e.createVNode)(1,"br")},X)}),P.body_short&&(0,e.createComponentVNode)(2,o.Button,{content:"Read more..",mt:"0.5rem",onClick:function(){function G(){return W([].concat(F,[P.uid]))}return G}()}),(0,e.createComponentVNode)(2,o.Box,{clear:"right"})],0)})})},v=function(L,w){var A=L.name,x=i(L,h),E=(0,t.useLocalState)(w,"viewingPhoto",""),P=E[0],D=E[1];return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Box,Object.assign({as:"img",className:"Newscaster__photo",src:A,onClick:function(){function M(){return D(A)}return M}()},x)))},f=function(L,w){var A=(0,t.useLocalState)(w,"viewingPhoto",""),x=A[0],E=A[1];return(0,e.createComponentVNode)(2,o.Modal,{className:"Newscaster__photoZoom",children:[(0,e.createComponentVNode)(2,o.Box,{as:"img",src:x}),(0,e.createComponentVNode)(2,o.Button,{icon:"times",content:"Close",color:"grey",mt:"1rem",onClick:function(){function P(){return E("")}return P}()})]})},N=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=!!L.args.uid&&E.channels.filter(function(te){return te.uid===L.args.uid}).pop();if(L.id==="manage_channel"&&!P){(0,y.modalClose)(w);return}var D=L.id==="manage_channel",M=!!L.args.is_admin,O=L.args.scanned_user,R=(0,t.useLocalState)(w,"author",(P==null?void 0:P.author)||O||"Unknown"),F=R[0],W=R[1],U=(0,t.useLocalState)(w,"name",(P==null?void 0:P.name)||""),z=U[0],$=U[1],G=(0,t.useLocalState)(w,"description",(P==null?void 0:P.description)||""),X=G[0],J=G[1],se=(0,t.useLocalState)(w,"icon",(P==null?void 0:P.icon)||"newspaper"),ie=se[0],me=se[1],q=(0,t.useLocalState)(w,"isPublic",D?!!(P!=null&&P.public):!1),re=q[0],ae=q[1],le=(0,t.useLocalState)(w,"adminLocked",(P==null?void 0:P.admin)===1||!1),Z=le[0],ne=le[1];return(0,e.createComponentVNode)(2,o.Section,{m:"-1rem",pb:"1.5rem",title:D?"Manage "+P.name:"Create New Channel",children:[(0,e.createComponentVNode)(2,o.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Owner",children:(0,e.createComponentVNode)(2,o.Input,{disabled:!M,width:"100%",value:F,onInput:function(){function te(fe,pe){return W(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Name",children:(0,e.createComponentVNode)(2,o.Input,{width:"100%",placeholder:"50 characters max.",maxLength:"50",value:z,onInput:function(){function te(fe,pe){return $(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Description (optional)",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Input,{multiline:!0,width:"100%",placeholder:"128 characters max.",maxLength:"128",value:X,onInput:function(){function te(fe,pe){return J(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Icon",children:[(0,e.createComponentVNode)(2,o.Input,{disabled:!M,value:ie,width:"35%",mr:"0.5rem",onInput:function(){function te(fe,pe){return me(pe)}return te}()}),(0,e.createComponentVNode)(2,o.Icon,{name:ie,size:"2",verticalAlign:"middle",mr:"0.5rem"})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Accept Public Stories?",children:(0,e.createComponentVNode)(2,o.Button,{selected:re,icon:re?"toggle-on":"toggle-off",content:re?"Yes":"No",onClick:function(){function te(){return ae(!re)}return te}()})}),M&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"CentComm Lock",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Button,{selected:Z,icon:Z?"lock":"lock-open",content:Z?"On":"Off",tooltip:"Locking this channel will make it editable by nobody but CentComm officers.",tooltipPosition:"top",onClick:function(){function te(){return ne(!Z)}return te}()})})]})}),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:F.trim().length===0||z.trim().length===0,icon:"check",color:"good",content:"Submit",position:"absolute",right:"1rem",bottom:"-0.75rem",onClick:function(){function te(){(0,y.modalAnswer)(w,L.id,"",{author:F,name:z.substr(0,49),description:X.substr(0,128),icon:ie,public:re?1:0,admin_locked:Z?1:0})}return te}()})]})},V=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=E.photo,D=E.channels,M=E.channel_idx,O=M===void 0?-1:M,R=!!L.args.is_admin,F=L.args.scanned_user,W=D.slice().sort(function(te,fe){if(O<0)return 0;var pe=D[O-1];if(pe.uid===te.uid)return-1;if(pe.uid===fe.uid)return 1}).filter(function(te){return R||!te.frozen&&(te.author===F||!!te.public)}),U=(0,t.useLocalState)(w,"author",F||"Unknown"),z=U[0],$=U[1],G=(0,t.useLocalState)(w,"channel",W.length>0?W[0].name:""),X=G[0],J=G[1],se=(0,t.useLocalState)(w,"title",""),ie=se[0],me=se[1],q=(0,t.useLocalState)(w,"body",""),re=q[0],ae=q[1],le=(0,t.useLocalState)(w,"adminLocked",!1),Z=le[0],ne=le[1];return(0,e.createComponentVNode)(2,o.Section,{m:"-1rem",pb:"1.5rem",title:"Create New Story",children:[(0,e.createComponentVNode)(2,o.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Author",children:(0,e.createComponentVNode)(2,o.Input,{disabled:!R,width:"100%",value:z,onInput:function(){function te(fe,pe){return $(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Channel",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Dropdown,{selected:X,options:W.map(function(te){return te.name}),mb:"0",width:"100%",onSelected:function(){function te(fe){return J(fe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Divider),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,o.Input,{width:"100%",placeholder:"128 characters max.",maxLength:"128",value:ie,onInput:function(){function te(fe,pe){return me(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Story Text",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Input,{fluid:!0,multiline:!0,placeholder:"1024 characters max.",maxLength:"1024",rows:"8",width:"100%",value:re,onInput:function(){function te(fe,pe){return ae(pe)}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Photo (optional)",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Button,{icon:"image",selected:P,content:P?"Eject: "+P.name:"Insert Photo",tooltip:!P&&"Attach a photo to this story by holding the photograph in your hand.",onClick:function(){function te(){return x(P?"eject_photo":"attach_photo")}return te}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Preview",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Section,{noTopPadding:!0,title:ie,maxHeight:"13.5rem",overflow:"auto",children:(0,e.createComponentVNode)(2,o.Box,{mt:"0.5rem",children:[!!P&&(0,e.createComponentVNode)(2,v,{name:"inserted_photo_"+P.uid+".png",float:"right"}),re.split("\n").map(function(te,fe){return(0,e.createComponentVNode)(2,o.Box,{children:te||(0,e.createVNode)(1,"br")},fe)}),(0,e.createComponentVNode)(2,o.Box,{clear:"right"})]})})}),R&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"CentComm Lock",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Button,{selected:Z,icon:Z?"lock":"lock-open",content:Z?"On":"Off",tooltip:"Locking this story will make it censorable by nobody but CentComm officers.",tooltipPosition:"top",onClick:function(){function te(){return ne(!Z)}return te}()})})]})}),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:z.trim().length===0||X.trim().length===0||ie.trim().length===0||re.trim().length===0,icon:"check",color:"good",content:"Submit",position:"absolute",right:"1rem",bottom:"-0.75rem",onClick:function(){function te(){(0,y.modalAnswer)(w,"create_story","",{author:z,channel:X,title:ie.substr(0,127),body:re.substr(0,1023),admin_locked:Z?1:0})}return te}()})]})},B=function(L,w){var A=(0,t.useBackend)(w),x=A.act,E=A.data,P=E.photo,D=E.wanted,M=!!L.args.is_admin,O=L.args.scanned_user,R=(0,t.useLocalState)(w,"author",(D==null?void 0:D.author)||O||"Unknown"),F=R[0],W=R[1],U=(0,t.useLocalState)(w,"name",(D==null?void 0:D.title.substr(8))||""),z=U[0],$=U[1],G=(0,t.useLocalState)(w,"description",(D==null?void 0:D.body)||""),X=G[0],J=G[1],se=(0,t.useLocalState)(w,"adminLocked",(D==null?void 0:D.admin_locked)===1||!1),ie=se[0],me=se[1];return(0,e.createComponentVNode)(2,o.Section,{m:"-1rem",pb:"1.5rem",title:"Manage Wanted Notice",children:[(0,e.createComponentVNode)(2,o.Box,{mx:"0.5rem",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Authority",children:(0,e.createComponentVNode)(2,o.Input,{disabled:!M,width:"100%",value:F,onInput:function(){function q(re,ae){return W(ae)}return q}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Name",children:(0,e.createComponentVNode)(2,o.Input,{width:"100%",value:z,maxLength:"128",onInput:function(){function q(re,ae){return $(ae)}return q}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Description",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Input,{multiline:!0,width:"100%",value:X,maxLength:"512",rows:"4",onInput:function(){function q(re,ae){return J(ae)}return q}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Photo (optional)",verticalAlign:"top",children:[(0,e.createComponentVNode)(2,o.Button,{icon:"image",selected:P,content:P?"Eject: "+P.name:"Insert Photo",tooltip:!P&&"Attach a photo to this wanted notice by holding the photograph in your hand.",tooltipPosition:"top",onClick:function(){function q(){return x(P?"eject_photo":"attach_photo")}return q}()}),!!P&&(0,e.createComponentVNode)(2,v,{name:"inserted_photo_"+P.uid+".png",float:"right"})]}),M&&(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"CentComm Lock",verticalAlign:"top",children:(0,e.createComponentVNode)(2,o.Button,{selected:ie,icon:ie?"lock":"lock-open",content:ie?"On":"Off",tooltip:"Locking this wanted notice will make it editable by nobody but CentComm officers.",tooltipPosition:"top",onClick:function(){function q(){return me(!ie)}return q}()})})]})}),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:!D,icon:"eraser",color:"danger",content:"Clear",position:"absolute",right:"7.25rem",bottom:"-0.75rem",onClick:function(){function q(){x("clear_wanted_notice"),(0,y.modalClose)(w)}return q}()}),(0,e.createComponentVNode)(2,o.Button.Confirm,{disabled:F.trim().length===0||z.trim().length===0||X.trim().length===0,icon:"check",color:"good",content:"Submit",position:"absolute",right:"1rem",bottom:"-0.75rem",onClick:function(){function q(){(0,y.modalAnswer)(w,L.id,"",{author:F,name:z.substr(0,127),description:X.substr(0,511),admin_locked:ie?1:0})}return q}()})]})};(0,y.modalRegisterBodyOverride)("create_channel",N),(0,y.modalRegisterBodyOverride)("manage_channel",N),(0,y.modalRegisterBodyOverride)("create_story",V),(0,y.modalRegisterBodyOverride)("wanted_notice",B)},48286:function(T,r,n){"use strict";r.__esModule=!0,r.Noticeboard=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=r.Noticeboard=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.act,c=h.data,m=c.papers;return(0,e.createComponentVNode)(2,p.Window,{width:600,height:300,theme:"noticeboard",children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:m.map(function(l){return(0,e.createComponentVNode)(2,o.Stack.Item,{align:"center",width:"22.45%",height:"85%",onClick:function(){function u(){return i("interact",{paper:l.ref})}return u}(),onContextMenu:function(){function u(s){s.preventDefault(),i("showFull",{paper:l.ref})}return u}(),children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,fontSize:.75,title:l.name,children:(0,a.decodeHtmlEntities)(l.contents)})},l.ref)})})})})}return y}()},41166:function(T,r,n){"use strict";r.__esModule=!0,r.NuclearBomb=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.NuclearBomb=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;return i.extended?(0,e.createComponentVNode)(2,o.Window,{width:350,height:290,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Authorization",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auth Disk",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.authdisk?"eject":"id-card",selected:i.authdisk,content:i.diskname?i.diskname:"-----",tooltip:i.authdisk?"Eject Disk":"Insert Disk",onClick:function(){function c(){return h("auth")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auth Code",children:(0,e.createComponentVNode)(2,t.Button,{icon:"key",disabled:!i.authdisk,selected:i.authcode,content:i.codemsg,onClick:function(){function c(){return h("code")}return c}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Arming & Disarming",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Bolted to floor",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.anchored?"check":"times",selected:i.anchored,disabled:!i.authdisk,content:i.anchored?"YES":"NO",onClick:function(){function c(){return h("toggle_anchor")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Time Left",children:(0,e.createComponentVNode)(2,t.Button,{icon:"stopwatch",content:i.time,disabled:!i.authfull,tooltip:"Set Timer",onClick:function(){function c(){return h("set_time")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Safety",children:(0,e.createComponentVNode)(2,t.Button,{icon:i.safety?"check":"times",selected:i.safety,disabled:!i.authfull,content:i.safety?"ON":"OFF",tooltip:i.safety?"Disable Safety":"Enable Safety",onClick:function(){function c(){return h("toggle_safety")}return c}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Arm/Disarm",children:(0,e.createComponentVNode)(2,t.Button,{icon:(i.timer,"bomb"),disabled:i.safety||!i.authfull,color:"red",content:i.timer?"DISARM THE NUKE":"ARM THE NUKE",onClick:function(){function c(){return h("toggle_armed")}return c}()})})]})})]})}):(0,e.createComponentVNode)(2,o.Window,{width:350,height:115,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Deployment",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"exclamation-triangle",content:"Deploy Nuclear Device (will bolt device to floor)",onClick:function(){function c(){return h("deploy")}return c}()})})})})}return b}()},52416:function(T,r,n){"use strict";r.__esModule=!0,r.NumberInputModal=void 0;var e=n(89005),a=n(51057),t=n(19203),o=n(92986),p=n(72253),b=n(36036),y=n(98595),S=r.NumberInputModal=function(){function h(i,c){var m=(0,p.useBackend)(c),l=m.act,u=m.data,s=u.init_value,d=u.large_buttons,C=u.message,g=C===void 0?"":C,v=u.timeout,f=u.title,N=(0,p.useLocalState)(c,"input",s),V=N[0],B=N[1],I=function(){function A(x){x!==V&&B(x)}return A}(),L=function(){function A(x){x!==V&&B(x)}return A}(),w=140+Math.max(Math.ceil(g.length/3),g.length>0&&d?5:0);return(0,e.createComponentVNode)(2,y.Window,{title:f,width:270,height:w,children:[v&&(0,e.createComponentVNode)(2,a.Loader,{value:v}),(0,e.createComponentVNode)(2,y.Window.Content,{onKeyDown:function(){function A(x){var E=window.event?x.which:x.keyCode;E===o.KEY_ENTER&&l("submit",{entry:V}),E===o.KEY_ESCAPE&&l("cancel")}return A}(),children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,children:(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Box,{color:"label",children:g})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,k,{input:V,onClick:L,onChange:I})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,t.InputButtons,{input:V})})]})})})]})}return h}(),k=function(i,c){var m=(0,p.useBackend)(c),l=m.act,u=m.data,s=u.min_value,d=u.max_value,C=u.init_value,g=u.round_value,v=i.input,f=i.onClick,N=i.onChange,V=Math.round(v!==s?Math.max(v/2,s):d/2),B=v===s&&s>0||v===1;return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Button,{disabled:v===s,icon:"angle-double-left",onClick:function(){function I(){return f(s)}return I}(),tooltip:v===s?"Min":"Min ("+s+")"})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.RestrictedInput,{autoFocus:!0,autoSelect:!0,fluid:!0,allowFloats:!g,minValue:s,maxValue:d,onChange:function(){function I(L,w){return N(w)}return I}(),onEnter:function(){function I(L,w){return l("submit",{entry:w})}return I}(),value:v})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Button,{disabled:v===d,icon:"angle-double-right",onClick:function(){function I(){return f(d)}return I}(),tooltip:v===d?"Max":"Max ("+d+")"})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Button,{disabled:B,icon:"divide",onClick:function(){function I(){return f(V)}return I}(),tooltip:B?"Split":"Split ("+V+")"})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Button,{disabled:v===C,icon:"redo",onClick:function(){function I(){return f(C)}return I}(),tooltip:C?"Reset ("+C+")":"Reset"})})]})}},1218:function(T,r,n){"use strict";r.__esModule=!0,r.OperatingComputer=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(98595),p=n(36036),b=[["good","Conscious"],["average","Unconscious"],["bad","DEAD"]],y=[["Resp.","oxyLoss"],["Toxin","toxLoss"],["Brute","bruteLoss"],["Burn","fireLoss"]],S={average:[.25,.5],bad:[.5,1/0]},k=["bad","average","average","good","average","average","bad"],h=r.OperatingComputer=function(){function l(u,s){var d=(0,t.useBackend)(s),C=d.act,g=d.data,v=g.hasOccupant,f=g.choice,N;return f?N=(0,e.createComponentVNode)(2,m):N=v?(0,e.createComponentVNode)(2,i):(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,o.Window,{width:650,height:455,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Tabs,{children:[(0,e.createComponentVNode)(2,p.Tabs.Tab,{selected:!f,icon:"user",onClick:function(){function V(){return C("choiceOff")}return V}(),children:"Patient"}),(0,e.createComponentVNode)(2,p.Tabs.Tab,{selected:!!f,icon:"cog",onClick:function(){function V(){return C("choiceOn")}return V}(),children:"Options"})]})}),(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.Section,{fill:!0,scrollable:!0,children:N})})]})})})}return l}(),i=function(u,s){var d=(0,t.useBackend)(s),C=d.data,g=C.occupant;return(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.Section,{fill:!0,title:"Patient",children:(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Name",children:g.name}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Status",color:b[g.stat][0],children:b[g.stat][1]}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:g.maxHealth,value:g.health/g.maxHealth,ranges:{good:[.5,1/0],average:[0,.5],bad:[-1/0,0]}})}),y.map(function(v,f){return(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:v[0]+" Damage",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:"100",value:g[v[1]]/100,ranges:S,children:(0,a.round)(g[v[1]])},f)},f)}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:g.maxTemp,value:g.bodyTemperature/g.maxTemp,color:k[g.temperatureSuitability+3],children:[(0,a.round)(g.btCelsius),"\xB0C, ",(0,a.round)(g.btFaren),"\xB0F"]})}),!!g.hasBlood&&(0,e.createFragment)([(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Blood Level",children:(0,e.createComponentVNode)(2,p.ProgressBar,{min:"0",max:g.bloodMax,value:g.bloodLevel/g.bloodMax,ranges:{bad:[-1/0,.6],average:[.6,.9],good:[.6,1/0]},children:[g.bloodPercent,"%, ",g.bloodLevel,"cl"]})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Pulse",children:[g.pulse," BPM"]})],4)]})})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Section,{title:"Current Procedure",level:"2",children:g.inSurgery?(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Procedure",children:g.surgeryName}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Next Step",children:g.stepName})]}):(0,e.createComponentVNode)(2,p.Box,{color:"label",children:"No procedure ongoing."})})})]})},c=function(){return(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,align:"center",textAlign:"center",color:"label",children:[(0,e.createComponentVNode)(2,p.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No patient detected."]})})},m=function(u,s){var d=(0,t.useBackend)(s),C=d.act,g=d.data,v=g.verbose,f=g.health,N=g.healthAlarm,V=g.oxy,B=g.oxyAlarm,I=g.crit;return(0,e.createComponentVNode)(2,p.LabeledList,{children:[(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Loudspeaker",children:(0,e.createComponentVNode)(2,p.Button,{selected:v,icon:v?"toggle-on":"toggle-off",content:v?"On":"Off",onClick:function(){function L(){return C(v?"verboseOff":"verboseOn")}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Health Announcer",children:(0,e.createComponentVNode)(2,p.Button,{selected:f,icon:f?"toggle-on":"toggle-off",content:f?"On":"Off",onClick:function(){function L(){return C(f?"healthOff":"healthOn")}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Health Announcer Threshold",children:(0,e.createComponentVNode)(2,p.Knob,{bipolar:!0,minValue:-100,maxValue:100,value:N,stepPixelSize:5,ml:"0",onChange:function(){function L(w,A){return C("health_adj",{new:A})}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Oxygen Alarm",children:(0,e.createComponentVNode)(2,p.Button,{selected:V,icon:V?"toggle-on":"toggle-off",content:V?"On":"Off",onClick:function(){function L(){return C(V?"oxyOff":"oxyOn")}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Oxygen Alarm Threshold",children:(0,e.createComponentVNode)(2,p.Knob,{bipolar:!0,minValue:-100,maxValue:100,value:B,stepPixelSize:5,ml:"0",onChange:function(){function L(w,A){return C("oxy_adj",{new:A})}return L}()})}),(0,e.createComponentVNode)(2,p.LabeledList.Item,{label:"Critical Alert",children:(0,e.createComponentVNode)(2,p.Button,{selected:I,icon:I?"toggle-on":"toggle-off",content:I?"On":"Off",onClick:function(){function L(){return C(I?"critOff":"critOn")}return L}()})})]})}},46892:function(T,r,n){"use strict";r.__esModule=!0,r.Orbit=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=n(35840);function y(d,C){var g=typeof Symbol!="undefined"&&d[Symbol.iterator]||d["@@iterator"];if(g)return(g=g.call(d)).next.bind(g);if(Array.isArray(d)||(g=S(d))||C&&d&&typeof d.length=="number"){g&&(d=g);var v=0;return function(){return v>=d.length?{done:!0}:{done:!1,value:d[v++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function S(d,C){if(d){if(typeof d=="string")return k(d,C);var g={}.toString.call(d).slice(8,-1);return g==="Object"&&d.constructor&&(g=d.constructor.name),g==="Map"||g==="Set"?Array.from(d):g==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(g)?k(d,C):void 0}}function k(d,C){(C==null||C>d.length)&&(C=d.length);for(var g=0,v=Array(C);gg},m=function(C,g){var v=C.name,f=g.name;if(!v||!f)return 0;var N=v.match(h),V=f.match(h);if(N&&V&&v.replace(h,"")===f.replace(h,"")){var B=parseInt(N[1],10),I=parseInt(V[1],10);return B-I}return c(v,f)},l=function(C,g){var v=C.searchText,f=C.source,N=C.title,V=C.color,B=C.sorted,I=f.filter(i(v));return B&&I.sort(m),f.length>0&&(0,e.createComponentVNode)(2,o.Section,{title:N+" - ("+f.length+")",children:I.map(function(L){return(0,e.createComponentVNode)(2,u,{thing:L,color:V},L.name)})})},u=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=C.color,V=C.thing;return(0,e.createComponentVNode)(2,o.Button,{color:N,tooltip:V.assigned_role?(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Box,{as:"img",mr:"0.5em",className:(0,b.classes)(["job_icons16x16",V.assigned_role_sprite])})," ",V.assigned_role]}):"",tooltipPosition:"bottom",onClick:function(){function B(){return f("orbit",{ref:V.ref})}return B}(),children:[V.name,V.orbiters&&(0,e.createComponentVNode)(2,o.Box,{inline:!0,ml:1,children:["(",V.orbiters," ",(0,e.createComponentVNode)(2,o.Icon,{name:"eye"}),")"]})]})},s=r.Orbit=function(){function d(C,g){for(var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.alive,B=N.antagonists,I=N.highlights,L=N.response_teams,w=N.tourist,A=N.auto_observe,x=N.dead,E=N.ssd,P=N.ghosts,D=N.misc,M=N.npcs,O=(0,t.useLocalState)(g,"searchText",""),R=O[0],F=O[1],W={},U=y(B),z;!(z=U()).done;){var $=z.value;W[$.antag]===void 0&&(W[$.antag]=[]),W[$.antag].push($)}var G=Object.entries(W);G.sort(function(J,se){return c(J[0],se[0])});var X=function(){function J(se){for(var ie=0,me=[G.map(function(ae){var le=ae[0],Z=ae[1];return Z}),w,I,V,P,E,x,M,D];ie0&&(0,e.createComponentVNode)(2,o.Section,{title:"Antagonists",children:G.map(function(J){var se=J[0],ie=J[1];return(0,e.createComponentVNode)(2,o.Section,{title:se+" - ("+ie.length+")",level:2,children:ie.filter(i(R)).sort(m).map(function(me){return(0,e.createComponentVNode)(2,u,{color:"bad",thing:me},me.name)})},se)})}),I.length>0&&(0,e.createComponentVNode)(2,l,{title:"Highlights",source:I,searchText:R,color:"teal"}),(0,e.createComponentVNode)(2,l,{title:"Response Teams",source:L,searchText:R,color:"purple"}),(0,e.createComponentVNode)(2,l,{title:"Tourists",source:w,searchText:R,color:"violet"}),(0,e.createComponentVNode)(2,l,{title:"Alive",source:V,searchText:R,color:"good"}),(0,e.createComponentVNode)(2,l,{title:"Ghosts",source:P,searchText:R,color:"grey"}),(0,e.createComponentVNode)(2,l,{title:"SSD",source:E,searchText:R,color:"grey"}),(0,e.createComponentVNode)(2,l,{title:"Dead",source:x,searchText:R,sorted:!1}),(0,e.createComponentVNode)(2,l,{title:"NPCs",source:M,searchText:R,sorted:!1}),(0,e.createComponentVNode)(2,l,{title:"Misc",source:D,searchText:R,sorted:!1})]})})}return d}()},15421:function(T,r,n){"use strict";r.__esModule=!0,r.OreRedemption=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=n(98595),b=n(9394);function y(d){if(d==null)throw new TypeError("Cannot destructure "+d)}var S=(0,b.createLogger)("OreRedemption"),k=function(C){return C.toLocaleString("en-US")+" pts"},h=r.OreRedemption=function(){function d(C,g){return(0,e.createComponentVNode)(2,p.Window,{width:490,height:750,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,i,{height:"100%"})}),(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,m)]})})})}return d}(),i=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.id,B=N.points,I=N.disk,L=Object.assign({},(y(C),C));return(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({},L,{children:[(0,e.createComponentVNode)(2,o.Box,{color:"average",textAlign:"center",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-triangle",mr:"0.5rem"}),"This machine only accepts ore. Gibtonite is not accepted."]}),(0,e.createComponentVNode)(2,o.Divider),(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Unclaimed Points",color:B>0?"good":"grey",bold:B>0&&"good",children:k(B)})}),(0,e.createComponentVNode)(2,o.Divider),I?(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Design disk",children:[(0,e.createComponentVNode)(2,o.Button,{selected:!0,bold:!0,icon:"eject",content:I.name,tooltip:"Ejects the design disk.",onClick:function(){function w(){return f("eject_disk")}return w}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:!I.design||!I.compatible,icon:"upload",content:"Download",tooltip:"Downloads the design on the disk into the machine.",onClick:function(){function w(){return f("download")}return w}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Stored design",children:(0,e.createComponentVNode)(2,o.Box,{color:I.design&&(I.compatible?"good":"bad"),children:I.design||"N/A"})})]}):(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No design disk inserted."})]})))},c=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.sheets,B=Object.assign({},(y(C),C));return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,height:"20%",children:(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({fill:!0,scrollable:!0,className:"OreRedemption__Ores",p:"0"},B,{children:[(0,e.createComponentVNode)(2,l,{title:"Sheets",columns:[["Available","25%"],["Ore Value","15%"],["Smelt","20%"]]}),V.map(function(I){return(0,e.createComponentVNode)(2,u,{ore:I},I.id)})]})))})},m=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.alloys,B=Object.assign({},(y(C),C));return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.normalizeProps)((0,e.createComponentVNode)(2,o.Section,Object.assign({fill:!0,scrollable:!0,className:"OreRedemption__Ores",p:"0"},B,{children:[(0,e.createComponentVNode)(2,l,{title:"Alloys",columns:[["Recipe","50%"],["Available","11%"],["Smelt","20%"]]}),V.map(function(I){return(0,e.createComponentVNode)(2,s,{ore:I},I.id)})]})))})},l=function(C,g){var v;return(0,e.createComponentVNode)(2,o.Box,{className:"OreHeader",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:C.title}),(v=C.columns)==null?void 0:v.map(function(f){return(0,e.createComponentVNode)(2,o.Stack.Item,{basis:f[1],textAlign:"center",color:"label",bold:!0,children:f[0]},f)})]})})},u=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=C.ore;if(!(N.value&&N.amount<=0&&!(["metal","glass"].indexOf(N.id)>-1)))return(0,e.createComponentVNode)(2,o.Box,{className:"SheetLine",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"45%",align:"middle",children:(0,e.createComponentVNode)(2,o.Stack,{align:"center",children:[(0,e.createComponentVNode)(2,o.Stack.Item,{className:(0,a.classes)(["materials32x32",N.id])}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:N.name})]})}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"20%",textAlign:"center",color:N.amount>=1?"good":"gray",bold:N.amount>=1,align:"center",children:N.amount.toLocaleString("en-US")}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"20%",textAlign:"center",align:"center",children:N.value}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"20%",textAlign:"center",align:"center",lineHeight:"32px",children:(0,e.createComponentVNode)(2,o.NumberInput,{width:"40%",value:0,minValue:0,maxValue:Math.min(N.amount,50),stepPixelSize:6,onChange:function(){function V(B,I){return f(N.value?"sheet":"alloy",{id:N.id,amount:I})}return V}()})})]})})},s=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=C.ore;return(0,e.createComponentVNode)(2,o.Box,{className:"SheetLine",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"7%",align:"middle",children:(0,e.createComponentVNode)(2,o.Box,{className:(0,a.classes)(["alloys32x32",N.id])})}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"30%",textAlign:"middle",align:"center",children:N.name}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"35%",textAlign:"middle",color:N.amount>=1?"good":"gray",align:"center",children:N.description}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"10%",textAlign:"center",color:N.amount>=1?"good":"gray",bold:N.amount>=1,align:"center",children:N.amount.toLocaleString("en-US")}),(0,e.createComponentVNode)(2,o.Stack.Item,{basis:"20%",textAlign:"center",align:"center",lineHeight:"32px",children:(0,e.createComponentVNode)(2,o.NumberInput,{width:"40%",value:0,minValue:0,maxValue:Math.min(N.amount,50),stepPixelSize:6,onChange:function(){function V(B,I){return f(N.value?"sheet":"alloy",{id:N.id,amount:I})}return V}()})})]})})}},52754:function(T,r,n){"use strict";r.__esModule=!0,r.PAI=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(71253),b=n(70752),y=function(h){var i;try{i=b("./"+h+".js")}catch(m){if(m.code==="MODULE_NOT_FOUND")return(0,p.routingError)("notFound",h);throw m}var c=i[h];return c||(0,p.routingError)("missingExport",h)},S=r.PAI=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.app_template,s=l.app_icon,d=l.app_title,C=y(u);return(0,e.createComponentVNode)(2,o.Window,{width:600,height:650,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{p:1,fill:!0,scrollable:!0,title:(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:s,mr:1}),d,u!=="pai_main_menu"&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{ml:2,mb:0,content:"Back",icon:"arrow-left",onClick:function(){function g(){return m("Back")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Home",icon:"arrow-up",onClick:function(){function g(){return m("MASTER_back")}return g}()})],4)]}),children:(0,e.createComponentVNode)(2,C)})})})})})}return k}()},85175:function(T,r,n){"use strict";r.__esModule=!0,r.PDA=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(71253),b=n(59395),y=function(c){var m;try{m=b("./"+c+".js")}catch(u){if(u.code==="MODULE_NOT_FOUND")return(0,p.routingError)("notFound",c);throw u}var l=m[c];return l||(0,p.routingError)("missingExport",c)},S=r.PDA=function(){function i(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.app,C=s.owner;if(!C)return(0,e.createComponentVNode)(2,o.Window,{width:350,height:105,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Error",children:"No user data found. Please swipe an ID card."})})});var g=y(d.template);return(0,e.createComponentVNode)(2,o.Window,{width:600,height:650,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,k)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,p:1,pb:0,title:(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:d.icon,mr:1}),d.name]}),children:(0,e.createComponentVNode)(2,g)})}),(0,e.createComponentVNode)(2,t.Stack.Item,{mt:7.5,children:(0,e.createComponentVNode)(2,h)})]})})})}return i}(),k=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.idInserted,C=s.idLink,g=s.stationTime,v=s.cartridge_name;return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{ml:.5,children:(0,e.createComponentVNode)(2,t.Button,{icon:"id-card",color:"transparent",onClick:function(){function f(){return u("Authenticate")}return f}(),content:d?C:"No ID Inserted"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"sd-card",color:"transparent",onClick:function(){function f(){return u("Eject")}return f}(),content:v?["Eject "+v]:"No Cartridge Inserted"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"right",bold:!0,mr:1,mt:.5,children:g})]})},h=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.app;return(0,e.createComponentVNode)(2,t.Box,{height:"45px",className:"PDA__footer",backgroundColor:"#1b1b1b",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[!!d.has_back&&(0,e.createComponentVNode)(2,t.Stack.Item,{basis:"33%",mr:-.5,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,className:"PDA__footer__button",color:"transparent",iconColor:d.has_back?"white":"disabled",icon:"arrow-alt-circle-left-o",onClick:function(){function C(){return u("Back")}return C}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{basis:d.has_back?"33%":"100%",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,className:"PDA__footer__button",color:"transparent",iconColor:d.is_home?"disabled":"white",icon:"home",onClick:function(){function C(){u("Home")}return C}()})})]})})}},68654:function(T,r,n){"use strict";r.__esModule=!0,r.Pacman=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(49968),b=r.Pacman=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.active,l=c.anchored,u=c.broken,s=c.emagged,d=c.fuel_type,C=c.fuel_usage,g=c.fuel_stored,v=c.fuel_cap,f=c.is_ai,N=c.tmp_current,V=c.tmp_max,B=c.tmp_overheat,I=c.output_max,L=c.power_gen,w=c.output_set,A=c.has_fuel,x=g/v,E=N/V,P=w*L,D=Math.round(g/C*2),M=Math.round(D/60),O=D>120?M+" minutes":D+" seconds";return(0,e.createComponentVNode)(2,o.Window,{width:500,height:225,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(u||!l)&&(0,e.createComponentVNode)(2,t.Section,{title:"Status",children:[!!u&&(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"The generator is malfunctioning!"}),!u&&!l&&(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"The generator needs to be anchored to the floor with a wrench."})]}),!u&&!!l&&(0,e.createVNode)(1,"div",null,[(0,e.createComponentVNode)(2,t.Section,{title:"Status",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:m?"power-off":"times",content:m?"On":"Off",tooltip:"Toggles the generator on/off. Requires fuel.",tooltipPosition:"left",disabled:!A,selected:m,onClick:function(){function R(){return i("toggle_power")}return R}()}),children:(0,e.createComponentVNode)(2,t.Flex,{direction:"row",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{width:"50%",className:"ml-1",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power setting",children:[(0,e.createComponentVNode)(2,t.NumberInput,{value:w,minValue:1,maxValue:I*(s?2.5:1),step:1,className:"mt-1",onDrag:function(){function R(F,W){return i("change_power",{change_power:W})}return R}()}),"(",(0,p.formatPower)(P),")"]})})}),(0,e.createComponentVNode)(2,t.Flex.Item,{width:"50%",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:E,ranges:{green:[-1/0,.33],orange:[.33,.66],red:[.66,1/0]},children:[N," \u2103"]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:[B>50&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"CRITICAL OVERHEAT!"}),B>20&&B<=50&&(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"WARNING: Overheating!"}),B>1&&B<=20&&(0,e.createComponentVNode)(2,t.Box,{color:"orange",children:"Temperature High"}),B===0&&(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Optimal"})]})]})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Fuel",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:"Eject Fuel",tooltip:"Ejects fuel. Generator needs to be offline.",tooltipPosition:"left",disabled:m||f||!A,onClick:function(){function R(){return i("eject_fuel")}return R}()}),children:(0,e.createComponentVNode)(2,t.Grid,{children:[(0,e.createComponentVNode)(2,t.Grid.Column,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Type",children:d}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fuel level",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:x,ranges:{red:[-1/0,.33],orange:[.33,.66],green:[.66,1/0]},children:[Math.round(g/1e3)," dm\xB3"]})})]})}),(0,e.createComponentVNode)(2,t.Grid.Column,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fuel usage",children:[C/1e3," dm\xB3/s"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fuel depletion",children:[!!A&&(C?O:"N/A"),!A&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Out of fuel"})]})]})})]})})],4)]})})}return y}()},1701:function(T,r,n){"use strict";r.__esModule=!0,r.PanDEMIC=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.PanDEMIC=function(){function l(u,s){var d=(0,a.useBackend)(s),C=d.data,g=C.beakerLoaded,v=C.beakerContainsBlood,f=C.beakerContainsVirus,N=C.resistances,V=N===void 0?[]:N,B;return g?v?v&&!f&&(B=(0,e.createFragment)([(0,e.createTextVNode)("No disease detected in provided blood sample.")],4)):B=(0,e.createFragment)([(0,e.createTextVNode)("No blood sample found in the loaded container.")],4):B=(0,e.createFragment)([(0,e.createTextVNode)("No container loaded.")],4),(0,e.createComponentVNode)(2,o.Window,{width:575,height:510,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[B&&!f?(0,e.createComponentVNode)(2,t.Section,{title:"Container Information",buttons:(0,e.createComponentVNode)(2,b,{fill:!0,vertical:!0}),children:(0,e.createComponentVNode)(2,t.NoticeBox,{children:B})}):(0,e.createComponentVNode)(2,k),(V==null?void 0:V.length)>0&&(0,e.createComponentVNode)(2,m,{align:"bottom"})]})})})}return l}(),b=function(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.beakerLoaded;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:"Eject",disabled:!v,onClick:function(){function f(){return C("eject_beaker")}return f}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"trash-alt",confirmIcon:"eraser",content:"Destroy",confirmContent:"Destroy",disabled:!v,onClick:function(){function f(){return C("destroy_eject_beaker")}return f}()})],4)},y=function(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.beakerContainsVirus,f=u.strain,N=f.commonName,V=f.description,B=f.diseaseAgent,I=f.bloodDNA,L=f.bloodType,w=f.possibleTreatments,A=f.transmissionRoute,x=f.isAdvanced,E=(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood DNA",children:I?(0,e.createVNode)(1,"span",null,I,0,{style:{"font-family":"'Courier New', monospace"}}):"Undetectable"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Blood Type",children:(0,e.createVNode)(1,"div",null,null,1,{dangerouslySetInnerHTML:{__html:L!=null?L:"Undetectable"}})})],4);if(!v)return(0,e.createComponentVNode)(2,t.LabeledList,{children:E});var P;return x&&(N!=null&&N!=="Unknown"?P=(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:"Print Release Forms",onClick:function(){function D(){return C("print_release_forms",{strain_index:u.strainIndex})}return D}(),style:{"margin-left":"auto"}}):P=(0,e.createComponentVNode)(2,t.Button,{icon:"pen",content:"Name Disease",onClick:function(){function D(){return C("name_strain",{strain_index:u.strainIndex})}return D}(),style:{"margin-left":"auto"}})),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Common Name",className:"common-name-label",children:(0,e.createComponentVNode)(2,t.Stack,{horizontal:!0,align:"center",children:[N!=null?N:"Unknown",P]})}),V&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:V}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Disease Agent",children:B}),E,(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Spread Vector",children:A!=null?A:"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Possible Cures",children:w!=null?w:"None"})]})},S=function(u,s){var d,C=(0,a.useBackend)(s),g=C.act,v=C.data,f=!!v.synthesisCooldown,N=(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:f?"spinner":"clone",iconSpin:f,content:"Clone",disabled:f,onClick:function(){function V(){return g("clone_strain",{strain_index:u.strainIndex})}return V}()}),u.sectionButtons],0);return(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:(d=u.sectionTitle)!=null?d:"Strain Information",buttons:N,children:(0,e.createComponentVNode)(2,y,{strain:u.strain,strainIndex:u.strainIndex})})})},k=function(u,s){var d,C=(0,a.useBackend)(s),g=C.act,v=C.data,f=v.selectedStrainIndex,N=v.strains,V=N[f-1];if(N.length===0)return(0,e.createComponentVNode)(2,t.Section,{title:"Container Information",buttons:(0,e.createComponentVNode)(2,b),children:(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No disease detected in provided blood sample."})});if(N.length===1){var B;return(0,e.createFragment)([(0,e.createComponentVNode)(2,S,{strain:N[0],strainIndex:1,sectionButtons:(0,e.createComponentVNode)(2,b)}),((B=N[0].symptoms)==null?void 0:B.length)>0&&(0,e.createComponentVNode)(2,i,{strain:N[0]})],0)}var I=(0,e.createComponentVNode)(2,b);return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Culture Information",fill:!0,buttons:I,children:(0,e.createComponentVNode)(2,t.Flex,{direction:"column",style:{height:"100%"},children:[(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Tabs,{children:N.map(function(L,w){var A;return(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"virus",selected:f-1===w,onClick:function(){function x(){return g("switch_strain",{strain_index:w+1})}return x}(),children:(A=L.commonName)!=null?A:"Unknown"},w)})})}),(0,e.createComponentVNode)(2,S,{strain:V,strainIndex:f}),((d=V.symptoms)==null?void 0:d.length)>0&&(0,e.createComponentVNode)(2,i,{className:"remove-section-bottom-padding",strain:V})]})})})},h=function(u){return u.reduce(function(s,d){return s+d},0)},i=function(u){var s=u.strain.symptoms;return(0,e.createComponentVNode)(2,t.Flex.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{title:"Infection Symptoms",fill:!0,className:u.className,children:(0,e.createComponentVNode)(2,t.Table,{className:"symptoms-table",children:[(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Stealth"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Resistance"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Stage Speed"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Transmissibility"})]}),s.map(function(d,C){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.stealth}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.resistance}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.stageSpeed}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d.transmissibility})]},C)}),(0,e.createComponentVNode)(2,t.Table.Row,{className:"table-spacer"}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{style:{"font-weight":"bold"},children:"Total"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h(s.map(function(d){return d.stealth}))}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h(s.map(function(d){return d.resistance}))}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h(s.map(function(d){return d.stageSpeed}))}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h(s.map(function(d){return d.transmissibility}))})]})]})})})},c=["flask","vial","eye-dropper"],m=function(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.synthesisCooldown,f=g.beakerContainsVirus,N=g.resistances;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Antibodies",fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{horizontal:!0,wrap:!0,children:N.map(function(V,B){return(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:c[B%c.length],disabled:!!v,onClick:function(){function I(){return C("clone_vaccine",{resistance_index:B+1})}return I}(),mr:"0.5em"}),V]},B)})})})})}},67921:function(T,r,n){"use strict";r.__esModule=!0,r.ParticleAccelerator=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(25328),p=n(79646),b=n(36352),y=n(98595),S=n(35840),k=n(38307),h=function(u){switch(u){case 1:return"north";case 2:return"south";case 4:return"east";case 8:return"west";case 5:return"northeast";case 6:return"southeast";case 9:return"northwest";case 10:return"southwest"}return""},i=r.ParticleAccelerator=function(){function l(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.assembled,f=g.power,N=g.strength,V=g.max_strength,B=g.icon,I=g.layout_1,L=g.layout_2,w=g.layout_3,A=g.orientation;return(0,e.createComponentVNode)(2,y.Window,{width:395,height:v?160:A==="north"||A==="south"?540:465,children:(0,e.createComponentVNode)(2,y.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Control Panel",buttons:(0,e.createComponentVNode)(2,t.Button,{dmIcon:"sync",content:"Connect",onClick:function(){function x(){return C("scan")}return x}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",mb:"5px",children:(0,e.createComponentVNode)(2,t.Box,{color:v?"good":"bad",children:v?"Operational":"Error: Verify Configuration"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:(0,e.createComponentVNode)(2,t.Button,{icon:f?"power-off":"times",content:f?"On":"Off",selected:f,disabled:!v,onClick:function(){function x(){return C("power")}return x}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Strength",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"backward",disabled:!v||N===0,onClick:function(){function x(){return C("remove_strength")}return x}(),mr:"4px"}),N,(0,e.createComponentVNode)(2,t.Button,{icon:"forward",disabled:!v||N===V,onClick:function(){function x(){return C("add_strength")}return x}(),ml:"4px"})]})]})}),v?"":(0,e.createComponentVNode)(2,t.Section,{title:A?"EM Acceleration Chamber Orientation: "+(0,o.capitalize)(A):"Place EM Acceleration Chamber Next To Console",children:A===0?"":A==="north"||A==="south"?(0,e.createComponentVNode)(2,m):(0,e.createComponentVNode)(2,c)})]})})}return l}(),c=function(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.assembled,f=g.power,N=g.strength,V=g.max_strength,B=g.icon,I=g.layout_1,L=g.layout_2,w=g.layout_3,A=g.orientation;return(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,b.TableRow,{width:"40px",children:(A==="east"?I:w).slice().map(function(x){return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})}),(0,e.createComponentVNode)(2,b.TableRow,{width:"40px",children:L.slice().map(function(x){return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})}),(0,e.createComponentVNode)(2,b.TableRow,{width:"40px",children:(A==="east"?w:I).slice().map(function(x){return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})})]})},m=function(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.assembled,f=g.power,N=g.strength,V=g.max_strength,B=g.icon,I=g.layout_1,L=g.layout_2,w=g.layout_3,A=g.orientation;return(0,e.createComponentVNode)(2,t.Grid,{children:[(0,e.createComponentVNode)(2,p.GridColumn,{width:"40px",children:(A==="north"?I:w).slice().map(function(x){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})}),(0,e.createComponentVNode)(2,p.GridColumn,{children:L.slice().map(function(x){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})}),(0,e.createComponentVNode)(2,p.GridColumn,{width:"40px",children:(A==="north"?w:I).slice().map(function(x){return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,tooltip:x.status,children:(0,e.createComponentVNode)(2,t.Tooltip,{content:(0,e.createVNode)(1,"span",null,[x.name,(0,e.createTextVNode)(" "),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)(" "),"Status: "+x.status,(0,e.createVNode)(1,"br"),"Direction: "+h(x.dir)],0,{style:{wordWrap:"break-word"}}),children:(0,e.createComponentVNode)(2,t.ImageButton,{dmIcon:B,dmIconState:x.icon_state,dmDirection:x.dir,style:{"border-style":"solid","border-width":"2px","border-color":x.status==="good"?"green":x.status==="Incomplete"?"orange":"red",padding:"2px"}})})},x.name)})})]})}},71432:function(T,r,n){"use strict";r.__esModule=!0,r.PdaPainter=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.PdaPainter=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.has_pda;return(0,e.createComponentVNode)(2,o.Window,{width:510,height:505,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:l?(0,e.createComponentVNode)(2,y):(0,e.createComponentVNode)(2,b)})})}return k}(),b=function(h,i){var c=(0,a.useBackend)(i),m=c.act;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"silver",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"download",size:5,mb:"10px"}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{width:"160px",textAlign:"center",content:"Insert PDA",onClick:function(){function l(){return m("insert_pda")}return l}()})]})})})},y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.pda_colors;return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,horizontal:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,S)}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,t.Table,{className:"PdaPainter__list",children:Object.keys(u).map(function(s){return(0,e.createComponentVNode)(2,t.Table.Row,{onClick:function(){function d(){return m("choose_pda",{selectedPda:s})}return d}(),children:[(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,children:(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/png;base64,"+u[s][0],style:{"vertical-align":"middle",width:"32px",margin:"0px","margin-left":"0px","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:s})]},s)})})})})]})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.current_appearance,s=l.preview_appearance;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Current PDA",children:[(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+u,style:{"vertical-align":"middle",width:"160px",margin:"0px","margin-left":"0px","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"eject",content:"Eject",color:"green",onClick:function(){function d(){return m("eject_pda")}return d}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",icon:"paint-roller",content:"Paint PDA",onClick:function(){function d(){return m("paint_pda")}return d}()})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Preview",children:(0,e.createVNode)(1,"img",null,null,1,{src:"data:image/jpeg;base64,"+s,style:{"vertical-align":"middle",width:"160px",margin:"0px","margin-left":"0px","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}})})]})}},33388:function(T,r,n){"use strict";r.__esModule=!0,r.PersonalCrafting=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.PersonalCrafting=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.busy,u=m.category,s=m.display_craftable_only,d=m.display_compact,C=m.prev_cat,g=m.next_cat,v=m.subcategory,f=m.prev_subcat,N=m.next_subcat;return(0,e.createComponentVNode)(2,o.Window,{width:700,height:800,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[!!l&&(0,e.createComponentVNode)(2,t.Dimmer,{fontSize:"32px",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"cog",spin:1})," Crafting..."]}),(0,e.createComponentVNode)(2,t.Section,{title:u,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"Show Craftable Only",icon:s?"check-square-o":"square-o",selected:s,onClick:function(){function V(){return c("toggle_recipes")}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Compact Mode",icon:d?"check-square-o":"square-o",selected:d,onClick:function(){function V(){return c("toggle_compact")}return V}()})],4),children:[(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{content:C,icon:"arrow-left",onClick:function(){function V(){return c("backwardCat")}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:g,icon:"arrow-right",onClick:function(){function V(){return c("forwardCat")}return V}()})]}),v&&(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Button,{content:f,icon:"arrow-left",onClick:function(){function V(){return c("backwardSubCat")}return V}()}),(0,e.createComponentVNode)(2,t.Button,{content:N,icon:"arrow-right",onClick:function(){function V(){return c("forwardSubCat")}return V}()})]}),d?(0,e.createComponentVNode)(2,b):(0,e.createComponentVNode)(2,y)]})]})})}return S}(),b=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.display_craftable_only,u=m.can_craft,s=m.cant_craft;return(0,e.createComponentVNode)(2,t.Box,{mt:1,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[u.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.name,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"hammer",content:"Craft",onClick:function(){function C(){return c("make",{make:d.ref})}return C}()}),d.catalyst_text&&(0,e.createComponentVNode)(2,t.Button,{tooltip:d.catalyst_text,content:"Catalysts",color:"transparent"}),(0,e.createComponentVNode)(2,t.Button,{tooltip:d.req_text,content:"Requirements",color:"transparent"}),d.tool_text&&(0,e.createComponentVNode)(2,t.Button,{tooltip:d.tool_text,content:"Tools",color:"transparent"})]},d.name)}),!l&&s.map(function(d){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:d.name,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"hammer",content:"Craft",disabled:!0}),d.catalyst_text&&(0,e.createComponentVNode)(2,t.Button,{tooltip:d.catalyst_text,content:"Catalysts",color:"transparent"}),(0,e.createComponentVNode)(2,t.Button,{tooltip:d.req_text,content:"Requirements",color:"transparent"}),d.tool_text&&(0,e.createComponentVNode)(2,t.Button,{tooltip:d.tool_text,content:"Tools",color:"transparent"})]},d.name)})]})})},y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.display_craftable_only,u=m.can_craft,s=m.cant_craft;return(0,e.createComponentVNode)(2,t.Box,{mt:1,children:[u.map(function(d){return(0,e.createComponentVNode)(2,t.Section,{title:d.name,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"hammer",content:"Craft",onClick:function(){function C(){return c("make",{make:d.ref})}return C}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[d.catalyst_text&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Catalysts",children:d.catalyst_text}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Requirements",children:d.req_text}),d.tool_text&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tools",children:d.tool_text})]})},d.name)}),!l&&s.map(function(d){return(0,e.createComponentVNode)(2,t.Section,{title:d.name,buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"hammer",content:"Craft",disabled:!0}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[d.catalyst_text&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Catalysts",children:d.catalyst_text}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Requirements",children:d.req_text}),d.tool_text&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tools",children:d.tool_text})]})},d.name)})]})}},56150:function(T,r,n){"use strict";r.__esModule=!0,r.Photocopier=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Photocopier=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:440,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Photocopier",color:"silver",children:[(0,e.createComponentVNode)(2,t.Stack,{mb:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:12,children:"Copies:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"2em",bold:!0,children:m.copynumber}),(0,e.createComponentVNode)(2,t.Stack.Item,{float:"right",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"minus",textAlign:"center",content:"",onClick:function(){function l(){return c("minus")}return l}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"plus",textAlign:"center",content:"",onClick:function(){function l(){return c("add")}return l}()})]})]}),(0,e.createComponentVNode)(2,t.Stack,{mb:2,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:12,children:"Toner:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,children:m.toner})]}),(0,e.createComponentVNode)(2,t.Stack,{mb:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:12,children:"Inserted Document:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",disabled:!m.copyitem&&!m.mob,content:m.copyitem?m.copyitem:m.mob?m.mob+"'s ass!":"document",onClick:function(){function l(){return c("removedocument")}return l}()})})]}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:12,children:"Inserted Folder:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",disabled:!m.folder,content:m.folder?m.folder:"folder",onClick:function(){function l(){return c("removefolder")}return l}()})})]})]}),(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,b)}),(0,e.createComponentVNode)(2,y)]})})})}return S}(),b=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.issilicon;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"copy",float:"center",textAlign:"center",content:"Copy",onClick:function(){function u(){return c("copy")}return u}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"file-import",float:"center",textAlign:"center",content:"Scan",onClick:function(){function u(){return c("scandocument")}return u}()}),!!l&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"file",color:"green",float:"center",textAlign:"center",content:"Print Text",onClick:function(){function u(){return c("ai_text")}return u}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"image",color:"green",float:"center",textAlign:"center",content:"Print Image",onClick:function(){function u(){return c("ai_pic")}return u}()})],4)],0)},y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data;return(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Scanned Files",children:m.files.map(function(l){return(0,e.createComponentVNode)(2,t.Section,{title:l.name,buttons:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:"Print",disabled:m.toner<=0,onClick:function(){function u(){return c("filecopy",{uid:l.uid})}return u}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"trash-alt",content:"Delete",color:"bad",onClick:function(){function u(){return c("deletefile",{uid:l.uid})}return u}()})]})},l.name)})})}},84676:function(T,r,n){"use strict";r.__esModule=!0,r.PoolController=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=["tempKey"];function b(h,i){if(h==null)return{};var c={};for(var m in h)if({}.hasOwnProperty.call(h,m)){if(i.includes(m))continue;c[m]=h[m]}return c}var y={scalding:{label:"Scalding",color:"#FF0000",icon:"fa fa-arrow-circle-up",requireEmag:!0},warm:{label:"Warm",color:"#990000",icon:"fa fa-arrow-circle-up"},normal:{label:"Normal",color:null,icon:"fa fa-arrow-circle-right"},cool:{label:"Cool",color:"#009999",icon:"fa fa-arrow-circle-down"},frigid:{label:"Frigid",color:"#00CCCC",icon:"fa fa-arrow-circle-down",requireEmag:!0}},S=function(i,c){var m=i.tempKey,l=b(i,p),u=y[m];if(!u)return null;var s=(0,a.useBackend)(c),d=s.data,C=s.act,g=d.currentTemp,v=u.label,f=u.icon,N=m===g,V=function(){C("setTemp",{temp:m})};return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Button,Object.assign({color:"transparent",selected:N,onClick:V},l,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:f}),v]})))},k=r.PoolController=function(){function h(i,c){for(var m=(0,a.useBackend)(c),l=m.data,u=l.emagged,s=l.currentTemp,d=y[s]||y.normal,C=d.label,g=d.color,v=[],f=0,N=Object.entries(y);f50?"battery-half":"battery-quarter")||g==="C"&&"bolt"||g==="F"&&"battery-full"||g==="M"&&"slash",color:g==="N"&&(v>50?"yellow":"red")||g==="C"&&"yellow"||g==="F"&&"green"||g==="M"&&"orange"}),(0,e.createComponentVNode)(2,S.Box,{inline:!0,width:"36px",textAlign:"right",children:(0,o.toFixed)(v)+"%"})],4)};u.defaultHooks=p.pureComponentHooks;var s=function(C){var g,v,f=C.status;switch(f){case"AOn":g=!0,v=!0;break;case"AOff":g=!0,v=!1;break;case"On":g=!1,v=!0;break;case"Off":g=!1,v=!1;break}var N=(v?"On":"Off")+(" ["+(g?"auto":"manual")+"]");return(0,e.createComponentVNode)(2,S.ColorBox,{color:v?"good":"bad",content:g?void 0:"M",title:N})};s.defaultHooks=p.pureComponentHooks},50992:function(T,r,n){"use strict";r.__esModule=!0,r.PrisonerImplantManager=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(29319),p=n(3939),b=n(321),y=n(5485),S=n(98595),k=r.PrisonerImplantManager=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.loginState,d=u.prisonerInfo,C=u.chemicalInfo,g=u.trackingInfo,v;if(!s.logged_in)return(0,e.createComponentVNode)(2,S.Window,{theme:"security",width:500,height:850,children:(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,y.LoginScreen)})});var f=[1,5,10];return(0,e.createComponentVNode)(2,S.Window,{theme:"security",width:500,height:850,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.LoginInfo),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Prisoner Points Manager System",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Prisoner",children:(0,e.createComponentVNode)(2,t.Button,{icon:d.name?"eject":"id-card",selected:d.name,content:d.name?d.name:"-----",tooltip:d.name?"Eject ID":"Insert ID",onClick:function(){function N(){return l("id_card")}return N}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Points",children:[d.points!==null?d.points:"-/-",(0,e.createComponentVNode)(2,t.Button,{ml:2,icon:"minus-square",disabled:d.points===null,content:"Reset",onClick:function(){function N(){return l("reset_points")}return N}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Point Goal",children:[d.goal!==null?d.goal:"-/-",(0,e.createComponentVNode)(2,t.Button,{ml:2,icon:"pen",disabled:d.goal===null,content:"Edit",onClick:function(){function N(){return(0,p.modalOpen)(c,"set_points")}return N}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{children:(0,e.createVNode)(1,"box",null,[(0,e.createTextVNode)("1 minute of prison time should roughly equate to 150 points."),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Sentences should not exceed 5000 points."),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Permanent prisoners should not be given a point goal."),(0,e.createVNode)(1,"br"),(0,e.createVNode)(1,"br"),(0,e.createTextVNode)("Prisoners who meet their point goal will be able to automatically access their locker and return to the station using the shuttle.")],4,{hidden:d.goal===null})})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Tracking Implants",children:g.map(function(N){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{p:1,backgroundColor:"rgba(255, 255, 255, 0.05)",children:[(0,e.createComponentVNode)(2,t.Box,{bold:!0,children:["Subject: ",N.subject]}),(0,e.createComponentVNode)(2,t.Box,{children:[" ",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Location",children:N.location}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Health",children:N.health}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Prisoner",children:(0,e.createComponentVNode)(2,t.Button,{icon:"exclamation-triangle",content:"Warn",tooltip:"Broadcast a message to this poor sod",onClick:function(){function V(){return(0,p.modalOpen)(c,"warn",{uid:N.uid})}return V}()})})]})]},N.subject)]}),(0,e.createVNode)(1,"br")],4)})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Chemical Implants",children:C.map(function(N){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{p:1,backgroundColor:"rgba(255, 255, 255, 0.05)",children:[(0,e.createComponentVNode)(2,t.Box,{bold:!0,children:["Subject: ",N.name]}),(0,e.createComponentVNode)(2,t.Box,{children:[" ",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Remaining Reagents",children:N.volume})}),f.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{mt:2,disabled:N.volumec;return(0,e.createComponentVNode)(2,t.ImageButton,{fluid:!0,title:N.name,dmIcon:N.icon,dmIconState:N.icon_state,buttonsAlt:(0,e.createComponentVNode)(2,t.Button,{bold:!0,translucent:!0,fontSize:1.5,tooltip:V&&"Not enough tickets",disabled:V,onClick:function(){function B(){return h("purchase",{purchase:N.itemID})}return B}(),children:[N.cost,(0,e.createComponentVNode)(2,t.Icon,{m:0,mt:.25,name:"ticket",color:V?"bad":"good",size:1.6})]}),children:N.desc},N.name)})})})})})})}return b}()},94813:function(T,r,n){"use strict";r.__esModule=!0,r.RCD=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(3939),b=n(49148),y=r.RCD=function(){function l(u,s){return(0,e.createComponentVNode)(2,o.Window,{width:480,height:670,children:[(0,e.createComponentVNode)(2,p.ComplexModal),(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,i),(0,e.createComponentVNode)(2,c)]})})]})}return l}(),S=function(u,s){var d=(0,a.useBackend)(s),C=d.data,g=C.matter,v=C.max_matter,f=v*.7,N=v*.25;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Matter Storage",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ranges:{good:[f,1/0],average:[N,f],bad:[-1/0,N]},value:g,maxValue:v,children:(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"center",children:g+" / "+v+" units"})})})})},k=function(){return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Construction Type",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,h,{mode_type:"Floors and Walls"}),(0,e.createComponentVNode)(2,h,{mode_type:"Airlocks"}),(0,e.createComponentVNode)(2,h,{mode_type:"Windows"}),(0,e.createComponentVNode)(2,h,{mode_type:"Deconstruction"})]})})})},h=function(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=u.mode_type,f=g.mode;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,color:"transparent",content:v,selected:f===v?1:0,onClick:function(){function N(){return C("mode",{mode:v})}return N}()})})},i=function(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.door_name,f=g.electrochromic,N=g.airlock_glass;return(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Airlock Settings",children:(0,e.createComponentVNode)(2,t.Stack,{textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,color:"transparent",icon:"pen-alt",content:(0,e.createFragment)([(0,e.createTextVNode)("Rename: "),(0,e.createVNode)(1,"b",null,v,0)],0),onClick:function(){function V(){return(0,p.modalOpen)(s,"renameAirlock")}return V}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:N===1&&(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:f?"toggle-on":"toggle-off",content:"Electrochromic",selected:f,onClick:function(){function V(){return C("electrochromic")}return V}()})})]})})})},c=function(u,s){var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.tab,f=g.locked,N=g.one_access,V=g.selected_accesses,B=g.regions;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Tabs,{fluid:!0,children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"cog",selected:v===1,onClick:function(){function I(){return C("set_tab",{tab:1})}return I}(),children:"Airlock Types"}),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:v===2,icon:"list",onClick:function(){function I(){return C("set_tab",{tab:2})}return I}(),children:"Airlock Access"})]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:v===1?(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Types",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,m,{check_number:0})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,m,{check_number:1})})]})}):v===2&&f?(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Access",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"lock-open",content:"Unlock",onClick:function(){function I(){return C("set_lock",{new_lock:"unlock"})}return I}()}),children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",align:"center",color:"label",children:[(0,e.createComponentVNode)(2,t.Icon,{name:"lock",size:"5",mb:3}),(0,e.createVNode)(1,"br"),"Airlock access selection is currently locked."]})})}):(0,e.createComponentVNode)(2,b.AccessList,{sectionButtons:(0,e.createComponentVNode)(2,t.Button,{icon:"lock",content:"Lock",onClick:function(){function I(){return C("set_lock",{new_lock:"lock"})}return I}()}),usedByRcd:1,rcdButtons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:N,content:"One",onClick:function(){function I(){return C("set_one_access",{access:"one"})}return I}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:!N,width:4,content:"All",onClick:function(){function I(){return C("set_one_access",{access:"all"})}return I}()})],4),accesses:B,selectedList:V,accessMod:function(){function I(L){return C("set",{access:L})}return I}(),grantAll:function(){function I(){return C("grant_all")}return I}(),denyAll:function(){function I(){return C("clear_all")}return I}(),grantDep:function(){function I(L){return C("grant_region",{region:L})}return I}(),denyDep:function(){function I(L){return C("deny_region",{region:L})}return I}()})})],4)},m=function(u,s){for(var d=(0,a.useBackend)(s),C=d.act,g=d.data,v=g.door_types_ui_list,f=g.door_type,N=u.check_number,V=[],B=0;Bp?w=(0,e.createComponentVNode)(2,t.Box,{color:"red",bold:!0,mb:1,children:"There are new messages"}):w=(0,e.createComponentVNode)(2,t.Box,{color:"label",mb:1,children:"There are no new messages"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Main Menu",buttons:(0,e.createComponentVNode)(2,t.Button,{width:9,content:L?"Speaker Off":"Speaker On",selected:!L,icon:L?"volume-mute":"volume-up",onClick:function(){function A(){return N("toggleSilent")}return A}()}),children:[w,(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"View Messages",icon:B>p?"envelope-open-text":"envelope",onClick:function(){function A(){return N("setScreen",{setScreen:6})}return A}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{mt:1,children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Request Assistance",icon:"hand-paper",onClick:function(){function A(){return N("setScreen",{setScreen:1})}return A}()}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Request Supplies",icon:"box",onClick:function(){function A(){return N("setScreen",{setScreen:2})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Request Secondary Goal",icon:"clipboard-list",onClick:function(){function A(){return N("setScreen",{setScreen:11})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Relay Anonymous Information",icon:"comment",onClick:function(){function A(){return N("setScreen",{setScreen:3})}return A}()})]})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{mt:1,children:(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Print Shipping Label",icon:"tag",onClick:function(){function A(){return N("setScreen",{setScreen:9})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"View Shipping Logs",icon:"clipboard-list",onClick:function(){function A(){return N("setScreen",{setScreen:10})}return A}()})]})}),!!I&&(0,e.createComponentVNode)(2,t.Stack.Item,{mt:1,children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,lineHeight:3,content:"Send Station-Wide Announcement",icon:"bullhorn",onClick:function(){function A(){return N("setScreen",{setScreen:8})}return A}()})})]})})},i=function(g,v){var f=(0,a.useBackend)(v),N=f.act,V=f.data,B=V.department,I=[],L;switch(g.purpose){case"ASSISTANCE":I=V.assist_dept,L="Request assistance from another department";break;case"SUPPLIES":I=V.supply_dept,L="Request supplies from another department";break;case"INFO":I=V.info_dept,L="Relay information to another department";break}return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:L,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function w(){return N("setScreen",{setScreen:0})}return w}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:I.filter(function(w){return w!==B}).map(function(w){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:w,textAlign:"right",className:"candystripe",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Message",icon:"envelope",onClick:function(){function A(){return N("writeInput",{write:w,priority:y})}return A}()}),(0,e.createComponentVNode)(2,t.Button,{content:"High Priority",icon:"exclamation-circle",onClick:function(){function A(){return N("writeInput",{write:w,priority:S})}return A}()})]},w)})})})})},c=function(g,v){var f=(0,a.useBackend)(v),N=f.act,V=f.data,B;switch(g.type){case"SUCCESS":B="Message sent successfully";break;case"FAIL":B="Unable to contact messaging server";break}return(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:B,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function I(){return N("setScreen",{setScreen:0})}return I}()})})},m=function(g,v){var f=(0,a.useBackend)(v),N=f.act,V=f.data,B,I;switch(g.type){case"MESSAGES":B=V.message_log,I="Message Log";break;case"SHIPPING":B=V.shipping_log,I="Shipping label print log";break}return B.reverse(),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:I,buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function L(){return N("setScreen",{setScreen:0})}return L}()}),children:B.map(function(L){return(0,e.createComponentVNode)(2,t.Box,{textAlign:"left",children:[L.map(function(w,A){return(0,e.createVNode)(1,"div",null,w,0,null,A)}),(0,e.createVNode)(1,"hr")]},L)})})})},l=function(g,v){var f=(0,a.useBackend)(v),N=f.act,V=f.data,B=V.recipient,I=V.message,L=V.msgVerified,w=V.msgStamped;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Message Authentication",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function A(){return N("setScreen",{setScreen:0})}return A}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Recipient",children:B}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Message",children:I}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Validated by",color:"green",children:L}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Stamped by",color:"blue",children:w})]})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,textAlign:"center",content:"Send Message",icon:"envelope",onClick:function(){function A(){return N("department",{department:B})}return A}()})})})],4)},u=function(g,v){var f=(0,a.useBackend)(v),N=f.act,V=f.data,B=V.message,I=V.announceAuth;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Station-Wide Announcement",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function L(){return N("setScreen",{setScreen:0})}return L}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Edit Message",icon:"edit",onClick:function(){function L(){return N("writeAnnouncement")}return L}()})],4),children:B})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{children:[I?(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"green",children:"ID verified. Authentication accepted."}):(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"label",children:"Swipe your ID card to authenticate yourself"}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,mt:2,textAlign:"center",content:"Send Announcement",icon:"bullhorn",disabled:!(I&&B),onClick:function(){function L(){return N("sendAnnouncement")}return L}()})]})})],4)},s=function(g,v){var f=(0,a.useBackend)(v),N=f.act,V=f.data,B=V.shipDest,I=V.msgVerified,L=V.ship_dept;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{textAlign:"center",children:(0,e.createComponentVNode)(2,t.Section,{title:"Print Shipping Label",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function w(){return N("setScreen",{setScreen:0})}return w}()}),children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Destination",children:B}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Validated by",children:I})]}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,mt:1,textAlign:"center",content:"Print Label",icon:"print",disabled:!(B&&I),onClick:function(){function w(){return N("printLabel")}return w}()})]})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Destinations",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:L.map(function(w){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:w,textAlign:"right",className:"candystripe",children:(0,e.createComponentVNode)(2,t.Button,{content:B===w?"Selected":"Select",selected:B===w,onClick:function(){function A(){return N("shipSelect",{shipSelect:w})}return A}()})},w)})})})})],4)},d=function(g,v){var f=(0,a.useBackend)(v),N=f.act,V=f.data,B=V.secondaryGoalAuth,I=V.secondaryGoalEnabled;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Request Secondary Goal",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Back",icon:"arrow-left",onClick:function(){function L(){return N("setScreen",{setScreen:0})}return L}()})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{children:[I?B?(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"green",children:"ID verified. Authentication accepted."}):(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"label",children:"Swipe your ID card to authenticate yourself"}):(0,e.createComponentVNode)(2,t.Box,{textAlign:"center",color:"label",children:"Complete your current goal first!"}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,mt:2,textAlign:"center",content:"Request Secondary Goal",icon:"clipboard-list",disabled:!(B&&I),onClick:function(){function L(){return N("requestSecondaryGoal")}return L}()})]})})],4)}},9861:function(T,r,n){"use strict";r.__esModule=!0,r.RndBackupConsole=r.LinkMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.RndBackupConsole=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.network_name,l=c.has_disk,u=c.disk_name,s=c.linked,d=c.techs,C=c.last_timestamp;return(0,e.createComponentVNode)(2,o.Window,{width:900,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Device Info",children:[(0,e.createComponentVNode)(2,t.Box,{mb:2,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Network",children:s?(0,e.createComponentVNode)(2,t.Button,{content:m,icon:"unlink",selected:1,onClick:function(){function g(){return i("unlink")}return g}()}):"None"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Loaded Disk",children:l?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:u+" (Last backup: "+C+")",icon:"save",selected:1,onClick:function(){function g(){return i("eject_disk")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"Save all",onClick:function(){function g(){return i("saveall2disk")}return g}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-out-alt",content:"Load all",onClick:function(){function g(){return i("saveall2network")}return g}()})],4):"None"})]})}),!!s||(0,e.createComponentVNode)(2,b)]}),(0,e.createComponentVNode)(2,t.Box,{mt:2,children:(0,e.createComponentVNode)(2,t.Section,{title:"Tech Info",children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Tech Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network Level"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Disk Level"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Actions"})]}),Object.keys(d).map(function(g){return!(d[g].network_level>0||d[g].disk_level>0)||(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:d[g].name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d[g].network_level||"None"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:d[g].disk_level||"None"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"Load to network",disabled:!l||!s,onClick:function(){function v(){return i("savetech2network",{tech:g})}return v}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-out-alt",content:"Load to disk",disabled:!l||!s,onClick:function(){function v(){return i("savetech2disk",{tech:g})}return v}()})]})]},g)})]})})})]})})}return y}(),b=r.LinkMenu=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.controllers;return(0,e.createComponentVNode)(2,t.Section,{title:"Setup Linkage",children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Link"})]}),m.map(function(l){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:l.addr}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:l.net_id}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Link",icon:"link",onClick:function(){function u(){return i("linktonetworkcontroller",{target_controller:l.addr})}return u}()})})]},l.addr)})]})})}return y}()},37556:function(T,r,n){"use strict";r.__esModule=!0,r.DataDiskMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o="design",p="tech",b=function(c,m){var l=(0,a.useBackend)(m),u=l.data,s=l.act,d=u.disk_data;return d?(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:d.name}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Level",children:d.level}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:d.desc})]}),(0,e.createComponentVNode)(2,t.Box,{mt:"10px",children:(0,e.createComponentVNode)(2,t.Button,{content:"Upload to Database",icon:"arrow-up",onClick:function(){function C(){return s("updt_tech")}return C}()})})]}):null},y=function(c,m){var l=(0,a.useBackend)(m),u=l.data,s=l.act,d=u.disk_data;if(!d)return null;var C=d.name,g=d.lathe_types,v=d.materials,f=g.join(", ");return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name",children:C}),f?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Lathe Types",children:f}):null,(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Required Materials"})]}),v.map(function(N){return(0,e.createComponentVNode)(2,t.Box,{children:["- ",(0,e.createVNode)(1,"span",null,N.name,0,{style:{"text-transform":"capitalize"}})," x ",N.amount]},N.name)}),(0,e.createComponentVNode)(2,t.Box,{mt:"10px",children:(0,e.createComponentVNode)(2,t.Button,{content:"Upload to Database",icon:"arrow-up",onClick:function(){function N(){return s("updt_design")}return N}()})})]})},S=function(c,m){var l=(0,a.useBackend)(m),u=l.act,s=l.data,d=s.disk_data;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.Section,Object.assign({buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button.Confirm,{content:"Erase",icon:"eraser",disabled:!d,onClick:function(){function C(){return u("erase_disk")}return C}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Eject",icon:"eject",onClick:function(){function C(){u("eject_disk")}return C}()})],4)},c)))},k=function(c,m){var l=(0,a.useBackend)(m),u=l.data,s=l.act,d=u.disk_type,C=u.to_copy,g=c.title;return(0,e.createComponentVNode)(2,S,{title:g,children:(0,e.createComponentVNode)(2,t.Box,{overflowY:"auto",overflowX:"hidden",maxHeight:"450px",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:C.sort(function(v,f){return v.name.localeCompare(f.name)}).map(function(v){var f=v.name,N=v.id;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{noColon:!0,label:f,children:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-down",content:"Copy to Disk",onClick:function(){function V(){d===p?s("copy_tech",{id:N}):s("copy_design",{id:N})}return V}()})},N)})})})})},h=r.DataDiskMenu=function(){function i(c,m){var l=(0,a.useBackend)(m),u=l.data,s=u.disk_type,d=u.disk_data;if(!s)return(0,e.createComponentVNode)(2,t.Section,{title:"Data Disk",children:"No disk loaded."});switch(s){case o:return d?(0,e.createComponentVNode)(2,S,{title:"Design Disk",children:(0,e.createComponentVNode)(2,y)}):(0,e.createComponentVNode)(2,k,{title:"Design Disk"});case p:return d?(0,e.createComponentVNode)(2,S,{title:"Technology Disk",children:(0,e.createComponentVNode)(2,b)}):(0,e.createComponentVNode)(2,k,{title:"Technology Disk"});default:return(0,e.createFragment)([(0,e.createTextVNode)("UNRECOGNIZED DISK TYPE")],4)}}return i}()},58147:function(T,r,n){"use strict";r.__esModule=!0,r.DeconstructionMenu=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=r.DeconstructionMenu=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.data,c=h.act,m=i.tech_levels,l=i.loaded_item,u=i.linked_destroy;return u?l?(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Section,{title:"Object Analysis",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{content:"Deconstruct",icon:"microscope",onClick:function(){function s(){c("deconstruct")}return s}()}),(0,e.createComponentVNode)(2,o.Button,{content:"Eject",icon:"eject",onClick:function(){function s(){c("eject_item")}return s}()})],4),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Name",children:l.name})})}),(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.Table,{id:"research-levels",children:[(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Research Field"}),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Current Level"}),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Object Level"}),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"New Level"})]}),m.map(function(s){return(0,e.createComponentVNode)(2,b,{techLevel:s},s.id)})]})})],4):(0,e.createComponentVNode)(2,o.Section,{title:"Deconstruction Menu",children:"No item loaded. Standing by..."}):(0,e.createComponentVNode)(2,o.Section,{title:"Deconstruction Menu",children:"NO DESTRUCTIVE ANALYZER LINKED TO CONSOLE"})}return y}(),b=function(S,k){var h=S.techLevel,i=h.name,c=h.desc,m=h.level,l=h.object_level,u=h.ui_icon,s=l!=null,d=s&&l>=m?Math.max(l,m+1):m;return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{icon:"circle-info",tooltip:c})}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:u})," ",i]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:m}),s?(0,e.createComponentVNode)(2,o.Table.Cell,{children:l}):(0,e.createComponentVNode)(2,o.Table.Cell,{className:"research-level-no-effect",children:"-"}),(0,e.createComponentVNode)(2,o.Table.Cell,{className:(0,a.classes)([d!==m&&"upgraded-level"]),children:d})]})}},16830:function(T,r,n){"use strict";r.__esModule=!0,r.LatheCategory=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(52662),p=r.LatheCategory=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.data,i=k.act,c=h.category,m=h.matching_designs,l=h.menu,u=l===4,s=u?"build":"imprint";return(0,e.createComponentVNode)(2,t.Section,{title:c,children:[(0,e.createComponentVNode)(2,o.LatheMaterials),(0,e.createComponentVNode)(2,t.Table,{className:"RndConsole__LatheCategory__MatchingDesigns",children:m.map(function(d){var C=d.id,g=d.name,v=d.can_build,f=d.materials;return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:g,disabled:v<1,onClick:function(){function N(){return i(s,{id:C,amount:1})}return N}()})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:v>=5?(0,e.createComponentVNode)(2,t.Button,{content:"x5",onClick:function(){function N(){return i(s,{id:C,amount:5})}return N}()}):null}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:v>=10?(0,e.createComponentVNode)(2,t.Button,{content:"x10",onClick:function(){function N(){return i(s,{id:C,amount:10})}return N}()}):null}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.map(function(N){return(0,e.createFragment)([" | ",(0,e.createVNode)(1,"span",N.is_red?"color-red":null,[N.amount,(0,e.createTextVNode)(" "),N.name],0)],0)})})]},C)})})]})}return b}()},70497:function(T,r,n){"use strict";r.__esModule=!0,r.LatheChemicalStorage=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LatheChemicalStorage=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data,h=S.act,i=k.loaded_chemicals,c=k.menu===4;return(0,e.createComponentVNode)(2,t.Section,{title:"Chemical Storage",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Purge All",icon:"trash",onClick:function(){function m(){var l=c?"disposeallP":"disposeallI";h(l)}return m}()}),(0,e.createComponentVNode)(2,t.LabeledList,{children:i.map(function(m){var l=m.volume,u=m.name,s=m.id;return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"* "+l+" of "+u,children:(0,e.createComponentVNode)(2,t.Button,{content:"Purge",icon:"trash",onClick:function(){function d(){var C=c?"disposeP":"disposeI";h(C,{id:s})}return d}()})},s)})})]})}return p}()},70864:function(T,r,n){"use strict";r.__esModule=!0,r.LatheMainMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(52662),p=n(68198),b=r.LatheMainMenu=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.data,c=h.act,m=i.menu,l=i.categories,u=m===4?"Protolathe":"Circuit Imprinter";return(0,e.createComponentVNode)(2,t.Section,{title:u+" Menu",children:[(0,e.createComponentVNode)(2,o.LatheMaterials),(0,e.createComponentVNode)(2,p.LatheSearch),(0,e.createComponentVNode)(2,t.Divider),(0,e.createComponentVNode)(2,t.Flex,{wrap:"wrap",children:l.map(function(s){return(0,e.createComponentVNode)(2,t.Flex,{style:{"flex-basis":"50%","margin-bottom":"6px"},children:(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-right",content:s,onClick:function(){function d(){c("setCategory",{category:s})}return d}()})},s)})})]})}return y}()},42878:function(T,r,n){"use strict";r.__esModule=!0,r.LatheMaterialStorage=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LatheMaterialStorage=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data,h=S.act,i=k.loaded_materials;return(0,e.createComponentVNode)(2,t.Section,{className:"RndConsole__LatheMaterialStorage",title:"Material Storage",children:(0,e.createComponentVNode)(2,t.Table,{children:i.map(function(c){var m=c.id,l=c.amount,u=c.name,s=function(){function v(f){var N=k.menu===4?"lathe_ejectsheet":"imprinter_ejectsheet";h(N,{id:m,amount:f})}return v}(),d=Math.floor(l/2e3),C=l<1,g=d===1?"":"s";return(0,e.createComponentVNode)(2,t.Table.Row,{className:C?"color-grey":"color-yellow",children:[(0,e.createComponentVNode)(2,t.Table.Cell,{minWidth:"210px",children:["* ",l," of ",u]}),(0,e.createComponentVNode)(2,t.Table.Cell,{minWidth:"110px",children:["(",d," sheet",g,")"]}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:l>=2e3?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:"1x",icon:"eject",onClick:function(){function v(){return s(1)}return v}()}),(0,e.createComponentVNode)(2,t.Button,{content:"C",icon:"eject",onClick:function(){function v(){return s("custom")}return v}()}),l>=2e3*5?(0,e.createComponentVNode)(2,t.Button,{content:"5x",icon:"eject",onClick:function(){function v(){return s(5)}return v}()}):null,(0,e.createComponentVNode)(2,t.Button,{content:"All",icon:"eject",onClick:function(){function v(){return s(50)}return v}()})],0):null})]},m)})})})}return p}()},52662:function(T,r,n){"use strict";r.__esModule=!0,r.LatheMaterials=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LatheMaterials=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data,h=k.total_materials,i=k.max_materials,c=k.max_chemicals,m=k.total_chemicals;return(0,e.createComponentVNode)(2,t.Box,{className:"RndConsole__LatheMaterials",mb:"10px",children:(0,e.createComponentVNode)(2,t.Table,{width:"auto",children:[(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Material Amount:"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:h}),i?(0,e.createComponentVNode)(2,t.Table.Cell,{children:" / "+i}):null]}),(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:"Chemical Amount:"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:m}),c?(0,e.createComponentVNode)(2,t.Table.Cell,{children:" / "+c}):null]})]})})}return p}()},9681:function(T,r,n){"use strict";r.__esModule=!0,r.LatheMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(12644),p=n(70864),b=n(16830),y=n(42878),S=n(70497),k=["menu"];function h(u,s){if(u==null)return{};var d={};for(var C in u)if({}.hasOwnProperty.call(u,C)){if(s.includes(C))continue;d[C]=u[C]}return d}var i=t.Tabs.Tab,c=function(s,d){var C=(0,a.useBackend)(d),g=C.act,v=C.data,f=v.menu===o.MENU.LATHE?["nav_protolathe",v.submenu_protolathe]:["nav_imprinter",v.submenu_imprinter],N=f[0],V=f[1],B=s.menu,I=h(s,k);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,i,Object.assign({selected:V===B,onClick:function(){function L(){return g(N,{menu:B})}return L}()},I)))},m=function(s){switch(s){case o.PRINTER_MENU.MAIN:return(0,e.createComponentVNode)(2,p.LatheMainMenu);case o.PRINTER_MENU.SEARCH:return(0,e.createComponentVNode)(2,b.LatheCategory);case o.PRINTER_MENU.MATERIALS:return(0,e.createComponentVNode)(2,y.LatheMaterialStorage);case o.PRINTER_MENU.CHEMICALS:return(0,e.createComponentVNode)(2,S.LatheChemicalStorage)}},l=r.LatheMenu=function(){function u(s,d){var C=(0,a.useBackend)(d),g=C.data,v=g.menu,f=g.linked_lathe,N=g.linked_imprinter;return v===o.MENU.LATHE&&!f?(0,e.createComponentVNode)(2,t.Box,{children:"NO PROTOLATHE LINKED TO CONSOLE"}):v===o.MENU.IMPRINTER&&!N?(0,e.createComponentVNode)(2,t.Box,{children:"NO CIRCUIT IMPRITER LINKED TO CONSOLE"}):(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,c,{menu:o.PRINTER_MENU.MAIN,icon:"bars",children:"Main Menu"}),(0,e.createComponentVNode)(2,c,{menu:o.PRINTER_MENU.MATERIALS,icon:"layer-group",children:"Materials"}),(0,e.createComponentVNode)(2,c,{menu:o.PRINTER_MENU.CHEMICALS,icon:"flask-vial",children:"Chemicals"})]}),m(g.menu===o.MENU.LATHE?g.submenu_protolathe:g.submenu_imprinter)]})}return u}()},68198:function(T,r,n){"use strict";r.__esModule=!0,r.LatheSearch=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LatheSearch=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act;return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Input,{placeholder:"Search...",onEnter:function(){function h(i,c){return k("search",{to_search:c})}return h}()})})}return p}()},81421:function(T,r,n){"use strict";r.__esModule=!0,r.LinkMenu=void 0;var e=n(89005),a=n(72253),t=n(98595),o=n(36036),p=r.LinkMenu=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.controllers;return(0,e.createComponentVNode)(2,t.Window,{width:800,height:550,children:(0,e.createComponentVNode)(2,t.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{title:"Setup Linkage",children:(0,e.createComponentVNode)(2,o.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Link"})]}),c.map(function(m){return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:m.addr}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:m.net_id}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{content:"Link",icon:"link",onClick:function(){function l(){return h("linktonetworkcontroller",{target_controller:m.addr})}return l}()})})]},m.addr)})]})})})})}return b}()},6256:function(T,r,n){"use strict";r.__esModule=!0,r.SettingsMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.SettingsMenu=function(){function y(S,k){return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,p),(0,e.createComponentVNode)(2,b)]})}return y}(),p=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.sync,l=c.admin;return(0,e.createComponentVNode)(2,t.Section,{title:"Settings",children:(0,e.createComponentVNode)(2,t.Flex,{direction:"column",align:"flex-start",children:(0,e.createComponentVNode)(2,t.Button,{color:"red",icon:"unlink",content:"Disconnect from Research Network",onClick:function(){function u(){i("unlink")}return u}()})})})},b=function(S,k){var h=(0,a.useBackend)(k),i=h.data,c=h.act,m=i.linked_destroy,l=i.linked_lathe,u=i.linked_imprinter;return(0,e.createComponentVNode)(2,t.Section,{title:"Linked Devices",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"link",content:"Re-sync with Nearby Devices",onClick:function(){function s(){return c("find_device")}return s}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Destructive Analyzer",children:(0,e.createComponentVNode)(2,t.Button,{icon:"unlink",disabled:!m,content:m?"Unlink":"Undetected",onClick:function(){function s(){return c("disconnect",{item:"destroy"})}return s}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Protolathe",children:(0,e.createComponentVNode)(2,t.Button,{icon:"unlink",disabled:!l,content:l?"Unlink":"Undetected",onClick:function(){function s(){c("disconnect",{item:"lathe"})}return s}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Circuit Imprinter",children:(0,e.createComponentVNode)(2,t.Button,{icon:"unlink",disabled:!u,content:u?"Unlink":"Undetected",onClick:function(){function s(){return c("disconnect",{item:"imprinter"})}return s}()})})]})})}},12644:function(T,r,n){"use strict";r.__esModule=!0,r.RndConsole=r.PRINTER_MENU=r.MENU=void 0;var e=n(89005),a=n(72253),t=n(98595),o=n(36036),p=n(35840),b=n(37556),y=n(9681),S=n(81421),k=n(6256),h=n(58147),i=["menu"];function c(f,N){if(f==null)return{};var V={};for(var B in f)if({}.hasOwnProperty.call(f,B)){if(N.includes(B))continue;V[B]=f[B]}return V}var m=o.Tabs.Tab,l=r.MENU={MAIN:0,DISK:2,DESTROY:3,LATHE:4,IMPRINTER:5,SETTINGS:6},u=r.PRINTER_MENU={MAIN:0,SEARCH:1,MATERIALS:2,CHEMICALS:3},s=function(N){switch(N){case l.MAIN:return(0,e.createComponentVNode)(2,v);case l.DISK:return(0,e.createComponentVNode)(2,b.DataDiskMenu);case l.DESTROY:return(0,e.createComponentVNode)(2,h.DeconstructionMenu);case l.LATHE:case l.IMPRINTER:return(0,e.createComponentVNode)(2,y.LatheMenu);case l.SETTINGS:return(0,e.createComponentVNode)(2,k.SettingsMenu);default:return"UNKNOWN MENU"}},d=function(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data,w=L.menu,A=N.menu,x=c(N,i);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,m,Object.assign({selected:w===A,onClick:function(){function E(){return I("nav",{menu:A})}return E}()},x)))},C=r.RndConsole=function(){function f(N,V){var B=(0,a.useBackend)(V),I=B.act,L=B.data;if(!L.linked)return(0,e.createComponentVNode)(2,S.LinkMenu);var w=L.menu,A=L.linked_destroy,x=L.linked_lathe,E=L.linked_imprinter,P=L.wait_message;return(0,e.createComponentVNode)(2,t.Window,{width:800,height:550,children:(0,e.createComponentVNode)(2,t.Window.Content,{children:(0,e.createComponentVNode)(2,o.Box,{className:"RndConsole",children:[(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,d,{icon:"flask",menu:l.MAIN,children:"Research"}),!!A&&(0,e.createComponentVNode)(2,d,{icon:"microscope",menu:l.DESTROY,children:"Analyze"}),!!x&&(0,e.createComponentVNode)(2,d,{icon:"print",menu:l.LATHE,children:"Protolathe"}),!!E&&(0,e.createComponentVNode)(2,d,{icon:"memory",menu:l.IMPRINTER,children:"Imprinter"}),(0,e.createComponentVNode)(2,d,{icon:"floppy-disk",menu:l.DISK,children:"Disk"}),(0,e.createComponentVNode)(2,d,{icon:"cog",menu:l.SETTINGS,children:"Settings"})]}),s(w),(0,e.createComponentVNode)(2,g)]})})})}return f}(),g=function(N,V){var B=(0,a.useBackend)(V),I=B.data,L=I.wait_message;return L?(0,e.createComponentVNode)(2,o.Box,{className:"RndConsole__Overlay",children:(0,e.createComponentVNode)(2,o.Box,{className:"RndConsole__Overlay__Wrapper",children:(0,e.createComponentVNode)(2,o.NoticeBox,{color:"black",children:L})})}):null},v=function(N,V){var B=(0,a.useBackend)(V),I=B.data,L=I.tech_levels;return(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.Table,{id:"research-levels",children:[(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Research Field"}),(0,e.createComponentVNode)(2,o.Table.Cell,{header:!0,children:"Level"})]}),L.map(function(w){var A=w.id,x=w.name,E=w.desc,P=w.level,D=w.ui_icon;return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{icon:"circle-info",tooltip:E})}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:D})," ",x]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:P})]},A)})]})})}},29205:function(T,r,n){"use strict";r.__esModule=!0,r.RndNetController=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=r.RndNetController=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=l.ion,s=(0,t.useLocalState)(i,"mainTabIndex",0),d=s[0],C=s[1],g=function(){function v(f){switch(f){case 0:return(0,e.createComponentVNode)(2,y);case 1:return(0,e.createComponentVNode)(2,S);default:return"SOMETHING WENT VERY WRONG PLEASE AHELP"}}return v}();return(0,e.createComponentVNode)(2,p.Window,{width:900,height:600,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"wrench",selected:d===0,onClick:function(){function v(){return C(0)}return v}(),children:"Network Management"},"ConfigPage"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"floppy-disk",selected:d===1,onClick:function(){function v(){return C(1)}return v}(),children:"Design Management"},"DesignPage")]}),g(d)]})})}return k}(),y=function(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=(0,t.useLocalState)(i,"filterType","ALL"),s=u[0],d=u[1],C=l.network_password,g=l.network_name,v=l.devices,f=[];f.push(s),s==="MSC"&&(f.push("BCK"),f.push("PGN"));var N=s==="ALL"?v:v.filter(function(V){return f.indexOf(V.dclass)>-1});return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Section,{title:"Network Configuration",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Network Name",children:(0,e.createComponentVNode)(2,o.Button,{content:g||"Unset",selected:g,icon:"edit",onClick:function(){function V(){return m("network_name")}return V}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Network Password",children:(0,e.createComponentVNode)(2,o.Button,{content:C||"Unset",selected:C,icon:"lock",onClick:function(){function V(){return m("network_password")}return V}()})})]})}),(0,e.createComponentVNode)(2,o.Section,{title:"Connected Devices",children:[(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="ALL",onClick:function(){function V(){return d("ALL")}return V}(),icon:"network-wired",children:"All Devices"},"AllDevices"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="SRV",onClick:function(){function V(){return d("SRV")}return V}(),icon:"server",children:"R&D Servers"},"RNDServers"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="RDC",onClick:function(){function V(){return d("RDC")}return V}(),icon:"desktop",children:"R&D Consoles"},"RDConsoles"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="MFB",onClick:function(){function V(){return d("MFB")}return V}(),icon:"industry",children:"Exosuit Fabricators"},"Mechfabs"),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:s==="MSC",onClick:function(){function V(){return d("MSC")}return V}(),icon:"microchip",children:"Miscellaneous Devices"},"Misc")]}),(0,e.createComponentVNode)(2,o.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Device Name"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Device ID"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Unlink"})]}),N.map(function(V){return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:V.name}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:V.id}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{content:"Unlink",icon:"unlink",color:"red",onClick:function(){function B(){return m("unlink_device",{dclass:V.dclass,uid:V.id})}return B}()})})]},V.id)})]})]})],4)},S=function(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=l.designs,s=(0,t.useLocalState)(i,"searchText",""),d=s[0],C=s[1];return(0,e.createComponentVNode)(2,o.Section,{title:"Design Management",children:[(0,e.createComponentVNode)(2,o.Input,{fluid:!0,placeholder:"Search for designs",mb:2,onInput:function(){function g(v,f){return C(f)}return g}()}),u.filter((0,a.createSearch)(d,function(g){return g.name})).map(function(g){return(0,e.createComponentVNode)(2,o.Button.Checkbox,{fluid:!0,content:g.name,checked:!g.blacklisted,onClick:function(){function v(){return m(g.blacklisted?"unblacklist_design":"blacklist_design",{d_uid:g.uid})}return v}()},g.name)})]})}},63315:function(T,r,n){"use strict";r.__esModule=!0,r.RndServer=void 0;var e=n(89005),a=n(72253),t=n(44879),o=n(36036),p=n(98595),b=r.RndServer=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.active,s=l.network_name;return(0,e.createComponentVNode)(2,p.Window,{width:600,height:500,resizable:!0,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,o.Section,{title:"Server Configuration",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Machine power",children:(0,e.createComponentVNode)(2,o.Button,{content:u?"On":"Off",selected:u,icon:"power-off",onClick:function(){function d(){return m("toggle_active")}return d}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Link status",children:s===null?(0,e.createComponentVNode)(2,o.Box,{color:"red",children:"Unlinked"}):(0,e.createComponentVNode)(2,o.Box,{color:"green",children:"Linked"})})]})}),s===null?(0,e.createComponentVNode)(2,S):(0,e.createComponentVNode)(2,y)]})})}return k}(),y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.network_name;return(0,e.createComponentVNode)(2,o.Section,{title:"Network Info",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Connected network ID",children:u}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Unlink",children:(0,e.createComponentVNode)(2,o.Button,{content:"Unlink",icon:"unlink",color:"red",onClick:function(){function s(){return m("unlink")}return s}()})})]})})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.controllers;return(0,e.createComponentVNode)(2,o.Section,{title:"Detected Cores",children:(0,e.createComponentVNode)(2,o.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,o.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:"Link"})]}),u.map(function(s){return(0,e.createComponentVNode)(2,o.Table.Row,{children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:s.netname}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{content:"Link",icon:"link",onClick:function(){function d(){return m("link",{addr:s.addr})}return d}()})})]},s.addr)})]})})}},26109:function(T,r,n){"use strict";r.__esModule=!0,r.RobotSelfDiagnosis=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(25328),b=function(k,h){var i=k/h;return i<=.2?"good":i<=.5?"average":"bad"},y=r.RobotSelfDiagnosis=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.data,m=c.component_data;return(0,e.createComponentVNode)(2,o.Window,{width:280,height:480,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:m.map(function(l,u){return(0,e.createComponentVNode)(2,t.Section,{title:(0,p.capitalize)(l.name),children:l.installed<=0?(0,e.createComponentVNode)(2,t.NoticeBox,{m:-.5,height:3.5,color:"red",style:{"font-style":"normal"},children:(0,e.createComponentVNode)(2,t.Flex,{height:"100%",children:(0,e.createComponentVNode)(2,t.Flex.Item,{grow:1,textAlign:"center",align:"center",color:"#e8e8e8",children:l.installed===-1?"Destroyed":"Missing"})})}):(0,e.createComponentVNode)(2,t.Flex,{children:[(0,e.createComponentVNode)(2,t.Flex.Item,{width:"72%",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Brute Damage",color:b(l.brute_damage,l.max_damage),children:l.brute_damage}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Burn Damage",color:b(l.electronic_damage,l.max_damage),children:l.electronic_damage})]})}),(0,e.createComponentVNode)(2,t.Flex.Item,{width:"50%",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Powered",color:l.powered?"good":"bad",children:l.powered?"Yes":"No"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Enabled",color:l.status?"good":"bad",children:l.status?"Yes":"No"})]})})]})},u)})})})}return S}()},97997:function(T,r,n){"use strict";r.__esModule=!0,r.RoboticsControlConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.RoboticsControlConsole=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.can_hack,l=c.safety,u=c.show_lock_all,s=c.cyborgs,d=s===void 0?[]:s;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:460,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[!!u&&(0,e.createComponentVNode)(2,t.Section,{title:"Emergency Lock Down",children:[(0,e.createComponentVNode)(2,t.Button,{icon:l?"lock":"unlock",content:l?"Disable Safety":"Enable Safety",selected:l,onClick:function(){function C(){return i("arm",{})}return C}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"lock",disabled:l,content:"Lock ALL Cyborgs",color:"bad",onClick:function(){function C(){return i("masslock",{})}return C}()})]}),(0,e.createComponentVNode)(2,b,{cyborgs:d,can_hack:m})]})})}return y}(),b=function(S,k){var h=S.cyborgs,i=S.can_hack,c=(0,a.useBackend)(k),m=c.act,l=c.data,u="Detonate";return l.detonate_cooldown>0&&(u+=" ("+l.detonate_cooldown+"s)"),h.length?h.map(function(s){return(0,e.createComponentVNode)(2,t.Section,{title:s.name,buttons:(0,e.createFragment)([!!s.hackable&&!s.emagged&&(0,e.createComponentVNode)(2,t.Button,{icon:"terminal",content:"Hack",color:"bad",onClick:function(){function d(){return m("hackbot",{uid:s.uid})}return d}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:s.locked_down?"unlock":"lock",color:s.locked_down?"good":"default",content:s.locked_down?"Release":"Lockdown",disabled:!l.auth,onClick:function(){function d(){return m("stopbot",{uid:s.uid})}return d}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"bomb",content:u,disabled:!l.auth||l.detonate_cooldown>0,color:"bad",onClick:function(){function d(){return m("killbot",{uid:s.uid})}return d}()})],0),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:(0,e.createComponentVNode)(2,t.Box,{color:s.status?"bad":s.locked_down?"average":"good",children:s.status?"Not Responding":s.locked_down?"Locked Down":"Nominal"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Location",children:(0,e.createComponentVNode)(2,t.Box,{children:s.locstring})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Integrity",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:s.health>50?"good":"bad",value:s.health/100})}),typeof s.charge=="number"&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cell Charge",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:s.charge>30?"good":"bad",value:s.charge/100})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cell Capacity",children:(0,e.createComponentVNode)(2,t.Box,{color:s.cell_capacity<3e4?"average":"good",children:s.cell_capacity})})],4)||(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cell",children:(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"No Power Cell"})}),!!s.is_hacked&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Safeties",children:(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"DISABLED"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Module",children:s.module}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Master AI",children:(0,e.createComponentVNode)(2,t.Box,{color:s.synchronization?"default":"average",children:s.synchronization||"None"})})]})},s.uid)}):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No cyborg units detected within access parameters."})}},54431:function(T,r,n){"use strict";r.__esModule=!0,r.Safe=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Safe=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.dial,s=l.open,d=l.locked,C=l.contents;return(0,e.createComponentVNode)(2,o.Window,{theme:"safe",width:600,height:800,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Box,{className:"Safe--engraving",children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Box,{className:"Safe--engraving--hinge",top:"25%"}),(0,e.createComponentVNode)(2,t.Box,{className:"Safe--engraving--hinge",top:"75%"})]}),(0,e.createComponentVNode)(2,t.Icon,{className:"Safe--engraving--arrow",name:"long-arrow-alt-down",size:"3"}),(0,e.createVNode)(1,"br"),s?(0,e.createComponentVNode)(2,y):(0,e.createComponentVNode)(2,t.Box,{as:"img",className:"Safe--dial",src:"safe_dial.png",style:{transform:"rotate(-"+3.6*u+"deg)","z-index":0}})]}),!s&&(0,e.createComponentVNode)(2,S)]})})}return k}(),b=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.dial,s=l.open,d=l.locked,C=function(v,f){return(0,e.createComponentVNode)(2,t.Button,{disabled:s||f&&!d,icon:"arrow-"+(f?"right":"left"),content:(f?"Right":"Left")+" "+v,iconRight:f,onClick:function(){function N(){return m(f?"turnleft":"turnright",{num:v})}return N}(),style:{"z-index":10}})};return(0,e.createComponentVNode)(2,t.Box,{className:"Safe--dialer",children:[(0,e.createComponentVNode)(2,t.Button,{disabled:d,icon:s?"lock":"lock-open",content:s?"Close":"Open",mb:"0.5rem",onClick:function(){function g(){return m("open")}return g}()}),(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Box,{position:"absolute",children:[C(50),C(10),C(1)]}),(0,e.createComponentVNode)(2,t.Box,{className:"Safe--dialer--right",position:"absolute",right:"5px",children:[C(1,!0),C(10,!0),C(50,!0)]}),(0,e.createComponentVNode)(2,t.Box,{className:"Safe--dialer--number",children:u})]})},y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.contents;return(0,e.createComponentVNode)(2,t.Box,{className:"Safe--contents",overflow:"auto",children:u.map(function(s,d){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{mb:"0.5rem",onClick:function(){function C(){return m("retrieve",{index:d+1})}return C}(),children:[(0,e.createComponentVNode)(2,t.Box,{as:"img",src:s.sprite+".png",verticalAlign:"middle",ml:"-6px",mr:"0.5rem"}),s.name]}),(0,e.createVNode)(1,"br")],4,s)})})},S=function(h,i){return(0,e.createComponentVNode)(2,t.Section,{className:"Safe--help",title:"Safe opening instructions (because you all keep forgetting)",children:[(0,e.createComponentVNode)(2,t.Box,{children:["1. Turn the dial left to the first number.",(0,e.createVNode)(1,"br"),"2. Turn the dial right to the second number.",(0,e.createVNode)(1,"br"),"3. Continue repeating this process for each number, switching between left and right each time.",(0,e.createVNode)(1,"br"),"4. Open the safe."]}),(0,e.createComponentVNode)(2,t.Box,{bold:!0,children:"To lock fully, turn the dial to the left after closing the safe."})]})}},29740:function(T,r,n){"use strict";r.__esModule=!0,r.SatelliteControl=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SatelliteControl=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.satellites,m=i.notice,l=i.meteor_shield,u=i.meteor_shield_coverage,s=i.meteor_shield_coverage_max,d=i.meteor_shield_coverage_percentage;return(0,e.createComponentVNode)(2,o.Window,{width:475,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[l&&(0,e.createComponentVNode)(2,t.Section,{title:"Station Shield Coverage",children:(0,e.createComponentVNode)(2,t.ProgressBar,{color:d>=100?"good":"average",value:u,maxValue:s,children:[d," %"]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Satellite Network Control",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[m&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Alert",color:"red",children:i.notice}),c.map(function(C){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"#"+C.id,children:[C.mode," ",(0,e.createComponentVNode)(2,t.Button,{content:C.active?"Deactivate":"Activate",icon:"arrow-circle-right",onClick:function(){function g(){return h("toggle",{id:C.id})}return g}()})]},C.id)})]})})]})})}return b}()},44162:function(T,r,n){"use strict";r.__esModule=!0,r.SecureStorage=void 0;var e=n(89005),a=n(35840),t=n(72253),o=n(36036),p=n(98595),b=n(36352),y=n(92986),S=r.SecureStorage=function(){function c(m,l){return(0,e.createComponentVNode)(2,p.Window,{theme:"securestorage",height:500,width:280,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,h)})})})})}return c}(),k=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=window.event?m.which:m.keyCode;if(d===y.KEY_ENTER){m.preventDefault(),s("keypad",{digit:"E"});return}if(d===y.KEY_ESCAPE){m.preventDefault(),s("keypad",{digit:"C"});return}if(d===y.KEY_BACKSPACE){m.preventDefault(),s("backspace");return}if(d>=y.KEY_0&&d<=y.KEY_9){m.preventDefault(),s("keypad",{digit:d-y.KEY_0});return}if(d>=y.KEY_NUMPAD_0&&d<=y.KEY_NUMPAD_9){m.preventDefault(),s("keypad",{digit:d-y.KEY_NUMPAD_0});return}},h=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=d.locked,g=d.no_passcode,v=d.emagged,f=d.user_entered_code,N=[["1","2","3"],["4","5","6"],["7","8","9"],["C","0","E"]],V=g?"":C?"bad":"good";return(0,e.createComponentVNode)(2,o.Section,{fill:!0,onKeyDown:function(){function B(I){return k(I,l)}return B}(),children:[(0,e.createComponentVNode)(2,o.Stack.Item,{height:7.3,children:(0,e.createComponentVNode)(2,o.Box,{className:(0,a.classes)(["SecureStorage__displayBox","SecureStorage__displayBox--"+V]),height:"100%",children:v?"ERROR":f})}),(0,e.createComponentVNode)(2,o.Table,{children:N.map(function(B){return(0,e.createComponentVNode)(2,b.TableRow,{children:B.map(function(I){return(0,e.createComponentVNode)(2,b.TableCell,{children:(0,e.createComponentVNode)(2,i,{number:I})},I)})},B[0])})})]})},i=function(m,l){var u=(0,t.useBackend)(l),s=u.act,d=u.data,C=m.number;return(0,e.createComponentVNode)(2,o.Button,{fluid:!0,bold:!0,mb:"6px",content:C,textAlign:"center",fontSize:"60px",lineHeight:1.25,width:"80px",className:(0,a.classes)(["SecureStorage__Button","SecureStorage__Button--keypad","SecureStorage__Button--"+C]),onClick:function(){function g(){return s("keypad",{digit:C})}return g}()})}},6272:function(T,r,n){"use strict";r.__esModule=!0,r.SecurityRecords=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=n(3939),y=n(321),S=n(5485),k=n(22091),h={"*Execute*":"execute","*Arrest*":"arrest",Incarcerated:"incarcerated",Parolled:"parolled",Released:"released",Demote:"demote",Search:"search",Monitor:"monitor"},i=function(f,N){(0,b.modalOpen)(f,"edit",{field:N.edit,value:N.value})},c=r.SecurityRecords=function(){function v(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.loginState,w=I.currentPage,A;if(L.logged_in)w===1?A=(0,e.createComponentVNode)(2,l):w===2&&(A=(0,e.createComponentVNode)(2,d));else return(0,e.createComponentVNode)(2,p.Window,{theme:"security",width:800,height:900,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,S.LoginScreen)})});return(0,e.createComponentVNode)(2,p.Window,{theme:"security",width:800,height:900,children:[(0,e.createComponentVNode)(2,b.ComplexModal),(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,y.LoginInfo),(0,e.createComponentVNode)(2,k.TemporaryNotice),(0,e.createComponentVNode)(2,m),A]})})]})}return v}(),m=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.currentPage,w=I.general;return(0,e.createComponentVNode)(2,o.Stack.Item,{m:0,children:(0,e.createComponentVNode)(2,o.Tabs,{children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"list",selected:L===1,onClick:function(){function A(){return B("page",{page:1})}return A}(),children:"List Records"}),L===2&&w&&!w.empty&&(0,e.createComponentVNode)(2,o.Tabs.Tab,{icon:"file",selected:L===2,children:["Record: ",w.fields[0].value]})]})})},l=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.records,w=(0,t.useLocalState)(N,"searchText",""),A=w[0],x=w[1],E=(0,t.useLocalState)(N,"sortId","name"),P=E[0],D=E[1],M=(0,t.useLocalState)(N,"sortOrder",!0),O=M[0],R=M[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,s)}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,mt:.5,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,o.Table,{className:"SecurityRecords__list",children:[(0,e.createComponentVNode)(2,o.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,u,{id:"name",children:"Name"}),(0,e.createComponentVNode)(2,u,{id:"id",children:"ID"}),(0,e.createComponentVNode)(2,u,{id:"rank",children:"Assignment"}),(0,e.createComponentVNode)(2,u,{id:"fingerprint",children:"Fingerprint"}),(0,e.createComponentVNode)(2,u,{id:"status",children:"Criminal Status"})]}),L.filter((0,a.createSearch)(A,function(F){return F.name+"|"+F.id+"|"+F.rank+"|"+F.fingerprint+"|"+F.status})).sort(function(F,W){var U=O?1:-1;return F[P].localeCompare(W[P])*U}).map(function(F){return(0,e.createComponentVNode)(2,o.Table.Row,{className:"SecurityRecords__listRow--"+h[F.status],onClick:function(){function W(){return B("view",{uid_gen:F.uid_gen,uid_sec:F.uid_sec})}return W}(),children:[(0,e.createComponentVNode)(2,o.Table.Cell,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user"})," ",F.name]}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:F.id}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:F.rank}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:F.fingerprint}),(0,e.createComponentVNode)(2,o.Table.Cell,{children:F.status})]},F.id)})]})})})],4)},u=function(f,N){var V=(0,t.useLocalState)(N,"sortId","name"),B=V[0],I=V[1],L=(0,t.useLocalState)(N,"sortOrder",!0),w=L[0],A=L[1],x=f.id,E=f.children;return(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Table.Cell,{children:(0,e.createComponentVNode)(2,o.Button,{color:B!==x&&"transparent",fluid:!0,onClick:function(){function P(){B===x?A(!w):(I(x),A(!0))}return P}(),children:[E,B===x&&(0,e.createComponentVNode)(2,o.Icon,{name:w?"sort-up":"sort-down",ml:"0.25rem;"})]})})})},s=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.isPrinting,w=(0,t.useLocalState)(N,"searchText",""),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{ml:"0.25rem",content:"New Record",icon:"plus",onClick:function(){function E(){return B("new_general")}return E}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Button,{disabled:L,icon:L?"spinner":"print",iconSpin:!!L,content:"Print Cell Log",onClick:function(){function E(){return(0,b.modalOpen)(N,"print_cell_log")}return E}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"Search by Name, ID, Assignment, Fingerprint, Status",fluid:!0,onInput:function(){function E(P,D){return x(D)}return E}()})})]})},d=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.isPrinting,w=I.general,A=I.security;return!w||!w.fields?(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:"General records lost!"}):(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"General Data",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{disabled:L,icon:L?"spinner":"print",iconSpin:!!L,content:"Print Record",onClick:function(){function x(){return B("print_record")}return x}()}),(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",tooltip:"WARNING: This will also delete the Security and Medical records associated with this crew member!",tooltipPosition:"bottom-start",content:"Delete Record",onClick:function(){function x(){return B("delete_general")}return x}()})],4),children:(0,e.createComponentVNode)(2,C)})}),!A||!A.fields?(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,title:"Security Data",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"pen",content:"Create New Record",onClick:function(){function x(){return B("new_security")}return x}()}),children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{bold:!0,grow:!0,textAlign:"center",fontSize:1.75,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon.Stack,{children:[(0,e.createComponentVNode)(2,o.Icon,{name:"scroll",size:5,color:"gray"}),(0,e.createComponentVNode)(2,o.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"Security records lost!"]})})})}):(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Security Data",buttons:(0,e.createComponentVNode)(2,o.Button.Confirm,{icon:"trash",disabled:A.empty,content:"Delete Record",onClick:function(){function x(){return B("delete_security")}return x}()}),children:(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:A.fields.map(function(x,E){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:x.field,preserveWhitespace:!0,children:[(0,a.decodeHtmlEntities)(x.value),!!x.edit&&(0,e.createComponentVNode)(2,o.Button,{icon:"pen",ml:"0.5rem",mb:x.line_break?"1rem":"initial",onClick:function(){function P(){return i(N,x)}return P}()})]},E)})})})})}),(0,e.createComponentVNode)(2,g)],4)],0)},C=function(f,N){var V=(0,t.useBackend)(N),B=V.data,I=B.general;return!I||!I.fields?(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,color:"bad",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,children:"General records lost!"})})}):(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:I.fields.map(function(L,w){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:L.field,preserveWhitespace:!0,children:[(0,a.decodeHtmlEntities)(""+L.value),!!L.edit&&(0,e.createComponentVNode)(2,o.Button,{icon:"pen",ml:"0.5rem",mb:L.line_break?"1rem":"initial",onClick:function(){function A(){return i(N,L)}return A}()})]},w)})})}),!!I.has_photos&&I.photos.map(function(L,w){return(0,e.createComponentVNode)(2,o.Stack.Item,{inline:!0,textAlign:"center",color:"label",ml:0,children:[(0,e.createVNode)(1,"img",null,null,1,{src:L,style:{width:"96px","margin-top":"5rem","margin-bottom":"0.5rem","-ms-interpolation-mode":"nearest-neighbor","image-rendering":"pixelated"}}),(0,e.createVNode)(1,"br"),"Photo #",w+1]},w)})]})},g=function(f,N){var V=(0,t.useBackend)(N),B=V.act,I=V.data,L=I.security;return(0,e.createComponentVNode)(2,o.Stack.Item,{height:"150px",children:(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Comments/Log",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:"comment",content:"Add Entry",onClick:function(){function w(){return(0,b.modalOpen)(N,"comment_add")}return w}()}),children:L.comments.length===0?(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No comments found."}):L.comments.map(function(w,A){return(0,e.createComponentVNode)(2,o.Box,{preserveWhitespace:!0,children:[(0,e.createComponentVNode)(2,o.Box,{color:"label",inline:!0,children:w.header||"Auto-generated"}),(0,e.createVNode)(1,"br"),w.text||w,(0,e.createComponentVNode)(2,o.Button,{icon:"comment-slash",color:"bad",ml:"0.5rem",onClick:function(){function x(){return B("comment_delete",{id:A+1})}return x}()})]},A)})})})}},5099:function(T,r,n){"use strict";r.__esModule=!0,r.SeedExtractor=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=n(98595),b=n(3939);function y(u,s){var d=typeof Symbol!="undefined"&&u[Symbol.iterator]||u["@@iterator"];if(d)return(d=d.call(u)).next.bind(d);if(Array.isArray(u)||(d=S(u))||s&&u&&typeof u.length=="number"){d&&(u=d);var C=0;return function(){return C>=u.length?{done:!0}:{done:!1,value:u[C++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function S(u,s){if(u){if(typeof u=="string")return k(u,s);var d={}.toString.call(u).slice(8,-1);return d==="Object"&&u.constructor&&(d=u.constructor.name),d==="Map"||d==="Set"?Array.from(u):d==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(d)?k(u,s):void 0}}function k(u,s){(s==null||s>u.length)&&(s=u.length);for(var d=0,C=Array(s);d=A},g=function(w,A){return w<=A},v=s.split(" "),f=[],N=function(){var w=I.value,A=w.split(":");if(A.length===0)return 0;if(A.length===1)return f.push(function(P){return(P.name+" ("+P.variant+")").toLocaleLowerCase().includes(A[0].toLocaleLowerCase())}),0;if(A.length>2)return{v:function(){function P(D){return!1}return P}()};var x,E=d;if(A[1][A[1].length-1]==="-"?(E=g,x=Number(A[1].substring(0,A[1].length-1))):A[1][A[1].length-1]==="+"?(E=C,x=Number(A[1].substring(0,A[1].length-1))):x=Number(A[1]),isNaN(x))return{v:function(){function P(D){return!1}return P}()};switch(A[0].toLocaleLowerCase()){case"l":case"life":case"lifespan":f.push(function(P){return E(P.lifespan,x)});break;case"e":case"end":case"endurance":f.push(function(P){return E(P.endurance,x)});break;case"m":case"mat":case"maturation":f.push(function(P){return E(P.maturation,x)});break;case"pr":case"prod":case"production":f.push(function(P){return E(P.production,x)});break;case"y":case"yield":f.push(function(P){return E(P.yield,x)});break;case"po":case"pot":case"potency":f.push(function(P){return E(P.potency,x)});break;case"s":case"stock":case"c":case"count":case"a":case"amount":f.push(function(P){return E(P.amount,x)});break;default:return{v:function(){function P(D){return!1}return P}()}}},V,B=y(v),I;!(I=B()).done;)if(V=N(),V!==0&&V)return V.v;return function(L){for(var w=0,A=f;w=1?Number(E):1)}return A}()})]})]})}},2916:function(T,r,n){"use strict";r.__esModule=!0,r.ShuttleConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ShuttleConsole=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;return(0,e.createComponentVNode)(2,o.Window,{width:350,height:150,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Location",children:i.status?i.status:(0,e.createComponentVNode)(2,t.NoticeBox,{color:"red",children:"Shuttle Missing"})}),!!i.shuttle&&(!!i.docking_ports_len&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Send to ",children:i.docking_ports.map(function(c){return(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-right",content:c.name,onClick:function(){function m(){return h("move",{move:c.id})}return m}()},c.name)})})||(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",color:"red",children:(0,e.createComponentVNode)(2,t.NoticeBox,{color:"red",children:"Shuttle Locked"})}),!!i.admin_controlled&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Authorization",children:(0,e.createComponentVNode)(2,t.Button,{icon:"exclamation-circle",content:"Request Authorization",disabled:!i.status,onClick:function(){function c(){return h("request")}return c}()})})],0))]})})})})}return b}()},39401:function(T,r,n){"use strict";r.__esModule=!0,r.ShuttleManipulator=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.ShuttleManipulator=function(){function k(h,i){var c=(0,a.useLocalState)(i,"tabIndex",0),m=c[0],l=c[1],u=function(){function s(d){switch(d){case 0:return(0,e.createComponentVNode)(2,b);case 1:return(0,e.createComponentVNode)(2,y);case 2:return(0,e.createComponentVNode)(2,S);default:return"WE SHOULDN'T BE HERE!"}}return s}();return(0,e.createComponentVNode)(2,o.Window,{width:650,height:700,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Box,{fillPositionedParent:!0,children:[(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:m===0,onClick:function(){function s(){return l(0)}return s}(),icon:"info-circle",children:"Status"},"Status"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:m===1,onClick:function(){function s(){return l(1)}return s}(),icon:"file-import",children:"Templates"},"Templates"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:m===2,onClick:function(){function s(){return l(2)}return s}(),icon:"tools",children:"Modification"},"Modification")]}),u(m)]})})})}return k}(),b=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.shuttles;return(0,e.createComponentVNode)(2,t.Box,{children:u.map(function(s){return(0,e.createComponentVNode)(2,t.Section,{title:s.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"ID",children:s.id}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Shuttle Timer",children:s.timeleft}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Shuttle Mode",children:s.mode}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Shuttle Status",children:s.status}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Jump To",icon:"location-arrow",onClick:function(){function d(){return m("jump_to",{type:"mobile",id:s.id})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Fast Travel",icon:"fast-forward",onClick:function(){function d(){return m("fast_travel",{id:s.id})}return d}()})]})]})},s.name)})})},y=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.templates_tabs,s=l.existing_shuttle,d=l.templates;return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Tabs,{children:u.map(function(C){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:C===s.id,icon:"file",onClick:function(){function g(){return m("select_template_category",{cat:C})}return g}(),children:C},C)})}),!!s&&d[s.id].templates.map(function(C){return(0,e.createComponentVNode)(2,t.Section,{title:C.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[C.description&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:C.description}),C.admin_notes&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Admin Notes",children:C.admin_notes}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:(0,e.createComponentVNode)(2,t.Button,{content:"Load Template",icon:"download",onClick:function(){function g(){return m("select_template",{shuttle_id:C.shuttle_id})}return g}()})})]})},C.name)})]})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.existing_shuttle,s=l.selected;return(0,e.createComponentVNode)(2,t.Box,{children:[u?(0,e.createComponentVNode)(2,t.Section,{title:"Selected Shuttle: "+u.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:u.status}),u.timer&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Timer",children:u.timeleft}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:(0,e.createComponentVNode)(2,t.Button,{content:"Jump To",icon:"location-arrow",onClick:function(){function d(){return m("jump_to",{type:"mobile",id:u.id})}return d}()})})]})}):(0,e.createComponentVNode)(2,t.Section,{title:"Selected Shuttle: None"}),s?(0,e.createComponentVNode)(2,t.Section,{title:"Selected Template: "+s.name,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[s.description&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Description",children:s.description}),s.admin_notes&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Admin Notes",children:s.admin_notes}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Actions",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Preview",icon:"eye",onClick:function(){function d(){return m("preview",{shuttle_id:s.shuttle_id})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Load",icon:"download",onClick:function(){function d(){return m("load",{shuttle_id:s.shuttle_id})}return d}()})]})]})}):(0,e.createComponentVNode)(2,t.Section,{title:"Selected Template: None"})]})}},88284:function(T,r,n){"use strict";r.__esModule=!0,r.Sleeper=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=[["good","Alive"],["average","Critical"],["bad","DEAD"]],y=[["Resp.","oxyLoss"],["Toxin","toxLoss"],["Brute","bruteLoss"],["Burn","fireLoss"]],S={average:[.25,.5],bad:[.5,1/0]},k=["bad","average","average","good","average","average","bad"],h=r.Sleeper=function(){function d(C,g){var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.hasOccupant,B=V?(0,e.createComponentVNode)(2,i):(0,e.createComponentVNode)(2,s);return(0,e.createComponentVNode)(2,p.Window,{width:550,height:760,children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:B}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,l)})]})})})}return d}(),i=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.occupant;return(0,e.createFragment)([(0,e.createComponentVNode)(2,c),(0,e.createComponentVNode)(2,m),(0,e.createComponentVNode)(2,u)],4)},c=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.occupant,B=N.auto_eject_dead;return(0,e.createComponentVNode)(2,o.Section,{title:"Occupant",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Box,{color:"label",inline:!0,children:"Auto-eject if dead:\xA0"}),(0,e.createComponentVNode)(2,o.Button,{icon:B?"toggle-on":"toggle-off",selected:B,content:B?"On":"Off",onClick:function(){function I(){return f("auto_eject_dead_"+(B?"off":"on"))}return I}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"user-slash",content:"Eject",onClick:function(){function I(){return f("ejectify")}return I}()})],4),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Name",children:V.name}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Health",children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:V.maxHealth,value:V.health/V.maxHealth,ranges:{good:[.5,1/0],average:[0,.5],bad:[-1/0,0]},children:(0,a.round)(V.health,0)})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Status",color:b[V.stat][0],children:b[V.stat][1]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:V.maxTemp,value:V.bodyTemperature/V.maxTemp,color:k[V.temperatureSuitability+3],children:[(0,a.round)(V.btCelsius,0),"\xB0C,",(0,a.round)(V.btFaren,0),"\xB0F"]})}),!!V.hasBlood&&(0,e.createFragment)([(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Blood Level",children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:V.bloodMax,value:V.bloodLevel/V.bloodMax,ranges:{bad:[-1/0,.6],average:[.6,.9],good:[.6,1/0]},children:[V.bloodPercent,"%, ",V.bloodLevel,"cl"]})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Pulse",verticalAlign:"middle",children:[V.pulse," BPM"]})],4)]})})},m=function(C,g){var v=(0,t.useBackend)(g),f=v.data,N=f.occupant;return(0,e.createComponentVNode)(2,o.Section,{title:"Occupant Damage",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:y.map(function(V,B){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:V[0],children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:"100",value:N[V[1]]/100,ranges:S,children:(0,a.round)(N[V[1]],0)},B)},B)})})})},l=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.hasOccupant,B=N.isBeakerLoaded,I=N.beakerMaxSpace,L=N.beakerFreeSpace,w=N.dialysis,A=w&&L>0;return(0,e.createComponentVNode)(2,o.Section,{title:"Dialysis",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{disabled:!B||L<=0||!V,selected:A,icon:A?"toggle-on":"toggle-off",content:A?"Active":"Inactive",onClick:function(){function x(){return f("togglefilter")}return x}()}),(0,e.createComponentVNode)(2,o.Button,{disabled:!B,icon:"eject",content:"Eject",onClick:function(){function x(){return f("removebeaker")}return x}()})],4),children:B?(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Remaining Space",children:(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:I,value:L/I,ranges:{good:[.5,1/0],average:[.25,.5],bad:[-1/0,.25]},children:[L,"u"]})})}):(0,e.createComponentVNode)(2,o.Box,{color:"label",children:"No beaker loaded."})})},u=function(C,g){var v=(0,t.useBackend)(g),f=v.act,N=v.data,V=N.occupant,B=N.chemicals,I=N.maxchem,L=N.amounts;return(0,e.createComponentVNode)(2,o.Section,{title:"Occupant Chemicals",children:B.map(function(w,A){var x="",E;return w.overdosing?(x="bad",E=(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-circle"}),"\xA0 Overdosing!"]})):w.od_warning&&(x="average",E=(0,e.createComponentVNode)(2,o.Box,{color:"average",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"exclamation-triangle"}),"\xA0 Close to overdosing"]})),(0,e.createComponentVNode)(2,o.Box,{backgroundColor:"rgba(0, 0, 0, 0.33)",mb:"0.5rem",children:(0,e.createComponentVNode)(2,o.Section,{title:w.title,level:"3",mx:"0",lineHeight:"18px",buttons:E,children:(0,e.createComponentVNode)(2,o.Stack,{children:[(0,e.createComponentVNode)(2,o.ProgressBar,{min:"0",max:I,value:w.occ_amount/I,color:x,title:"Amount of chemicals currently inside the occupant / Total amount injectable by this machine",mr:"0.5rem",children:[w.pretty_amount,"/",I,"u"]}),L.map(function(P,D){return(0,e.createComponentVNode)(2,o.Button,{disabled:!w.injectable||w.occ_amount+P>I||V.stat===2,icon:"syringe",content:"Inject "+P+"u",title:"Inject "+P+"u of "+w.title+" into the occupant",mb:"0",height:"19px",onClick:function(){function M(){return f("chemical",{chemid:w.id,amount:P})}return M}()},D)})]})})},A)})})},s=function(C,g){return(0,e.createComponentVNode)(2,o.Section,{fill:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,o.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,align:"center",color:"label",children:[(0,e.createComponentVNode)(2,o.Icon,{name:"user-slash",mb:"0.5rem",size:"5"}),(0,e.createVNode)(1,"br"),"No occupant detected."]})})})}},21597:function(T,r,n){"use strict";r.__esModule=!0,r.SlotMachine=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SlotMachine=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;if(i.money===null)return(0,e.createComponentVNode)(2,o.Window,{width:350,height:90,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{children:"Could not scan your card or could not find account!"}),(0,e.createComponentVNode)(2,t.Box,{children:"Please wear or hold your ID and try again."})]})})});var c;return i.plays===1?c=i.plays+" player has tried their luck today!":c=i.plays+" players have tried their luck today!",(0,e.createComponentVNode)(2,o.Window,{width:300,height:151,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{lineHeight:2,children:c}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Credits Remaining",children:(0,e.createComponentVNode)(2,t.AnimatedNumber,{value:i.money})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"10 credits to spin",children:(0,e.createComponentVNode)(2,t.Button,{icon:"coins",disabled:i.working,content:i.working?"Spinning...":"Spin",onClick:function(){function m(){return h("spin")}return m}()})})]}),(0,e.createComponentVNode)(2,t.Box,{bold:!0,lineHeight:2,color:i.resultlvl,children:i.result})]})})})}return b}()},46348:function(T,r,n){"use strict";r.__esModule=!0,r.Smartfridge=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Smartfridge=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.secure,m=i.can_dry,l=i.drying,u=i.contents;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[!!c&&(0,e.createComponentVNode)(2,t.NoticeBox,{children:"Secure Access: Please have your identification ready."}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:m?"Drying rack":"Contents",buttons:!!m&&(0,e.createComponentVNode)(2,t.Button,{width:4,icon:l?"power-off":"times",content:l?"On":"Off",selected:l,onClick:function(){function s(){return h("drying")}return s}()}),children:[!u&&(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{bold:!0,grow:!0,textAlign:"center",align:"center",color:"average",children:[(0,e.createComponentVNode)(2,t.Icon.Stack,{children:[(0,e.createComponentVNode)(2,t.Icon,{name:"cookie-bite",size:5,color:"brown"}),(0,e.createComponentVNode)(2,t.Icon,{name:"slash",size:5,color:"red"})]}),(0,e.createVNode)(1,"br"),"No products loaded."]})}),!!u&&u.slice().sort(function(s,d){return s.display_name.localeCompare(d.display_name)}).map(function(s){return(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:"55%",children:s.display_name}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:"25%",children:["(",s.quantity," in stock)"]}),(0,e.createComponentVNode)(2,t.Stack.Item,{width:13,children:[(0,e.createComponentVNode)(2,t.Button,{width:3,icon:"arrow-down",tooltip:"Dispense one.",content:"1",onClick:function(){function d(){return h("vend",{index:s.vend,amount:1})}return d}()}),(0,e.createComponentVNode)(2,t.NumberInput,{width:"40px",minValue:0,value:0,maxValue:s.quantity,step:1,stepPixelSize:3,onChange:function(){function d(C,g){return h("vend",{index:s.vend,amount:g})}return d}()}),(0,e.createComponentVNode)(2,t.Button,{width:4,icon:"arrow-down",content:"All",tooltip:"Dispense all.",tooltipPosition:"bottom-start",onClick:function(){function d(){return h("vend",{index:s.vend,amount:s.quantity})}return d}()})]})]},s)})]})]})})})}return b}()},86162:function(T,r,n){"use strict";r.__esModule=!0,r.Smes=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(49968),p=n(98595),b=1e3,y=r.Smes=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.capacityPercent,u=m.capacity,s=m.charge,d=m.inputAttempt,C=m.inputting,g=m.inputLevel,v=m.inputLevelMax,f=m.inputAvailable,N=m.outputPowernet,V=m.outputAttempt,B=m.outputting,I=m.outputLevel,L=m.outputLevelMax,w=m.outputUsed,A=l>=100&&"good"||C&&"average"||"bad",x=B&&"good"||s>0&&"average"||"bad";return(0,e.createComponentVNode)(2,p.Window,{width:340,height:345,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Stored Energy",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:l*.01,ranges:{good:[.5,1/0],average:[.15,.5],bad:[-1/0,.15]}})}),(0,e.createComponentVNode)(2,t.Section,{title:"Input",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Charge Mode",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:d?"sync-alt":"times",selected:d,onClick:function(){function E(){return c("tryinput")}return E}(),children:d?"Auto":"Off"}),children:(0,e.createComponentVNode)(2,t.Box,{color:A,children:l>=100&&"Fully Charged"||C&&"Charging"||"Not Charging"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target Input",children:(0,e.createComponentVNode)(2,t.Stack,{inline:!0,width:"100%",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",disabled:g===0,onClick:function(){function E(){return c("input",{target:"min"})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"backward",disabled:g===0,onClick:function(){function E(){return c("input",{adjust:-1e4})}return E}()})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Slider,{value:g/b,fillValue:f/b,minValue:0,maxValue:v/b,step:5,stepPixelSize:4,format:function(){function E(P){return(0,o.formatPower)(P*b,1)}return E}(),onChange:function(){function E(P,D){return c("input",{target:D*b})}return E}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"forward",disabled:g===v,onClick:function(){function E(){return c("input",{adjust:1e4})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",disabled:g===v,onClick:function(){function E(){return c("input",{target:"max"})}return E}()})]})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Available",children:(0,o.formatPower)(f)})]})}),(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Output",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Output Mode",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:V?"power-off":"times",selected:V,onClick:function(){function E(){return c("tryoutput")}return E}(),children:V?"On":"Off"}),children:(0,e.createComponentVNode)(2,t.Box,{color:x,children:N?B?"Sending":s>0?"Not Sending":"No Charge":"Not Connected"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target Output",children:(0,e.createComponentVNode)(2,t.Stack,{inline:!0,width:"100%",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",disabled:I===0,onClick:function(){function E(){return c("output",{target:"min"})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"backward",disabled:I===0,onClick:function(){function E(){return c("output",{adjust:-1e4})}return E}()})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Slider,{value:I/b,minValue:0,maxValue:L/b,step:5,stepPixelSize:4,format:function(){function E(P){return(0,o.formatPower)(P*b,1)}return E}(),onChange:function(){function E(P,D){return c("output",{target:D*b})}return E}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"forward",disabled:I===L,onClick:function(){function E(){return c("output",{adjust:1e4})}return E}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",disabled:I===L,onClick:function(){function E(){return c("output",{target:"max"})}return E}()})]})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Outputting",children:(0,o.formatPower)(w)})]})})]})})})}return S}()},63584:function(T,r,n){"use strict";r.__esModule=!0,r.SolarControl=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SolarControl=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=0,m=1,l=2,u=i.generated,s=i.generated_ratio,d=i.tracking_state,C=i.tracking_rate,g=i.connected_panels,v=i.connected_tracker,f=i.cdir,N=i.direction,V=i.rotating_direction;return(0,e.createComponentVNode)(2,o.Window,{width:490,height:277,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Status",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"sync",content:"Scan for new hardware",onClick:function(){function B(){return h("refresh")}return B}()}),children:(0,e.createComponentVNode)(2,t.Grid,{children:[(0,e.createComponentVNode)(2,t.Grid.Column,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Solar tracker",color:v?"good":"bad",children:v?"OK":"N/A"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Solar panels",color:g>0?"good":"bad",children:g})]})}),(0,e.createComponentVNode)(2,t.Grid.Column,{size:2,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power output",children:(0,e.createComponentVNode)(2,t.ProgressBar,{ranges:{good:[.66,1/0],average:[.33,.66],bad:[-1/0,.33]},minValue:0,maxValue:1,value:s,children:u+" W"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Panel orientation",children:[f,"\xB0 (",N,")"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tracker rotation",children:[d===l&&(0,e.createComponentVNode)(2,t.Box,{children:" Automated "}),d===m&&(0,e.createComponentVNode)(2,t.Box,{children:[" ",C,"\xB0/h (",V,")"," "]}),d===c&&(0,e.createComponentVNode)(2,t.Box,{children:" Tracker offline "})]})]})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Controls",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Panel orientation",children:[d!==l&&(0,e.createComponentVNode)(2,t.NumberInput,{unit:"\xB0",step:1,stepPixelSize:1,minValue:0,maxValue:359,value:f,onDrag:function(){function B(I,L){return h("cdir",{cdir:L})}return B}()}),d===l&&(0,e.createComponentVNode)(2,t.Box,{lineHeight:"19px",children:" Automated "})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tracker status",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Off",selected:d===c,onClick:function(){function B(){return h("track",{track:c})}return B}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"clock-o",content:"Timed",selected:d===m,onClick:function(){function B(){return h("track",{track:m})}return B}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sync",content:"Auto",selected:d===l,disabled:!v,onClick:function(){function B(){return h("track",{track:l})}return B}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tracker rotation",children:[d===m&&(0,e.createComponentVNode)(2,t.NumberInput,{unit:"\xB0/h",step:1,stepPixelSize:1,minValue:-7200,maxValue:7200,value:C,format:function(){function B(I){var L=Math.sign(I)>0?"+":"-";return L+Math.abs(I)}return B}(),onDrag:function(){function B(I,L){return h("tdir",{tdir:L})}return B}()}),d===c&&(0,e.createComponentVNode)(2,t.Box,{lineHeight:"19px",children:" Tracker offline "}),d===l&&(0,e.createComponentVNode)(2,t.Box,{lineHeight:"19px",children:" Automated "})]})]})})]})})}return b}()},38096:function(T,r,n){"use strict";r.__esModule=!0,r.SpawnersMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SpawnersMenu=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.spawners||[];return(0,e.createComponentVNode)(2,o.Window,{width:700,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Section,{children:c.map(function(m){return(0,e.createComponentVNode)(2,t.Section,{mb:.5,title:m.name+" ("+m.amount_left+" left)",level:2,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-circle-right",content:"Jump",onClick:function(){function l(){return h("jump",{ID:m.uids})}return l}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"chevron-circle-right",content:"Spawn",onClick:function(){function l(){return h("spawn",{ID:m.uids})}return l}()})],4),children:[(0,e.createComponentVNode)(2,t.Box,{style:{"white-space":"pre-wrap"},mb:1,fontSize:"16px",children:m.desc}),!!m.fluff&&(0,e.createComponentVNode)(2,t.Box,{style:{"white-space":"pre-wrap"},textColor:"#878787",fontSize:"14px",children:m.fluff}),!!m.important_info&&(0,e.createComponentVNode)(2,t.Box,{style:{"white-space":"pre-wrap"},mt:1,bold:!0,color:"red",fontSize:"18px",children:m.important_info})]},m.name)})})})})}return b}()},30586:function(T,r,n){"use strict";r.__esModule=!0,r.SpecMenu=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SpecMenu=function(){function h(i,c){return(0,e.createComponentVNode)(2,o.Window,{width:1100,height:600,theme:"nologo",children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,y),(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k)]})})})}return h}(),b=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.subclasses;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Hemomancer",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Choose",onClick:function(){function d(){return l("hemomancer")}return d}()}),children:[(0,e.createVNode)(1,"h3",null,"Focuses on blood magic and the manipulation of blood around you.",16),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Vampiric claws",16),(0,e.createTextVNode)(": Unlocked at 150 blood, allows you to summon a robust pair of claws that attack rapidly, drain a targets blood, and heal you.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood Barrier",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to select two turfs and create a wall between them.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood tendrils",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to slow everyone in a targeted 3x3 area after a short delay.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Sanguine pool",16),(0,e.createTextVNode)(": Unlocked at 400 blood, allows you to travel at high speeds for a short duration. Doing this leaves behind blood splatters. You can move through anything but walls and space when doing this.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Predator senses",16),(0,e.createTextVNode)(": Unlocked at 600 blood, allows you to sniff out anyone within the same sector as you.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood eruption",16),(0,e.createTextVNode)(": Unlocked at 800 blood, allows you to manipulate all nearby blood splatters, in 4 tiles around you, into spikes that impale anyone stood ontop of them.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Full power",16),(0,e.createComponentVNode)(2,t.Divider),(0,e.createVNode)(1,"b",null,"The blood bringers rite",16),(0,e.createTextVNode)(": When toggled you will rapidly drain the blood of everyone who is nearby and use it to heal yourself slightly and remove any incapacitating effects rapidly.")],4)]})})},y=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.subclasses;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Umbrae",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Choose",onClick:function(){function d(){return l("umbrae")}return d}()}),children:[(0,e.createVNode)(1,"h3",null,"Focuses on darkness, stealth ambushing and mobility.",16),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Cloak of darkness",16),(0,e.createTextVNode)(": Unlocked at 150 blood, when toggled, allows you to become nearly invisible and move rapidly when in dark regions. While active, burn damage is more effective against you.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Shadow anchor",16),(0,e.createTextVNode)(": Unlocked at 250 blood, casting it will create an anchor at the cast location after a short delay. If you then cast the ability again, you are teleported back to the anchor. If you do not cast again within 2 minutes, you will do a fake recall, causing a clone to appear at the anchor and making yourself invisible. It will not teleport you between Z levels.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Shadow snare",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to summon a trap that when crossed blinds and ensnares the victim. This trap is hard to see, but withers in the light.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Dark passage",16),(0,e.createTextVNode)(": Unlocked at 400 blood, allows you to target a turf on screen, you will then teleport to that turf.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Extinguish",16),(0,e.createTextVNode)(": Unlocked at 600 blood, allows you to snuff out nearby electronic light sources and glowshrooms.")],4),(0,e.createVNode)(1,"b",null,"Shadow boxing",16),": Unlocked at 800 blood, sends out shadow clones towards a target, damaging them while you remain in range.",(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Full power",16),(0,e.createComponentVNode)(2,t.Divider),(0,e.createVNode)(1,"b",null,"Eternal darkness",16),(0,e.createTextVNode)(": When toggled, you consume yourself in unholy darkness, only the strongest of lights will be able to see through it. Inside the radius, nearby creatures will freeze and energy projectiles will deal less damage.")],4),(0,e.createVNode)(1,"p",null,"In addition, you also gain permanent X-ray vision.",16)]})})},S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.subclasses;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Gargantua",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Choose",onClick:function(){function d(){return l("gargantua")}return d}()}),children:[(0,e.createVNode)(1,"h3",null,"Focuses on tenacity and melee damage.",16),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Rejuvenate",16),(0,e.createTextVNode)(": Will heal you at an increased rate based on how much damage you have taken.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood swell",16),(0,e.createTextVNode)(": Unlocked at 150 blood, increases your resistance to physical damage, stuns and stamina for 30 seconds. While it is active you cannot fire guns.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Seismic stomp",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to stomp the ground to send out a shockwave, knocking people back.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood rush",16),(0,e.createTextVNode)(": Unlocked at 250 blood, gives you a short speed boost when cast.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood swell II",16),(0,e.createTextVNode)(": Unlocked at 400 blood, increases all melee damage by 10.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Overwhelming force",16),(0,e.createTextVNode)(": Unlocked at 600 blood, when toggled, if you bump into a door that you do not have access to, it will force it open. In addition, you cannot be pushed or pulled while it is active.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Demonic grasp",16),(0,e.createTextVNode)(": Unlocked at 800 blood, allows you to send out a demonic hand to snare someone. If you are on disarm/grab intent you will push/pull the target, respectively.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Charge",16),(0,e.createTextVNode)(": Unlocked at 800 blood, you gain the ability to charge at a target. Destroying and knocking back pretty much anything you collide with.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Full Power",16),(0,e.createComponentVNode)(2,t.Divider),(0,e.createVNode)(1,"b",null,"Desecrated Duel",16),(0,e.createTextVNode)(": Leap towards a visible enemy, creating an arena upon landing, infusing you with increased regeneration, and granting you resistance to internal damages.")],4)]})})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.subclasses;return(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,basis:"25%",children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Dantalion",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Choose",onClick:function(){function d(){return l("dantalion")}return d}()}),children:[(0,e.createVNode)(1,"h3",null,"Focuses on thralling and illusions.",16),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Enthrall",16),(0,e.createTextVNode)(": Unlocked at 150 blood, Thralls your target to your will, requires you to stand still. Does not work on mindshielded or already enthralled/mindslaved people.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Thrall cap",16),(0,e.createTextVNode)(": You can only thrall a max of 1 person at a time. This can be increased at 400 blood, 600 blood and at full power to a max of 4 thralls.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Thrall commune",16),(0,e.createTextVNode)(": Unlocked at 150 blood, Allows you to talk to your thralls, your thralls can talk back in the same way.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Subspace swap",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to swap positions with a target.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Pacify",16),(0,e.createTextVNode)(": Unlocked at 250 blood, allows you to pacify a target, preventing them from causing harm for 40 seconds.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Decoy",16),(0,e.createTextVNode)(": Unlocked at 400 blood, briefly turn invisible and send out an illusion to fool everyone nearby.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Rally thralls",16),(0,e.createTextVNode)(": Unlocked at 600 blood, removes all incapacitating effects from nearby thralls.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Blood bond",16),(0,e.createTextVNode)(": Unlocked at 800 blood, when cast, all nearby thralls become linked to you. If anyone in the network takes damage, it is shared equally between everyone in the network. If a thrall goes out of range, they will be removed from the network.")],4),(0,e.createVNode)(1,"p",null,[(0,e.createVNode)(1,"b",null,"Full Power",16),(0,e.createComponentVNode)(2,t.Divider),(0,e.createVNode)(1,"b",null,"Mass Hysteria",16),(0,e.createTextVNode)(": Casts a powerful illusion that blinds and then makes everyone nearby perceive others as random animals.")],4)]})})}},95152:function(T,r,n){"use strict";r.__esModule=!0,r.StackCraft=void 0;var e=n(89005),a=n(72253),t=n(88510),o=n(64795),p=n(25328),b=n(98595),y=n(36036),S=r.StackCraft=function(){function s(){return(0,e.createComponentVNode)(2,b.Window,{width:350,height:500,children:(0,e.createComponentVNode)(2,b.Window.Content,{children:(0,e.createComponentVNode)(2,k)})})}return s}(),k=function(d,C){var g=(0,a.useBackend)(C),v=g.data,f=v.amount,N=v.recipes,V=(0,a.useLocalState)(C,"searchText",""),B=V[0],I=V[1],L=h(N,(0,p.createSearch)(B)),w=(0,a.useLocalState)(C,"",!1),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,y.Section,{fill:!0,scrollable:!0,title:"Amount: "+f,buttons:(0,e.createFragment)([A&&(0,e.createComponentVNode)(2,y.Input,{width:12.5,value:B,placeholder:"Find recipe",onInput:function(){function E(P,D){return I(D)}return E}()}),(0,e.createComponentVNode)(2,y.Button,{ml:.5,tooltip:"Search",tooltipPosition:"bottom-end",icon:"magnifying-glass",selected:A,onClick:function(){function E(){return x(!A)}return E}()})],0),children:L?(0,e.createComponentVNode)(2,l,{recipes:L}):(0,e.createComponentVNode)(2,y.NoticeBox,{children:"No recipes found!"})})},h=function s(d,C){var g=(0,o.flow)([(0,t.map)(function(v){var f=v[0],N=v[1];return i(N)?C(f)?v:[f,s(N,C)]:C(f)?v:[f,void 0]}),(0,t.filter)(function(v){var f=v[0],N=v[1];return N!==void 0}),(0,t.sortBy)(function(v){var f=v[0],N=v[1];return f}),(0,t.sortBy)(function(v){var f=v[0],N=v[1];return!i(N)}),(0,t.reduce)(function(v,f){var N=f[0],V=f[1];return v[N]=V,v},{})])(Object.entries(d));return Object.keys(g).length?g:void 0},i=function(d){return d.uid===void 0},c=function(d,C){return d.required_amount>C?0:Math.floor(C/d.required_amount)},m=function(d,C){for(var g=(0,a.useBackend)(C),v=g.act,f=d.recipe,N=d.max_possible_multiplier,V=Math.min(N,Math.floor(f.max_result_amount/f.result_amount)),B=[5,10,25],I=[],L=function(){var E=A[w];V>=E&&I.push((0,e.createComponentVNode)(2,y.Button,{bold:!0,translucent:!0,fontSize:.85,width:"32px",content:E*f.result_amount+"x",onClick:function(){function P(){return v("make",{recipe_uid:f.uid,multiplier:E})}return P}()}))},w=0,A=B;w1?I+"x ":"",M=L>1?"s":"",O=""+D+V,R=L+" sheet"+M,F=c(B,N);return(0,e.createComponentVNode)(2,y.ImageButton,{fluid:!0,base64:P,dmIcon:x,dmIconState:E,imageSize:32,disabled:!F,tooltip:R,buttons:w>1&&F>1&&(0,e.createComponentVNode)(2,m,{recipe:B,max_possible_multiplier:F}),onClick:function(){function W(){return v("make",{recipe_uid:A,multiplier:1})}return W}(),children:O})}},38307:function(T,r,n){"use strict";r.__esModule=!0,r.StationAlertConsoleContent=r.StationAlertConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.StationAlertConsole=function(){function y(){return(0,e.createComponentVNode)(2,o.Window,{width:325,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,b)})})}return y}(),b=r.StationAlertConsoleContent=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.data,c=i.alarms||[],m=c.Fire||[],l=c.Atmosphere||[],u=c.Power||[];return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"Fire Alarms",children:(0,e.createVNode)(1,"ul",null,[m.length===0&&(0,e.createVNode)(1,"li","color-good","Systems Nominal",16),m.map(function(s){return(0,e.createVNode)(1,"li","color-average",s,0,null,s)})],0)}),(0,e.createComponentVNode)(2,t.Section,{title:"Atmospherics Alarms",children:(0,e.createVNode)(1,"ul",null,[l.length===0&&(0,e.createVNode)(1,"li","color-good","Systems Nominal",16),l.map(function(s){return(0,e.createVNode)(1,"li","color-average",s,0,null,s)})],0)}),(0,e.createComponentVNode)(2,t.Section,{title:"Power Alarms",children:(0,e.createVNode)(1,"ul",null,[u.length===0&&(0,e.createVNode)(1,"li","color-good","Systems Nominal",16),u.map(function(s){return(0,e.createVNode)(1,"li","color-average",s,0,null,s)})],0)})],4)}return y}()},96091:function(T,r,n){"use strict";r.__esModule=!0,r.StationTraitsPanel=void 0;var e=n(89005),a=n(88510),t=n(42127),o=n(72253),p=n(36036),b=n(98595),y=function(i){return i[i.SetupFutureStationTraits=0]="SetupFutureStationTraits",i[i.ViewStationTraits=1]="ViewStationTraits",i}(y||{}),S=function(c,m){var l=(0,o.useBackend)(m),u=l.act,s=l.data,d=s.future_station_traits,C=(0,o.useLocalState)(m,"selectedFutureTrait",null),g=C[0],v=C[1],f=Object.fromEntries(s.valid_station_traits.map(function(V){return[V.name,V.path]})),N=Object.keys(f);return N.sort(),(0,e.createComponentVNode)(2,p.Box,{children:[(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,p.Dropdown,{displayText:!g&&"Select trait to add...",onSelected:v,options:N,selected:g,width:"100%"})}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button,{color:"green",icon:"plus",onClick:function(){function V(){if(g){var B=f[g],I=[B];if(d){var L,w=d.map(function(A){return A.path});if(w.indexOf(B)!==-1)return;I=(L=I).concat.apply(L,w)}u("setup_future_traits",{station_traits:I})}}return V}(),children:"Add"})})]}),(0,e.createComponentVNode)(2,p.Divider),Array.isArray(d)?d.length>0?(0,e.createComponentVNode)(2,p.Stack,{vertical:!0,fill:!0,children:d.map(function(V){return(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:V.name}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button,{color:"red",icon:"times",onClick:function(){function B(){u("setup_future_traits",{station_traits:(0,a.filterMap)(d,function(I){if(I.path!==V.path)return I.path})})}return B}(),children:"Delete"})})]})},V.path)})}):(0,e.createComponentVNode)(2,p.Box,{textAlign:"center",children:[(0,e.createComponentVNode)(2,p.Box,{children:"No station traits will run next round."}),(0,e.createComponentVNode)(2,p.Button,{mt:1,fluid:!0,color:"good",icon:"times",tooltip:"The next round will roll station traits randomly, just like normal",onClick:function(){function V(){return u("clear_future_traits")}return V}(),children:"Run Station Traits Normally"})]}):(0,e.createComponentVNode)(2,p.Box,{textAlign:"center",children:[(0,e.createComponentVNode)(2,p.Box,{children:"No future station traits are planned."}),(0,e.createComponentVNode)(2,p.Button,{mt:1,fluid:!0,color:"red",icon:"times",onClick:function(){function V(){return u("setup_future_traits",{station_traits:[]})}return V}(),children:"Prevent station traits from running next round"})]})]})},k=function(c,m){var l=(0,o.useBackend)(m),u=l.act,s=l.data;return s.current_traits.length>0?(0,e.createComponentVNode)(2,p.Stack,{vertical:!0,fill:!0,children:s.current_traits.map(function(d){return(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{grow:!0,children:d.name}),(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Button.Confirm,{content:"Revert",color:"red",disabled:s.too_late_to_revert||!d.can_revert,tooltip:!d.can_revert&&"This trait is not revertable."||s.too_late_to_revert&&"It's too late to revert station traits, the round has already started.",icon:"times",onClick:function(){function C(){return u("revert",{ref:d.ref})}return C}()})})]})},d.ref)})}):(0,e.createComponentVNode)(2,p.Box,{textAlign:"center",children:"There are no active station traits."})},h=r.StationTraitsPanel=function(){function i(c,m){var l=(0,o.useLocalState)(m,"station_traits_tab",y.ViewStationTraits),u=l[0],s=l[1],d;switch(u){case y.SetupFutureStationTraits:d=(0,e.createComponentVNode)(2,S);break;case y.ViewStationTraits:d=(0,e.createComponentVNode)(2,k);break;default:(0,t.exhaustiveCheck)(u)}return(0,e.createComponentVNode)(2,b.Window,{title:"Modify Station Traits",height:350,width:350,children:(0,e.createComponentVNode)(2,b.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,p.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,p.Stack.Item,{children:(0,e.createComponentVNode)(2,p.Tabs,{children:[(0,e.createComponentVNode)(2,p.Tabs.Tab,{icon:"eye",selected:u===y.ViewStationTraits,onClick:function(){function C(){return s(y.ViewStationTraits)}return C}(),children:"View"}),(0,e.createComponentVNode)(2,p.Tabs.Tab,{icon:"edit",selected:u===y.SetupFutureStationTraits,onClick:function(){function C(){return s(y.SetupFutureStationTraits)}return C}(),children:"Edit"})]})}),(0,e.createComponentVNode)(2,p.Stack.Item,{m:0,children:[(0,e.createComponentVNode)(2,p.Divider),d]})]})})})}return i}()},39409:function(T,r,n){"use strict";r.__esModule=!0,r.StripMenu=void 0;var e=n(89005),a=n(88510),t=n(79140),o=n(72253),p=n(36036),b=n(98595),y=5,S=9,k=function(g){return g===0?5:9},h="64px",i=function(g){return g[0]+"/"+g[1]},c=function(g){var v=g.align,f=g.children;return(0,e.createComponentVNode)(2,p.Box,{style:{position:"absolute",left:v==="left"?"6px":"48px","text-align":v,"text-shadow":"2px 2px 2px #000",top:"2px"},children:f})},m={enable_internals:{icon:"lungs",text:"Enable internals"},disable_internals:{icon:"lungs",text:"Disable internals"},enable_lock:{icon:"lock",text:"Enable lock"},disable_lock:{icon:"unlock",text:"Disable lock"},suit_sensors:{icon:"tshirt",text:"Adjust suit sensors"},remove_accessory:{icon:"medal",text:"Remove accessory"},dislodge_headpocket:{icon:"head-side-virus",text:"Dislodge headpocket"}},l={eyes:{displayName:"eyewear",gridSpot:i([0,0]),image:"inventory-glasses.png"},head:{displayName:"headwear",gridSpot:i([0,1]),image:"inventory-head.png"},mask:{displayName:"mask",gridSpot:i([1,1]),image:"inventory-mask.png"},neck:{displayName:"neck",gridSpot:i([1,0]),image:"inventory-neck.png"},pet_collar:{displayName:"collar",gridSpot:i([1,1]),image:"inventory-collar.png"},right_ear:{displayName:"right ear",gridSpot:i([0,2]),image:"inventory-ears.png"},left_ear:{displayName:"left ear",gridSpot:i([1,2]),image:"inventory-ears.png"},parrot_headset:{displayName:"headset",gridSpot:i([1,2]),image:"inventory-ears.png"},handcuffs:{displayName:"handcuffs",gridSpot:i([1,3])},legcuffs:{displayName:"legcuffs",gridSpot:i([1,4])},jumpsuit:{displayName:"uniform",gridSpot:i([2,0]),image:"inventory-uniform.png"},suit:{displayName:"suit",gridSpot:i([2,1]),image:"inventory-suit.png"},gloves:{displayName:"gloves",gridSpot:i([2,2]),image:"inventory-gloves.png"},right_hand:{displayName:"right hand",gridSpot:i([2,3]),image:"inventory-hand_r.png",additionalComponent:(0,e.createComponentVNode)(2,c,{align:"left",children:"R"})},left_hand:{displayName:"left hand",gridSpot:i([2,4]),image:"inventory-hand_l.png",additionalComponent:(0,e.createComponentVNode)(2,c,{align:"right",children:"L"})},shoes:{displayName:"shoes",gridSpot:i([3,1]),image:"inventory-shoes.png"},suit_storage:{displayName:"suit storage",gridSpot:i([4,0]),image:"inventory-suit_storage.png"},id:{displayName:"ID",gridSpot:i([4,1]),image:"inventory-id.png"},belt:{displayName:"belt",gridSpot:i([4,2]),image:"inventory-belt.png"},back:{displayName:"backpack",gridSpot:i([4,3]),image:"inventory-back.png"},left_pocket:{displayName:"left pocket",gridSpot:i([3,4]),image:"inventory-pocket.png"},right_pocket:{displayName:"right pocket",gridSpot:i([3,3]),image:"inventory-pocket.png"},pda:{displayName:"PDA",gridSpot:i([4,4]),image:"inventory-pda.png"}},u={eyes:{displayName:"eyewear",gridSpot:i([0,0]),image:"inventory-glasses.png"},head:{displayName:"headwear",gridSpot:i([0,1]),image:"inventory-head.png"},mask:{displayName:"mask",gridSpot:i([1,1]),image:"inventory-mask.png"},neck:{displayName:"neck",gridSpot:i([1,0]),image:"inventory-neck.png"},pet_collar:{displayName:"collar",gridSpot:i([1,1]),image:"inventory-collar.png"},right_ear:{displayName:"right ear",gridSpot:i([0,2]),image:"inventory-ears.png"},left_ear:{displayName:"left ear",gridSpot:i([1,2]),image:"inventory-ears.png"},parrot_headset:{displayName:"headset",gridSpot:i([1,2]),image:"inventory-ears.png"},handcuffs:{displayName:"handcuffs",gridSpot:i([1,3])},legcuffs:{displayName:"legcuffs",gridSpot:i([1,4])},jumpsuit:{displayName:"uniform",gridSpot:i([2,0]),image:"inventory-uniform.png"},suit:{displayName:"suit",gridSpot:i([2,1]),image:"inventory-suit.png"},gloves:{displayName:"gloves",gridSpot:i([2,2]),image:"inventory-gloves.png"},right_hand:{displayName:"right hand",gridSpot:i([4,4]),image:"inventory-hand_r.png",additionalComponent:(0,e.createComponentVNode)(2,c,{align:"left",children:"R"})},left_hand:{displayName:"left hand",gridSpot:i([4,5]),image:"inventory-hand_l.png",additionalComponent:(0,e.createComponentVNode)(2,c,{align:"right",children:"L"})},shoes:{displayName:"shoes",gridSpot:i([3,1]),image:"inventory-shoes.png"},suit_storage:{displayName:"suit storage",gridSpot:i([4,0]),image:"inventory-suit_storage.png"},id:{displayName:"ID",gridSpot:i([4,1]),image:"inventory-id.png"},belt:{displayName:"belt",gridSpot:i([4,2]),image:"inventory-belt.png"},back:{displayName:"backpack",gridSpot:i([4,3]),image:"inventory-back.png"},left_pocket:{displayName:"left pocket",gridSpot:i([4,7]),image:"inventory-pocket.png"},right_pocket:{displayName:"right pocket",gridSpot:i([4,6]),image:"inventory-pocket.png"},pda:{displayName:"PDA",gridSpot:i([4,8]),image:"inventory-pda.png"}},s=function(C){return C[C.Completely=1]="Completely",C[C.Hidden=2]="Hidden",C}(s||{}),d=r.StripMenu=function(){function C(g,v){var f=(0,o.useBackend)(v),N=f.act,V=f.data,B=new Map;if(V.show_mode===0)for(var I=0,L=Object.keys(V.items);I=.01})},(0,a.sortBy)(function(w){return-w.amount})])(g.gases||[]),L=Math.max.apply(Math,[1].concat(I.map(function(w){return w.amount})));return(0,e.createComponentVNode)(2,S.Window,{width:550,height:185,children:(0,e.createComponentVNode)(2,S.Window.Content,{children:(0,e.createComponentVNode)(2,b.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{width:"270px",children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Metrics",children:(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Integrity",children:(0,e.createComponentVNode)(2,b.ProgressBar,{value:f/100,ranges:{good:[.9,1/0],average:[.5,.9],bad:[-1/0,.5]}})}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Relative EER",children:(0,e.createComponentVNode)(2,b.ProgressBar,{value:N,minValue:0,maxValue:5e3,ranges:{good:[-1/0,5e3],average:[5e3,7e3],bad:[7e3,1/0]},children:(0,o.toFixed)(N)+" MeV/cm3"})}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Temperature",children:(0,e.createComponentVNode)(2,b.ProgressBar,{value:i(V),minValue:0,maxValue:i(1e4),ranges:{teal:[-1/0,i(80)],good:[i(80),i(373)],average:[i(373),i(1e3)],bad:[i(1e3),1/0]},children:(0,o.toFixed)(V)+" K"})}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Pressure",children:(0,e.createComponentVNode)(2,b.ProgressBar,{value:i(B),minValue:0,maxValue:i(5e4),ranges:{good:[i(1),i(300)],average:[-1/0,i(1e3)],bad:[i(1e3),1/0]},children:(0,o.toFixed)(B)+" kPa"})})]})})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,basis:0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Gases",buttons:(0,e.createComponentVNode)(2,b.Button,{icon:"arrow-left",content:"Back",onClick:function(){function w(){return C("back")}return w}()}),children:(0,e.createComponentVNode)(2,b.LabeledList,{children:I.map(function(w){return(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:(0,y.getGasLabel)(w.name),children:(0,e.createComponentVNode)(2,b.ProgressBar,{color:(0,y.getGasColor)(w.name),value:w.amount,minValue:0,maxValue:L,children:(0,o.toFixed)(w.amount,2)+"%"})},w.name)})})})})]})})})}},46029:function(T,r,n){"use strict";r.__esModule=!0,r.SyndicateComputerSimple=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.SyndicateComputerSimple=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data;return(0,e.createComponentVNode)(2,o.Window,{theme:"syndicate",width:400,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:i.rows.map(function(c){return(0,e.createComponentVNode)(2,t.Section,{title:c.title,buttons:(0,e.createComponentVNode)(2,t.Button,{content:c.buttontitle,disabled:c.buttondisabled,tooltip:c.buttontooltip,tooltipPosition:"left",onClick:function(){function m(){return h(c.buttonact)}return m}()}),children:[c.status,!!c.bullets&&(0,e.createComponentVNode)(2,t.Box,{children:c.bullets.map(function(m){return(0,e.createComponentVNode)(2,t.Box,{children:m},m)})})]},c.title)})})})}return b}()},36372:function(T,r,n){"use strict";r.__esModule=!0,r.TEG=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(S){return S.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,")},b=r.TEG=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data;return c.error?(0,e.createComponentVNode)(2,o.Window,{width:500,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Error",children:[c.error,(0,e.createComponentVNode)(2,t.Button,{icon:"circle",content:"Recheck",onClick:function(){function m(){return i("check")}return m}()})]})})}):(0,e.createComponentVNode)(2,o.Window,{width:500,height:400,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Cold Loop ("+c.cold_dir+")",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cold Inlet",children:[p(c.cold_inlet_temp)," K, ",p(c.cold_inlet_pressure)," kPa"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cold Outlet",children:[p(c.cold_outlet_temp)," K, ",p(c.cold_outlet_pressure)," kPa"]})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Hot Loop ("+c.hot_dir+")",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hot Inlet",children:[p(c.hot_inlet_temp)," K, ",p(c.hot_inlet_pressure)," kPa"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hot Outlet",children:[p(c.hot_outlet_temp)," K, ",p(c.hot_outlet_pressure)," kPa"]})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Power Output",children:[p(c.output_power)," W",!!c.warning_switched&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Warning: Cold inlet temperature exceeds hot inlet temperature."}),!!c.warning_cold_pressure&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Warning: Cold circulator inlet pressure is under 1,000 kPa."}),!!c.warning_hot_pressure&&(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Warning: Hot circulator inlet pressure is under 1,000 kPa."})]})]})})}return y}()},56441:function(T,r,n){"use strict";r.__esModule=!0,r.TachyonArrayContent=r.TachyonArray=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TachyonArray=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.records,l=m===void 0?[]:m,u=c.explosion_target,s=c.toxins_tech,d=c.printing;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:600,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Shift's Target",children:u}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Toxins Level",children:s}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Administration",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"print",content:"Print All Logs",disabled:!l.length||d,align:"center",onClick:function(){function C(){return i("print_logs")}return C}()}),(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"trash",content:"Delete All Logs",disabled:!l.length,color:"bad",align:"center",onClick:function(){function C(){return i("delete_logs")}return C}()})]})]})}),l.length?(0,e.createComponentVNode)(2,b):(0,e.createComponentVNode)(2,t.NoticeBox,{children:"No Records"})]})})}return y}(),b=r.TachyonArrayContent=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.records,l=m===void 0?[]:m;return(0,e.createComponentVNode)(2,t.Section,{title:"Logged Explosions",children:(0,e.createComponentVNode)(2,t.Flex,{children:(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Time"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Epicenter"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Actual Size"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Theoretical Size"})]}),l.map(function(u){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.logged_time}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.epicenter}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.actual_size_message}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.theoretical_size_message}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button.Confirm,{icon:"trash",content:"Delete",color:"bad",onClick:function(){function s(){return i("delete_record",{index:u.index})}return s}()})})]},u.index)})]})})})})}return y}()},1754:function(T,r,n){"use strict";r.__esModule=!0,r.Tank=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Tank=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c;return i.has_mask?c=(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mask",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,width:"76%",icon:i.connected?"check":"times",content:i.connected?"Internals On":"Internals Off",selected:i.connected,onClick:function(){function m(){return h("internals")}return m}()})}):c=(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mask",color:"red",children:"No Mask Equipped"}),(0,e.createComponentVNode)(2,o.Window,{width:325,height:135,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Tank Pressure",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:i.tankPressure/1013,ranges:{good:[.35,1/0],average:[.15,.35],bad:[-1/0,.15]},children:i.tankPressure+" kPa"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Release Pressure",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"fast-backward",disabled:i.ReleasePressure===i.minReleasePressure,tooltip:"Min",onClick:function(){function m(){return h("pressure",{pressure:"min"})}return m}()}),(0,e.createComponentVNode)(2,t.NumberInput,{animated:!0,value:parseFloat(i.releasePressure),width:"65px",unit:"kPa",minValue:i.minReleasePressure,maxValue:i.maxReleasePressure,onChange:function(){function m(l,u){return h("pressure",{pressure:u})}return m}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"fast-forward",disabled:i.ReleasePressure===i.maxReleasePressure,tooltip:"Max",onClick:function(){function m(){return h("pressure",{pressure:"max"})}return m}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"undo",content:"",disabled:i.ReleasePressure===i.defaultReleasePressure,tooltip:"Reset",onClick:function(){function m(){return h("pressure",{pressure:"reset"})}return m}()})]}),c]})})})})}return b}()},7579:function(T,r,n){"use strict";r.__esModule=!0,r.TankDispenser=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TankDispenser=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.o_tanks,m=i.p_tanks;return(0,e.createComponentVNode)(2,o.Window,{width:250,height:105,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:"Dispense Oxygen Tank ("+c+")",disabled:c===0,icon:"arrow-circle-down",onClick:function(){function l(){return h("oxygen")}return l}()})}),(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{mt:1,fluid:!0,content:"Dispense Plasma Tank ("+m+")",disabled:m===0,icon:"arrow-circle-down",onClick:function(){function l(){return h("plasma")}return l}()})})]})})})}return b}()},16136:function(T,r,n){"use strict";r.__esModule=!0,r.TcommsCore=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TcommsCore=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.ion,d=(0,a.useLocalState)(c,"tabIndex",0),C=d[0],g=d[1],v=function(){function f(N){switch(N){case 0:return(0,e.createComponentVNode)(2,y);case 1:return(0,e.createComponentVNode)(2,S);case 2:return(0,e.createComponentVNode)(2,k);default:return"SOMETHING WENT VERY WRONG PLEASE AHELP"}}return f}();return(0,e.createComponentVNode)(2,o.Window,{width:900,height:520,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[s===1&&(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,t.Tabs,{children:[(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"wrench",selected:C===0,onClick:function(){function f(){return g(0)}return f}(),children:"Configuration"},"ConfigPage"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"link",selected:C===1,onClick:function(){function f(){return g(1)}return f}(),children:"Device Linkage"},"LinkagePage"),(0,e.createComponentVNode)(2,t.Tabs.Tab,{icon:"user-times",selected:C===2,onClick:function(){function f(){return g(2)}return f}(),children:"User Filtering"},"FilterPage")]}),v(C)]})})}return h}(),b=function(){return(0,e.createComponentVNode)(2,t.NoticeBox,{children:"ERROR: An Ionospheric overload has occured. Please wait for the machine to reboot. This cannot be manually done."})},y=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.active,d=u.sectors_available,C=u.nttc_toggle_jobs,g=u.nttc_toggle_job_color,v=u.nttc_toggle_name_color,f=u.nttc_toggle_command_bold,N=u.nttc_job_indicator_type,V=u.nttc_setting_language,B=u.network_id;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{title:"Status",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Machine Power",children:(0,e.createComponentVNode)(2,t.Button,{content:s?"On":"Off",selected:s,icon:"power-off",onClick:function(){function I(){return l("toggle_active")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Sector Coverage",children:d})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Radio Configuration",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Job Announcements",children:(0,e.createComponentVNode)(2,t.Button,{content:C?"On":"Off",selected:C,icon:"user-tag",onClick:function(){function I(){return l("nttc_toggle_jobs")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Job Departmentalisation",children:(0,e.createComponentVNode)(2,t.Button,{content:g?"On":"Off",selected:g,icon:"clipboard-list",onClick:function(){function I(){return l("nttc_toggle_job_color")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Name Departmentalisation",children:(0,e.createComponentVNode)(2,t.Button,{content:v?"On":"Off",selected:v,icon:"user-tag",onClick:function(){function I(){return l("nttc_toggle_name_color")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Command Amplification",children:(0,e.createComponentVNode)(2,t.Button,{content:f?"On":"Off",selected:f,icon:"volume-up",onClick:function(){function I(){return l("nttc_toggle_command_bold")}return I}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Advanced",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Job Announcement Format",children:(0,e.createComponentVNode)(2,t.Button,{content:N||"Unset",selected:N,icon:"pencil-alt",onClick:function(){function I(){return l("nttc_job_indicator_type")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Language Conversion",children:(0,e.createComponentVNode)(2,t.Button,{content:V||"Unset",selected:V,icon:"globe",onClick:function(){function I(){return l("nttc_setting_language")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Network ID",children:(0,e.createComponentVNode)(2,t.Button,{content:B||"Unset",selected:B,icon:"server",onClick:function(){function I(){return l("network_id")}return I}()})})]})}),(0,e.createComponentVNode)(2,t.Section,{title:"Maintenance",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Import Configuration",icon:"file-import",onClick:function(){function I(){return l("import")}return I}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Export Configuration",icon:"file-export",onClick:function(){function I(){return l("export")}return I}()})]})],4)},S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.link_password,d=u.relay_entries;return(0,e.createComponentVNode)(2,t.Section,{title:"Device Linkage",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Linkage Password",children:(0,e.createComponentVNode)(2,t.Button,{content:s||"Unset",selected:s,icon:"lock",onClick:function(){function C(){return l("change_password")}return C}()})})}),(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Sector"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Status"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Unlink"})]}),d.map(function(C){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:C.addr}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:C.net_id}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:C.sector}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:C.status===1?(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Online"}):(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Offline"})}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Unlink",icon:"unlink",onClick:function(){function g(){return l("unlink",{addr:C.addr})}return g}()})})]},C.addr)})]})]})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.filtered_users;return(0,e.createComponentVNode)(2,t.Section,{title:"User Filtering",buttons:(0,e.createComponentVNode)(2,t.Button,{content:"Add User",icon:"user-plus",onClick:function(){function d(){return l("add_filter")}return d}()}),children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{style:{width:"90%"},children:"User"}),(0,e.createComponentVNode)(2,t.Table.Cell,{style:{width:"10%"},children:"Actions"})]}),s.map(function(d){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:d}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Remove",icon:"user-times",onClick:function(){function C(){return l("remove_filter",{user:d})}return C}()})})]},d)})]})})}},88046:function(T,r,n){"use strict";r.__esModule=!0,r.TcommsRelay=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TcommsRelay=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.linked,u=m.active,s=m.network_id;return(0,e.createComponentVNode)(2,o.Window,{width:600,height:292,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Relay Configuration",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Machine Power",children:(0,e.createComponentVNode)(2,t.Button,{content:u?"On":"Off",selected:u,icon:"power-off",onClick:function(){function d(){return c("toggle_active")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Network ID",children:(0,e.createComponentVNode)(2,t.Button,{content:s||"Unset",selected:s,icon:"server",onClick:function(){function d(){return c("network_id")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Link Status",children:l===1?(0,e.createComponentVNode)(2,t.Box,{color:"green",children:"Linked"}):(0,e.createComponentVNode)(2,t.Box,{color:"red",children:"Unlinked"})})]})}),l===1?(0,e.createComponentVNode)(2,b):(0,e.createComponentVNode)(2,y)]})})}return S}(),b=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.linked_core_id,u=m.linked_core_addr,s=m.hidden_link;return(0,e.createComponentVNode)(2,t.Section,{title:"Link Status",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Linked Core ID",children:l}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Linked Core Address",children:u}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hidden Link",children:(0,e.createComponentVNode)(2,t.Button,{content:s?"Yes":"No",icon:s?"eye-slash":"eye",selected:s,onClick:function(){function d(){return c("toggle_hidden_link")}return d}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Unlink",children:(0,e.createComponentVNode)(2,t.Button,{content:"Unlink",icon:"unlink",color:"red",onClick:function(){function d(){return c("unlink")}return d}()})})]})})},y=function(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.cores;return(0,e.createComponentVNode)(2,t.Section,{title:"Detected Cores",children:(0,e.createComponentVNode)(2,t.Table,{m:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network Address"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Network ID"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Sector"}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:"Link"})]}),l.map(function(u){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.addr}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.net_id}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:u.sector}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{content:"Link",icon:"link",onClick:function(){function s(){return c("link",{addr:u.addr})}return s}()})})]},u.addr)})]})})}},20802:function(T,r,n){"use strict";r.__esModule=!0,r.Teleporter=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Teleporter=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.targetsTeleport?i.targetsTeleport:{},m=0,l=1,u=2,s=i.calibrated,d=i.calibrating,C=i.powerstation,g=i.regime,v=i.teleporterhub,f=i.target,N=i.locked,V=i.adv_beacon_allowed,B=i.advanced_beacon_locking;return(0,e.createComponentVNode)(2,o.Window,{width:350,height:270,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:[(!C||!v)&&(0,e.createComponentVNode)(2,t.Section,{fill:!0,title:"Error",children:[v,!C&&(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:" Powerstation not linked "}),C&&!v&&(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:" Teleporter hub not linked "})]}),C&&v&&(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Status",buttons:(0,e.createFragment)(!!V&&(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{inline:!0,color:"label",children:"Advanced Beacon Locking:\xA0"}),(0,e.createComponentVNode)(2,t.Button,{selected:B,icon:B?"toggle-on":"toggle-off",content:B?"Enabled":"Disabled",onClick:function(){function I(){return h("advanced_beacon_locking",{on:B?0:1})}return I}()})],4),0),children:[(0,e.createComponentVNode)(2,t.Stack,{mb:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:8.5,color:"label",children:"Teleport target:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[g===m&&(0,e.createComponentVNode)(2,t.Dropdown,{width:18.2,selected:f,disabled:d,options:Object.keys(c),color:f!=="None"?"default":"bad",onSelected:function(){function I(L){return h("settarget",{x:c[L].x,y:c[L].y,z:c[L].z,tptarget:c[L].pretarget})}return I}()}),g===l&&(0,e.createComponentVNode)(2,t.Dropdown,{width:18.2,selected:f,disabled:d,options:Object.keys(c),color:f!=="None"?"default":"bad",onSelected:function(){function I(L){return h("settarget",{x:c[L].x,y:c[L].y,z:c[L].z,tptarget:c[L].pretarget})}return I}()}),g===u&&(0,e.createComponentVNode)(2,t.Box,{children:f})]})]}),(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:8.5,color:"label",children:"Regime:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:"Gate",tooltip:"Teleport to another teleport hub.",tooltipPosition:"top",color:g===l?"good":null,onClick:function(){function I(){return h("setregime",{regime:l})}return I}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:"Teleporter",tooltip:"One-way teleport.",tooltipPosition:"top",color:g===m?"good":null,onClick:function(){function I(){return h("setregime",{regime:m})}return I}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,content:"GPS",tooltip:"Teleport to a location stored in a GPS device.",tooltipPosition:"top-end",color:g===u?"good":null,disabled:!N,onClick:function(){function I(){return h("setregime",{regime:u})}return I}()})})]}),(0,e.createComponentVNode)(2,t.Stack,{label:"Calibration",mt:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:8.5,color:"label",children:"Calibration:"}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[f!=="None"&&(0,e.createComponentVNode)(2,t.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{width:15.8,textAlign:"center",mt:.5,children:d&&(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"In Progress"})||s&&(0,e.createComponentVNode)(2,t.Box,{color:"good",children:"Optimal"})||(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"Sub-Optimal"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button,{icon:"sync-alt",tooltip:"Calibrates the hub. Accidents may occur when the calibration is not optimal.",tooltipPosition:"bottom-end",disabled:!!(s||d),onClick:function(){function I(){return h("calibrate")}return I}()})})]}),f==="None"&&(0,e.createComponentVNode)(2,t.Box,{lineHeight:"21px",children:"No target set"})]})]})]}),!!(N&&C&&v&&g===u)&&(0,e.createComponentVNode)(2,t.Section,{title:"GPS",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Button,{content:"Upload GPS data",tooltip:"Loads the GPS data from the device.",icon:"upload",onClick:function(){function I(){return h("load")}return I}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Eject",tooltip:"Ejects the GPS device",icon:"eject",onClick:function(){function I(){return h("eject")}return I}()})]})})]})})})})}return b}()},48517:function(T,r,n){"use strict";r.__esModule=!0,r.TelescienceConsole=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TelescienceConsole=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.last_msg,m=i.linked_pad,l=i.held_gps,u=i.lastdata,s=i.power_levels,d=i.current_max_power,C=i.current_power,g=i.current_bearing,v=i.current_elevation,f=i.current_sector,N=i.working,V=i.max_z,B=(0,a.useLocalState)(S,"dummyrot",g),I=B[0],L=B[1];return(0,e.createComponentVNode)(2,o.Window,{width:400,height:500,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:[(0,e.createComponentVNode)(2,t.Section,{title:"Status",children:(0,e.createFragment)([c,!(u.length>0)||(0,e.createVNode)(1,"ul",null,u.map(function(w){return(0,e.createVNode)(1,"li",null,w,0,null,w)}),0)],0)}),(0,e.createComponentVNode)(2,t.Section,{title:"Telepad Status",children:m===1?(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Bearing",children:(0,e.createComponentVNode)(2,t.Box,{inline:!0,position:"relative",children:[(0,e.createComponentVNode)(2,t.NumberInput,{unit:"\xB0",width:6.1,lineHeight:1.5,step:.1,minValue:0,maxValue:360,disabled:N,value:g,onDrag:function(){function w(A,x){return L(x)}return w}(),onChange:function(){function w(A,x){return h("setbear",{bear:x})}return w}()}),(0,e.createComponentVNode)(2,t.Icon,{ml:1,size:1,name:"arrow-up",rotation:I})]})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Elevation",children:(0,e.createComponentVNode)(2,t.NumberInput,{width:6.1,lineHeight:1.5,step:.1,minValue:0,maxValue:100,disabled:N,value:v,onChange:function(){function w(A,x){return h("setelev",{elev:x})}return w}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power Level",children:s.map(function(w,A){return(0,e.createComponentVNode)(2,t.Button,{content:w,selected:C===w,disabled:A>=d-1||N,onClick:function(){function x(){return h("setpwr",{pwr:A+1})}return x}()},w)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Target Sector",children:(0,e.createComponentVNode)(2,t.NumberInput,{width:6.1,lineHeight:1.5,step:1,minValue:2,maxValue:V,value:f,disabled:N,onChange:function(){function w(A,x){return h("setz",{newz:x})}return w}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Telepad Actions",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Send",disabled:N,onClick:function(){function w(){return h("pad_send")}return w}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Receive",disabled:N,onClick:function(){function w(){return h("pad_receive")}return w}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Crystal Maintenance",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Recalibrate Crystals",disabled:N,onClick:function(){function w(){return h("recal_crystals")}return w}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Eject Crystals",disabled:N,onClick:function(){function w(){return h("eject_crystals")}return w}()})]})]}):(0,e.createFragment)([(0,e.createTextVNode)("No pad linked to console. Please use a multitool to link a pad.")],4)}),(0,e.createComponentVNode)(2,t.Section,{title:"GPS Actions",children:l===1?(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{disabled:l===0||N,content:"Eject GPS",onClick:function(){function w(){return h("eject_gps")}return w}()}),(0,e.createComponentVNode)(2,t.Button,{disabled:l===0||N,content:"Store Coordinates",onClick:function(){function w(){return h("store_to_gps")}return w}()})],4):(0,e.createFragment)([(0,e.createTextVNode)("Please insert a GPS to store coordinates to it.")],4)})]})})}return b}()},21800:function(T,r,n){"use strict";r.__esModule=!0,r.TempGun=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.TempGun=function(){function h(i,c){var m=(0,t.useBackend)(c),l=m.act,u=m.data,s=u.target_temperature,d=u.temperature,C=u.max_temp,g=u.min_temp;return(0,e.createComponentVNode)(2,p.Window,{width:250,height:121,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Target Temperature",children:[(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:10,stepPixelSize:6,minValue:g,maxValue:C,value:s,format:function(){function v(f){return(0,a.toFixed)(f,2)}return v}(),width:"50px",onDrag:function(){function v(f,N){return l("target_temperature",{target_temperature:N})}return v}()}),"\xB0C"]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Current Temperature",children:(0,e.createComponentVNode)(2,o.Box,{color:y(d),bold:d>500-273.15,children:[(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:(0,a.round)(d,2)}),"\xB0C"]})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Power Cost",children:(0,e.createComponentVNode)(2,o.Box,{color:k(d),children:S(d)})})]})})})})}return h}(),y=function(i){return i<=-100?"blue":i<=0?"teal":i<=100?"green":i<=200?"orange":"red"},S=function(i){return i<=100-273.15?"High":i<=250-273.15?"Medium":i<=300-273.15?"Low":i<=400-273.15?"Medium":"High"},k=function(i){return i<=100-273.15?"red":i<=250-273.15?"orange":i<=300-273.15?"green":i<=400-273.15?"orange":"red"}},24410:function(T,r,n){"use strict";r.__esModule=!0,r.sanitizeMultiline=r.removeAllSkiplines=r.TextInputModal=void 0;var e=n(89005),a=n(51057),t=n(19203),o=n(72253),p=n(92986),b=n(36036),y=n(98595),S=r.sanitizeMultiline=function(){function c(m){return m.replace(/(\n|\r\n){3,}/,"\n\n")}return c}(),k=r.removeAllSkiplines=function(){function c(m){return m.replace(/[\r\n]+/,"")}return c}(),h=r.TextInputModal=function(){function c(m,l){var u=(0,o.useBackend)(l),s=u.act,d=u.data,C=d.max_length,g=d.message,v=g===void 0?"":g,f=d.multiline,N=d.placeholder,V=d.timeout,B=d.title,I=(0,o.useLocalState)(l,"input",N||""),L=I[0],w=I[1],A=function(){function P(D){if(D!==L){var M=f?S(D):k(D);w(M)}}return P}(),x=f||L.length>=40,E=130+(v.length>40?Math.ceil(v.length/4):0)+(x?80:0);return(0,e.createComponentVNode)(2,y.Window,{title:B,width:325,height:E,children:[V&&(0,e.createComponentVNode)(2,a.Loader,{value:V}),(0,e.createComponentVNode)(2,y.Window.Content,{onKeyDown:function(){function P(D){var M=window.event?D.which:D.keyCode;M===p.KEY_ENTER&&(!x||!D.shiftKey)&&s("submit",{entry:L}),M===p.KEY_ESCAPE&&s("cancel")}return P}(),children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,children:(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Box,{color:"label",children:v})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,i,{input:L,onType:A})}),(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,t.InputButtons,{input:L,message:L.length+"/"+C})})]})})})]})}return c}(),i=function(m,l){var u=(0,o.useBackend)(l),s=u.act,d=u.data,C=d.max_length,g=d.multiline,v=m.input,f=m.onType,N=g||v.length>=40;return(0,e.createComponentVNode)(2,b.TextArea,{autoFocus:!0,autoSelect:!0,height:g||v.length>=40?"100%":"1.8rem",maxLength:C,onEscape:function(){function V(){return s("cancel")}return V}(),onEnter:function(){function V(B){N&&B.shiftKey||(B.preventDefault(),s("submit",{entry:v}))}return V}(),onInput:function(){function V(B,I){return f(I)}return V}(),placeholder:"Type something...",value:v})}},25036:function(T,r,n){"use strict";r.__esModule=!0,r.ThermoMachine=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=n(98595),b=r.ThermoMachine=function(){function y(S,k){var h=(0,t.useBackend)(k),i=h.act,c=h.data;return(0,e.createComponentVNode)(2,p.Window,{width:300,height:225,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:[(0,e.createComponentVNode)(2,o.Section,{title:"Status",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Temperature",children:[(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:c.temperature,format:function(){function m(l){return(0,a.toFixed)(l,2)}return m}()})," K"]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Pressure",children:[(0,e.createComponentVNode)(2,o.AnimatedNumber,{value:c.pressure,format:function(){function m(l){return(0,a.toFixed)(l,2)}return m}()})," kPa"]})]})}),(0,e.createComponentVNode)(2,o.Section,{title:"Controls",buttons:(0,e.createComponentVNode)(2,o.Button,{icon:c.on?"power-off":"times",content:c.on?"On":"Off",selected:c.on,onClick:function(){function m(){return i("power")}return m}()}),children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Setting",textAlign:"center",children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,icon:c.cooling?"temperature-low":"temperature-high",content:c.cooling?"Cooling":"Heating",selected:c.cooling,onClick:function(){function m(){return i("cooling")}return m}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Target Temperature",children:[(0,e.createComponentVNode)(2,o.Button,{icon:"fast-backward",disabled:c.target===c.min,title:"Minimum temperature",onClick:function(){function m(){return i("target",{target:c.min})}return m}()}),(0,e.createComponentVNode)(2,o.NumberInput,{animated:!0,value:Math.round(c.target),unit:"K",width:5.4,lineHeight:1.4,minValue:Math.round(c.min),maxValue:Math.round(c.max),step:5,stepPixelSize:3,onDrag:function(){function m(l,u){return i("target",{target:u})}return m}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"fast-forward",disabled:c.target===c.max,title:"Maximum Temperature",onClick:function(){function m(){return i("target",{target:c.max})}return m}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"sync",disabled:c.target===c.initial,title:"Room Temperature",onClick:function(){function m(){return i("target",{target:c.initial})}return m}()})]})]})})]})})}return y}()},20035:function(T,r,n){"use strict";r.__esModule=!0,r.TransferValve=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.TransferValve=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.tank_one,m=i.tank_two,l=i.attached_device,u=i.valve;return(0,e.createComponentVNode)(2,o.Window,{width:460,height:285,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Valve Status",children:(0,e.createComponentVNode)(2,t.Button,{icon:u?"unlock":"lock",content:u?"Open":"Closed",disabled:!c||!m,onClick:function(){function s(){return h("toggle")}return s}()})})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Assembly",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"cog",content:"Configure Assembly",disabled:!l,onClick:function(){function s(){return h("device")}return s}()}),children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Attachment",children:l?(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:l,disabled:!l,onClick:function(){function s(){return h("remove_device")}return s}()}):(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"No Assembly"})})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Attachment One",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Attachment",children:c?(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:c,disabled:!c,onClick:function(){function s(){return h("tankone")}return s}()}):(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"No Tank"})})})}),(0,e.createComponentVNode)(2,t.Section,{title:"Attachment Two",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Attachment",children:m?(0,e.createComponentVNode)(2,t.Button,{icon:"eject",content:m,disabled:!m,onClick:function(){function s(){return h("tanktwo")}return s}()}):(0,e.createComponentVNode)(2,t.Box,{color:"average",children:"No Tank"})})})})]})})}return b}()},78166:function(T,r,n){"use strict";r.__esModule=!0,r.TurbineComputer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=n(44879),b=r.TurbineComputer=function(){function k(h,i){var c=(0,a.useBackend)(i),m=c.act,l=c.data,u=l.compressor,s=l.compressor_broken,d=l.turbine,C=l.turbine_broken,g=l.online,v=!!(u&&!s&&d&&!C);return(0,e.createComponentVNode)(2,o.Window,{width:400,height:200,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Status",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{icon:g?"power-off":"times",content:g?"Online":"Offline",selected:g,disabled:!v,onClick:function(){function f(){return m("toggle_power")}return f}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:"Disconnect",onClick:function(){function f(){return m("disconnect")}return f}()})],4),children:v?(0,e.createComponentVNode)(2,S):(0,e.createComponentVNode)(2,y)})})})}return k}(),y=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.compressor,u=m.compressor_broken,s=m.turbine,d=m.turbine_broken,C=m.online;return(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Compressor Status",color:!l||u?"bad":"good",children:u?l?"Offline":"Missing":"Online"}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Turbine Status",color:!s||d?"bad":"good",children:d?s?"Offline":"Missing":"Online"})]})},S=function(h,i){var c=(0,a.useBackend)(i),m=c.data,l=m.rpm,u=m.temperature,s=m.power,d=m.bearing_heat;return(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Turbine Speed",children:[l," RPM"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Internal Temp",children:[u," K"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Generated Power",children:[s," W"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Bearing Heat",children:(0,e.createComponentVNode)(2,t.ProgressBar,{value:d,minValue:0,maxValue:100,ranges:{good:[-1/0,60],average:[60,90],bad:[90,1/0]},children:(0,p.toFixed)(d)+"%"})})]})}},52847:function(T,r,n){"use strict";r.__esModule=!0,r.Uplink=void 0;var e=n(89005),a=n(88510),t=n(64795),o=n(25328),p=n(72253),b=n(36036),y=n(98595),S=n(3939),k=function(g){switch(g){case 0:return(0,e.createComponentVNode)(2,i);case 1:return(0,e.createComponentVNode)(2,c);case 2:return(0,e.createComponentVNode)(2,d);default:return"SOMETHING WENT VERY WRONG PLEASE AHELP"}},h=r.Uplink=function(){function C(g,v){var f=(0,p.useBackend)(v),N=f.act,V=f.data,B=V.cart,I=(0,p.useLocalState)(v,"tabIndex",0),L=I[0],w=I[1],A=(0,p.useLocalState)(v,"searchText",""),x=A[0],E=A[1];return(0,e.createComponentVNode)(2,y.Window,{width:900,height:600,theme:"syndicate",children:[(0,e.createComponentVNode)(2,S.ComplexModal),(0,e.createComponentVNode)(2,y.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Tabs,{children:[(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:L===0,onClick:function(){function P(){w(0),E("")}return P}(),icon:"store",children:"View Market"},"PurchasePage"),(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:L===1,onClick:function(){function P(){w(1),E("")}return P}(),icon:"shopping-cart",children:["View Shopping Cart ",B&&B.length?"("+B.length+")":""]},"Cart"),(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:L===2,onClick:function(){function P(){w(2),E("")}return P}(),icon:"user",children:"Exploitable Information"},"ExploitableInfo"),(0,e.createComponentVNode)(2,b.Tabs.Tab,{onClick:function(){function P(){return N("lock")}return P}(),icon:"lock",children:"Lock Uplink"},"LockUplink")]})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:k(L)})]})})]})}return C}(),i=function(g,v){var f=(0,p.useBackend)(v),N=f.act,V=f.data,B=V.crystals,I=V.cats,L=(0,p.useLocalState)(v,"uplinkItems",I[0].items),w=L[0],A=L[1],x=(0,p.useLocalState)(v,"searchText",""),E=x[0],P=x[1],D=function(U,z){z===void 0&&(z="");var $=(0,o.createSearch)(z,function(G){var X=G.hijack_only===1?"|hijack":"";return G.name+"|"+G.desc+"|"+G.cost+"tc"+X});return(0,t.flow)([(0,a.filter)(function(G){return G==null?void 0:G.name}),z&&(0,a.filter)($),(0,a.sortBy)(function(G){return G==null?void 0:G.name})])(U)},M=function(U){if(P(U),U==="")return A(I[0].items);A(D(I.map(function(z){return z.items}).flat(),U))},O=(0,p.useLocalState)(v,"showDesc",1),R=O[0],F=O[1];return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack,{vertical:!0,children:(0,e.createComponentVNode)(2,b.Stack.Item,{children:(0,e.createComponentVNode)(2,b.Section,{title:"Current Balance: "+B+"TC",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,b.Button.Checkbox,{content:"Show Descriptions",checked:R,onClick:function(){function W(){return F(!R)}return W}()}),(0,e.createComponentVNode)(2,b.Button,{content:"Random Item",icon:"question",onClick:function(){function W(){return N("buyRandom")}return W}()}),(0,e.createComponentVNode)(2,b.Button,{content:"Refund Currently Held Item",icon:"undo",onClick:function(){function W(){return N("refund")}return W}()})],4),children:(0,e.createComponentVNode)(2,b.Input,{fluid:!0,placeholder:"Search Equipment",onInput:function(){function W(U,z){M(z)}return W}(),value:E})})})}),(0,e.createComponentVNode)(2,b.Stack,{fill:!0,mt:.3,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,b.Tabs,{vertical:!0,children:I.map(function(W){return(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:E!==""?!1:W.items===w,onClick:function(){function U(){A(W.items),P("")}return U}(),children:W.cat},W)})})})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,b.Stack,{vertical:!0,children:w.map(function(W){return(0,e.createComponentVNode)(2,b.Stack.Item,{p:1,backgroundColor:"rgba(255, 0, 0, 0.1)",children:(0,e.createComponentVNode)(2,l,{i:W,showDecription:R},(0,o.decodeHtmlEntities)(W.name))},(0,o.decodeHtmlEntities)(W.name))})})})})]})]})},c=function(g,v){var f=(0,p.useBackend)(v),N=f.act,V=f.data,B=V.cart,I=V.crystals,L=V.cart_price,w=(0,p.useLocalState)(v,"showDesc",0),A=w[0],x=w[1];return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Current Balance: "+I+"TC",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,b.Button.Checkbox,{content:"Show Descriptions",checked:A,onClick:function(){function E(){return x(!A)}return E}()}),(0,e.createComponentVNode)(2,b.Button,{content:"Empty Cart",icon:"trash",onClick:function(){function E(){return N("empty_cart")}return E}(),disabled:!B}),(0,e.createComponentVNode)(2,b.Button,{content:"Purchase Cart ("+L+"TC)",icon:"shopping-cart",onClick:function(){function E(){return N("purchase_cart")}return E}(),disabled:!B||L>I})],4),children:(0,e.createComponentVNode)(2,b.Stack,{vertical:!0,children:B?B.map(function(E){return(0,e.createComponentVNode)(2,b.Stack.Item,{p:1,mr:1,backgroundColor:"rgba(255, 0, 0, 0.1)",children:(0,e.createComponentVNode)(2,l,{i:E,showDecription:A,buttons:(0,e.createComponentVNode)(2,s,{i:E})})},(0,o.decodeHtmlEntities)(E.name))}):(0,e.createComponentVNode)(2,b.Box,{italic:!0,children:"Your Shopping Cart is empty!"})})})}),(0,e.createComponentVNode)(2,m)]})},m=function(g,v){var f=(0,p.useBackend)(v),N=f.act,V=f.data,B=V.cats,I=V.lucky_numbers;return(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Suggested Purchases",buttons:(0,e.createComponentVNode)(2,b.Button,{icon:"dice",content:"See more suggestions",onClick:function(){function L(){return N("shuffle_lucky_numbers")}return L}()}),children:(0,e.createComponentVNode)(2,b.Stack,{wrap:!0,children:I.map(function(L){return B[L.cat].items[L.item]}).filter(function(L){return L!=null}).map(function(L,w){return(0,e.createComponentVNode)(2,b.Stack.Item,{p:1,mb:1,ml:1,width:34,backgroundColor:"rgba(255, 0, 0, 0.15)",children:(0,e.createComponentVNode)(2,l,{grow:!0,i:L})},w)})})})})},l=function(g,v){var f=g.i,N=g.showDecription,V=N===void 0?1:N,B=g.buttons,I=B===void 0?(0,e.createComponentVNode)(2,u,{i:f}):B;return(0,e.createComponentVNode)(2,b.Section,{title:(0,o.decodeHtmlEntities)(f.name),showBottom:V,buttons:I,children:V?(0,e.createComponentVNode)(2,b.Box,{italic:!0,children:(0,o.decodeHtmlEntities)(f.desc)}):null})},u=function(g,v){var f=(0,p.useBackend)(v),N=f.act,V=f.data,B=g.i,I=V.crystals;return(0,e.createFragment)([(0,e.createComponentVNode)(2,b.Button,{icon:"shopping-cart",color:B.hijack_only===1&&"red",tooltip:"Add to cart.",tooltipPosition:"left",onClick:function(){function L(){return N("add_to_cart",{item:B.obj_path})}return L}(),disabled:B.cost>I}),(0,e.createComponentVNode)(2,b.Button,{content:"Buy ("+B.cost+"TC)"+(B.refundable?" [Refundable]":""),color:B.hijack_only===1&&"red",tooltip:B.hijack_only===1&&"Hijack Agents Only!",tooltipPosition:"left",onClick:function(){function L(){return N("buyItem",{item:B.obj_path})}return L}(),disabled:B.cost>I})],4)},s=function(g,v){var f=(0,p.useBackend)(v),N=f.act,V=f.data,B=g.i,I=V.exploitable;return(0,e.createComponentVNode)(2,b.Stack,{children:[(0,e.createComponentVNode)(2,b.Button,{icon:"times",content:"("+B.cost*B.amount+"TC)",tooltip:"Remove from cart.",tooltipPosition:"left",onClick:function(){function L(){return N("remove_from_cart",{item:B.obj_path})}return L}()}),(0,e.createComponentVNode)(2,b.Button,{icon:"minus",tooltip:B.limit===0&&"Discount already redeemed!",ml:"5px",onClick:function(){function L(){return N("set_cart_item_quantity",{item:B.obj_path,quantity:--B.amount})}return L}(),disabled:B.amount<=0}),(0,e.createComponentVNode)(2,b.Button.Input,{content:B.amount,width:"45px",tooltipPosition:"bottom-end",tooltip:B.limit===0&&"Discount already redeemed!",onCommit:function(){function L(w,A){return N("set_cart_item_quantity",{item:B.obj_path,quantity:A})}return L}(),disabled:B.limit!==-1&&B.amount>=B.limit&&B.amount<=0}),(0,e.createComponentVNode)(2,b.Button,{mb:.3,icon:"plus",tooltipPosition:"bottom-start",tooltip:B.limit===0&&"Discount already redeemed!",onClick:function(){function L(){return N("set_cart_item_quantity",{item:B.obj_path,quantity:++B.amount})}return L}(),disabled:B.limit!==-1&&B.amount>=B.limit})]})},d=function(g,v){var f=(0,p.useBackend)(v),N=f.act,V=f.data,B=V.exploitable,I=(0,p.useLocalState)(v,"selectedRecord",B[0]),L=I[0],w=I[1],A=(0,p.useLocalState)(v,"searchText",""),x=A[0],E=A[1],P=function(O,R){R===void 0&&(R="");var F=(0,o.createSearch)(R,function(W){return W.name});return(0,t.flow)([(0,a.filter)(function(W){return W==null?void 0:W.name}),R&&(0,a.filter)(F),(0,a.sortBy)(function(W){return W.name})])(O)},D=P(B,x);return(0,e.createComponentVNode)(2,b.Stack,{fill:!0,children:[(0,e.createComponentVNode)(2,b.Stack.Item,{width:"30%",children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:"Exploitable Records",children:[(0,e.createComponentVNode)(2,b.Input,{fluid:!0,mb:1,placeholder:"Search Crew",onInput:function(){function M(O,R){return E(R)}return M}()}),(0,e.createComponentVNode)(2,b.Tabs,{vertical:!0,children:D.map(function(M){return(0,e.createComponentVNode)(2,b.Tabs.Tab,{selected:M===L,onClick:function(){function O(){return w(M)}return O}(),children:M.name},M)})})]})}),(0,e.createComponentVNode)(2,b.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,b.Section,{fill:!0,scrollable:!0,title:L.name,children:(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Age",children:L.age}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Fingerprint",children:L.fingerprint}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Rank",children:L.rank}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Sex",children:L.sex}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Species",children:L.species})]})})})]})}},12261:function(T,r,n){"use strict";r.__esModule=!0,r.Vending=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=S.product,l=S.productStock,u=S.productIcon,s=S.productIconState,d=c.chargesMoney,C=c.user,g=c.usermoney,v=c.inserted_cash,f=c.vend_ready,N=c.inserted_item_name,V=!d||m.price===0,B="ERROR!",I="";V?(B="FREE",I="arrow-circle-down"):(B=m.price,I="shopping-cart");var L=!f||l===0||!V&&m.price>g&&m.price>v;return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,children:(0,e.createComponentVNode)(2,t.DmIcon,{verticalAlign:"middle",icon:u,icon_state:s,fallback:(0,e.createComponentVNode)(2,t.Icon,{p:.66,name:"spinner",size:2,spin:!0})})}),(0,e.createComponentVNode)(2,t.Table.Cell,{bold:!0,children:m.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Box,{color:l<=0&&"bad"||l<=m.max_amount/2&&"average"||"good",children:[l," in stock"]})}),(0,e.createComponentVNode)(2,t.Table.Cell,{collapsing:!0,textAlign:"center",children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,disabled:L,icon:I,content:B,textAlign:"left",onClick:function(){function w(){return i("vend",{inum:m.inum})}return w}()})})]})},b=r.Vending=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.user,l=c.usermoney,u=c.inserted_cash,s=c.chargesMoney,d=c.product_records,C=d===void 0?[]:d,g=c.hidden_records,v=g===void 0?[]:g,f=c.stock,N=c.vend_ready,V=c.inserted_item_name,B=c.panel_open,I=c.speaker,L;return L=[].concat(C),c.extended_inventory&&(L=[].concat(L,v)),L=L.filter(function(w){return!!w}),(0,e.createComponentVNode)(2,o.Window,{title:"Vending Machine",width:450,height:Math.min((s?171:89)+L.length*32,585),children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[!!s&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"User",buttons:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:!!V&&(0,e.createComponentVNode)(2,t.Button,{fluid:!0,icon:"eject",content:(0,e.createVNode)(1,"span",null,V,0,{style:{"text-transform":"capitalize"}}),onClick:function(){function w(){return i("eject_item",{})}return w}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{disabled:!u,icon:"money-bill-wave-alt",content:u?(0,e.createFragment)([(0,e.createVNode)(1,"b",null,u,0),(0,e.createTextVNode)(" credits")],0):"Dispense Change",tooltip:u?"Dispense Change":null,textAlign:"left",onClick:function(){function w(){return i("change")}return w}()})})]}),children:m&&(0,e.createComponentVNode)(2,t.Box,{children:["Welcome, ",(0,e.createVNode)(1,"b",null,m.name,0),", ",(0,e.createVNode)(1,"b",null,m.job||"Unemployed",0),"!",(0,e.createVNode)(1,"br"),"Your balance is ",(0,e.createVNode)(1,"b",null,[l,(0,e.createTextVNode)(" credits")],0),".",(0,e.createVNode)(1,"br")]})})}),!!B&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{title:"Maintenance",children:(0,e.createComponentVNode)(2,t.Button,{icon:I?"check":"volume-mute",selected:I,content:"Speaker",textAlign:"left",onClick:function(){function w(){return i("toggle_voice",{})}return w}()})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:"Products",children:(0,e.createComponentVNode)(2,t.Table,{children:L.map(function(w){return(0,e.createComponentVNode)(2,p,{product:w,productStock:f[w.name],productIcon:w.icon,productIconState:w.icon_state},w.name)})})})})]})})})}return y}()},68971:function(T,r,n){"use strict";r.__esModule=!0,r.VolumeMixer=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.VolumeMixer=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.channels;return(0,e.createComponentVNode)(2,o.Window,{width:350,height:Math.min(95+c.length*50,565),children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:c.map(function(m,l){return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.25rem",color:"label",mt:l>0&&"0.5rem",children:m.name}),(0,e.createComponentVNode)(2,t.Box,{mt:"0.5rem",children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{mr:.5,children:(0,e.createComponentVNode)(2,t.Button,{width:"24px",color:"transparent",children:(0,e.createComponentVNode)(2,t.Icon,{name:"volume-off",size:"1.5",mt:"0.1rem",onClick:function(){function u(){return h("volume",{channel:m.num,volume:0})}return u}()})})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,mx:"0.5rem",children:(0,e.createComponentVNode)(2,t.Slider,{minValue:0,maxValue:100,stepPixelSize:3.13,value:m.volume,onChange:function(){function u(s,d){return h("volume",{channel:m.num,volume:d})}return u}()})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{width:"24px",color:"transparent",children:(0,e.createComponentVNode)(2,t.Icon,{name:"volume-up",size:"1.5",mt:"0.1rem",onClick:function(){function u(){return h("volume",{channel:m.num,volume:100})}return u}()})})})]})})],4,m.num)})})})})}return b}()},2510:function(T,r,n){"use strict";r.__esModule=!0,r.VotePanel=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.VotePanel=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.remaining,m=i.question,l=i.choices,u=i.user_vote,s=i.counts,d=i.show_counts;return(0,e.createComponentVNode)(2,o.Window,{width:400,height:360,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,title:m,children:[(0,e.createComponentVNode)(2,t.Box,{mb:1.5,ml:.5,children:["Time remaining: ",Math.round(c/10),"s"]}),l.map(function(C){return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{mb:1,fluid:!0,translucent:!0,lineHeight:3,multiLine:C,content:C+(d?" ("+(s[C]||0)+")":""),onClick:function(){function g(){return h("vote",{target:C})}return g}(),selected:C===u})},C)})]})})})}return b}()},30138:function(T,r,n){"use strict";r.__esModule=!0,r.Wires=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.Wires=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.wires||[],m=i.status||[],l=56+c.length*23+(status?0:15+m.length*17);return(0,e.createComponentVNode)(2,o.Window,{width:350,height:l,children:(0,e.createComponentVNode)(2,o.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Section,{fill:!0,scrollable:!0,children:(0,e.createComponentVNode)(2,t.LabeledList,{children:c.map(function(u){return(0,e.createComponentVNode)(2,t.LabeledList.Item,{className:"candystripe",label:u.color_name,labelColor:u.seen_color,color:u.seen_color,buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Button,{content:u.cut?"Mend":"Cut",onClick:function(){function s(){return h("cut",{wire:u.color})}return s}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Pulse",onClick:function(){function s(){return h("pulse",{wire:u.color})}return s}()}),(0,e.createComponentVNode)(2,t.Button,{content:u.attached?"Detach":"Attach",onClick:function(){function s(){return h("attach",{wire:u.color})}return s}()})],4),children:!!u.wire&&(0,e.createVNode)(1,"i",null,[(0,e.createTextVNode)("("),u.wire,(0,e.createTextVNode)(")")],0)},u.seen_color)})})})}),!!m.length&&(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Section,{children:m.map(function(u){return(0,e.createComponentVNode)(2,t.Box,{color:"lightgray",children:u},u)})})})]})})})}return b}()},21400:function(T,r,n){"use strict";r.__esModule=!0,r.WizardApprenticeContract=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(98595),p=r.WizardApprenticeContract=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.used;return(0,e.createComponentVNode)(2,o.Window,{width:500,height:555,children:(0,e.createComponentVNode)(2,o.Window.Content,{scrollable:!0,children:[(0,e.createComponentVNode)(2,t.Section,{title:"Contract of Apprenticeship",children:["Using this contract, you may summon an apprentice to aid you on your mission.",(0,e.createVNode)(1,"p",null,"If you are unable to establish contact with your apprentice, you can feed the contract back to the spellbook to refund your points.",16),c?(0,e.createComponentVNode)(2,t.Box,{bold:!0,color:"red",children:"You've already summoned an apprentice or you are in process of summoning one."}):""]}),(0,e.createComponentVNode)(2,t.Section,{title:"Which school of magic is your apprentice studying?",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Fire",children:["Your apprentice is skilled in bending fire. ",(0,e.createVNode)(1,"br"),"They know Fireball, Sacred Flame, and Ethereal Jaunt.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("fire")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Translocation",children:["Your apprentice is able to defy physics, learning how to move through bluespace. ",(0,e.createVNode)(1,"br"),"They know Teleport, Blink and Ethereal Jaunt.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("translocation")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Restoration",children:["Your apprentice is dedicated to supporting your magical prowess.",(0,e.createVNode)(1,"br"),"They come equipped with a Staff of Healing, have the unique ability to teleport back to you, and know Charge and Knock.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("restoration")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Stealth",children:["Your apprentice is learning the art of infiltrating mundane facilities. ",(0,e.createVNode)(1,"br"),"They know Mindswap, Knock, Homing Toolbox, and Disguise Self, all of which can be cast without robes. They also join you in a Maintenance Dweller disguise, complete with Gloves of Shock Immunity and a Belt of Tools.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("stealth")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Honk",children:["Your apprentice is here to spread the Honkmother's blessings.",(0,e.createVNode)(1,"br"),"They know Banana Touch, Instant Summons, Ethereal Jaunt, and come equipped with a Staff of Slipping."," ",(0,e.createVNode)(1,"br"),"While under your tutelage, they have been 'blessed' with clown shoes that are impossible to remove.",(0,e.createVNode)(1,"br"),(0,e.createComponentVNode)(2,t.Button,{content:"Select",disabled:c,onClick:function(){function m(){return h("honk")}return m}()})]}),(0,e.createComponentVNode)(2,t.LabeledList.Divider)]})})]})})}return b}()},49148:function(T,r,n){"use strict";r.__esModule=!0,r.AccessList=void 0;var e=n(89005),a=n(88510),t=n(72253),o=n(36036);function p(h,i){var c=typeof Symbol!="undefined"&&h[Symbol.iterator]||h["@@iterator"];if(c)return(c=c.call(h)).next.bind(c);if(Array.isArray(h)||(c=b(h))||i&&h&&typeof h.length=="number"){c&&(h=c);var m=0;return function(){return m>=h.length?{done:!0}:{done:!1,value:h[m++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function b(h,i){if(h){if(typeof h=="string")return y(h,i);var c={}.toString.call(h).slice(8,-1);return c==="Object"&&h.constructor&&(c=h.constructor.name),c==="Map"||c==="Set"?Array.from(h):c==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(c)?y(h,i):void 0}}function y(h,i){(i==null||i>h.length)&&(i=h.length);for(var c=0,m=Array(i);c0&&!V.includes(R.ref)&&!f.includes(R.ref),checked:f.includes(R.ref),onClick:function(){function F(){return B(R.ref)}return F}()},R.desc)})]})]})})}return h}()},26991:function(T,r,n){"use strict";r.__esModule=!0,r.AtmosScan=void 0;var e=n(89005),a=n(88510),t=n(72253),o=n(36036),p=function(S,k,h,i,c){return Si?"average":S>c?"bad":"good"},b=r.AtmosScan=function(){function y(S,k){var h=S.data.aircontents;return(0,e.createComponentVNode)(2,o.Box,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,a.filter)(function(i){return i.val!=="0"||i.entry==="Pressure"||i.entry==="Temperature"})(h).map(function(i){return(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:i.entry,color:p(i.val,i.bad_low,i.poor_low,i.poor_high,i.bad_high),children:[i.val,i.units]},i.entry)})})})}return y}()},85870:function(T,r,n){"use strict";r.__esModule=!0,r.BeakerContents=void 0;var e=n(89005),a=n(36036),t=n(15964),o=function(y){return y+" unit"+(y===1?"":"s")},p=r.BeakerContents=function(){function b(y){var S=y.beakerLoaded,k=y.beakerContents,h=k===void 0?[]:k,i=y.buttons;return(0,e.createComponentVNode)(2,a.Stack,{vertical:!0,children:[!S&&(0,e.createComponentVNode)(2,a.Stack.Item,{color:"label",children:"No beaker loaded."})||h.length===0&&(0,e.createComponentVNode)(2,a.Stack.Item,{color:"label",children:"Beaker is empty."}),h.map(function(c,m){return(0,e.createComponentVNode)(2,a.Stack,{children:[(0,e.createComponentVNode)(2,a.Stack.Item,{color:"label",grow:!0,children:[o(c.volume)," of ",c.name]},c.name),!!i&&(0,e.createComponentVNode)(2,a.Stack.Item,{children:i(c,m)})]},c.name)})]})}return b}();p.propTypes={beakerLoaded:t.bool,beakerContents:t.array,buttons:t.arrayOf(t.element)}},92963:function(T,r,n){"use strict";r.__esModule=!0,r.BotStatus=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.BotStatus=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.locked,c=h.noaccess,m=h.maintpanel,l=h.on,u=h.autopatrol,s=h.canhack,d=h.emagged,C=h.remote_disabled;return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.NoticeBox,{children:["Swipe an ID card to ",i?"unlock":"lock"," this interface."]}),(0,e.createComponentVNode)(2,t.Section,{title:"General Settings",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:(0,e.createComponentVNode)(2,t.Button,{icon:l?"power-off":"times",content:l?"On":"Off",selected:l,disabled:c,onClick:function(){function g(){return k("power")}return g}()})}),u!==null&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Patrol",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:u,content:"Auto Patrol",disabled:c,onClick:function(){function g(){return k("autopatrol")}return g}()})}),!!m&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Maintenance Panel",children:(0,e.createComponentVNode)(2,t.Box,{color:"bad",children:"Panel Open!"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Safety System",children:(0,e.createComponentVNode)(2,t.Box,{color:d?"bad":"good",children:d?"DISABLED!":"Enabled"})}),!!s&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Hacking",children:(0,e.createComponentVNode)(2,t.Button,{icon:"terminal",content:d?"Restore Safties":"Hack",disabled:c,color:"bad",onClick:function(){function g(){return k("hack")}return g}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Remote Access",children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:!C,content:"AI Remote Control",disabled:c,onClick:function(){function g(){return k("disableremote")}return g}()})})]})})],4)}return p}()},3939:function(T,r,n){"use strict";r.__esModule=!0,r.modalRegisterBodyOverride=r.modalOpen=r.modalClose=r.modalAnswer=r.ComplexModal=void 0;var e=n(89005),a=n(72253),t=n(36036),o={},p=r.modalOpen=function(){function h(i,c,m){var l=(0,a.useBackend)(i),u=l.act,s=l.data,d=Object.assign(s.modal?s.modal.args:{},m||{});u("modal_open",{id:c,arguments:JSON.stringify(d)})}return h}(),b=r.modalRegisterBodyOverride=function(){function h(i,c){o[i]=c}return h}(),y=r.modalAnswer=function(){function h(i,c,m,l){var u=(0,a.useBackend)(i),s=u.act,d=u.data;if(d.modal){var C=Object.assign(d.modal.args||{},l||{});s("modal_answer",{id:c,answer:m,arguments:JSON.stringify(C)})}}return h}(),S=r.modalClose=function(){function h(i,c){var m=(0,a.useBackend)(i),l=m.act;l("modal_close",{id:c})}return h}(),k=r.ComplexModal=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.data;if(l.modal){var u=l.modal,s=u.id,d=u.text,C=u.type,g,v=(0,e.createComponentVNode)(2,t.Button,{className:"Button--modal",icon:"arrow-left",content:"Cancel",onClick:function(){function L(){return S(c)}return L}()}),f,N,V="auto";if(o[s])f=o[s](l.modal,c);else if(C==="input"){var B=l.modal.value;g=function(){function L(w){return y(c,s,B)}return L}(),f=(0,e.createComponentVNode)(2,t.Input,{value:l.modal.value,placeholder:"ENTER to submit",width:"100%",my:"0.5rem",autofocus:!0,onChange:function(){function L(w,A){B=A}return L}()}),N=(0,e.createComponentVNode)(2,t.Box,{mt:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"arrow-left",content:"Cancel",color:"grey",onClick:function(){function L(){return S(c)}return L}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"check",content:"Confirm",color:"good",float:"right",m:"0",onClick:function(){function L(){return y(c,s,B)}return L}()}),(0,e.createComponentVNode)(2,t.Box,{clear:"both"})]})}else if(C==="choice"){var I=typeof l.modal.choices=="object"?Object.values(l.modal.choices):l.modal.choices;f=(0,e.createComponentVNode)(2,t.Dropdown,{options:I,selected:l.modal.value,width:"100%",my:"0.5rem",onSelected:function(){function L(w){return y(c,s,w)}return L}()}),V="initial"}else C==="bento"?f=(0,e.createComponentVNode)(2,t.Stack,{spacingPrecise:"1",wrap:"wrap",my:"0.5rem",maxHeight:"1%",children:l.modal.choices.map(function(L,w){return(0,e.createComponentVNode)(2,t.Stack.Item,{flex:"1 1 auto",children:(0,e.createComponentVNode)(2,t.Button,{selected:w+1===parseInt(l.modal.value,10),onClick:function(){function A(){return y(c,s,w+1)}return A}(),children:(0,e.createVNode)(1,"img",null,null,1,{src:L})})},w)})}):C==="boolean"&&(N=(0,e.createComponentVNode)(2,t.Box,{mt:"0.5rem",children:[(0,e.createComponentVNode)(2,t.Button,{icon:"times",content:l.modal.no_text,color:"bad",float:"left",mb:"0",onClick:function(){function L(){return y(c,s,0)}return L}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"check",content:l.modal.yes_text,color:"good",float:"right",m:"0",onClick:function(){function L(){return y(c,s,1)}return L}()}),(0,e.createComponentVNode)(2,t.Box,{clear:"both"})]}));return(0,e.createComponentVNode)(2,t.Modal,{maxWidth:i.maxWidth||window.innerWidth/2+"px",maxHeight:i.maxHeight||window.innerHeight/2+"px",onEnter:g,mx:"auto",overflowY:V,"padding-bottom":"5px",children:[d&&(0,e.createComponentVNode)(2,t.Box,{inline:!0,children:d}),o[s]&&v,f,N]})}}return h}()},41874:function(T,r,n){"use strict";r.__esModule=!0,r.CrewManifest=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(25328),p=n(76910),b=p.COLORS.department,y=["Captain","Head of Security","Chief Engineer","Chief Medical Officer","Research Director","Head of Personnel","Quartermaster"],S=function(m){return y.indexOf(m)!==-1?"green":"orange"},k=function(m){if(y.indexOf(m)!==-1)return!0},h=function(m){return m.length>0&&(0,e.createComponentVNode)(2,t.Table,{children:[(0,e.createComponentVNode)(2,t.Table.Row,{header:!0,color:"white",children:[(0,e.createComponentVNode)(2,t.Table.Cell,{width:"50%",children:"Name"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"35%",children:"Rank"}),(0,e.createComponentVNode)(2,t.Table.Cell,{width:"15%",children:"Active"})]}),m.map(function(l){return(0,e.createComponentVNode)(2,t.Table.Row,{color:S(l.rank),bold:k(l.rank),children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,o.decodeHtmlEntities)(l.name)}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,o.decodeHtmlEntities)(l.rank)}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:l.active})]},l.name+l.rank)})]})},i=r.CrewManifest=function(){function c(m,l){var u=(0,a.useBackend)(l),s=u.act,d;if(m.data)d=m.data;else{var C=(0,a.useBackend)(l),g=C.data;d=g}var v=d,f=v.manifest,N=f.heads,V=f.sec,B=f.eng,I=f.med,L=f.sci,w=f.ser,A=f.sup,x=f.misc;return(0,e.createComponentVNode)(2,t.Box,{children:[(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.command,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Command"})}),level:2,children:h(N)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.security,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Security"})}),level:2,children:h(V)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.engineering,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Engineering"})}),level:2,children:h(B)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.medical,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Medical"})}),level:2,children:h(I)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.science,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Science"})}),level:2,children:h(L)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.service,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Service"})}),level:2,children:h(w)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{backgroundColor:b.supply,m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Supply"})}),level:2,children:h(A)}),(0,e.createComponentVNode)(2,t.Section,{title:(0,e.createComponentVNode)(2,t.Box,{m:-1,pt:1,pb:1,children:(0,e.createComponentVNode)(2,t.Box,{ml:1,textAlign:"center",fontSize:1.4,children:"Misc"})}),level:2,children:h(x)})]})}return c}()},19203:function(T,r,n){"use strict";r.__esModule=!0,r.InputButtons=void 0;var e=n(89005),a=n(36036),t=n(72253),o=r.InputButtons=function(){function p(b,y){var S=(0,t.useBackend)(y),k=S.act,h=S.data,i=h.large_buttons,c=h.swapped_buttons,m=b.input,l=b.message,u=b.disabled,s=(0,e.createComponentVNode)(2,a.Button,{color:"good",content:"Submit",bold:!!i,fluid:!!i,onClick:function(){function C(){return k("submit",{entry:m})}return C}(),textAlign:"center",tooltip:i&&l,disabled:u,width:!i&&6}),d=(0,e.createComponentVNode)(2,a.Button,{color:"bad",content:"Cancel",bold:!!i,fluid:!!i,onClick:function(){function C(){return k("cancel")}return C}(),textAlign:"center",width:!i&&6});return(0,e.createComponentVNode)(2,a.Flex,{fill:!0,align:"center",direction:c?"row-reverse":"row",justify:"space-around",children:[i?(0,e.createComponentVNode)(2,a.Flex.Item,{grow:!0,ml:c?.5:0,mr:c?0:.5,children:d}):(0,e.createComponentVNode)(2,a.Flex.Item,{children:d}),!i&&l&&(0,e.createComponentVNode)(2,a.Flex.Item,{children:(0,e.createComponentVNode)(2,a.Box,{color:"label",textAlign:"center",children:l})}),i?(0,e.createComponentVNode)(2,a.Flex.Item,{grow:!0,mr:c?.5:0,ml:c?0:.5,children:s}):(0,e.createComponentVNode)(2,a.Flex.Item,{children:s})]})}return p}()},195:function(T,r,n){"use strict";r.__esModule=!0,r.InterfaceLockNoticeBox=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.InterfaceLockNoticeBox=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=b.siliconUser,c=i===void 0?h.siliconUser:i,m=b.locked,l=m===void 0?h.locked:m,u=b.normallyLocked,s=u===void 0?h.normallyLocked:u,d=b.onLockStatusChange,C=d===void 0?function(){return k("lock")}:d,g=b.accessText,v=g===void 0?"an ID card":g;return c?(0,e.createComponentVNode)(2,t.NoticeBox,{color:c&&"grey",children:(0,e.createComponentVNode)(2,t.Flex,{align:"center",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{children:"Interface lock status:"}),(0,e.createComponentVNode)(2,t.Flex.Item,{grow:"1"}),(0,e.createComponentVNode)(2,t.Flex.Item,{children:(0,e.createComponentVNode)(2,t.Button,{m:"0",color:s?"red":"green",icon:s?"lock":"unlock",content:s?"Locked":"Unlocked",onClick:function(){function f(){C&&C(!l)}return f}()})})]})}):(0,e.createComponentVNode)(2,t.NoticeBox,{children:["Swipe ",v," to ",l?"unlock":"lock"," this interface."]})}return p}()},51057:function(T,r,n){"use strict";r.__esModule=!0,r.Loader=void 0;var e=n(89005),a=n(44879),t=n(36036),o=r.Loader=function(){function p(b){var y=b.value;return(0,e.createVNode)(1,"div","AlertModal__Loader",(0,e.createComponentVNode)(2,t.Box,{className:"AlertModal__LoaderProgress",style:{width:(0,a.clamp01)(y)*100+"%"}}),2)}return p}()},321:function(T,r,n){"use strict";r.__esModule=!0,r.LoginInfo=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LoginInfo=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.loginState;if(h)return(0,e.createComponentVNode)(2,t.NoticeBox,{info:!0,children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,mt:.5,children:["Logged in as: ",i.name," (",i.rank,")"]}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:[(0,e.createComponentVNode)(2,t.Button,{icon:"eject",disabled:!i.id,content:"Eject ID",color:"good",onClick:function(){function c(){return k("login_eject")}return c}()}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-out-alt",content:"Logout",color:"good",onClick:function(){function c(){return k("login_logout")}return c}()})]})]})})}return p}()},5485:function(T,r,n){"use strict";r.__esModule=!0,r.LoginScreen=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.LoginScreen=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.loginState,c=h.isAI,m=h.isRobot,l=h.isAdmin;return(0,e.createComponentVNode)(2,t.Section,{title:"Welcome",fill:!0,stretchContents:!0,children:(0,e.createComponentVNode)(2,t.Flex,{height:"100%",align:"center",justify:"center",children:(0,e.createComponentVNode)(2,t.Flex.Item,{textAlign:"center",mt:"-2rem",children:[(0,e.createComponentVNode)(2,t.Box,{fontSize:"1.5rem",bold:!0,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"user-circle",verticalAlign:"middle",size:3,mr:"1rem"}),"Guest"]}),(0,e.createComponentVNode)(2,t.Box,{color:"label",my:"1rem",children:["ID:",(0,e.createComponentVNode)(2,t.Button,{icon:"id-card",content:i.id?i.id:"----------",ml:"0.5rem",onClick:function(){function u(){return k("login_insert")}return u}()})]}),(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",disabled:!i.id,content:"Login",onClick:function(){function u(){return k("login_login",{login_type:1})}return u}()}),!!c&&(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"Login as AI",onClick:function(){function u(){return k("login_login",{login_type:2})}return u}()}),!!m&&(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"Login as Cyborg",onClick:function(){function u(){return k("login_login",{login_type:3})}return u}()}),!!l&&(0,e.createComponentVNode)(2,t.Button,{icon:"sign-in-alt",content:"CentComm Secure Login",onClick:function(){function u(){return k("login_login",{login_type:4})}return u}()})]})})})}return p}()},62411:function(T,r,n){"use strict";r.__esModule=!0,r.Operating=void 0;var e=n(89005),a=n(36036),t=n(15964),o=r.Operating=function(){function p(b){var y=b.operating,S=b.name;if(y)return(0,e.createComponentVNode)(2,a.Dimmer,{children:(0,e.createComponentVNode)(2,a.Flex,{mb:"30px",children:(0,e.createComponentVNode)(2,a.Flex.Item,{bold:!0,color:"silver",textAlign:"center",children:[(0,e.createComponentVNode)(2,a.Icon,{name:"spinner",spin:!0,size:4,mb:"15px"}),(0,e.createVNode)(1,"br"),"The ",S," is processing..."]})})})}return p}();o.propTypes={operating:t.bool,name:t.string}},13545:function(T,r,n){"use strict";r.__esModule=!0,r.Signaler=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=r.Signaler=function(){function b(y,S){var k=(0,t.useBackend)(S),h=k.act,i=y.data,c=i.code,m=i.frequency,l=i.minFrequency,u=i.maxFrequency;return(0,e.createComponentVNode)(2,o.Section,{children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Frequency",children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:.2,stepPixelSize:6,minValue:l/10,maxValue:u/10,value:m/10,format:function(){function s(d){return(0,a.toFixed)(d,1)}return s}(),width:"80px",onDrag:function(){function s(d,C){return h("freq",{freq:C})}return s}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Code",children:(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:1,stepPixelSize:6,minValue:1,maxValue:100,value:c,width:"80px",onDrag:function(){function s(d,C){return h("code",{code:C})}return s}()})})]}),(0,e.createComponentVNode)(2,o.Button,{mt:1,fluid:!0,icon:"arrow-up",content:"Send Signal",textAlign:"center",onClick:function(){function s(){return h("signal")}return s}()})]})}return b}()},41984:function(T,r,n){"use strict";r.__esModule=!0,r.SimpleRecords=void 0;var e=n(89005),a=n(72253),t=n(25328),o=n(64795),p=n(88510),b=n(36036),y=r.SimpleRecords=function(){function h(i,c){var m=i.data.records;return(0,e.createComponentVNode)(2,b.Box,{children:m?(0,e.createComponentVNode)(2,k,{data:i.data,recordType:i.recordType}):(0,e.createComponentVNode)(2,S,{data:i.data})})}return h}(),S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=i.data.recordsList,s=(0,a.useLocalState)(c,"searchText",""),d=s[0],C=s[1],g=function(N,V){V===void 0&&(V="");var B=(0,t.createSearch)(V,function(I){return I.Name});return(0,o.flow)([(0,p.filter)(function(I){return I==null?void 0:I.Name}),V&&(0,p.filter)(B),(0,p.sortBy)(function(I){return I.Name})])(u)},v=g(u,d);return(0,e.createComponentVNode)(2,b.Box,{children:[(0,e.createComponentVNode)(2,b.Input,{fluid:!0,mb:1,placeholder:"Search records...",onInput:function(){function f(N,V){return C(V)}return f}()}),v.map(function(f){return(0,e.createComponentVNode)(2,b.Box,{children:(0,e.createComponentVNode)(2,b.Button,{mb:.5,content:f.Name,icon:"user",onClick:function(){function N(){return l("Records",{target:f.uid})}return N}()})},f)})]})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=i.data.records,s=u.general,d=u.medical,C=u.security,g;switch(i.recordType){case"MED":g=(0,e.createComponentVNode)(2,b.Section,{level:2,title:"Medical Data",children:d?(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Blood Type",children:d.blood_type}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Minor Disabilities",children:d.mi_dis}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:d.mi_dis_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Major Disabilities",children:d.ma_dis}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:d.ma_dis_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Allergies",children:d.alg}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:d.alg_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Current Diseases",children:d.cdi}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:d.cdi_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Important Notes",preserveWhitespace:!0,children:d.notes})]}):(0,e.createComponentVNode)(2,b.Box,{color:"red",bold:!0,children:"Medical record lost!"})});break;case"SEC":g=(0,e.createComponentVNode)(2,b.Section,{level:2,title:"Security Data",children:C?(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Criminal Status",children:C.criminal}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Minor Crimes",children:C.mi_crim}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:C.mi_crim_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Major Crimes",children:C.ma_crim}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Details",children:C.ma_crim_d}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Important Notes",preserveWhitespace:!0,children:C.notes})]}):(0,e.createComponentVNode)(2,b.Box,{color:"red",bold:!0,children:"Security record lost!"})});break}return(0,e.createComponentVNode)(2,b.Box,{children:[(0,e.createComponentVNode)(2,b.Section,{title:"General Data",children:s?(0,e.createComponentVNode)(2,b.LabeledList,{children:[(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Name",children:s.name}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Sex",children:s.sex}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Species",children:s.species}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Age",children:s.age}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Rank",children:s.rank}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Fingerprint",children:s.fingerprint}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Physical Status",children:s.p_stat}),(0,e.createComponentVNode)(2,b.LabeledList.Item,{label:"Mental Status",children:s.m_stat})]}):(0,e.createComponentVNode)(2,b.Box,{color:"red",bold:!0,children:"General record lost!"})}),g]})}},22091:function(T,r,n){"use strict";r.__esModule=!0,r.TemporaryNotice=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.TemporaryNotice=function(){function p(b,y){var S,k=(0,a.useBackend)(y),h=k.act,i=k.data,c=i.temp;if(c){var m=(S={},S[c.style]=!0,S);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,t.NoticeBox,Object.assign({},m,{children:(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,mt:.5,children:c.text}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{icon:"times-circle",onClick:function(){function l(){return h("cleartemp")}return l}()})})]})})))}}return p}()},95213:function(T,r,n){"use strict";r.__esModule=!0,r.goonstation_PTL=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(49968),p=n(98595);/**
* @file
* @copyright 2020
* @author Sovexe (https://github.com/Sovexe)
* @license ISC
- */var b=r.goonstation_PTL=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.data,u=l.total_earnings,s=l.total_energy,d=l.name,v=d===void 0?"Power Transmission Laser":d;return(0,e.createComponentVNode)(2,p.Window,{title:"Power Transmission Laser",width:"310",height:"485",children:(0,e.createComponentVNode)(2,p.Window.Content,{children:[(0,e.createComponentVNode)(2,y),(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,t.NoticeBox,{success:!0,children:["Earned Credits : ",u?(0,o.formatMoney)(u):0]}),(0,e.createComponentVNode)(2,t.NoticeBox,{success:!0,children:["Energy Sold : ",s?(0,o.formatSiUnit)(s,0,"J"):"0 J"]})]})})}return h}(),y=function(i,c){var m=(0,a.useBackend)(c),l=m.data,u=l.max_capacity,s=l.held_power,d=l.input_total,v=l.max_grid_load;return(0,e.createComponentVNode)(2,t.Section,{title:"Status",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Reserve energy",children:s?(0,o.formatSiUnit)(s,0,"J"):"0 J"})}),(0,e.createComponentVNode)(2,t.ProgressBar,{mt:"0.5em",mb:"0.5em",ranges:{good:[.8,1/0],average:[.5,.8],bad:[-1/0,.5]},value:s/u}),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Grid Saturation"})}),(0,e.createComponentVNode)(2,t.ProgressBar,{mt:"0.5em",ranges:{good:[.8,1/0],average:[.5,.8],bad:[-1/0,.5]},value:Math.min(d,u-s)/v})]})},S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.input_total,d=u.accepting_power,v=u.sucking_power,g=u.input_number,C=u.power_format;return(0,e.createComponentVNode)(2,t.Section,{title:"Input Controls",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Input Circuit",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",color:d?"green":"red",onClick:function(){function f(){return l("toggle_input")}return f}(),children:d?"Enabled":"Disabled"}),children:(0,e.createComponentVNode)(2,t.Box,{color:v&&"good"||d&&"average"||"bad",children:v&&"Online"||d&&"Idle"||"Offline"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Input Level",children:s?(0,o.formatPower)(s):"0 W"})]}),(0,e.createComponentVNode)(2,t.Box,{mt:"0.5em",children:[(0,e.createComponentVNode)(2,t.NumberInput,{mr:"0.5em",animated:!0,size:1.25,inline:!0,step:1,stepPixelSize:2,minValue:0,maxValue:999,value:g,onChange:function(){function f(N,V){return l("set_input",{set_input:V})}return f}()}),(0,e.createComponentVNode)(2,t.Button,{selected:C===1,onClick:function(){function f(){return l("inputW")}return f}(),children:"W"}),(0,e.createComponentVNode)(2,t.Button,{selected:C===Math.pow(10,3),onClick:function(){function f(){return l("inputKW")}return f}(),children:"KW"}),(0,e.createComponentVNode)(2,t.Button,{selected:C===Math.pow(10,6),onClick:function(){function f(){return l("inputMW")}return f}(),children:"MW"}),(0,e.createComponentVNode)(2,t.Button,{selected:C===Math.pow(10,9),onClick:function(){function f(){return l("inputGW")}return f}(),children:"GW"})]})]})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.output_total,d=u.firing,v=u.accepting_power,g=u.output_number,C=u.output_multiplier,f=u.target,N=u.held_power;return(0,e.createComponentVNode)(2,t.Section,{title:"Output Controls",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Laser Circuit",buttons:(0,e.createComponentVNode)(2,t.Stack,{Horizontal:!0,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"crosshairs",color:f===""?"green":"red",onClick:function(){function V(){return l("target")}return V}(),children:f}),(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",color:d?"green":"red",disabled:!d&&Nu,onClick:function(){function B(){return k("purchaseSoftware",{key:V.key})}return B}()},V.key)}),c.filter(function(V){return!N[V.key]}).length===0&&"No software available!"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Installed Software",children:[m.filter(function(V){return V.key!=="mainmenu"}).map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,icon:V.icon,onClick:function(){function B(){return k("startSoftware",{software_key:V.key})}return B}()},V.key)}),m.length===0&&"No software installed!"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Installed Toggles",children:[l.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,icon:V.icon,selected:V.active,onClick:function(){function B(){return k("setToggle",{toggle_key:V.key})}return B}()},V.key)}),l.length===0&&"No toggles installed!"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Emotion",children:s.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,selected:V.id===d,onClick:function(){function B(){return k("setEmotion",{emotion:V.id})}return B}()},V.id)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Speaking State",children:v.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,selected:V.name===g,onClick:function(){function B(){return k("setSpeechStyle",{speech_state:V.name})}return B}()},V.id)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Chassis Type",children:C.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,selected:V.icon===f,onClick:function(){function B(){return k("setChassis",{chassis_to_change:V.icon})}return B}()},V.id)})})]})})}return p}()},2983:function(T,r,n){"use strict";r.__esModule=!0,r.pai_manifest=void 0;var e=n(89005),a=n(72253),t=n(41874),o=r.pai_manifest=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data;return(0,e.createComponentVNode)(2,t.CrewManifest,{data:h.app_data})}return p}()},40758:function(T,r,n){"use strict";r.__esModule=!0,r.pai_medrecords=void 0;var e=n(89005),a=n(72253),t=n(41984),o=r.pai_medrecords=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data;return(0,e.createComponentVNode)(2,t.SimpleRecords,{data:k.app_data,recordType:"MED"})}return p}()},98599:function(T,r,n){"use strict";r.__esModule=!0,r.pai_messenger=void 0;var e=n(89005),a=n(72253),t=n(77595),o=r.pai_messenger=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.app_data.active_convo;return i?(0,e.createComponentVNode)(2,t.ActiveConversation,{data:h.app_data}):(0,e.createComponentVNode)(2,t.MessengerList,{data:h.app_data})}return p}()},50775:function(T,r,n){"use strict";r.__esModule=!0,r.pai_radio=void 0;var e=n(89005),a=n(72253),t=n(44879),o=n(36036),p=r.pai_radio=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.app_data,m=c.minFrequency,l=c.maxFrequency,u=c.frequency,s=c.broadcasting;return(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Frequency",children:[(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:.2,stepPixelSize:6,minValue:m/10,maxValue:l/10,value:u/10,format:function(){function d(v){return(0,t.toFixed)(v,1)}return d}(),onChange:function(){function d(v,g){return h("freq",{freq:g})}return d}()}),(0,e.createComponentVNode)(2,o.Button,{tooltip:"Reset",icon:"undo",onClick:function(){function d(){return h("freq",{freq:"145.9"})}return d}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Broadcast Nearby Speech",children:(0,e.createComponentVNode)(2,o.Button,{onClick:function(){function d(){return h("toggleBroadcast")}return d}(),selected:s,content:s?"Enabled":"Disabled"})})]})}return b}()},48623:function(T,r,n){"use strict";r.__esModule=!0,r.pai_secrecords=void 0;var e=n(89005),a=n(72253),t=n(41984),o=r.pai_secrecords=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data;return(0,e.createComponentVNode)(2,t.SimpleRecords,{data:k.app_data,recordType:"SEC"})}return p}()},47297:function(T,r,n){"use strict";r.__esModule=!0,r.pai_signaler=void 0;var e=n(89005),a=n(72253),t=n(13545),o=r.pai_signaler=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data;return(0,e.createComponentVNode)(2,t.Signaler,{data:h.app_data})}return p}()},78532:function(T,r,n){"use strict";r.__esModule=!0,r.pda_atmos_scan=void 0;var e=n(89005),a=n(72253),t=n(26991),o=r.pda_atmos_scan=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data;return(0,e.createComponentVNode)(2,t.AtmosScan,{data:k})}return p}()},2395:function(T,r,n){"use strict";r.__esModule=!0,r.pda_games=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(1331),p=r.pda_games=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.games,m=function(){function l(u){switch(u){case"Minesweeper":return(0,e.createComponentVNode)(2,o.IconStack,{children:[(0,e.createComponentVNode)(2,o.Icon,{ml:"0",mt:"10px",name:"flag",size:"6",color:"gray",rotation:30}),(0,e.createComponentVNode)(2,o.Icon,{ml:"9px",mt:"23px",name:"bomb",size:"3",color:"black"})]});default:return(0,e.createComponentVNode)(2,o.Icon,{ml:"16px",mt:"10px",name:"gamepad",size:"6"})}}return l}();return(0,e.createComponentVNode)(2,t.Box,{children:c.map(function(l){return(0,e.createComponentVNode)(2,t.Button,{width:"33%",textAlign:"center",translucent:!0,onClick:function(){function u(){return h("play",{id:l.id})}return u}(),children:[m(l.name),(0,e.createComponentVNode)(2,t.Box,{children:l.name})]},l.name)})})}return b}()},40253:function(T,r,n){"use strict";r.__esModule=!0,r.pda_janitor=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.pda_janitor=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.janitor,c=i.user_loc,m=i.mops,l=i.buckets,u=i.cleanbots,s=i.carts,d=i.janicarts;return(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Location",children:[c.x,",",c.y]}),m&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mop Locations",children:m.map(function(v){return(0,e.createComponentVNode)(2,t.Box,{children:[v.x,",",v.y," (",v.dir,") - ",v.status]},v)})}),l&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mop Bucket Locations",children:l.map(function(v){return(0,e.createComponentVNode)(2,t.Box,{children:[v.x,",",v.y," (",v.dir,") - [",v.volume,"/",v.max_volume,"]"]},v)})}),u&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cleanbot Locations",children:u.map(function(v){return(0,e.createComponentVNode)(2,t.Box,{children:[v.x,",",v.y," (",v.dir,") - ",v.status]},v)})}),s&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Janitorial Cart Locations",children:s.map(function(v){return(0,e.createComponentVNode)(2,t.Box,{children:[v.x,",",v.y," (",v.dir,") - [",v.volume,"/",v.max_volume,"]"]},v)})}),d&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Janicart Locations",children:d.map(function(v){return(0,e.createComponentVNode)(2,t.Box,{children:[v.x,",",v.y," (",v.direction_from_user,")"]},v)})})]})}return p}()},58293:function(T,r,n){"use strict";r.__esModule=!0,r.pda_main_menu=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=r.pda_main_menu=function(){function b(y,S){var k=(0,t.useBackend)(S),h=k.act,i=k.data,c=i.owner,m=i.ownjob,l=i.idInserted,u=i.categories,s=i.pai,d=i.notifying;return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Owner",color:"average",children:[c,", ",m]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"ID",children:(0,e.createComponentVNode)(2,o.Button,{icon:"sync",content:"Update PDA Info",disabled:!l,onClick:function(){function v(){return h("UpdateInfo")}return v}()})})]})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:"Functions",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:u.map(function(v){var g=i.apps[v];return!g||!g.length?null:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:v,children:g.map(function(C){return(0,e.createComponentVNode)(2,o.Button,{icon:C.uid in d?C.notify_icon:C.icon,iconSpin:C.uid in d,color:C.uid in d?"red":"transparent",content:C.name,onClick:function(){function f(){return h("StartProgram",{program:C.uid})}return f}()},C.uid)})},v)})})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:!!s&&(0,e.createComponentVNode)(2,o.Section,{title:"pAI",children:[(0,e.createComponentVNode)(2,o.Button,{fluid:!0,icon:"cog",content:"Configuration",onClick:function(){function v(){return h("pai",{option:1})}return v}()}),(0,e.createComponentVNode)(2,o.Button,{fluid:!0,icon:"eject",content:"Eject pAI",onClick:function(){function v(){return h("pai",{option:2})}return v}()})]})})]})}return b}()},58059:function(T,r,n){"use strict";r.__esModule=!0,r.pda_manifest=void 0;var e=n(89005),a=n(72253),t=n(41874),o=r.pda_manifest=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data;return(0,e.createComponentVNode)(2,t.CrewManifest)}return p}()},18147:function(T,r,n){"use strict";r.__esModule=!0,r.pda_medical=void 0;var e=n(89005),a=n(72253),t=n(41984),o=r.pda_medical=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data;return(0,e.createComponentVNode)(2,t.SimpleRecords,{data:k,recordType:"MED"})}return p}()},77595:function(T,r,n){"use strict";r.__esModule=!0,r.pda_messenger=r.MessengerList=r.ActiveConversation=void 0;var e=n(89005),a=n(88510),t=n(72253),o=n(36036),p=r.pda_messenger=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=l.active_convo;return u?(0,e.createComponentVNode)(2,b,{data:l}):(0,e.createComponentVNode)(2,y,{data:l})}return k}(),b=r.ActiveConversation=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=h.data,u=l.convo_name,s=l.convo_job,d=l.messages,v=l.active_convo,g=(0,t.useLocalState)(i,"clipboardMode",!1),C=g[0],f=g[1],N=(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Conversation with "+u+" ("+s+")",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{icon:"eye",selected:C,tooltip:"Enter Clipboard Mode",tooltipPosition:"bottom-start",onClick:function(){function V(){return f(!C)}return V}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"comment",onClick:function(){function V(){return m("Message",{target:v})}return V}(),content:"Reply"})],4),children:(0,a.filter)(function(V){return V.target===v})(d).map(function(V,B){return(0,e.createComponentVNode)(2,o.Box,{textAlign:V.sent?"right":"left",position:"relative",mb:1,children:[(0,e.createComponentVNode)(2,o.Icon,{fontSize:2.5,color:V.sent?"#4d9121":"#cd7a0d",position:"absolute",left:V.sent?null:"0px",right:V.sent?"0px":null,bottom:"-4px",style:{"z-index":"0",transform:V.sent?"scale(-1, 1)":null},name:"comment"}),(0,e.createComponentVNode)(2,o.Box,{inline:!0,backgroundColor:V.sent?"#4d9121":"#cd7a0d",p:1,maxWidth:"100%",position:"relative",textAlign:V.sent?"left":"right",style:{"z-index":"1","border-radius":"10px","word-break":"normal"},children:[V.sent?"You:":"Them:"," ",V.message]})]},B)})});return C&&(N=(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Conversation with "+u+" ("+s+")",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{icon:"eye",selected:C,tooltip:"Exit Clipboard Mode",tooltipPosition:"bottom-start",onClick:function(){function V(){return f(!C)}return V}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"comment",onClick:function(){function V(){return m("Message",{target:v})}return V}(),content:"Reply"})],4),children:(0,a.filter)(function(V){return V.target===v})(d).map(function(V,B){return(0,e.createComponentVNode)(2,o.Box,{color:V.sent?"#4d9121":"#cd7a0d",style:{"word-break":"normal"},children:[V.sent?"You:":"Them:"," ",(0,e.createComponentVNode)(2,o.Box,{inline:!0,children:V.message})]},B)})})),(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{mb:.5,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Messenger Functions",children:(0,e.createComponentVNode)(2,o.Button.Confirm,{content:"Delete Conversations",confirmContent:"Are you sure?",icon:"trash",confirmIcon:"trash",onClick:function(){function V(){return m("Clear",{option:"Convo"})}return V}()})})})}),N]})}return k}(),y=r.MessengerList=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=h.data,u=l.convopdas,s=l.pdas,d=l.charges,v=l.silent,g=l.toff,C=l.ringtone_list,f=l.ringtone,N=(0,t.useLocalState)(i,"searchTerm",""),V=N[0],B=N[1];return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{mb:5,children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Messenger Functions",children:[(0,e.createComponentVNode)(2,o.Button,{selected:!v,icon:v?"volume-mute":"volume-up",onClick:function(){function I(){return m("Toggle Ringer")}return I}(),children:["Ringer: ",v?"Off":"On"]}),(0,e.createComponentVNode)(2,o.Button,{color:g?"bad":"green",icon:"power-off",onClick:function(){function I(){return m("Toggle Messenger")}return I}(),children:["Messenger: ",g?"Off":"On"]}),(0,e.createComponentVNode)(2,o.Button,{icon:"trash",color:"bad",onClick:function(){function I(){return m("Clear",{option:"All"})}return I}(),children:"Delete All Conversations"}),(0,e.createComponentVNode)(2,o.Button,{icon:"bell",onClick:function(){function I(){return m("Ringtone")}return I}(),children:"Set Custom Ringtone"}),(0,e.createComponentVNode)(2,o.Dropdown,{selected:f,width:"100px",options:Object.keys(C),onSelected:function(){function I(L){return m("Available_Ringtones",{selected_ringtone:L})}return I}()})]})}),!g&&(0,e.createComponentVNode)(2,o.Box,{children:[!!d&&(0,e.createComponentVNode)(2,o.Box,{mt:.5,mb:1,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Cartridge Special Function",children:[d," charges left."]})})}),!u.length&&!s.length&&(0,e.createComponentVNode)(2,o.Box,{children:"No current conversations"})||(0,e.createComponentVNode)(2,o.Box,{children:["Search:"," ",(0,e.createComponentVNode)(2,o.Input,{mt:.5,value:V,onInput:function(){function I(L,w){B(w)}return I}()})]})]})||(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:"Messenger Offline."})]}),(0,e.createComponentVNode)(2,S,{title:"Current Conversations",data:l,pdas:u,msgAct:"Select Conversation",searchTerm:V}),(0,e.createComponentVNode)(2,S,{title:"Other PDAs",pdas:s,msgAct:"Message",data:l,searchTerm:V})]})}return k}(),S=function(h,i){var c=(0,t.useBackend)(i),m=c.act,l=h.data,u=h.pdas,s=h.title,d=h.msgAct,v=h.searchTerm,g=l.charges,C=l.plugins;return!u||!u.length?(0,e.createComponentVNode)(2,o.Section,{title:s,children:"No PDAs found."}):(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:s,children:u.filter(function(f){return f.Name.toLowerCase().includes(v.toLowerCase())}).map(function(f){return(0,e.createComponentVNode)(2,o.Stack,{m:.5,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,icon:"arrow-circle-down",content:f.Name,onClick:function(){function N(){return m(d,{target:f.uid})}return N}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:!!g&&C.map(function(N){return(0,e.createComponentVNode)(2,o.Button,{icon:N.icon,content:N.name,onClick:function(){function V(){return m("Messenger Plugin",{plugin:N.uid,target:f.uid})}return V}()},N.uid)})})]},f.uid)})})}},90382:function(T,r,n){"use strict";r.__esModule=!0,r.pda_minesweeper=r.MineSweeperLeaderboard=r.MineSweeperGame=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.pda_minesweeper=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=(0,a.useLocalState)(h,"window","Game"),u=l[0],s=l[1],d={Game:"Leaderboard",Leaderboard:"Game"};return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:u==="Game"?(0,e.createComponentVNode)(2,p):(0,e.createComponentVNode)(2,b)}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,fontSize:2,lineHeight:1.75,icon:u==="Game"?"book":"gamepad",onClick:function(){function v(){return s(d[u])}return v}(),children:d[u]})})]})}return S}(),p=r.MineSweeperGame=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.matrix,u=m.flags,s=m.bombs,d={1:"blue",2:"green",3:"red",4:"darkblue",5:"brown",6:"lightblue",7:"black",8:"white"},v=function(){function g(C,f,N){c("Square",{X:C,Y:f,mode:N})}return g}();return(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:Object.keys(l).map(function(g){return(0,e.createComponentVNode)(2,t.Box,{children:Object.keys(l[g]).map(function(C){return(0,e.createComponentVNode)(2,t.Button,{m:.25,height:2,width:2,className:l[g][C].open?"Minesweeper__open":"Minesweeper__closed",bold:!0,color:"transparent",icon:l[g][C].open?l[g][C].bomb?"bomb":"":l[g][C].flag?"flag":"",textColor:l[g][C].open?l[g][C].bomb?"black":d[l[g][C].around]:l[g][C].flag?"red":"gray",onClick:function(){function f(N){return v(g,C,"bomb")}return f}(),onContextMenu:function(){function f(N){event.preventDefault(),v(g,C,"flag")}return f}(),children:l[g][C].open&&!l[g][C].bomb&&l[g][C].around?l[g][C].around:" "},C)})},g)})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,className:"Minesweeper__infobox",children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,textAlign:"left",pt:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{pl:2,fontSize:2,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"bomb",color:"gray"})," : ",s]}),(0,e.createComponentVNode)(2,t.Stack.Divider),(0,e.createComponentVNode)(2,t.Stack.Item,{pl:2,fontSize:2,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"flag",color:"red"})," : ",u]})]})})]})}return S}(),b=r.MineSweeperLeaderboard=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.leaderboard,u=(0,a.useLocalState)(h,"sortId","time"),s=u[0],d=u[1],v=(0,a.useLocalState)(h,"sortOrder",!1),g=v[0],C=v[1];return(0,e.createComponentVNode)(2,t.Table,{className:"Minesweeper__list",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,y,{id:"name",children:"Nick"}),(0,e.createComponentVNode)(2,y,{id:"time",children:"Time"})]}),l&&l.sort(function(f,N){var V=g?1:-1;return f[s].localeCompare(N[s])*V}).map(function(f,N){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.time})]},N)})]})}return S}(),y=function(k,h){var i=(0,a.useLocalState)(h,"sortId","time"),c=i[0],m=i[1],l=(0,a.useLocalState)(h,"sortOrder",!1),u=l[0],s=l[1],d=k.id,v=k.children;return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,color:"transparent",onClick:function(){function g(){c===d?s(!u):(m(d),s(!0))}return g}(),children:[v,c===d&&(0,e.createComponentVNode)(2,t.Icon,{name:u?"sort-up":"sort-down",ml:"0.25rem;"})]})})}},24635:function(T,r,n){"use strict";r.__esModule=!0,r.pda_mule=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.pda_mule=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.mulebot,l=m.active;return(0,e.createComponentVNode)(2,t.Box,{children:l?(0,e.createComponentVNode)(2,b):(0,e.createComponentVNode)(2,p)})}return y}(),p=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.mulebot,l=m.bots;return l.map(function(u){return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:u.Name,icon:"cog",onClick:function(){function s(){return i("control",{bot:u.uid})}return s}()})},u.Name)})},b=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.mulebot,l=m.botstatus,u=m.active,s=l.mode,d=l.loca,v=l.load,g=l.powr,C=l.dest,f=l.home,N=l.retn,V=l.pick,B;switch(s){case 0:B="Ready";break;case 1:B="Loading/Unloading";break;case 2:case 12:B="Navigating to delivery location";break;case 3:B="Navigating to Home";break;case 4:B="Waiting for clear path";break;case 5:case 6:B="Calculating navigation path";break;case 7:B="Unable to locate destination";break;default:B=s;break}return(0,e.createComponentVNode)(2,t.Section,{title:u,children:[s===-1&&(0,e.createComponentVNode)(2,t.Box,{color:"red",bold:!0,children:"Waiting for response..."}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Location",children:d}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:B}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:[g,"%"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Home",children:f}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Destination",children:(0,e.createComponentVNode)(2,t.Button,{content:C?C+" (Set)":"None (Set)",onClick:function(){function I(){return i("target")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Load",children:(0,e.createComponentVNode)(2,t.Button,{content:v?v+" (Unload)":"None",disabled:!v,onClick:function(){function I(){return i("unload")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auto Pickup",children:(0,e.createComponentVNode)(2,t.Button,{content:V?"Yes":"No",selected:V,onClick:function(){function I(){return i("set_pickup_type",{autopick:V?0:1})}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auto Return",children:(0,e.createComponentVNode)(2,t.Button,{content:N?"Yes":"No",selected:N,onClick:function(){function I(){return i("set_auto_return",{autoret:N?0:1})}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Controls",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Stop",icon:"stop",onClick:function(){function I(){return i("stop")}return I}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Proceed",icon:"play",onClick:function(){function I(){return i("start")}return I}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Return Home",icon:"home",onClick:function(){function I(){return i("home")}return I}()})]})]})]})}},23734:function(T,r,n){"use strict";r.__esModule=!0,r.pda_nanobank=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=r.pda_nanobank=function(){function l(u,s){var d=(0,t.useBackend)(s),v=d.act,g=d.data,C=g.logged_in,f=g.owner_name,N=g.money;return C?(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Box,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Name",children:f}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Balance",children:["$",N]})]})}),(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,y)]})],4):(0,e.createComponentVNode)(2,i)}return l}(),b=function(u,s){var d=(0,t.useBackend)(s),v=d.data,g=v.is_premium,C=(0,t.useLocalState)(s,"tabIndex",1),f=C[0],N=C[1];return(0,e.createComponentVNode)(2,o.Tabs,{mt:2,children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:f===1,onClick:function(){function V(){return N(1)}return V}(),children:[(0,e.createComponentVNode)(2,o.Icon,{mr:1,name:"list"}),"Transfers"]}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:f===2,onClick:function(){function V(){return N(2)}return V}(),children:[(0,e.createComponentVNode)(2,o.Icon,{mr:1,name:"list"}),"Account Actions"]}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:f===3,onClick:function(){function V(){return N(3)}return V}(),children:[(0,e.createComponentVNode)(2,o.Icon,{mr:1,name:"list"}),"Transaction History"]}),!!g&&(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:f===4,onClick:function(){function V(){return N(4)}return V}(),children:[(0,e.createComponentVNode)(2,o.Icon,{mr:1,name:"list"}),"Supply Orders"]})]})},y=function(u,s){var d=(0,t.useLocalState)(s,"tabIndex",1),v=d[0],g=(0,t.useBackend)(s),C=g.data,f=C.db_status;if(!f)return(0,e.createComponentVNode)(2,o.Box,{children:"Account Database Connection Severed"});switch(v){case 1:return(0,e.createComponentVNode)(2,S);case 2:return(0,e.createComponentVNode)(2,k);case 3:return(0,e.createComponentVNode)(2,h);case 4:return(0,e.createComponentVNode)(2,m);default:return"You are somehow on a tab that doesn't exist! Please let a coder know."}},S=function(u,s){var d,v=(0,t.useBackend)(s),g=v.act,C=v.data,f=C.requests,N=C.available_accounts,V=C.money,B=(0,t.useLocalState)(s,"selectedAccount"),I=B[0],L=B[1],w=(0,t.useLocalState)(s,"transferAmount"),A=w[0],x=w[1],E=(0,t.useLocalState)(s,"searchText",""),P=E[0],D=E[1],M=[];return N.map(function(O){return M[O.name]=O.UID}),(0,e.createFragment)([(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account",children:[(0,e.createComponentVNode)(2,o.Input,{placeholder:"Search by account name",onInput:function(){function O(R,F){return D(F)}return O}()}),(0,e.createComponentVNode)(2,o.Dropdown,{mt:.6,width:"190px",options:N.filter((0,a.createSearch)(P,function(O){return O.name})).map(function(O){return O.name}),selected:(d=N.filter(function(O){return O.UID===I})[0])==null?void 0:d.name,onSelected:function(){function O(R){return L(M[R])}return O}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Amount",children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"Up to 5000",onInput:function(){function O(R,F){return x(F)}return O}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Actions",children:[(0,e.createComponentVNode)(2,o.Button.Confirm,{bold:!0,icon:"paper-plane",width:"auto",disabled:V0&&d.map(function(g){return(0,e.createComponentVNode)(2,t.Box,{children:["#",g.Number,' - "',g.Name,'" for "',g.OrderedBy,'"']},g)})}),(0,e.createComponentVNode)(2,t.Section,{title:"Approved Orders",children:s>0&&u.map(function(g){return(0,e.createComponentVNode)(2,t.Box,{children:["#",g.Number,' - "',g.Name,'" for "',g.ApprovedBy,'"']},g)})})]})}return p}()},17617:function(T,r,n){"use strict";r.__esModule=!0,r.Layout=void 0;var e=n(89005),a=n(35840),t=n(55937),o=n(24826),p=["className","theme","children"],b=["className","scrollable","children"];/**
+ */var b=r.goonstation_PTL=function(){function h(i,c){var m=(0,a.useBackend)(c),l=m.data,u=l.total_earnings,s=l.total_energy,d=l.name,C=d===void 0?"Power Transmission Laser":d;return(0,e.createComponentVNode)(2,p.Window,{title:"Power Transmission Laser",width:"310",height:"485",children:(0,e.createComponentVNode)(2,p.Window.Content,{children:[(0,e.createComponentVNode)(2,y),(0,e.createComponentVNode)(2,S),(0,e.createComponentVNode)(2,k),(0,e.createComponentVNode)(2,t.NoticeBox,{success:!0,children:["Earned Credits : ",u?(0,o.formatMoney)(u):0]}),(0,e.createComponentVNode)(2,t.NoticeBox,{success:!0,children:["Energy Sold : ",s?(0,o.formatSiUnit)(s,0,"J"):"0 J"]})]})})}return h}(),y=function(i,c){var m=(0,a.useBackend)(c),l=m.data,u=l.max_capacity,s=l.held_power,d=l.input_total,C=l.max_grid_load;return(0,e.createComponentVNode)(2,t.Section,{title:"Status",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Reserve energy",children:s?(0,o.formatSiUnit)(s,0,"J"):"0 J"})}),(0,e.createComponentVNode)(2,t.ProgressBar,{mt:"0.5em",mb:"0.5em",ranges:{good:[.8,1/0],average:[.5,.8],bad:[-1/0,.5]},value:s/u}),(0,e.createComponentVNode)(2,t.LabeledList,{children:(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Grid Saturation"})}),(0,e.createComponentVNode)(2,t.ProgressBar,{mt:"0.5em",ranges:{good:[.8,1/0],average:[.5,.8],bad:[-1/0,.5]},value:Math.min(d,u-s)/C})]})},S=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.input_total,d=u.accepting_power,C=u.sucking_power,g=u.input_number,v=u.power_format;return(0,e.createComponentVNode)(2,t.Section,{title:"Input Controls",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Input Circuit",buttons:(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",color:d?"green":"red",onClick:function(){function f(){return l("toggle_input")}return f}(),children:d?"Enabled":"Disabled"}),children:(0,e.createComponentVNode)(2,t.Box,{color:C&&"good"||d&&"average"||"bad",children:C&&"Online"||d&&"Idle"||"Offline"})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Input Level",children:s?(0,o.formatPower)(s):"0 W"})]}),(0,e.createComponentVNode)(2,t.Box,{mt:"0.5em",children:[(0,e.createComponentVNode)(2,t.NumberInput,{mr:"0.5em",animated:!0,size:1.25,inline:!0,step:1,stepPixelSize:2,minValue:0,maxValue:999,value:g,onChange:function(){function f(N,V){return l("set_input",{set_input:V})}return f}()}),(0,e.createComponentVNode)(2,t.Button,{selected:v===1,onClick:function(){function f(){return l("inputW")}return f}(),children:"W"}),(0,e.createComponentVNode)(2,t.Button,{selected:v===Math.pow(10,3),onClick:function(){function f(){return l("inputKW")}return f}(),children:"KW"}),(0,e.createComponentVNode)(2,t.Button,{selected:v===Math.pow(10,6),onClick:function(){function f(){return l("inputMW")}return f}(),children:"MW"}),(0,e.createComponentVNode)(2,t.Button,{selected:v===Math.pow(10,9),onClick:function(){function f(){return l("inputGW")}return f}(),children:"GW"})]})]})},k=function(i,c){var m=(0,a.useBackend)(c),l=m.act,u=m.data,s=u.output_total,d=u.firing,C=u.accepting_power,g=u.output_number,v=u.output_multiplier,f=u.target,N=u.held_power;return(0,e.createComponentVNode)(2,t.Section,{title:"Output Controls",children:[(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Laser Circuit",buttons:(0,e.createComponentVNode)(2,t.Stack,{Horizontal:!0,children:[(0,e.createComponentVNode)(2,t.Button,{icon:"crosshairs",color:f===""?"green":"red",onClick:function(){function V(){return l("target")}return V}(),children:f}),(0,e.createComponentVNode)(2,t.Button,{icon:"power-off",color:d?"green":"red",disabled:!d&&Nu,onClick:function(){function B(){return k("purchaseSoftware",{key:V.key})}return B}()},V.key)}),c.filter(function(V){return!N[V.key]}).length===0&&"No software available!"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Installed Software",children:[m.filter(function(V){return V.key!=="mainmenu"}).map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,icon:V.icon,onClick:function(){function B(){return k("startSoftware",{software_key:V.key})}return B}()},V.key)}),m.length===0&&"No software installed!"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Installed Toggles",children:[l.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,icon:V.icon,selected:V.active,onClick:function(){function B(){return k("setToggle",{toggle_key:V.key})}return B}()},V.key)}),l.length===0&&"No toggles installed!"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Emotion",children:s.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,selected:V.id===d,onClick:function(){function B(){return k("setEmotion",{emotion:V.id})}return B}()},V.id)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Speaking State",children:C.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,selected:V.name===g,onClick:function(){function B(){return k("setSpeechStyle",{speech_state:V.name})}return B}()},V.id)})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Select Chassis Type",children:v.map(function(V){return(0,e.createComponentVNode)(2,t.Button,{content:V.name,selected:V.icon===f,onClick:function(){function B(){return k("setChassis",{chassis_to_change:V.icon})}return B}()},V.id)})})]})})}return p}()},2983:function(T,r,n){"use strict";r.__esModule=!0,r.pai_manifest=void 0;var e=n(89005),a=n(72253),t=n(41874),o=r.pai_manifest=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data;return(0,e.createComponentVNode)(2,t.CrewManifest,{data:h.app_data})}return p}()},40758:function(T,r,n){"use strict";r.__esModule=!0,r.pai_medrecords=void 0;var e=n(89005),a=n(72253),t=n(41984),o=r.pai_medrecords=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data;return(0,e.createComponentVNode)(2,t.SimpleRecords,{data:k.app_data,recordType:"MED"})}return p}()},98599:function(T,r,n){"use strict";r.__esModule=!0,r.pai_messenger=void 0;var e=n(89005),a=n(72253),t=n(77595),o=r.pai_messenger=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.app_data.active_convo;return i?(0,e.createComponentVNode)(2,t.ActiveConversation,{data:h.app_data}):(0,e.createComponentVNode)(2,t.MessengerList,{data:h.app_data})}return p}()},50775:function(T,r,n){"use strict";r.__esModule=!0,r.pai_radio=void 0;var e=n(89005),a=n(72253),t=n(44879),o=n(36036),p=r.pai_radio=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.app_data,m=c.minFrequency,l=c.maxFrequency,u=c.frequency,s=c.broadcasting;return(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Frequency",children:[(0,e.createComponentVNode)(2,o.NumberInput,{animate:!0,step:.2,stepPixelSize:6,minValue:m/10,maxValue:l/10,value:u/10,format:function(){function d(C){return(0,t.toFixed)(C,1)}return d}(),onChange:function(){function d(C,g){return h("freq",{freq:g})}return d}()}),(0,e.createComponentVNode)(2,o.Button,{tooltip:"Reset",icon:"undo",onClick:function(){function d(){return h("freq",{freq:"145.9"})}return d}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Broadcast Nearby Speech",children:(0,e.createComponentVNode)(2,o.Button,{onClick:function(){function d(){return h("toggleBroadcast")}return d}(),selected:s,content:s?"Enabled":"Disabled"})})]})}return b}()},48623:function(T,r,n){"use strict";r.__esModule=!0,r.pai_secrecords=void 0;var e=n(89005),a=n(72253),t=n(41984),o=r.pai_secrecords=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data;return(0,e.createComponentVNode)(2,t.SimpleRecords,{data:k.app_data,recordType:"SEC"})}return p}()},47297:function(T,r,n){"use strict";r.__esModule=!0,r.pai_signaler=void 0;var e=n(89005),a=n(72253),t=n(13545),o=r.pai_signaler=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data;return(0,e.createComponentVNode)(2,t.Signaler,{data:h.app_data})}return p}()},78532:function(T,r,n){"use strict";r.__esModule=!0,r.pda_atmos_scan=void 0;var e=n(89005),a=n(72253),t=n(26991),o=r.pda_atmos_scan=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data;return(0,e.createComponentVNode)(2,t.AtmosScan,{data:k})}return p}()},2395:function(T,r,n){"use strict";r.__esModule=!0,r.pda_games=void 0;var e=n(89005),a=n(72253),t=n(36036),o=n(1331),p=r.pda_games=function(){function b(y,S){var k=(0,a.useBackend)(S),h=k.act,i=k.data,c=i.games,m=function(){function l(u){switch(u){case"Minesweeper":return(0,e.createComponentVNode)(2,o.IconStack,{children:[(0,e.createComponentVNode)(2,o.Icon,{ml:"0",mt:"10px",name:"flag",size:"6",color:"gray",rotation:30}),(0,e.createComponentVNode)(2,o.Icon,{ml:"9px",mt:"23px",name:"bomb",size:"3",color:"black"})]});default:return(0,e.createComponentVNode)(2,o.Icon,{ml:"16px",mt:"10px",name:"gamepad",size:"6"})}}return l}();return(0,e.createComponentVNode)(2,t.Box,{children:c.map(function(l){return(0,e.createComponentVNode)(2,t.Button,{width:"33%",textAlign:"center",translucent:!0,onClick:function(){function u(){return h("play",{id:l.id})}return u}(),children:[m(l.name),(0,e.createComponentVNode)(2,t.Box,{children:l.name})]},l.name)})})}return b}()},40253:function(T,r,n){"use strict";r.__esModule=!0,r.pda_janitor=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.pda_janitor=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data,i=h.janitor,c=i.user_loc,m=i.mops,l=i.buckets,u=i.cleanbots,s=i.carts,d=i.janicarts;return(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Location",children:[c.x,",",c.y]}),m&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mop Locations",children:m.map(function(C){return(0,e.createComponentVNode)(2,t.Box,{children:[C.x,",",C.y," (",C.dir,") - ",C.status]},C)})}),l&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Mop Bucket Locations",children:l.map(function(C){return(0,e.createComponentVNode)(2,t.Box,{children:[C.x,",",C.y," (",C.dir,") - [",C.volume,"/",C.max_volume,"]"]},C)})}),u&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Cleanbot Locations",children:u.map(function(C){return(0,e.createComponentVNode)(2,t.Box,{children:[C.x,",",C.y," (",C.dir,") - ",C.status]},C)})}),s&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Janitorial Cart Locations",children:s.map(function(C){return(0,e.createComponentVNode)(2,t.Box,{children:[C.x,",",C.y," (",C.dir,") - [",C.volume,"/",C.max_volume,"]"]},C)})}),d&&(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Janicart Locations",children:d.map(function(C){return(0,e.createComponentVNode)(2,t.Box,{children:[C.x,",",C.y," (",C.direction_from_user,")"]},C)})})]})}return p}()},58293:function(T,r,n){"use strict";r.__esModule=!0,r.pda_main_menu=void 0;var e=n(89005),a=n(44879),t=n(72253),o=n(36036),p=r.pda_main_menu=function(){function b(y,S){var k=(0,t.useBackend)(S),h=k.act,i=k.data,c=i.owner,m=i.ownjob,l=i.idInserted,u=i.categories,s=i.pai,d=i.notifying;return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Owner",color:"average",children:[c,", ",m]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"ID",children:(0,e.createComponentVNode)(2,o.Button,{icon:"sync",content:"Update PDA Info",disabled:!l,onClick:function(){function C(){return h("UpdateInfo")}return C}()})})]})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:(0,e.createComponentVNode)(2,o.Section,{title:"Functions",children:(0,e.createComponentVNode)(2,o.LabeledList,{children:u.map(function(C){var g=i.apps[C];return!g||!g.length?null:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:C,children:g.map(function(v){return(0,e.createComponentVNode)(2,o.Button,{icon:v.uid in d?v.notify_icon:v.icon,iconSpin:v.uid in d,color:v.uid in d?"red":"transparent",content:v.name,onClick:function(){function f(){return h("StartProgram",{program:v.uid})}return f}()},v.uid)})},C)})})})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:!!s&&(0,e.createComponentVNode)(2,o.Section,{title:"pAI",children:[(0,e.createComponentVNode)(2,o.Button,{fluid:!0,icon:"cog",content:"Configuration",onClick:function(){function C(){return h("pai",{option:1})}return C}()}),(0,e.createComponentVNode)(2,o.Button,{fluid:!0,icon:"eject",content:"Eject pAI",onClick:function(){function C(){return h("pai",{option:2})}return C}()})]})})]})}return b}()},58059:function(T,r,n){"use strict";r.__esModule=!0,r.pda_manifest=void 0;var e=n(89005),a=n(72253),t=n(41874),o=r.pda_manifest=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.act,h=S.data;return(0,e.createComponentVNode)(2,t.CrewManifest)}return p}()},18147:function(T,r,n){"use strict";r.__esModule=!0,r.pda_medical=void 0;var e=n(89005),a=n(72253),t=n(41984),o=r.pda_medical=function(){function p(b,y){var S=(0,a.useBackend)(y),k=S.data;return(0,e.createComponentVNode)(2,t.SimpleRecords,{data:k,recordType:"MED"})}return p}()},77595:function(T,r,n){"use strict";r.__esModule=!0,r.pda_messenger=r.MessengerList=r.ActiveConversation=void 0;var e=n(89005),a=n(88510),t=n(72253),o=n(36036),p=r.pda_messenger=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=c.data,u=l.active_convo;return u?(0,e.createComponentVNode)(2,b,{data:l}):(0,e.createComponentVNode)(2,y,{data:l})}return k}(),b=r.ActiveConversation=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=h.data,u=l.convo_name,s=l.convo_job,d=l.messages,C=l.active_convo,g=(0,t.useLocalState)(i,"clipboardMode",!1),v=g[0],f=g[1],N=(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Conversation with "+u+" ("+s+")",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{icon:"eye",selected:v,tooltip:"Enter Clipboard Mode",tooltipPosition:"bottom-start",onClick:function(){function V(){return f(!v)}return V}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"comment",onClick:function(){function V(){return m("Message",{target:C})}return V}(),content:"Reply"})],4),children:(0,a.filter)(function(V){return V.target===C})(d).map(function(V,B){return(0,e.createComponentVNode)(2,o.Box,{textAlign:V.sent?"right":"left",position:"relative",mb:1,children:[(0,e.createComponentVNode)(2,o.Icon,{fontSize:2.5,color:V.sent?"#4d9121":"#cd7a0d",position:"absolute",left:V.sent?null:"0px",right:V.sent?"0px":null,bottom:"-4px",style:{"z-index":"0",transform:V.sent?"scale(-1, 1)":null},name:"comment"}),(0,e.createComponentVNode)(2,o.Box,{inline:!0,backgroundColor:V.sent?"#4d9121":"#cd7a0d",p:1,maxWidth:"100%",position:"relative",textAlign:V.sent?"left":"right",style:{"z-index":"1","border-radius":"10px","word-break":"normal"},children:[V.sent?"You:":"Them:"," ",V.message]})]},B)})});return v&&(N=(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:"Conversation with "+u+" ("+s+")",buttons:(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Button,{icon:"eye",selected:v,tooltip:"Exit Clipboard Mode",tooltipPosition:"bottom-start",onClick:function(){function V(){return f(!v)}return V}()}),(0,e.createComponentVNode)(2,o.Button,{icon:"comment",onClick:function(){function V(){return m("Message",{target:C})}return V}(),content:"Reply"})],4),children:(0,a.filter)(function(V){return V.target===C})(d).map(function(V,B){return(0,e.createComponentVNode)(2,o.Box,{color:V.sent?"#4d9121":"#cd7a0d",style:{"word-break":"normal"},children:[V.sent?"You:":"Them:"," ",(0,e.createComponentVNode)(2,o.Box,{inline:!0,children:V.message})]},B)})})),(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{mb:.5,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Messenger Functions",children:(0,e.createComponentVNode)(2,o.Button.Confirm,{content:"Delete Conversations",confirmContent:"Are you sure?",icon:"trash",confirmIcon:"trash",onClick:function(){function V(){return m("Clear",{option:"Convo"})}return V}()})})})}),N]})}return k}(),y=r.MessengerList=function(){function k(h,i){var c=(0,t.useBackend)(i),m=c.act,l=h.data,u=l.convopdas,s=l.pdas,d=l.charges,C=l.silent,g=l.toff,v=l.ringtone_list,f=l.ringtone,N=(0,t.useLocalState)(i,"searchTerm",""),V=N[0],B=N[1];return(0,e.createComponentVNode)(2,o.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{mb:5,children:[(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Messenger Functions",children:[(0,e.createComponentVNode)(2,o.Button,{selected:!C,icon:C?"volume-mute":"volume-up",onClick:function(){function I(){return m("Toggle Ringer")}return I}(),children:["Ringer: ",C?"Off":"On"]}),(0,e.createComponentVNode)(2,o.Button,{color:g?"bad":"green",icon:"power-off",onClick:function(){function I(){return m("Toggle Messenger")}return I}(),children:["Messenger: ",g?"Off":"On"]}),(0,e.createComponentVNode)(2,o.Button,{icon:"trash",color:"bad",onClick:function(){function I(){return m("Clear",{option:"All"})}return I}(),children:"Delete All Conversations"}),(0,e.createComponentVNode)(2,o.Button,{icon:"bell",onClick:function(){function I(){return m("Ringtone")}return I}(),children:"Set Custom Ringtone"}),(0,e.createComponentVNode)(2,o.Dropdown,{selected:f,width:"100px",options:Object.keys(v),onSelected:function(){function I(L){return m("Available_Ringtones",{selected_ringtone:L})}return I}()})]})}),!g&&(0,e.createComponentVNode)(2,o.Box,{children:[!!d&&(0,e.createComponentVNode)(2,o.Box,{mt:.5,mb:1,children:(0,e.createComponentVNode)(2,o.LabeledList,{children:(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Cartridge Special Function",children:[d," charges left."]})})}),!u.length&&!s.length&&(0,e.createComponentVNode)(2,o.Box,{children:"No current conversations"})||(0,e.createComponentVNode)(2,o.Box,{children:["Search:"," ",(0,e.createComponentVNode)(2,o.Input,{mt:.5,value:V,onInput:function(){function I(L,w){B(w)}return I}()})]})]})||(0,e.createComponentVNode)(2,o.Box,{color:"bad",children:"Messenger Offline."})]}),(0,e.createComponentVNode)(2,S,{title:"Current Conversations",data:l,pdas:u,msgAct:"Select Conversation",searchTerm:V}),(0,e.createComponentVNode)(2,S,{title:"Other PDAs",pdas:s,msgAct:"Message",data:l,searchTerm:V})]})}return k}(),S=function(h,i){var c=(0,t.useBackend)(i),m=c.act,l=h.data,u=h.pdas,s=h.title,d=h.msgAct,C=h.searchTerm,g=l.charges,v=l.plugins;return!u||!u.length?(0,e.createComponentVNode)(2,o.Section,{title:s,children:"No PDAs found."}):(0,e.createComponentVNode)(2,o.Section,{fill:!0,scrollable:!0,title:s,children:u.filter(function(f){return f.Name.toLowerCase().includes(C.toLowerCase())}).map(function(f){return(0,e.createComponentVNode)(2,o.Stack,{m:.5,children:[(0,e.createComponentVNode)(2,o.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,o.Button,{fluid:!0,icon:"arrow-circle-down",content:f.Name,onClick:function(){function N(){return m(d,{target:f.uid})}return N}()})}),(0,e.createComponentVNode)(2,o.Stack.Item,{children:!!g&&v.map(function(N){return(0,e.createComponentVNode)(2,o.Button,{icon:N.icon,content:N.name,onClick:function(){function V(){return m("Messenger Plugin",{plugin:N.uid,target:f.uid})}return V}()},N.uid)})})]},f.uid)})})}},90382:function(T,r,n){"use strict";r.__esModule=!0,r.pda_minesweeper=r.MineSweeperLeaderboard=r.MineSweeperGame=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.pda_minesweeper=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=(0,a.useLocalState)(h,"window","Game"),u=l[0],s=l[1],d={Game:"Leaderboard",Leaderboard:"Game"};return(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,textAlign:"center",children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:u==="Game"?(0,e.createComponentVNode)(2,p):(0,e.createComponentVNode)(2,b)}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:!0,fontSize:2,lineHeight:1.75,icon:u==="Game"?"book":"gamepad",onClick:function(){function C(){return s(d[u])}return C}(),children:d[u]})})]})}return S}(),p=r.MineSweeperGame=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.matrix,u=m.flags,s=m.bombs,d={1:"blue",2:"green",3:"red",4:"darkblue",5:"brown",6:"lightblue",7:"black",8:"white"},C=function(){function g(v,f,N){c("Square",{X:v,Y:f,mode:N})}return g}();return(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:Object.keys(l).map(function(g){return(0,e.createComponentVNode)(2,t.Box,{children:Object.keys(l[g]).map(function(v){return(0,e.createComponentVNode)(2,t.Button,{m:.25,height:2,width:2,className:l[g][v].open?"Minesweeper__open":"Minesweeper__closed",bold:!0,color:"transparent",icon:l[g][v].open?l[g][v].bomb?"bomb":"":l[g][v].flag?"flag":"",textColor:l[g][v].open?l[g][v].bomb?"black":d[l[g][v].around]:l[g][v].flag?"red":"gray",onClick:function(){function f(N){return C(g,v,"bomb")}return f}(),onContextMenu:function(){function f(N){event.preventDefault(),C(g,v,"flag")}return f}(),children:l[g][v].open&&!l[g][v].bomb&&l[g][v].around?l[g][v].around:" "},v)})},g)})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,className:"Minesweeper__infobox",children:(0,e.createComponentVNode)(2,t.Stack,{vertical:!0,textAlign:"left",pt:1,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{pl:2,fontSize:2,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"bomb",color:"gray"})," : ",s]}),(0,e.createComponentVNode)(2,t.Stack.Divider),(0,e.createComponentVNode)(2,t.Stack.Item,{pl:2,fontSize:2,children:[(0,e.createComponentVNode)(2,t.Icon,{name:"flag",color:"red"})," : ",u]})]})})]})}return S}(),b=r.MineSweeperLeaderboard=function(){function S(k,h){var i=(0,a.useBackend)(h),c=i.act,m=i.data,l=m.leaderboard,u=(0,a.useLocalState)(h,"sortId","time"),s=u[0],d=u[1],C=(0,a.useLocalState)(h,"sortOrder",!1),g=C[0],v=C[1];return(0,e.createComponentVNode)(2,t.Table,{className:"Minesweeper__list",children:[(0,e.createComponentVNode)(2,t.Table.Row,{bold:!0,children:[(0,e.createComponentVNode)(2,y,{id:"name",children:"Nick"}),(0,e.createComponentVNode)(2,y,{id:"time",children:"Time"})]}),l&&l.sort(function(f,N){var V=g?1:-1;return f[s].localeCompare(N[s])*V}).map(function(f,N){return(0,e.createComponentVNode)(2,t.Table.Row,{children:[(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.name}),(0,e.createComponentVNode)(2,t.Table.Cell,{children:f.time})]},N)})]})}return S}(),y=function(k,h){var i=(0,a.useLocalState)(h,"sortId","time"),c=i[0],m=i[1],l=(0,a.useLocalState)(h,"sortOrder",!1),u=l[0],s=l[1],d=k.id,C=k.children;return(0,e.createComponentVNode)(2,t.Table.Cell,{children:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,color:"transparent",onClick:function(){function g(){c===d?s(!u):(m(d),s(!0))}return g}(),children:[C,c===d&&(0,e.createComponentVNode)(2,t.Icon,{name:u?"sort-up":"sort-down",ml:"0.25rem;"})]})})}},24635:function(T,r,n){"use strict";r.__esModule=!0,r.pda_mule=void 0;var e=n(89005),a=n(72253),t=n(36036),o=r.pda_mule=function(){function y(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.mulebot,l=m.active;return(0,e.createComponentVNode)(2,t.Box,{children:l?(0,e.createComponentVNode)(2,b):(0,e.createComponentVNode)(2,p)})}return y}(),p=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.mulebot,l=m.bots;return l.map(function(u){return(0,e.createComponentVNode)(2,t.Box,{children:(0,e.createComponentVNode)(2,t.Button,{content:u.Name,icon:"cog",onClick:function(){function s(){return i("control",{bot:u.uid})}return s}()})},u.Name)})},b=function(S,k){var h=(0,a.useBackend)(k),i=h.act,c=h.data,m=c.mulebot,l=m.botstatus,u=m.active,s=l.mode,d=l.loca,C=l.load,g=l.powr,v=l.dest,f=l.home,N=l.retn,V=l.pick,B;switch(s){case 0:B="Ready";break;case 1:B="Loading/Unloading";break;case 2:case 12:B="Navigating to delivery location";break;case 3:B="Navigating to Home";break;case 4:B="Waiting for clear path";break;case 5:case 6:B="Calculating navigation path";break;case 7:B="Unable to locate destination";break;default:B=s;break}return(0,e.createComponentVNode)(2,t.Section,{title:u,children:[s===-1&&(0,e.createComponentVNode)(2,t.Box,{color:"red",bold:!0,children:"Waiting for response..."}),(0,e.createComponentVNode)(2,t.LabeledList,{children:[(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Location",children:d}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Status",children:B}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Power",children:[g,"%"]}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Home",children:f}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Destination",children:(0,e.createComponentVNode)(2,t.Button,{content:v?v+" (Set)":"None (Set)",onClick:function(){function I(){return i("target")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Current Load",children:(0,e.createComponentVNode)(2,t.Button,{content:C?C+" (Unload)":"None",disabled:!C,onClick:function(){function I(){return i("unload")}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auto Pickup",children:(0,e.createComponentVNode)(2,t.Button,{content:V?"Yes":"No",selected:V,onClick:function(){function I(){return i("set_pickup_type",{autopick:V?0:1})}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Auto Return",children:(0,e.createComponentVNode)(2,t.Button,{content:N?"Yes":"No",selected:N,onClick:function(){function I(){return i("set_auto_return",{autoret:N?0:1})}return I}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Controls",children:[(0,e.createComponentVNode)(2,t.Button,{content:"Stop",icon:"stop",onClick:function(){function I(){return i("stop")}return I}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Proceed",icon:"play",onClick:function(){function I(){return i("start")}return I}()}),(0,e.createComponentVNode)(2,t.Button,{content:"Return Home",icon:"home",onClick:function(){function I(){return i("home")}return I}()})]})]})]})}},23734:function(T,r,n){"use strict";r.__esModule=!0,r.pda_nanobank=void 0;var e=n(89005),a=n(25328),t=n(72253),o=n(36036),p=r.pda_nanobank=function(){function l(u,s){var d=(0,t.useBackend)(s),C=d.act,g=d.data,v=g.logged_in,f=g.owner_name,N=g.money;return v?(0,e.createFragment)([(0,e.createComponentVNode)(2,o.Box,{children:(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Name",children:f}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account Balance",children:["$",N]})]})}),(0,e.createComponentVNode)(2,o.Box,{children:[(0,e.createComponentVNode)(2,b),(0,e.createComponentVNode)(2,y)]})],4):(0,e.createComponentVNode)(2,i)}return l}(),b=function(u,s){var d=(0,t.useBackend)(s),C=d.data,g=C.is_premium,v=(0,t.useLocalState)(s,"tabIndex",1),f=v[0],N=v[1];return(0,e.createComponentVNode)(2,o.Tabs,{mt:2,children:[(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:f===1,onClick:function(){function V(){return N(1)}return V}(),children:[(0,e.createComponentVNode)(2,o.Icon,{mr:1,name:"list"}),"Transfers"]}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:f===2,onClick:function(){function V(){return N(2)}return V}(),children:[(0,e.createComponentVNode)(2,o.Icon,{mr:1,name:"list"}),"Account Actions"]}),(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:f===3,onClick:function(){function V(){return N(3)}return V}(),children:[(0,e.createComponentVNode)(2,o.Icon,{mr:1,name:"list"}),"Transaction History"]}),!!g&&(0,e.createComponentVNode)(2,o.Tabs.Tab,{selected:f===4,onClick:function(){function V(){return N(4)}return V}(),children:[(0,e.createComponentVNode)(2,o.Icon,{mr:1,name:"list"}),"Supply Orders"]})]})},y=function(u,s){var d=(0,t.useLocalState)(s,"tabIndex",1),C=d[0],g=(0,t.useBackend)(s),v=g.data,f=v.db_status;if(!f)return(0,e.createComponentVNode)(2,o.Box,{children:"Account Database Connection Severed"});switch(C){case 1:return(0,e.createComponentVNode)(2,S);case 2:return(0,e.createComponentVNode)(2,k);case 3:return(0,e.createComponentVNode)(2,h);case 4:return(0,e.createComponentVNode)(2,m);default:return"You are somehow on a tab that doesn't exist! Please let a coder know."}},S=function(u,s){var d,C=(0,t.useBackend)(s),g=C.act,v=C.data,f=v.requests,N=v.available_accounts,V=v.money,B=(0,t.useLocalState)(s,"selectedAccount"),I=B[0],L=B[1],w=(0,t.useLocalState)(s,"transferAmount"),A=w[0],x=w[1],E=(0,t.useLocalState)(s,"searchText",""),P=E[0],D=E[1],M=[];return N.map(function(O){return M[O.name]=O.UID}),(0,e.createFragment)([(0,e.createComponentVNode)(2,o.LabeledList,{children:[(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Account",children:[(0,e.createComponentVNode)(2,o.Input,{placeholder:"Search by account name",onInput:function(){function O(R,F){return D(F)}return O}()}),(0,e.createComponentVNode)(2,o.Dropdown,{mt:.6,width:"190px",options:N.filter((0,a.createSearch)(P,function(O){return O.name})).map(function(O){return O.name}),selected:(d=N.filter(function(O){return O.UID===I})[0])==null?void 0:d.name,onSelected:function(){function O(R){return L(M[R])}return O}()})]}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Amount",children:(0,e.createComponentVNode)(2,o.Input,{placeholder:"Up to 5000",onInput:function(){function O(R,F){return x(F)}return O}()})}),(0,e.createComponentVNode)(2,o.LabeledList.Item,{label:"Actions",children:[(0,e.createComponentVNode)(2,o.Button.Confirm,{bold:!0,icon:"paper-plane",width:"auto",disabled:V0&&d.map(function(g){return(0,e.createComponentVNode)(2,t.Box,{children:["#",g.Number,' - "',g.Name,'" for "',g.OrderedBy,'"']},g)})}),(0,e.createComponentVNode)(2,t.Section,{title:"Approved Orders",children:s>0&&u.map(function(g){return(0,e.createComponentVNode)(2,t.Box,{children:["#",g.Number,' - "',g.Name,'" for "',g.ApprovedBy,'"']},g)})})]})}return p}()},17617:function(T,r,n){"use strict";r.__esModule=!0,r.Layout=void 0;var e=n(89005),a=n(35840),t=n(55937),o=n(24826),p=["className","theme","children"],b=["className","scrollable","children"];/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
@@ -259,11 +259,11 @@
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
- */function k(c,m){if(c==null)return{};var l={};for(var u in c)if({}.hasOwnProperty.call(c,u)){if(m.includes(u))continue;l[u]=c[u]}return l}var h=r.Pane=function(){function c(m,l){var u=m.theme,s=m.children,d=m.className,v=k(m,y),g=(0,t.useBackend)(l),C=g.suspended,f=(0,p.useDebug)(l),N=f.debugLayout;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,b.Layout,Object.assign({className:(0,a.classes)(["Window",d]),theme:u},v,{children:(0,e.createComponentVNode)(2,o.Box,{fillPositionedParent:!0,className:N&&"debug-layout",children:!C&&s})})))}return c}(),i=function(m){var l=m.className,u=m.fitted,s=m.children,d=k(m,S);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,b.Layout.Content,Object.assign({className:(0,a.classes)(["Window__content",l])},d,{children:u&&s||(0,e.createVNode)(1,"div","Window__contentPadding",s,0)})))};h.Content=i},34827:function(T,r,n){"use strict";r.__esModule=!0,r.Window=void 0;var e=n(89005),a=n(35840),t=n(85307),o=n(25328),p=n(72253),b=n(36036),y=n(76910),S=n(99851),k=n(77384),h=n(35421),i=n(9394),c=n(17617),m=["className","fitted","children"];function l(V,B){if(V==null)return{};var I={};for(var L in V)if({}.hasOwnProperty.call(V,L)){if(B.includes(L))continue;I[L]=V[L]}return I}function u(V,B){V.prototype=Object.create(B.prototype),V.prototype.constructor=V,s(V,B)}function s(V,B){return s=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(I,L){return I.__proto__=L,I},s(V,B)}/**
+ */function k(c,m){if(c==null)return{};var l={};for(var u in c)if({}.hasOwnProperty.call(c,u)){if(m.includes(u))continue;l[u]=c[u]}return l}var h=r.Pane=function(){function c(m,l){var u=m.theme,s=m.children,d=m.className,C=k(m,y),g=(0,t.useBackend)(l),v=g.suspended,f=(0,p.useDebug)(l),N=f.debugLayout;return(0,e.normalizeProps)((0,e.createComponentVNode)(2,b.Layout,Object.assign({className:(0,a.classes)(["Window",d]),theme:u},C,{children:(0,e.createComponentVNode)(2,o.Box,{fillPositionedParent:!0,className:N&&"debug-layout",children:!v&&s})})))}return c}(),i=function(m){var l=m.className,u=m.fitted,s=m.children,d=k(m,S);return(0,e.normalizeProps)((0,e.createComponentVNode)(2,b.Layout.Content,Object.assign({className:(0,a.classes)(["Window__content",l])},d,{children:u&&s||(0,e.createVNode)(1,"div","Window__contentPadding",s,0)})))};h.Content=i},34827:function(T,r,n){"use strict";r.__esModule=!0,r.Window=void 0;var e=n(89005),a=n(35840),t=n(85307),o=n(25328),p=n(72253),b=n(36036),y=n(76910),S=n(99851),k=n(77384),h=n(35421),i=n(9394),c=n(17617),m=["className","fitted","children"];function l(V,B){if(V==null)return{};var I={};for(var L in V)if({}.hasOwnProperty.call(V,L)){if(B.includes(L))continue;I[L]=V[L]}return I}function u(V,B){V.prototype=Object.create(B.prototype),V.prototype.constructor=V,s(V,B)}function s(V,B){return s=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(I,L){return I.__proto__=L,I},s(V,B)}/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
-*/var d=(0,i.createLogger)("Window"),v=[400,600],g=r.Window=function(V){function B(){return V.apply(this,arguments)||this}u(B,V);var I=B.prototype;return I.componentDidMount=function(){function L(){var w=(0,p.useBackend)(this.context),A=w.suspended;A||(d.log("mounting"),this.updateGeometry())}return L}(),I.componentDidUpdate=function(){function L(w){var A=this.props.width!==w.width||this.props.height!==w.height;A&&this.updateGeometry()}return L}(),I.updateGeometry=function(){function L(){var w,A=(0,p.useBackend)(this.context),x=A.config,E=Object.assign({size:v},x.window);this.props.width&&this.props.height&&(E.size=[this.props.width,this.props.height]),(w=x.window)!=null&&w.key&&(0,h.setWindowKey)(x.window.key),(0,h.recallWindowGeometry)(E)}return L}(),I.render=function(){function L(){var w,A=this.props,x=A.theme,E=A.title,P=A.children,D=(0,p.useBackend)(this.context),M=D.config,O=D.suspended,R=(0,S.useDebug)(this.context),F=R.debugLayout,W=(0,t.useDispatch)(this.context),U=(w=M.window)==null?void 0:w.fancy,z=M.user&&(M.user.observer?M.status0;){var f=g.shift(),N=f(v);try{C=b(N)}catch(B){if(B.code!=="MODULE_NOT_FOUND")throw B}}if(!C)return y("notFound",v);var V=C[v];return V||y("missingExport",v)}return i}()},72178:function(T,r,n){"use strict";r.__esModule=!0,r.configureStore=r.StoreProvider=void 0;var e=n(64795),a=n(85307),t=n(89005),o=n(79140),p=n(72253),b=n(99851),y=n(9394);function S(u,s){u.prototype=Object.create(s.prototype),u.prototype.constructor=u,k(u,s)}function k(u,s){return k=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(d,v){return d.__proto__=v,d},k(u,s)}/**
+ */var b=n(32054),y=function(c,m){return function(){return(0,e.createComponentVNode)(2,p.Window,{children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0,children:[c==="notFound"&&(0,e.createVNode)(1,"div",null,[(0,e.createTextVNode)("Interface "),(0,e.createVNode)(1,"b",null,m,0),(0,e.createTextVNode)(" was not found.")],4),c==="missingExport"&&(0,e.createVNode)(1,"div",null,[(0,e.createTextVNode)("Interface "),(0,e.createVNode)(1,"b",null,m,0),(0,e.createTextVNode)(" is missing an export.")],4)]})})}},S=function(){return(0,e.createComponentVNode)(2,p.Window,{children:(0,e.createComponentVNode)(2,p.Window.Content,{scrollable:!0})})},k=function(){return(0,e.createComponentVNode)(2,p.Window,{height:130,title:"Loading",width:150,children:(0,e.createComponentVNode)(2,p.Window.Content,{children:(0,e.createComponentVNode)(2,t.Stack,{align:"center",fill:!0,justify:"center",vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{children:(0,e.createComponentVNode)(2,t.Icon,{color:"blue",name:"toolbox",spin:!0,size:4})}),(0,e.createComponentVNode)(2,t.Stack.Item,{children:"Please wait..."})]})})})},h=r.getRoutedComponent=function(){function i(c){var m=c.getState(),l=(0,a.selectBackend)(m),u=l.suspended,s=l.config;if(u)return S;if(s.refreshing)return k;if(0)var d;for(var C=s==null?void 0:s.interface,g=[function(B){return"./"+B+".tsx"},function(B){return"./"+B+".js"},function(B){return"./"+B+"/index.tsx"},function(B){return"./"+B+"/index.js"}],v;!v&&g.length>0;){var f=g.shift(),N=f(C);try{v=b(N)}catch(B){if(B.code!=="MODULE_NOT_FOUND")throw B}}if(!v)return y("notFound",C);var V=v[C];return V||y("missingExport",C)}return i}()},72178:function(T,r,n){"use strict";r.__esModule=!0,r.configureStore=r.StoreProvider=void 0;var e=n(64795),a=n(85307),t=n(89005),o=n(79140),p=n(72253),b=n(99851),y=n(9394);function S(u,s){u.prototype=Object.create(s.prototype),u.prototype.constructor=u,k(u,s)}function k(u,s){return k=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(d,C){return d.__proto__=C,d},k(u,s)}/**
* @file
* @copyright 2020 Aleksej Komarov
* @license MIT
-*/var h=(0,y.createLogger)("store"),i=r.configureStore=function(){function u(s){var d,v;s===void 0&&(s={});var g=s,C=g.sideEffects,f=C===void 0?!0:C,N=(0,e.flow)([(0,a.combineReducers)({debug:b.debugReducer,backend:p.backendReducer}),s.reducer]),V=f?[].concat(((d=s.middleware)==null?void 0:d.pre)||[],[o.assetMiddleware,p.backendMiddleware],((v=s.middleware)==null?void 0:v.post)||[]):[],B=a.applyMiddleware.apply(void 0,V),I=(0,a.createStore)(N,B);return window.__store__=I,window.__augmentStack__=m(I),I}return u}(),c=function(s){return function(d){return function(v){var g=v.type,C=v.payload;return g==="update"||g==="backend/update"?h.debug("action",{type:g}):h.debug("action",v),d(v)}}},m=function(s){return function(d,v){var g,C;v?typeof v=="object"&&!v.stack&&(v.stack=d):(v=new Error(d.split("\n")[0]),v.stack=d),h.log("FatalError:",v);var f=s.getState(),N=f==null||(g=f.backend)==null?void 0:g.config,V=d;return V+="\nUser Agent: "+navigator.userAgent,V+="\nState: "+JSON.stringify({ckey:N==null||(C=N.client)==null?void 0:C.ckey,interface:N==null?void 0:N.interface,window:N==null?void 0:N.window}),V}},l=r.StoreProvider=function(u){function s(){return u.apply(this,arguments)||this}S(s,u);var d=s.prototype;return d.getChildContext=function(){function v(){var g=this.props.store;return{store:g}}return v}(),d.render=function(){function v(){return this.props.children}return v}(),s}(t.Component)},51364:function(T,r,n){"use strict";r.__esModule=!0,r.meta=void 0;var e=n(89005),a=n(36036);/**
+*/var h=(0,y.createLogger)("store"),i=r.configureStore=function(){function u(s){var d,C;s===void 0&&(s={});var g=s,v=g.sideEffects,f=v===void 0?!0:v,N=(0,e.flow)([(0,a.combineReducers)({debug:b.debugReducer,backend:p.backendReducer}),s.reducer]),V=f?[].concat(((d=s.middleware)==null?void 0:d.pre)||[],[o.assetMiddleware,p.backendMiddleware],((C=s.middleware)==null?void 0:C.post)||[]):[],B=a.applyMiddleware.apply(void 0,V),I=(0,a.createStore)(N,B);return window.__store__=I,window.__augmentStack__=m(I),I}return u}(),c=function(s){return function(d){return function(C){var g=C.type,v=C.payload;return g==="update"||g==="backend/update"?h.debug("action",{type:g}):h.debug("action",C),d(C)}}},m=function(s){return function(d,C){var g,v;C?typeof C=="object"&&!C.stack&&(C.stack=d):(C=new Error(d.split("\n")[0]),C.stack=d),h.log("FatalError:",C);var f=s.getState(),N=f==null||(g=f.backend)==null?void 0:g.config,V=d;return V+="\nUser Agent: "+navigator.userAgent,V+="\nState: "+JSON.stringify({ckey:N==null||(v=N.client)==null?void 0:v.ckey,interface:N==null?void 0:N.interface,window:N==null?void 0:N.window}),V}},l=r.StoreProvider=function(u){function s(){return u.apply(this,arguments)||this}S(s,u);var d=s.prototype;return d.getChildContext=function(){function C(){var g=this.props.store;return{store:g}}return C}(),d.render=function(){function C(){return this.props.children}return C}(),s}(t.Component)},51364:function(T,r,n){"use strict";r.__esModule=!0,r.meta=void 0;var e=n(89005),a=n(36036);/**
* @file
* @copyright 2021 Aleksej Komarov
* @license MIT
@@ -307,11 +307,11 @@
* @file
* @copyright 2021 Aleksej Komarov
* @license MIT
- */var o=r.meta={title:"Flex & Sections",render:function(){function b(){return(0,e.createComponentVNode)(2,p)}return b}()},p=function(y,S){var k=(0,a.useLocalState)(S,"fs_grow",1),h=k[0],i=k[1],c=(0,a.useLocalState)(S,"fs_direction","column"),m=c[0],l=c[1],u=(0,a.useLocalState)(S,"fs_fill",!0),s=u[0],d=u[1],v=(0,a.useLocalState)(S,"fs_title",!0),g=v[0],C=v[1];return(0,e.createComponentVNode)(2,t.Flex,{height:"100%",direction:"column",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{mb:1,children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:function(){function f(){return l(m==="column"?"row":"column")}return f}(),children:'Flex direction="'+m+'"'}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:function(){function f(){return i(+!h)}return f}(),children:"Flex.Item grow={"+h+"}"}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:function(){function f(){return d(!s)}return f}(),children:"Section fill={"+String(s)+"}"}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,selected:g,onClick:function(){function f(){return C(!g)}return f}(),children:"Section title"})]})}),(0,e.createComponentVNode)(2,t.Flex.Item,{grow:1,children:(0,e.createComponentVNode)(2,t.Flex,{height:"100%",direction:m,children:[(0,e.createComponentVNode)(2,t.Flex.Item,{mr:m==="row"&&1,mb:m==="column"&&1,grow:h,children:(0,e.createComponentVNode)(2,t.Section,{title:g&&"Section 1",fill:s,children:"Content"})}),(0,e.createComponentVNode)(2,t.Flex.Item,{grow:h,children:(0,e.createComponentVNode)(2,t.Section,{title:g&&"Section 2",fill:s,children:"Content"})})]})})]})}},48779:function(T,r,n){"use strict";r.__esModule=!0,r.meta=void 0;var e=n(89005),a=n(72253),t=n(36036);/**
+ */var o=r.meta={title:"Flex & Sections",render:function(){function b(){return(0,e.createComponentVNode)(2,p)}return b}()},p=function(y,S){var k=(0,a.useLocalState)(S,"fs_grow",1),h=k[0],i=k[1],c=(0,a.useLocalState)(S,"fs_direction","column"),m=c[0],l=c[1],u=(0,a.useLocalState)(S,"fs_fill",!0),s=u[0],d=u[1],C=(0,a.useLocalState)(S,"fs_title",!0),g=C[0],v=C[1];return(0,e.createComponentVNode)(2,t.Flex,{height:"100%",direction:"column",children:[(0,e.createComponentVNode)(2,t.Flex.Item,{mb:1,children:(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:function(){function f(){return l(m==="column"?"row":"column")}return f}(),children:'Flex direction="'+m+'"'}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:function(){function f(){return i(+!h)}return f}(),children:"Flex.Item grow={"+h+"}"}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,onClick:function(){function f(){return d(!s)}return f}(),children:"Section fill={"+String(s)+"}"}),(0,e.createComponentVNode)(2,t.Button,{fluid:!0,selected:g,onClick:function(){function f(){return v(!g)}return f}(),children:"Section title"})]})}),(0,e.createComponentVNode)(2,t.Flex.Item,{grow:1,children:(0,e.createComponentVNode)(2,t.Flex,{height:"100%",direction:m,children:[(0,e.createComponentVNode)(2,t.Flex.Item,{mr:m==="row"&&1,mb:m==="column"&&1,grow:h,children:(0,e.createComponentVNode)(2,t.Section,{title:g&&"Section 1",fill:s,children:"Content"})}),(0,e.createComponentVNode)(2,t.Flex.Item,{grow:h,children:(0,e.createComponentVNode)(2,t.Section,{title:g&&"Section 2",fill:s,children:"Content"})})]})})]})}},48779:function(T,r,n){"use strict";r.__esModule=!0,r.meta=void 0;var e=n(89005),a=n(72253),t=n(36036);/**
* @file
* @copyright 2024 Aylong (https://github.com/AyIong)
* @license MIT
- */var o=r.meta={title:"ImageButton",render:function(){function S(){return(0,e.createComponentVNode)(2,y)}return S}()},p=["red","orange","yellow","olive","green","teal","blue","violet","purple","pink","brown","grey","gold"],b=["good","average","bad","black","white"],y=function(k,h){var i=(0,a.useLocalState)(h,"fluid1",!0),c=i[0],m=i[1],l=(0,a.useLocalState)(h,"fluid2",!1),u=l[0],s=l[1],d=(0,a.useLocalState)(h,"fluid3",!1),v=d[0],g=d[1],C=(0,a.useLocalState)(h,"disabled",!1),f=C[0],N=C[1],V=(0,a.useLocalState)(h,"selected",!1),B=V[0],I=V[1],L=(0,a.useLocalState)(h,"addImage",!1),w=L[0],A=L[1],x=(0,a.useLocalState)(h,"base64",""),E=x[0],P=x[1],D=(0,a.useLocalState)(h,"title","Image Button"),M=D[0],O=D[1],R=(0,a.useLocalState)(h,"content","You can put anything in there"),F=R[0],W=R[1],U=(0,a.useLocalState)(h,"imageSize",64),z=U[0],$=U[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{basis:"50%",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:w?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"base64",children:(0,e.createComponentVNode)(2,t.Input,{value:E,onInput:function(){function G(X,J){return P(J)}return G}()})}):(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,t.Input,{value:M,onInput:function(){function G(X,J){return O(J)}return G}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Content",children:(0,e.createComponentVNode)(2,t.Input,{value:F,onInput:function(){function G(X,J){return W(J)}return G}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Image Size",children:(0,e.createComponentVNode)(2,t.Slider,{width:10,value:z,minValue:0,maxValue:256,step:1,onChange:function(){function G(X,J){return $(J)}return G}()})})],4)})}),(0,e.createComponentVNode)(2,t.Stack.Item,{basis:"50%",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:c,onClick:function(){function G(){return m(!c)}return G}(),children:"Fluid"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:f,onClick:function(){function G(){return N(!f)}return G}(),children:"Disabled"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:B,onClick:function(){function G(){return I(!B)}return G}(),children:"Selected"})})]})})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{mt:1,children:(0,e.createComponentVNode)(2,t.ImageButton,{m:!c&&0,fluid:c,base64:E,imageSize:z,title:M,tooltip:!c&&F,disabled:f,selected:B,buttonsAlt:c,buttons:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:c,compact:!c,color:!c&&"transparent",selected:w,onClick:function(){function G(){return A(!w)}return G}(),children:"Add Image"}),children:F})})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Color States",buttons:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:u,onClick:function(){function G(){return s(!u)}return G}(),children:"Fluid"}),children:b.map(function(G){return(0,e.createComponentVNode)(2,t.ImageButton,{fluid:u,color:G,imageSize:u?24:48,children:G},G)})}),(0,e.createComponentVNode)(2,t.Section,{title:"Available Colors",buttons:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:v,onClick:function(){function G(){return g(!v)}return G}(),children:"Fluid"}),children:p.map(function(G){return(0,e.createComponentVNode)(2,t.ImageButton,{fluid:v,color:G,imageSize:v?24:48,children:G},G)})})],4)}},21394:function(T,r,n){"use strict";r.__esModule=!0,r.meta=void 0;var e=n(89005),a=n(72253),t=n(36036);/**
+ */var o=r.meta={title:"ImageButton",render:function(){function S(){return(0,e.createComponentVNode)(2,y)}return S}()},p=["red","orange","yellow","olive","green","teal","blue","violet","purple","pink","brown","grey","gold"],b=["good","average","bad","black","white"],y=function(k,h){var i=(0,a.useLocalState)(h,"fluid1",!0),c=i[0],m=i[1],l=(0,a.useLocalState)(h,"fluid2",!1),u=l[0],s=l[1],d=(0,a.useLocalState)(h,"fluid3",!1),C=d[0],g=d[1],v=(0,a.useLocalState)(h,"disabled",!1),f=v[0],N=v[1],V=(0,a.useLocalState)(h,"selected",!1),B=V[0],I=V[1],L=(0,a.useLocalState)(h,"addImage",!1),w=L[0],A=L[1],x=(0,a.useLocalState)(h,"base64",""),E=x[0],P=x[1],D=(0,a.useLocalState)(h,"title","Image Button"),M=D[0],O=D[1],R=(0,a.useLocalState)(h,"content","You can put anything in there"),F=R[0],W=R[1],U=(0,a.useLocalState)(h,"imageSize",64),z=U[0],$=U[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Stack,{children:[(0,e.createComponentVNode)(2,t.Stack.Item,{basis:"50%",children:(0,e.createComponentVNode)(2,t.LabeledList,{children:w?(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"base64",children:(0,e.createComponentVNode)(2,t.Input,{value:E,onInput:function(){function G(X,J){return P(J)}return G}()})}):(0,e.createFragment)([(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Title",children:(0,e.createComponentVNode)(2,t.Input,{value:M,onInput:function(){function G(X,J){return O(J)}return G}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Content",children:(0,e.createComponentVNode)(2,t.Input,{value:F,onInput:function(){function G(X,J){return W(J)}return G}()})}),(0,e.createComponentVNode)(2,t.LabeledList.Item,{label:"Image Size",children:(0,e.createComponentVNode)(2,t.Slider,{width:10,value:z,minValue:0,maxValue:256,step:1,onChange:function(){function G(X,J){return $(J)}return G}()})})],4)})}),(0,e.createComponentVNode)(2,t.Stack.Item,{basis:"50%",children:(0,e.createComponentVNode)(2,t.Stack,{fill:!0,vertical:!0,children:[(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:c,onClick:function(){function G(){return m(!c)}return G}(),children:"Fluid"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:f,onClick:function(){function G(){return N(!f)}return G}(),children:"Disabled"})}),(0,e.createComponentVNode)(2,t.Stack.Item,{grow:!0,children:(0,e.createComponentVNode)(2,t.Button.Checkbox,{fluid:!0,checked:B,onClick:function(){function G(){return I(!B)}return G}(),children:"Selected"})})]})})]}),(0,e.createComponentVNode)(2,t.Stack.Item,{mt:1,children:(0,e.createComponentVNode)(2,t.ImageButton,{m:!c&&0,fluid:c,base64:E,imageSize:z,title:M,tooltip:!c&&F,disabled:f,selected:B,buttonsAlt:c,buttons:(0,e.createComponentVNode)(2,t.Button,{fluid:!0,translucent:c,compact:!c,color:!c&&"transparent",selected:w,onClick:function(){function G(){return A(!w)}return G}(),children:"Add Image"}),children:F})})]}),(0,e.createComponentVNode)(2,t.Section,{title:"Color States",buttons:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:u,onClick:function(){function G(){return s(!u)}return G}(),children:"Fluid"}),children:b.map(function(G){return(0,e.createComponentVNode)(2,t.ImageButton,{fluid:u,color:G,imageSize:u?24:48,children:G},G)})}),(0,e.createComponentVNode)(2,t.Section,{title:"Available Colors",buttons:(0,e.createComponentVNode)(2,t.Button.Checkbox,{checked:C,onClick:function(){function G(){return g(!C)}return G}(),children:"Fluid"}),children:p.map(function(G){return(0,e.createComponentVNode)(2,t.ImageButton,{fluid:C,color:G,imageSize:C?24:48,children:G},G)})})],4)}},21394:function(T,r,n){"use strict";r.__esModule=!0,r.meta=void 0;var e=n(89005),a=n(72253),t=n(36036);/**
* @file
* @copyright 2021 Aleksej Komarov
* @license MIT
@@ -331,7 +331,7 @@
* @file
* @copyright 2021 Aleksej Komarov
* @license MIT
- */var o=r.meta={title:"Tabs",render:function(){function y(){return(0,e.createComponentVNode)(2,b)}return y}()},p=["Tab #1","Tab #2","Tab #3","Tab #4"],b=function(S,k){var h=(0,a.useLocalState)(k,"tabIndex",0),i=h[0],c=h[1],m=(0,a.useLocalState)(k,"tabProps",{}),l=m[0],u=m[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"vertical",checked:l.vertical,onClick:function(){function s(){return u(Object.assign({},l,{vertical:!l.vertical}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"leftSlot",checked:l.leftSlot,onClick:function(){function s(){return u(Object.assign({},l,{leftSlot:!l.leftSlot}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"rightSlot",checked:l.rightSlot,onClick:function(){function s(){return u(Object.assign({},l,{rightSlot:!l.rightSlot}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"icon",checked:l.icon,onClick:function(){function s(){return u(Object.assign({},l,{icon:!l.icon}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"fluid",checked:l.fluid,onClick:function(){function s(){return u(Object.assign({},l,{fluid:!l.fluid}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"left aligned",checked:l.leftAligned,onClick:function(){function s(){return u(Object.assign({},l,{leftAligned:!l.leftAligned}))}return s}()})]}),(0,e.createComponentVNode)(2,t.Section,{fitted:!0,children:(0,e.createComponentVNode)(2,t.Tabs,{vertical:l.vertical,fluid:l.fluid,textAlign:l.leftAligned&&"left",children:p.map(function(s,d){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:d===i,icon:l.icon&&"info-circle",leftSlot:l.leftSlot&&(0,e.createComponentVNode)(2,t.Button,{circular:!0,compact:!0,color:"transparent",icon:"times"}),rightSlot:l.rightSlot&&(0,e.createComponentVNode)(2,t.Button,{circular:!0,compact:!0,color:"transparent",icon:"times"}),onClick:function(){function v(){return c(d)}return v}(),children:s},d)})})})],4)}},53276:function(T,r,n){"use strict";r.__esModule=!0,r.meta=void 0;var e=n(89005),a=n(72253),t=n(36036);/**
+ */var o=r.meta={title:"Tabs",render:function(){function y(){return(0,e.createComponentVNode)(2,b)}return y}()},p=["Tab #1","Tab #2","Tab #3","Tab #4"],b=function(S,k){var h=(0,a.useLocalState)(k,"tabIndex",0),i=h[0],c=h[1],m=(0,a.useLocalState)(k,"tabProps",{}),l=m[0],u=m[1];return(0,e.createFragment)([(0,e.createComponentVNode)(2,t.Section,{children:[(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"vertical",checked:l.vertical,onClick:function(){function s(){return u(Object.assign({},l,{vertical:!l.vertical}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"leftSlot",checked:l.leftSlot,onClick:function(){function s(){return u(Object.assign({},l,{leftSlot:!l.leftSlot}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"rightSlot",checked:l.rightSlot,onClick:function(){function s(){return u(Object.assign({},l,{rightSlot:!l.rightSlot}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"icon",checked:l.icon,onClick:function(){function s(){return u(Object.assign({},l,{icon:!l.icon}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"fluid",checked:l.fluid,onClick:function(){function s(){return u(Object.assign({},l,{fluid:!l.fluid}))}return s}()}),(0,e.createComponentVNode)(2,t.Button.Checkbox,{inline:!0,content:"left aligned",checked:l.leftAligned,onClick:function(){function s(){return u(Object.assign({},l,{leftAligned:!l.leftAligned}))}return s}()})]}),(0,e.createComponentVNode)(2,t.Section,{fitted:!0,children:(0,e.createComponentVNode)(2,t.Tabs,{vertical:l.vertical,fluid:l.fluid,textAlign:l.leftAligned&&"left",children:p.map(function(s,d){return(0,e.createComponentVNode)(2,t.Tabs.Tab,{selected:d===i,icon:l.icon&&"info-circle",leftSlot:l.leftSlot&&(0,e.createComponentVNode)(2,t.Button,{circular:!0,compact:!0,color:"transparent",icon:"times"}),rightSlot:l.rightSlot&&(0,e.createComponentVNode)(2,t.Button,{circular:!0,compact:!0,color:"transparent",icon:"times"}),onClick:function(){function C(){return c(d)}return C}(),children:s},d)})})})],4)}},53276:function(T,r,n){"use strict";r.__esModule=!0,r.meta=void 0;var e=n(89005),a=n(72253),t=n(36036);/**
* @file
* @copyright 2021 Aleksej Komarov
* @license MIT
@@ -343,7 +343,7 @@
* @file
* @copyright 2021 Aleksej Komarov
* @license MIT
- */var t=r.BoxWithSampleText=function(){function o(p){return(0,e.normalizeProps)((0,e.createComponentVNode)(2,a.Box,Object.assign({},p,{children:[(0,e.createComponentVNode)(2,a.Box,{italic:!0,children:"Jackdaws love my big sphinx of quartz."}),(0,e.createComponentVNode)(2,a.Box,{mt:1,bold:!0,children:"The wide electrification of the southern provinces will give a powerful impetus to the growth of agriculture."})]})))}return o}()},67160:function(){},23542:function(){},30386:function(){},98996:function(){},50578:function(){},4444:function(){},77870:function(){},23632:function(){},56492:function(){},39108:function(){},11714:function(){},73492:function(){},49641:function(){},17570:function(){},61858:function(){},32882:function(){},70752:function(T,r,n){var e={"./pai_atmosphere.js":80818,"./pai_bioscan.js":23903,"./pai_directives.js":64988,"./pai_doorjack.js":13813,"./pai_main_menu.js":66025,"./pai_manifest.js":2983,"./pai_medrecords.js":40758,"./pai_messenger.js":98599,"./pai_radio.js":50775,"./pai_secrecords.js":48623,"./pai_signaler.js":47297};function a(o){var p=t(o);return n(p)}function t(o){if(!n.o(e,o)){var p=new Error("Cannot find module '"+o+"'");throw p.code="MODULE_NOT_FOUND",p}return e[o]}a.keys=function(){return Object.keys(e)},a.resolve=t,T.exports=a,a.id=70752},59395:function(T,r,n){var e={"./pda_atmos_scan.js":78532,"./pda_games.js":2395,"./pda_janitor.js":40253,"./pda_main_menu.js":58293,"./pda_manifest.js":58059,"./pda_medical.js":18147,"./pda_messenger.js":77595,"./pda_minesweeper.js":90382,"./pda_mule.js":24635,"./pda_nanobank.js":23734,"./pda_notes.js":97085,"./pda_power.js":57513,"./pda_secbot.js":99808,"./pda_security.js":77168,"./pda_signaler.js":21773,"./pda_status_display.js":81857,"./pda_supplyrecords.js":70287};function a(o){var p=t(o);return n(p)}function t(o){if(!n.o(e,o)){var p=new Error("Cannot find module '"+o+"'");throw p.code="MODULE_NOT_FOUND",p}return e[o]}a.keys=function(){return Object.keys(e)},a.resolve=t,T.exports=a,a.id=59395},32054:function(T,r,n){var e={"./AICard":1090,"./AICard.js":1090,"./AIFixer":39454,"./AIFixer.js":39454,"./APC":88422,"./APC.js":88422,"./ATM":99660,"./ATM.js":99660,"./AccountsUplinkTerminal":86423,"./AccountsUplinkTerminal.js":86423,"./AgentCard":39683,"./AgentCard.tsx":39683,"./AiAirlock":56793,"./AiAirlock.js":56793,"./AirAlarm":72475,"./AirAlarm.js":72475,"./AirlockAccessController":12333,"./AirlockAccessController.js":12333,"./AirlockElectronics":28736,"./AirlockElectronics.js":28736,"./AlertModal":47365,"./AlertModal.tsx":47365,"./AppearanceChanger":71824,"./AppearanceChanger.js":71824,"./AtmosAlertConsole":72285,"./AtmosAlertConsole.js":72285,"./AtmosControl":65805,"./AtmosControl.js":65805,"./AtmosFilter":87816,"./AtmosFilter.js":87816,"./AtmosMixer":52977,"./AtmosMixer.js":52977,"./AtmosPump":11748,"./AtmosPump.js":11748,"./AtmosTankControl":69321,"./AtmosTankControl.js":69321,"./AugmentMenu":92444,"./AugmentMenu.js":92444,"./Autolathe":59179,"./Autolathe.js":59179,"./BioChipPad":5147,"./BioChipPad.js":5147,"./Biogenerator":64273,"./Biogenerator.js":64273,"./BloomEdit":47823,"./BloomEdit.js":47823,"./BlueSpaceArtilleryControl":18621,"./BlueSpaceArtilleryControl.js":18621,"./BluespaceTap":27629,"./BluespaceTap.js":27629,"./BodyScanner":33758,"./BodyScanner.js":33758,"./BookBinder":67963,"./BookBinder.js":67963,"./BotCall":61925,"./BotCall.js":61925,"./BotClean":20464,"./BotClean.js":20464,"./BotFloor":69479,"./BotFloor.js":69479,"./BotHonk":59887,"./BotHonk.js":59887,"./BotMed":80063,"./BotMed.js":80063,"./BotSecurity":74439,"./BotSecurity.js":74439,"./BrigCells":10833,"./BrigCells.js":10833,"./BrigTimer":45761,"./BrigTimer.js":45761,"./CameraConsole":26300,"./CameraConsole.js":26300,"./Canister":52927,"./Canister.js":52927,"./CardComputer":51793,"./CardComputer.js":51793,"./CargoConsole":64083,"./CargoConsole.js":64083,"./Chameleon":36232,"./Chameleon.tsx":36232,"./ChangelogView":87331,"./ChangelogView.js":87331,"./CheckboxListInputModal":91360,"./CheckboxListInputModal.tsx":91360,"./ChemDispenser":36108,"./ChemDispenser.js":36108,"./ChemHeater":13146,"./ChemHeater.js":13146,"./ChemMaster":56541,"./ChemMaster.tsx":56541,"./CloningConsole":37173,"./CloningConsole.js":37173,"./CloningPod":98723,"./CloningPod.js":98723,"./CoinMint":18259,"./CoinMint.tsx":18259,"./ColorPickerModal":93858,"./ColorPickerModal.tsx":93858,"./ColourMatrixTester":8444,"./ColourMatrixTester.js":8444,"./CommunicationsComputer":63818,"./CommunicationsComputer.js":63818,"./CompostBin":20562,"./CompostBin.js":20562,"./Contractor":21813,"./Contractor.js":21813,"./ConveyorSwitch":54151,"./ConveyorSwitch.js":54151,"./CrewMonitor":73169,"./CrewMonitor.js":73169,"./Cryo":63987,"./Cryo.js":63987,"./CryopodConsole":86099,"./CryopodConsole.js":86099,"./DNAModifier":12692,"./DNAModifier.js":12692,"./DestinationTagger":41074,"./DestinationTagger.js":41074,"./DisposalBin":46500,"./DisposalBin.js":46500,"./DnaVault":33233,"./DnaVault.js":33233,"./DroneConsole":33681,"./DroneConsole.js":33681,"./EFTPOS":17263,"./EFTPOS.js":17263,"./ERTManager":76382,"./ERTManager.js":76382,"./EconomyManager":90217,"./EconomyManager.js":90217,"./Electropack":82565,"./Electropack.js":82565,"./Emojipedia":11243,"./Emojipedia.tsx":11243,"./EvolutionMenu":36730,"./EvolutionMenu.js":36730,"./ExosuitFabricator":17370,"./ExosuitFabricator.js":17370,"./ExperimentConsole":59128,"./ExperimentConsole.js":59128,"./ExternalAirlockController":97086,"./ExternalAirlockController.js":97086,"./FaxMachine":96142,"./FaxMachine.js":96142,"./FilingCabinet":74123,"./FilingCabinet.js":74123,"./FloorPainter":83767,"./FloorPainter.js":83767,"./GPS":53424,"./GPS.js":53424,"./GeneModder":89124,"./GeneModder.js":89124,"./GenericCrewManifest":73053,"./GenericCrewManifest.js":73053,"./GhostHudPanel":42914,"./GhostHudPanel.js":42914,"./GlandDispenser":25825,"./GlandDispenser.js":25825,"./GravityGen":10270,"./GravityGen.js":10270,"./GuestPass":48657,"./GuestPass.js":48657,"./HandheldChemDispenser":67834,"./HandheldChemDispenser.js":67834,"./HealthSensor":46098,"./HealthSensor.js":46098,"./Holodeck":36771,"./Holodeck.js":36771,"./Instrument":25471,"./Instrument.js":25471,"./KeyComboModal":13618,"./KeyComboModal.tsx":13618,"./KeycardAuth":35655,"./KeycardAuth.js":35655,"./KitchenMachine":62955,"./KitchenMachine.js":62955,"./LawManager":9525,"./LawManager.js":9525,"./LibraryComputer":85066,"./LibraryComputer.js":85066,"./LibraryManager":9516,"./LibraryManager.js":9516,"./ListInputModal":90447,"./ListInputModal.tsx":90447,"./Loadout":26826,"./Loadout.tsx":26826,"./MODsuit":77613,"./MODsuit.js":77613,"./MagnetController":78624,"./MagnetController.js":78624,"./MechBayConsole":72106,"./MechBayConsole.js":72106,"./MechaControlConsole":7466,"./MechaControlConsole.js":7466,"./MedicalRecords":79625,"./MedicalRecords.js":79625,"./MerchVendor":54989,"./MerchVendor.js":54989,"./MiningVendor":87684,"./MiningVendor.js":87684,"./NTRecruiter":59783,"./NTRecruiter.js":59783,"./Newscaster":64713,"./Newscaster.js":64713,"./Noticeboard":48286,"./Noticeboard.tsx":48286,"./NuclearBomb":41166,"./NuclearBomb.js":41166,"./NumberInputModal":52416,"./NumberInputModal.tsx":52416,"./OperatingComputer":1218,"./OperatingComputer.js":1218,"./Orbit":46892,"./Orbit.js":46892,"./OreRedemption":15421,"./OreRedemption.js":15421,"./PAI":52754,"./PAI.js":52754,"./PDA":85175,"./PDA.js":85175,"./Pacman":68654,"./Pacman.js":68654,"./PanDEMIC":1701,"./PanDEMIC.tsx":1701,"./ParticleAccelerator":67921,"./ParticleAccelerator.js":67921,"./PdaPainter":71432,"./PdaPainter.js":71432,"./PersonalCrafting":33388,"./PersonalCrafting.js":33388,"./Photocopier":56150,"./Photocopier.js":56150,"./PoolController":84676,"./PoolController.js":84676,"./PortablePump":57003,"./PortablePump.js":57003,"./PortableScrubber":70069,"./PortableScrubber.js":70069,"./PortableTurret":59955,"./PortableTurret.js":59955,"./PowerMonitor":61631,"./PowerMonitor.js":61631,"./PrisonerImplantManager":50992,"./PrisonerImplantManager.js":50992,"./PrisonerShuttleConsole":53952,"./PrisonerShuttleConsole.js":53952,"./PrizeCounter":97852,"./PrizeCounter.tsx":97852,"./RCD":94813,"./RCD.js":94813,"./RPD":18738,"./RPD.js":18738,"./Radio":80299,"./Radio.js":80299,"./RankedListInputModal":14846,"./RankedListInputModal.tsx":14846,"./ReagentGrinder":48125,"./ReagentGrinder.js":48125,"./ReagentsEditor":58262,"./ReagentsEditor.tsx":58262,"./RemoteSignaler":30207,"./RemoteSignaler.js":30207,"./RequestConsole":25472,"./RequestConsole.js":25472,"./RndBackupConsole":9861,"./RndBackupConsole.js":9861,"./RndConsole":12644,"./RndConsole/":12644,"./RndConsole/DataDiskMenu":37556,"./RndConsole/DataDiskMenu.js":37556,"./RndConsole/DeconstructionMenu":58147,"./RndConsole/DeconstructionMenu.js":58147,"./RndConsole/LatheCategory":16830,"./RndConsole/LatheCategory.js":16830,"./RndConsole/LatheChemicalStorage":70497,"./RndConsole/LatheChemicalStorage.js":70497,"./RndConsole/LatheMainMenu":70864,"./RndConsole/LatheMainMenu.js":70864,"./RndConsole/LatheMaterialStorage":42878,"./RndConsole/LatheMaterialStorage.js":42878,"./RndConsole/LatheMaterials":52662,"./RndConsole/LatheMaterials.js":52662,"./RndConsole/LatheMenu":9681,"./RndConsole/LatheMenu.js":9681,"./RndConsole/LatheSearch":68198,"./RndConsole/LatheSearch.js":68198,"./RndConsole/LinkMenu":81421,"./RndConsole/LinkMenu.js":81421,"./RndConsole/SettingsMenu":6256,"./RndConsole/SettingsMenu.js":6256,"./RndConsole/index":12644,"./RndConsole/index.js":12644,"./RndNetController":29205,"./RndNetController.js":29205,"./RndServer":63315,"./RndServer.js":63315,"./RobotSelfDiagnosis":26109,"./RobotSelfDiagnosis.js":26109,"./RoboticsControlConsole":97997,"./RoboticsControlConsole.js":97997,"./Safe":54431,"./Safe.js":54431,"./SatelliteControl":29740,"./SatelliteControl.js":29740,"./SecureStorage":44162,"./SecureStorage.js":44162,"./SecurityRecords":6272,"./SecurityRecords.js":6272,"./SeedExtractor":5099,"./SeedExtractor.js":5099,"./ShuttleConsole":2916,"./ShuttleConsole.js":2916,"./ShuttleManipulator":39401,"./ShuttleManipulator.js":39401,"./Sleeper":88284,"./Sleeper.js":88284,"./SlotMachine":21597,"./SlotMachine.js":21597,"./Smartfridge":46348,"./Smartfridge.js":46348,"./Smes":86162,"./Smes.js":86162,"./SolarControl":63584,"./SolarControl.js":63584,"./SpawnersMenu":38096,"./SpawnersMenu.js":38096,"./SpecMenu":30586,"./SpecMenu.js":30586,"./StackCraft":95152,"./StackCraft.js":95152,"./StationAlertConsole":38307,"./StationAlertConsole.js":38307,"./StationTraitsPanel":96091,"./StationTraitsPanel.tsx":96091,"./StripMenu":39409,"./StripMenu.tsx":39409,"./SuitStorage":69514,"./SuitStorage.js":69514,"./SupermatterMonitor":15022,"./SupermatterMonitor.js":15022,"./SyndicateComputerSimple":46029,"./SyndicateComputerSimple.js":46029,"./TEG":36372,"./TEG.js":36372,"./TachyonArray":56441,"./TachyonArray.js":56441,"./Tank":1754,"./Tank.js":1754,"./TankDispenser":7579,"./TankDispenser.js":7579,"./TcommsCore":16136,"./TcommsCore.js":16136,"./TcommsRelay":88046,"./TcommsRelay.js":88046,"./Teleporter":20802,"./Teleporter.js":20802,"./TelescienceConsole":48517,"./TelescienceConsole.js":48517,"./TempGun":21800,"./TempGun.js":21800,"./TextInputModal":24410,"./TextInputModal.tsx":24410,"./ThermoMachine":25036,"./ThermoMachine.js":25036,"./TransferValve":20035,"./TransferValve.js":20035,"./TurbineComputer":78166,"./TurbineComputer.js":78166,"./Uplink":52847,"./Uplink.js":52847,"./Vending":12261,"./Vending.js":12261,"./VolumeMixer":68971,"./VolumeMixer.js":68971,"./VotePanel":2510,"./VotePanel.js":2510,"./Wires":30138,"./Wires.js":30138,"./WizardApprenticeContract":21400,"./WizardApprenticeContract.js":21400,"./common/AccessList":49148,"./common/AccessList.js":49148,"./common/AtmosScan":26991,"./common/AtmosScan.js":26991,"./common/BeakerContents":85870,"./common/BeakerContents.js":85870,"./common/BotStatus":92963,"./common/BotStatus.js":92963,"./common/ComplexModal":3939,"./common/ComplexModal.js":3939,"./common/CrewManifest":41874,"./common/CrewManifest.js":41874,"./common/InputButtons":19203,"./common/InputButtons.tsx":19203,"./common/InterfaceLockNoticeBox":195,"./common/InterfaceLockNoticeBox.js":195,"./common/Loader":51057,"./common/Loader.tsx":51057,"./common/LoginInfo":321,"./common/LoginInfo.js":321,"./common/LoginScreen":5485,"./common/LoginScreen.js":5485,"./common/Operating":62411,"./common/Operating.js":62411,"./common/Signaler":13545,"./common/Signaler.js":13545,"./common/SimpleRecords":41984,"./common/SimpleRecords.js":41984,"./common/TemporaryNotice":22091,"./common/TemporaryNotice.js":22091,"./goonstation_PTL":95213,"./goonstation_PTL/":95213,"./goonstation_PTL/index":95213,"./goonstation_PTL/index.js":95213,"./pai/pai_atmosphere":80818,"./pai/pai_atmosphere.js":80818,"./pai/pai_bioscan":23903,"./pai/pai_bioscan.js":23903,"./pai/pai_directives":64988,"./pai/pai_directives.js":64988,"./pai/pai_doorjack":13813,"./pai/pai_doorjack.js":13813,"./pai/pai_main_menu":66025,"./pai/pai_main_menu.js":66025,"./pai/pai_manifest":2983,"./pai/pai_manifest.js":2983,"./pai/pai_medrecords":40758,"./pai/pai_medrecords.js":40758,"./pai/pai_messenger":98599,"./pai/pai_messenger.js":98599,"./pai/pai_radio":50775,"./pai/pai_radio.js":50775,"./pai/pai_secrecords":48623,"./pai/pai_secrecords.js":48623,"./pai/pai_signaler":47297,"./pai/pai_signaler.js":47297,"./pda/pda_atmos_scan":78532,"./pda/pda_atmos_scan.js":78532,"./pda/pda_games":2395,"./pda/pda_games.js":2395,"./pda/pda_janitor":40253,"./pda/pda_janitor.js":40253,"./pda/pda_main_menu":58293,"./pda/pda_main_menu.js":58293,"./pda/pda_manifest":58059,"./pda/pda_manifest.js":58059,"./pda/pda_medical":18147,"./pda/pda_medical.js":18147,"./pda/pda_messenger":77595,"./pda/pda_messenger.js":77595,"./pda/pda_minesweeper":90382,"./pda/pda_minesweeper.js":90382,"./pda/pda_mule":24635,"./pda/pda_mule.js":24635,"./pda/pda_nanobank":23734,"./pda/pda_nanobank.js":23734,"./pda/pda_notes":97085,"./pda/pda_notes.js":97085,"./pda/pda_power":57513,"./pda/pda_power.js":57513,"./pda/pda_secbot":99808,"./pda/pda_secbot.js":99808,"./pda/pda_security":77168,"./pda/pda_security.js":77168,"./pda/pda_signaler":21773,"./pda/pda_signaler.js":21773,"./pda/pda_status_display":81857,"./pda/pda_status_display.js":81857,"./pda/pda_supplyrecords":70287,"./pda/pda_supplyrecords.js":70287};function a(o){var p=t(o);return n(p)}function t(o){if(!n.o(e,o)){var p=new Error("Cannot find module '"+o+"'");throw p.code="MODULE_NOT_FOUND",p}return e[o]}a.keys=function(){return Object.keys(e)},a.resolve=t,T.exports=a,a.id=32054},4085:function(T,r,n){var e={"./Blink.stories.js":51364,"./BlockQuote.stories.js":32453,"./Box.stories.js":83531,"./Button.stories.js":74198,"./ByondUi.stories.js":51956,"./Collapsible.stories.js":17466,"./Flex.stories.js":89241,"./ImageButton.stories.js":48779,"./Input.stories.js":21394,"./Popper.stories.js":43932,"./ProgressBar.stories.js":33270,"./Stack.stories.js":77766,"./Storage.stories.js":30187,"./Tabs.stories.js":46554,"./Themes.stories.js":53276,"./Tooltip.stories.js":28717};function a(o){var p=t(o);return n(p)}function t(o){if(!n.o(e,o)){var p=new Error("Cannot find module '"+o+"'");throw p.code="MODULE_NOT_FOUND",p}return e[o]}a.keys=function(){return Object.keys(e)},a.resolve=t,T.exports=a,a.id=4085},10320:function(T,r,n){"use strict";var e=n(55747),a=n(89393),t=TypeError;T.exports=function(o){if(e(o))return o;throw new t(a(o)+" is not a function")}},32606:function(T,r,n){"use strict";var e=n(1031),a=n(89393),t=TypeError;T.exports=function(o){if(e(o))return o;throw new t(a(o)+" is not a constructor")}},35908:function(T,r,n){"use strict";var e=n(45015),a=String,t=TypeError;T.exports=function(o){if(e(o))return o;throw new t("Can't set "+a(o)+" as a prototype")}},80575:function(T,r,n){"use strict";var e=n(24697),a=n(80674),t=n(74595).f,o=e("unscopables"),p=Array.prototype;p[o]===void 0&&t(p,o,{configurable:!0,value:a(null)}),T.exports=function(b){p[o][b]=!0}},35483:function(T,r,n){"use strict";var e=n(50233).charAt;T.exports=function(a,t,o){return t+(o?e(a,t).length:1)}},60077:function(T,r,n){"use strict";var e=n(21287),a=TypeError;T.exports=function(t,o){if(e(o,t))return t;throw new a("Incorrect invocation")}},30365:function(T,r,n){"use strict";var e=n(77568),a=String,t=TypeError;T.exports=function(o){if(e(o))return o;throw new t(a(o)+" is not an object")}},70377:function(T){"use strict";T.exports=typeof ArrayBuffer!="undefined"&&typeof DataView!="undefined"},3782:function(T,r,n){"use strict";var e=n(40033);T.exports=e(function(){if(typeof ArrayBuffer=="function"){var a=new ArrayBuffer(8);Object.isExtensible(a)&&Object.defineProperty(a,"a",{value:8})}})},4246:function(T,r,n){"use strict";var e=n(70377),a=n(58310),t=n(74685),o=n(55747),p=n(77568),b=n(45299),y=n(2281),S=n(89393),k=n(37909),h=n(55938),i=n(73936),c=n(21287),m=n(36917),l=n(76649),u=n(24697),s=n(16738),d=n(5419),v=d.enforce,g=d.get,C=t.Int8Array,f=C&&C.prototype,N=t.Uint8ClampedArray,V=N&&N.prototype,B=C&&m(C),I=f&&m(f),L=Object.prototype,w=t.TypeError,A=u("toStringTag"),x=s("TYPED_ARRAY_TAG"),E="TypedArrayConstructor",P=e&&!!l&&y(t.opera)!=="Opera",D=!1,M,O,R,F={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},W={BigInt64Array:8,BigUint64Array:8},U=function(){function ie(me){if(!p(me))return!1;var q=y(me);return q==="DataView"||b(F,q)||b(W,q)}return ie}(),z=function ie(me){var q=m(me);if(p(q)){var re=g(q);return re&&b(re,E)?re[E]:ie(q)}},$=function(me){if(!p(me))return!1;var q=y(me);return b(F,q)||b(W,q)},G=function(me){if($(me))return me;throw new w("Target is not a typed array")},X=function(me){if(o(me)&&(!l||c(B,me)))return me;throw new w(S(me)+" is not a typed array constructor")},J=function(me,q,re,ae){if(a){if(re)for(var le in F){var Z=t[le];if(Z&&b(Z.prototype,me))try{delete Z.prototype[me]}catch(ne){try{Z.prototype[me]=q}catch(te){}}}(!I[me]||re)&&h(I,me,re?q:P&&f[me]||q,ae)}},se=function(me,q,re){var ae,le;if(a){if(l){if(re){for(ae in F)if(le=t[ae],le&&b(le,me))try{delete le[me]}catch(Z){}}if(!B[me]||re)try{return h(B,me,re?q:P&&B[me]||q)}catch(Z){}else return}for(ae in F)le=t[ae],le&&(!le[me]||re)&&h(le,me,q)}};for(M in F)O=t[M],R=O&&O.prototype,R?v(R)[E]=O:P=!1;for(M in W)O=t[M],R=O&&O.prototype,R&&(v(R)[E]=O);if((!P||!o(B)||B===Function.prototype)&&(B=function(){function ie(){throw new w("Incorrect invocation")}return ie}(),P))for(M in F)t[M]&&l(t[M],B);if((!P||!I||I===L)&&(I=B.prototype,P))for(M in F)t[M]&&l(t[M].prototype,I);if(P&&m(V)!==I&&l(V,I),a&&!b(I,A)){D=!0,i(I,A,{configurable:!0,get:function(){function ie(){return p(this)?this[x]:void 0}return ie}()});for(M in F)t[M]&&k(t[M],x,M)}T.exports={NATIVE_ARRAY_BUFFER_VIEWS:P,TYPED_ARRAY_TAG:D&&x,aTypedArray:G,aTypedArrayConstructor:X,exportTypedArrayMethod:J,exportTypedArrayStaticMethod:se,getTypedArrayConstructor:z,isView:U,isTypedArray:$,TypedArray:B,TypedArrayPrototype:I}},37336:function(T,r,n){"use strict";var e=n(74685),a=n(67250),t=n(58310),o=n(70377),p=n(70520),b=n(37909),y=n(73936),S=n(30145),k=n(40033),h=n(60077),i=n(61365),c=n(10188),m=n(43806),l=n(95867),u=n(91784),s=n(36917),d=n(76649),v=n(88471),g=n(54602),C=n(5781),f=n(5774),N=n(84925),V=n(5419),B=p.PROPER,I=p.CONFIGURABLE,L="ArrayBuffer",w="DataView",A="prototype",x="Wrong length",E="Wrong index",P=V.getterFor(L),D=V.getterFor(w),M=V.set,O=e[L],R=O,F=R&&R[A],W=e[w],U=W&&W[A],z=Object.prototype,$=e.Array,G=e.RangeError,X=a(v),J=a([].reverse),se=u.pack,ie=u.unpack,me=function(Ne){return[Ne&255]},q=function(Ne){return[Ne&255,Ne>>8&255]},re=function(Ne){return[Ne&255,Ne>>8&255,Ne>>16&255,Ne>>24&255]},ae=function(Ne){return Ne[3]<<24|Ne[2]<<16|Ne[1]<<8|Ne[0]},le=function(Ne){return se(l(Ne),23,4)},Z=function(Ne){return se(Ne,52,8)},ne=function(Ne,Be,be){y(Ne[A],Be,{configurable:!0,get:function(){function Le(){return be(this)[Be]}return Le}()})},te=function(Ne,Be,be,Le){var we=D(Ne),xe=m(be),Re=!!Le;if(xe+Be>we.byteLength)throw new G(E);var He=we.bytes,ye=xe+we.byteOffset,de=g(He,ye,ye+Be);return Re?de:J(de)},fe=function(Ne,Be,be,Le,we,xe){var Re=D(Ne),He=m(be),ye=Le(+we),de=!!xe;if(He+Be>Re.byteLength)throw new G(E);for(var he=Re.bytes,ke=He+Re.byteOffset,ve=0;vewe)throw new G("Wrong offset");if(be=be===void 0?we-xe:c(be),xe+be>we)throw new G(x);M(this,{type:w,buffer:Ne,byteLength:be,byteOffset:xe,bytes:Le.bytes}),t||(this.buffer=Ne,this.byteLength=be,this.byteOffset=xe)}return Ce}(),U=W[A],t&&(ne(R,"byteLength",P),ne(W,"buffer",D),ne(W,"byteLength",D),ne(W,"byteOffset",D)),S(U,{getInt8:function(){function Ce(Ne){return te(this,1,Ne)[0]<<24>>24}return Ce}(),getUint8:function(){function Ce(Ne){return te(this,1,Ne)[0]}return Ce}(),getInt16:function(){function Ce(Ne){var Be=te(this,2,Ne,arguments.length>1?arguments[1]:!1);return(Be[1]<<8|Be[0])<<16>>16}return Ce}(),getUint16:function(){function Ce(Ne){var Be=te(this,2,Ne,arguments.length>1?arguments[1]:!1);return Be[1]<<8|Be[0]}return Ce}(),getInt32:function(){function Ce(Ne){return ae(te(this,4,Ne,arguments.length>1?arguments[1]:!1))}return Ce}(),getUint32:function(){function Ce(Ne){return ae(te(this,4,Ne,arguments.length>1?arguments[1]:!1))>>>0}return Ce}(),getFloat32:function(){function Ce(Ne){return ie(te(this,4,Ne,arguments.length>1?arguments[1]:!1),23)}return Ce}(),getFloat64:function(){function Ce(Ne){return ie(te(this,8,Ne,arguments.length>1?arguments[1]:!1),52)}return Ce}(),setInt8:function(){function Ce(Ne,Be){fe(this,1,Ne,me,Be)}return Ce}(),setUint8:function(){function Ce(Ne,Be){fe(this,1,Ne,me,Be)}return Ce}(),setInt16:function(){function Ce(Ne,Be){fe(this,2,Ne,q,Be,arguments.length>2?arguments[2]:!1)}return Ce}(),setUint16:function(){function Ce(Ne,Be){fe(this,2,Ne,q,Be,arguments.length>2?arguments[2]:!1)}return Ce}(),setInt32:function(){function Ce(Ne,Be){fe(this,4,Ne,re,Be,arguments.length>2?arguments[2]:!1)}return Ce}(),setUint32:function(){function Ce(Ne,Be){fe(this,4,Ne,re,Be,arguments.length>2?arguments[2]:!1)}return Ce}(),setFloat32:function(){function Ce(Ne,Be){fe(this,4,Ne,le,Be,arguments.length>2?arguments[2]:!1)}return Ce}(),setFloat64:function(){function Ce(Ne,Be){fe(this,8,Ne,Z,Be,arguments.length>2?arguments[2]:!1)}return Ce}()});else{var pe=B&&O.name!==L;!k(function(){O(1)})||!k(function(){new O(-1)})||k(function(){return new O,new O(1.5),new O(NaN),O.length!==1||pe&&!I})?(R=function(){function Ce(Ne){return h(this,F),C(new O(m(Ne)),this,R)}return Ce}(),R[A]=F,F.constructor=R,f(R,O)):pe&&I&&b(O,"name",L),d&&s(U)!==z&&d(U,z);var ce=new W(new R(2)),Ve=a(U.setInt8);ce.setInt8(0,2147483648),ce.setInt8(1,2147483649),(ce.getInt8(0)||!ce.getInt8(1))&&S(U,{setInt8:function(){function Ce(Ne,Be){Ve(this,Ne,Be<<24>>24)}return Ce}(),setUint8:function(){function Ce(Ne,Be){Ve(this,Ne,Be<<24>>24)}return Ce}()},{unsafe:!0})}N(R,L),N(W,w),T.exports={ArrayBuffer:R,DataView:W}},71447:function(T,r,n){"use strict";var e=n(46771),a=n(13912),t=n(24760),o=n(95108),p=Math.min;T.exports=[].copyWithin||function(){function b(y,S){var k=e(this),h=t(k),i=a(y,h),c=a(S,h),m=arguments.length>2?arguments[2]:void 0,l=p((m===void 0?h:a(m,h))-c,h-i),u=1;for(c0;)c in k?k[i]=k[c]:o(k,i),i+=u,c+=u;return k}return b}()},88471:function(T,r,n){"use strict";var e=n(46771),a=n(13912),t=n(24760);T.exports=function(){function o(p){for(var b=e(this),y=t(b),S=arguments.length,k=a(S>1?arguments[1]:void 0,y),h=S>2?arguments[2]:void 0,i=h===void 0?y:a(h,y);i>k;)b[k++]=p;return b}return o}()},35601:function(T,r,n){"use strict";var e=n(22603).forEach,a=n(55528),t=a("forEach");T.exports=t?[].forEach:function(){function o(p){return e(this,p,arguments.length>1?arguments[1]:void 0)}return o}()},78008:function(T,r,n){"use strict";var e=n(24760);T.exports=function(a,t,o){for(var p=0,b=arguments.length>2?o:e(t),y=new a(b);b>p;)y[p]=t[p++];return y}},73174:function(T,r,n){"use strict";var e=n(75754),a=n(91495),t=n(46771),o=n(40125),p=n(76571),b=n(1031),y=n(24760),S=n(60102),k=n(77455),h=n(59201),i=Array;T.exports=function(){function c(m){var l=t(m),u=b(this),s=arguments.length,d=s>1?arguments[1]:void 0,v=d!==void 0;v&&(d=e(d,s>2?arguments[2]:void 0));var g=h(l),C=0,f,N,V,B,I,L;if(g&&!(this===i&&p(g)))for(N=u?new this:[],B=k(l,g),I=B.next;!(V=a(I,B)).done;C++)L=v?o(B,d,[V.value,C],!0):V.value,S(N,C,L);else for(f=y(l),N=u?new this(f):i(f);f>C;C++)L=v?d(l[C],C):l[C],S(N,C,L);return N.length=C,N}return c}()},14211:function(T,r,n){"use strict";var e=n(57591),a=n(13912),t=n(24760),o=function(b){return function(y,S,k){var h=e(y),i=t(h);if(i===0)return!b&&-1;var c=a(k,i),m;if(b&&S!==S){for(;i>c;)if(m=h[c++],m!==m)return!0}else for(;i>c;c++)if((b||c in h)&&h[c]===S)return b||c||0;return!b&&-1}};T.exports={includes:o(!0),indexOf:o(!1)}},22603:function(T,r,n){"use strict";var e=n(75754),a=n(67250),t=n(37457),o=n(46771),p=n(24760),b=n(57823),y=a([].push),S=function(h){var i=h===1,c=h===2,m=h===3,l=h===4,u=h===6,s=h===7,d=h===5||u;return function(v,g,C,f){for(var N=o(v),V=t(N),B=p(V),I=e(g,C),L=0,w=f||b,A=i?w(v,B):c||s?w(v,0):void 0,x,E;B>L;L++)if((d||L in V)&&(x=V[L],E=I(x,L,N),h))if(i)A[L]=E;else if(E)switch(h){case 3:return!0;case 5:return x;case 6:return L;case 2:y(A,x)}else switch(h){case 4:return!1;case 7:y(A,x)}return u?-1:m||l?l:A}};T.exports={forEach:S(0),map:S(1),filter:S(2),some:S(3),every:S(4),find:S(5),findIndex:S(6),filterReject:S(7)}},1325:function(T,r,n){"use strict";var e=n(61267),a=n(57591),t=n(61365),o=n(24760),p=n(55528),b=Math.min,y=[].lastIndexOf,S=!!y&&1/[1].lastIndexOf(1,-0)<0,k=p("lastIndexOf"),h=S||!k;T.exports=h?function(){function i(c){if(S)return e(y,this,arguments)||0;var m=a(this),l=o(m);if(l===0)return-1;var u=l-1;for(arguments.length>1&&(u=b(u,t(arguments[1]))),u<0&&(u=l+u);u>=0;u--)if(u in m&&m[u]===c)return u||0;return-1}return i}():y},44091:function(T,r,n){"use strict";var e=n(40033),a=n(24697),t=n(5026),o=a("species");T.exports=function(p){return t>=51||!e(function(){var b=[],y=b.constructor={};return y[o]=function(){return{foo:1}},b[p](Boolean).foo!==1})}},55528:function(T,r,n){"use strict";var e=n(40033);T.exports=function(a,t){var o=[][a];return!!o&&e(function(){o.call(null,t||function(){return 1},1)})}},56844:function(T,r,n){"use strict";var e=n(10320),a=n(46771),t=n(37457),o=n(24760),p=TypeError,b="Reduce of empty array with no initial value",y=function(k){return function(h,i,c,m){var l=a(h),u=t(l),s=o(l);if(e(i),s===0&&c<2)throw new p(b);var d=k?s-1:0,v=k?-1:1;if(c<2)for(;;){if(d in u){m=u[d],d+=v;break}if(d+=v,k?d<0:s<=d)throw new p(b)}for(;k?d>=0:s>d;d+=v)d in u&&(m=i(m,u[d],d,l));return m}};T.exports={left:y(!1),right:y(!0)}},13345:function(T,r,n){"use strict";var e=n(58310),a=n(37386),t=TypeError,o=Object.getOwnPropertyDescriptor,p=e&&!function(){if(this!==void 0)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(b){return b instanceof TypeError}}();T.exports=p?function(b,y){if(a(b)&&!o(b,"length").writable)throw new t("Cannot set read only .length");return b.length=y}:function(b,y){return b.length=y}},54602:function(T,r,n){"use strict";var e=n(67250);T.exports=e([].slice)},90274:function(T,r,n){"use strict";var e=n(54602),a=Math.floor,t=function o(p,b){var y=p.length;if(y<8)for(var S=1,k,h;S0;)p[h]=p[--h];h!==S++&&(p[h]=k)}else for(var i=a(y/2),c=o(e(p,0,i),b),m=o(e(p,i),b),l=c.length,u=m.length,s=0,d=0;s1?arguments[1]:void 0),E;E=E?E.next:A.first;)for(x(E.value,E.key,this);E&&E.removed;)E=E.previous}return L}(),has:function(){function L(w){return!!I(this,w)}return L}()}),t(N,g?{get:function(){function L(w){var A=I(this,w);return A&&A.value}return L}(),set:function(){function L(w,A){return B(this,w===0?0:w,A)}return L}()}:{add:function(){function L(w){return B(this,w=w===0?0:w,w)}return L}()}),i&&a(N,"size",{configurable:!0,get:function(){function L(){return V(this).size}return L}()}),f}return s}(),setStrong:function(){function s(d,v,g){var C=v+" Iterator",f=u(v),N=u(C);S(d,v,function(V,B){l(this,{type:C,target:V,state:f(V),kind:B,last:void 0})},function(){for(var V=N(this),B=V.kind,I=V.last;I&&I.removed;)I=I.previous;return!V.target||!(V.last=I=I?I.next:V.state.first)?(V.target=void 0,k(void 0,!0)):k(B==="keys"?I.key:B==="values"?I.value:[I.key,I.value],!1)},g?"entries":"values",!g,!0),h(v)}return s}()}},39895:function(T,r,n){"use strict";var e=n(67250),a=n(30145),t=n(81969).getWeakData,o=n(60077),p=n(30365),b=n(42871),y=n(77568),S=n(49450),k=n(22603),h=n(45299),i=n(5419),c=i.set,m=i.getterFor,l=k.find,u=k.findIndex,s=e([].splice),d=0,v=function(N){return N.frozen||(N.frozen=new g)},g=function(){this.entries=[]},C=function(N,V){return l(N.entries,function(B){return B[0]===V})};g.prototype={get:function(){function f(N){var V=C(this,N);if(V)return V[1]}return f}(),has:function(){function f(N){return!!C(this,N)}return f}(),set:function(){function f(N,V){var B=C(this,N);B?B[1]=V:this.entries.push([N,V])}return f}(),delete:function(){function f(N){var V=u(this.entries,function(B){return B[0]===N});return~V&&s(this.entries,V,1),!!~V}return f}()},T.exports={getConstructor:function(){function f(N,V,B,I){var L=N(function(E,P){o(E,w),c(E,{type:V,id:d++,frozen:void 0}),b(P)||S(P,E[I],{that:E,AS_ENTRIES:B})}),w=L.prototype,A=m(V),x=function(){function E(P,D,M){var O=A(P),R=t(p(D),!0);return R===!0?v(O).set(D,M):R[O.id]=M,P}return E}();return a(w,{delete:function(){function E(P){var D=A(this);if(!y(P))return!1;var M=t(P);return M===!0?v(D).delete(P):M&&h(M,D.id)&&delete M[D.id]}return E}(),has:function(){function E(P){var D=A(this);if(!y(P))return!1;var M=t(P);return M===!0?v(D).has(P):M&&h(M,D.id)}return E}()}),a(w,B?{get:function(){function E(P){var D=A(this);if(y(P)){var M=t(P);return M===!0?v(D).get(P):M?M[D.id]:void 0}}return E}(),set:function(){function E(P,D){return x(this,P,D)}return E}()}:{add:function(){function E(P){return x(this,P,!0)}return E}()}),L}return f}()}},45150:function(T,r,n){"use strict";var e=n(63964),a=n(74685),t=n(67250),o=n(41314),p=n(55938),b=n(81969),y=n(49450),S=n(60077),k=n(55747),h=n(42871),i=n(77568),c=n(40033),m=n(92490),l=n(84925),u=n(5781);T.exports=function(s,d,v){var g=s.indexOf("Map")!==-1,C=s.indexOf("Weak")!==-1,f=g?"set":"add",N=a[s],V=N&&N.prototype,B=N,I={},L=function(O){var R=t(V[O]);p(V,O,O==="add"?function(){function F(W){return R(this,W===0?0:W),this}return F}():O==="delete"?function(F){return C&&!i(F)?!1:R(this,F===0?0:F)}:O==="get"?function(){function F(W){return C&&!i(W)?void 0:R(this,W===0?0:W)}return F}():O==="has"?function(){function F(W){return C&&!i(W)?!1:R(this,W===0?0:W)}return F}():function(){function F(W,U){return R(this,W===0?0:W,U),this}return F}())},w=o(s,!k(N)||!(C||V.forEach&&!c(function(){new N().entries().next()})));if(w)B=v.getConstructor(d,s,g,f),b.enable();else if(o(s,!0)){var A=new B,x=A[f](C?{}:-0,1)!==A,E=c(function(){A.has(1)}),P=m(function(M){new N(M)}),D=!C&&c(function(){for(var M=new N,O=5;O--;)M[f](O,O);return!M.has(-0)});P||(B=d(function(M,O){S(M,V);var R=u(new N,M,B);return h(O)||y(O,R[f],{that:R,AS_ENTRIES:g}),R}),B.prototype=V,V.constructor=B),(E||D)&&(L("delete"),L("has"),g&&L("get")),(D||x)&&L(f),C&&V.clear&&delete V.clear}return I[s]=B,e({global:!0,constructor:!0,forced:B!==N},I),l(B,s),C||v.setStrong(B,s,g),B}},5774:function(T,r,n){"use strict";var e=n(45299),a=n(97921),t=n(27193),o=n(74595);T.exports=function(p,b,y){for(var S=a(b),k=o.f,h=t.f,i=0;i"+h+""+y+">"}},5959:function(T){"use strict";T.exports=function(r,n){return{value:r,done:n}}},37909:function(T,r,n){"use strict";var e=n(58310),a=n(74595),t=n(87458);T.exports=e?function(o,p,b){return a.f(o,p,t(1,b))}:function(o,p,b){return o[p]=b,o}},87458:function(T){"use strict";T.exports=function(r,n){return{enumerable:!(r&1),configurable:!(r&2),writable:!(r&4),value:n}}},60102:function(T,r,n){"use strict";var e=n(58310),a=n(74595),t=n(87458);T.exports=function(o,p,b){e?a.f(o,p,t(0,b)):o[p]=b}},67206:function(T,r,n){"use strict";var e=n(67250),a=n(40033),t=n(24051).start,o=RangeError,p=isFinite,b=Math.abs,y=Date.prototype,S=y.toISOString,k=e(y.getTime),h=e(y.getUTCDate),i=e(y.getUTCFullYear),c=e(y.getUTCHours),m=e(y.getUTCMilliseconds),l=e(y.getUTCMinutes),u=e(y.getUTCMonth),s=e(y.getUTCSeconds);T.exports=a(function(){return S.call(new Date(-50000000000001))!=="0385-07-25T07:06:39.999Z"})||!a(function(){S.call(new Date(NaN))})?function(){function d(){if(!p(k(this)))throw new o("Invalid time value");var v=this,g=i(v),C=m(v),f=g<0?"-":g>9999?"+":"";return f+t(b(g),f?6:4,0)+"-"+t(u(v)+1,2,0)+"-"+t(h(v),2,0)+"T"+t(c(v),2,0)+":"+t(l(v),2,0)+":"+t(s(v),2,0)+"."+t(C,3,0)+"Z"}return d}():S},10886:function(T,r,n){"use strict";var e=n(30365),a=n(13396),t=TypeError;T.exports=function(o){if(e(this),o==="string"||o==="default")o="string";else if(o!=="number")throw new t("Incorrect hint");return a(this,o)}},73936:function(T,r,n){"use strict";var e=n(20001),a=n(74595);T.exports=function(t,o,p){return p.get&&e(p.get,o,{getter:!0}),p.set&&e(p.set,o,{setter:!0}),a.f(t,o,p)}},55938:function(T,r,n){"use strict";var e=n(55747),a=n(74595),t=n(20001),o=n(18231);T.exports=function(p,b,y,S){S||(S={});var k=S.enumerable,h=S.name!==void 0?S.name:b;if(e(y)&&t(y,h,S),S.global)k?p[b]=y:o(b,y);else{try{S.unsafe?p[b]&&(k=!0):delete p[b]}catch(i){}k?p[b]=y:a.f(p,b,{value:y,enumerable:!1,configurable:!S.nonConfigurable,writable:!S.nonWritable})}return p}},30145:function(T,r,n){"use strict";var e=n(55938);T.exports=function(a,t,o){for(var p in t)e(a,p,t[p],o);return a}},18231:function(T,r,n){"use strict";var e=n(74685),a=Object.defineProperty;T.exports=function(t,o){try{a(e,t,{value:o,configurable:!0,writable:!0})}catch(p){e[t]=o}return o}},95108:function(T,r,n){"use strict";var e=n(89393),a=TypeError;T.exports=function(t,o){if(!delete t[o])throw new a("Cannot delete property "+e(o)+" of "+e(t))}},58310:function(T,r,n){"use strict";var e=n(40033);T.exports=!e(function(){return Object.defineProperty({},1,{get:function(){function a(){return 7}return a}()})[1]!==7})},12689:function(T,r,n){"use strict";var e=n(74685),a=n(77568),t=e.document,o=a(t)&&a(t.createElement);T.exports=function(p){return o?t.createElement(p):{}}},21291:function(T){"use strict";var r=TypeError,n=9007199254740991;T.exports=function(e){if(e>n)throw r("Maximum allowed index exceeded");return e}},652:function(T,r,n){"use strict";var e=n(63318),a=e.match(/firefox\/(\d+)/i);T.exports=!!a&&+a[1]},8180:function(T,r,n){"use strict";var e=n(73730),a=n(81702);T.exports=!e&&!a&&typeof window=="object"&&typeof document=="object"},49197:function(T){"use strict";T.exports=typeof Bun=="function"&&Bun&&typeof Bun.version=="string"},73730:function(T){"use strict";T.exports=typeof Deno=="object"&&Deno&&typeof Deno.version=="object"},19228:function(T,r,n){"use strict";var e=n(63318);T.exports=/MSIE|Trident/.test(e)},51802:function(T,r,n){"use strict";var e=n(63318);T.exports=/ipad|iphone|ipod/i.test(e)&&typeof Pebble!="undefined"},83433:function(T,r,n){"use strict";var e=n(63318);T.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(e)},81702:function(T,r,n){"use strict";var e=n(74685),a=n(7462);T.exports=a(e.process)==="process"},63383:function(T,r,n){"use strict";var e=n(63318);T.exports=/web0s(?!.*chrome)/i.test(e)},63318:function(T){"use strict";T.exports=typeof navigator!="undefined"&&String(navigator.userAgent)||""},5026:function(T,r,n){"use strict";var e=n(74685),a=n(63318),t=e.process,o=e.Deno,p=t&&t.versions||o&&o.version,b=p&&p.v8,y,S;b&&(y=b.split("."),S=y[0]>0&&y[0]<4?1:+(y[0]+y[1])),!S&&a&&(y=a.match(/Edge\/(\d+)/),(!y||y[1]>=74)&&(y=a.match(/Chrome\/(\d+)/),y&&(S=+y[1]))),T.exports=S},9342:function(T,r,n){"use strict";var e=n(63318),a=e.match(/AppleWebKit\/(\d+)\./);T.exports=!!a&&+a[1]},89453:function(T){"use strict";T.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},63964:function(T,r,n){"use strict";var e=n(74685),a=n(27193).f,t=n(37909),o=n(55938),p=n(18231),b=n(5774),y=n(41314);T.exports=function(S,k){var h=S.target,i=S.global,c=S.stat,m,l,u,s,d,v;if(i?l=e:c?l=e[h]||p(h,{}):l=e[h]&&e[h].prototype,l)for(u in k){if(d=k[u],S.dontCallGetSet?(v=a(l,u),s=v&&v.value):s=l[u],m=y(i?u:h+(c?".":"#")+u,S.forced),!m&&s!==void 0){if(typeof d==typeof s)continue;b(d,s)}(S.sham||s&&s.sham)&&t(d,"sham",!0),o(l,u,d,S)}}},40033:function(T){"use strict";T.exports=function(r){try{return!!r()}catch(n){return!0}}},79942:function(T,r,n){"use strict";n(79669);var e=n(91495),a=n(55938),t=n(14489),o=n(40033),p=n(24697),b=n(37909),y=p("species"),S=RegExp.prototype;T.exports=function(k,h,i,c){var m=p(k),l=!o(function(){var v={};return v[m]=function(){return 7},""[k](v)!==7}),u=l&&!o(function(){var v=!1,g=/a/;return k==="split"&&(g={},g.constructor={},g.constructor[y]=function(){return g},g.flags="",g[m]=/./[m]),g.exec=function(){return v=!0,null},g[m](""),!v});if(!l||!u||i){var s=/./[m],d=h(m,""[k],function(v,g,C,f,N){var V=g.exec;return V===t||V===S.exec?l&&!N?{done:!0,value:e(s,g,C,f)}:{done:!0,value:e(v,C,g,f)}:{done:!1}});a(String.prototype,k,d[0]),a(S,m,d[1])}c&&b(S[m],"sham",!0)}},65561:function(T,r,n){"use strict";var e=n(37386),a=n(24760),t=n(21291),o=n(75754),p=function b(y,S,k,h,i,c,m,l){for(var u=i,s=0,d=m?o(m,l):!1,v,g;s0&&e(v)?(g=a(v),u=b(y,S,v,g,u,c-1)-1):(t(u+1),y[u]=v),u++),s++;return u};T.exports=p},50730:function(T,r,n){"use strict";var e=n(40033);T.exports=!e(function(){return Object.isExtensible(Object.preventExtensions({}))})},61267:function(T,r,n){"use strict";var e=n(55050),a=Function.prototype,t=a.apply,o=a.call;T.exports=typeof Reflect=="object"&&Reflect.apply||(e?o.bind(t):function(){return o.apply(t,arguments)})},75754:function(T,r,n){"use strict";var e=n(71138),a=n(10320),t=n(55050),o=e(e.bind);T.exports=function(p,b){return a(p),b===void 0?p:t?o(p,b):function(){return p.apply(b,arguments)}}},55050:function(T,r,n){"use strict";var e=n(40033);T.exports=!e(function(){var a=function(){}.bind();return typeof a!="function"||a.hasOwnProperty("prototype")})},66284:function(T,r,n){"use strict";var e=n(67250),a=n(10320),t=n(77568),o=n(45299),p=n(54602),b=n(55050),y=Function,S=e([].concat),k=e([].join),h={},i=function(m,l,u){if(!o(h,l)){for(var s=[],d=0;d]*>)/g,S=/\$([$&'`]|\d{1,2})/g;T.exports=function(k,h,i,c,m,l){var u=i+k.length,s=c.length,d=S;return m!==void 0&&(m=a(m),d=y),p(l,d,function(v,g){var C;switch(o(g,0)){case"$":return"$";case"&":return k;case"`":return b(h,0,i);case"'":return b(h,u);case"<":C=m[b(g,1,-1)];break;default:var f=+g;if(f===0)return v;if(f>s){var N=t(f/10);return N===0?v:N<=s?c[N-1]===void 0?o(g,1):c[N-1]+o(g,1):v}C=c[f-1]}return C===void 0?"":C})}},74685:function(T,r,n){"use strict";var e=function(t){return t&&t.Math===Math&&t};T.exports=e(typeof globalThis=="object"&&globalThis)||e(typeof window=="object"&&window)||e(typeof self=="object"&&self)||e(typeof n.g=="object"&&n.g)||e(!1)||function(){return this}()||Function("return this")()},45299:function(T,r,n){"use strict";var e=n(67250),a=n(46771),t=e({}.hasOwnProperty);T.exports=Object.hasOwn||function(){function o(p,b){return t(a(p),b)}return o}()},79195:function(T){"use strict";T.exports={}},72259:function(T){"use strict";T.exports=function(r,n){try{arguments.length}catch(e){}}},5315:function(T,r,n){"use strict";var e=n(4009);T.exports=e("document","documentElement")},36223:function(T,r,n){"use strict";var e=n(58310),a=n(40033),t=n(12689);T.exports=!e&&!a(function(){return Object.defineProperty(t("div"),"a",{get:function(){function o(){return 7}return o}()}).a!==7})},91784:function(T){"use strict";var r=Array,n=Math.abs,e=Math.pow,a=Math.floor,t=Math.log,o=Math.LN2,p=function(S,k,h){var i=r(h),c=h*8-k-1,m=(1<>1,u=k===23?e(2,-24)-e(2,-77):0,s=S<0||S===0&&1/S<0?1:0,d=0,v,g,C;for(S=n(S),S!==S||S===1/0?(g=S!==S?1:0,v=m):(v=a(t(S)/o),C=e(2,-v),S*C<1&&(v--,C*=2),v+l>=1?S+=u/C:S+=u*e(2,1-l),S*C>=2&&(v++,C/=2),v+l>=m?(g=0,v=m):v+l>=1?(g=(S*C-1)*e(2,k),v+=l):(g=S*e(2,l-1)*e(2,k),v=0));k>=8;)i[d++]=g&255,g/=256,k-=8;for(v=v<0;)i[d++]=v&255,v/=256,c-=8;return i[--d]|=s*128,i},b=function(S,k){var h=S.length,i=h*8-k-1,c=(1<>1,l=i-7,u=h-1,s=S[u--],d=s&127,v;for(s>>=7;l>0;)d=d*256+S[u--],l-=8;for(v=d&(1<<-l)-1,d>>=-l,l+=k;l>0;)v=v*256+S[u--],l-=8;if(d===0)d=1-m;else{if(d===c)return v?NaN:s?-1/0:1/0;v+=e(2,k),d-=m}return(s?-1:1)*v*e(2,d-k)};T.exports={pack:p,unpack:b}},37457:function(T,r,n){"use strict";var e=n(67250),a=n(40033),t=n(7462),o=Object,p=e("".split);T.exports=a(function(){return!o("z").propertyIsEnumerable(0)})?function(b){return t(b)==="String"?p(b,""):o(b)}:o},5781:function(T,r,n){"use strict";var e=n(55747),a=n(77568),t=n(76649);T.exports=function(o,p,b){var y,S;return t&&e(y=p.constructor)&&y!==b&&a(S=y.prototype)&&S!==b.prototype&&t(o,S),o}},40492:function(T,r,n){"use strict";var e=n(67250),a=n(55747),t=n(40095),o=e(Function.toString);a(t.inspectSource)||(t.inspectSource=function(p){return o(p)}),T.exports=t.inspectSource},81969:function(T,r,n){"use strict";var e=n(63964),a=n(67250),t=n(79195),o=n(77568),p=n(45299),b=n(74595).f,y=n(37310),S=n(81644),k=n(81834),h=n(16738),i=n(50730),c=!1,m=h("meta"),l=0,u=function(N){b(N,m,{value:{objectID:"O"+l++,weakData:{}}})},s=function(N,V){if(!o(N))return typeof N=="symbol"?N:(typeof N=="string"?"S":"P")+N;if(!p(N,m)){if(!k(N))return"F";if(!V)return"E";u(N)}return N[m].objectID},d=function(N,V){if(!p(N,m)){if(!k(N))return!0;if(!V)return!1;u(N)}return N[m].weakData},v=function(N){return i&&c&&k(N)&&!p(N,m)&&u(N),N},g=function(){C.enable=function(){},c=!0;var N=y.f,V=a([].splice),B={};B[m]=1,N(B).length&&(y.f=function(I){for(var L=N(I),w=0,A=L.length;wI;I++)if(w=P(l[I]),w&&y(m,w))return w;return new c(!1)}V=S(l,B)}for(A=g?l.next:V.next;!(x=a(A,V)).done;){try{w=P(x.value)}catch(D){h(V,"throw",D)}if(typeof w=="object"&&w&&y(m,w))return w}return new c(!1)}},28649:function(T,r,n){"use strict";var e=n(91495),a=n(30365),t=n(78060);T.exports=function(o,p,b){var y,S;a(o);try{if(y=t(o,"return"),!y){if(p==="throw")throw b;return b}y=e(y,o)}catch(k){S=!0,y=k}if(p==="throw")throw b;if(S)throw y;return a(y),b}},5656:function(T,r,n){"use strict";var e=n(67635).IteratorPrototype,a=n(80674),t=n(87458),o=n(84925),p=n(83967),b=function(){return this};T.exports=function(y,S,k,h){var i=S+" Iterator";return y.prototype=a(e,{next:t(+!h,k)}),o(y,i,!1,!0),p[i]=b,y}},65574:function(T,r,n){"use strict";var e=n(63964),a=n(91495),t=n(4493),o=n(70520),p=n(55747),b=n(5656),y=n(36917),S=n(76649),k=n(84925),h=n(37909),i=n(55938),c=n(24697),m=n(83967),l=n(67635),u=o.PROPER,s=o.CONFIGURABLE,d=l.IteratorPrototype,v=l.BUGGY_SAFARI_ITERATORS,g=c("iterator"),C="keys",f="values",N="entries",V=function(){return this};T.exports=function(B,I,L,w,A,x,E){b(L,I,w);var P=function(X){if(X===A&&F)return F;if(!v&&X&&X in O)return O[X];switch(X){case C:return function(){function J(){return new L(this,X)}return J}();case f:return function(){function J(){return new L(this,X)}return J}();case N:return function(){function J(){return new L(this,X)}return J}()}return function(){return new L(this)}},D=I+" Iterator",M=!1,O=B.prototype,R=O[g]||O["@@iterator"]||A&&O[A],F=!v&&R||P(A),W=I==="Array"&&O.entries||R,U,z,$;if(W&&(U=y(W.call(new B)),U!==Object.prototype&&U.next&&(!t&&y(U)!==d&&(S?S(U,d):p(U[g])||i(U,g,V)),k(U,D,!0,!0),t&&(m[D]=V))),u&&A===f&&R&&R.name!==f&&(!t&&s?h(O,"name",f):(M=!0,F=function(){function G(){return a(R,this)}return G}())),A)if(z={values:P(f),keys:x?F:P(C),entries:P(N)},E)for($ in z)(v||M||!($ in O))&&i(O,$,z[$]);else e({target:I,proto:!0,forced:v||M},z);return(!t||E)&&O[g]!==F&&i(O,g,F,{name:A}),m[I]=F,z}},67635:function(T,r,n){"use strict";var e=n(40033),a=n(55747),t=n(77568),o=n(80674),p=n(36917),b=n(55938),y=n(24697),S=n(4493),k=y("iterator"),h=!1,i,c,m;[].keys&&(m=[].keys(),"next"in m?(c=p(p(m)),c!==Object.prototype&&(i=c)):h=!0);var l=!t(i)||e(function(){var u={};return i[k].call(u)!==u});l?i={}:S&&(i=o(i)),a(i[k])||b(i,k,function(){return this}),T.exports={IteratorPrototype:i,BUGGY_SAFARI_ITERATORS:h}},83967:function(T){"use strict";T.exports={}},24760:function(T,r,n){"use strict";var e=n(10188);T.exports=function(a){return e(a.length)}},20001:function(T,r,n){"use strict";var e=n(67250),a=n(40033),t=n(55747),o=n(45299),p=n(58310),b=n(70520).CONFIGURABLE,y=n(40492),S=n(5419),k=S.enforce,h=S.get,i=String,c=Object.defineProperty,m=e("".slice),l=e("".replace),u=e([].join),s=p&&!a(function(){return c(function(){},"length",{value:8}).length!==8}),d=String(String).split("String"),v=T.exports=function(g,C,f){m(i(C),0,7)==="Symbol("&&(C="["+l(i(C),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),f&&f.getter&&(C="get "+C),f&&f.setter&&(C="set "+C),(!o(g,"name")||b&&g.name!==C)&&(p?c(g,"name",{value:C,configurable:!0}):g.name=C),s&&f&&o(f,"arity")&&g.length!==f.arity&&c(g,"length",{value:f.arity});try{f&&o(f,"constructor")&&f.constructor?p&&c(g,"prototype",{writable:!1}):g.prototype&&(g.prototype=void 0)}catch(V){}var N=k(g);return o(N,"source")||(N.source=u(d,typeof C=="string"?C:"")),g};Function.prototype.toString=v(function(){function g(){return t(this)&&h(this).source||y(this)}return g}(),"toString")},82040:function(T){"use strict";var r=Math.expm1,n=Math.exp;T.exports=!r||r(10)>22025.465794806718||r(10)<22025.465794806718||r(-2e-17)!==-2e-17?function(){function e(a){var t=+a;return t===0?t:t>-1e-6&&t<1e-6?t+t*t/2:n(t)-1}return e}():r},14950:function(T,r,n){"use strict";var e=n(22172),a=Math.abs,t=2220446049250313e-31,o=1/t,p=function(y){return y+o-o};T.exports=function(b,y,S,k){var h=+b,i=a(h),c=e(h);if(i