Spacing

New

Spacing Tokens

All spacing values in our style guide are derived from the following spacing tokens. Our spacing system is built on an 8pt soft-grid, with a few additional sizes (namely at smaller sizes) added to add flexibility. Whenever you want to add white space between elements, you should use on of these values.

NameValue (px)Value (rem*)VariableUsage Notes
space-000$ref-space-0Zero-value, meant for instances when no space is needed.
space-5020.125$ref-space-50 
space-10040.25$ref-space-100 
space-20080.5$ref-space-200 
space-300120.75$ref-space-300 
space-400161$ref-space-400 
space-500241.5$ref-space-500 
space-600322$ref-space-600 
space-700402.5$ref-space-700 
space-800483$ref-space-800 
space-900563.5$ref-space-900 
space-1000644$ref-space-1000 
space-1100885.5$ref-space-1100 
space-1200966$ref-space-1200 
space-13001288$ref-space-1300 

 

Spacing utility classes

For general layout and utility spacing, a set of utility classes have been implemented to help provide designers flexibility in their layouts while also giving developers an efficient way to apply or update spacing between various elements on the page.

Basic spacing utility classes are static and apply the same across all breakpoints. Spacing utilities only apply to the following CSS rules: margin-top/bottom/left/right/x/y-space padding-top/bottom/left/right/x/y-space

Implementation

Use prefix for classes:

'x' for left and right

'y' for top and bottom

'sm' for mobile

'md' for tablet

'lg' for desktop

Static rules (applies to all breakpoints)

<p class="margin-x-700"></p>
<p class="margin-top-700"></p>

Responsive spacing classes, applies at specific breakpoints only

<p class="margin-top-lg-1200 margin-top-md-900 margin-top-sm-600"></p>

Static and responsive spacing classes, applies at specific breakpoints

<p class="padding-top-200 padding-top-lg-600"></p>