mirror of
https://github.com/zulip/zulip.git
synced 2025-11-11 17:36:27 +00:00
compose: Pass a container to which the banner should be applied.
This fixes banners related to message editing incorrectly appearing next to the compose box. Fixes: #25230.
This commit is contained in:
committed by
Tim Abbott
parent
c70910b5dc
commit
6dc10f8696
@@ -93,6 +93,7 @@ export function open_scheduled_message_in_compose(scheduled_msg) {
|
||||
}
|
||||
|
||||
export function send_request_to_schedule_message(scheduled_message_data, deliver_at) {
|
||||
const $banner_container = $("#compose_banners");
|
||||
const success = function (data) {
|
||||
drafts.draft_model.deleteDraft($("#compose-textarea").data("draft-id"));
|
||||
compose.clear_compose_box();
|
||||
@@ -101,7 +102,7 @@ export function send_request_to_schedule_message(scheduled_message_data, deliver
|
||||
deliver_at,
|
||||
});
|
||||
compose_banner.clear_message_sent_banners();
|
||||
compose_banner.append_compose_banner_to_banner_list(new_row);
|
||||
compose_banner.append_compose_banner_to_banner_list(new_row, $banner_container);
|
||||
};
|
||||
|
||||
const error = function (xhr) {
|
||||
@@ -110,6 +111,7 @@ export function send_request_to_schedule_message(scheduled_message_data, deliver
|
||||
compose_banner.show_error_message(
|
||||
response,
|
||||
compose_banner.CLASSNAMES.generic_compose_error,
|
||||
$banner_container,
|
||||
$("#compose-textarea"),
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user