1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/layout/reftests/w3c-css/submitted/flexbox/flexbox-align-self-vert-2-ref.xhtml Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,90 @@ 1.4 +<?xml version="1.0" encoding="UTF-8"?> 1.5 +<!-- 1.6 + Any copyright is dedicated to the Public Domain. 1.7 + http://creativecommons.org/publicdomain/zero/1.0/ 1.8 +--> 1.9 +<!-- Reference case for align-items / align-self behavior, using blocks in 1.10 + place of flex items and using float and width keywords to emulate the 1.11 + align-items / align-self properties. --> 1.12 +<html xmlns="http://www.w3.org/1999/xhtml"> 1.13 + <head> 1.14 + <title>CSS Reftest Reference</title> 1.15 + <link rel="author" title="Daniel Holbert" href="mailto:dholbert@mozilla.com"/> 1.16 + <style> 1.17 + .flexbox { 1.18 + border: 1px dashed blue; 1.19 + width: 200px; 1.20 + float: left; 1.21 + font-size: 10px; 1.22 + } 1.23 + 1.24 + .flex-start, .flex-end, .center, .baseline, .stretch { 1.25 + clear: both; 1.26 + margin: 1px 2px 3px 4px; 1.27 + border-width: 2px 3px 4px 5px; 1.28 + padding: 3px 4px 5px 6px; 1.29 + border-style: dotted; 1.30 + } 1.31 + 1.32 + div.big { 1.33 + font-size: 20px; 1.34 + width: 50px; 1.35 + } 1.36 + 1.37 + /* Classes for each of the various align-self values */ 1.38 + .flex-start { 1.39 + background: lime; 1.40 + float: left; 1.41 + } 1.42 + .flex-end { 1.43 + background: orange; 1.44 + float: right; 1.45 + } 1.46 + <!-- We center shrinkwrapped text by putting it into an inline-block, and 1.47 + then wrapping that inline-block in a helper-div that has 1.48 + "text-align:center" set. --> 1.49 + .centerParent { 1.50 + text-align: center; 1.51 + } 1.52 + .center { 1.53 + background: lightblue; 1.54 + display: inline-block; 1.55 + text-align: left; /* Keep parent's centering from tweaking my text */ 1.56 + } 1.57 + .baseline { 1.58 + background: teal; 1.59 + float: left; 1.60 + } 1.61 + .stretch { 1.62 + background: pink; 1.63 + } 1.64 + .clearFloats { clear: both } 1.65 + </style> 1.66 + </head> 1.67 + <body> 1.68 + <div class="flexbox"> 1.69 + <div class="flex-start">start</div> 1.70 + <div class="flex-start big">a b c d e f</div> 1.71 + <div class="flex-end">end</div> 1.72 + <div class="flex-end big">a b c d e f</div> 1.73 + <div class="clearFloats"></div> 1.74 + <div class="centerParent"> 1.75 + <div class="center">center</div> 1.76 + </div> 1.77 + <div class="centerParent"> 1.78 + <div class="center big">a b c d e f</div> 1.79 + </div> 1.80 + </div> 1.81 + <div class="flexbox"> 1.82 + <div class="baseline">base</div> 1.83 + <div class="baseline big">abc</div> 1.84 + <div class="clearFloats"></div> 1.85 + <div class="stretch">stretch</div> 1.86 + <!-- Force a 3px + 1px = 4px margin between this and the previous div 1.87 + (to thwart the effects of margin-collapsing). This is the only 1.88 + place we need this hack, because everywhere else in this test 1.89 + we use floats or inline-blocks, whose margins don't collapse. --> 1.90 + <div class="stretch big" style="margin-top: 4px">a b c d e f</div> 1.91 + </div> 1.92 + </body> 1.93 +</html>