I'm using bootstrap to display a modal dialog and jquery to dynamically show/hide some elements of the modal. The problem I have is that when I show or hide an item the modal immediately resizes. What I'd like to do is have it transition to the new size either with a jquery or css animation.
I tried to accomplish this with css with:
.modal {
flex-grow: 1;
-webkit-transition: all 300ms ease-in-out;
-moz-transition: all 300ms ease-in-out;
-o-transition: all 300ms ease-in-out;
transition: all 300ms ease-in-out;
}
But that didn't work.
Here is an example modal I'm using:
<div id="myModal" class="modal fade" role="dialog">
<div class="modal-dialog">
<div class="modal-content">
<p>A paragraph</p>
</div>
</div>
</div>
Thanks for your help with this-