A modal can be created and opened:
const modal = this.modalService.open(SomeComponent);
and with the ‘modal’ reference, it is possible to close the modal
but if there is a backdrop, the modal can be closed by the user/visitor clicking on it (or outside the modal), then the modal is closed but it’s not possible to get this ‘event’. I didn’t find any solution for this reading the API doc.
My proposal is to add some kind of event listener, like:
or as a promise
modal.closed().then( someHandler )