Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New test to see if WPT can be used to eval gradients at points
- Loading branch information
Showing
1 changed file
with
27 additions
and
0 deletions.
There are no files selected for viewing
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,27 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<title>Gradient interpolation</title> | ||
<meta name="fuzzy" content="maxDifference=2"/> | ||
<link rel="help" href="https://www.w3.org/TR/css-color-4/#interpolation"> | ||
<meta name="assert" content="A narrow segment of a wide gradient is essentially a single color, allowing for anti-aliasing"/> | ||
<link rel="match" href="../../reference/ref-filled-green-100px-square-only.html"/> | ||
<style> | ||
:root { | ||
--start: #000; | ||
--end: #0F0; | ||
--t: 0.5; | ||
--big: 131070000px; | ||
} | ||
.test { | ||
width: 100px; | ||
height: 100px; | ||
background: linear-gradient(90deg, var(--start) calc(var(--big) * (0 - var(--t))), var(--end) calc(var(--big) * (1 - var(--t)))); | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<p>Test passes if there is a filled green square.</p> | ||
<div class="test"></div> | ||
</body> | ||
</html> |