mirror of
https://github.com/zulip/zulip.git
synced 2025-11-21 23:19:10 +00:00
bug fix: Blur message edit textboxes when hitting escape.
We have a somewhat janky mechanism for rendering message edits, and before this fix, we were not unblurring the text boxes when we closed the message editing session with the escape key, which made it so that the escape key was unusable.
This commit is contained in:
@@ -170,12 +170,14 @@ exports.process_escape_key = function (e) {
|
||||
if (exports.processing_text()) {
|
||||
if ($(".message_edit_content").filter(":focus").length > 0) {
|
||||
row = $(".message_edit_content").filter(":focus").closest(".message_row");
|
||||
row.find('.message_edit_content').blur();
|
||||
message_edit.end(row);
|
||||
return true;
|
||||
}
|
||||
|
||||
if ($(".message_edit_topic").filter(":focus").length > 0) {
|
||||
row = $(".message_edit_topic").filter(":focus").closest(".message_row");
|
||||
row.find('.message_edit_topic').blur();
|
||||
message_edit.end(row);
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user