-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Fontawesome 5 error randomly on j5 #42611
Comments
Confirmed. It happens to me too. After clearing the browser cache and reloading the page, everything is back to normal. |
Using Joomla5 since 2 month never happened. System informationPHP Built On Linux lamp302.cloudaccess.net 3.10.0-962.3.2.lve1.5.81.el6h.x86_64 #1 SMP Wed May 31 12:07:35 UTC 2023 x86_64 |
It happens to me quite often as well. Thought it was just me but obviously not |
Does the network tab of the browser's developer tools show something when this happens, or does the browser's error console? |
@brianteeman Is it also with the Chrome browser in your case? Or also with other browsers? |
My colleagues are using firefox and do not face this issue till j5 update. Thought might because chrome and nvidia graphic card. |
I only use Chrome on Windows |
Does it also happen with Joomla 4.4.x? Or only with 5? |
For me just in j5 |
It seems just in J5 |
UPDATE: it also happens on J4 |
Do you have any conflicting Fontawesome installed before updating? |
I cannot replicate - win11 with different browsers but always correct icons. A conflict with former versions could explain the effect |
Maybe the issue is somehow related to the font-display CSS property? Maybe it has something to do with optimizations with Chrome version 83 for handling "font-display: optional" which are mentioned on this page https://web.dev/articles/preload-optional-fonts?hl=en and more detailed handled here: https://bugs.chromium.org/p/chromium/issues/detail?id=1040632 ? |
Unfortunately I can't reproduce it here. |
I can't reproduce it on demand either. Although lats night I did see it twice on a site that was not one of my own. The link you shared about font-display does sound similar |
I cannot reproduce it,
That sounds like the initial load went wrong, and cached version works. Try disable cache:
Do you able to reproduce it every time now? If you able to reproduce then also please look for a response headers for |
I strongly suspect that this is caused by something related to #32141 // Defer fontawesome for increased performance. Once the page is loaded javascript changes it to a stylesheet. |
@brianteeman Yes, I have the same thing in mind. On my private website I have disabled that lazy loading of the fonteawesome fonts in my child template. |
Nope, that PR affecting only frontend, and the issue about admin side. |
Update: chrome on ubuntu also got this issue. |
It’s either:
|
Another thing I would probably try is to use the |
At the time we were doing those optimizations preload wasn’t supported across the board but now should be done, no questions asked |
At least in my case I have observed this with clean joomla installs so that would rule out the plugin or csp and if it works on reload it cant be the mime types |
This comment was marked as outdated.
This comment was marked as outdated.
Please try following, edit Fontawesome css, manualy and place: @charset "utf-8"; at top of each file .css and .min.css:
it looks like Browser get confused with content encoding, randomly. |
@Fedik what's unfortunate here is that when we had Postcss, the Basically if it's a lightningcss issue (ie: parcel-bundler/lightningcss#310) someone could enable debug and check if the problem occurs there as well (the non minified css file is not passed through lightningcss iirc) |
The description in this comment exactly matches my own observations FortAwesome/Font-Awesome#10842 (comment) |
@dgrammatiko it more about sass compiler (or probably both sass and lightning css), this potato removes |
Hi, |
Your with escaped symbols, and joomla with non-escaped. |
Isn’t sass and dart-sass the same package? |
If you use this command to install sass
so it's dart-sass. |
Btw, we use |
I noticed that in the package.json file, but I'm not sure why my compiled CSS is significantly different from Joomla's. |
Okay, it clearly Another links:
@trananhmanh89 what version of sass did you use? |
@Fedik I'm using Dart Sass 1.71.1 on my windows. |
Sorry, it is not Scss (it works fine, and keep the icons escaped) (I have edited my previous comment) |
Possible fix: #42938 Please test it |
I am going to assume this is fixed with #42938. If not, this can be reopened. Thanks for the report. |
No, it's not resolved yet. Please do not use raw utf8 for fontawesome. This causes font issue on chrome. |
@trananhmanh89 how did you tested it? (recent changes) Also, do not trust what browser dev tool shows you, it is not able to render every simbol in dev console. |
Hi, I thought the solution would be using escaped utf8 string instead of raw utf8 to avoid browser issue... |
I just wanted to be sure whether you tested on dev branch of 5.1-dev or not.
It one of possible solutions. So if you able to test on latest 5.1 RC, that would be nice. |
Ok, I asume that adding Checked on package Joomla_5.1.0-rc1-Release_Candidate-Full_Package.zip |
Confirmed. Someone needs to check why (caching, something else?) The npm tools code seems to have the required changes... So maybe the release leader didn't start on a lean branch and didn't run |
This is an issue of the build script, three persons tested now with a clean and fresh checkout. If we run normal npm install, it's included, if we do a So the build script is broken and the mentioned fix did not fix it. |
This can be close since #43207 is merged |
Steps to reproduce the issue
I can't tell, because it happens randomly, and it's gone after several refreshes.
Expected result
Fontawesome should show fine.
Actual result
Check the image
System information (as much as possible)
chrome browser
windows 11
cpu intel i5-8400
nvidia card 1050ti
php82
mysql 80
apache 2.4.52
Additional comments
Does anyone have this issue?
The text was updated successfully, but these errors were encountered: