@@ -1447,13 +1447,13 @@ The Oklch chroma has dropped from 0.251 to 0.117.
14471447</div>
14481448
14491449<!--
1450- ██████ ███████ ██ ███████ ████████ ███ ███
1451- ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
1452- ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
1453- ██ ██ ██ ██ ██ ██ ████████ ██ ██
1454- ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
1455- ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
1456- ██████ ███████ ████████ ███████ ██ ██ ███ ███
1450+ ██████ ███████ ██ ███████ ████████ ███ ███
1451+ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
1452+ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
1453+ ██ ██ ██ ██ ██ ██ ████████ ██ ██
1454+ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
1455+ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
1456+ ██████ ███████ ████████ ███████ ██ ██ ███ ███
14571457-->
14581458
14591459<h2 id="color-function">
@@ -1603,6 +1603,20 @@ the allowed [=channel keywords=] are:
16031603 parsing/color-computed-relative-color.html
16041604 </wpt>
16051605
1606+ <div class="example" id="ex-RCS-XYZ">
1607+ For example, Relative Color Syntax in the CIE XYZ D65 colorspace
1608+ is used to generate a color which has exactly half the luminance
1609+ of the base color:
1610+
1611+ <pre class="lang-css">
1612+ --base: <span class="swatch" style="--color: rgb(73.58% 48.92% 10.45%)"></span> color(display-p3 0.7 0.5 0.1);
1613+ --dark: <span class="swatch" style="--color: rgb(53.617% 35.186% 6.4237%)"></span> color(from var(--base) xyz-d65 calc(x/2) calc(y/2) calc(z/2));
1614+ </pre>
1615+
1616+ The origin color is color(xyz-d65 0.281 0.253 0.044)
1617+ and so the relative color is color(xyz-d65 0.14 0.126 0.022).
1618+ </div>
1619+
16061620<h3 id="custom-color">
16071621 Custom Color Spaces
16081622</h3>
0 commit comments