8000 [css-fonts] Specify `generic()` versions of existing generic font families · Issue #10608 · w3c/csswg-drafts · GitHub
[go: up one dir, main page]

Skip to content

[css-fonts] Specify generic() versions of existing generic font families #10608

@LeaVerou

Description

@LeaVerou

Re: https://drafts.csswg.org/css-fonts/#generic-family-name-syntax

It appears we introduced a generic() syntax for new generic font families, but existing generic font families are still only specifiable using keywords.

Specifying them using generic() as well is not only more consistent and more readable, but it would also facilitate feature detection via @supports — which is currently impossible (this post recommends a JS method, but it doesn’t actually work).

Precedent: when we switched to a double colon for future pseudo-elements, we supported both syntaxes for existing pseudo-elements so that authors could eventually move towards that as a convention for all pseudo-elements. It’s the same here: we want authors to eventually move towards generic() for all generic font families.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0