Skip to main content

CSS Reference

This page lists every CSS grid property, where you can set it in Builderius, and which values the grid builder reads. Use it when you write grid CSS by hand and want to know how the builder will show it.

Paid Feature

The CSS grid builder is available in Builderius Website, Professional and Studio. It is not included in Builderius Community (Free).

How to read the tables: Sidebar is the Styles tab, Canvas is the canvas builder, and CSS only means you set it in the CSS editor or in Advanced styles. A value written in the CSS editor is always kept as written. The grid builder only rewrites a property when you change it.

The Grid​

PropertySidebarCanvasNotes
display: gridLayout → Display → Grid-Shows the grid controls
display: inline-gridDisplay dialogyesSame grid controls and canvas builder as grid
grid-template-columnsColumns cardsheaders, − / +See below
grid-template-rowsRows cardsheaders, − / +See below
grid-template-areasGrid Areas cardsdraw, edit, deleteSee below
grid-auto-flowAuto Flow-row, column, dense, row dense, column dense
grid-auto-columnsAuto Columnsfaint headersAny value
grid-auto-rowsAuto Rowsfaint headersAny value
gapGapcells follow itOne or two values
row-gap, column-gapCSS onlycells follow them
align-itemsAlign items in cells (vertical)-Stretch writes nothing
justify-itemsAlign items in cells (horizontal)-Stretch writes nothing
justify-contentJustify Content-
align-contentAlign Content-
place-items, place-contentCSS only-Not shown in the sidebar
grid, grid-templateCSS only-Shorthands are not read; use the longhands

Grid Items​

PropertySidebarCanvasNotes
grid-columnGrid Child → Auto (span) or Manual (start / end)move grip, span handle
grid-rowGrid Child → Auto (span) or Manual (start / end)move grip, span handle
grid-area with a nameGrid Child → Area-
grid-area with 2 to 4 linesGrid Child → Manualmove gripRewritten as grid-column / grid-row when you edit it
grid-column-start and the other longhandsCSS only-Not shown in the sidebar
align-selfGrid Child → Align Self-
justify-selfGrid Child → Justify Self-
place-selfCSS only-
orderGrid Child → Order-

grid-template-columns and grid-template-rows​

Each value separated by a space at the top level is one track card. Spaces inside () and [] don't split.

You writeCardCanvas
200px, 20rem, 25%, any unitValue with unitone header
1frValue with unitone header
auto, min-content, max-contentValueone header
minmax(200px, 1fr)Size: Min/Maxone header
fit-content(300px), calc(…), clamp(…), min(…), max(…)Value, kept as textone header
var(--size)Value, kept as textone header
repeat(3, 1fr)Repeat: 3three headers: one solid, two dashed
repeat(2, 100px 1fr)Tracks: 100px 1fr, Repeat 2four headers
repeat(auto-fill, minmax(200px, 1fr))Repeat: auto-fillas many headers as fit
repeat(auto-fit, …)Repeat: auto-fitas many headers as fit
repeat(var(--cols, 3), 1fr)Repeat: typedas many headers as the browser makes
var(--grid-cols, 1fr 2fr)one card, kept as textas many headers as the browser makes
[name] between tracksLine name-
none, or nothingno cardsfirst header reads none
subgridone card, kept as textnot editable as tracks
An invalid valuecards, with "This is not valid CSS…"as if nothing were written

These values are all read and written back unchanged:

1fr 1fr 1fr
repeat(3, 1fr)
200px 1fr 2fr
repeat(2, 100px 1fr)
1fr repeat(2, 200px) 1fr
[full-start] minmax(1rem, 1fr) [content-start] minmax(0, 40rem) [content-end] minmax(1rem, 1fr) [full-end]
repeat(auto-fill, minmax(200px, 1fr))
repeat(auto-fit, minmax(min(100%, 250px), 1fr))
repeat(auto-fit, minmax(clamp(200px, 25vw, 320px), 1fr))
fit-content(300px) 1fr
min-content max-content auto
calc(100% / 3 - 1rem) calc(100% / 3 - 1rem) auto
repeat(var(--cols, 3), 1fr)
var(--grid-cols, 1fr 2fr)
subgrid

Line names. Several names on one line are written as one bracket: [content-start main-start]. Several brackets in a row, such as [a] [b] 1fr, are kept as written until you edit that line in the sidebar, which merges them into one.

Empty fields. An empty Value, Min or Max is written as auto.

grid-template-areas​

  • Rows in double or single quotes are both read.
  • ., and any run of dots such as ..., is an empty cell.
  • Only as many rows and columns as the areas reach are written.
  • Overlapping areas are refused.
  • An area that is not a rectangle is invalid CSS. When you save from the grid builder, "a . a" becomes "a a a", and "a b a" is reported as an overlap. This is the one case where hand-written text is not kept.
  • Each area creates the line names name-start and name-end.

grid-column, grid-row and grid-area​

How Grid Child opens an item:

You writeMode
nothing, auto, span 2Auto
grid-column: 2 / 4, 1 / -1, content-start / content-endManual
grid-area: mainArea
grid-area: 2 / 1 / 4 / 3Manual, read as row start / column start / row end / column end
  • A grid-area shorthand wins over grid-column and grid-row, as it does in the browser.
  • Only span with a number is read as a span. A named span, span main, is not shown in Auto.

Where Writes Go​

  • The selector in the selector input, at the breakpoint you are on, in the scope you are on. This is the same as the rest of the Styles tab.
  • Canvas edits to the grid while an item is selected go into the grid's %local% at the current breakpoint.
  • A single Collection item goes into <selector>:nth-of-type(n), where <selector> is %local% or the class in the selector input.

Not Supported​

  • The grid and grid-template shorthands. They work in the browser, but the sidebar doesn't read them. Use the longhands if you want to edit in the sidebar.
  • place-items, place-content, place-self. No controls; use the separate properties.
  • Separate row-gap and column-gap controls. Use gap with two values, or write them in the CSS editor.
  • Editing subgrid tracks. subgrid is kept, but its tracks come from the parent grid and can't be edited here.
  • masonry. Not supported.
  • Named spans (span main) in Auto.

Known Issue​

On the canvas, the span handle does nothing on an item placed with grid-area, either the line shorthand or a named area. Use Grid Child in the sidebar for these items.

Next steps: