First time here, bear with me :)
I've searched numerous times for an answer but nothing I've found actually solved my problem.
I have a div that is overflow-y: scroll; overflow-x: hidden; nested in another div.
The nested div contains other div elements with images that are transform: scale(2); on hover.
Problem is- the items won't breach the "Overflow" definition and are cut by the containing div.
This is how it looks: Image is cut by div
Containing div CSS:
.CatPnl {
position: relative;
background-color: #8BB2C5;
padding: 8px 5px 0px 0px;
height: 200px;
overflow-y: scroll;
overflow-x: hidden;
box-shadow: 2px 1px 4px 1px #053655 inset;}
Inside Element which is scalled up on hover:
.imgItem {
width: 49.6px;
height: 49.6px;
transition: all .2s ease-in-out;
margin: -3px 1px 1px 2px;}
.containdiv:hover> .imgItem {
transform: scale(2);
z-index:9;
}
I've tried z-index on hover, it didn't help so far.
Any help will be appreciated!
position:relativewould break theoverflow:hidden, butposition:absoluteinside aposition:relativesurely would.