Statically rotate font-awesome icons

后端 未结 6 1131
说谎
说谎 2021-01-30 06:19

I\'d like to statically rotate my font-awesome icons by 45 degrees. It says on the site that:

To arbitrarily rotate and flip icons, use the fa-rotate-* an

6条回答
  •  情深已故
    2021-01-30 06:43

    In case someone else stumbles upon this question and wants it here is the SASS mixin I use.

    @mixin rotate($deg: 90){
        $sDeg: #{$deg}deg;
    
        -webkit-transform: rotate($sDeg);
        -moz-transform: rotate($sDeg);
        -ms-transform: rotate($sDeg);
        -o-transform: rotate($sDeg);
        transform: rotate($sDeg);
    }
    

提交回复
热议问题