components

Grid & Column

The foundational 12-column layout atoms for strict geometric structure.

The Grid and Column atoms are the bedrock of the Curva & Concreto layout system. They enforce a strict 12-column geometry, ensuring that content aligns cleanly without arbitrary padding values scattered across feature code.

Curva & Concreto

Grids are the ultimate “Concreto”. They establish the invisible sharp lines upon which all other elements rest. They do not have visual boundaries themselves, but they strictly enforce the spatial boundaries of their children.

Basic Usage

By default, <Grid> creates a 12-column CSS Grid container. <Column> spans all 12 columns on mobile, but you can override this for larger breakpoints using sm, md, and lg.

<Grid gap="1rem">
<Column span={12} md={6} lg={4}>
<div style="background: var(--papel-20); padding: 1rem; border-radius: var(--r-1);">Col 1</div>
</Column>
<Column span={12} md={6} lg={4}>
<div style="background: var(--papel-20); padding: 1rem; border-radius: var(--r-1);">Col 2</div>
</Column>
<Column span={12} md={12} lg={4}>
<div style="background: var(--papel-20); padding: 1rem; border-radius: var(--r-1);">Col 3</div>
</Column>
</Grid>
Col 1 (12/6/4)
Col 2 (12/6/4)
Col 3 (12/12/4)

Offsets

You can use the start prop on a Column to offset it within the grid. This is particularly useful for centering content or creating asymmetrical layouts.

<Grid>
<Column span={8} start={3}>
<div style="background: var(--azul-soft); padding: 1rem;">Centered 8-col</div>
</Column>
</Grid>
Centered 8-col via start=3

Semantic Containers

Both Grid and Column accept an as prop to change their underlying HTML element, ensuring you don’t sacrifice document semantics for visual layout.

<Grid as="section">
<Column as="article" span={12}>...</Column>
</Grid>

Props

Grid

NameTypeDefaultDescription
columns number12Number of columns in the grid.
gap string"2rem"Gap between grid items. Uses standard CSS units.
as string"div"HTML element to render. Options: div, section, article, main, form, fieldset.
class string""Additional CSS classes.

Column

NameTypeDefaultDescription
span number12Columns to span on mobile (default).
sm numberundefinedColumns to span on tablet (>= 480px).
md numberundefinedColumns to span on larger tablet (>= 768px).
lg numberundefinedColumns to span on desktop (>= 1024px).
start numberundefinedColumn line to start at (for offsets).
as string"div"HTML element to render.
class string""Additional CSS classes.