mirror of
https://github.com/moodle/moodle.git
synced 2025-04-20 16:04:25 +02:00
MDL-79384 core: fix modal footer logic when rendering it from template
If the footer property is a Templates.render() promise, and the modal is set to show immediately (show=true), the show() logic - which contains the footer show/hide logic - can run before the footer content is set (i.e. before the promise chain is complete). In such cases, the footer will be marked as hidden and must be made visible again.
This commit is contained in:
parent
ecddfa6ccd
commit
6b214f1c81
2
lib/amd/build/modal.min.js
vendored
2
lib/amd/build/modal.min.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -642,6 +642,7 @@ export default class Modal {
|
||||
})
|
||||
.then((footer) => {
|
||||
this.footerPromise.resolve(footer);
|
||||
this.showFooter();
|
||||
return;
|
||||
})
|
||||
.catch(Notification.exception);
|
||||
|
Loading…
x
Reference in New Issue
Block a user