[css-color] Percent reference ranges do not imply maximum allowed values in color functions #32408
Labels
Content:CSS
Cascading Style Sheets docs
needs triage
Triage needed by staff and/or partners. Automatically applied when an issue is opened.
MDN URL
https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/lab
What specific section or headline is this issue about?
Values: https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/lab#values
What information was incorrect, unhelpful, or incomplete?
What did you expect to see?
It seems there has been some confusion between the percent references ranges for color functions and the max/min allowed values.
I think this is likely incorrect for all color functions but definitely for lab, oklab, ...
There are multiple important concepts.
1: Values can be expressed as both numbers and percentages. Because of this it needs to be specified wat
0%
and100%
map to.2: Values can be bound or unbound and when bound have specified min/max values.
3: Values can be theoretically unbound but still have maximum values which are practically useful.
It seems that the current documentation mixes these aspects and states the corresponding values for
0%
and100%
as bounds. (Or maybe an earlier specification stated these as max/min values?)a
andb
forlab
for example are unbound.Do you have any supporting links, references, or citations?
https://drafts.csswg.org/css-color-4/#specifying-lab-lch
https://drafts.csswg.org/css-color-5/#relative-Lab
Do you have anything more you want to share?
No response
The text was updated successfully, but these errors were encountered: