For the complete documentation index, see llms.txt. This page is also available as Markdown.

The section & block model

How Analog builds pages from sections, blocks, and nested container blocks, and when to use a purpose-built section.

Every Analog page is a stack of sections. Sections hold blocks, and container blocks hold more blocks. Once you know those three parts, you can read any section in the theme.

Sections, blocks, and containers

A layout is a tree. A section holds blocks, and a container block holds child blocks at any depth. Product pages, heroes, and footers all use this structure.

The three primitives

Primitive
What it is
Notes

Section

A full-width band on the page. You add, reorder, and remove sections on a template.

Sets page-level width, vertical spacing, and a color scheme for its blocks.

Block

A piece of content inside a section, such as text, an image, a button, a product card, or a form input.

In source these are files prefixed with _ (for example _inline-text, _accordion).

Container block

A block whose only job is to hold and arrange other blocks.

Containers make layouts trees instead of flat lists.

A leaf block renders content. A container arranges its child blocks. Containers can hold other containers, so the layout can be nested as deeply as needed:

Section (Custom)
├─ Section title
└─ Accordions              ← container
   ├─ Accordion            ← container
   │  └─ Rich text         ← leaf
   └─ Accordion            ← container
      └─ Text              ← leaf

Settings follow the tree. A section value applies to every block inside it until a child block sets its own value. See Global settings & local overrides.

The container blocks

The container blocks are "Flexbox" for freeform layout, "Row" for a horizontal strip, "Frame" for layered content, "Text group" for text, "Grid auto" and "Grid editorial" for grids, and "Accordions" and "Tabs" for disclosure. See Layout blocks for their settings.

Reach for the purpose-built section first

Use a purpose-built section when one matches the content. It already handles the details that are easy to miss when rebuilding it: sliders break out of their container on mobile, page margins shrink on small screens, and card text keeps a minimum inset when the card gap is zero.

Situation
Reach for

Selling a product

Hero or promo banner

A banner section ("Banner layers" when you need stacked content)

Media beside text

Collection or product strip

Bespoke editorial content

Don't rebuild existing sections

The Custom section includes every container and leaf block. Use it for editorial content that doesn't fit another section. Don't use it to rebuild a product layout or hero that Analog already includes. You would need to recreate its spacing, responsive behavior, and component wiring, and the copy will still behave differently from the built-in section.

The model branches into the Building pages:

See also

Last updated

Was this helpful?