Overview

The grid allows content to flexibly adapt by percentages. The number of columns is defined by breakpoints which are based on desktop, tablet and mobile widths.

Grid is a Layout style.


Usage

Grid Structure


Screen Type Breakpoint Columns Gutter
X Small (XS) 0 - 350px 4 16
Small (SM) 360 - 599px 4 16
Medium (MD) 600 - 959px 12 24
Large (LG) 960 - 1439px 12 24
X Large (XL) 1440 - 1920px 12 24

grid anatomy


The Cardinal 1D grid is made up of three elements: Columns, Gutters, and Margins.

Grid Anatomy
  1. Column: Used for basic alignment, these are flexible values used to create the foundation of your content. The number of columns displayed in the grid is determined by the breakpoint for mobile, tablet, or desktop.
  2. Gutter: These are fixed values placed between columns and are set based on the number of columns and width of the screen.
  3. Margin: These are fixed values on each side of the content and are based on the number of columns and width of the screen.

Designing Mobile First


We design mobile first because it is the hardest and should be done first. Once the mobile design questions are answered, designing for other devices are easier. The smallest of the designs will have only the essential features.

Designing Mobile First

Stacked Grids


Grids can be stacked in order to provide the best layout for the user. Diversify content by staggering full width grids with more narrow grids.

Stacked Grids

Nested Grids vs. Spacers


Cardinal guidelines generally promote the use of spacers over deeply nested grids so as to limit complication of the design or code. However, when your content requires more structure that cannot be supported by a single layout grid, you have the nested grid option.

Note:If you are unsure of which to use, consult with a Cardinal developer. See the spacers section for more information.

Flex Grid & Percentages


The flex grid is based on percentages in order to size layouts appropriately. The recommended container is 90% of the screen which allows for the margin and gutter on each side of the device to adjust accordingly.

Flex Grid & Percentages

Do's & Don'ts

Margins at Minimum Breakpoint


Margins at Minimum Breakpoints Don’t define margin widths for Maximum Breakpoints without first defining the minimum margin width at Minimum Breakpoints. This leads to situations like the above, where content breaks off at Minimum Breakpoint, and leads to users missing important information.

Designing for Mobile


Design promotes the use of spacers on mobile instead of aligning to the grid in order to avoid poor user layout.

correct use of mobile design Employ spacers to bring in content away from columns and diversify your layouts.
caution use of mobile design When aligning elements to grid. Margins will become too large or too small, resulting in poor legibility and layout.

Humdrum Grids


Stack mutiple grids to avoid monotonous layouts.

Margins at Minimum Breakpoints Avoid using only one grid on large layouts. This does not promote user retention.