nix

  • Docs
Docs Menu
  • nix
    • Display
    • Flexbox
    • Float
    • Margin
    • Sizing
    • Padding
    • Position
    • Text
    • Others

Flexbox guide

These properties require display: flex in the parent for working.

Learn flexbox with this guide.

justify-content

CLASSDESCRIPTION
.nix-justify-content_startItems are positioned at the beginning of the container
.nix-justify-content_endItems are positioned at the end of the container
.nix-justify-content_betweenItems are positioned with space between the lines
.nix-justify-content_aroundItems are positioned with space before, between, and after the lines
.nix-justify-content_centerItems are positioned at the center of the container
<div class="nix-justify-content_center"></div>
xxxxxxxxxx
 
1
<div class="nix-justify-content_center"></div>

align-item

CLASSDESCRIPTION
.nix-align-items_stretchItems are stretched to fit the container
.nix-align-items_startItems are positioned at the beginning of the container
.nix-align-items_endItems are positioned at the end of the container
.nix-align-items_centerItems are positioned at the center of the container
.nix-align-items_baselineItems are positioned at the baseline of the container
<div class="nix-align-items_center"></div>
xxxxxxxxxx
 
1
<div class="nix-align-items_center"></div>

align-content

CLASSDESCRIPTION
.nix-align-content_stretchLines stretch to take up the remaining space
.nix-align-content_startLines are packed toward the start of the flex container
.nix-align-content_endLines are packed toward the end of the flex container
.nix-align-content_centerLines are packed toward the center of the flex container
.nix-align-content_betweenLines are evenly distributed in the flex container
.nix-align-content_arroundLines are evenly distributed in the flex container, with half-size spaces on either end
<div class="nix-align-content_center"></div>
xxxxxxxxxx
 
1
<div class="nix-align-content_center"></div>

align-self

CLASSDESCRIPTION
.nix-align-self_stretchThe element is positioned to fit the container
.nix-align-self_autoThe element inherits its parent container's align-items property, or "stretch" if it has no parent container
.nix-align-self_startThe element is positioned at the beginning of the container
.nix-align-self_endThe element is positioned at the end of the container
.nix-align-self_centerThe element is positioned at the center of the container
.nix-align-self_baselineThe element is positioned at the baseline of the container
<div class="nix-align-self_center"></div>
xxxxxxxxxx
 
1
<div class="nix-align-self_center"></div>

flex-direction

CLASSDESCRIPTION
.nix-flex-direction_columnThe flexible items are displayed vertically, as a column
.nix-flex-direction_column-reverseSame as column, but in reverse order
.nix-flex-direction_rowThe flexible items are displayed horizontally, as a row
.nix-flex-direction_row-reverseSame as row, but in reverse order
<div class="nix-flex-direction_column"></div>
xxxxxxxxxx
 
1
<div class="nix-flex-direction_column"></div>

flex-wrap

CLASSDESCRIPTION
.nix-flex-wrap_wrapSpecifies that the flexible items will wrap if necessary
.nix-flex-wrap_nowrapSpecifies that the flexible items will not wrap
.nix-flex-wrap_wrap-reverseSpecifies that the flexible items will wrap, if necessary, in reverse order
<div class="nix-flex-wrap_wrap"></div>
xxxxxxxxxx
 
1
<div class="nix-flex-wrap_wrap"></div>

flex

This defines the size of an element before the remaining space is distributed.

CLASSDESCRIPTION
.nix-flex_autoDefines an automatic size
.nix-flex_0Defines a minimum size
.nix-flex_1Defines all available space
<div class="nix-flex_1"></div>
xxxxxxxxxx
 
1
<div class="nix-flex_1"></div>

order

order defines the order of an element from 0 until 5.

CLASSDESCRIPTION
.nix-order_0Default
......
.nix-order_5
<div class="nix-flex_1"></div>
xxxxxxxxxx
 
1
<div class="nix-flex_1"></div>

Responsive example

CLASSDESCRIPTION
.nix-align-items_center--xs--xs suffix only affects device widths of 768px and lower.
.nix-justify-content_middle--sm--sm suffix only affects device widths of 1024px and lower.
.nix-flex-direction_column--md--md suffix only affects device widths of 1200px and lower.

Contribute on Github! Edit this section.

  • justify-content23 sec read
  • align-item17 sec read
  • align-content23 sec read
  • align-self23 sec read
  • flex-direction15 sec read
  • flex-wrap12 sec read
  • flex10 sec read
  • order6 sec read
  • Responsive example12 sec read
    Copy