implicit-nesting-ident-recovery.html (821B)
1 <!DOCTYPE html> 2 <title>CSS Nesting: Nesting, error recovery</title> 3 <link rel="help" href="https://drafts.csswg.org/css-nesting-1/"> 4 <script src="/resources/testharness.js"></script> 5 <script src="/resources/testharnessreport.js"></script> 6 <style> 7 #target1 { 8 display:block; 9 display:new-block; 10 color:green; 11 } 12 #target2 { 13 display:block; 14 display:hover {}; 15 color:green; 16 } 17 </style> 18 <div id=target1>Green</div> 19 <div id=target2>Green</div> 20 <script> 21 test(() => { 22 assert_equals(getComputedStyle(target1).color, 'rgb(0, 128, 0)'); 23 }, 'Unknown declaration does not consume subsequent declaration'); 24 </script> 25 <script> 26 test(() => { 27 assert_equals(getComputedStyle(target2).color, 'rgb(0, 128, 0)'); 28 }, 'Unknown declaration with blocks does not consume subsequent declaration'); 29 </script>