From 666d05554c74f0d844a2882536555dbe184415db Mon Sep 17 00:00:00 2001 From: Youjiiin Date: Tue, 27 Aug 2024 22:53:57 +0900 Subject: [PATCH 1/6] fix --- src/components/headerRefactor/SubHeader.js | 2 +- src/components/studyPostWrite/PostInput.js | 8 +++++++- .../studyPostWrite/studyRequirement/StudyLink.js | 2 +- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/components/headerRefactor/SubHeader.js b/src/components/headerRefactor/SubHeader.js index 6ad4120c..deed475a 100644 --- a/src/components/headerRefactor/SubHeader.js +++ b/src/components/headerRefactor/SubHeader.js @@ -11,7 +11,7 @@ export const SubHeader = ({ text }) => { const handleUserClick = () => { if (token) { - navigate('/my-page'); // 유저 아이콘 클릭 시 /my-page로 이동 + navigate('/mypage'); // 유저 아이콘 클릭 시 /my-page로 이동 } else { navigate('/login'); // 로그인 텍스트 클릭 시 /login-page로 이동 } diff --git a/src/components/studyPostWrite/PostInput.js b/src/components/studyPostWrite/PostInput.js index e9ac03e3..e56a7573 100644 --- a/src/components/studyPostWrite/PostInput.js +++ b/src/components/studyPostWrite/PostInput.js @@ -1,10 +1,16 @@ import style from './PostInput.module.css'; import usePostStore from '../../pages/study/studyPostWrite/usePostStore'; + const PostInput = () => { const { content, setContent } = usePostStore(); + const handleContentChange = e => { - setContent(e.target.value); + const newValue = e.target.value; + if (newValue.length <= 1000) { + setContent(newValue); + } }; + return (