<button class="btn anviz-btn-primary footer-search-btn" data-class=""><i class="footer-icon icon-more_line"></i></button>
<button class="btn anviz-btn-primary footer-search-btn" data-class=""><i class="footer-icon icon-loading"></i></button>
两个字体图标分别在button内部,显示效果为:
样式为:
.footer-search-btn{
width: 40px;
height: 40px;
display: inline-block;
vertical-align: middle;
}
.footer-search-btn .footer-icon{
font-size: 24px;
display: flex;
justify-content: center;
}
动画样式:
.animated-cycle{
-webkit-animation:rotating 1s infinite linear ;
-webkit-transform-origin: center center;
-ms-transform-origin: center center;
transform-origin: center center;
}
@-webkit-keyframes rotating{
0%{
-webkit-transform: rotate(0deg);
-moz-transform: rotate(0deg);
-ms-transform: rotate(0deg);
transform: rotate(0deg);
}
100%{
-webkit-transform: rotate(360deg);
-moz-transform: rotate(360deg);
-ms-transform: rotate(360deg);
transform: rotate(360deg);
}
}
不管我怎么写,在buuton内的字体图标都不会旋转,请问该怎么写呢?谢谢,非常感谢!
想的太复杂了,这样就可以实现动画了