mirror of
https://github.com/zulip/zulip.git
synced 2025-11-05 06:23:38 +00:00
dialog_widget: Remove code related to email field visibility.
The code for hiding and showing email field in the user deactiavtion modal was added in dialog_widget.js. This commit removes it and instead add the code to its relevant module (settings_user.js), since the email field is present only in one modal and not all modals.
This commit is contained in:
@@ -117,10 +117,6 @@ export function launch(conf) {
|
||||
}
|
||||
|
||||
const $submit_button = $dialog.find(".dialog_submit_button");
|
||||
const $send_email_checkbox = $dialog.find(".send_email");
|
||||
const $email_field = $dialog.find(".email_field");
|
||||
|
||||
$email_field.hide();
|
||||
|
||||
// This is used to link the submit button with the form, if present, in the modal.
|
||||
// This makes it so that submitting this form by pressing Enter on an input element
|
||||
@@ -143,14 +139,6 @@ export function launch(conf) {
|
||||
conf.on_click(e);
|
||||
});
|
||||
|
||||
$send_email_checkbox.on("change", () => {
|
||||
if ($send_email_checkbox.is(":checked")) {
|
||||
$email_field.show();
|
||||
} else {
|
||||
$email_field.hide();
|
||||
}
|
||||
});
|
||||
|
||||
overlays.open_modal("dialog_widget_modal", {
|
||||
autoremove: true,
|
||||
on_show() {
|
||||
|
||||
Reference in New Issue
Block a user