If I have a flexbox that is styled with flex-flow: column, and that container has five child div with variable heights, is it possible to make all the children be the same height as the tallest?
I'm not necessarily looking to fill the container with them (i.e. have them fill any excess space), just all be the same height.
In the snippet below, the five child div all have different content, which causes them to be different heights; is it possible to make all five be as tall as the uppermost div, which has the most content?
html {
font-family: Arial, sans-serif;
}
*,
*:before,
*:after {
box-sizing: border-box;
border: none;
margin: 0;
padding: 0;
}
body {
background: #333;
color: #333;
}
.container {
background: firebrick;
display: flex;
flex-flow: column;
height: 50rem;
margin: 0 auto;
padding: 1rem;
width: 30rem;
}
.panel {
background: white;
padding: 1rem;
}
.panel:nth-child(even) {
background: lightgrey;
}
<div class="container">
<div class="panel">Lorem ipsum dolor sit amet consectetur adipisicing elit. Magnam pariatur commodi ipsum ex quam eius voluptatibus fugit vero, consectetur explicabo cum magni fugiat natus.</div>
<div class="panel">Lorem, ipsum dolor sit amet consectetur adipisicing elit.</div>
<div class="panel">this is a test</div>
<div class="panel">Lorem ipsum dolor sit amet consectetur adipisicing elit. Nulla, commodi a!</div>
<div class="panel">Lorem ipsum dolor sit amet consectetur, adipisicing elit. Saepe, nihil pariatur enim, porro temporibus harum, quo omnis beatae eaque soluta totam ipsa?</div>
</div>