RamseyInHouse / scut

Sass utilities for the frontend laborer.
https://ramseyinhouse.github.io/scut/
MIT License
769 stars 61 forks source link

Add WOFF2 format to font-face mixin #174

Closed teohhanhui closed 9 years ago

teohhanhui commented 9 years ago

I didn't assemble the docs because there's no Ruby and SASS in my environment (using node-sass/libsass).

Also fixed some glaring mistakes which prevented me from doing npm install and gulp build

davidtheclark commented 9 years ago

I tidied up the build process in 399e2b7fcec1d00b19666c95c714300f76802a45, so now I think the problems you encountered should be gone. I will merge the WOFF2 addition separately. Thanks @teohhanhui!

davidtheclark commented 9 years ago

Yes, you can get it from the generator.

I was hesitant to add it as default still because worried that would cause erroneous lookups for people that don't have woff2 in the stack already? But it shouldn't be a breaking change I think, because the src property is supposed to just move on to the next available source if the file is not found: http://www.w3.org/TR/css3-fonts/#src-desc

Could you confirm that this is not a breaking change --- if you only have woff available, not woff2, it does not break the font loading?

teohhanhui commented 9 years ago

Will do. But I have limited browsers to test on... So no guarantee there. On 17 Jan 2015 22:43, "David Clark" notifications@github.com wrote:

Yes, you can get it from the generator.

I was hesitant to add it as default still because worried that would cause erroneous lookups for people that don't have woff2 in the stack already? But it shouldn't be a breaking change I think, because the src property is supposed to just move on to the next available source if the file is not found: http://www.w3.org/TR/css3-fonts/#src-desc

Could you confirm that this is not a breaking change --- if you only have woff available, not woff2, it does not break the font loading?

— Reply to this email directly or view it on GitHub https://github.com/davidtheclark/scut/pull/174#issuecomment-70369392.

davidtheclark commented 9 years ago

Well, it should be enough to just test on a browser that supports woff --- make sure that if woff2 is not found it falls back to woff just find, without breaking.

teohhanhui commented 9 years ago

Tested OK in Chrome 39

davidtheclark commented 9 years ago

Available in v1.1.0