Custom Mode
Footer Mode: Custom
In
custom footer mode, you are free to provide any content for the footerModalManager.instance.addModal({
body: {
content: `<span>Testing footer in <code>custom</code> mode</span>`
},
footer: {
enabled: true,
mode: 'custom',
content : `Hello there, this is custom content. <a href="#">Learn more!</a>`,
}
});
Footer Mode: Custom with Template
In
custom footer mode, Instead of providing content directly, you can provide a <template> element id. If the template element id is valid, its content will be loaded as footer content, else you will see an error message as footer content
Please Note: Given a valid template ID, the footer mode will be always set to
This footer content was fetched from inside a template!
custom and template content will be used for footer content!
ModalManager.instance.addModal({
body: {
content: `<span>Testing footer in <code>custom</code> mode</span>`
},
footer: {
enabled: true,
mode: 'custom',
templateId : 'invalid-template-id'
}
});
ModalManager.instance.addModal({
body: {
content: `<span>Testing footer in <code>custom</code> mode width template ID</span>`
},
footer: {
enabled: true,
mode: 'custom',
templateId : 'footer-template'
}
});