CSS3图像在带过渡的悬停状态下超出圆形div
为什么图像在CSS3图像在带过渡的悬停状态下超出圆形div,css,transition,Css,Transition,为什么图像在overflow:hiddendiv onhover,如何修复此错误 例: 注意:chrome有问题 通过在img中添加边界半径来解决此问题。我不确定这是不是你想要的。请评论这件事与否 a { width: 100px; height: 100px; background: #000; display: block; border: 2px solid #000; border-radius: 50%; overflow: hi
overflow:hidden
div onhover,如何修复此错误
例:
注意:chrome有问题
通过在img中添加边界半径来解决此问题。我不确定这是不是你想要的。请评论这件事与否
a {
width: 100px;
height: 100px;
background: #000;
display: block;
border: 2px solid #000;
border-radius: 50%;
overflow: hidden;
}
img {
max-width: 100%;
-webkit-transition: opacity 0.1s linear;
-moz-transition: opacity 0.1s linear;
-o-transition: opacity 0.1s linear;
transition: opacity 0.1s linear;
border-radius: 50%;
}
img:hover {
opacity: 0.5;
}