I have a strange problem when I dismiss my modal, the modal dialog goes away but the backdrop is staying. Looking what is going on I see that when the model is opened it ads a ng-model class o the body tag and adds two div's modal-render and modal-backdrop.
I created the ugly workaround below to solve it, but there must be a reason why it is not working as expected.
Any ideas where to look ?
document.body.setAttribute("class", "ng-scope");
var modalRender = document.body.lastChild;
var modalBackdrop = modalRender.previousSibling;
window.setTimeout(function()
{
modalBackdrop.style.zIndex = -1;
}, 100);
document.body.removeChild(modalRender);