I have a two column layout with flexbox and flex-wrap: wrap
set on the parent of the columns. However the columns are not wrapping even though the contents are clearly wider than the width percentage that the column is set to. How do I get the column to wrap when the contents are wider than the percentage width?
.wrapper {
display: flex;
flex-wrap: wrap;
height: 100px;
width: 300px;
}
.left {
width: 60%;
background-color: lightblue;
}
.right {
width: 40%;
background-color: lightcoral;
}
<div class="wrapper">
<div class="left">
<table><tbody>
<tr><td>Column 1</td><td>Column 2</td><td>Column 3</td><td>Column 4</td></tr>
</tbody></table>
</div>
<div class="right"></div>
</div>