From 5f4d6daf1b33761d8e5d254a343a9c7304653007 Mon Sep 17 00:00:00 2001 From: John Mitchell Date: Tue, 20 Oct 2020 17:33:37 -0400 Subject: [PATCH] update dashboard to 3 tab single pane --- .../src/screens/Dashboard/Dashboard.jsx | 157 +++++++++--------- 1 file changed, 83 insertions(+), 74 deletions(-) diff --git a/awx/ui_next/src/screens/Dashboard/Dashboard.jsx b/awx/ui_next/src/screens/Dashboard/Dashboard.jsx index 59f05c2cfb..736a9a7482 100644 --- a/awx/ui_next/src/screens/Dashboard/Dashboard.jsx +++ b/awx/ui_next/src/screens/Dashboard/Dashboard.jsx @@ -5,7 +5,6 @@ import { t } from '@lingui/macro'; import { Card, CardHeader, - CardHeaderMain, CardActions, CardBody, PageSection, @@ -16,9 +15,6 @@ import { Tabs, Tab, TabTitleText, - Text, - TextContent, - TextVariants, Title, } from '@patternfly/react-core'; @@ -34,7 +30,6 @@ const Counts = styled.div` display: grid; grid-template-columns: repeat(6, 1fr); grid-gap: var(--pf-global--spacer--lg); - margin-bottom: var(--pf-global--spacer--lg); @media (max-width: 900px) { grid-template-columns: repeat(3, 1fr); @@ -42,16 +37,24 @@ const Counts = styled.div` } `; -const ListPageSection = styled(PageSection)` +const MainPageSection = styled(PageSection)` padding-top: 0; padding-bottom: 0; - min-height: 626px; & .spacer { margin-bottom: var(--pf-global--spacer--lg); } `; +const GraphCardHeader = styled(CardHeader)` + margin-top: var(--pf-global--spacer--lg); +`; + +const GraphCardActions = styled(CardActions)` + margin-left: initial; + padding-left: 0; +`; + function Dashboard({ i18n }) { const { light } = PageSectionVariants; @@ -149,69 +152,8 @@ function Dashboard({ i18n }) { label={i18n._(t`Project sync failures`)} /> - - - - - {i18n._(t`Job Status`)} - - - - - - - - - - - - +
setActiveTabId(eventKey)} > {i18n._(t`Job status`)}} + /> + {i18n._(t`Recent Jobs`)}} /> {i18n._(t`Recent Templates`)} } /> - {activeTabId === 0 && } - {activeTabId === 1 && } + {activeTabId === 0 && ( + + + + + + + + + + + + )} + {activeTabId === 1 && } + {activeTabId === 2 && }
-
+ ); }