profile page compleated
This commit is contained in:
@@ -48,22 +48,10 @@ const ProfileSection = dynamic(
|
||||
|
||||
// ─── Section switcher ──────────────────────────────────────────────────────────
|
||||
|
||||
function SectionContent({
|
||||
section,
|
||||
onNavigate,
|
||||
}: {
|
||||
section: CabinetSection;
|
||||
onNavigate: (s: CabinetSection) => void;
|
||||
}) {
|
||||
function SectionContent({ section }: { section: CabinetSection }) {
|
||||
switch (section) {
|
||||
case 'dashboard':
|
||||
return (
|
||||
<Dashboard
|
||||
stats={MOCK_STATS}
|
||||
onNavigate={onNavigate}
|
||||
userName={MOCK_USER.name}
|
||||
/>
|
||||
);
|
||||
return <Dashboard stats={MOCK_STATS} userName={MOCK_USER.name} />;
|
||||
case 'plagiat':
|
||||
return <PlagiatTable data={MOCK_PLAGIAT} />;
|
||||
case 'si':
|
||||
@@ -107,7 +95,7 @@ export const CabinetLayout: React.FC = () => {
|
||||
<main className="flex-1 p-4 md:p-6 lg:p-8 max-w-6xl mx-auto w-full">
|
||||
<AnimatePresence mode="wait">
|
||||
<motion.div key={activeSection} {...FADE}>
|
||||
<SectionContent section={activeSection} onNavigate={navigate} />
|
||||
<SectionContent section={activeSection} />
|
||||
</motion.div>
|
||||
</AnimatePresence>
|
||||
</main>
|
||||
|
||||
Reference in New Issue
Block a user