Skip to content

Commit 51d93cf

Browse files
authored
Merge pull request #35 from modern-agile-team/feature/mentolist/#27
Mentor페이지 퍼블리싱
2 parents 72e9466 + ebaba27 commit 51d93cf

File tree

12 files changed

+131
-68
lines changed

12 files changed

+131
-68
lines changed
Lines changed: 10 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { SideViewerAtom } from '@/recoil/atoms/SideViewerAtom';
22
import { useRecoilState } from 'recoil';
3-
import styled from 'styled-components';
4-
3+
import * as S from './styled';
54
interface CardType {
65
id: number;
76
name: string;
@@ -17,58 +16,19 @@ const MentorCard = (props: CardType) => {
1716
setSideViewer(props.id);
1817
};
1918
return (
20-
<CardContainer onClick={handleSideViewer}>
21-
<CardImageBox>프로필 이미지 들어옴</CardImageBox>
22-
<CardTextBox size={16} color="#ff6000" padding="13px 0px">
19+
<S.CardContainer onClick={handleSideViewer}>
20+
<S.CardImageBox>이미지들어옴</S.CardImageBox>
21+
<S.CardTextBox size={20} color="#C63D2F" padding="13px 0px">
2322
{props.name}
24-
</CardTextBox>
25-
<CardTextBox size={11} color="#c58940" padding="0px 0px 10px 0px">
23+
</S.CardTextBox>
24+
<S.CardTextBox size={14} color="#fff" padding="0px 0px 10px 0px">
2625
{props.introduct}
27-
</CardTextBox>
28-
<CardTextBox size={9} color="#c58940" padding="10px 0px 0px 0px">
26+
</S.CardTextBox>
27+
<S.CardTextBox size={14} color="#fff" padding="10px 0px 0px 0px">
2928
{props.mainField}
30-
</CardTextBox>
31-
</CardContainer>
29+
</S.CardTextBox>
30+
</S.CardContainer>
3231
);
3332
};
3433

3534
export default MentorCard;
36-
37-
const CardContainer = styled.div`
38-
border: 1px solid #f0f;
39-
`;
40-
41-
const CardImageBox = styled.div`
42-
width: 280px;
43-
height: 290px;
44-
background-color: #999;
45-
border-radius: 10px;
46-
cursor: pointer;
47-
`;
48-
49-
interface CardTextBoxType {
50-
size: number;
51-
color: string;
52-
padding: string;
53-
}
54-
55-
/** CardTextBox
56-
* @params size={number}
57-
* @params color={string}
58-
* @params padding={string}
59-
*
60-
* @returns size -> font-size
61-
* @returns color -> color
62-
* @returns padding -> padding
63-
*
64-
* @example size={20}
65-
* @example color={#fff}
66-
* @example padding={5px || 5px 5px || 5px 5px 5px 5px}
67-
*/
68-
const CardTextBox = styled.div<CardTextBoxType>`
69-
font-weight: bold;
70-
font-size: ${(props) => props.size}px;
71-
color: ${(props) => props.color};
72-
padding: ${(props) => props.padding};
73-
cursor: pointer;
74-
`;
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
import styled from 'styled-components';
2+
3+
export const CardContainer = styled.div`
4+
height: 425px;
5+
transition: height 500ms ease;
6+
& > :nth-child(1) {
7+
height: 290px;
8+
transition: height 500ms ease;
9+
}
10+
&:hover {
11+
height: 517px;
12+
& > :nth-child(1) {
13+
height: 370px;
14+
transition: height 500ms ease;
15+
}
16+
}
17+
`;
18+
19+
export const CardImageBox = styled.div`
20+
width: 280px;
21+
height: 290px;
22+
background-color: #999;
23+
border-radius: 10px;
24+
cursor: pointer;
25+
`;
26+
27+
interface CardTextBoxType {
28+
size: number;
29+
color: string;
30+
padding: string;
31+
}
32+
33+
/** CardTextBox
34+
* @params size={number}
35+
* @params color={string}
36+
* @params padding={string}
37+
*
38+
* @returns size -> font-size
39+
* @returns color -> color
40+
* @returns padding -> padding
41+
*
42+
* @example size={20}
43+
* @example color={#fff}
44+
* @example padding={5px || 5px 5px || 5px 5px 5px 5px}
45+
*/
46+
export const CardTextBox = styled.div<CardTextBoxType>`
47+
font-weight: bold;
48+
font-size: ${(props) => props.size}px;
49+
color: ${(props) => props.color};
50+
padding: ${(props) => props.padding};
51+
cursor: pointer;
52+
`;

