I'm trying to make a simple grid with only 3 images. I'm trying to do it with grid-template-areas but it's not working at all. When I inspect the page, the areas are properly named and placed, but not at all the right sizes. Also, the images don't line up with the areas
Here's my html:
<div class="images">
<a href="#"><div class="image1"><img src="Visuels/Images/CarreRose.jpg"></div></a>
<a href="#"><div class="image2"><img src="Visuels/Images/TextureRose.jpg"></div></a>
<a href="#"><div class="image3"><img src="Visuels/Images/FleurRose.jpg"></div></a>
</div>
And here's the CSS:
img{
min-width: 100%;
min-height: 100%;
object-fit: cover;
}
.images {
display: grid;
grid-template-columns: 1fr 1fr 1fr;
grid-template-rows: 1fr 1fr 1fr;
grid-template-areas: "im3 im1 im1"
"im3 im1 im1"
"im3 im2 im2";
margin-right: 20px;
height:76vh;
width: 76vh;
}
.image1 {grid-area: im1;}
.image2 {grid-area: im2;}
.image3 {grid-area: im3;}
.image1 img{
height: 66vh;
width: 66vh;
}
.image2 img{
height: 32vh;
width: 32vh;
}
.image3 img{
height: 32vh;
width: 32vh;
}
I've only made a CSS grid one time so it's pretty new to me, does anyone know what's happening?
