import { ReactElement, useContext } from 'react' import { Route, Routes } from 'react-router-dom' import { AccountChequebook } from './pages/account/chequebook/AccountChequebook' import { AccountFeeds } from './pages/account/feeds/AccountFeeds' import { AccountStaking } from './pages/account/staking/AccountStaking' import { AccountStamps } from './pages/account/stamps/AccountStamps' import { AccountWallet } from './pages/account/wallet/AccountWallet' import CreateNewFeed from './pages/feeds/CreateNewFeed' import { FeedSubpage } from './pages/feeds/FeedSubpage' import UpdateFeed from './pages/feeds/UpdateFeed' import { FileManagerPage } from './pages/filemanager' import { Download } from './pages/files/Download' import { Share } from './pages/files/Share' import { Upload } from './pages/files/Upload' import { UploadLander } from './pages/files/UploadLander' import GiftCards from './pages/giftCode' import Info from './pages/info' import PageNotFound from './pages/notFound/PageNotFound' import LightModeRestart from './pages/restart/LightModeRestart' import Settings from './pages/settings' import { CreatePostageStampPage } from './pages/stamps/CreatePostageStampAdvancedPage' import { CreatePostageStampBasicPage } from './pages/stamps/CreatePostageStampStandardPage' import Status from './pages/status' import TopUp from './pages/topUp' import { BankCardTopUpIndex } from './pages/topUp/BankCardTopUpIndex' import { CryptoTopUpIndex } from './pages/topUp/CryptoTopUpIndex' import { GiftCardFund } from './pages/topUp/GiftCardFund' import { GiftCardTopUpIndex } from './pages/topUp/GiftCardTopUpIndex' import { Swap } from './pages/topUp/Swap' import { Context as SettingsContext } from './providers/Settings' export enum ROUTES { INFO = '/', FILES = '/files', FILEMANAGER = '/filemanager', UPLOAD = '/files/upload', UPLOAD_IN_PROGRESS = '/files/upload/workflow', DOWNLOAD = '/files/download', HASH = '/files/hash/:hash', SETTINGS = '/settings', STATUS = '/status', TOP_UP = '/account/wallet/top-up', TOP_UP_CRYPTO = '/account/wallet/top-up/crypto', TOP_UP_CRYPTO_SWAP = '/account/wallet/top-up/crypto/swap', TOP_UP_BANK_CARD = '/account/wallet/top-up/bank-card', TOP_UP_BANK_CARD_SWAP = '/account/wallet/top-up/bank-card/swap', TOP_UP_GIFT_CODE = '/account/wallet/top-up/gift-code', TOP_UP_GIFT_CODE_FUND = '/account/wallet/top-up/gift-code/fund/:privateKeyString', RESTART_LIGHT = '/light-mode-restart', ACCOUNT_WALLET = '/account/wallet', ACCOUNT_CHEQUEBOOK = '/account/chequebook', ACCOUNT_STAMPS = '/account/stamps', ACCOUNT_STAMPS_NEW_STANDARD = '/account/stamps/new', ACCOUNT_STAMPS_NEW_ADVANCED = '/account/stamps/new/advanced', ACCOUNT_FEEDS = '/account/feeds', ACCOUNT_FEEDS_NEW = '/account/feeds/new', ACCOUNT_FEEDS_UPDATE = '/account/feeds/update/:hash', ACCOUNT_FEEDS_VIEW = '/account/feeds/view/:uuid', ACCOUNT_INVITATIONS = '/account/invitations', ACCOUNT_STAKING = '/account/staking', } export const ACCOUNT_TABS = [ ROUTES.ACCOUNT_WALLET, ROUTES.ACCOUNT_CHEQUEBOOK, ROUTES.ACCOUNT_STAMPS, ROUTES.ACCOUNT_FEEDS, ROUTES.ACCOUNT_STAKING, ] const BaseRouter = (): ReactElement => { const { isDesktop } = useContext(SettingsContext) return ( } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> {isDesktop && } />} } /> ) } export default BaseRouter