Topic: Remove the padding right modal on navigation
Neanrakyr pro asked 6 years ago
Hello, today I install the modal button in my navigation. When I click on the icon I see a style who appared on my body: style="padding-right: 17px;"
I would like to know how to remove it, because each time i click on the button all my menu move.
Thank you
Hasan Ali Haolader free answered 1 year ago
Add in JS
modal.on('show.bs.modal', function () {
$('body').addClass('modal-padding-overlap');
});
Add in CSS
.modal-padding-overlap[style] {
padding-right:0 !important;
padding-left: 0 !important;
}
LauraPitskhelauri pro answered 6 years ago
Hi,
I had same problem, i found solution by removing class .fade
https://stackoverflow.com/questions/32862394/bootstrap-modals-keep-adding-padding-right-to-body-after-closed
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Status
Answered
Specification of the issue
- ForumUser: Pro
- Premium support: No
- Technology: MDB jQuery
- MDB Version: -
- Device: -
- Browser: -
- OS: -
- Provided sample code: No
- Provided link: No
Tags
Manuel Remus Stanca free commented 6 years ago
put 0 iof 17px