From 538413c96326c757575db2f4a096f63e0293e368 Mon Sep 17 00:00:00 2001 From: nevermoregb Date: Tue, 11 Mar 2025 13:59:21 +0900 Subject: [PATCH] =?UTF-8?q?=EC=9D=B5=EB=AA=85=EC=9D=BC=EB=95=8C=20?= =?UTF-8?q?=EC=88=98=EC=A0=95,=EC=82=AD=EC=A0=9C=20=EB=B9=84=EB=B0=80?= =?UTF-8?q?=EB=B2=88=ED=98=B8=20=ED=8F=BC=20=ED=95=9C=EB=B2=88=20=EB=8D=94?= =?UTF-8?q?=20=ED=81=B4=EB=A6=AD=EC=8B=9C=20=ED=8F=BC=20=EB=8B=AB=ED=9E=88?= =?UTF-8?q?=EA=B2=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/board/BoardView.vue | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/views/board/BoardView.vue b/src/views/board/BoardView.vue index 9f3d352..efc8379 100644 --- a/src/views/board/BoardView.vue +++ b/src/views/board/BoardView.vue @@ -473,25 +473,26 @@ password.value = ''; passwordCommentAlert.value = ''; //currentPasswordCommentId.value = null; + isPassword.value = false; // 상단 프로필 비밀번호 const targetComment = findCommentById(comment.commentId, comments.value); - if (!targetComment) { return; } const isMyComment = comment.authorId === currentUserId.value; const isAnonymous = comment.author === '익명'; - if (isMyComment) { if (targetComment.isEditTextarea) { // 수정창이 열려 있는 상태에서 다시 수정 버튼을 누르면 초기화 + targetComment.isEditTextarea = false; + currentPasswordCommentId.value = comment.commentId; } else { // 다른 모든 댓글의 수정창 닫기 closeAllEditTextareas(); - + currentPasswordCommentId.value = null; // 현재 댓글만 수정 모드 활성화 targetComment.isEditTextarea = true; } @@ -541,9 +542,6 @@ // 익명 댓글 비밀번호 창 토글 const toggleCommentPassword = (comment, button) => { - console.log('comment.commentId: ', comment.commentId); - console.log('currentPasswordCommentId.value: ', currentPasswordCommentId.value); - console.log('lastCommentClickedButton.value : ', lastCommentClickedButton.value); if (lastCommentClickedButton.value === button && currentPasswordCommentId.value === comment.commentId) { currentPasswordCommentId.value = null; // 비밀번호 창 닫기 password.value = '';