Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/Routes.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import EditProjectLayout from "./layouts/entity/project/edit/EditProjectLayout";
import ProjectPricingLayout from "./layouts/entity/project/pricing/ProjectPricingLayout";
import RegisterLayout from "./layouts/auth/register/RegisterLayout";
import ConfirmEmailLayout from "./layouts/auth/confirmEmail/ConfirmEmailLayout";
import NotFoundLayout from "./layouts/404/NotFoundLayout";

class Routes extends React.Component {
render() {
Expand Down Expand Up @@ -61,6 +62,9 @@ class Routes extends React.Component {

<Route path="/:owner/:alias/board/:boardGuid" exact component={BoardPage}/>
</Switch>
<Switch>
<Route component={NotFoundLayout}/>
</Switch>
</div>
);
}
Expand Down
34 changes: 34 additions & 0 deletions src/layouts/404/NotFoundLayout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import React from "react";
import FullContainerPage from "../../components/layout/simple/fullpage/FullContainerPage";
import {Button, Card, Col, Icon, Row} from "antd";
import styles from "../auth/login/styles.module.css";
import {Link} from "react-router-dom";

interface IProps {
}

interface IState {
}

class NotFoundLayout extends React.Component<IProps, IState> {
render() {
return (
<FullContainerPage>
<Row type={"flex"} justify={"center"}>
<Col xxl={8} xl={8} md={12} xs={24} className={styles.verticalCenter}>
<Card>
<h3 className={"ant-typography"}>Page not found <Icon type={"robot"}/></h3>
<Link to={window.App.isAuthorized() ? "/home" : "/"}>
<Button type={"primary"}>
{window.App.isAuthorized() ? "Go to home" : "Go to index page"}
</Button>
</Link>
</Card>
</Col>
</Row>
</FullContainerPage>
);
}
}

export default NotFoundLayout;