-
Notifications
You must be signed in to change notification settings - Fork 746
Description
When discussing the format() specifier with regards to font variations, we came across diverging behavior between different browsers.
There are two possible mechanisms (that I know of) for fallback:
@font-face {
...
src: url("file-novariations.otf") format("opentype");
src: url("file-variations.otf") format("opentype", "variations");
}
and
@font-face {
...
src: url("file-variations.otf") format("opentype", "variations"), url("file-novariations.otf") format("opentype");
}
Currently, with either of the above examples, Edge and Firefox would download the variation font even when though those browsers don't (currently) understand variations.
The spec states:
The format hint contains a comma-separated list of format strings that denote well-known font formats. Conformant user agents must skip downloading a font resource if the format hints indicate only unsupported or unknown font formats.
This seems to imply that the format() identifier will be used if any of the arguments are known. Instead, in order to support modern and future font behaviors, web authors should be able to list the requirements that the browser needs to understand in order to use a font.
This could either be changing how format() works, adding a new specifier, or something completely different.