block-container-block-end-self-collapsing-children-offsets.html (1116B)
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <link rel="author" title="Sammy Gill" href="mailto:sammy.gill@apple.com"> 5 <link rel="help" href="https://drafts.csswg.org/css-box-4/#margin-trim-block"> 6 <meta name="assert" content="self-collapsing children at end of block with margin-trim block-end should be positioned at the bottom of the block container"> 7 <style> 8 container { 9 display: block; 10 margin-trim: block; 11 margin-block-end: 10px; 12 } 13 item { 14 display: block; 15 margin-block-end: 40px; 16 inline-size: 50px; 17 block-size: 50px; 18 background-color: green; 19 } 20 .collapsed { 21 margin-block-start: 50px; 22 block-size: 0px; 23 } 24 </style> 25 <script src="/resources/testharness.js"></script> 26 <script src="/resources/testharnessreport.js"></script> 27 <script src="/resources/check-layout-th.js"></script> 28 </head> 29 <body onload="checkLayout('container > item')"> 30 <div id="target"> 31 <container> 32 <item data-offset-y="8"></item> 33 <item data-offset-y="58" class="collapsed"></item> 34 <item data-offset-y="58" class="collapsed"></item> 35 </container> 36 </div> 37 </body> 38 </html>