diff --git a/pandora_console/general/header.php b/pandora_console/general/header.php index 5502fec94f..89fb89fbde 100644 --- a/pandora_console/general/header.php +++ b/pandora_console/general/header.php @@ -1058,8 +1058,10 @@ echo sprintf('
', $menuTypeClass); }) } }, + closeOnEscape: true, onload: () => { $(document).ready(function () { + $(".ui-dialog-titlebar-close").hide(); var buttonpane = $("div[aria-describedby='welcome_modal_window'] .ui-dialog-buttonpane.ui-widget-content.ui-helper-clearfix"); $(buttonpane).append(`
diff --git a/pandora_console/godmode/menu.php b/pandora_console/godmode/menu.php index 8669b9f257..c039193fb2 100644 --- a/pandora_console/godmode/menu.php +++ b/pandora_console/godmode/menu.php @@ -804,8 +804,10 @@ $("#conf_wizard").click(function() { }) } }, + closeOnEscape: true, onload: () => { $(document).ready(function () { + $(".ui-dialog-titlebar-close").hide(); var buttonpane = $("div[aria-describedby='welcome_modal_window'] .ui-dialog-buttonpane.ui-widget-content.ui-helper-clearfix"); $(buttonpane).append(`
diff --git a/pandora_console/include/class/WelcomeWindow.class.php b/pandora_console/include/class/WelcomeWindow.class.php index 69d682a169..49d1b2159d 100644 --- a/pandora_console/include/class/WelcomeWindow.class.php +++ b/pandora_console/include/class/WelcomeWindow.class.php @@ -182,8 +182,10 @@ class WelcomeWindow extends Wizard }) } }, + closeOnEscape: true, onload: () => { $(document).ready(function () { + $(".ui-dialog-titlebar-close").hide(); var buttonpane = $("div[aria-describedby='welcome_modal_window'] .ui-dialog-buttonpane.ui-widget-content.ui-helper-clearfix"); $(buttonpane).append(`
diff --git a/pandora_console/include/javascript/pandora_ui.js b/pandora_console/include/javascript/pandora_ui.js index 6045afa439..3fa11322f1 100644 --- a/pandora_console/include/javascript/pandora_ui.js +++ b/pandora_console/include/javascript/pandora_ui.js @@ -449,6 +449,10 @@ function load_modal(settings) { } }; + if (settings.closeOnEscape == undefined) { + settings.closeOnEscape = true; + } + required_buttons.push({ class: "ui-widget ui-state-default ui-corner-all ui-button-text-only sub ok submit-next", @@ -518,7 +522,7 @@ function load_modal(settings) { collision: "fit" }, buttons: required_buttons, - closeOnEscape: true, + closeOnEscape: settings.closeOnEscape, open: function() { //$(".ui-dialog-titlebar-close").hide(); },