diff --git a/src/app/(steady)/steady/create/page.tsx b/src/app/(steady)/steady/create/page.tsx index 83b52b33..7e7c9485 100644 --- a/src/app/(steady)/steady/create/page.tsx +++ b/src/app/(steady)/steady/create/page.tsx @@ -81,7 +81,9 @@ const CreateSteadyPage = () => { }; return ( -
+

@@ -92,49 +94,52 @@ const CreateSteadyPage = () => { my={"3"} className={cn("h-3 bg-st-gray-400")} /> - ( - - - { - field.onChange(value); - }} - /> - - - - )} - /> -
- ( - - - { - field.onChange(value); - }} - /> - - - - )} - /> -
+
+ ( + + + { + field.onChange(value); + }} + /> + + + + )} + /> + ( + + + { + field.onChange(value); + }} + /> + + + + )} + /> +
+
{ { field.onChange(selected); }} @@ -162,7 +167,7 @@ const CreateSteadyPage = () => { { field.onChange(selected); }} @@ -180,7 +185,7 @@ const CreateSteadyPage = () => { { field.onChange(Number(selected)); }} @@ -197,7 +202,7 @@ const CreateSteadyPage = () => { { field.onChange(format(date, "yyyy-MM-dd")); }} @@ -207,15 +212,12 @@ const CreateSteadyPage = () => { )} /> -
-
+ ( - + { value: position.id.toString(), label: position.name, }))} - className={cn("w-200")} + className={cn("w-full")} onSelectedChange={(selected) => { field.onChange(extractValue(selected).map(Number)); }} @@ -241,7 +243,7 @@ const CreateSteadyPage = () => { { field.onChange(selected); }} @@ -255,14 +257,14 @@ const CreateSteadyPage = () => { control={steadyForm.control} name={"stacks"} render={({ field }) => ( - + ({ value: stack.id.toString(), label: stack.name, }))} - className={cn("w-455")} + className={cn("w-full")} onSelectedChange={(selected) => { field.onChange(extractValue(selected).map(Number)); }} @@ -316,9 +318,12 @@ const CreateSteadyPage = () => { control={steadyForm.control} name={"content"} render={({ field }) => ( - + { unified() diff --git a/src/app/(steady)/steady/create/questions/page.tsx b/src/app/(steady)/steady/create/questions/page.tsx index 065d7739..b3e59ff3 100644 --- a/src/app/(steady)/steady/create/questions/page.tsx +++ b/src/app/(steady)/steady/create/questions/page.tsx @@ -160,138 +160,153 @@ const CreateQuestionsPage = () => { return (
-
-

스테디 신청서 질문 등록

-
- ({ - value: item.id.toString(), - label: item.title, - }), - )} - initialLabel={"질문 템플릿"} - onSelectedChange={(selected) => { - handleSelectTemplate(selected); - }} - /> - +
+
+ + +
+ { - handleAddQuestion(); - }} > - 질문 추가 - -
-
- -
- -
- {question.map((item) => ( -
+
+ {question.map((item) => (
- - { - setQuestion((prev) => - prev.map((pItem) => { - if (pItem.id === item.id) { - return { - ...pItem, - question: event.target.value, - }; - } - return pItem; - }), - ); - }} - /> - -
{ - handleDeleteQuestion(item.id); - }} + key={item.id} + className={cn( + "flex h-70 items-center justify-between gap-30 rounded-10 p-10 shadow-lg", + )} > - +
+
+ + { + setQuestion((prev) => + prev.map((pItem) => { + if (pItem.id === item.id) { + return { + ...pItem, + question: event.target.value, + }; + } + return pItem; + }), + ); + }} + /> + +
+
{ + handleDeleteQuestion(item.id); + }} + > + +
-
- ))} + ))} +
+ + +
+
- - -
+
+ +
+
+ setIsTemplateTitleSetting(false)} + onSave={handleSaveTemplate} + />
- -
- - -
- setIsTemplateTitleSetting(false)} - onSave={handleSaveTemplate} - />
); }; diff --git a/src/app/(steady)/steady/edit/[id]/page.tsx b/src/app/(steady)/steady/edit/[id]/page.tsx index d320639f..127c5340 100644 --- a/src/app/(steady)/steady/edit/[id]/page.tsx +++ b/src/app/(steady)/steady/edit/[id]/page.tsx @@ -159,7 +159,9 @@ const SteadyEditPage = ({ }; return ( -
+

@@ -170,52 +172,57 @@ const SteadyEditPage = ({ my={"3"} className={cn("h-3 bg-st-gray-400")} /> - ( - - - { - field.onChange(value); - }} - /> - - - - )} - /> -
- ( - - - { - field.onChange(value); - }} - /> - - - - )} - /> -
+
+ ( + + + { + field.onChange(value); + }} + /> + + + + )} + /> + ( + + + { + field.onChange(value); + }} + /> + + + + )} + /> +
+
-
+
{ field.onChange(selected); }} @@ -248,7 +255,7 @@ const SteadyEditPage = ({ initialLabel={"진행 방식"} initialData={steadyMode} items={steadyRunningMethods} - className={cn("w-200")} + className={cn("w-full")} onSelectedChange={(selected) => { field.onChange(selected); }} @@ -268,7 +275,7 @@ const SteadyEditPage = ({ initialLabel={"스테디 정원"} initialData={participantLimit} items={steadyParticipantsLimit} - className={cn("w-200")} + className={cn("w-full")} onSelectedChange={(selected) => { field.onChange(Number(selected)); }} @@ -287,7 +294,7 @@ const SteadyEditPage = ({ { field.onChange(format(date, "yyyy-MM-dd")); }} @@ -296,20 +303,18 @@ const SteadyEditPage = ({ )} /> -
-
-
+ ( - + { field.onChange(extractValue(selected).map(Number)); }} @@ -328,7 +333,7 @@ const SteadyEditPage = ({ initialLabel={"예상 기간"} initialData={scheduledPeriod} items={steadyExpectedPeriods} - className={cn("w-200")} + className={cn("w-full")} onSelectedChange={(selected) => { field.onChange(selected); }} @@ -342,12 +347,12 @@ const SteadyEditPage = ({ defaultValue={extractValue(stacksInitialData).map(Number)} name={"stacks"} render={({ field }) => ( - + { field.onChange(extractValue(selected).map(Number)); }} @@ -366,7 +371,7 @@ const SteadyEditPage = ({ initialLabel={"상태"} initialData={status} items={steadyRecruitmentStatus} - className={cn("w-200")} + className={cn("w-full")} onSelectedChange={(selected) => { field.onChange(selected); }} @@ -423,9 +428,12 @@ const SteadyEditPage = ({ name={"content"} render={({ field }) => { return ( - + { diff --git a/src/app/(steady)/steady/edit/questions/[id]/page.tsx b/src/app/(steady)/steady/edit/questions/[id]/page.tsx index a9bcb5b3..9b3cd7ef 100644 --- a/src/app/(steady)/steady/edit/questions/[id]/page.tsx +++ b/src/app/(steady)/steady/edit/questions/[id]/page.tsx @@ -176,124 +176,143 @@ const EditQuestionsPage = ({ params }: { params: { id: string } }) => { return (
-
-

스테디 신청서 질문

-
- ({ - value: item.id.toString(), - label: item.title, - }), - )} - initialLabel={"질문 템플릿"} - onSelectedChange={(selected) => { - handleSelectTemplate(selected); - }} - /> - +
+
+ + +
+ { - handleAddQuestion(); - }} > - 질문 추가 - -
-
- -
- -
- {question.map((item) => ( -
+
+ {question.map((item) => (
- - { - handleInputQuestion(event, item.sequence); - }} - /> - -
{ - handleDeleteQuestion(item.sequence); - }} + key={item.sequence} + className={cn( + "z-10 flex h-70 items-center justify-between gap-30 rounded-10 p-10 shadow-lg", + )} > - +
+
+ + { + handleInputQuestion(event, item.sequence); + }} + /> + +
+
{ + handleDeleteQuestion(item.sequence); + }} + > + +
-
- ))} + ))} +
+ + +
+
- - -
+
+ +
+
+ setIsTemplateTitleSetting(false)} + onSave={handleSaveTemplate} + />
- -
- - -
- setIsTemplateTitleSetting(false)} - onSave={handleSaveTemplate} - />
); }; diff --git a/src/app/(steady)/steady/manage/[id]/page.tsx b/src/app/(steady)/steady/manage/[id]/page.tsx index 52fe0703..f37422cf 100644 --- a/src/app/(steady)/steady/manage/[id]/page.tsx +++ b/src/app/(steady)/steady/manage/[id]/page.tsx @@ -122,17 +122,18 @@ const SteadyManagePage = ({ params }: { params: { id: string } }) => { } return ( -
-
-
- {`${steadyDetailsData.name} 운영 페이지`} +
+
+
+ {steadyDetailsData.name} + 스테디 운영
-
+
- -
- - - {steadyParticipantsData.participants.map((participant) => ( - { - setCurrentUserIndex( - steadyParticipantsData.participants.findIndex( - (item) => item.id === participant.id, - ), - ); - }} - > - {participant.nickname} - - ))} - -
- {steadyParticipantsData.participants.map((participant) => ( - - {!participantDetailsData.isDeleted ? ( -
-
-
-
- 멤버 정보 + + + + + {steadyParticipantsData.participants.map((participant) => ( + { + setCurrentUserIndex( + steadyParticipantsData.participants.findIndex( + (item) => item.id === participant.id, + ), + ); + }} + > + {participant.nickname} + + ))} + +
+ {steadyParticipantsData.participants.map((participant) => ( + + {!participantDetailsData.isDeleted ? ( +
+
+
+
+ 멤버 정보 +
+ {"내 +
+ {participantDetailsData.user.nickname} +
+ + {participantDetailsData.user.position.name} + +
+
+ {participantDetailsData.user.stacks.map((stack) => ( + + {stack.name} + + ))}
- {"내
- {participantDetailsData.user.nickname} -
- - {participantDetailsData.user.position.name} - -
-
- {participantDetailsData.user.stacks.map((stack) => ( - - {stack.name} - - ))} -
-
- {participantDetailsData.user.bio ?? - "소개가 없습니다."} -
-
- {participantDetailsData.userCards.map((card) => ( -
- 카드 이미지 -
- {`( ${card.count} )`} -
-
- ))} -
-
+ {participantDetailsData.user.bio ?? + "소개가 없습니다."} +
+
+ {participantDetailsData.userCards.map((card) => (
- {participantDetailsData.reviews.length}개의 리뷰 -
- - {participantDetailsData.reviews.map( - (review, idx) => ( - <> -
- {review} -
- - - ), - )} -
-
+ 카드 이미지 +
+ {`( ${card.count} )`} +
+
+ ))}
-
-
- {steadyDetailsData.leaderResponse.id !== - participantDetailsData.user.userId && ( -
-
-
- 스테디 참여자 추방 시 되돌릴 수 없습니다. +
+
+ {participantDetailsData.reviews.length}개의 리뷰
- {/* TODO: 유저 추방 기능 구현 */} - - 멤버 추방 - - } - actionButton={ - - } + - - 정말 해당 멤버를 추방하시겠습니까? - - + {participantDetailsData.reviews.map( + (review, idx) => ( + <> +
+ {review} +
+ + + ), + )} +
- )} -
- ) : ( -
-
- 탈퇴한 유저 이미지 -
- 탈퇴한 유저 입니다. -
-
-
+
+ {steadyDetailsData.leaderResponse.id !== + participantDetailsData.user.userId && ( +
+
스테디 참여자 추방 시 되돌릴 수 없습니다.
@@ -401,13 +367,53 @@ const SteadyManagePage = ({ params }: { params: { id: string } }) => {
+ )} +
+ ) : ( +
+
+ 탈퇴한 유저 이미지 +
탈퇴한 유저 입니다.
- )} - - ))} -
- -
+
+
+
+ 스테디 참여자 추방 시 되돌릴 수 없습니다. +
+ {/* TODO: 유저 추방 기능 구현 */} + + 멤버 추방 + + } + actionButton={ + + } + > + 정말 해당 멤버를 추방하시겠습니까? + +
+
+
+ )} + + ))} +
+ +
); diff --git a/src/components/_common/Input/index.tsx b/src/components/_common/Input/index.tsx index 289093a5..608b267f 100644 --- a/src/components/_common/Input/index.tsx +++ b/src/components/_common/Input/index.tsx @@ -27,7 +27,7 @@ const Input = ({ input = (
+