forked from web-platform-tests/wpt
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add reftest for single-stop wrapping (longer hue) gradients with vary…
…ing stop placement. Without the patch, the example gradients are increasingly broken as the stop position advances through the range. Differential Revision: https://phabricator.services.mozilla.com/D231943 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1936569 gecko-commit: 3b9b9357ef56d8ad413f51b6da801e815285a98d gecko-reviewers: gfx-reviewers, lsalzman
- Loading branch information
1 parent
e415e6c
commit 0e89687
Showing
2 changed files
with
62 additions
and
0 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
css/css-images/gradient/gradient-single-stop-longer-hue-hsl-002-ref.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
|
||
<head> | ||
<meta charset="utf-8"> | ||
<title>Gradient in HSL space - reference</title> | ||
<link rel="author" title="Jonathan Kew" href="mailto:jkew@mozilla.com"> | ||
<style> | ||
body { | ||
background: #fff; | ||
} | ||
|
||
div { | ||
width: 200px; | ||
height: 50px; | ||
margin: 10px; | ||
background-image: linear-gradient(to right in hsl longer hue, red 0%, red var(--pos) var(--pos), red 100%); | ||
} | ||
</style> | ||
</head> | ||
|
||
<body> | ||
<div style="--pos: 0%"></div> | ||
<div style="--pos: 25%"></div> | ||
<div style="--pos: 50%"></div> | ||
<div style="--pos: 75%"></div> | ||
<div style="--pos: 100%"></div> | ||
</body> | ||
</html> |
33 changes: 33 additions & 0 deletions
33
css/css-images/gradient/gradient-single-stop-longer-hue-hsl-002.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
|
||
<head> | ||
<meta charset="utf-8"> | ||
<title>Gradient in HSL space</title> | ||
<meta name="fuzzy" content="maxDifference=0-8;totalPixels=0-9050"> | ||
<link rel="author" title="Jonathan Kew" href="mailto:jkew@mozilla.com"> | ||
<link rel="help" href="https://www.w3.org/TR/css-color-4/#interpolation"> | ||
<meta name="assert" content="Tests that a single-stop longer-hue (wrapping) gradient renders as expected for various stop positions"> | ||
<link rel="match" href="gradient-single-stop-longer-hue-hsl-002-ref.html"> | ||
<style> | ||
body { | ||
background: #fff; | ||
} | ||
|
||
div { | ||
width: 200px; | ||
height: 50px; | ||
margin: 10px; | ||
background-image: linear-gradient(to right in hsl longer hue, red var(--pos) var(--pos)); | ||
} | ||
</style> | ||
</head> | ||
|
||
<body> | ||
<div style="--pos: 0%"></div> | ||
<div style="--pos: 25%"></div> | ||
<div style="--pos: 50%"></div> | ||
<div style="--pos: 75%"></div> | ||
<div style="--pos: 100%"></div> | ||
</body> | ||
</html> |