mirror of
https://github.com/zulip/zulip.git
synced 2025-11-04 14:03:30 +00:00
message view: Show message source button until message successfully sent.
This commit removes the unless msg/locally_echoed condition for the edit content div, which has the consequence of making the "view message source" widget always available for locally echoed messages. This ensures that the message source can be seen if a very long message has been drafted and it fails due to a server-side error (See #17425 for the original report). Fixes #17650.
This commit is contained in:
@@ -95,14 +95,13 @@ function message_hover(message_row) {
|
||||
if (current_message_hover && rows.id(current_message_hover) === id) {
|
||||
return;
|
||||
}
|
||||
// Don't allow on-hover editing for local-only messages
|
||||
if (message_row.hasClass("local")) {
|
||||
return;
|
||||
}
|
||||
|
||||
const message = current_msg_list.get(rows.id(message_row));
|
||||
message_unhover();
|
||||
current_message_hover = message_row;
|
||||
|
||||
// Locally echoed messages have !is_topic_editable and thus go
|
||||
// through this code path.
|
||||
if (!message_edit.is_topic_editable(message)) {
|
||||
// The actions and reactions icon hover logic is handled entirely by CSS
|
||||
return;
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
<div class="message_controls{{#status_message}} sender-status-controls{{/status_message}} no-select">
|
||||
{{#if msg/sent_by_me}}
|
||||
{{#unless msg/locally_echoed}}
|
||||
<div class="edit_content"></div>
|
||||
{{/unless}}
|
||||
<div class="edit_content"></div>
|
||||
{{/if}}
|
||||
|
||||
{{#unless msg/sent_by_me}}
|
||||
|
||||
Reference in New Issue
Block a user