-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Description
Default Alert Module does not hide black overlay when alert is dismissed manually (by clicking on it)
@contactmike1 reported issue on forum and I have confirmed it that Default Alert Module does not hide black overlay when alert is dismissed manually (by clicking on it).
Steps to Reproduce: List the step by step process to reproduce the issue.
as shown in screen shot below when you show alert with out timer and manually dismiss it the black semi transpernt overlay does not hide and block the screen.
this.sendNotification("SHOW_ALERT", {'title':'Hello','message':'World........................ Hello Hello'});
Alert is dismissed but overlay is still present

Expected Results:
After dismissal of alert the overlay should also removed.
Additional Notes:
Issue is because NotificationFx.js calls the onClose call back but alert.js have not registered the callback handler and thus only alert is removed while overlay stays on the screen.
Alert.js creating the alert
this.alerts[sender.name] = new NotificationFx({
message: image + message,
effect: this.config.alert_effect,
ttl: params.timer,
al_no: "ns-alert"
});NotificationFx calling the onClose callback when it is being dismissed.
NotificationFx.prototype.dismiss = function () {
this.active = false;
clearTimeout(this.dismissttl);
this.ntf.classList.remove("ns-show");
setTimeout(() => {
this.ntf.classList.add("ns-hide");
// callback
this.options.onClose(); //< -----------
}, 25);PR : Is on the way !
