I have the following HTML and CSS:
h3 {
font-family: Tahoma;
}
p {
width: 300px;
box-shadow: 2px 2px 5px #888888;
border-radius: 12px;
background-color: rgba(255, 255, 0, 1);
}
ul {
list-style-type: none;
}
#main_table {
display: grid;
grid-template-columns: 1fr 1fr 1fr 8fr;
grid-auto-rows: 1fr;
}
#img1 {
background-color: lightblue;
}
li {
border: 1px solid black;
}
#img2 {
background-color: lightgreen;
}
#num1 {
background-color: beige;
}
#text1 {
background-color: pink;
}
<div id="main_table">
<div id="img1">
<ul>
<li> image 1 </li>
<li> image 2 </li>
</ul>
</div>
<div id="img2">
<ul>
<li> image on first row </li>
<li> second row </li>
</ul>
</div>
<div id="num1">
<ul>
<li> 24 </li>
<li> a long entry </li>
<ul>
</div>
<div id="text1">
</div>
</div>
As you can see, the rows of the li are not of equal length.
Solutions here and here say to use grid-auto-rows: 1fr;
, however as you can see in the above code this property is set and yet the rows are not of equal size.