Skip to content
Snippets Groups Projects
Commit 73cfec86 authored by Steinwender, Tamara's avatar Steinwender, Tamara
Browse files

Dbp-modal fires an event on close

parent 325fb400
No related branches found
No related tags found
No related merge requests found
......@@ -60,7 +60,12 @@ export class Modal extends DBPLitElement {
MicroModal.show(this._('#' + this.modalId), {
disableScroll: true,
onClose: (modal) => {
// TODO get from parent maybe notify parent with event
const event = new CustomEvent('dbp-modal-closed', {
detail: {id: this.modalId},
bubbles: true,
composed: true,
});
this.dispatchEvent(event);
},
});
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment