From fcebeee7f417b50006899ef8ac7df6d9895ad752 Mon Sep 17 00:00:00 2001 From: hyuna Date: Sat, 30 Mar 2024 11:21:01 +0900 Subject: [PATCH] =?UTF-8?q?=EC=BD=94=EB=93=9C=20=EC=98=A4=EB=A5=98=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/common/list/accept/page.tsx | 2 +- .../common/list/after/delete/page.tsx | 2 +- .../components/common/list/before/index.tsx | 4 +- .../components/common/list/reason/page.tsx | 20 +++-- src/app/outAccept/page.tsx | 2 + src/app/outList/reason/page.tsx | 85 ++++++++----------- tailwind.config.ts | 1 + 7 files changed, 59 insertions(+), 57 deletions(-) diff --git a/src/app/components/common/list/accept/page.tsx b/src/app/components/common/list/accept/page.tsx index eec36b0..b16b3a5 100644 --- a/src/app/components/common/list/accept/page.tsx +++ b/src/app/components/common/list/accept/page.tsx @@ -19,7 +19,7 @@ const AcceptList: React.FC = ({ student, time, why, onClick }) => { return (
= ({ student, id }) => { const onDelete = async () => { try { await DeleteMutate( - { id: id }, + { id }, { onSuccess() { alert("삭제되었습니다"); diff --git a/src/app/components/common/list/before/index.tsx b/src/app/components/common/list/before/index.tsx index a02945b..66b1094 100644 --- a/src/app/components/common/list/before/index.tsx +++ b/src/app/components/common/list/before/index.tsx @@ -61,8 +61,8 @@ const PreviousList: React.FC = ({ id, userName }) => { }, []); return ( -
-
+
+
= ({ why, endTime, }) => { + const MAX_WHY_LENGTH = 69; + + let whyDisplay = why; + if (why.length > MAX_WHY_LENGTH) { + whyDisplay = why.substring(0, MAX_WHY_LENGTH) + "..."; + } + return ( -
-
+
+
{student}
-
+
{getToday()} • {time}~{endTime}
-
{why}
+
+ {whyDisplay} +
); }; -export default ReasonList \ No newline at end of file +export default ReasonList; diff --git a/src/app/outAccept/page.tsx b/src/app/outAccept/page.tsx index d4baa44..17e1456 100644 --- a/src/app/outAccept/page.tsx +++ b/src/app/outAccept/page.tsx @@ -197,6 +197,8 @@ const OutAccept = () => { router.push("/outAccept/previous"); }; + const ChangeText = () => {}; + return ( { }, []); return ( -
-
-
-
- 홈 > - 외출자 목록 > - {selectedTab ? "외출자 사유" : " 조기 귀가 사유"} -
-
-
- {selectedTab ? "외출자 사유" : "조기 귀가 사유"} -
- {getFullToday()} -
-
-
- ${ + selectedTab ? "외출자 사유" : " 조기 귀가 사유" + } `} + subTitle={selectedTab ? "외출자 사유" : " 조기 귀가 사유"} + secondTitle={getFullToday()} + DropChildren={ + + } + > + {selectedTab ? ( +
+ {data.map((item, index) => ( + -
+ ))}
-
- {selectedTab ? ( -
- {data.map((item, index) => ( - - ))} -
- ) : ( -
- {homeData.map((item, index) => ( - - ))} -
- )} + ) : ( +
+ {homeData.map((item, index) => ( + + ))}
-
-
+ )} + ); }; diff --git a/tailwind.config.ts b/tailwind.config.ts index e594efe..7a51588 100644 --- a/tailwind.config.ts +++ b/tailwind.config.ts @@ -299,6 +299,7 @@ const config: Config = { "30": "7.438rem", "29": "7.25rem", "25": "6.25rem", + "27%": "27%", }, height: { "140": "36.625rem",