Layout
2.0.2The foundation of the Axis Twelve framework, providing a robust 12-column grid system, flexible flexbox utilities, and spacing/typography defaults.
Installation
Full Bundle (via UNPKG)
<link rel="stylesheet" href="https://unpkg.com/axis-twelve@2.0.2/dist/axis-twelve.min.css">Module Only (via UNPKG)
<link rel="stylesheet" href="https://unpkg.com/axis-twelve@2.0.2/dist/modules/axis-layout.min.css">Class Reference
.ax-gridLayoutThe main grid container. Sets display: grid and a default gap.
.ax-subgridLayoutEnables subgrid support. Inherits parent grid tracks (with 12-col fallback).
.ax-col-{1-12}LayoutColumn span for all screen sizes.
.ax-col-{breakpoint}-{1-12}LayoutResponsive column span (e.g., .ax-col-md-6).
.ax-offset-{0-12}LayoutStarts a column at a specific position.
.ax-containerLayoutCenters content with a responsive max-width.
.ax-flexFlexboxBase flex container.
.ax-justify-centerFlexboxCenters items along the main axis.
.ax-items-centerFlexboxCenters items along the cross axis.
.ax-flex-columnFlexboxSets direction to column.
Breakpoints
sm
576pxmd
768pxlg
992pxxl
1200pxxxl
1400pxKey Features
- ✓Mobile-First approach
- ✓CSS Logical Properties support (LTR/RTL)
- ✓Subgrid utility with fallback
Live Examples
Basic 12-Column Grid
A simple two-column layout.
Preview: Basic 12-Column Grid
Column 1 (4/12)
Column 2 (8/12)
Source Code
html
<div class="ax-grid">
<div class="ax-col-4">Column 1 (4/12)</div>
<div class="ax-col-8">Column 2 (8/12)</div>
</div>Customization
| Variable | Default | Description |
|---|---|---|
--ax-spacing-xs | 0.25rem | Extra small spacing |
--ax-spacing-md | 1rem | Medium spacing (default gap) |
Module Evolution
| Version | Type | Description |
|---|---|---|
| v2.0.2 | Added Utility | Added .ax-subgrid for nested elements to inherit parent grid tracks. |
| v2.0.1 | Internal | Refactored spacing and alignment to use Logical Properties. |