Subj.
I have two divs (left and right). And I want to make left div something like main one, and force right div to have the same height as a left one, even if it will have more content (and do overflow: hidden
). I will appreciate if there is a way to make it with css
and html
without js
.
Here is a little snippet, how my markup is looking:
.parent {
display: flex;
flex-direction: row;
align-items: stretch;
}
.children-1 {
width: 66.6%;
background: green;
}
.children-2 {
width: 33.4%;
background: yellow;
}
<div class="parent">
<div class="children-1">
<p>My content</p>
</div>
<div class="children-2">
<p>a lot of content<p>
<p>a lot of content</p>
</div>
</div>