Commit 31b9d93f authored by Mark Otto's avatar Mark Otto Committed by Mark Otto
Browse files

Enable flex on the .modal-content, ensure .modal-body stretches the height (if needed)

parent c214aa32
Showing with 5 additions and 0 deletions
+5 -0
...@@ -48,6 +48,8 @@ ...@@ -48,6 +48,8 @@
// Actual modal // Actual modal
.modal-content { .modal-content {
position: relative; position: relative;
display: flex;
flex-direction: column;
background-color: $modal-content-bg; background-color: $modal-content-bg;
background-clip: padding-box; background-clip: padding-box;
border: $modal-content-border-width solid $modal-content-border-color; border: $modal-content-border-width solid $modal-content-border-color;
...@@ -94,6 +96,9 @@ ...@@ -94,6 +96,9 @@
// Where all modal content resides (sibling of .modal-header and .modal-footer) // Where all modal content resides (sibling of .modal-header and .modal-footer)
.modal-body { .modal-body {
position: relative; position: relative;
// Enable `flex-grow: 1` so that the body take up as much space as possible
// when should there be a fixed height on `.modal-dialog`.
flex: 1 1 auto;
padding: $modal-inner-padding; padding: $modal-inner-padding;
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment