tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

flexbox-align-self-horiz-001-table.xhtml (2818B)


      1 <?xml version="1.0" encoding="UTF-8"?>
      2 <!--
      3     Any copyright is dedicated to the Public Domain.
      4     http://creativecommons.org/publicdomain/zero/1.0/
      5 -->
      6 <!-- Testcase for align-items / align-self behavior, with all the possible
      7     values included on different items within a flex container. -->
      8 <html xmlns="http://www.w3.org/1999/xhtml">
      9  <head>
     10    <title>CSS Test: Testing the various 'align-self' property values on flex items that are tables</title>
     11    <link rel="author" title="Daniel Holbert" href="mailto:dholbert@mozilla.com"/>
     12    <link rel="help" href="http://www.w3.org/TR/css-flexbox-1/#align-items-property"/>
     13    <link rel="match" href="flexbox-align-self-horiz-001-ref.xhtml"/>
     14    <style>
     15      .flexbox {
     16        border: 1px dashed blue;
     17        height: 200px;
     18        display: inline-flex;
     19        font-size: 10px;
     20        line-height: 10px;
     21 
     22        /* Any children whose align-self is 'auto' (or unspecified, or
     23           initial) will end up taking this value from us: */
     24        align-items: center;
     25 
     26        /* Any children whose align-self is 'inherit' will end up
     27           inheriting this value from us: */
     28        align-self: flex-end;
     29      }
     30 
     31      .flexbox > * {
     32        display: table;
     33        width: 40px;
     34      }
     35 
     36      .big {
     37        height: 100px;
     38        font-size: 20px;
     39        line-height: 20px;
     40      }
     41 
     42      /* Classes for each of the various align-self values */
     43      .flex-start {
     44        background: lime;
     45        align-self: flex-start;
     46      }
     47      .flex-end {
     48        background: orange;
     49        align-self: flex-end;
     50      }
     51      .center {
     52        background: lightblue;
     53        align-self: center;
     54      }
     55      .baseline {
     56        background: teal;
     57        align-self: baseline;
     58      }
     59      .stretch {
     60        background: pink;
     61        align-self: stretch;
     62      }
     63      .auto {
     64        background: yellow;
     65        align-self: auto;
     66      }
     67      .unspecified {
     68        background: lightgreen;
     69      }
     70      .initial {
     71        background: aqua;
     72        align-self: initial;
     73      }
     74      .inherit {
     75        background: violet;
     76        align-self: inherit;
     77      }
     78   </style>
     79  </head>
     80  <body>
     81    <div class="flexbox">
     82      <div class="flex-start">start</div>
     83      <div class="flex-start big">a b c d e f</div>
     84      <div class="flex-end">end</div>
     85      <div class="flex-end big">a b c d e f</div>
     86      <div class="center">center</div>
     87      <div class="center big">a b c d e f</div>
     88      <div class="baseline">base</div>
     89      <div class="baseline big">abc</div>
     90      <div class="stretch">stretch</div>
     91      <div class="stretch big">a b c d e f</div>
     92      <div class="auto">auto</div>
     93      <div class="unspecified">unspec</div>
     94      <div class="initial">initial</div>
     95      <div class="inherit">inherit</div>
     96    </div>
     97  </body>
     98 </html>