Commit 762c2f80 authored by Scarlett Perry's avatar Scarlett Perry
Browse files

add mock cards for PR reviewers

parent f6e7a827
Showing with 124 additions and 2 deletions
+124 -2
import * as React from "react";
import { Table, TableRow, Typography } from "@clutch-sh/core";
import styled from "@emotion/styled";
import { Box } from "@material-ui/core";
import { Box, Grid as MuiGrid } from "@material-ui/core";
import _ from "lodash";
import Card from "./card";
import { DashDispatchContext, DashStateContext } from "./dash-hooks";
import ProjectSelector from "./project-selector";
import type { DashAction, DashState } from "./types";
......@@ -19,6 +21,10 @@ const CardContainer = styled.div({
overflowY: "scroll",
});
const BigGrid = styled(MuiGrid)({
margin: "7px",
});
const dashReducer = (state: DashState, action: DashAction): DashState => {
switch (action.type) {
case "UPDATE_SELECTED": {
......@@ -40,7 +46,123 @@ const Dash = ({ children }) => {
<DashDispatchContext.Provider value={dispatch}>
<DashStateContext.Provider value={state}>
<ProjectSelector />
<CardContainer>{children}</CardContainer>
<CardContainer>
<BigGrid
spacing={3}
container
direction="row"
justify="flex-start"
alignItems="flex-start"
alignContent="flex-start"
>
<Card
avatar="🚀"
title="Deploys"
summary={[
{
title: <Typography variant="subtitle2">-</Typography>,
subheader: "Last Deploy",
},
{
title: (
<Typography variant="subtitle2" color="#3548D4">
0
</Typography>
),
subheader: "In progress",
},
{
title: (
<Typography variant="subtitle2" color="#DB3615">
0
</Typography>
),
subheader: "Failed Deploys",
},
]}
>
<Table columns={["", "", "", ""]} responsive>
<TableRow>
<div>clutch</div>
<div>No commits</div>
<div>0m</div>
<div>✅ 🥚</div>
</TableRow>
<TableRow>
<div>clutch</div>
<div>No commits</div>
<div>0m</div>
<div>✅ 🥚</div>
</TableRow>
<TableRow>
<div>clutch</div>
<div>No commits</div>
<div>0m</div>
<div>✅ 🥚</div>
</TableRow>
</Table>
</Card>
<Card
avatar="🚨"
title="Alerts"
summary={[
{
title: <Typography variant="subtitle2">-</Typography>,
subheader: "Last alert",
},
{
title: (
<Typography variant="subtitle2" color="#3548D4">
0
</Typography>
),
subheader: "Open",
},
{
title: (
<Typography variant="subtitle2" color="#DB3615">
0
</Typography>
),
subheader: "Acknowledged",
},
]}
>
<Table columns={["", "", "", ""]} responsive>
<TableRow>
<div>clutch</div>
<div>No alerts</div>
<></>
<></>
</TableRow>
<TableRow>
<div>clutch</div>
<div>No alerts</div>
<></>
<></>
</TableRow>
<TableRow>
<div>clutch</div>
<div>No alerts</div>
<></>
<></>
</TableRow>
</Table>
</Card>
<Card avatar="🌏" title="Incidents">
<Table columns={["", ""]} responsive>
<TableRow>
<div>AWS</div>
<div>Healthy</div>
</TableRow>
<TableRow>
<div>Github</div>
<div>Healthy</div>
</TableRow>
</Table>
</Card>
</BigGrid>
</CardContainer>
</DashStateContext.Provider>
</DashDispatchContext.Provider>
</Box>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment