refactor: remove electron-related code

This commit is contained in:
codytseng 2024-12-21 23:20:30 +08:00
parent bed8df06e8
commit 2b1e6fe8f5
200 changed files with 2771 additions and 8432 deletions

View file

@ -1,27 +0,0 @@
import { match } from 'path-to-regexp'
import { isValidElement } from 'react'
import FollowingListPage from './pages/secondary/FollowingListPage'
import HomePage from './pages/secondary/HomePage'
import NoteListPage from './pages/secondary/NoteListPage'
import NotePage from './pages/secondary/NotePage'
import NotificationListPage from './pages/secondary/NotificationListPage'
import ProfileListPage from './pages/secondary/ProfileListPage'
import ProfilePage from './pages/secondary/ProfilePage'
import RelaySettingsPage from './pages/secondary/RelaySettingsPage'
const ROUTES = [
{ path: '/', element: <HomePage /> },
{ path: '/notes', element: <NoteListPage /> },
{ path: '/notes/:id', element: <NotePage /> },
{ path: '/users', element: <ProfileListPage /> },
{ path: '/users/:id', element: <ProfilePage /> },
{ path: '/users/:id/following', element: <FollowingListPage /> },
{ path: '/relay-settings', element: <RelaySettingsPage /> },
{ path: '/notifications', element: <NotificationListPage /> }
]
export const routes = ROUTES.map(({ path, element }) => ({
path,
element: isValidElement(element) ? element : null,
matcher: match(path)
}))