Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
send_later_modal: Disable interaction with modal when flatpickr is open.
Aman Agrawal0d3b617a8221
diff --git a/web/src/popover_menus.js b/web/src/popover_menus.jsindex 5b003a7ec67..e7d4463d864 100644--- a/web/src/popover_menus.js+++ b/web/src/popover_menus.js@@ -897,13 +897,23 @@ export function initialize() {}});$send_later_modal.on("click", ".send_later_custom", (e) => {+ const $send_later_modal_content =+ $send_later_modal.find(".modal__content");const current_time = new Date();flatpickr.show_flatpickr($(".send_later_custom")[0],do_schedule_message,new Date(current_time.getTime() + 60 * 60 * 1000),- {minDate: new Date(current_time.getTime() + 5 * 60 * 1000)},+ {+ minDate: new Date(current_time.getTime() + 5 * 60 * 1000),+ onClose() {+ // Return to normal state.+ $send_later_modal_content.css("pointer-events", "all");+ },+ },);+ // Disable interaction with rest of the options in the modal.+ $send_later_modal_content.css("pointer-events", "none");e.preventDefault();e.stopPropagation();});