JSFiddle - React, Tailwind, and code Playground
HTML
<ul>
<li>here's some content</li>
<li>here's some content</li>
<li>here's some content</li>
<li>here's some content</li>
<li class="last"><img src="https://images.unsplash.com/photo-1481349518771-20055b2a7b24?ixlib=rb-4.0.3&ixid=MnwxMjA3fDB8MHxzZWFyY2h8NHx8cmFuZG9tfGVufDB8fDB8fA%3D%3D&w=1000&q=80"></li>
</ul>
CSS
ul {
display: flex;
flex-direction: column;
flex-wrap: wrap;
gap: 20px;
max-width: 600px;
margin: 0;
list-style-type: none;
padding: 0;
height: 80vh;
}
li {
flex: 1;
border: 1px solid black;
}
li.last {
flex-shrink: 0;
height: 100%;
}
img {
width: auto;
height: 100%;
}