Overide Closemodal in custom widget
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-10-2025 06:42 AM
Hi Community,
Can we override the "close modal" to close?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-17-2025 06:11 AM
Hi @Dinesh61 ,
i have try this way it worked. Please follow this step
in client controller where your calling spModal just make little bit modification. if your using alert then this tooltip will be appeared try to use open method with an options
function(spModal) {
var c = this;
c.onAlert = function () {
var options = {
title: '',
message: '<h1 class="modal-title h4">Hi BK</h1>',
input: false,
keyboard: false,
noDismiss: true, // this also hides the normal "title"
buttons: [
{label:'${OK}', primary: true}
]
};
spModal.open(options).then(function (answer) {
c.simple = answer;
});
}
}
output look like this:
If this helped please like and mark it as an accepted solution.
Thanks,
BK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2025 02:26 AM
Hi @Bhavya11,
write the below code in widget client script to change the OOB label "closemodal" to "close", it worked for me