-
Notifications
You must be signed in to change notification settings - Fork 56
Icons don't load in iOS + Some IEs under certain conditions #6
Comments
Did you run these tests using the newest code? The options.error bug was fixed 2 days ago: 1cdcf87 However, I’m guessing that was not the root cause of your issue. I looked into this a little and the stock Hm, can you try updating and running the test again? I think there is a bug with the font measurement. The other thing you can try is adding more characters to your test string (the second argument): |
Thanks for the quick reply. http://circa-79.com/afontgarde-test-2/icon-test.html (Works) For 'icon-test-2.html' I added every single glyph font in my font to the test string as well. BTW, the icons will work for some reason if I add the test string twice. Have you tried adding a custom icon to your icomoon font, adding more icons or changing the name of the font? |
I'm also having problems with IE 8, 9, 10, 11. You can see my testpage here: Or download it here: Don't really know what TOLERANCE is. But setting TOLERANCE = 1 makes it work... Please look into this! |
This seem to fix it (in afontgarde.js):
I added line-height:normal; |
+1 adding |
@adjohnson916’s upstream fixes to fontfaceonload have been merged into the https://github.com/filamentgroup/a-font-garde/releases/tag/v0.1.5 release. Please reopen if the issue persists. |
Note: I'm using fonts generated in http://icomoon.io/app/
So I get the following error in iOS 6.0 and above:
[Error] TypeError: 'undefined' is not a function (evaluating 'options.error()')
checkDimensions (afontgarde.js, line 80)
(anonymous function) (afontgarde.js, line 83)
I don't know much Javascript but I was able to narrow down what causes it to fail by changing certain conditions:
line-height
(any value) on thehtml
element causes the JS error and therefore class is not added tohtml
In this case, when I remove the
line-height
attribute I get no error, the class is added and icons load just fine:http://circa-79.com/afontgarde-test/icon-test.html
When I add
line-height
back in the error happens and the icons do not load:http://circa-79.com/afontgarde-test/icon-test-2.html
http://circa-79.com/afontgarde-test/icon-test-3.html
Using Browserstack I did other tests and all three example pages were failing in IE 8. In IE 9 and 10 example 2 and 3 failed.
It's a weird one for sure. I've spent way too much time trying to figure this out so I finally gave and posted it here. Hope it's not something simple I missed as is usually the case :)
The text was updated successfully, but these errors were encountered: