diff --git a/src/components/board/BoardComment.vue b/src/components/board/BoardComment.vue index 4ad12f7..01879d2 100644 --- a/src/components/board/BoardComment.vue +++ b/src/components/board/BoardComment.vue @@ -16,7 +16,7 @@ @updateReaction="handleUpdateReaction" /> -
+
{ // 익명 비밀번호 창 토글 const toggleCommentPassword = (comment, button) => { console.log(comment.commentId) - if (lastCommentClickedButton.value === button && isCommentPassword.value === comment.commentId) { - isCommentPassword.value = false; // 비밀번호 창 닫기 + if (lastCommentClickedButton.value === button && currentPasswordCommentId.value === comment.commentId) { + currentPasswordCommentId.value = null; // 비밀번호 창 닫기 } else { - isCommentPassword.value = comment.commentId; // 비밀번호 창 열기 + currentPasswordCommentId.value = comment.commentId; // 비밀번호 창 열기 } lastCommentClickedButton.value = button;