Topic: Modal display block issue

Geoffrey free asked 6 years ago


Hello, I use the modal component with carousel component inside. The value of the css property "display" is "block" by deafult for the modal. And this is not a good thing for me... When you have it, the render is not good with a carousel. To improve that, I change in angular-bootstrap-md.es5 > ModalDirective.prototype.showElement this._renderer.setStyle(this._element.nativeElement, 'display', 'block'); to this._renderer.setStyle(this._element.nativeElement, 'display', 'grid'); But i touch the node-modules and this is not good... Is it possible to change this without touching node-modules ? I tried to use css with an "!important" but this is not working because sometimes the display value is "none" when the modal is close. Then maybe it s possible to look if the modal is open and if it is open, force display to grid. And when you close it, force display to none. But it s not a good practice ... Do you have an idea ?

Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Opened

Specification of the issue

  • ForumUser: Free
  • Premium support: No
  • Technology: MDB Angular
  • MDB Version: -
  • Device: -
  • Browser: -
  • OS: -
  • Provided sample code: No
  • Provided link: No
Tags