Spacing
Spacing helpers are useful for modifying the padding and margin of an element.
How It Works
These classes can be applied using the following format u-{property}{direction}-{size}.
The property applies the type of spacing:
m
- applies margin.p
- applies padding.
The direction designates the side, the property applies to:
t
- applies the spacing formargin-top
orpadding-top
.r
- applies the spacing formargin-right
orpadding-right
.b
- applies the spacing formargin-bottom
orpadding-bottom
.l
- applies the spacing formargin-left
orpadding-left
.h
- applies the spacing for both*-left
and*-right
.v
- applies the spacing for both*-top
and*-bottom
.- If left empty, applies the spacing for the property in all directions. (Ex:
u-p
,u-m
)
The size controls the increment of the property:
xxs
- setsmargin
orpadding
to 4px.xs
- setsmargin
orpadding
to 8px.sm
- setsmargin
orpadding
to 12px.- If left empty, sets
margin
orpadding
to 20px. (Ex:u-pt
,u-mt
) lg
- setsmargin
orpadding
to 32px.xl
- setsmargin
orpadding
to 40px.xxl
- setsmargin
orpadding
to 48px.