mix-blend-mode-animation.html (1375B)
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <title>CSS Test: Blended element with animation</title> 5 <link rel="author" title="Mihai Tica" href="mailto:mitica@adobe.com"> 6 <link rel="help" href="https://drafts.fxtf.org/compositing-1/#mix-blend-mode"> 7 <meta name="assert" content="Test checks that an element with mix-blend-mode and animation blends with the parent element."> 8 <meta name="fuzzy" content="0-2;0-11000"> 9 <link rel="reviewer" title="Rik Cabanier" href="mailto:cabanier@adobe.com"> 10 <link rel="reviewer" title="Mirela Budaes" href="mailto:mbudaes@adobe.com"> 11 <link rel="match" href="reference/mix-blend-mode-animation-ref.html"> 12 <style type="text/css"> 13 div { 14 width: 100px; 15 height: 100px; 16 background: #FF0; 17 } 18 19 @keyframes changeOpacity 20 { 21 from { opacity: 0.9; } 22 50% { opacity: 0.9; } 23 to { opacity: 0.1; } 24 } 25 26 #blender { 27 background: #F00; 28 mix-blend-mode: difference; 29 animation: changeOpacity 10s; 30 } 31 </style> 32 </head> 33 <body> 34 <p>Test passes if you can see a fading green box after 5 seconds.</p> 35 <div><div id="blender"></div></div> 36 </body> 37 </html>