You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Posting a comment with Ctrl+Enter does not add it to the "review queue", but instead publishes the whole "queue" immediately.
Introduced in 1.17 with #19729.
Make a PR and go to "files changed" section.
Write a comment somewhere. Notice that there are "Start review" and "Add single comment" buttons.
Click "Start review". The comment now has yellow "pending" label.
Add another comment. Notice that there is only one button now, "Add comment".
Instead of clicking the button, hit Ctrl+Enter. The new comment will have gray "review" label, while the old one still has yellow "pending".
Try to write another comment. Notice that "Start review" and "Add single comment" are back.
Refresh the page. Both comments have "review" label. If you go to "conversation", both comments are visible.
Gitea Version
1.17
Can you reproduce the bug on the Gitea demo site?
Yes
The text was updated successfully, but these errors were encountered:
The problem is that the review comment UI is inside a form, then the quick-submit handler triggers submit event and it's ambiguous.
To make the logic correct and fix the issue, the AJAX related inputs should be (refactored) moved out of the form, and handle ce-quick-submit event by customized code.
Related code:
initRepoDiffConversationForm in repo-diff.js
<form ...> in comment_form.tmpl
Maybe there could be another fix: set the is_review=true if the form only contains one Add comment button.
If there is only one "Add comment" button (when there are pending review comments), the quick-submit should submit the form with is_review=true even if the "Add comment" button is not really clicked.
Close#20990
Description
Posting a comment with
Ctrl+Enter
does not add it to the "review queue", but instead publishes the whole "queue" immediately.Introduced in 1.17 with #19729.
Ctrl+Enter
. The new comment will have gray "review" label, while the old one still has yellow "pending".Gitea Version
1.17
Can you reproduce the bug on the Gitea demo site?
Yes
The text was updated successfully, but these errors were encountered: