I have dynamically created divs. For some tests, I go for 30 divs.
Each div got a button bar at the bottom. I just want to show this bar, when hovering the div container.
When hiding these elements, the div gets smaller / is shrinking down. I want to keep this bigger size, so only the buttons are hidden but the container keeps its size.
When leaving the div, only the buttons should disappear.
#wrapper{
padding: 50px;
background-color: red;
}
#content{
color: white;
padding: 10px;
font-size: 20px;
}
#wrapper:hover .btn{
display:block;
}
.btn{
display:none;
}
<div id="wrapper">
<div id="content">
content
</div>
<div>
<button class="btn">
Button 1
</button>
<button class="btn">
Button 2
</button>
<button class="btn">
Button 3
</button>
</div>
</div>