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

Fix icons issue after migration to font-awesome-rails #8023

Closed
Tlazypanda opened this issue Jun 12, 2020 · 8 comments · Fixed by #8026 or #8041
Closed

Fix icons issue after migration to font-awesome-rails #8023

Tlazypanda opened this issue Jun 12, 2020 · 8 comments · Fixed by #8026 or #8041
Labels
bug the issue is regarding one of our programs which faces problems when a certain task is executed outreachy

Comments

@Tlazypanda
Copy link
Collaborator

Please describe the problem (or idea)

Some icons available in Font Awesome 5.0 are currently used in the application which aren't getting loaded now since font-awesome-rails makes use of v4.7.0.

The icons are as follows and can be replaced by their counterpart of the FA v4.7.0 library instead:-

  • fa-map-marker-alt -> fa-map-marker
  • fa-dot-circle -> fa-dot-circle-o

One more thing noticed in file layouts/_header the bars icons needs to be called as fa fa-bars instead of fas fa-bars

What did you expect to see that you didn't?
Icons not getting loaded

@Tlazypanda Tlazypanda added bug the issue is regarding one of our programs which faces problems when a certain task is executed outreachy labels Jun 12, 2020
@Tlazypanda Tlazypanda added this to the Performance Summer 2020 milestone Jun 12, 2020
@Tlazypanda
Copy link
Collaborator Author

@jywarren Can you point me to the right files for the leaflet map icons? I can't seem to find them in plots2 😅

@jywarren
Copy link
Member

Hi! @icarito sez:

Staging's /system/images folder is setup such that any missing images are pulled from production if not found locally (I did this thru nginx). But images in other directories could be missing.
Let me know if there's another path that should work the same! I see for instance /system/profile/photos could be such an instance...

Hope that helps!!!

@Tlazypanda
Copy link
Collaborator Author

Tlazypanda commented Jun 13, 2020

Hey @jywarren I am not sure if I understand correctly 😅 I have to edit the font awesome icons called that is-

image

The fas fa-map-marker-alt shown here needs to be replaced with fa fa-map-marker since this icon is part of FA 5.0 and not available in v4.7 so I am not sure about the system routes since these are not like images but like <i> tags with the FA icons 😅 I am confused 😕 Am I missing something out here? 😅 Please help!!

@jywarren
Copy link
Member

Ah but you can't find where the HTML is? I wonder if it's actually in the upstream library leaflet-environmental-layers?

@jywarren
Copy link
Member

@jywarren
Copy link
Member

Maybe they're instantiated here and we need to detect fontawesome version?

https://github.com/publiclab/leaflet-environmental-layers

@Tlazypanda
Copy link
Collaborator Author

Tlazypanda commented Jun 13, 2020

Ohh @jywarren so this code wasn't part of plots2 repo at all then 😅 I was so confused looking for it 😆 Have opened a pr here #8026

@Tlazypanda
Copy link
Collaborator Author

Tlazypanda commented Jun 16, 2020

@jywarren Noticed some more issues arising due to the FA 5 being loaded after FA 4.7 thus overwriting some of the css of the icons, have added one more fix here #8041 Sorry for the inconvenience caused 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug the issue is regarding one of our programs which faces problems when a certain task is executed outreachy
Projects
None yet
2 participants