From 99e9cff6920af12e24e900ae8131f92c5228d4a0 Mon Sep 17 00:00:00 2001 From: presleyp Date: Wed, 22 Jun 2022 19:25:20 +0000 Subject: [PATCH 1/2] Move agent status --- site/src/components/Resources/Resources.tsx | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/site/src/components/Resources/Resources.tsx b/site/src/components/Resources/Resources.tsx index 7944323eb4738..b3c1e772ab012 100644 --- a/site/src/components/Resources/Resources.tsx +++ b/site/src/components/Resources/Resources.tsx @@ -21,7 +21,6 @@ const Language = { resourceLabel: "Resource", agentsLabel: "Agents", agentLabel: "Agent", - statusLabel: "Status", accessLabel: "Access", } @@ -57,7 +56,6 @@ export const Resources: FC = ({ resources, getResourcesError, wo {canUpdateWorkspace && {Language.accessLabel}} - {Language.statusLabel} @@ -82,6 +80,7 @@ export const Resources: FC = ({ resources, getResourcesError, wo ) } + const agentStatus = getDisplayAgentStatus(theme, agent) return ( {/* We only want to display the name in the first row because we are using rowSpan */} @@ -90,12 +89,16 @@ export const Resources: FC = ({ resources, getResourcesError, wo {resource.name} {resource.type} + )} {agent.name} {agent.operating_system} + + {agentStatus.status} + {canUpdateWorkspace && ( @@ -121,11 +124,6 @@ export const Resources: FC = ({ resources, getResourcesError, wo )} - - - {getDisplayAgentStatus(theme, agent).status} - - ) }) From 95ad3e8d4d84f2b38a49ecc76090172d9b3b39f9 Mon Sep 17 00:00:00 2001 From: presleyp Date: Wed, 22 Jun 2022 20:22:08 +0000 Subject: [PATCH 2/2] Format --- site/src/components/Resources/Resources.tsx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/site/src/components/Resources/Resources.tsx b/site/src/components/Resources/Resources.tsx index b3c1e772ab012..a32a2d082a6ef 100644 --- a/site/src/components/Resources/Resources.tsx +++ b/site/src/components/Resources/Resources.tsx @@ -89,16 +89,13 @@ export const Resources: FC = ({ resources, getResourcesError, wo {resource.name} {resource.type} - )} {agent.name} {agent.operating_system} - - {agentStatus.status} - + {agentStatus.status} {canUpdateWorkspace && (