angular-mdc-web icon indicating copy to clipboard operation
angular-mdc-web copied to clipboard

Dialog - add ability to fail on beforeClose to prevent closing dialog / missing documentation

Open spiotr12 opened this issue 6 years ago • 0 comments

It would be nice if dialog.beforeEach() could be used to do e.g. some validation. if it fails then the dialog should not be closed.

Scenario: dialog as a create/update form on beforeClose I would like to check if value already exists. If it does then I would like to cancel closing the dialog.

Also the beforeClose is missed in official documentation

PS I know I could achieve this within dialog. But what I have is a dummy dialog with form. I handle api calls in class which opens the dialog.

spiotr12 avatar Nov 14 '19 14:11 spiotr12