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

Missing fontawesome icons in 5.0.0-rc.96 #5895

Closed
CaptainGlac1er opened this issue Nov 4, 2024 · 3 comments
Closed

Missing fontawesome icons in 5.0.0-rc.96 #5895

CaptainGlac1er opened this issue Nov 4, 2024 · 3 comments
Assignees

Comments

@CaptainGlac1er
Copy link

Describe the bug
In the form builder a couple icons are missing.
The remove button is currently trying to use fa-remove (which doesn't exist) maybe is suppose to use fa-trash?
The move button is currently trying to use fa-arrows (which only exists for PRO) maybe is suppose to use fa-arrows-alt for 5.x fontawesome or fa-arrows-up-down-left-right for fontawesome 6.x?

Version/Branch
5.0.0-rc.96

To Reproduce
Steps to reproduce the behavior:
Use: "@fortawesome/fontawesome-free": "^5.15.4"

  1. Create form
  2. Add component
  3. Hover to see buttons in the top right

Expected behavior
See all buttons icons

Screenshots
image

@blakekrammes
Copy link
Contributor

blakekrammes commented Jan 15, 2025

The form builder for formio.js 5.x uses bootstrap 5 by default, which includes its own icon library (bootstrap icons). Although, it looks like we still have fontawesome 4 classes on our bootstrap 5 templates in addition to the bootstrap icon classes. You are welcome to take a look at our template repo and make a PR that supports fontawesome 5. https://github.com/formio/bootstrap

@CaptainGlac1er
Copy link
Author

Ah so stuff like fa-times here is just legacy fontawesome 4?
https://github.com/formio/bootstrap/blob/5a2451899db1ebf59fc09cd16fe60b5b566ffb11/src/templates/bootstrap5/address/form.ejs#L14
What if you want to use bootstrap 5 classnames but use fontawesome for icons? If that were to be created would it be bootstrap5-fontawesome5?

@blakekrammes
Copy link
Contributor

blakekrammes commented Jan 16, 2025

Yes. And while you could create a new global template, a better solution would probably be overriding the specific template(s) that are causing you grief: https://help.form.io/developers/form-development/form-templates#overriding-templates.

And I believe this is the template you'd want to override https://github.com/formio/bootstrap/blob/5a2451899db1ebf59fc09cd16fe60b5b566ffb11/src/templates/bootstrap5/builderComponent/form.ejs

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

4 participants