update navbar , create pages
This commit is contained in:
26
src/app/[locale]/dashboard/page.tsx
Normal file
26
src/app/[locale]/dashboard/page.tsx
Normal file
@@ -0,0 +1,26 @@
|
||||
'use client';
|
||||
import { useEffect, useState } from 'react';
|
||||
import { Dashboard } from '@/widgets/cabinet/ui/dashboard';
|
||||
import { MOCK_USER } from '@/widgets/cabinet/lib/mock';
|
||||
|
||||
export default function Page() {
|
||||
const [userName, setUserName] = useState(MOCK_USER.first_name);
|
||||
|
||||
useEffect(() => {
|
||||
const data = localStorage.getItem('user');
|
||||
if (data) {
|
||||
try {
|
||||
const user = JSON.parse(data);
|
||||
setUserName(user.name || MOCK_USER.first_name);
|
||||
} catch {
|
||||
// ignore
|
||||
}
|
||||
}
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<div className="max-w-6xl mx-auto w-full pt-20 px-4 pb-10">
|
||||
<Dashboard userName={userName} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
9
src/app/[locale]/payments/page.tsx
Normal file
9
src/app/[locale]/payments/page.tsx
Normal file
@@ -0,0 +1,9 @@
|
||||
import { PaymentsTable } from '@/widgets/cabinet/ui/tables/PaymentsTable';
|
||||
|
||||
export default function Page() {
|
||||
return (
|
||||
<div className="max-w-6xl mx-auto w-full pt-20 px-4 pb-10">
|
||||
<PaymentsTable />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
10
src/app/[locale]/profile/page.tsx
Normal file
10
src/app/[locale]/profile/page.tsx
Normal file
@@ -0,0 +1,10 @@
|
||||
import { ProfileSection } from '@/widgets/cabinet/ui/profile';
|
||||
import { MOCK_STATS } from '@/widgets/cabinet/lib/mock';
|
||||
|
||||
export default function Page() {
|
||||
return (
|
||||
<div className="max-w-6xl mx-auto w-full pt-20 px-4 pb-10">
|
||||
<ProfileSection stats={MOCK_STATS} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
12
src/app/[locale]/si/page.tsx
Normal file
12
src/app/[locale]/si/page.tsx
Normal file
@@ -0,0 +1,12 @@
|
||||
import { SiTable } from '@/widgets/cabinet/ui/tables/SiTable';
|
||||
import { SiUploadSection } from '@/features/modals/siModal/ui/SiUploadSection';
|
||||
import React from 'react';
|
||||
|
||||
export default function Page() {
|
||||
return (
|
||||
<div className="max-w-6xl mx-auto w-full pt-20 px-4">
|
||||
<SiUploadSection />
|
||||
<SiTable />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user