Skip to content

Flex

Elevate offers a streamlined flexbox experience, with defined properties for both row and column flexbox layouts as well as a large number of supported modifiers to describe flex layouts or adjust flex children as necessary.

Declaring a Flexbox Row in Elevate
<div class = "row">
Declaring a Flexbox Column in Elevate
<div class = "col">


For further convenience, Elevate introduces normalized axes - meaning that you can refer directly to the intended axis without the need to be considerate of flex orientation.


Normalized Axes In Elevate
<div class = "row:x-center:y-start">
X is always horizontal, Y is always vertical

row & col Property Modifiers

The following table describes the supported modifiers for the row and col properties, along with the expected options.

ModifierExpected ValuesExample
X-Axisx-start, x-end, x-center, x-between, x-around, x-evenly, x-stretch, x-baselinerow:x-center
Y-Axisy-start, y-end, y-center, y-between, y-around, y-evenly, y-stretch, y-baselinecol:y-start
Wrapno-wrap, wrap, reverserow:x-start:wrap

row-r & col-r Property Modifiers

The following table describes the supported modifiers for the row-r and col-r (reverse) properties, along with the expected options.

ModifierExpected ValuesExample
X-Axisx-start, x-end, x-center, x-between, x-around, x-evenly, x-stretch, x-baselinerow-r:x-center
Y-Axisy-start, y-end, y-center, y-between, y-around, y-evenly, y-stretch, y-baselinecol-r:y-start
Wrapno-wrap, wrap, reverserow-r:x-start:wrap

child Property Modifiers

The following table describes the supported modifiers for the child property, along with the expected options.

ModifierExpected ValuesExample
Growno-grow, grow, autochild:grow
Shrinkno-shrink, shrinkchild:shrink
Selfstart, end, center, stretch, autochild:auto
Orderorder-{value} (where {value} corresponds to a numeric token)child:order-5
Basisbasis-{value} (where {value} corresponds to a spacing token)child:basis-d5