I have the code bellow and the following issue:
The image container should be square and have:
height: 5.5rem;
width: 5.5rem;
but this dimensions are not respected.
.slider {
align-items: flex-start;
display: flex;
flex-direction: column;
}
.items {
justify-content: center;
margin: 0 auto;
position: relative;
display: flex;
}
.item {
display: flex;
flex-direction: row;
left: 0;
outline: 0;
top: 0;
opacity: 0;
position: absolute;
visibility: hidden;
z-index: -1;
}
.item.show {
position: relative;
opacity: 1;
visibility: visible;
z-index: 9;
}
.image {
height: 5.5rem;
margin: 0 0.5rem 0 0;
width: 5.5rem;
align-items: center;
padding: .5rem;
display: flex;
border: 1px solid black;
}
.image img {
display: block;
margin-left: auto;
margin-right: auto;
max-height: 100%;
max-width: 100%;
}
}
<div class="slide">
<div class="items">
<div class="item show">
<div class="image">
<img src="https://via.placeholder.com/150">
</div>
<div class="content">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of</div>
</div>
<div class="item">
<div class="image">
<img src="https://via.placeholder.com/150">
</div>
<div class="content">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a software like Aldus
PageMaker including versions of Lorem Ipsu</div>
</div>
</div>
</div>
</div>