diff --git a/src/api/get.ts b/src/api/get.ts index e588aa28..f0498799 100644 --- a/src/api/get.ts +++ b/src/api/get.ts @@ -143,11 +143,11 @@ export const getCounselorsRandomConsult = async () => export const getCustomerOpenConsultList = async (params: any) => await getInstance('/posts/customers', params); -export const getCustomerPopularConsultList = async (params: any) => - await getInstance('/posts/customers/public/likes', params); +export const getCustomerPopularConsultList = async () => + await getPublicInstance('/posts/customers/public/likes'); export const getCustomerPublicConsultList = async (params: any) => - await getInstance('/posts/customers/public', params); + await getPublicInstance('/posts/customers/public', params); export const getCustomerIsWriter = async (postId: any) => await getInstance(`/posts/customers/public/${postId}`); diff --git a/src/api/patch.ts b/src/api/patch.ts index a8791f55..a710a214 100644 --- a/src/api/patch.ts +++ b/src/api/patch.ts @@ -76,8 +76,8 @@ export const patchWishLists = async (counselorId: number) => //Comment Controller -export const patchAdoptComment = async (postId: any, params: any) => - await patchInstance(`/comments/customers/${postId}`, params); +export const patchAdoptComment = async (postId: any, commentId: string) => + await patchInstance(`/comments/customers/${postId}?commentId=${commentId}`); //Post Controller export const patchOpenConsult = async (body: any) => { diff --git a/src/components/Buyer/BuyerOpenConsult/HotOpenConsultList.tsx b/src/components/Buyer/BuyerOpenConsult/HotOpenConsultList.tsx index d3a128c9..c45e8d2e 100644 --- a/src/components/Buyer/BuyerOpenConsult/HotOpenConsultList.tsx +++ b/src/components/Buyer/BuyerOpenConsult/HotOpenConsultList.tsx @@ -1,23 +1,42 @@ -import React from 'react'; +import React, { useEffect, useState } from 'react'; import styled from 'styled-components'; import { ReactComponent as FireIcon } from 'assets/icons/icon-fire.svg'; import { Body3, Body4 } from 'styles/font'; import { Grey6 } from 'styles/color'; +import { getCustomerPopularConsultList } from 'api/get'; +import { useNavigate } from 'react-router-dom'; +interface apiHotConsultObj { + postId: number; + title: string; +} function HotOpenConsultList() { + const [hotConsultList, setHotConsultList] = useState([]); + const navigate = useNavigate(); + useEffect(() => { + const fetchHotConsultList = async () => { + const res: any = await getCustomerPopularConsultList(); + setHotConsultList(res.data); + }; + fetchHotConsultList(); + }, []); return ( - - 이거 권태기 증상 맞나요? - - - 이거 권태기 증상 맞나요? - - - 이거 권태기 증상 맞나요? - + {hotConsultList.map((item) => ( + { + navigate(`/open-consult/${item.postId}`); + }} + > + + {item.title.length > 19 + ? item.title.slice(0, 19) + '...' + : item.title} + + + ))} ); } diff --git a/src/components/Buyer/BuyerOpenConsult/OpenConsultList.tsx b/src/components/Buyer/BuyerOpenConsult/OpenConsultList.tsx index 7a1bd8c9..67a52516 100644 --- a/src/components/Buyer/BuyerOpenConsult/OpenConsultList.tsx +++ b/src/components/Buyer/BuyerOpenConsult/OpenConsultList.tsx @@ -1,4 +1,4 @@ -import React, { useEffect, useState } from 'react'; +import React, { useEffect, useLayoutEffect, useRef, useState } from 'react'; import styled from 'styled-components'; import { Green, Grey1, Grey2, Grey3, Grey6 } from 'styles/color'; import { Body1, Caption1, Caption2 } from 'styles/font'; @@ -14,60 +14,106 @@ import { ReactComponent as WriteIcon } from 'assets/icons/icon-write.svg'; import { Space } from 'components/Common/Space'; import { BackDrop } from 'components/Common/BackDrop'; import { openConsultApiObject } from 'pages/Buyer/BuyerConsult'; -import { getCustomerPublicConsultList } from 'api/get'; +import { + getCustomerOpenConsultList, + getCustomerPublicConsultList, +} from 'api/get'; +import { useNavigate } from 'react-router-dom'; +import useIntersectionObserver from 'hooks/useIntersectionObserver'; function OpenConsultList() { const [cardData, setCardData] = useState([]); - useEffect(() => { - const fetchOpenConsultData = async () => { + const preventRef = useRef(true); + const navigate = useNavigate(); + const [isLastElem, setIsLastElem] = useState(false); + const [isLoading, setIsLoading] = useState(false); + const onIntersect: IntersectionObserverCallback = async (entry) => { + if (entry[0].isIntersecting && !isLastElem && preventRef.current) { + preventRef.current = false; + await fetchOpenConsult( + cardData[cardData.length - 1]?.postId, + cardData[cardData.length - 1]?.finishedAt, + ); + preventRef.current = true; + } + }; + const { setTarget } = useIntersectionObserver({ + root: null, + rootMargin: '0px', + threshold: 0.8, + onIntersect, + }); + const fetchOpenConsult = async (lastId: number, lastDate: string) => { + try { const params = { - postId: '0', - finishedAt: new Date().toISOString().slice(0, 19), + postId: lastId, + finishedAt: lastDate, }; const res: any = await getCustomerPublicConsultList({ params }); + if (res.status === 200) { - setCardData(res.data); + if (res.data.length !== 0) { + if (lastId === 0) { + setCardData(res.data); + } else { + const updatedReviews = [...cardData, ...res.data]; + setCardData(updatedReviews); + } + } else { + setIsLastElem(true); + } + } else if (res.response.status === 404) { + alert('존재하지 않는 회원입니다.'); + navigate('/login'); + } + } catch (err) { + alert(err); + } finally { + if (lastId === 0) { + setIsLoading(false); } - }; - fetchOpenConsultData(); + } + }; + useLayoutEffect(() => { + fetchOpenConsult(0, new Date().toISOString().slice(0, 19)); }, []); - console.log(cardData); return (
{/* 상담카드 부분 */} - -
- 이거 권태기 증상 맞나요? - - - 비공개 - -
- -
- 요즘따라 여자친구가 먼저 만나자고 이야기도 안 하고 만나면 - 피곤하다고만 해요. 스킨십도 하려고 하지 않고 인생이 재미가 - 없다네요.. 그런데 여자친구가 다른 남자 인스타 피드에는 좋아요를 - 눌러요... 이거 여자친구가 권태기가 맞는 걸까요? 맞다면 어떻게 - 이야기를 꺼내면 좋을까요? 너무 힘듭니다.. -
-
- - - 28 - - - - 28 - - - - 28 - -
- 8분 전 -
+ {cardData.map((item) => ( + { + navigate(`/open-consult/${item.postId}`); + }} + > +
+ {item.title} +
+ +
{item.content}
+
+ + + {item.totalLike} + + + + {item.totalScrap} + + + + {item.totalComment} + +
+ {item.updatedAt} +
+ ))} + {!isLastElem ? ( +
+ ) : ( +
+ )} {/* 상담카드 부분 */}
@@ -84,11 +130,20 @@ const BuyerOpenConsultCardList = styled.div` const BuyerOpenConsultCard = styled.div` width: 100%; height: 14rem; + cursor: pointer; position: relative; background-color: ${Grey6}; padding: 1.6rem; box-sizing: border-box; border-radius: 1.2rem; + .row1 { + width: calc(100% - 5rem); + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-line-clamp: 1; + max-height: 5rem; + overflow: hidden; + } .row2 { display: -webkit-box; max-height: 4.7rem; diff --git a/src/components/Buyer/BuyerOpenConsultDetail/CommentCard.tsx b/src/components/Buyer/BuyerOpenConsultDetail/CommentCard.tsx new file mode 100644 index 00000000..5e8421a1 --- /dev/null +++ b/src/components/Buyer/BuyerOpenConsultDetail/CommentCard.tsx @@ -0,0 +1,178 @@ +import { commentApiObject } from 'components/Seller/SellerOpenConsult/CommentListSection'; +import React, { + MouseEventHandler, + useCallback, + useEffect, + useState, +} from 'react'; +import styled from 'styled-components'; +import { Grey1, Grey2, Grey3, Grey6, Red, White } from 'styles/color'; +import { Body1, Body3, Caption1, Caption2 } from 'styles/font'; +import { Characters } from 'utils/Characters'; +import { ReactComponent as HeartIcon } from 'assets/icons/icon-heart1.svg'; +import { ReactComponent as HeartEmptyIcon } from 'assets/icons/icon-heart3.svg'; +import { ReactComponent as SettingIcon } from 'assets/icons/icon-option.svg'; +import { ReactComponent as GreenCheckIcon } from 'assets/icons/icon-green-check.svg'; +import { ReactComponent as CheckIcon } from 'assets/icons/icon-check2.svg'; +import { deleteCommentLikes } from 'api/delete'; +import { postLikeComment } from 'api/post'; +interface CommentCardProps { + item: commentApiObject; + isMyPost: boolean; + setIsPickPopup: React.Dispatch>; + setPickedCommentId: React.Dispatch>; + isEndConsult: boolean | undefined; +} +function CommentCard({ + item, + isMyPost, + setPickedCommentId, + setIsPickPopup, + isEndConsult, +}: CommentCardProps) { + const [isLike, setIsLike] = useState(item.isLiked); + // 보내기 중복 방지 + const [isSending, setIsSending] = useState(false); + const [isFirstRendering, setIsFirstRendering] = useState(true); + const handleClickLikeButton = useCallback(async () => { + if (isSending) { + return; + } else { + if (isLike) { + setIsSending(true); + const res: any = await deleteCommentLikes(item.commentId); + if (res.response?.status === 400) { + alert('이미 좋아요를 취소한 댓글입니다.'); + } else if (res.response?.status === 404) { + alert('존재하지 않은 댓글입니다.'); + } + setIsLike(false); + setIsSending(false); + setIsFirstRendering(false); + } else { + setIsSending(true); + const res: any = await postLikeComment(item.commentId); + if (res.response?.status === 400) { + alert('이미 좋아요를 누른 댓글입니다.'); + } else if (res.response?.status === 404) { + alert('존재하지 않은 댓글입니다.'); + } + setIsLike(true); + setIsSending(false); + setIsFirstRendering(false); + } + } + }, [item, isLike]); + + return ( + +
+ + {item.nickName} + + {item.updatedAt} + +
+ {item.content} + + {isLike ? ( + + ) : ( + + )} + + {isFirstRendering + ? item.totalLike + : isLike + ? item.totalLike + 1 + : item.totalLike} + + + {isMyPost && !item.isChosen && !isEndConsult && ( + { + setPickedCommentId(item.commentId); + setIsPickPopup(true); + }} + > + + 이 답변 채택하기 + + )} + {item.isChosen && ( + + + 셰어 Pick + + )} +
+ ); +} + +const CommentCardWrapper = styled.div` + display: flex; + position: relative; + border-radius: 1.2rem; + box-sizing: border-box; + padding: 1.2rem 1.6rem; + flex-direction: column; + align-items: flex-start; + background-color: ${Grey6}; + gap: 1rem; + .flex1 { + display: flex; + width: 100%; + gap: 0.8rem; + height: 3.3rem; + align-items: center; + } +`; + +const SharePickButton = styled.div` + display: flex; + border-radius: 0.8rem; + position: absolute; + bottom: 1.2rem; + right: 1.6rem; + padding: 0.6rem 0.8rem; + align-items: center; + background: ${Red}; + gap: 0.4rem; +`; + +const SelectButton = styled.div` + position: absolute; + bottom: 1.2rem; + cursor: pointer; + right: 1.6rem; + display: flex; + padding: 0.6rem 0.8rem; + justify-content: flex-end; + align-items: center; + gap: 0.4rem; + border-radius: 0.8rem; + background: var(--Basic-White, #fff); +`; + +const LikeButton = styled.div` + display: flex; + border-radius: 0.8rem; + background-color: white; + padding: 0.4rem 0.8rem 0.4rem 0.4rem; + align-items: center; + gap: 0.4rem; +`; + +const SettingButton = styled(SettingIcon)` + position: absolute; + top: 2.65rem; + right: 2rem; +`; + +const Circle = styled.div` + width: 0.2rem; + height: 0.2rem; + border-radius: 100%; + background-color: ${Grey3}; +`; +export default CommentCard; diff --git a/src/components/Buyer/BuyerOpenConsultDetail/CommentListSection.tsx b/src/components/Buyer/BuyerOpenConsultDetail/CommentListSection.tsx index ed37801c..3c23c615 100644 --- a/src/components/Buyer/BuyerOpenConsultDetail/CommentListSection.tsx +++ b/src/components/Buyer/BuyerOpenConsultDetail/CommentListSection.tsx @@ -1,41 +1,23 @@ -import { lightGreen } from '@mui/material/colors'; -import { light } from '@mui/material/styles/createPalette'; import React, { useEffect, useState } from 'react'; import styled from 'styled-components'; -import { - Green, - Grey1, - Grey2, - Grey3, - Grey6, - LightGreen, - LightRed, - Red, - White, -} from 'styles/color'; -import { Body1, Body3, Body4, Caption1, Caption2 } from 'styles/font'; -import { ReactComponent as HeartIcon } from 'assets/icons/icon-heart1.svg'; -import { ReactComponent as HeartEmptyIcon } from 'assets/icons/icon-heart3.svg'; -import { ReactComponent as SettingIcon } from 'assets/icons/icon-option.svg'; -import { ReactComponent as GreenCheckIcon } from 'assets/icons/icon-green-check.svg'; -import { Characters } from 'utils/Characters'; import { Space } from 'components/Common/Space'; -import { - getCounselorsComments, - getCustomerIsWriter, - getCustomersComments, -} from 'api/get'; +import { getCustomerIsWriter, getCustomersComments } from 'api/get'; import { useNavigate, useParams } from 'react-router-dom'; -import { ReactComponent as CheckIcon } from 'assets/icons/icon-check2.svg'; import { commentApiObject } from 'components/Seller/SellerOpenConsult/CommentListSection'; import { BackDrop } from 'components/Common/BackDrop'; import IsPickPopup from './IsPickPopup'; +import CommentCard from './CommentCard'; function CommentListSection() { const [commentCard, setCommendCard] = useState([]); + // 내 게시물인지 아닌지 const [isMyPost, setIsMyPost] = useState(false); + // 팝업 창 열지 말지 const [isPickPopup, setIsPickPopup] = useState(false); - const [pickedCommentId, setPickedCommentId] = useState(); + // 상담이 종료되었는지 여부 (채택된 댓글이 있는가) + const [isEndConsult, setIsEndConsult] = useState(); + // 선택한 댓글 아이디 (좋아요, 채택) + const [pickedCommentId, setPickedCommentId] = useState(''); const { id } = useParams(); const navigate = useNavigate(); @@ -45,6 +27,11 @@ function CommentListSection() { const res: any = await getCustomersComments(id); if (res.status === 200) { setCommendCard(res.data); + for (let obj of res.data) { + if (obj.hasOwnProperty('isChosen') && obj.isChosen === true) { + setIsEndConsult(true); + } + } const res2: any = await getCustomerIsWriter(id); if (res2.status === 200) setIsMyPost(res.data); else if (res2?.response.status === 404) { @@ -61,7 +48,7 @@ function CommentListSection() { } }; fetchComment(); - }, [id]); + }, [id, isPickPopup]); return ( <> {isPickPopup && ( @@ -78,38 +65,15 @@ function CommentListSection() { {/* 댓글 리스트 , 최대 5개까지*/} {commentCard?.map((item) => ( - -
- - {item.nickName} - - {item.updatedAt} - -
- {item.content} - - - {item.totalLike} - - {/* {isMyPost && ( - { - setPickedCommentId(item.id); - setIsPickPopup(true); - }} - > - - 이 답변 채택하기 - - )} */} - - - - 셰어 Pick - -
+ ))} -
@@ -123,80 +87,4 @@ const CommentListSectionWrapper = styled.section` gap: 0.6rem; `; -const CommentGuide = styled.div<{ $isGreen: boolean }>` - height: 3.1rem; - background-color: ${(props) => (props.$isGreen ? LightGreen : LightRed)}; - display: flex; - justify-content: center; - align-items: center; - border-radius: 0.8rem; -`; - -const SelectButton = styled.div` - position: absolute; - bottom: 1.2rem; - cursor: pointer; - right: 1.6rem; - display: flex; - padding: 0.6rem 0.8rem; - justify-content: flex-end; - align-items: center; - gap: 0.4rem; - border-radius: 0.8rem; - background: var(--Basic-White, #fff); -`; - -const CommentCard = styled.div` - display: flex; - position: relative; - border-radius: 1.2rem; - box-sizing: border-box; - padding: 1.2rem 1.6rem; - flex-direction: column; - align-items: flex-start; - background-color: ${Grey6}; - gap: 1rem; - .flex1 { - display: flex; - width: 100%; - gap: 0.8rem; - height: 3.3rem; - align-items: center; - } -`; - -const SharePickButton = styled.div` - display: flex; - border-radius: 0.8rem; - position: absolute; - bottom: 1.2rem; - right: 1.6rem; - padding: 0.6rem 0.8rem; - align-items: center; - background: ${Red}; - gap: 0.4rem; -`; - -const LikeButton = styled.div` - display: flex; - border-radius: 0.8rem; - background-color: white; - padding: 0.4rem 0.8rem 0.4rem 0.4rem; - align-items: center; - gap: 0.4rem; -`; - -const Circle = styled.div` - width: 0.2rem; - height: 0.2rem; - border-radius: 100%; - background-color: ${Grey3}; -`; - -const SettingButton = styled(SettingIcon)` - position: absolute; - top: 2.65rem; - right: 2rem; -`; - export default CommentListSection; diff --git a/src/components/Buyer/BuyerOpenConsultDetail/IsPickPopup.tsx b/src/components/Buyer/BuyerOpenConsultDetail/IsPickPopup.tsx index 27208c2c..ba11d918 100644 --- a/src/components/Buyer/BuyerOpenConsultDetail/IsPickPopup.tsx +++ b/src/components/Buyer/BuyerOpenConsultDetail/IsPickPopup.tsx @@ -1,10 +1,9 @@ import { patchAdoptComment } from 'api/patch'; -import { postComment } from 'api/post'; import React from 'react'; import { useParams } from 'react-router-dom'; import styled from 'styled-components'; import { Green, Grey4, LightGreen, White } from 'styles/color'; -import { Body1, Body3, Body4 } from 'styles/font'; +import { Body1, Body3 } from 'styles/font'; interface IsPickPopupProps { isPickPopup: boolean; @@ -12,15 +11,15 @@ interface IsPickPopupProps { pickedCommentId: string; } -function IsPickPopup({ isPickPopup, setIsPickPopup }: IsPickPopupProps) { +function IsPickPopup({ + isPickPopup, + setIsPickPopup, + pickedCommentId, +}: IsPickPopupProps) { const { id } = useParams(); const adoptComment = async () => { - const params = { - commentId: 1, - }; - try { - const res: any = await patchAdoptComment(id, params); + const res: any = await patchAdoptComment(id, pickedCommentId); if (res.status === 200) { setIsPickPopup(false); } diff --git a/src/components/Buyer/BuyerOpenConsultDetail/MainQuestionSection.tsx b/src/components/Buyer/BuyerOpenConsultDetail/MainQuestionSection.tsx index 18cc6d10..576b12fa 100644 --- a/src/components/Buyer/BuyerOpenConsultDetail/MainQuestionSection.tsx +++ b/src/components/Buyer/BuyerOpenConsultDetail/MainQuestionSection.tsx @@ -5,15 +5,10 @@ import { ReactComponent as LockIcon } from 'assets/icons/icon-lock.svg'; import { ReactComponent as HeartIcon } from 'assets/icons/icon-heart1.svg'; import { ReactComponent as SaveIcon } from 'assets/icons/icon-save2.svg'; import { ReactComponent as HeartEmptyIcon } from 'assets/icons/icon-heart3.svg'; -import { ReactComponent as CommentIcon } from 'assets/icons/icon-comment.svg'; import { ReactComponent as SaveEmptyIcon } from 'assets/icons/icon-save3.svg'; -import { ReactComponent as CheckIcon } from 'assets/icons/icon-check2.svg'; import { Body1, Caption1, Caption2 } from 'styles/font'; import { Space } from 'components/Common/Space'; -import { - consultApiObject, - openConsultApiObject, -} from 'pages/Buyer/BuyerConsult'; +import { openConsultApiObject } from 'pages/Buyer/BuyerConsult'; import { getOneOpenConsult } from 'api/get'; import { useNavigate, useParams } from 'react-router-dom'; import { postLikeOpenConsult, postScrapOpenConsult } from 'api/post'; @@ -66,7 +61,7 @@ function MainQuestionSection() { if (isSending) { return; } else { - if (isSave ) { + if (isSave) { setIsSending(true); const res: any = await deletePostScraps(id); if (res.response?.status === 400) { diff --git a/src/components/Seller/SellerConsult/SellerOpenConsultList.tsx b/src/components/Seller/SellerConsult/SellerOpenConsultList.tsx index 94c98e1e..142fa4b8 100644 --- a/src/components/Seller/SellerConsult/SellerOpenConsultList.tsx +++ b/src/components/Seller/SellerConsult/SellerOpenConsultList.tsx @@ -1,7 +1,7 @@ import React, { useLayoutEffect, useRef, useState } from 'react'; import styled from 'styled-components'; import { Green, Grey1, Grey2, Grey3, Grey6, Red, White } from 'styles/color'; -import { Body1, Caption1, Caption2 } from 'styles/font'; +import { Body1, Caption1, Caption2, Heading } from 'styles/font'; import { ReactComponent as LockIcon } from 'assets/icons/icon-lock.svg'; import { ReactComponent as HeartIcon } from 'assets/icons/icon-heart2.svg'; import { ReactComponent as HeartEmptyIcon } from 'assets/icons/icon-heart3.svg'; @@ -19,6 +19,7 @@ import { ConsultModal } from 'components/Buyer/BuyerConsult/ConsultModal'; import { openConsultApiObject } from 'pages/Buyer/BuyerConsult'; import { getCounselorsOpenConsultList } from 'api/get'; import useIntersectionObserver from 'hooks/useIntersectionObserver'; +import { ReactComponent as Empty } from 'assets/icons/graphic-noting.svg'; interface SellerConsultOpenProps { sortType: number; @@ -114,6 +115,13 @@ function SellerOpenConsultList({ 내가 댓글을 작성한 글의 목록입니다. + + {openConsultList.length === 0 && ( + + + 아직 답변한 상담이 없어요 + + )} {openConsultList.map((item) => ( { @@ -270,7 +278,15 @@ const IconItem = styled.div` align-items: center; gap: 0.5rem; `; - +const EmptyIcon = styled(Empty)` + padding: 4.7rem 4.41rem 4.603rem 4.5rem; +`; +const EmptyWrapper = styled.div` + margin: 10vh auto 0px; + display: flex; + flex-direction: column; + align-items: center; +`; const Circle = styled.div` width: 0.2rem; height: 0.2rem; diff --git a/src/components/Seller/SellerOpenConsult/CommentListSection.tsx b/src/components/Seller/SellerOpenConsult/CommentListSection.tsx index 118eb840..5114e97a 100644 --- a/src/components/Seller/SellerOpenConsult/CommentListSection.tsx +++ b/src/components/Seller/SellerOpenConsult/CommentListSection.tsx @@ -21,6 +21,7 @@ import { isSendPopupOpenState } from 'utils/atom'; import { useRecoilValue } from 'recoil'; export interface commentApiObject { + commentId: string; nickName: string; content: string; isLiked: boolean; diff --git a/src/pages/Buyer/BuyerConsult.tsx b/src/pages/Buyer/BuyerConsult.tsx index e87076f4..d342fc4a 100644 --- a/src/pages/Buyer/BuyerConsult.tsx +++ b/src/pages/Buyer/BuyerConsult.tsx @@ -42,7 +42,7 @@ export interface openConsultApiObject { totalScrap: number; totalComment: number; updatedAt: string; - finishedAt?: string; + finishedAt: string; consultCategory?: string; } diff --git a/src/pages/Buyer/BuyerOpenConsult.tsx b/src/pages/Buyer/BuyerOpenConsult.tsx index a7923309..8cbc5003 100644 --- a/src/pages/Buyer/BuyerOpenConsult.tsx +++ b/src/pages/Buyer/BuyerOpenConsult.tsx @@ -10,6 +10,7 @@ import HotOpenConsultList from 'components/Buyer/BuyerOpenConsult/HotOpenConsult import { Button } from 'components/Common/Button'; function BuyerOpenConsult() { const navigate = useNavigate(); + return (
-
+
-
+
@@ -40,7 +41,7 @@ function BuyerOpenConsult() { } const Wrapper = styled.div` - section.fire { + section.hot-consult-list { height: 4.6rem; margin: 1.2rem 0rem 1.2rem 2rem; overflow: hidden; diff --git a/src/pages/Seller/SellerMyPageModifyProfile.tsx b/src/pages/Seller/SellerMyPageModifyProfile.tsx index c8a3a731..ac1d8cf0 100644 --- a/src/pages/Seller/SellerMyPageModifyProfile.tsx +++ b/src/pages/Seller/SellerMyPageModifyProfile.tsx @@ -40,7 +40,6 @@ const categoryList = { export const SellerMypageModifyProfile = () => { // 상담 카테고리 enum List,, 후에 POST할 때 Mapping 필요 const [selectCategory, setSelectCategory] = useState([]); - console.log(selectCategory); // 상담 스타일 string const [selectStyle, setSelectStyle] = useState(''); // 상담 방식 enum List @@ -104,7 +103,6 @@ export const SellerMypageModifyProfile = () => { navigate('/seller/mypage/viewProfile'); } else { const profileRes: any = await getProfiles(); - console.log(profileRes); const data = profileRes.data; if (profileRes?.response?.status === 404) { alert('판매 정보가 등록되어 있지 않습니다.');