Allow full bootstrap modal html structure
See original GitHub issueCurrently, when creating a modal based on an ng-template, it is not possible to set the “outer” divs of the modal.
ng-bootstrap needs only the modal-header, modal-body and modal-footer.
When I provided the following divs (with some extra classes, that’s why I need to do this in the first place) before modal-body the modal does not show anymore:
<div class="modal">
<div class="modal-dialog">
<div class="modal-content">
...
Versions of Angular, ng-bootstrap and Bootstrap:
Angular: 9.1.7
ng-bootstrap: 6.1.0
Bootstrap: 4.4.1
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Modal
Modals are built with HTML, CSS, and JavaScript. They're positioned over everything else in the document and remove scroll from the <body> so...
Read more >How to Create Modals with Bootstrap 5
Always try to place your modal HTML in a top-level position in your document, preferably before closing of the <body> tag (i.e. </body>...
Read more >Bootstrap Modal - examples & tutorial
Responsive popup window with Bootstrap 5. Examples of with image, modal position i.e. center, z-index usage, modal fade animation, backdrop usage, ...
Read more >How to pass data into a bootstrap modal?
Bootstrap is a CSS framework used for designing web pages. Bootstrap v4.5 is the latest release. Bootstrap along with HTML and JavaScript ...
Read more >Bootstrap 4 Modals
Complete Bootstrap Modal Reference. For a complete reference of all modal options, methods and events, go to our Bootstrap JS Modal Reference. ❮...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Would implementing this allow us to make the modal draggable with
cdkDrag
when passing a Component to theopen
method? If so, this would be very appreciated.I’m going to leave open this as a feature request. In the end it is generally not a good idea to hide BS markup behind components.