harland free asked 7 months ago

Expected Behaviour When clicking outside the toaster, it should dismiss it. User does not know the actual behaviour.

Actual behavior The user has to click the toaster itself to close / dismiss it.

Resources (screenshots, code snippets etc.) In app module: ToastModule.forRoot({preventDuplicates: true}),

In the component: this.toastService.success("Your Profile is successfully updated", "", {

Arkadiusz Idzikowski staff answered 7 months ago

This is expected behavior. It would be too easy to accidentally close the notification on document click.

You can easily add this feature on your end. The MdbNotificationRef returned by the MdbToastSerivce has a close method that you can use to programmaticaly close the Toast on a specific event.

harland free commented 7 months ago

Yes, closing the notification on document click should have been the expected behaviour on a UX perspective. The problem is that, when the notification comes up, it does not allow to click other clickable items, and the user has to wait or click the notification (in which they do not know, not common for them) for it to be close before clicking on other clickable items. It would have been nice if you have a config to be set that on a user click/tap outside the notification (on document click), the notification is dismissed.

Arkadiusz Idzikowski staff commented 7 months ago

I meant that the current behavior is correct and consistent with our assumptions. We currently have no plans to add support for closing the Toast on document click.

As I mentioned in my answer, if you need such a feature, it should be possible to implement it using available public methods.

Please insert min. 20 characters.


Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.



Specification of the issue

  • ForumUser: Free
  • Premium support: No
  • Technology: MDB Angular
  • MDB Version: MDB5 5.1.0
  • Device: Macbook
  • Browser: Chrome
  • OS: MacOS
  • Provided sample code: No
  • Provided link: No