src/components/organisms/help-board/HelpCategory.tsx

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ const HelpCategory = () => {
55
<CategoryWarpper>
66
<CategoryContainer>
77
<CategoryBox>카테고리</CategoryBox>
8-
<CategoryBox>카테고리2</CategoryBox>
8+
<CategoryBox>카테고리2123123</CategoryBox>
99
<CategoryBox>카테고리3</CategoryBox>
1010
<CategoryBox>카테고리4</CategoryBox>
1111
</CategoryContainer>
@@ -16,15 +16,14 @@ const HelpCategory = () => {
1616
export default HelpCategory;
1717

1818
const CategoryWarpper = styled.div`
19-
border: 1px solid #e92;
2019
display: flex;
2120
justify-content: center;
21+
margin: 40px 0px 25px 0px;
2222
`;
2323

2424
const CategoryContainer = styled.div`
2525
display: flex;
2626
justify-content: left;
27-
border: 1px solid #9ff;
2827
min-width: 500px;
2928
width: 1532px;
3029
`;
@@ -36,5 +35,11 @@ const CategoryBox = styled.div`
3635
color: #fff;
3736
width: auto;
3837
margin: 6px;
39-
font-size: 10px;
38+
font-size: 16px;
39+
cursor: pointer;
40+
transition: all 300ms ease;
41+
&:hover {
42+
background-color: #c63d2f;
43+
transition: all 300ms ease;
44+
}
4045
`;

src/components/organisms/mentor-board/styled.ts

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,18 @@ import styled from 'styled-components';
33
/**MentorBoardCard.tsx */
44

55
export const MentoCardContainer = styled.div`
6-
border: 2px solid #c12;
76
display: flex;
87
width: 1560px;
98
min-height: 500px;
109
flex-wrap: wrap;
1110
`;
1211

1312
export const MentorCardWarpper = styled.div`
14-
margin: 0px 14px 118px 14px;
13+
/* margin: 0px 14px 118px 14px; */
14+
display: flex;
15+
justify-content: center;
16+
width: 308px;
17+
height: 545px;
1518
`;
1619

1720
/**MentorSideViewer */
@@ -23,7 +26,7 @@ export const SideViewerWarpper = styled.div`
2326
padding: 130px;
2427
min-width: 1100px;
2528
width: 650px;
26-
border: 4px solid #fe9;
29+
border: 4px solid #c63d2f;
2730
`;
2831

2932
export const SideProfileContainer = styled.div`
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
const CreateHelpTemplate = () => {
2+
return (
3+
<div>
4+
<div>도와줘요생성생성생성</div>
5+
</div>
6+
);
7+
};
8+
9+
export default CreateHelpTemplate;
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
const CreateMentorTemplate = () => {
2+
return (
3+
<div>
4+
<div>멘토생성생성생성</div>
5+
</div>
6+
);
7+
};
8+
9+
export default CreateMentorTemplate;
Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,27 @@
11
import SubPageHeader from '@/components/common/header/SubPageHeader';
22
import HelpBoardCardList from '../organisms/help-board/HelpBoardCard';
33
import HelpCategory from '../organisms/help-board/HelpCategory';
4+
import Link from 'next/link';
45

5-
const MenteeTemplate = () => {
6+
const HelpTemplate = () => {
67
return (
78
<>
89
<SubPageHeader />
9-
<div style={{ display: 'flex', justifyContent: 'center' }}>
10+
<div
11+
style={{ display: 'flex', justifyContent: 'center', width: '100vw' }}>
1012
<div>
1113
<HelpCategory />
14+
<Link
15+
href={{
16+
pathname: `/help/create`,
17+
}}>
18+
글쓰기
19+
</Link>
1220
<HelpBoardCardList />
1321
</div>
1422
</div>
1523
</>
1624
);
1725
};
1826

19-
export default MenteeTemplate;
27+
export default HelpTemplate;

src/components/templates/MentorTemplate.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ const MentorTemplate = () => {
2020
display: 'flex',
2121
justifyContent: 'center',
2222
width: '100vw',
23-
border: '2px solid #fff',
2423
}}>
2524
<SlideContainer>
2625
<ContentList>

src/pages/help/create/index.tsx

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import CreateHelpTemplate from '@/components/templates/CreateHelpTemplate';
2+
3+
const CreateMentee = () => {
4+
return (
5+
<div>
6+
<CreateHelpTemplate />
7+
</div>
8+
);
9+
};
10+
11+
export default CreateMentee;

src/pages/help/index.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import HelpTemplate from '@/components/templates/HelpTemplate';
2+
3+
const Mentee = () => {
4+
return <HelpTemplate />;
5+
};
6+
7+
export default Mentee;

0 commit comments

Comments
 (0)