зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1893818 [wpt PR 45941] - [css-color] Tests assume old hsl()/hsla() clipping behavior or depend on unclear gamut mapping to sRGB, a=testonly
Automatic update from web-platform-tests [css-color] Tests assume old hsl()/hsla() clipping behavior or depend on unclear gamut mapping to sRGB (#45941) https://github.com/web-platform-tests/wpt/issues/45814 Removes tests that were assuming the CSS Color 3 rules for hsl()/hsla() where lightness and saturation values outside of 0-100 were clamped to that range. CSS Color 4 states that only saturation below 0 is clamped. To make it clear that only the saturation clamping is being tested, the tests where that is still tested have been renamed to be more clear. -- wpt-commits: fd6e317871ed6baeedfe25b03b79b73eb898d15c wpt-pr: 45941
This commit is contained in:
Родитель
9fbda4f321
Коммит
8e6635b8ce
|
@ -7,29 +7,12 @@
|
|||
td { border: none; padding: 0; height: 1.2em; }
|
||||
</style>
|
||||
<body>
|
||||
<p><strong>WARNING: This test assumes that the device gamut is sRGB
|
||||
(as it will be for many CRT monitors).</strong></p>
|
||||
<p>Every row in this table should have both columns the same color:</p>
|
||||
<table>
|
||||
<tr>
|
||||
<th style="background:white; color: black">Column 1</th>
|
||||
<th style="background:black; color: white">Column 2</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: black"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: black"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: white"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: rgb(0, 0, 255)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: rgb(102, 0, 255)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: rgb(102, 102, 102)"> </td>
|
||||
</tr>
|
|
@ -0,0 +1,37 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>CSS Test: hsl() clamp negative saturation values</title>
|
||||
<link rel="author" title="L. David Baron" href="https://dbaron.org/" />
|
||||
<link rel="author" title="Mozilla Corporation" href="http://mozilla.com/" />
|
||||
<link rel="help" href="https://www.w3.org/TR/css-color-4/#the-hsl-notation" />
|
||||
<link rel="match" href="hsl-clamp-negative-saturation-ref.html" />
|
||||
<meta name="assert" content="Test clamping of negative saturation values in hsl() functions." />
|
||||
<style type="text/css">
|
||||
|
||||
table { border-spacing: 0 2px; padding: 0; border: none; }
|
||||
td { border: none; padding: 0; height: 1.2em; }
|
||||
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Every row in this table should have both columns the same color:</p>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th style="background:white; color: black">Column 1</th>
|
||||
<th style="background:black; color: white">Column 2</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(0, -50%, 40%)"> </td>
|
||||
<td style="background: rgb(102, 102, 102)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(30, -50%, 60%)"> </td>
|
||||
<td style="background: rgb(153, 153, 153)"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -8,29 +8,12 @@
|
|||
td { border: none; padding: 0; height: 1.2em; }
|
||||
</style>
|
||||
<body>
|
||||
<p><strong>WARNING: This test assumes that the device gamut is sRGB
|
||||
(as it will be for many CRT monitors).</strong></p>
|
||||
<p>Every row in this table should have both columns the same color:</p>
|
||||
<table>
|
||||
<tr>
|
||||
<th style="background:white; color: black">Column 1</th>
|
||||
<th style="background:black; color: white">Column 2</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: rgb(102, 102, 102)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: rgb(153, 153, 153)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: white"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: rgb(153, 153, 255)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: rgb(163, 102, 255)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='2' style="background: rgb(194, 194, 194)"> </td>
|
||||
</tr>
|
|
@ -0,0 +1,38 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>CSS Test: hsla() clamp negative saturation values</title>
|
||||
<link rel="author" title="L. David Baron" href="https://dbaron.org/" />
|
||||
<link rel="author" title="Mozilla Corporation" href="http://mozilla.com/" />
|
||||
<link rel="help" href="https://www.w3.org/TR/css-color-4/#the-hsl-notation" />
|
||||
<link rel="match" href="hsla-clamp-negative-saturation-ref.html" />
|
||||
<meta name="assert" content="Test clamping of negative saturation values in hsla() functions." />
|
||||
<style type="text/css">
|
||||
|
||||
body { background: white; color: black; }
|
||||
table { border-spacing: 0 2px; padding: 0; border: none; }
|
||||
td { border: none; padding: 0; height: 1.2em; }
|
||||
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Every row in this table should have both columns the same color:</p>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th style="background:white; color: black">Column 1</th>
|
||||
<th style="background:black; color: white">Column 2</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(0, -50%, 40%, 0.4)"> </td>
|
||||
<td style="background: rgb(194, 194, 194)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(30, -50%, 60%, 0.6)"> </td>
|
||||
<td style="background: rgb(194, 194, 194)"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,60 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>CSS Test: hsl() clipping outside device gamut</title>
|
||||
<link rel="author" title="L. David Baron" href="https://dbaron.org/" />
|
||||
<link rel="author" title="Mozilla Corporation" href="http://mozilla.com/" />
|
||||
<link rel="help" href="http://www.w3.org/TR/css3-color/#hsl-color" />
|
||||
<link rel="match" href="t424-hsl-clip-outside-gamut-b-ref.html" />
|
||||
<meta name="assert" content="Test clipping of hsl() values outside the device gamut." />
|
||||
<style type="text/css"><![CDATA[
|
||||
|
||||
table { border-spacing: 0 2px; padding: 0; border: none; }
|
||||
td { border: none; padding: 0; height: 1.2em; }
|
||||
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p><strong>WARNING: This test assumes that the device gamut is sRGB
|
||||
(as it will be for many CRT monitors).</strong></p>
|
||||
|
||||
<p>Every row in this table should have both columns the same color:</p>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th style="background:white; color: black">Column 1</th>
|
||||
<th style="background:black; color: white">Column 2</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(240, 100%, -100%)"> </td>
|
||||
<td style="background: black"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(240, 75%, -20%)"> </td>
|
||||
<td style="background: black"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(240, 75%, 120%)"> </td>
|
||||
<td style="background: white"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(240, 130%, 50%)"> </td>
|
||||
<td style="background: rgb(0, 0, 255)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(264, 130%, 50%)"> </td>
|
||||
<td style="background: rgb(102, 0, 255)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(0, -50%, 40%)"> </td>
|
||||
<td style="background: rgb(102, 102, 102)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsl(30, -50%, 60%)"> </td>
|
||||
<td style="background: rgb(153, 153, 153)"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,61 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>CSS Test: hsla() clipping outside device gamut</title>
|
||||
<link rel="author" title="L. David Baron" href="https://dbaron.org/" />
|
||||
<link rel="author" title="Mozilla Corporation" href="http://mozilla.com/" />
|
||||
<link rel="help" href="http://www.w3.org/TR/css3-color/#hsla-color" />
|
||||
<link rel="match" href="t425-hsla-clip-outside-device-gamut-b-ref.html" />
|
||||
<meta name="assert" content="Test clipping of hsla() values outside the device gamut." />
|
||||
<style type="text/css"><![CDATA[
|
||||
|
||||
body { background: white; color: black; }
|
||||
table { border-spacing: 0 2px; padding: 0; border: none; }
|
||||
td { border: none; padding: 0; height: 1.2em; }
|
||||
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p><strong>WARNING: This test assumes that the device gamut is sRGB
|
||||
(as it will be for many CRT monitors).</strong></p>
|
||||
|
||||
<p>Every row in this table should have both columns the same color:</p>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th style="background:white; color: black">Column 1</th>
|
||||
<th style="background:black; color: white">Column 2</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(240, 100%, -100%, 0.6)"> </td>
|
||||
<td style="background: rgb(102, 102, 102)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(240, 75%, -20%, 0.4)"> </td>
|
||||
<td style="background: rgb(153, 153, 153)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(240, 75%, 120%, 0.6)"> </td>
|
||||
<td style="background: white"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(240, 130%, 50%, 0.4)"> </td>
|
||||
<td style="background: rgb(153, 153, 255)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(264, 130%, 50%, 0.6)"> </td>
|
||||
<td style="background: rgb(163, 102, 255)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(0, -50%, 40%, 0.4)"> </td>
|
||||
<td style="background: rgb(194, 194, 194)"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="background: hsla(30, -50%, 60%, 0.6)"> </td>
|
||||
<td style="background: rgb(194, 194, 194)"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -390,18 +390,12 @@
|
|||
('hsl-4', 'hsl(-360240, 100%, 50%)', 0,255,0,255, ""),
|
||||
('hsl-5', 'hsl(120.0, 100.0%, 50.0%)', 0,255,0,255, ""),
|
||||
('hsl-6', 'hsl(+120, +100%, +50%)', 0,255,0,255, ""),
|
||||
('hsl-clamp-1', 'hsl(120, 200%, 50%)', 0,255,0,255, ""),
|
||||
('hsl-clamp-2', 'hsl(120, -200%, 49.9%)', 127,127,127,255, ""),
|
||||
('hsl-clamp-3', 'hsl(120, 100%, 200%)', 255,255,255,255, ""),
|
||||
('hsl-clamp-4', 'hsl(120, 100%, -200%)', 0,0,0,255, ""),
|
||||
('hsl-clamp-negative-saturation', 'hsl(120, -200%, 49.9%)', 127,127,127,255, ""),
|
||||
('hsla-1', 'hsla(120, 100%, 50%, 0.499)', 0,255,0,127, ""),
|
||||
('hsla-2', 'hsla( 120.0 , 100.0% , 50.0% , 1 )', 0,255,0,255, ""),
|
||||
('hsla-clamp-1', 'hsla(120, 200%, 50%, 1)', 0,255,0,255, ""),
|
||||
('hsla-clamp-2', 'hsla(120, -200%, 49.9%, 1)', 127,127,127,255, ""),
|
||||
('hsla-clamp-3', 'hsla(120, 100%, 200%, 1)', 255,255,255,255, ""),
|
||||
('hsla-clamp-4', 'hsla(120, 100%, -200%, 1)', 0,0,0,255, ""),
|
||||
('hsla-clamp-5', 'hsla(120, 100%, 50%, 2)', 0,255,0,255, ""),
|
||||
('hsla-clamp-6', 'hsla(120, 100%, 0%, -2)', 0,0,0,0, ""),
|
||||
('hsla-clamp-negative-saturation', 'hsla(120, -200%, 49.9%, 1)', 127,127,127,255, ""),
|
||||
('hsla-clamp-alpha-1', 'hsla(120, 100%, 50%, 2)', 0,255,0,255, ""),
|
||||
('hsla-clamp-alpha-2', 'hsla(120, 100%, 0%, -2)', 0,0,0,0, ""),
|
||||
('svg-1', 'gray', 128,128,128,255, ""),
|
||||
('svg-2', 'grey', 128,128,128,255, ""),
|
||||
# css-color-4 rgb() color function
|
||||
|
|
Загрузка…
Ссылка в новой задаче