关于css旋转动画
来源:动视网
责编:小OO
时间:2020-11-27 15:39:17
关于css旋转动画
a{text-align:center;line-height:100px;transition:all 2s;width:100px;height:100px;background:pink;float:left;border-radius:50%;} a:hover{ transition:all 2s;background:red;transform-origin:50 100;transform:rotate(360deg);border-radius:50%;}请将鼠标移动到下面的矩形上: 两秒旋转360。
导读 a{text-align:center;line-height:100px;transition:all 2s;width:100px;height:100px;background:pink;float:left;border-radius:50%;} a:hover{ transition:all 2s;background:red;transform-origin:50 100;transform:rotate(360deg);border-radius:50%;}请将鼠标移动到下面的矩形上: 两秒旋转360。

我们可以通过css来做出动画效果,下面我为大家演示的是div的旋转,颜色过渡的动画
效果自己测试,很绚丽哦
关于css旋转动画
a{text-align:center;line-height:100px;transition:all 2s;width:100px;height:100px;background:pink;float:left;border-radius:50%;} a:hover{ transition:all 2s;background:red;transform-origin:50 100;transform:rotate(360deg);border-radius:50%;}请将鼠标移动到下面的矩形上: 两秒旋转360。