I'm currently working on a 2 by 2 grid layout using flexbox, where the items in the first column are combined together. Check out the setup below:
https://i.sstatic.net/fAhtu.png
Everything looks great in Google Chrome but unfortunately, I've run into an issue with IE11. The image within the flexbox is causing its container to stretch, and despite my efforts to find a solution online, nothing seems to work. It seems like my situation is unique compared to similar problems reported.
This is how it appears in IE: https://i.sstatic.net/5xJIS.png
Could you assist me in identifying what might be causing this problem? I've set up a plunker for you to experiment with your solutions.
CSS:
body {
width: 100%;
}
.element {
display: flex;
flex-direction: row;
width: 100%;
}
.name {
display: flex;
align-items: center;
justify-content: center;
flex: 0 0 100px;
font-weight: bolder;
}
.detail-wrapper {
display: flex;
flex-direction: column;
flex: 1 0 0;
width: 100%;
}
.detail {
display: flex;
flex: 1 0 0;
align-items: center;
justify-content: center;
flex-wrap: wrap;
}
.detail img {
max-width: 100%;
}
.name, .detail {
border: 1px solid;
margin: 8px;
padding: 8px;
text-align: center;
word-break: break-word;
}
HTML:
<div class="element">
<div class="name">name</div>
<div class="detail-wrapper">
<div class="detail">
<img src="https://miro.medium.com/max/1200/1*y6C4nSvy2Woe0m7bWEn4BA.png" />
</div>
<div class="detail">
<a href="#">url</a>
</div>
</div>
</div>