gradient-powerless-hue-hwb.html (1651B)
1 <!doctype html> 2 <html lang="en"> 3 <head> 4 <meta charset="utf-8"> 5 <title>Gradient powerless hue component converting tests - hwb</title> 6 <link rel="author" title="CGQAQ" href="mailto:m.jason.liu@gmail.com"> 7 <link rel="help" href="https://www.w3.org/TR/css-color-4/#interpolation"> 8 <meta name="assert" content="Tests that powerless hue component logic works."> 9 <link rel="match" href="gradient-powerless-hue-hwb-ref.html"> 10 <style> 11 .test { 12 display: flex; 13 align-items: center; 14 width: 200px; 15 height: 50px; 16 position: relative; 17 border: 1px solid black; 18 margin: 10px; 19 } 20 21 .info { 22 position: absolute; 23 right: -10px; 24 transform: translateX(100%); 25 } 26 .hwb { 27 /* Expected */ 28 background-image: linear-gradient(to right in hwb, red, hwb(120deg 0% 0% / 0%) ); 29 30 } 31 .rgba { 32 background-image: linear-gradient(to right in hwb, red, rgba(0, 255, 0, 0) ); 33 } 34 .hsl { 35 background-image: linear-gradient(to right in hwb, red, hsl(120deg 100% 50% / 0%) ); 36 } 37 .color { 38 background-image: linear-gradient(90deg in hwb, red, color(srgb 0 1 0 / 0) ); 39 } 40 </style> 41 </head> 42 <p>They should be the same as the first box.</p> 43 <ol> 44 <li class="test hwb"><div class="info">hwb() Expected</div></li> 45 <li class="test rgba"><div class="info">rgba()</div></li> 46 <li class="test hsl"><div class="info">hsl()</div></li> 47 <li class="test color"><div class="info">color()</div></li> 48 </ol> 49 </html>