Flex

The default styling for flexbox is:

.flex {
  display: flex;
  gap: var(--cn-gap);
  flex-wrap: wrap;
  align-items: flex-start;
}

Atomics

We do provide a set of atomic classes to help you with flexbox layouts. These classes follow the best-practice naming conventions from Tailwind CSS.

ClassDescription
flexThis class sets display: flex; on the element.
flex-rowThis class sets flex-direction: row; on the element.
flex-colThis class sets flex-direction: column; on the element, and width: 100% to all direct children
flex-no-wrapThis class sets flex-wrap: nowrap; on the element.
growThis class sets flex-grow: 1; on the element.
shrinkThis class sets flex-shrink: 1; on the element.