我有一个问题,当真棒旋转字体图标



我在旋转字体图标时遇到问题。如果我把它旋转180度,图标就会移动一点。查看屏幕截图。

不旋转

旋转180°

代码:

<i class="fa fa-angle-down icon-show"></i>
.icon-show {
transform: rotate(180deg);
transition: all 0.15s ease-in;
}
.icon-show:hover {
transform: rotate(360deg);
transition: all 0.15s ease-out;
}

.icon-show {
transform: rotate(180deg);
transition: all 0.15s ease-in;
}
.icon-show:hover {
transform: rotate(360deg);
transition: all 0.15s ease-out;
}
<link href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet"/>
<i class="fa fa-angle-down fa-2x icon-show"></i>

最新更新