刘嘉昕 | 07fee5f | 2025-06-09 17:18:47 +0800 | [diff] [blame] | 1 | import React from 'react'; |
| 2 | import { BrowserRouter as Router, Routes, Route } from 'react-router-dom'; |
| 3 | import Home from './pages/Home'; |
| 4 | import AdminPage from './pages/AdminPage'; |
| 5 | import TorrentDetail from './components/torrentdetail'; |
| 6 | import TorrentDetailhelp from './components/torrentdetailhelp'; |
| 7 | import TorrentDetailcomplain from './components/torrentdetailcomplain'; |
| 8 | import TorrentList from './components/torrentlist'; |
| 9 | import UploadTorrent from './components/upload'; |
| 10 | import Navbar from './components/Navbar'; |
| 11 | import TorrentDetailmanage from './pages/managetorrentdetail'; |
| 12 | import RecommendAll from './components/RecommendAll'; |
| 13 | import UserAuth from './pages/UserAuth'; |
| 14 | import 'antd/dist/reset.css'; // Ant Design 默认样式 |
| 15 | import './App.css'; |
| 16 | import MainPage from './pages/MainPage'; |
| 17 | import Friend from './pages/Friend'; |
| 18 | import Community from './pages/Community'; |
| 19 | import UserCenter from './pages/UserCenter111'; |
| 20 | import UploadTorrentFull from './components/upload-full'; |
| 21 | import ShopPage from './pages/ShopPage'; |
| 22 | |
| 23 | // 定义橙色主题(使用 Ant Design 的 orange-6 色值) |
| 24 | const orangeTheme = { |
| 25 | token: { |
| 26 | colorPrimary: '#fa8c16', // orange-6 |
| 27 | borderRadius: 4, // 可选:圆角大小 |
| 28 | }, |
| 29 | }; |
| 30 | |
| 31 | function App() { |
| 32 | return ( |
| 33 | <div className="App"> |
| 34 | {/* <div className="container mx-auto p-4"> */} |
| 35 | <Routes> |
| 36 | {/* <Route path="/" element={<Home />} /> */} |
| 37 | <Route path="/home" element={<MainPage />} /> |
| 38 | <Route path="/admin" element={<AdminPage />} /> |
| 39 | <Route path="/admin/:id" element={<TorrentDetailmanage />} /> |
| 40 | <Route path="/process/:id" element={<TorrentDetailhelp />} /> |
| 41 | <Route path="/complain-process/:id" element={<TorrentDetailcomplain />} /> |
| 42 | <Route path="/torrents" element={<TorrentList />} /> |
| 43 | <Route path="/upload" element={<UploadTorrent />} /> |
| 44 | <Route path="/torrent/:id" element={<TorrentDetail />} /> |
| 45 | <Route path="/recommend" element={<RecommendAll />} /> |
| 46 | <Route path="/" element={<UserAuth />} /> |
| 47 | <Route path="/Community" element={<Community />} /> |
| 48 | <Route path="/friend" element={<Friend />} /> |
| 49 | <Route path="/usercenter" element={<UserCenter />} /> |
| 50 | <Route path="/uploadfull/:requestid" element={<UploadTorrentFull/>}/> |
| 51 | <Route path="/shop" element={<ShopPage />} /> |
| 52 | </Routes> |
| 53 | {/* </div> */} |
| 54 | </div> |
| 55 | ); |
| 56 | } |
| 57 | |
| 58 | export default App; |