Skip to content

[css-values-4][css-color] Addition of <color> is way underspecified. #8576

Closed
@svgeesus

Description

It probably doesn't help that I don't really understand why one would want to add <color>s (as opposed to, say, adding lengths which is obviously useful in an animation or transition). That said, this sentence in V&U4 on Combination of <color> seems underspecified:

Addition of <color> is likewise defined as the independent addition of each component as a <number> in premultiplied space.)

The color space in which addition happens is unspecified. It sounds like this text was written when <color> was always an sRGB value so you add the red, green and blue components.

--one: color(display-p3 0.3 0.6 0.2 / 0.5);
--two: oklch(0.5 0.2 140);

What happens when I add --one and --two, and why.

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

        翻译: