Alert Mode
In
alert mode, the modal works like an alert dialog box. So you only get to have a close button with default text set to "Close". Ofcourse, you can customize the button through footer.closeButton option.
/**
* Alert mode with default data ...
*/
ModalManager.instance.addModal({
body : {
content : `<span>Testing footer in <code>alert</code> mode</span>`
},
footer : {
enabled : true,
mode : 'alert',
}
});
/**
* Alert mode + custom close button text ...
*/
ModalManager.instance.addModal({
body: {
content: `<span>Testing footer in <code>alert</code> mode, with custom close button text</span>`
},
footer: {
enabled: true,
mode: 'alert',
closeButton: {
text: 'Close, or not?'
}
}
});