Flexible Box Model



Tom Janssens & Stian Didriksen
CSS Flexible Box Layout Module

The children of a box are laid out either:
 ● horizontally
 ● vertically

Unused space can be assigned to:
 ● particular child
 ● distributed among the children

Nest boxes to build layouts:
 ● horizontal inside vertical
 ● vertical inside horizontal
What about ...

              Floats
Where we're going, we don't need floats



          Calculations
   Browser will do the calculations
Properties

New display property:
 ● display: box

8 new properties:
  ● box-orient
  ● box-pack
  ● box-align
  ● box-flex
  ● box-flex-group
  ● box-ordinal-group
  ● box-direction
  ● box-lines
Live demo!

Flexible Box Model

  • 1.
    Flexible Box Model TomJanssens & Stian Didriksen
  • 2.
    CSS Flexible BoxLayout Module The children of a box are laid out either: ● horizontally ● vertically Unused space can be assigned to: ● particular child ● distributed among the children Nest boxes to build layouts: ● horizontal inside vertical ● vertical inside horizontal
  • 3.
    What about ... Floats Where we're going, we don't need floats Calculations Browser will do the calculations
  • 4.
    Properties New display property: ● display: box 8 new properties: ● box-orient ● box-pack ● box-align ● box-flex ● box-flex-group ● box-ordinal-group ● box-direction ● box-lines
  • 5.