I want to make something like collage where I have 3 images. First is large on left side and two others smaller which placed in right side one above the other. Key feature is that the first image can have different height
I've used a css grid, but I don't know, how to make row (or content) height in second column to be based on first column, where I have element on 2 rows height.
I've created a fiddle for better understanding https://jsfiddle.net/x0jd2Lcf/, but result is not what I want:
.container {
display: grid;
gap: 16px;
grid-template-columns: repeat(2, min-content);
}
.container img:nth-child(1) {
grid-row: span 2;
}
<div class="container">
<img src="https://via.placeholder.com/246x354" />
<img src="https://via.placeholder.com/164x236" />
<img src="https://via.placeholder.com/164x236" />
</div>
Edit: first image (large, in left column) should not change its size