Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /css/css-images/linear-gradient-sibling-index.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<title>CSS Images Test: Linear gradient with sibling-index()</title>
<link rel="match" href="linear-gradient-sibling-index-ref.html">
<style>
.grad {
width: 100px;
height: 100px;
background: linear-gradient(blue calc(10px * sibling-index()), yellow);
}
</style>
<div>
<div></div>
<div class="grad"></div>
<div></div>
<div></div>
<div class="grad"></div>
</div>