Skip to content

Commit

Permalink
Update page.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
MustaphaJAM committed Jun 7, 2024
1 parent fb6a7d8 commit 1107b83
Showing 1 changed file with 11 additions and 14 deletions.
25 changes: 11 additions & 14 deletions app/profile/page.tsx
Original file line number Diff line number Diff line change
@@ -1,24 +1,21 @@
"use client";
import React, { useState } from "react";
import Sidebar from "../components/profileComponents/Sidebar";
import Security from "../components/profile/security";
import ProfileFrameElement from "../components/profile/profileFrame";
import Payments from "../components/profile/Payment";
import Preferences from "../components/profile/Preferences";
import getUserProfile from "../actions/getUserProfile";
// import PersonalInfo from "../components/profile/PersonalInfo"
import React, { useState } from 'react';
import Sidebar from '../components/profileComponents/Sidebar';
import Security from '../components/profile/security';
import Payments from '../components/profile/Payment';
import Preferences from '../components/profile/Preferences';
import getUserProfile from '../actions/getUserProfile';

const ProfilePage = () => {
const [currentScreen, setCurretScreen] = useState("PersonalInfo");
const [currentScreen, setCurrentScreen] = useState('PersonalInfo');

return (
<div className="container mx-auto max-w-screen-lg flex">
<Sidebar setCurretScreen={setCurretScreen} />
<Sidebar setCurretScreen={setCurrentScreen} />
<main className="flex-grow">
{currentScreen === "Security" && <Security />}
{currentScreen === "Payments" && <Payments />}
{currentScreen === "Preferences" && <Preferences />}
{/* {currentScreen === "PersonalInfo" && <PersonalInfo user={getUserProfile}/>} */}
{currentScreen === 'Security' && <Security />}
{currentScreen === 'Payments' && <Payments />}
{currentScreen === 'Preferences' && <Preferences />}
</main>
</div>
);
Expand Down

0 comments on commit 1107b83

Please sign in to comment.