Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions client/src/app/components/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,16 @@ import { SIDEBAR_WIDTH } from '../../shared/components/organisms/sidebar/constan
import { Routes } from 'react-router-dom';
import getRoutesV1 from '../routes/auth-routes/v1';

export const LoginLazyComponent = lazy(
() => import('../../modules/user-auth-form/v1')
);
export const LoginLazyComponent = lazy(() => import('../../modules/auth/v1'));
export const HomePageLazyComponent = lazy(
() => import('../../modules/home/v1')
);
export const ChatsPageLazyComponent = lazy(
() => import('../../modules/chats/v1')
);
export const CodePageLazyComponent = lazy(
() => import('../../modules/code/v1')
);
export const SettingsPageLazyComponent = lazy(
() => import('../../modules/settings/v1')
);
Expand Down
20 changes: 20 additions & 0 deletions client/src/app/routes/auth-routes/v1/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ import { LOADING } from '../../constants';
import Loader from '../../../../shared/components/molecules/loader';
import {
HomePageLazyComponent,
ChatsPageLazyComponent,
SettingsPageLazyComponent,
CodePageLazyComponent,
} from '../../../components';

export default function getRoutesV1() {
Expand All @@ -19,6 +21,24 @@ export default function getRoutesV1() {
</Suspense>
}
/>,
<Route
key={`${ROUTES_V1.CHATS}/*`}
path={`${ROUTES_V1.CHATS}/*`}
element={
<Suspense fallback={<Loader size={32} secondary={LOADING} />}>
<ChatsPageLazyComponent />
</Suspense>
}
/>,
<Route
key={`${ROUTES_V1.CODE}/*`}
path={`${ROUTES_V1.CODE}/*`}
element={
<Suspense fallback={<Loader size={32} secondary={LOADING} />}>
<CodePageLazyComponent />
</Suspense>
}
/>,
<Route
key={`${ROUTES_V1.SETTINGS}/*`}
path={`${ROUTES_V1.SETTINGS}/*`}
Expand Down
5 changes: 5 additions & 0 deletions client/src/app/routes/constants/routes.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
export enum ROUTES_PAGE_V1 {
HOME = 'home',
CHATS = 'chats',
CODE = 'code',
SETTINGS = 'settings',
}

export enum ROUTES_V1 {
HOME = '/v1/home',
CHATS = '/v1/chats',
CODE = '/v1/code',
SETTINGS = '/v1/settings',
}

Expand All @@ -16,6 +20,7 @@ export enum ROUTES_HOME_V1 {

export enum ROUTES_SETTINGS_V1 {
PROFILE = '/profile',
NOTIFICATION = '/notification',
MANAGE_ARTICLES = '/manage-articles',
INTEGRATIONS = '/integrations',
}
Expand Down
93 changes: 0 additions & 93 deletions client/src/modules/404/index.tsx

This file was deleted.

11 changes: 11 additions & 0 deletions client/src/modules/chats/v1/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { Box } from '@mui/material';

const Chats = () => {
return (
<Box>
<p>Chats</p>
</Box>
);
};

export default Chats;
11 changes: 11 additions & 0 deletions client/src/modules/code/v1/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { Box } from '@mui/material';

const Code = () => {
return (
<Box>
<p>Code</p>
</Box>
);
};

export default Code;
1 change: 0 additions & 1 deletion client/src/modules/notification/constants/index.ts

This file was deleted.

Loading
Loading