Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Add support for "fa-rotate-by" #454

Open
3 tasks done
darrenhollick opened this issue Oct 6, 2024 · 0 comments
Open
3 tasks done

Feature request: Add support for "fa-rotate-by" #454

darrenhollick opened this issue Oct 6, 2024 · 0 comments

Comments

@darrenhollick
Copy link

darrenhollick commented Oct 6, 2024

Describe the problem you'd like to see solved or task you'd like to see made easier

FontAwesome provides a way to rotate an icon by any custom value. You can add the class fa-rotate-by and then set the CSS variable --fa-rotate-angle. E.g. from https://docs.fontawesome.com/web/style/rotate

<i class="fa-solid fa-snowboarding fa-rotate-by" style="--fa-rotate-angle: 19deg;" ></i>

This doesn't not seem to be possible using the Angular component because the rotate property is set to the type RotateProp which only allows the values which correspond to fa-rotate-90, fa-rotate-180, and fa-rotate-270.

Is this in relation to an existing part of angular-fontawesome or something new?

Existing functionality of the rotate property of FaIcon. I am suggesting a slight change to the accepted values and subsequent behavior. My suggestion is that the rotate property be changed to accept numbers and if the number is 90, 180, or 270 exactly then you can simply add the corresponding fa-rotate-* class but if it's any other number then add the fa-rotate-by class and a style similar to the example given above

What is 1 thing that we can do when building this feature that will guarantee that it is awesome?

Instead of creating a new property such as rotateBy just change the behavior of the current rotate property which shouldn't break anyone's code.

Why would other angular-fontawesome users care about this?

Because it's a part of FontAwesome for web and just not implemented in the Angular components.

On a scale of 1 (sometime in the future) to 10 (absolutely right now), how soon would you recommend we make this feature?

11! Ok, just kidding. I'm going to say 9 since this seems like a super easy change with with good value I would label this change "low hanging fruit", easy to pick. :-)

Feature request checklist

  • This is a single feature (i.e. not a re-write of all of Font Awesome)
  • The title starts with "Feature request: " and is followed by a clear feature name (Ex: Feature request: moar cowbell)
  • I have searched for existing issues and to the best of my knowledge this is not a duplicate
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant