contain-layout-013.html (807B)
1 <!DOCTYPE html> 2 <meta charset=utf-8> 3 <title>CSS Containment Test: Layout containment on table-cell</title> 4 <link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com"> 5 <link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-layout"> 6 <link rel="match" href="../reference/ref-filled-green-100px-square.xht"> 7 <meta name=assert content="Layout containment does apply to table-cell elements."> 8 9 <style> 10 #table-cell { 11 display: table-cell; 12 contain: layout; 13 width: 100px; 14 height: 100px; 15 background: red; 16 } 17 #abspos { 18 position: absolute; 19 bottom: 0; 20 right: 0; 21 background: green; 22 width: 100px; 23 height: 100px; 24 } 25 </style> 26 27 <p>Test passes if there is a filled green square and <strong>no red</strong>.</p> 28 <div id="table-cell"> 29 <div id="abspos"></div> 30 </div>