Skip to content

Commit

Permalink
Merge pull request #27 from SoluxProject/feature/#26
Browse files Browse the repository at this point in the history
마이페이지 내비바 수정
  • Loading branch information
Sae-byeol authored Aug 18, 2021
2 parents 76c6247 + 328bc61 commit 5d72dab
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/component/EditMyPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export default function EditMyPage({location}){
return(
<div className="EditMyPage">

<MyPageNavbar></MyPageNavbar>
<MyPageNavbar page="editmypage"></MyPageNavbar>
<div className="EditMyPageMainContent">
<div className="EditMyPageTitle">
<h1>회원정보 수정</h1>
Expand Down
2 changes: 1 addition & 1 deletion src/component/ExamDday.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ export default function ExamDday({location}){
return(
<div className="wrapper">
<div className="MyPageNavbar">
<MyPageNavbar></MyPageNavbar>
<MyPageNavbar page="examdday"></MyPageNavbar>
</div>
<div className="ExamDday">
<div className="ExamDdayHeadBlock">
Expand Down
3 changes: 2 additions & 1 deletion src/component/MyPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import Navbr from "./Navbar";
import React , {useState, useEffect} from 'react';
import Axios from 'axios';
import {Link} from 'react-router-dom';
import MyPageNavbar from "./MyPageNavbar";

export default function MyPage(){
const [user,setUser]=useState([]);
Expand All @@ -18,7 +19,7 @@ export default function MyPage(){
return(
<div className="MyPage">
<div className="MyPageNavbar">
<Navbr page="MyPage"></Navbr>
<MyPageNavbar page="mypage"></MyPageNavbar>
</div>
<div className="MyPageContent">
<div className="MyPageTitle">
Expand Down
20 changes: 17 additions & 3 deletions src/component/MyPageNavbar.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,28 @@ import { BsChevronDoubleLeft } from 'react-icons/bs';
import { Link } from 'react-router-dom';
import '../Navbar.css';

export default function MyPageNavbar(){
export default function MyPageNavbar(props){
const thisPage = props.page;

return(
<div className="nav-bar">
<div className="menu-toggle">
<Link to="/mypage">
{(thisPage === "mypage") &&
(
<Link to="/">
<BsChevronDoubleLeft style={{color: 'white', width: '1.5rem', height: '1.5rem'}} />
</Link>
</Link>
)

}
{(thisPage !== "mypage") &&
(
<Link to="/mypage">
<BsChevronDoubleLeft style={{color: 'white', width: '1.5rem', height: '1.5rem'}} />
</Link>
)

}
</div>

</div>
Expand Down
2 changes: 1 addition & 1 deletion src/component/MyTime.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export default function MyTime ({location}){
return(
<div className="MyTime">
<div className="MyPageNavbar">
<MyPageNavbar></MyPageNavbar>
<MyPageNavbar page="mytime"></MyPageNavbar>
</div>
<div className="MyTimeTitle">나의 공부 시간</div>
<div className="MyTimeMain">
Expand Down

0 comments on commit 5d72dab

Please sign in to comment.