grid-abspos-staticpos-justify-self-rtl-last-baseline-001-ref.html (1532B)
1 <!DOCTYPE html> 2 <!-- 3 Any copyright is dedicated to the Public Domain. 4 http://creativecommons.org/publicdomain/zero/1.0/ 5 --> 6 <html> 7 <head> 8 <meta charset="utf-8"> 9 <title>CSS Reference</title> 10 <link rel="author" title="Daniel Holbert" href="mailto:dholbert@mozilla.com"> 11 <style> 12 .container { 13 display: block; 14 padding: 2px 1px; 15 border: 1px solid black; 16 background: yellow; 17 margin-bottom: 5px; 18 margin-right: 5px; 19 float: left; /* For testing in "rows" of containers */ 20 } 21 br { clear: both } 22 23 .big > .container { 24 width: 30px; 25 height: 22px; 26 } 27 .small > .container { 28 width: 2px; 29 height: 4px; 30 margin-right: 10px; /* To avoid overlap between overflowing kids */ 31 } 32 33 .container > * { 34 background: teal; 35 width: 6px; 36 height: 8px; 37 margin-top: 3px; 38 } 39 .big .alignStart { margin-left: 22px; } 40 .big .alignCenter { margin-left: 15px; } 41 .big .alignEnd { margin-left: 8px; } 42 .small .alignStart { margin-left: -4px; } 43 .small .alignCenter { margin-left: -2px; } 44 .small .alignEnd { margin-left: 0px; } 45 </style> 46 </head> 47 <body> 48 <!-- The last baseline value, from 49 https://www.w3.org/TR/css-align-3/#propdef-justify-self --> 50 <div class="big"> 51 <div class="container"><div class="alignEnd"><!--last baseline--></div></div> 52 </div> 53 <div class="small"> 54 <div class="container"><div class="alignEnd"><!--last baseline--></div></div> 55 </div> 56 </body> 57 </html>