.badge {
-webkit-transform-style: preserve-3d;
-webkit-perspective: 1000;
position: relative;
}
.back, .front {
position: absolute;
-webkit-backface-visibility: hidden;
-webkit-transition: -webkit-transform 1s ease-in;
width: 100%;
height: 100%;
}
.back {
-webkit-transform: rotateY(180deg);
overflow: hidden;
}
.front {
}
.product-action {
display: inline-block;
}
.product-action:hover .back {
-webkit-transform: rotateY(0deg);
}
.product-action:hover .front {
-webkit-transform: rotateY(-180deg);
}
... 可以,但翻转速度太慢,我可以改变速度吗?
此外,我能否以某种方式增加宽度,使翻盖看起来像一 block 木板而不是一张薄纸? :)
谢谢!
最佳答案
您已经指定了速度:
-webkit-transition: -webkit-transform 1s ease-in;
^^
将其更改为类似0.3s
的内容:http://jsfiddle.net/egEq2/1/
关于animation - CSS 旋转缓慢,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12449591/