mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-05-06 18:16:41 +07:00
added sample user profile page (#133)
This commit is contained in:
parent
aee4b662d5
commit
7638bdd1ad
6 changed files with 60 additions and 45 deletions
src/pages/profile
27
src/pages/profile/[username].tsx
Normal file
27
src/pages/profile/[username].tsx
Normal file
|
@ -0,0 +1,27 @@
|
|||
import React, { FC } from 'react';
|
||||
|
||||
import { useRouter } from 'next/router';
|
||||
import { RouteComponentProps } from 'react-router';
|
||||
|
||||
import { PageTitle } from '~/components/common/PageTitle';
|
||||
import { useGlobalLoader } from '~/hooks/dom/useGlobalLoader';
|
||||
import { ProfileLayout } from '~/layouts/ProfileLayout';
|
||||
import { FlowProvider } from '~/utils/providers/FlowProvider';
|
||||
import { getPageTitle } from '~/utils/ssr/getPageTitle';
|
||||
|
||||
type ProfilePageProps = RouteComponentProps<{ username: string }>;
|
||||
|
||||
const ProfilePage: FC<ProfilePageProps> = () => {
|
||||
const { query } = useRouter();
|
||||
|
||||
useGlobalLoader();
|
||||
|
||||
return (
|
||||
<FlowProvider>
|
||||
<PageTitle title={getPageTitle('Флоу')} />
|
||||
<ProfileLayout username={query.username as string} />
|
||||
</FlowProvider>
|
||||
);
|
||||
};
|
||||
|
||||
export default ProfilePage;
|
Loading…
Add table
Add a link
Reference in a new issue