Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: enable dashboard #134

Merged
merged 1 commit into from
Sep 20, 2022
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
2 changes: 1 addition & 1 deletion .env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
SASS_PATH=node_modules:src/styles
REACT_APP_MAINNET_SERVICE_URL=https://api-classic.terraswap.io/v2
REACT_APP_MAINNET_SERVICE_V1_URL=https://api-classic.terraswap.io
REACT_APP_MAINNET_DASHBOARD_URL=https://api-classic.terraswap.io/dashboard
REACT_APP_MAINNET_DASHBOARD_URL=https://api-classic.terraswap.io/v2/dashboard
2 changes: 1 addition & 1 deletion .env.development
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ REACT_APP_MAINNET_SERVICE_PROXY_URL=https://api-classic.terraswap.io/v2
REACT_APP_MAINNET_SERVICE_V1_URL=/api/mainnet-v1
REACT_APP_MAINNET_SERVICE_V1_PROXY_URL=https://api-classic.terraswap.io
REACT_APP_MAINNET_DASHBOARD_URL=/api/mainnet/dashboard
REACT_APP_MAINNET_DASHBOARD_PROXY_URL=https://api-classic.terraswap.io/dashboard
REACT_APP_MAINNET_DASHBOARD_PROXY_URL=https://api-classic.terraswap.io/v2/dashboard
6 changes: 1 addition & 5 deletions src/layouts/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -193,11 +193,7 @@ const Sidebar = () => {
<NavLink
to="/"
className={location.pathname?.includes("/pairs") ? "active" : ""}
onClick={(event) => {
event.preventDefault()
close()
}}
style={{ cursor: "not-allowed" }}
onClick={() => close()}
>
Dashboard
</NavLink>
Expand Down
5 changes: 5 additions & 0 deletions src/routes.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
import { Route, Routes, Navigate } from "react-router-dom"

import Dashboard from "./pages/Dashboard"
import PairPage from "./pages/Dashboard/Pair"
import Swap from "./pages/Swap"

export default () => (
<Routes>
<Route index element={<Dashboard />} />
<Route path="/swap" element={<Swap />} />
<Route path="/pairs/:address" element={<PairPage />} />
<Route element={<Navigate to="/" replace />} />
<Route path="/migration" element={<Swap />} />
<Route index element={<Navigate to="/swap" replace />} />
<Route path="*" element={<Navigate to="/swap" replace />} />
Expand Down