Skip to content

Commit 55979a6

Browse files
committed
[css-color-5] Use reference ranges for lightness and alpha, too #9016
1 parent 70622d0 commit 55979a6

File tree

1 file changed

+22
-11
lines changed

1 file changed

+22
-11
lines changed

css-color-5/Overview.bs

Lines changed: 22 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1075,7 +1075,8 @@ the allowed [=channel keywords=] are:
10751075
that correspond to the [=origin color's=] red, green, and blue channels
10761076
after <a href="#required-conversion">conversion, if required</a> to sRGB.
10771077
255.0 is equivalent to 100%.
1078-
* <dfn value for="rgb()">alpha</dfn> is a <<number>> that corresponds to the [=origin color's=] alpha transparency
1078+
* <dfn value for="rgb()">alpha</dfn> is a <<number>> that corresponds to the
1079+
[=origin color's=] alpha transparency. 1.0 is equivalent to 100%.
10791080

10801081
<div class="example">
10811082
To manipulate color channels in the sRGB color space:
@@ -1143,7 +1144,8 @@ the allowed [=channel keywords=] are:
11431144
HSL saturation and lightness,
11441145
after <a href="#required-conversion">conversion, if required</a> to sRGB.
11451146
100 is equivalent to 100%.
1146-
* <dfn value for="hsl()">alpha</dfn> is a <<number>> that corresponds to the [=origin color's=] alpha transparency
1147+
* <dfn value for="hsl()">alpha</dfn> is a <<number>> that corresponds to the
1148+
[=origin color's=] alpha transparency 1.0 is equivalent to 100%.
11471149

11481150
<div class="example">
11491151
This adds 180 degrees to the hue angle, giving a complementary color.
@@ -1180,7 +1182,8 @@ the allowed [=channel keywords=] are:
11801182
are <<number>>s that correspond to the [=origin color's=] HWB whiteness and blackness
11811183
after <a href="#required-conversion">conversion, if required</a> to sRGB.
11821184
100 is equivalent to 100%.
1183-
* <dfn value for="hwb()">alpha</dfn> is a <<number>> that corresponds to the [=origin color's=] alpha transparency
1185+
* <dfn value for="hwb()">alpha</dfn> is a <<number>> that corresponds to the
1186+
[=origin color's=] alpha transparency. 1.0 is equivalent to 100%.
11841187

11851188
<h3 id="relative-Lab">Relative Lab Colors</h3>
11861189

@@ -1200,12 +1203,14 @@ the allowed [=channel keywords=] are:
12001203

12011204
* <dfn value for="lab()">l</dfn> is a <<number>>
12021205
that corresponds to the [=origin color's=] CIE Lightness
1203-
after <a href="#required-conversion">conversion, if required</a>, to CIE Lab
1206+
after <a href="#required-conversion">conversion, if required</a>, to CIE Lab.
1207+
100 is equivalent to 100%.
12041208
* <dfn value for="lab()">a</dfn> and <dfn value for="lab()">b</dfn> are <<number>>s
12051209
that correspond to the [=origin color's=] CIE Lab a and b axes
12061210
after <a href="#required-conversion">conversion, if required</a>, to CIE Lab.
12071211
125 is equivalent to 100%, while -125 is equivalent to -100%.
1208-
* <dfn value for="lab()">alpha</dfn> is a <<number>> that corresponds to the [=origin color's=] alpha transparency
1212+
* <dfn value for="lab()">alpha</dfn> is a <<number>> that corresponds to the
1213+
[=origin color's=] alpha transparency. 1.0 is equivalent to 100%.
12091214

12101215
<div class="example">
12111216
Multiple ways to adjust the transparency of a base color:
@@ -1250,12 +1255,14 @@ the allowed [=channel keywords=] are:
12501255

12511256
* <dfn value for="oklab()">l</dfn> is a <<number>>
12521257
that corresponds to the [=origin color's=] Oklab Lightness
1253-
after <a href="#required-conversion">conversion, if required</a>, to Oklab
1258+
after <a href="#required-conversion">conversion, if required</a>, to Oklab.
1259+
1.0 is equivalent to 100%.
12541260
* <dfn value for="oklab()">a</dfn> and <dfn value for="oklab()">b</dfn> are <<number>>s
12551261
that correspond to the [=origin color's=] Oklab a and b axes
12561262
after <a href="#required-conversion">conversion, if required</a>, to Oklab.
12571263
0.4 is equivalent to 100%, while -0.4 is equivalent to -100%.
1258-
* <dfn value for="oklab()">alpha</dfn> is a <<number>> that corresponds to the [=origin color's=] alpha transparency
1264+
* <dfn value for="oklab()">alpha</dfn> is a <<number>> that corresponds to the
1265+
[=origin color's=] alpha transparency. 1.0 is equivalent to 100%.
12591266

12601267
<h3 id="relative-LCH">Relative LCH Colors</h3>
12611268

@@ -1275,7 +1282,8 @@ the allowed [=channel keywords=] are:
12751282

12761283
* <dfn value for="lch()">l</dfn> is a <<number>>
12771284
that corresponds to the [=origin color's=] CIE Lightness
1278-
after <a href="#required-conversion">conversion, if required</a>, to CIE LCH
1285+
after <a href="#required-conversion">conversion, if required</a>, to CIE LCH.
1286+
100 is equivalent to 100%.
12791287
* <dfn value for="lch()">c</dfn> is a <<number>>
12801288
that corresponds to the [=origin color's=] LCH chroma
12811289
after <a href="#required-conversion">conversion, if required</a>, to CIE LCH.
@@ -1284,7 +1292,8 @@ the allowed [=channel keywords=] are:
12841292
that corresponds to the [=origin color's=] LCH hue, in degrees,
12851293
after <a href="#required-conversion">conversion, if required</a>, to CIE LCH,
12861294
normalized to a [0, 360] range. 90 is equivalent to 90deg.
1287-
* <dfn value for="lch()">alpha</dfn> is a <<number>> that corresponds to the [=origin color's=] alpha transparency
1295+
* <dfn value for="lch()">alpha</dfn> is a <<number>> that corresponds to the
1296+
[=origin color's=] alpha transparency. 1.0 is equivalent to 100%.
12881297

12891298

12901299
<div class="example">
@@ -1409,7 +1418,8 @@ the allowed [=channel keywords=] are:
14091418

14101419
* <dfn value for="oklch()">l</dfn> is a <<number>>
14111420
that corresponds to the [=origin color's=] Oklab Lightness
1412-
after <a href="#required-conversion">conversion, if required</a>, to Oklch
1421+
after <a href="#required-conversion">conversion, if required</a>, to Oklch.
1422+
1.0 is equivalent to 100%.
14131423
* <dfn value for="oklch()">c</dfn> is a <<number>>
14141424
that corresponds to the [=origin color's=] Oklch chroma
14151425
after <a href="#required-conversion">conversion, if required</a>, to Oklch.
@@ -1418,7 +1428,8 @@ the allowed [=channel keywords=] are:
14181428
that corresponds to the [=origin color's=] Oklch hue, in degrees,
14191429
after <a href="#required-conversion">conversion, if required</a>, to Oklch,
14201430
normalized to a [0, 360] range. 90 is equivalent to 90deg.
1421-
* <dfn value for="oklch()">alpha</dfn> is a <<number>> that corresponds to the [=origin color's=] alpha transparency
1431+
* <dfn value for="oklch()">alpha</dfn> is a <<number>> that corresponds to the
1432+
[=origin color's=] alpha transparency. 1.0 is equivalent to 100%.
14221433

14231434
Because Oklch is both perceptually uniform and chroma-preserving,
14241435
and because the axes correspond to easily understood attributes of a color,

0 commit comments

Comments
 (0)