import React from 'react'; import { BrowserRouter as Router, Route, Routes } from 'react-router-dom'; import AccountPage from './pages/AccountPage'; import DepositPage from './pages/DepositPage'; import WithdrawPage from './pages/WithdrawPage'; import OrdersPage from './pages/OrdersPage'; import DepositHistoryPage from './pages/DepositHistoryPage'; import WithdrawHistoryPage from './pages/WithdrawHistoryPage'; import TradePage from './pages/TradePage'; import LoginPage from './pages/LoginPage'; import RegisterPage from './pages/RegisterPage'; import ForgotPasswordPage from './pages/ForgotPasswordPage'; import Layout from './components/Layout'; function App() { return ( <Router> <Routes> <Route path="/" element={<Layout />}> <Route path="/account" element={<AccountPage />} /> <Route path="/deposit" element={<DepositPage />} /> <Route path="/withdraw" element={<WithdrawPage />} /> <Route path="/orders" element={<OrdersPage />} /> <Route path="/deposit-history" element={<DepositHistoryPage />} /> <Route path="/withdraw-history" element={<WithdrawHistoryPage />} /> <Route path="/trade" element={<TradePage />} /> <Route path="/login" element={<LoginPage />} /> <Route path="/register" element={<RegisterPage />} /> <Route path="/forgot-password" element={<ForgotPasswordPage />} /> </Route> </Routes> </Router> ); } export default App; - Initial Deployment
Browse files- README.md +7 -5
- index.html +675 -19
README.md
CHANGED
@@ -1,10 +1,12 @@
|
|
1 |
---
|
2 |
-
title:
|
3 |
-
emoji:
|
4 |
-
colorFrom:
|
5 |
-
colorTo:
|
6 |
sdk: static
|
7 |
pinned: false
|
|
|
|
|
8 |
---
|
9 |
|
10 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
1 |
---
|
2 |
+
title: hna
|
3 |
+
emoji: 🐳
|
4 |
+
colorFrom: gray
|
5 |
+
colorTo: pink
|
6 |
sdk: static
|
7 |
pinned: false
|
8 |
+
tags:
|
9 |
+
- deepsite
|
10 |
---
|
11 |
|
12 |
+
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
index.html
CHANGED
@@ -1,19 +1,675 @@
|
|
1 |
-
<!
|
2 |
-
<html>
|
3 |
-
|
4 |
-
|
5 |
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<!DOCTYPE html>
|
2 |
+
<html lang="en">
|
3 |
+
<head>
|
4 |
+
<meta charset="UTF-8">
|
5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6 |
+
<title>TradeBank Pro</title>
|
7 |
+
<script src="https://cdn.tailwindcss.com"></script>
|
8 |
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
9 |
+
<style>
|
10 |
+
/* Custom styles that can't be done with Tailwind */
|
11 |
+
.sidebar {
|
12 |
+
transition: all 0.3s ease;
|
13 |
+
}
|
14 |
+
.sidebar.collapsed {
|
15 |
+
width: 70px;
|
16 |
+
}
|
17 |
+
.sidebar.collapsed .nav-text {
|
18 |
+
display: none;
|
19 |
+
}
|
20 |
+
.sidebar.collapsed .logo-text {
|
21 |
+
display: none;
|
22 |
+
}
|
23 |
+
.sidebar.collapsed .nav-item {
|
24 |
+
justify-content: center;
|
25 |
+
}
|
26 |
+
.main-content {
|
27 |
+
transition: margin-left 0.3s ease;
|
28 |
+
}
|
29 |
+
.main-content.expanded {
|
30 |
+
margin-left: 250px;
|
31 |
+
}
|
32 |
+
.main-content.collapsed {
|
33 |
+
margin-left: 70px;
|
34 |
+
}
|
35 |
+
.chart-container {
|
36 |
+
height: 300px;
|
37 |
+
}
|
38 |
+
@media (max-width: 768px) {
|
39 |
+
.sidebar {
|
40 |
+
position: fixed;
|
41 |
+
z-index: 1000;
|
42 |
+
left: -250px;
|
43 |
+
}
|
44 |
+
.sidebar.active {
|
45 |
+
left: 0;
|
46 |
+
}
|
47 |
+
.main-content {
|
48 |
+
margin-left: 0 !important;
|
49 |
+
}
|
50 |
+
.mobile-menu-btn {
|
51 |
+
display: block;
|
52 |
+
}
|
53 |
+
}
|
54 |
+
</style>
|
55 |
+
</head>
|
56 |
+
<body class="bg-gray-100 font-sans">
|
57 |
+
<div class="flex h-screen overflow-hidden">
|
58 |
+
<!-- Sidebar -->
|
59 |
+
<div id="sidebar" class="sidebar bg-gray-800 text-white w-64 h-full fixed">
|
60 |
+
<div class="p-4 flex items-center">
|
61 |
+
<i class="fas fa-chart-line text-blue-400 text-2xl mr-3"></i>
|
62 |
+
<span class="logo-text text-xl font-bold">TradeBank Pro</span>
|
63 |
+
</div>
|
64 |
+
<nav class="mt-6">
|
65 |
+
<div class="px-4 py-2">
|
66 |
+
<div class="text-gray-400 uppercase text-xs font-semibold tracking-wider mb-4">Main</div>
|
67 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1 active" data-page="account">
|
68 |
+
<i class="fas fa-user-circle mr-3"></i>
|
69 |
+
<span class="nav-text">Account</span>
|
70 |
+
</a>
|
71 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="trade">
|
72 |
+
<i class="fas fa-chart-bar mr-3"></i>
|
73 |
+
<span class="nav-text">Trade</span>
|
74 |
+
</a>
|
75 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="orders">
|
76 |
+
<i class="fas fa-list-alt mr-3"></i>
|
77 |
+
<span class="nav-text">Orders</span>
|
78 |
+
</a>
|
79 |
+
</div>
|
80 |
+
<div class="px-4 py-2">
|
81 |
+
<div class="text-gray-400 uppercase text-xs font-semibold tracking-wider mb-4">Transactions</div>
|
82 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="deposit">
|
83 |
+
<i class="fas fa-plus-circle mr-3 text-green-400"></i>
|
84 |
+
<span class="nav-text">Deposit</span>
|
85 |
+
</a>
|
86 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="withdraw">
|
87 |
+
<i class="fas fa-minus-circle mr-3 text-red-400"></i>
|
88 |
+
<span class="nav-text">Withdraw</span>
|
89 |
+
</a>
|
90 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="deposit-history">
|
91 |
+
<i class="fas fa-history mr-3 text-blue-400"></i>
|
92 |
+
<span class="nav-text">Deposit History</span>
|
93 |
+
</a>
|
94 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="withdraw-history">
|
95 |
+
<i class="fas fa-history mr-3 text-purple-400"></i>
|
96 |
+
<span class="nav-text">Withdraw History</span>
|
97 |
+
</a>
|
98 |
+
</div>
|
99 |
+
<div class="px-4 py-2 mt-8">
|
100 |
+
<div class="text-gray-400 uppercase text-xs font-semibold tracking-wider mb-4">Account</div>
|
101 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="login">
|
102 |
+
<i class="fas fa-sign-in-alt mr-3"></i>
|
103 |
+
<span class="nav-text">Login</span>
|
104 |
+
</a>
|
105 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="register">
|
106 |
+
<i class="fas fa-user-plus mr-3"></i>
|
107 |
+
<span class="nav-text">Register</span>
|
108 |
+
</a>
|
109 |
+
<a href="#" class="nav-item flex items-center px-4 py-3 text-gray-300 hover:bg-gray-700 rounded-lg mb-1" data-page="forgot-password">
|
110 |
+
<i class="fas fa-key mr-3"></i>
|
111 |
+
<span class="nav-text">Forgot Password</span>
|
112 |
+
</a>
|
113 |
+
</div>
|
114 |
+
</nav>
|
115 |
+
<div class="absolute bottom-0 w-full p-4">
|
116 |
+
<button id="toggleSidebar" class="w-full bg-gray-700 hover:bg-gray-600 text-white py-2 px-4 rounded-lg flex items-center justify-center">
|
117 |
+
<i class="fas fa-chevron-left mr-2"></i>
|
118 |
+
<span class="nav-text">Collapse</span>
|
119 |
+
</button>
|
120 |
+
</div>
|
121 |
+
</div>
|
122 |
+
|
123 |
+
<!-- Main Content -->
|
124 |
+
<div id="mainContent" class="main-content flex-1 flex flex-col overflow-hidden expanded">
|
125 |
+
<!-- Top Navigation -->
|
126 |
+
<header class="bg-white shadow-sm z-10">
|
127 |
+
<div class="flex items-center justify-between px-6 py-4">
|
128 |
+
<div class="flex items-center">
|
129 |
+
<button id="mobileMenuBtn" class="mobile-menu-btn mr-4 text-gray-500 focus:outline-none hidden">
|
130 |
+
<i class="fas fa-bars text-xl"></i>
|
131 |
+
</button>
|
132 |
+
<h1 class="text-xl font-semibold text-gray-800" id="pageTitle">Account Overview</h1>
|
133 |
+
</div>
|
134 |
+
<div class="flex items-center space-x-4">
|
135 |
+
<div class="relative">
|
136 |
+
<button class="text-gray-500 focus:outline-none">
|
137 |
+
<i class="fas fa-bell text-xl"></i>
|
138 |
+
<span class="absolute top-0 right-0 h-2 w-2 rounded-full bg-red-500"></span>
|
139 |
+
</button>
|
140 |
+
</div>
|
141 |
+
<div class="relative">
|
142 |
+
<button class="flex items-center focus:outline-none">
|
143 |
+
<img src="https://randomuser.me/api/portraits/men/32.jpg" alt="User" class="h-8 w-8 rounded-full">
|
144 |
+
<span class="ml-2 text-gray-700">John Doe</span>
|
145 |
+
</button>
|
146 |
+
</div>
|
147 |
+
</div>
|
148 |
+
</div>
|
149 |
+
</header>
|
150 |
+
|
151 |
+
<!-- Page Content -->
|
152 |
+
<main class="flex-1 overflow-y-auto p-6 bg-gray-50">
|
153 |
+
<!-- Dynamic content will be loaded here -->
|
154 |
+
<div id="pageContent">
|
155 |
+
<!-- Default Account Page Content -->
|
156 |
+
<div class="grid grid-cols-1 md:grid-cols-3 gap-6">
|
157 |
+
<!-- Balance Card -->
|
158 |
+
<div class="bg-white rounded-lg shadow p-6">
|
159 |
+
<div class="flex items-center justify-between">
|
160 |
+
<div>
|
161 |
+
<p class="text-gray-500">Total Balance</p>
|
162 |
+
<h2 class="text-3xl font-bold text-gray-800">$12,456.78</h2>
|
163 |
+
</div>
|
164 |
+
<div class="bg-blue-100 p-3 rounded-full">
|
165 |
+
<i class="fas fa-wallet text-blue-500 text-xl"></i>
|
166 |
+
</div>
|
167 |
+
</div>
|
168 |
+
<div class="mt-6">
|
169 |
+
<div class="flex justify-between mb-2">
|
170 |
+
<span class="text-gray-500">Available</span>
|
171 |
+
<span class="font-medium">$10,234.56</span>
|
172 |
+
</div>
|
173 |
+
<div class="flex justify-between mb-2">
|
174 |
+
<span class="text-gray-500">In Orders</span>
|
175 |
+
<span class="font-medium">$2,222.22</span>
|
176 |
+
</div>
|
177 |
+
</div>
|
178 |
+
</div>
|
179 |
+
|
180 |
+
<!-- Deposit Card -->
|
181 |
+
<div class="bg-white rounded-lg shadow p-6">
|
182 |
+
<div class="flex items-center justify-between">
|
183 |
+
<div>
|
184 |
+
<p class="text-gray-500">Total Deposits</p>
|
185 |
+
<h2 class="text-3xl font-bold text-gray-800">$15,000.00</h2>
|
186 |
+
</div>
|
187 |
+
<div class="bg-green-100 p-3 rounded-full">
|
188 |
+
<i class="fas fa-plus-circle text-green-500 text-xl"></i>
|
189 |
+
</div>
|
190 |
+
</div>
|
191 |
+
<div class="mt-6">
|
192 |
+
<button class="w-full bg-green-500 hover:bg-green-600 text-white py-2 px-4 rounded-lg">
|
193 |
+
Deposit Funds
|
194 |
+
</button>
|
195 |
+
</div>
|
196 |
+
</div>
|
197 |
+
|
198 |
+
<!-- Withdraw Card -->
|
199 |
+
<div class="bg-white rounded-lg shadow p-6">
|
200 |
+
<div class="flex items-center justify-between">
|
201 |
+
<div>
|
202 |
+
<p class="text-gray-500">Total Withdrawals</p>
|
203 |
+
<h2 class="text-3xl font-bold text-gray-800">$2,543.22</h2>
|
204 |
+
</div>
|
205 |
+
<div class="bg-red-100 p-3 rounded-full">
|
206 |
+
<i class="fas fa-minus-circle text-red-500 text-xl"></i>
|
207 |
+
</div>
|
208 |
+
</div>
|
209 |
+
<div class="mt-6">
|
210 |
+
<button class="w-full bg-red-500 hover:bg-red-600 text-white py-2 px-4 rounded-lg">
|
211 |
+
Withdraw Funds
|
212 |
+
</button>
|
213 |
+
</div>
|
214 |
+
</div>
|
215 |
+
</div>
|
216 |
+
|
217 |
+
<!-- Recent Activity -->
|
218 |
+
<div class="mt-8 bg-white rounded-lg shadow overflow-hidden">
|
219 |
+
<div class="px-6 py-4 border-b border-gray-200">
|
220 |
+
<h3 class="text-lg font-medium text-gray-900">Recent Activity</h3>
|
221 |
+
</div>
|
222 |
+
<div class="divide-y divide-gray-200">
|
223 |
+
<div class="px-6 py-4 flex items-center">
|
224 |
+
<div class="bg-blue-100 p-3 rounded-full mr-4">
|
225 |
+
<i class="fas fa-exchange-alt text-blue-500"></i>
|
226 |
+
</div>
|
227 |
+
<div class="flex-1">
|
228 |
+
<p class="text-sm font-medium text-gray-900">Trade Executed</p>
|
229 |
+
<p class="text-sm text-gray-500">BTC/USD - Buy 0.05 BTC at $42,156.78</p>
|
230 |
+
</div>
|
231 |
+
<div class="text-right">
|
232 |
+
<p class="text-sm font-medium text-green-500">+$2,107.84</p>
|
233 |
+
<p class="text-xs text-gray-500">2 hours ago</p>
|
234 |
+
</div>
|
235 |
+
</div>
|
236 |
+
<div class="px-6 py-4 flex items-center">
|
237 |
+
<div class="bg-green-100 p-3 rounded-full mr-4">
|
238 |
+
<i class="fas fa-plus-circle text-green-500"></i>
|
239 |
+
</div>
|
240 |
+
<div class="flex-1">
|
241 |
+
<p class="text-sm font-medium text-gray-900">Deposit Completed</p>
|
242 |
+
<p class="text-sm text-gray-500">Bank Transfer - Reference: TRX123456</p>
|
243 |
+
</div>
|
244 |
+
<div class="text-right">
|
245 |
+
<p class="text-sm font-medium text-green-500">+$5,000.00</p>
|
246 |
+
<p class="text-xs text-gray-500">1 day ago</p>
|
247 |
+
</div>
|
248 |
+
</div>
|
249 |
+
<div class="px-6 py-4 flex items-center">
|
250 |
+
<div class="bg-red-100 p-3 rounded-full mr-4">
|
251 |
+
<i class="fas fa-minus-circle text-red-500"></i>
|
252 |
+
</div>
|
253 |
+
<div class="flex-1">
|
254 |
+
<p class="text-sm font-medium text-gray-900">Withdrawal Request</p>
|
255 |
+
<p class="text-sm text-gray-500">To Bank Account ****4567 - Pending</p>
|
256 |
+
</div>
|
257 |
+
<div class="text-right">
|
258 |
+
<p class="text-sm font-medium text-red-500">-$1,000.00</p>
|
259 |
+
<p class="text-xs text-gray-500">2 days ago</p>
|
260 |
+
</div>
|
261 |
+
</div>
|
262 |
+
</div>
|
263 |
+
</div>
|
264 |
+
</div>
|
265 |
+
</main>
|
266 |
+
</div>
|
267 |
+
</div>
|
268 |
+
|
269 |
+
<script>
|
270 |
+
// DOM Elements
|
271 |
+
const sidebar = document.getElementById('sidebar');
|
272 |
+
const mainContent = document.getElementById('mainContent');
|
273 |
+
const toggleSidebarBtn = document.getElementById('toggleSidebar');
|
274 |
+
const mobileMenuBtn = document.getElementById('mobileMenuBtn');
|
275 |
+
const navItems = document.querySelectorAll('.nav-item');
|
276 |
+
const pageTitle = document.getElementById('pageTitle');
|
277 |
+
const pageContent = document.getElementById('pageContent');
|
278 |
+
|
279 |
+
// Toggle sidebar
|
280 |
+
let isCollapsed = false;
|
281 |
+
let isMobileMenuOpen = false;
|
282 |
+
|
283 |
+
toggleSidebarBtn.addEventListener('click', () => {
|
284 |
+
isCollapsed = !isCollapsed;
|
285 |
+
|
286 |
+
if (isCollapsed) {
|
287 |
+
sidebar.classList.add('collapsed');
|
288 |
+
mainContent.classList.remove('expanded');
|
289 |
+
mainContent.classList.add('collapsed');
|
290 |
+
toggleSidebarBtn.innerHTML = '<i class="fas fa-chevron-right mr-2"></i><span class="nav-text">Expand</span>';
|
291 |
+
} else {
|
292 |
+
sidebar.classList.remove('collapsed');
|
293 |
+
mainContent.classList.remove('collapsed');
|
294 |
+
mainContent.classList.add('expanded');
|
295 |
+
toggleSidebarBtn.innerHTML = '<i class="fas fa-chevron-left mr-2"></i><span class="nav-text">Collapse</span>';
|
296 |
+
}
|
297 |
+
});
|
298 |
+
|
299 |
+
// Mobile menu toggle
|
300 |
+
mobileMenuBtn.addEventListener('click', () => {
|
301 |
+
isMobileMenuOpen = !isMobileMenuOpen;
|
302 |
+
if (isMobileMenuOpen) {
|
303 |
+
sidebar.classList.add('active');
|
304 |
+
} else {
|
305 |
+
sidebar.classList.remove('active');
|
306 |
+
}
|
307 |
+
});
|
308 |
+
|
309 |
+
// Page navigation
|
310 |
+
navItems.forEach(item => {
|
311 |
+
item.addEventListener('click', (e) => {
|
312 |
+
e.preventDefault();
|
313 |
+
const page = item.getAttribute('data-page');
|
314 |
+
|
315 |
+
// Update active state
|
316 |
+
navItems.forEach(navItem => navItem.classList.remove('active'));
|
317 |
+
item.classList.add('active');
|
318 |
+
|
319 |
+
// Update page title
|
320 |
+
const pageTitles = {
|
321 |
+
'account': 'Account Overview',
|
322 |
+
'trade': 'Trade Platform',
|
323 |
+
'orders': 'Your Orders',
|
324 |
+
'deposit': 'Deposit Funds',
|
325 |
+
'withdraw': 'Withdraw Funds',
|
326 |
+
'deposit-history': 'Deposit History',
|
327 |
+
'withdraw-history': 'Withdrawal History',
|
328 |
+
'login': 'Login',
|
329 |
+
'register': 'Register',
|
330 |
+
'forgot-password': 'Forgot Password'
|
331 |
+
};
|
332 |
+
pageTitle.textContent = pageTitles[page];
|
333 |
+
|
334 |
+
// Load page content (simulated)
|
335 |
+
loadPageContent(page);
|
336 |
+
|
337 |
+
// Close mobile menu if open
|
338 |
+
if (isMobileMenuOpen) {
|
339 |
+
sidebar.classList.remove('active');
|
340 |
+
isMobileMenuOpen = false;
|
341 |
+
}
|
342 |
+
});
|
343 |
+
});
|
344 |
+
|
345 |
+
// Simulated page content loading
|
346 |
+
function loadPageContent(page) {
|
347 |
+
// In a real app, this would be an AJAX call or similar
|
348 |
+
let content = '';
|
349 |
+
|
350 |
+
switch(page) {
|
351 |
+
case 'account':
|
352 |
+
content = `
|
353 |
+
<div class="grid grid-cols-1 md:grid-cols-3 gap-6">
|
354 |
+
<!-- Balance Card -->
|
355 |
+
<div class="bg-white rounded-lg shadow p-6">
|
356 |
+
<div class="flex items-center justify-between">
|
357 |
+
<div>
|
358 |
+
<p class="text-gray-500">Total Balance</p>
|
359 |
+
<h2 class="text-3xl font-bold text-gray-800">$12,456.78</h2>
|
360 |
+
</div>
|
361 |
+
<div class="bg-blue-100 p-3 rounded-full">
|
362 |
+
<i class="fas fa-wallet text-blue-500 text-xl"></i>
|
363 |
+
</div>
|
364 |
+
</div>
|
365 |
+
<div class="mt-6">
|
366 |
+
<div class="flex justify-between mb-2">
|
367 |
+
<span class="text-gray-500">Available</span>
|
368 |
+
<span class="font-medium">$10,234.56</span>
|
369 |
+
</div>
|
370 |
+
<div class="flex justify-between mb-2">
|
371 |
+
<span class="text-gray-500">In Orders</span>
|
372 |
+
<span class="font-medium">$2,222.22</span>
|
373 |
+
</div>
|
374 |
+
</div>
|
375 |
+
</div>
|
376 |
+
|
377 |
+
<!-- Deposit Card -->
|
378 |
+
<div class="bg-white rounded-lg shadow p-6">
|
379 |
+
<div class="flex items-center justify-between">
|
380 |
+
<div>
|
381 |
+
<p class="text-gray-500">Total Deposits</p>
|
382 |
+
<h2 class="text-3xl font-bold text-gray-800">$15,000.00</h2>
|
383 |
+
</div>
|
384 |
+
<div class="bg-green-100 p-3 rounded-full">
|
385 |
+
<i class="fas fa-plus-circle text-green-500 text-xl"></i>
|
386 |
+
</div>
|
387 |
+
</div>
|
388 |
+
<div class="mt-6">
|
389 |
+
<button class="w-full bg-green-500 hover:bg-green-600 text-white py-2 px-4 rounded-lg">
|
390 |
+
Deposit Funds
|
391 |
+
</button>
|
392 |
+
</div>
|
393 |
+
</div>
|
394 |
+
|
395 |
+
<!-- Withdraw Card -->
|
396 |
+
<div class="bg-white rounded-lg shadow p-6">
|
397 |
+
<div class="flex items-center justify-between">
|
398 |
+
<div>
|
399 |
+
<p class="text-gray-500">Total Withdrawals</p>
|
400 |
+
<h2 class="text-3xl font-bold text-gray-800">$2,543.22</h2>
|
401 |
+
</div>
|
402 |
+
<div class="bg-red-100 p-3 rounded-full">
|
403 |
+
<i class="fas fa-minus-circle text-red-500 text-xl"></i>
|
404 |
+
</div>
|
405 |
+
</div>
|
406 |
+
<div class="mt-6">
|
407 |
+
<button class="w-full bg-red-500 hover:bg-red-600 text-white py-2 px-4 rounded-lg">
|
408 |
+
Withdraw Funds
|
409 |
+
</button>
|
410 |
+
</div>
|
411 |
+
</div>
|
412 |
+
</div>
|
413 |
+
|
414 |
+
<!-- Recent Activity -->
|
415 |
+
<div class="mt-8 bg-white rounded-lg shadow overflow-hidden">
|
416 |
+
<div class="px-6 py-4 border-b border-gray-200">
|
417 |
+
<h3 class="text-lg font-medium text-gray-900">Recent Activity</h3>
|
418 |
+
</div>
|
419 |
+
<div class="divide-y divide-gray-200">
|
420 |
+
<div class="px-6 py-4 flex items-center">
|
421 |
+
<div class="bg-blue-100 p-3 rounded-full mr-4">
|
422 |
+
<i class="fas fa-exchange-alt text-blue-500"></i>
|
423 |
+
</div>
|
424 |
+
<div class="flex-1">
|
425 |
+
<p class="text-sm font-medium text-gray-900">Trade Executed</p>
|
426 |
+
<p class="text-sm text-gray-500">BTC/USD - Buy 0.05 BTC at $42,156.78</p>
|
427 |
+
</div>
|
428 |
+
<div class="text-right">
|
429 |
+
<p class="text-sm font-medium text-green-500">+$2,107.84</p>
|
430 |
+
<p class="text-xs text-gray-500">2 hours ago</p>
|
431 |
+
</div>
|
432 |
+
</div>
|
433 |
+
<div class="px-6 py-4 flex items-center">
|
434 |
+
<div class="bg-green-100 p-3 rounded-full mr-4">
|
435 |
+
<i class="fas fa-plus-circle text-green-500"></i>
|
436 |
+
</div>
|
437 |
+
<div class="flex-1">
|
438 |
+
<p class="text-sm font-medium text-gray-900">Deposit Completed</p>
|
439 |
+
<p class="text-sm text-gray-500">Bank Transfer - Reference: TRX123456</p>
|
440 |
+
</div>
|
441 |
+
<div class="text-right">
|
442 |
+
<p class="text-sm font-medium text-green-500">+$5,000.00</p>
|
443 |
+
<p class="text-xs text-gray-500">1 day ago</p>
|
444 |
+
</div>
|
445 |
+
</div>
|
446 |
+
<div class="px-6 py-4 flex items-center">
|
447 |
+
<div class="bg-red-100 p-3 rounded-full mr-4">
|
448 |
+
<i class="fas fa-minus-circle text-red-500"></i>
|
449 |
+
</div>
|
450 |
+
<div class="flex-1">
|
451 |
+
<p class="text-sm font-medium text-gray-900">Withdrawal Request</p>
|
452 |
+
<p class="text-sm text-gray-500">To Bank Account ****4567 - Pending</p>
|
453 |
+
</div>
|
454 |
+
<div class="text-right">
|
455 |
+
<p class="text-sm font-medium text-red-500">-$1,000.00</p>
|
456 |
+
<p class="text-xs text-gray-500">2 days ago</p>
|
457 |
+
</div>
|
458 |
+
</div>
|
459 |
+
</div>
|
460 |
+
</div>
|
461 |
+
`;
|
462 |
+
break;
|
463 |
+
|
464 |
+
case 'trade':
|
465 |
+
content = `
|
466 |
+
<div class="grid grid-cols-1 lg:grid-cols-4 gap-6">
|
467 |
+
<div class="lg:col-span-3 bg-white rounded-lg shadow p-6">
|
468 |
+
<div class="flex justify-between items-center mb-6">
|
469 |
+
<div>
|
470 |
+
<h2 class="text-xl font-bold">BTC/USD</h2>
|
471 |
+
<p class="text-gray-500">Bitcoin / US Dollar</p>
|
472 |
+
</div>
|
473 |
+
<div class="text-right">
|
474 |
+
<p class="text-2xl font-bold">$42,156.78</p>
|
475 |
+
<p class="text-green-500">+2.45%</p>
|
476 |
+
</div>
|
477 |
+
</div>
|
478 |
+
|
479 |
+
<div class="chart-container bg-gray-100 rounded-lg mb-6">
|
480 |
+
<!-- Chart placeholder -->
|
481 |
+
<div class="flex items-center justify-center h-full text-gray-400">
|
482 |
+
<i class="fas fa-chart-line text-4xl mr-2"></i>
|
483 |
+
<span>Price Chart</span>
|
484 |
+
</div>
|
485 |
+
</div>
|
486 |
+
|
487 |
+
<div class="grid grid-cols-1 md:grid-cols-2 gap-4">
|
488 |
+
<div>
|
489 |
+
<h3 class="font-medium mb-2">Buy BTC</h3>
|
490 |
+
<div class="mb-4">
|
491 |
+
<label class="block text-gray-700 mb-2">Amount (USD)</label>
|
492 |
+
<input type="number" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="0.00">
|
493 |
+
</div>
|
494 |
+
<div class="mb-4">
|
495 |
+
<label class="block text-gray-700 mb-2">Price (USD)</label>
|
496 |
+
<input type="number" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="0.00">
|
497 |
+
</div>
|
498 |
+
<button class="w-full bg-green-500 hover:bg-green-600 text-white py-3 px-4 rounded-lg font-medium">
|
499 |
+
Buy BTC
|
500 |
+
</button>
|
501 |
+
</div>
|
502 |
+
|
503 |
+
<div>
|
504 |
+
<h3 class="font-medium mb-2">Sell BTC</h3>
|
505 |
+
<div class="mb-4">
|
506 |
+
<label class="block text-gray-700 mb-2">Amount (BTC)</label>
|
507 |
+
<input type="number" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="0.000000">
|
508 |
+
</div>
|
509 |
+
<div class="mb-4">
|
510 |
+
<label class="block text-gray-700 mb-2">Price (USD)</label>
|
511 |
+
<input type="number" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="0.00">
|
512 |
+
</div>
|
513 |
+
<button class="w-full bg-red-500 hover:bg-red-600 text-white py-3 px-4 rounded-lg font-medium">
|
514 |
+
Sell BTC
|
515 |
+
</button>
|
516 |
+
</div>
|
517 |
+
</div>
|
518 |
+
</div>
|
519 |
+
|
520 |
+
<div class="bg-white rounded-lg shadow p-6">
|
521 |
+
<h3 class="font-medium mb-4">Order Book</h3>
|
522 |
+
<div class="mb-6">
|
523 |
+
<h4 class="text-sm font-medium text-red-500 mb-2">Sell Orders</h4>
|
524 |
+
<div class="space-y-2">
|
525 |
+
<div class="flex justify-between text-sm">
|
526 |
+
<span>42,200.00</span>
|
527 |
+
<span>0.4521 BTC</span>
|
528 |
+
</div>
|
529 |
+
<div class="flex justify-between text-sm">
|
530 |
+
<span>42,180.50</span>
|
531 |
+
<span>1.2456 BTC</span>
|
532 |
+
</div>
|
533 |
+
<div class="flex justify-between text-sm">
|
534 |
+
<span>42,175.25</span>
|
535 |
+
<span>0.7842 BTC</span>
|
536 |
+
</div>
|
537 |
+
</div>
|
538 |
+
</div>
|
539 |
+
|
540 |
+
<div class="mb-6">
|
541 |
+
<h4 class="text-sm font-medium text-green-500 mb-2">Buy Orders</h4>
|
542 |
+
<div class="space-y-2">
|
543 |
+
<div class="flex justify-between text-sm">
|
544 |
+
<span>42,150.00</span>
|
545 |
+
<span>0.7845 BTC</span>
|
546 |
+
</div>
|
547 |
+
<div class="flex justify-between text-sm">
|
548 |
+
<span>42,145.75</span>
|
549 |
+
<span>1.4562 BTC</span>
|
550 |
+
</div>
|
551 |
+
<div class="flex justify-between text-sm">
|
552 |
+
<span>42,140.00</span>
|
553 |
+
<span>0.4523 BTC</span>
|
554 |
+
</div>
|
555 |
+
</div>
|
556 |
+
</div>
|
557 |
+
|
558 |
+
<h3 class="font-medium mb-4">Market Trades</h3>
|
559 |
+
<div class="space-y-2">
|
560 |
+
<div class="flex justify-between text-sm">
|
561 |
+
<span class="text-green-500">42,156.78</span>
|
562 |
+
<span>0.05 BTC</span>
|
563 |
+
<span class="text-gray-500">2 min ago</span>
|
564 |
+
</div>
|
565 |
+
<div class="flex justify-between text-sm">
|
566 |
+
<span class="text-red-500">42,155.25</span>
|
567 |
+
<span>0.12 BTC</span>
|
568 |
+
<span class="text-gray-500">5 min ago</span>
|
569 |
+
</div>
|
570 |
+
<div class="flex justify-between text-sm">
|
571 |
+
<span class="text-green-500">42,152.00</span>
|
572 |
+
<span>0.08 BTC</span>
|
573 |
+
<span class="text-gray-500">12 min ago</span>
|
574 |
+
</div>
|
575 |
+
</div>
|
576 |
+
</div>
|
577 |
+
</div>
|
578 |
+
`;
|
579 |
+
break;
|
580 |
+
|
581 |
+
case 'deposit':
|
582 |
+
content = `
|
583 |
+
<div class="max-w-2xl mx-auto bg-white rounded-lg shadow p-6">
|
584 |
+
<h2 class="text-2xl font-bold mb-6">Deposit Funds</h2>
|
585 |
+
|
586 |
+
<div class="mb-8">
|
587 |
+
<h3 class="font-medium mb-4">Select Deposit Method</h3>
|
588 |
+
<div class="grid grid-cols-1 md:grid-cols-3 gap-4">
|
589 |
+
<button class="border-2 border-blue-500 rounded-lg p-4 flex flex-col items-center">
|
590 |
+
<i class="fas fa-university text-3xl text-blue-500 mb-2"></i>
|
591 |
+
<span>Bank Transfer</span>
|
592 |
+
</button>
|
593 |
+
<button class="border rounded-lg p-4 flex flex-col items-center hover:border-blue-500">
|
594 |
+
<i class="fab fa-cc-visa text-3xl text-blue-500 mb-2"></i>
|
595 |
+
<span>Credit Card</span>
|
596 |
+
</button>
|
597 |
+
<button class="border rounded-lg p-4 flex flex-col items-center hover:border-blue-500">
|
598 |
+
<i class="fab fa-paypal text-3xl text-blue-500 mb-2"></i>
|
599 |
+
<span>PayPal</span>
|
600 |
+
</button>
|
601 |
+
</div>
|
602 |
+
</div>
|
603 |
+
|
604 |
+
<div class="mb-6">
|
605 |
+
<label class="block text-gray-700 mb-2">Amount (USD)</label>
|
606 |
+
<input type="number" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="0.00">
|
607 |
+
</div>
|
608 |
+
|
609 |
+
<div class="mb-6">
|
610 |
+
<label class="block text-gray-700 mb-2">Payment Details</label>
|
611 |
+
<div class="bg-gray-100 p-4 rounded-lg">
|
612 |
+
<p class="text-sm text-gray-600">Bank Name: TradeBank Pro</p>
|
613 |
+
<p class="text-sm text-gray-600">Account Number: 1234567890</p>
|
614 |
+
<p class="text-sm text-gray-600">Routing Number: 987654321</p>
|
615 |
+
<p class="text-sm text-gray-600">Reference: Your User ID</p>
|
616 |
+
</div>
|
617 |
+
</div>
|
618 |
+
|
619 |
+
<button class="w-full bg-blue-500 hover:bg-blue-600 text-white py-3 px-4 rounded-lg font-medium">
|
620 |
+
Confirm Deposit
|
621 |
+
</button>
|
622 |
+
</div>
|
623 |
+
`;
|
624 |
+
break;
|
625 |
+
|
626 |
+
case 'login':
|
627 |
+
content = `
|
628 |
+
<div class="max-w-md mx-auto bg-white rounded-lg shadow p-8">
|
629 |
+
<div class="text-center mb-8">
|
630 |
+
<i class="fas fa-chart-line text-blue-500 text-5xl mb-4"></i>
|
631 |
+
<h2 class="text-2xl font-bold">Welcome Back</h2>
|
632 |
+
<p class="text-gray-500">Sign in to your account</p>
|
633 |
+
</div>
|
634 |
+
|
635 |
+
<form>
|
636 |
+
<div class="mb-4">
|
637 |
+
<label class="block text-gray-700 mb-2">Email Address</label>
|
638 |
+
<input type="email" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="[email protected]">
|
639 |
+
</div>
|
640 |
+
|
641 |
+
<div class="mb-6">
|
642 |
+
<label class="block text-gray-700 mb-2">Password</label>
|
643 |
+
<input type="password" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="••••••••">
|
644 |
+
</div>
|
645 |
+
|
646 |
+
<div class="flex items-center justify-between mb-6">
|
647 |
+
<div class="flex items-center">
|
648 |
+
<input type="checkbox" id="remember" class="mr-2">
|
649 |
+
<label for="remember" class="text-gray-700">Remember me</label>
|
650 |
+
</div>
|
651 |
+
<a href="#" class="text-blue-500 hover:underline">Forgot password?</a>
|
652 |
+
</div>
|
653 |
+
|
654 |
+
<button class="w-full bg-blue-500 hover:bg-blue-600 text-white py-3 px-4 rounded-lg font-medium mb-4">
|
655 |
+
Sign In
|
656 |
+
</button>
|
657 |
+
|
658 |
+
<div class="text-center">
|
659 |
+
<p class="text-gray-500">Don't have an account? <a href="#" class="text-blue-500 hover:underline">Sign up</a></p>
|
660 |
+
</div>
|
661 |
+
</form>
|
662 |
+
</div>
|
663 |
+
`;
|
664 |
+
break;
|
665 |
+
|
666 |
+
// Add other page templates here...
|
667 |
+
default:
|
668 |
+
content = `<div class="text-center py-12"><p>Page content for ${page} would be loaded here.</p></div>`;
|
669 |
+
}
|
670 |
+
|
671 |
+
pageContent.innerHTML = content;
|
672 |
+
}
|
673 |
+
</script>
|
674 |
+
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=TDN-M/hna" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
|
675 |
+
</html>
|