|
|
|
@ -3,9 +3,9 @@ import { useDispatch, useSelector } from 'react-redux';
|
|
|
|
|
import Navbar from '../components/Navbar';
|
|
|
|
|
import { dateParser } from '../components/Utils';
|
|
|
|
|
import FollowHandler from '../components/UserProfil/FollowHandler';
|
|
|
|
|
import PostPersonnels from '../components/UserProfil/NavigationProfil/PostsPersonnels';
|
|
|
|
|
import DossierPersonnels from '../components/UserProfil/NavigationProfil/DossiersPersonnels';
|
|
|
|
|
import PostsLikes from '../components/UserProfil/NavigationProfil/PostsLikes';
|
|
|
|
|
import LesPostPersonnels from '../components/UserProfil/NavigationProfil/PostsPersonnels';
|
|
|
|
|
import LesDossierPersonnels from '../components/UserProfil/NavigationProfil/DossiersPersonnels';
|
|
|
|
|
import LesPostsLikes from '../components/UserProfil/NavigationProfil/PostsLikes';
|
|
|
|
|
|
|
|
|
|
const Profil = () => {
|
|
|
|
|
const userData = useSelector((state) => state.user.user);
|
|
|
|
@ -13,11 +13,13 @@ const Profil = () => {
|
|
|
|
|
const dispatch = useDispatch();
|
|
|
|
|
const [followingPopup, setFollowingPopup] = useState(false);
|
|
|
|
|
const [followerPopup, setFollowerPopup] = useState(false);
|
|
|
|
|
const [dossierPersonnels,setdossierPersonnels ] = useState(true);
|
|
|
|
|
const [postPersonnels,setpostPersonnels ] = useState(false);
|
|
|
|
|
const [postLikes,setpostLikes ] =useState(false)
|
|
|
|
|
|
|
|
|
|
const handleModals = (e) => {
|
|
|
|
|
|
|
|
|
|
const [dossierPersonnel,setdossierPersonnels ] = useState(true);
|
|
|
|
|
const [postPersonnel,setpostPersonnels ] = useState(false);
|
|
|
|
|
const [postLike,setpostLikes ] =useState(false);
|
|
|
|
|
|
|
|
|
|
const handleModalsProfil = (e) => {
|
|
|
|
|
if (e.target.id === "DossierPersonnels") {
|
|
|
|
|
setdossierPersonnels(true);
|
|
|
|
|
setpostPersonnels(false);
|
|
|
|
@ -170,7 +172,7 @@ const Profil = () => {
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
)}
|
|
|
|
|
)}
|
|
|
|
|
{followerPopup && (
|
|
|
|
|
<div className="popup-profil-container">
|
|
|
|
|
<div className="modal">
|
|
|
|
@ -204,31 +206,30 @@ const Profil = () => {
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="basDePage">
|
|
|
|
|
<div class="divMenu">
|
|
|
|
|
<div class="basDePage">
|
|
|
|
|
<div class="divMenu">
|
|
|
|
|
<div>
|
|
|
|
|
<nav role="navigation" class="navProfil">
|
|
|
|
|
<ul class="navItemsProfil">
|
|
|
|
|
<li class="navItemProfil">
|
|
|
|
|
<a class="navLinkProfil" id='DossierPersonnels' onClick={handleModals}><span>Dossier Personnel</span></a>
|
|
|
|
|
<a class="navLinkProfil" onClick={handleModalsProfil} id="DossierPersonnels" >Dossier Personnel</a>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="navItemProfil">
|
|
|
|
|
<a class="navLinkProfil" id='PostsPersonnels' onClick={handleModals}><span>Posts</span></a>
|
|
|
|
|
<a class="navLinkProfil" onClick={handleModalsProfil} id="PostsPersonnels">Posts</a>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="navItemProfil">
|
|
|
|
|
<a class="navLinkProfil" id='PostLikes' onClick={handleModals}><span>Posts likés</span></a>
|
|
|
|
|
<a class="navLinkProfil" onClick={handleModalsProfil} id="PostsLikes" >Posts likés</a>
|
|
|
|
|
</li>
|
|
|
|
|
|
|
|
|
|
</ul>
|
|
|
|
|
</nav>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="menuContent">
|
|
|
|
|
<div class="menuContent listContent">
|
|
|
|
|
|
|
|
|
|
{dossierPersonnel &&<LesDossierPersonnels/>}
|
|
|
|
|
{postPersonnel &&<LesPostPersonnels/>}
|
|
|
|
|
{postLike &&<LesPostsLikes/>}
|
|
|
|
|
|
|
|
|
|
<div class="listContent">
|
|
|
|
|
{dossierPersonnels &&<DossierPersonnels/>}
|
|
|
|
|
{postPersonnels &&<PostPersonnels/>}
|
|
|
|
|
{postLikes &&<PostsLikes/>}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|