From cf0239052c404d0645b8d8b100e9b8a08f80cd70 Mon Sep 17 00:00:00 2001 From: actioninja Date: Thu, 9 Apr 2020 19:43:51 -0700 Subject: [PATCH] wire ui --- tgui/packages/tgui/interfaces/Wires.js | 100 +++++++++++++------------ 1 file changed, 51 insertions(+), 49 deletions(-) diff --git a/tgui/packages/tgui/interfaces/Wires.js b/tgui/packages/tgui/interfaces/Wires.js index f33b2617382..e3fcdeeebd0 100644 --- a/tgui/packages/tgui/interfaces/Wires.js +++ b/tgui/packages/tgui/interfaces/Wires.js @@ -1,59 +1,61 @@ import { Fragment } from 'inferno'; import { useBackend } from '../backend'; -import { Box, Button, LabeledList, Section } from '../components'; +import { Box, Button, LabeledList, Section, Layout } from '../components'; -export const Wires = props => { - const { act, data } = useBackend(props); +export const Wires = (props, context) => { + const { act, data } = useBackend(context); const wires = data.wires || []; const statuses = data.status || []; return ( - -
- - {wires.map(wire => ( - -
- {!!statuses.length && ( + +
- {statuses.map(status => ( - - {status} - - ))} + + {wires.map(wire => ( + +
- )} -
+ {!!statuses.length && ( +
+ {statuses.map(status => ( + + {status} + + ))} +
+ )} + + ); };