Skip to content

Commit

Permalink
feat(ui): Add Wormhole page
Browse files Browse the repository at this point in the history
  • Loading branch information
wormat committed Oct 13, 2022
1 parent a06d25c commit 83a694b
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 0 deletions.
2 changes: 2 additions & 0 deletions apps/ui/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import StakePage from "./pages/StakePage";
import SwapPage from "./pages/SwapPage";
import SwapPageV2 from "./pages/SwapPageV2";
import TosPage from "./pages/TosPage";
import WormholePage from "./pages/WormholePage";

function App(): ReactElement {
return (
Expand Down Expand Up @@ -64,6 +65,7 @@ function App(): ReactElement {
{process.env.REACT_APP_ENABLE_POOL_RESTRUCTURE && (
<Route path="swapV2" element={<SwapPageV2 />} />
)}
<Route path="wormhole" element={<WormholePage />} />
<Route path="collectibles" element={<CollectiblesPage />} />
<Route path="tos" element={<TosPage />} />
<Route path="media" element={<MediaPage />} />
Expand Down
10 changes: 10 additions & 0 deletions apps/ui/src/pages/WormholePage.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
.wormholeForm {
width: 500px;
transition: all 0.5s ease;
}

@media (min-width: 768px) {
.wormholeForm {
min-width: 460px;
}
}
38 changes: 38 additions & 0 deletions apps/ui/src/pages/WormholePage.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
import {
EuiPage,
EuiPageBody,
EuiPageContent,
EuiPageContentBody,
EuiSpacer,
EuiTitle,
} from "@elastic/eui";
import type { ReactElement } from "react";
import { useTranslation } from "react-i18next";

import { WormholeForm } from "../components/WormholeForm";
import { useTitle } from "../hooks";

import "./WormholePage.scss";

const WormholePage = (): ReactElement => {
const { t } = useTranslation();
useTitle(t("nav.wormhole"));

return (
<EuiPage restrictWidth={620}>
<EuiPageBody>
<EuiPageContent verticalPosition="center">
<EuiPageContentBody>
<EuiTitle>
<h2>{"Wormhole"}</h2>
</EuiTitle>
<EuiSpacer />
<WormholeForm />
</EuiPageContentBody>
</EuiPageContent>
</EuiPageBody>
</EuiPage>
);
};

export default WormholePage;

0 comments on commit 83a694b

Please sign in to comment.