The application was extensively using modal popups, and the design allowed to stack popups on each other.
Many of them were just created on div elements that already existed in the HTML markup. What I thought would be a better
idea was to create div elements dynamically only if I wanted to show a dialog.
The next thing I’d like to achieve was using a default configuration for created dialogs.
What’s more, I wanted my div element destroyed after closing the dialog.