css: Add tests for relative colors

This commit is contained in:
Matthias Clasen 2024-06-03 18:02:52 -04:00
parent 0524c40640
commit d5e5f47666
3 changed files with 45 additions and 0 deletions

View File

@ -0,0 +1,24 @@
a {
color: color(from rgb(100, 200, 10) srgb g g calc(b * 2));
}
b {
color: oklab(from white l 0.1 0.2);
}
c {
color: red;
background-color: hsl(from currentcolor calc(h + 60) s l);
}
d {
color: oklab(from white r g b);
}
e {
color: rgb(from darkgoldenrod r g 100 / 50%);
}
e {
color: rgb(from rgba(30,40,50,60) r g 100 / alpha);
}

View File

@ -0,0 +1 @@
relative-color.css:15:27-28: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,20 @@
a {
color: color(srgb 0.784314 0.784314 0.0784314);
}
b {
color: oklab(1 0.1 0.2);
}
c {
background-color: hsl(from currentcolor calc(h + 60) s l / alpha);
color: rgb(255,0,0);
}
e {
color: color(from rgb(184,134,11) srgb 184 134 100 / 50%);
}
e {
color: rgb(30,40,100);
}