Skip to content

[color-5] Serialization of percentages in color-mix() #8564

@tiaanl

Description

@tiaanl

In reference to this section:

<h3 id="serial-color-mix">

The spec doesn't mention anything about serializing the incoming color-mix(), only the result. For color-mix() itself the tests suggest that the percentages on both sides should only be omitted if the author omitted them, otherwise they should be present.

@emilio mentioned that there is also the serializing-css-values section that suggests the percentages could be omitted if they are obvious.

So for example color-mix(in hsl, red 60%, blue 40%) should serialize to color-mix(in hsl, red 60%, blue). This contradicts what is currently in the tests.

As all other browsers (except firefox) is following the current wpt tests, I think we should maybe explicitly mention this in the spec?

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