Skip to content

Add CSS syntax patch for: absolute-size #1794

Closed

Description

@romainmenke

Link to the definition in the spec

https://drafts.csswg.org/css-fonts-4/#font-size-prop

Syntax of the CSS construct

xx-small | x-small | small | medium | large | x-large | xx-large | xxx-large

Notes

See:

// https://drafts.csswg.org/css2/#value-def-absolute-size
// https://drafts.csswg.org/css2/#value-def-relative-size
// https://drafts.csswg.org/css2/#value-def-shape
"CSS2": {
"<absolute-size>": `
xx-small | x-small | small | medium |
large | x-large | xx-large

I wasn't sure if the patch is incorrect or if maybe the patch should have been overridden by the later definition from css-fonts-4

Activity

  1. tidoust commented on Jan 9, 2026

    @tidoust
    Member

    Oh. So the problem is that the css-fonts-4 spec fails to define the <absolute-type> type properly. It defines the construct as a value instead. That value links back to the definition of <absolute-type> in CSS2, which is incorrect as that version does not have xxx-large.

    If there is a proper type definition in css-fonts-4, it will automatically override the definition in CSS2 in Webref. We'll still need a syntax patch, but that patch will then be for css-fonts-4, and not for CSS2.

    I'll propose an update to css-fonts-4. I'd say it's fine to adjust the syntax patch to add xxx-large in the meantime, even if the patch needs to remain tied to the definition in CSS2 for the time being.

  2. tidoust commented on Jan 12, 2026

    @tidoust
    Member

    Spec was updated. And I was wrong: the syntax in css-fonts-4 can actually be extracted automatically, which means the syntax patch is no longer needed at all. I dropped it.

    New syntax with xxx-large will be released once #1783 can be merged. I'm closing this issue as addressed.

    Note: The spec encloses the syntax in square brackets, which aren't necessary when considering the syntax in isolation. This is not the only case where enclosing square brackets are used. We could try to normalize syntaxes in the curated data if there's a need for it. Sticking to what the spec defines in the meantime.

  3. romainmenke commented on Jan 12, 2026

    @romainmenke
    MemberAuthor

    Thank you @tidoust 🙇

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions