MDL-88070 javascript: Respect removeOnClose

This commit is contained in:
Stefan Hanauska
2026-02-25 12:06:27 +01:00
parent 15557a5fc2
commit df7d605f21
3 changed files with 7 additions and 3 deletions
+1 -1
View File
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+5 -1
View File
@@ -916,7 +916,11 @@ export default class Modal {
hideIfNotForm() {
const formElement = this.modal.find(SELECTORS.FORM);
if (formElement.length == 0) {
this.hide();
if (this.removeOnClose) {
this.destroy();
} else {
this.hide();
}
}
}