Open oixan opened 7 years ago
I have the same question.Is there any solution for this?
i resolved this in a rude manner, but it work!
1) In dialog.service.ts in the addDialog method just before the return add:
var body = document.getElementsByTagName("body")[0];
body.style.overflow = "hidden";
2) in the removeDialog method as first line add
var body = document.getElementsByTagName("body")[0];
body.style.overflow = "";
3) in a custom css file add
.modal {
overflow: auto;
}
Try this, I hope it can work for you too.
Bad englado ... sorry :)
I think is a better solution to add the class "modal-open" to the body, wich is a bootstrap class and do the work.
There is a way to enable overflow auto for the modal and disable body overflow auto?