container-inside-multicol-with-table.html (1077B)
1 <!doctype html> 2 <title>CSS Container Queries Test: container inside multicol with table</title> 3 <link rel="help" href="https://drafts.csswg.org/css-conditional-5/#size-container"> 4 <script src="/resources/testharness.js"></script> 5 <script src="/resources/testharnessreport.js"></script> 6 <script src="support/cq-testcommon.js"></script> 7 <style> 8 #multicol { 9 columns: 2; 10 } 11 .container { 12 container-type: inline-size; 13 width: 100px; 14 } 15 @container (width = 100px) { 16 #t1, #t2 { color: green; } 17 } 18 </style> 19 <div id="multicol"> 20 <div class="container"> 21 <div id="t1"></div> 22 </div> 23 <table> 24 <div class="container"> 25 <div id="t2"></div> 26 </div> 27 </table> 28 </div> 29 <script> 30 setup(() => assert_implements_size_container_queries()); 31 32 const green = "rgb(0, 128, 0)"; 33 34 test(() => { 35 assert_equals(getComputedStyle(t1).color, green); 36 }, "Matching size container inside table inside multicol"); 37 38 test(() => { 39 assert_equals(getComputedStyle(t2).color, green); 40 }, "Matching size container inside multicol with table sibling"); 41 </script>