|
@@ -20,25 +20,25 @@ const mockData: Environment[] = [
|
|
|
id: 1,
|
|
id: 1,
|
|
|
url: "http://some-url",
|
|
url: "http://some-url",
|
|
|
pr_link: "https://githubsuper",
|
|
pr_link: "https://githubsuper",
|
|
|
- status: "some",
|
|
|
|
|
|
|
+ status: "deployed",
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
id: 2,
|
|
id: 2,
|
|
|
url: "http://some-url",
|
|
url: "http://some-url",
|
|
|
pr_link: "https://githubsuper",
|
|
pr_link: "https://githubsuper",
|
|
|
- status: "some",
|
|
|
|
|
|
|
+ status: "deployed",
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
id: 3,
|
|
id: 3,
|
|
|
url: "http://some-url",
|
|
url: "http://some-url",
|
|
|
pr_link: "https://githubsuper",
|
|
pr_link: "https://githubsuper",
|
|
|
- status: "some",
|
|
|
|
|
|
|
+ status: "deployed",
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
id: 4,
|
|
id: 4,
|
|
|
url: "http://some-url",
|
|
url: "http://some-url",
|
|
|
pr_link: "https://githubsuper",
|
|
pr_link: "https://githubsuper",
|
|
|
- status: "some",
|
|
|
|
|
|
|
+ status: "deployed",
|
|
|
},
|
|
},
|
|
|
];
|
|
];
|
|
|
|
|
|
|
@@ -110,7 +110,11 @@ const EnvironmentList = () => {
|
|
|
}, [location.search, history]);
|
|
}, [location.search, history]);
|
|
|
|
|
|
|
|
if (showConnectRepoFlow) {
|
|
if (showConnectRepoFlow) {
|
|
|
- return <ConnectNewRepo />;
|
|
|
|
|
|
|
+ return (
|
|
|
|
|
+ <Container>
|
|
|
|
|
+ <ConnectNewRepo />
|
|
|
|
|
+ </Container>
|
|
|
|
|
+ );
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
if (isLoading) {
|
|
if (isLoading) {
|
|
@@ -130,9 +134,12 @@ const EnvironmentList = () => {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
return (
|
|
return (
|
|
|
- <>
|
|
|
|
|
|
|
+ <Container>
|
|
|
<ControlRow>
|
|
<ControlRow>
|
|
|
- <Button onClick={() => console.log("launch repo")}>
|
|
|
|
|
|
|
+ <Button
|
|
|
|
|
+ to={`${currentUrl}?selected_tab=preview_environments&action=connect-repo`}
|
|
|
|
|
+ onClick={() => console.log("launch repo")}
|
|
|
|
|
+ >
|
|
|
<i className="material-icons">add</i> Add repository
|
|
<i className="material-icons">add</i> Add repository
|
|
|
</Button>
|
|
</Button>
|
|
|
<SortFilterWrapper>
|
|
<SortFilterWrapper>
|
|
@@ -158,7 +165,7 @@ const EnvironmentList = () => {
|
|
|
</DataAndIconContainer>
|
|
</DataAndIconContainer>
|
|
|
<StatusContainer>
|
|
<StatusContainer>
|
|
|
<Status>
|
|
<Status>
|
|
|
- <StatusDot status="deployed" />
|
|
|
|
|
|
|
+ <StatusDot status={env.status} />
|
|
|
{capitalize(env.status)}
|
|
{capitalize(env.status)}
|
|
|
</Status>
|
|
</Status>
|
|
|
</StatusContainer>
|
|
</StatusContainer>
|
|
@@ -166,14 +173,17 @@ const EnvironmentList = () => {
|
|
|
);
|
|
);
|
|
|
})}
|
|
})}
|
|
|
</EventsGrid>
|
|
</EventsGrid>
|
|
|
- </>
|
|
|
|
|
|
|
+ </Container>
|
|
|
);
|
|
);
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
export default EnvironmentList;
|
|
export default EnvironmentList;
|
|
|
|
|
|
|
|
-const ControlRow = styled.div`
|
|
|
|
|
|
|
+const Container = styled.div`
|
|
|
margin-top: 30px;
|
|
margin-top: 30px;
|
|
|
|
|
+`;
|
|
|
|
|
+
|
|
|
|
|
+const ControlRow = styled.div`
|
|
|
display: flex;
|
|
display: flex;
|
|
|
margin-left: auto;
|
|
margin-left: auto;
|
|
|
justify-content: space-between;
|
|
justify-content: space-between;
|
|
@@ -182,7 +192,7 @@ const ControlRow = styled.div`
|
|
|
padding-left: 0px;
|
|
padding-left: 0px;
|
|
|
`;
|
|
`;
|
|
|
|
|
|
|
|
-const Button = styled.div`
|
|
|
|
|
|
|
+const Button = styled(DynamicLink)`
|
|
|
display: flex;
|
|
display: flex;
|
|
|
flex-direction: row;
|
|
flex-direction: row;
|
|
|
align-items: center;
|
|
align-items: center;
|
|
@@ -246,7 +256,7 @@ const EnvironmentCard = styled(DynamicLink)`
|
|
|
border-radius: 8px;
|
|
border-radius: 8px;
|
|
|
padding: 20px;
|
|
padding: 20px;
|
|
|
|
|
|
|
|
- animation: fadeIn 0.5s;
|
|
|
|
|
|
|
+ animation: fadeIn 0.8s;
|
|
|
@keyframes fadeIn {
|
|
@keyframes fadeIn {
|
|
|
from {
|
|
from {
|
|
|
opacity: 0;
|
|
opacity: 0;
|
|
@@ -266,7 +276,7 @@ const EnvironmentCard = styled(DynamicLink)`
|
|
|
|
|
|
|
|
const EventsGrid = styled.div`
|
|
const EventsGrid = styled.div`
|
|
|
display: grid;
|
|
display: grid;
|
|
|
- grid-row-gap: 15px;
|
|
|
|
|
|
|
+ grid-row-gap: 20px;
|
|
|
grid-template-columns: 1;
|
|
grid-template-columns: 1;
|
|
|
`;
|
|
`;
|
|
|
|
|
|