Skip to content

Comments

fix: 데스크탑 스페이스 생성 시 커스텀 회고 템플릿 질문 수정 기능 개선#789

Merged
prgmr99 merged 2 commits intodevelopfrom
786-데스크탑-스페이스-생성-시-커스텀-회고-템플릿을-만들-때-초기-질문-수정-이슈
Jan 22, 2026

Hidden character warning

The head ref may contain hidden characters: "786-\ub370\uc2a4\ud06c\ud0d1-\uc2a4\ud398\uc774\uc2a4-\uc0dd\uc131-\uc2dc-\ucee4\uc2a4\ud140-\ud68c\uace0-\ud15c\ud50c\ub9bf\uc744-\ub9cc\ub4e4-\ub54c-\ucd08\uae30-\uc9c8\ubb38-\uc218\uc815-\uc774\uc288"
Merged

fix: 데스크탑 스페이스 생성 시 커스텀 회고 템플릿 질문 수정 기능 개선#789
prgmr99 merged 2 commits intodevelopfrom
786-데스크탑-스페이스-생성-시-커스텀-회고-템플릿을-만들-때-초기-질문-수정-이슈

Conversation

@prgmr99
Copy link
Member

@prgmr99 prgmr99 commented Jan 21, 2026

데스크탑 스페이스 생성 시 커스텀 회고 템플릿 질문 수정 기능 개선


🏄🏼‍♂️‍ Summary (요약)

  • 스페이스 생성 플로우에서 커스텀 회고 템플릿의 질문 수정이 제대로 동작하지 않던 버그를 수정했습니다.
  • 질문 수정 시 "완료" 버튼 클릭 시에만 변경사항이 저장되고, "뒤로가기" 시 변경사항이 취소되도록 개선했습니다.

🫨 Describe your Change (변경사항)

QuestionEditSection/index.tsx

  • 로컬 상태(editingQuestions)를 도입하여 수정 중인 질문들을 관리
  • 모든 수정 작업(드래그앤드롭, 내용 변경, 삭제, 추가)이 로컬 상태만 업데이트하도록 변경
  • handleComplete에서만 atom에 최종 반영되도록 수정
  • handleCancel 함수 추가: 변경사항이 있을 경우 확인 모달 표시 후 취소 처리
  • useEffect로 모달의 뒤로가기 버튼 콜백을 handleCancel로 설정

MainQuestionsContents.tsx

  • handleContentChange를 props로 받도록 변경 (기존: 컴포넌트 내부에서 atom 직접 업데이트)
  • 기존 내부 함수를 handleTextareaChange로 리네이밍하여 textarea 높이 조절만 담당

ConfirmDefaultTemplate.tsx

  • hasChangedOriginal이 true일 경우 API 원본 데이터로 덮어쓰지 않도록 조건 추가

🧐 Issue number and link (참고)

📚 Reference (참조)

  • n/a

@prgmr99 prgmr99 self-assigned this Jan 21, 2026
@prgmr99 prgmr99 added 🫨 bug Something isn't working 👾 desktop labels Jan 21, 2026
@coderabbitai
Copy link

coderabbitai bot commented Jan 21, 2026

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one) (1)
  • Not Rabbit

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@prgmr99
Copy link
Member Author

prgmr99 commented Jan 21, 2026

영상은 용량 관계로 업로드하지 못했습니다.

Copy link
Member

@klmhyeonwoo klmhyeonwoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다 굿굿뜨!


useEffect(() => {
// * 이미 질문이 수정된 상태라면 원본으로 덮어쓰지 않음
if (retroCreateData.hasChangedOriginal) return;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

!! 이거를 발견한거구나?!

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

맞습니다!

}));
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [editingQuestions, isAddMode]);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

코드로만 봤을 때는 editingQuestions 가 변경되면 내부적으로 모드에 대한 처리가 들어간 것 같은데,
의존성 배열에 editingQuestions 도 필수로 필요한거죠?!

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

주의 주석은 불필요해서 제거했습니다.
editingQuestions는 useEffect 문 내부의 handleCancel이 있는데요!
handleCanceleditingQuestions를 사용하고 있습니다.

editingQuestions가 변경될 때마다 컴포넌트가 리렌더링되고,
새로운 handleCancel이 생성되고 이때 최신 editingQuestions를 참조합니다.

그래서 필요합니다!

++ 허허... 이쪽 코드가 많이 복잡한 것 같아요..
제 코드 기준 리팩토링 1순위로 보이네요..!!

시간날 때마다 천천히 작업해볼게요!

@prgmr99 prgmr99 merged commit c2c5f63 into develop Jan 22, 2026
2 checks passed
@prgmr99 prgmr99 deleted the 786-데스크탑-스페이스-생성-시-커스텀-회고-템플릿을-만들-때-초기-질문-수정-이슈 branch February 18, 2026 11:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🫨 bug Something isn't working 👾 desktop

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants