Skip to content

Commit

Permalink
Merge branch 'main' into migrate-test-suites-to-starknetkit
Browse files Browse the repository at this point in the history
  • Loading branch information
davedumto authored Dec 21, 2024
2 parents 5094125 + a27935c commit 9a801d0
Show file tree
Hide file tree
Showing 97 changed files with 3,312 additions and 910 deletions.
48 changes: 22 additions & 26 deletions frontend/src/App.jsx
Original file line number Diff line number Diff line change
@@ -1,30 +1,29 @@
import React, { useState, useEffect } from 'react';
import { Routes, Route, Navigate, useNavigate } from 'react-router-dom';
import { Routes, Route, useNavigate } from 'react-router-dom';
import './globals.css';
import Header from './components/header/Header';
import Dashboard from 'pages/spotnet/dashboard/Dashboard';
import Footer from './components/Footer/Footer';
import SpotnetApp from 'pages/spotnet/spotnet_app/SpotnetApp';
import Login from 'pages/Login';
import Form from 'pages/forms/Form';
import Header from './components/layout/header/Header';
import Dashboard from './pages/dashboard/Dashboard';
import Footer from './components/layout/footer/Footer';
import SpotnetApp from './pages/spotnet-app/SpotnetApp';
import Form from './pages/form/Form';
import { createPortal } from 'react-dom';
import { logout } from 'services/wallet';
import { getTelegramUserWalletId } from 'services/telegram';
import Documentation from 'pages/spotnet/documentation/Documentation';
import Withdraw from 'pages/vault/withdraw/Withdraw';
import { useWalletStore } from 'stores/useWalletStore';
import { Notifier, notify } from 'components/Notifier/Notifier';
import { useConnectWallet } from 'hooks/useConnectWallet';
import OverviewPage from 'pages/spotnet/overview/Overview';
import { ActionModal } from 'components/ui/ActionModal';
import Stake from 'pages/vault/stake/Stake';
import { TELEGRAM_BOT_LINK } from 'utils/constants';
import { useCheckMobile } from 'hooks/useCheckMobile';
import PositionHistory from 'pages/spotnet/position_history/PositionHistory';

import { logout } from './services/wallet';
import { getTelegramUserWalletId } from './services/telegram';
import Documentation from './pages/documentation/Documentation';
import Withdraw from './pages/withdraw/Withdraw';
import { useWalletStore } from './stores/useWalletStore';
import { Notifier, notify } from './components/layout/notifier/Notifier';
import { useConnectWallet } from './hooks/useConnectWallet';
import OverviewPage from './pages/overview/Overview';
import { ActionModal } from './components/ui/action-modal';
import Stake from './pages/stake/Stake';
import { TELEGRAM_BOT_LINK } from './utils/constants';
import { useCheckMobile } from './hooks/useCheckMobile';
import PositionHistory from './pages/position-history/PositionHistory';
import WithdrawAll from 'pages/spotnet/dashboard/withdraw-all/WithdrawAll';

function App() {
const { walletId, setWalletId, removeWalletId } = useWalletStore();
const { setWalletId, removeWalletId } = useWalletStore();
const [showModal, setShowModal] = useState(false);
const navigate = useNavigate();
const [isMobileRestrictionModalOpen, setisMobileRestrictionModalOpen] = useState(true);
Expand Down Expand Up @@ -98,17 +97,14 @@ function App() {
<main>
<Routes>
<Route index element={<SpotnetApp onConnectWallet={handleConnectWallet} onLogout={handleLogout} />} />
<Route
path="/login"
element={walletId ? <Navigate to="/" /> : <Login onConnectWallet={handleConnectWallet} />}
/>
<Route path="/dashboard" element={<Dashboard telegramId={window?.Telegram?.WebApp?.initData?.user?.id} />} />
<Route path="/withdraw" element={<Withdraw />} />
<Route path="/overview" element={<OverviewPage />} />
<Route path="/form" element={<Form />} />
<Route path="/documentation" element={<Documentation />} />
<Route path="/position-history" element={<PositionHistory />} />
<Route path="/stake" element={<Stake />} />
<Route path="/dashboard/withdraw-all" element={<WithdrawAll />} />
</Routes>
</main>
<Footer />
Expand Down
63 changes: 0 additions & 63 deletions frontend/src/components/BalanceCards.jsx

This file was deleted.

10 changes: 0 additions & 10 deletions frontend/src/components/CardGradients.jsx

This file was deleted.

38 changes: 0 additions & 38 deletions frontend/src/components/Dashboard/DashboardCard.jsx

This file was deleted.

195 changes: 0 additions & 195 deletions frontend/src/components/LendingForm.js

This file was deleted.

15 changes: 0 additions & 15 deletions frontend/src/components/Login.js

This file was deleted.

Loading

0 comments on commit 9a801d0

Please sign in to comment.