From f73a94ce15e885c497475b33538b641bb1de0e41 Mon Sep 17 00:00:00 2001 From: Kim Junhee <100200965+junheekim61@users.noreply.github.com> Date: Thu, 22 Feb 2024 23:26:07 +0900 Subject: [PATCH] =?UTF-8?q?ADD:=20=EC=8B=9C=EC=97=B0=EC=9A=A9=20=EB=8D=B0?= =?UTF-8?q?=EC=9D=B4=ED=84=B0=20=EC=B6=94=EA=B0=80=20=EB=B0=8F=20=EA=B8=B0?= =?UTF-8?q?=EB=8A=A5=20=EB=B3=B4=EC=99=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.html | 31 +-- src/App.jsx | 1 - .../feedback-users/FeedbackBlock.jsx | 7 +- src/components/feedback/FeedbackPerson.jsx | 14 +- src/components/result-report/Input.jsx | 6 +- src/components/result-report/Review.jsx | 20 +- src/components/result-report/Summary.jsx | 19 +- src/components/sidebar/SideBar.jsx | 9 +- .../feedback-users/feedbackUsers_dummy.js | 27 +++ src/data/feedbacks/feedback_dummy.js | 194 ++++++++++++------ src/data/personal-report/personal_dummy.js | 43 ++++ src/data/result-report/review_dummy.js | 29 +++ src/data/result-report/summary_dummy.js | 33 +++ src/pages/feedback-users/FeedbackUsers.jsx | 29 +-- src/pages/feedback/Feedback.jsx | 10 +- src/pages/home/Home.jsx | 6 +- src/pages/personal-report/PersonalReport.jsx | 42 +++- src/styles/style.js | 16 +- 18 files changed, 395 insertions(+), 141 deletions(-) create mode 100644 src/data/feedback-users/feedbackUsers_dummy.js create mode 100644 src/data/personal-report/personal_dummy.js create mode 100644 src/data/result-report/review_dummy.js create mode 100644 src/data/result-report/summary_dummy.js diff --git a/index.html b/index.html index 3d091dd..4bc2145 100644 --- a/index.html +++ b/index.html @@ -1,14 +1,21 @@ - - - - - - PEER:RE - - -
- - - + + + + + + + + + + + PEER:RE + + + +
+ + + + \ No newline at end of file diff --git a/src/App.jsx b/src/App.jsx index f4d579d..62dc922 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -16,7 +16,6 @@ import ResultReport from "/src/pages/result-report/ResultReport"; import PersonalReport from "./pages/personal-report/PersonalReport"; import CreateTeam from "./pages/create-team/CreateTeam"; import CreateProject from "./pages/create-team/CreateProject"; - import Feedback from "./pages/feedback/Feedback"; import FeedbackUsers from "./pages/feedback-users/FeedbackUsers"; import Home from "./pages/home/Home"; diff --git a/src/components/feedback-users/FeedbackBlock.jsx b/src/components/feedback-users/FeedbackBlock.jsx index ff2c001..96d2817 100644 --- a/src/components/feedback-users/FeedbackBlock.jsx +++ b/src/components/feedback-users/FeedbackBlock.jsx @@ -1,4 +1,5 @@ import React, {useState} from "react"; +import { useNavigate } from "react-router-dom"; import { ReportBox2, ContentLine, @@ -18,7 +19,7 @@ import FeedbacksStore from "/src/stores/feedback/FeedbackStore"; import axios from "axios"; export default function FeedbackBlock({ yesData, noData, selectedUser }){ - + const navigate = useNavigate(); const selectedPRId = ProjectIdStore((state) => state.selectedPRId); // 프로젝트 id // 선택 데이터 저장 @@ -37,6 +38,7 @@ export default function FeedbackBlock({ yesData, noData, selectedUser }){ 'thorough': data[4], 'engaging': data[5], }; + console.log(newData); @@ -101,7 +103,8 @@ export default function FeedbackBlock({ yesData, noData, selectedUser }){ - SendUserFeedback()}>완료 + {/* SendUserFeedback()}>완료 */} + navigate("/feedback")}>완료 ); } diff --git a/src/components/feedback/FeedbackPerson.jsx b/src/components/feedback/FeedbackPerson.jsx index f78bd92..30b2288 100644 --- a/src/components/feedback/FeedbackPerson.jsx +++ b/src/components/feedback/FeedbackPerson.jsx @@ -1,35 +1,37 @@ import React from "react"; -import PropTypes from 'prop-types'; +import { useNavigate } from "react-router-dom"; +import PropTypes from "prop-types"; import { Person, Member, TeamProfImg, TeamPerson, MemberName, - MemberTeam, How, FeedbackContentBox, FeedbackContent, } from "/src/styles/style"; const FeedbackPerson = ({ name, image_url, no_feedbacks, yes_feedbacks }) => { + + const navigate = useNavigate(); return ( - + navigate("/feedback/users")}/> - {name} + navigate("/feedback/users")}>{name} - {yes_feedbacks.map((feedback, index) => ( + {yes_feedbacks.map((feedback, index) => (

• {feedback}

))}
- {no_feedbacks.map((feedback, index) => ( + {no_feedbacks.map((feedback, index) => (

• {feedback}

))}
diff --git a/src/components/result-report/Input.jsx b/src/components/result-report/Input.jsx index f109c42..803f5c3 100644 --- a/src/components/result-report/Input.jsx +++ b/src/components/result-report/Input.jsx @@ -17,8 +17,10 @@ export default function Input() { const accessToken = localStorage.getItem('accessToken'); const [content, setContent] = useState(""); - const [userNameInfo, setuserNameInfo] = useState(""); - const [userProfileImg, setuserProfileImg] = useState(""); + // const [userNameInfo, setuserNameInfo] = useState(""); // 원 데이터 + // const [userProfileImg, setuserProfileImg] = useState(""); // 원 데이터 + const [userNameInfo, setuserNameInfo] = useState("홍길동"); // 임시 더미 데이터 (api 연결 성공시 삭제) + const [userProfileImg, setuserProfileImg] = useState("/src/assets/images/result-report/미모티콘1.png"); // 임시 더미 데이터 (api 연결 성공시 삭제) const selectedPRId = ProjectIdStore((state) => state.selectedPRId); // 프로젝트 id const [isSend, setIsSend] = useState(false); // 보냈는지 확인하는 상태관리 diff --git a/src/components/result-report/Review.jsx b/src/components/result-report/Review.jsx index aae7f10..aff4dad 100644 --- a/src/components/result-report/Review.jsx +++ b/src/components/result-report/Review.jsx @@ -9,15 +9,24 @@ import { ProfileText, ProfileName, } from "/src/styles/style"; +import { + nickname, + profileImgUrl, + content, +} from "../../data/result-report/review_dummy"; // 임시 더미 데이터 (api 연결 성공시 삭제) import React, { useState, useEffect } from "react"; import axios from "axios"; import ProjectIdStore from "/src/stores/projectId/ProjectIdStore"; export default function Review() { - const [nicknames, setnicknames] = useState([]); - const [profileImgUrls, setprofileImgUrls] = useState([]); - const [contents, setcontents] = useState([]); + // 원 데이터 + // const [nicknames, setnicknames] = useState([]); + // const [profileImgUrls, setprofileImgUrls] = useState([]); + // const [contents, setcontents] = useState([]); + const [nicknames, setnicknames] = useState(nickname); // 임시 더미 데이터 (api 연결 성공시 삭제) + const [profileImgUrls, setprofileImgUrls] = useState(profileImgUrl); // 임시 더미 데이터 (api 연결 성공시 삭제) + const [contents, setcontents] = useState(content); // 임시 더미 데이터 (api 연결 성공시 삭제) const selectedPRId = ProjectIdStore((state) => state.selectedPRId); // 프로젝트 id @@ -28,9 +37,10 @@ export default function Review() { const sendGetRequest = async () => { try { - const response = await axios.get( - `${import.meta.env.VITE_APP_SERVER_HOST}/api/project/${selectedPRId}/comments`, + `${ + import.meta.env.VITE_APP_SERVER_HOST + }/api/project/${selectedPRId}/comments`, { headers: { "Content-Type": "application/json", diff --git a/src/components/result-report/Summary.jsx b/src/components/result-report/Summary.jsx index fad17e9..7e6f121 100644 --- a/src/components/result-report/Summary.jsx +++ b/src/components/result-report/Summary.jsx @@ -8,9 +8,9 @@ import { Team_Table, VerticalLine, } from "/src/styles/style"; +import { summary_dummy, summary_feedback_dummy } from "../../data/result-report/summary_dummy"; import { useState, useEffect } from "react"; import axios from "axios"; -import styled from "styled-components"; import PropTypes from "prop-types"; Summary.propTypes = { @@ -35,8 +35,21 @@ export default function Summary({ projectName, }) { const [button, setButton] = useState("team"); - const [yesFeedbackContents, setYesFeedbackContents] = useState([]); - const [noFeedbackContents, setNoFeedbackContents] = useState([]); + + // 임시 더미 데이터 (api 연결 성공시 삭제) + startDay = summary_dummy[0].startDay; + endDay = summary_dummy[0].endDay; + memberNum = summary_dummy[0].memberNum; + teamName = summary_dummy[0].teamName; + totalNoFeedbackCount = summary_dummy[0].totalNoFeedbackCount; + totalParticipateRate = summary_dummy[0].totalParticipateRate; + totalYesFeedbackCount = summary_dummy[0].totalYesFeedbackCount; + projectName = summary_dummy[0].projectName; + + // const [yesFeedbackContents, setYesFeedbackContents] = useState([]); // 원 데이터 + // const [noFeedbackContents, setNoFeedbackContents] = useState([]); // 원 데이터 + const [yesFeedbackContents, setYesFeedbackContents] = useState(summary_feedback_dummy[0].yesFeedbackList); // 임시 더미 데이터 (api 연결 성공시 삭제) + const [noFeedbackContents, setNoFeedbackContents] = useState(summary_feedback_dummy[1].noFeedbackList); // 임시 더미 데이터 (api 연결 성공시 삭제) const handleButtonClick = (btn) => { setButton(btn); diff --git a/src/components/sidebar/SideBar.jsx b/src/components/sidebar/SideBar.jsx index 9bc4562..1b2828e 100644 --- a/src/components/sidebar/SideBar.jsx +++ b/src/components/sidebar/SideBar.jsx @@ -47,11 +47,12 @@ export default function SideBar(location) { return ( - + + {/* */} + -

- {userName} -

+ {/*

{userName}

*/} +

홍길동


diff --git a/src/data/feedback-users/feedbackUsers_dummy.js b/src/data/feedback-users/feedbackUsers_dummy.js new file mode 100644 index 0000000..649de3a --- /dev/null +++ b/src/data/feedback-users/feedbackUsers_dummy.js @@ -0,0 +1,27 @@ +const getRandomImageUrl = () => { + return `https://picsum.photos/80/80?random=${Math.floor(Math.random() * 1000)}`; +}; + +export const yesData_dummy = [ + { comment: "연락이 잘 돼요." }, + { comment: "시간약속을 잘 지켜요." }, + { comment: "능력이 뛰어나요" }, + { comment: "말을 조리있게 잘 해요." }, + { comment: "빈틈이 없어요" }, + { comment: "친절해요." }, + { comment: "최선을 다해요." }, + { comment: "긍정적인 태도를 지녔어요." }, + { comment: "매너가 있어요." }, + ]; + +export const noData_dummy = [ + { comment: "연락이 안 돼요." }, + { comment: "시간약속을 안 지켜요." }, + { comment: "능력이 부족해요." }, + { comment: "말을 조리있게 못해요." }, + { comment: "빈틈이 있어요" }, + { comment: "불친절해요" }, + { comment: "최선을 다하지 않아요." }, + { comment: "부정적인 태로를 지녔어요." }, + { comment: "매너가 없어요." }, + ]; \ No newline at end of file diff --git a/src/data/feedbacks/feedback_dummy.js b/src/data/feedbacks/feedback_dummy.js index c43cf4c..31670a6 100644 --- a/src/data/feedbacks/feedback_dummy.js +++ b/src/data/feedbacks/feedback_dummy.js @@ -1,64 +1,132 @@ +const getRandomImageUrl = () => { + return `https://picsum.photos/80/80?random=${Math.floor(Math.random() * 1000)}`; + }; + export const feedback_dummy = [ - { - "teamUserNickname": "팀원1", - "teamUserProfileImageUrl": null, - "teamName": "피어리", - "yesFeedbackList": [], - "noFeedbackList": [] - }, - { - "teamUserNickname": "팀원2", - "teamUserProfileImageUrl": null, - "teamName": "피어리", - "yesFeedbackList": [], - "noFeedbackList": [] - }, - { - "teamUserNickname": "팀원3", - "teamUserProfileImageUrl": null, - "teamName": "피어리", - "yesFeedbackList": [], - "noFeedbackList": [] - }, - { - "teamUserNickname": "팀원4", - "teamUserProfileImageUrl": null, - "teamName": "피어리", - "yesFeedbackList": [], - "noFeedbackList": [ - "연락이 안 돼요", - "시간약속을 잘 안지켜요", - "능력이 뒤떨어져요", - "말을 조리있게 못해요", - "빈틈이 있어요", - "재미없어요" - ] - }, - { - "teamUserNickname": "팀원5", - "teamUserProfileImageUrl": null, - "teamName": "피어리", - "yesFeedbackList": [], - "noFeedbackList": [] - }, - { - "teamUserNickname": "팀원6", - "teamUserProfileImageUrl": null, - "teamName": "피어리", - "yesFeedbackList": [], - "noFeedbackList": [] - }, - { - "teamUserNickname": "팀원7", - "teamUserProfileImageUrl": "vvv.jpg", - "teamName": "피어리", - "yesFeedbackList": [], - "noFeedbackList": [ - "연락이 안 돼요", - "시간약속을 잘 안지켜요", - "능력이 뒤떨어져요", - "말을 조리있게 못해요", - "빈틈이 있어요" - ] - } -] \ No newline at end of file + { + teamUserNickname: "팀원1", + teamUserProfileImageUrl: getRandomImageUrl(), + teamName: "피어리", + yesFeedbackList: [ + "연락이 잘 돼요.", + "말을 조리있게 잘 해요.", + "빈틈이 없어요", + "긍정적인 태도를 지녔어요.", + "매너가 있어요.", + ], + noFeedbackList: [ + "연락이 안 돼요", + "시간약속을 잘 안지켜요", + "능력이 뒤떨어져요", + "불친절해요", + "협동심이 부족해요", + ], + }, + { + teamUserNickname: "팀원2", + teamUserProfileImageUrl: getRandomImageUrl(), + teamName: "피어리", + yesFeedbackList: [ + "시간약속을 잘 지켜요.", + "능력이 뛰어나요", + "말을 조리있게 잘 해요.", + "긍정적인 태도를 지녔어요.", + ], + noFeedbackList: [ + "연락이 안 돼요.", + "시간약속을 안 지켜요.", + "능력이 부족해요.", + "말을 조리있게 못해요.", + ], + }, + { + teamUserNickname: "팀원3", + teamUserProfileImageUrl: getRandomImageUrl(), + teamName: "피어리", + yesFeedbackList: [ + "연락이 잘 돼요.", + "최선을 다해요.", + "긍정적인 태도를 지녔어요.", + "매너가 있어요.", + ], + noFeedbackList: [ + "불친절해요", + "최선을 다하지 않아요.", + "부정적인 태로를 지녔어요.", + "매너가 없어요.", + ], + }, + { + teamUserNickname: "팀원4", + teamUserProfileImageUrl: getRandomImageUrl(), + teamName: "피어리", + yesFeedbackList: [ + "연락이 잘 돼요.", + "시간약속을 잘 지켜요.", + "능력이 뛰어나요", + "말을 조리있게 잘 해요.", + "빈틈이 없어요", + ], + noFeedbackList: [ + "연락이 안 돼요", + "시간약속을 잘 안지켜요", + "능력이 뒤떨어져요", + "말을 조리있게 못해요", + "빈틈이 있어요", + "재미없어요", + ], + }, + { + teamUserNickname: "팀원5", + teamUserProfileImageUrl: getRandomImageUrl(), + teamName: "피어리", + yesFeedbackList: [ + "친절해요.", + "최선을 다해요.", + "긍정적인 태도를 지녔어요.", + "매너가 있어요.", + ], + noFeedbackList: [ + "연락이 안 돼요.", + "시간약속을 안 지켜요.", + "능력이 부족해요.", + ], + }, + { + teamUserNickname: "팀원6", + teamUserProfileImageUrl: getRandomImageUrl(), + teamName: "피어리", + yesFeedbackList: [ + "연락이 잘 돼요.", + "말을 조리있게 잘 해요.", + "빈틈이 없어요", + "친절해요.", + ], + noFeedbackList: [ + "빈틈이 있어요", + "불친절해요", + "최선을 다하지 않아요.", + "부정적인 태로를 지녔어요.", + "매너가 없어요.", + ], + }, + { + teamUserNickname: "팀원7", + teamUserProfileImageUrl: getRandomImageUrl(), + teamName: "피어리", + yesFeedbackList: [ + "연락이 잘 돼요.", + "능력이 뛰어나요", + "빈틈이 없어요", + "최선을 다해요.", + "매너가 있어요.", + ], + noFeedbackList: [ + "연락이 안 돼요", + "시간약속을 잘 안지켜요", + "능력이 뒤떨어져요", + "말을 조리있게 못해요", + "빈틈이 있어요", + ], + }, +]; diff --git a/src/data/personal-report/personal_dummy.js b/src/data/personal-report/personal_dummy.js new file mode 100644 index 0000000..4612343 --- /dev/null +++ b/src/data/personal-report/personal_dummy.js @@ -0,0 +1,43 @@ +export const personal_dummy = { + "status": 200, + "message": "요청이 성공했습니다.", + "data": { + "yesFeedbackInfo": { + "goodCommunication": "연락이 잘 돼요", + "goodCommunicationNum": 6, + "goodPunctual": "시간약속을 잘 지켜요", + "goodPunctualNum": 4, + "goodCompetent": "능력이 뛰어나요", + "goodCompetentNum": 3, + "goodArticulate": "말을 조리있게 잘해요", + "goodArticulateNum": 2, + "goodThorough": "빈틈이 없어요", + "goodThoroughNum": 1, + "goodEngaging": "재미있어요", + "goodEngagingNum": 1 + }, + "noFeedbackInfo": { + "badCommunication": "연락이 안 돼요", + "badCommunicationNum": 5, + "badPunctual": "시간약속을 잘 안지켜요", + "badPunctualNum": 4, + "badCompetent": "능력이 뒤떨어져요", + "badCompetentNum": 3, + "badArticulate": "말을 조리있게 못해요", + "badArticulateNum": 2, + "badThorough": "빈틈이 있어요", + "badThoroughNum": 1, + "badEngaging": "재미없어요", + "badEngagingNum": 1 + }, + "userInfo": { + "teamName": "피어리", + "teamProfile": null, + "projectName": "피어리", + "nickname": "유저닉네임", + "profileImageUrl": "image.jpg" + }, + "totalEvaluationNum": 7, + "lastModifiedDate": "2024-02-08T23:27:57.7888784" + } +} \ No newline at end of file diff --git a/src/data/result-report/review_dummy.js b/src/data/result-report/review_dummy.js new file mode 100644 index 0000000..7fd9872 --- /dev/null +++ b/src/data/result-report/review_dummy.js @@ -0,0 +1,29 @@ +const getRandomImageUrl = () => { + return `https://picsum.photos/80/80?random=${Math.floor(Math.random() * 1000)}`; + }; + +export const nickname = [ + "홍길동", + "고길동", + "장길동", + "강길동", + "김길동", + "이길동", +]; + +export const profileImgUrl = [ + getRandomImageUrl(), + getRandomImageUrl(), + getRandomImageUrl(), + getRandomImageUrl(), + getRandomImageUrl(), + getRandomImageUrl() +]; +export const content = [ + "다들 수고하셨습니다.", + "좋은 팀을 만났던 것 같아 기쁩니다.", + "고생 많으셨어요.", + "다들 수고하셨습니다.", + "좋은 팀을 만났던 것 같아 기쁩니다.", + "고생 많으셨어요.", +]; diff --git a/src/data/result-report/summary_dummy.js b/src/data/result-report/summary_dummy.js new file mode 100644 index 0000000..6ec131b --- /dev/null +++ b/src/data/result-report/summary_dummy.js @@ -0,0 +1,33 @@ +export const summary_dummy = [ + { + startDay: "2022-01-01", + endDay: "2022-02-01", + memberNum: 4, + teamName: "피어리", + totalNoFeedbackCount: 10, + totalParticipateRate: 90, + totalYesFeedbackCount: 15, + projectName: "1분기 프로젝트", + }, +]; + +export const summary_feedback_dummy = [ + { + yesFeedbackList: [ + "연락이 잘 돼요.", + "말을 조리있게 잘 해요.", + "빈틈이 없어요", + "긍정적인 태도를 지녔어요.", + "매너가 있어요.", + ], + }, + { + noFeedbackList: [ + "연락이 안 돼요", + "시간약속을 잘 안지켜요", + "능력이 뒤떨어져요", + "불친절해요", + "협동심이 부족해요", + ], + }, +]; diff --git a/src/pages/feedback-users/FeedbackUsers.jsx b/src/pages/feedback-users/FeedbackUsers.jsx index a8d5210..828940b 100644 --- a/src/pages/feedback-users/FeedbackUsers.jsx +++ b/src/pages/feedback-users/FeedbackUsers.jsx @@ -15,30 +15,9 @@ import FeedbackBlock from "/src/components/feedback-users/FeedbackBlock.jsx"; import ProjectIdStore from "/src/stores/projectId/ProjectIdStore"; import TeamSpaceStore from "/src/stores/teamSpace/TeamSpaceStore"; import FeedbacksStore from "/src/stores/feedback/FeedbackStore"; - -const yesData = [ - { comment: "연락이 잘 돼요." }, - { comment: "시간약속을 잘 지켜요." }, - { comment: "능력이 뛰어나요" }, - { comment: "말을 조리있게 잘 해요." }, - { comment: "빈틈이 없어요" }, - { comment: "친절해요." }, - { comment: "최선을 다해요." }, - { comment: "긍정적인 태로를 지녔어요." }, - { comment: "매너가 있어요." }, -]; - -const noData = [ - { comment: "연락이 안 돼요." }, - { comment: "시간약속을 안 지켜요." }, - { comment: "능력이 부족해요." }, - { comment: "말을 조리있게 못해요." }, - { comment: "빈틈이 있어요" }, - { comment: "불친절해요" }, - { comment: "최선을 다하지 않아요." }, - { comment: "부정적인 태로를 지녔어요." }, - { comment: "매너가 없어요." }, -]; +import { + yesData_dummy, noData_dummy +} from "/src/data/feedback-users/feedbackUsers_dummy"; function FeedbackUsers() { const accessToken = localStorage.getItem("accessToken"); @@ -155,7 +134,7 @@ function FeedbackUsers() { ))} - + ); } diff --git a/src/pages/feedback/Feedback.jsx b/src/pages/feedback/Feedback.jsx index 09cdaa8..8157255 100644 --- a/src/pages/feedback/Feedback.jsx +++ b/src/pages/feedback/Feedback.jsx @@ -17,7 +17,10 @@ import axios from "axios"; import ProjectIdStore from "/src/stores/projectId/ProjectIdStore"; import FeedbackPerson from "/src/components/feedback/FeedbackPerson.jsx"; import FeedbackTitle from "/src/components/feedback/FeedbackTitle.jsx"; -function FeedbackUsers() { + + +function Feedback() { + const accessToken = localStorage.getItem("accessToken"); const selectedPRId = ProjectIdStore((state) => state.selectedPRId); // 프로젝트 id @@ -46,7 +49,6 @@ function FeedbackUsers() { getFeedbacks(); }, []); // 피드백 get - return ( 피드백관리 @@ -60,7 +62,7 @@ function FeedbackUsers() { {feedbacks.map((data, index) => ( - + ))} @@ -71,4 +73,4 @@ function FeedbackUsers() { ); } -export default FeedbackUsers; +export default Feedback; diff --git a/src/pages/home/Home.jsx b/src/pages/home/Home.jsx index 465f3d9..315ad6e 100644 --- a/src/pages/home/Home.jsx +++ b/src/pages/home/Home.jsx @@ -1,5 +1,6 @@ import { HomeContainer, LogoImg, MotoImg, LoginButton, HomeBg, HomeBox } from '/src/styles/style'; import axios from 'axios'; +import { useNavigate } from "react-router-dom"; const Home = () => { @@ -23,13 +24,16 @@ const Home = () => { } }; + const navigate = useNavigate(); + return ( - + {/* */} + navigate("/team-space")}/> diff --git a/src/pages/personal-report/PersonalReport.jsx b/src/pages/personal-report/PersonalReport.jsx index 352e599..a5d82b8 100644 --- a/src/pages/personal-report/PersonalReport.jsx +++ b/src/pages/personal-report/PersonalReport.jsx @@ -19,25 +19,53 @@ import { MyRole, IntroSelf, } from "/src/styles/style"; +import { personal_dummy } from "../../data/personal-report/personal_dummy"; // 임시 더미 데이터 (api 연결 성공시 삭제) import Evaluate from "/src/components/Evaluate/Evaluate.jsx"; - import ProjectIdStore from "/src/stores/projectId/ProjectIdStore"; function PersonalReport() { const accessToken = localStorage.getItem("accessToken"); - const [profileNameApi, setProfileNameApi] = useState(""); - const [profileImgApi, setProfileImgApi] = useState(""); - const [teamName, setTeamName] = useState(""); - const [noNumberArray, setNoNumberArray] = useState([]); - const [yesNumberArray, setYesNumberArray] = useState([]); + //// api로 받아올 원 데이터 (api 연결 성공시 주석 해제) + // const [profileNameApi, setProfileNameApi] = useState(""); + // const [profileImgApi, setProfileImgApi] = useState(""); + // const [teamName, setTeamName] = useState(""); + // const [noNumberArray, setNoNumberArray] = useState([]); + // const [yesNumberArray, setYesNumberArray] = useState([]); + // const [updateTime, setUpdateTime] = useState(""); + + // 임시 더미 데이터 (api 연결 후 삭제) ~~~ + const [profileNameApi, setProfileNameApi] = useState("홍길동"); + const [profileImgApi, setProfileImgApi] = useState( + "/src/assets/images/result-report/미모티콘1.png" + ); + const [teamName, setTeamName] = useState( + personal_dummy.data.userInfo.teamName + ); + const [noNumberArray, setNoNumberArray] = useState([ + personal_dummy.data.noFeedbackInfo.badCommunicationNum, + personal_dummy.data.noFeedbackInfo.badPunctualNum, + personal_dummy.data.noFeedbackInfo.badCompetentNum, + personal_dummy.data.noFeedbackInfo.badArticulateNum, + personal_dummy.data.noFeedbackInfo.badThoroughNum, + personal_dummy.data.noFeedbackInfo.badEngagingNum, + ]); + const [yesNumberArray, setYesNumberArray] = useState([ + personal_dummy.data.yesFeedbackInfo.goodCommunicationNum, + personal_dummy.data.yesFeedbackInfo.goodPunctualNum, + personal_dummy.data.yesFeedbackInfo.goodCompetentNum, + personal_dummy.data.yesFeedbackInfo.goodArticulateNum, + personal_dummy.data.yesFeedbackInfo.goodThoroughNum, + personal_dummy.data.yesFeedbackInfo.goodEngagingNum, + ]); const [updateTime, setUpdateTime] = useState(""); + // ~~~임시 더미 데이터 (api 연결 후 삭제) const selectedPRId = ProjectIdStore((state) => state.selectedPRId); // 프로젝트 id useEffect(() => { // 페이지 렌더링 시 GET 요청 보내기 - sendGetRequest(); + // sendGetRequest(); //api로 받아올 원 데이터 setUpdateTime(getCurrentTime()); }, []); diff --git a/src/styles/style.js b/src/styles/style.js index 57416f8..637631f 100644 --- a/src/styles/style.js +++ b/src/styles/style.js @@ -38,6 +38,7 @@ export const MainWrapper = styled.div` width: 100vw; height: 100vh; display: flex; + font-family: "Noto Sans KR", sans-serif; `; export const LeftBody = styled.div` @@ -373,6 +374,7 @@ export const ProfileImage = styled.div` background-repeat: no-repeat; background-size: contain; background-position: center; + border-radius: 50%; `; export const ProfileText = styled.div` @@ -609,8 +611,8 @@ export const UpdateTime = styled.div` export const ProfImg = styled.img` background: lightgray 50% / cover no-repeat; border-radius: 50%; - height: 70px; - width: 70px; + height: 80px; + width: 80px; margin: auto 4%; `; @@ -1044,7 +1046,6 @@ export const FeedBackType2 = styled.div` justify-content: center; align-items: center; padding: 0 3%; - overflow-y: scroll; `; export const FeedbackData = styled.div` @@ -1083,13 +1084,14 @@ export const Member = styled.div` align-items: center; border-right: 1.5px solid gray; gap: 15px; - padding: 0 50px 40px 20px; + padding: 0 20px 40px 20px; `; export const TeamProfImg = styled.img` background: lightgray 50% / cover no-repeat; border-radius: 50%; - max-width: 100px; - height: 10s0px; + width: 80px; + height: 80px; + pointer-events: auto; `; export const TeamPerson = styled.div` /* border: 1px solid green; */ @@ -1099,7 +1101,9 @@ export const TeamPerson = styled.div` export const MemberName = styled.div` font-weight: 700; font-size: x-large; + pointer-events: auto; `; + export const MemberTeam = styled.div``; export const How = styled.div`