Block object

Rendering

Block object

Every block shares the same envelope.

json
{
  "type": "button", // heading | text | image | button | …
  "values": { "label": "Buy", "href": "https://…" }, "visible_if": "plan == 'pro'", // optional display condition
  "mobile_styles": { }, // optional per-device overrides
  "hide_mobile": false
}

Optional fields

Only id, type and values are required. The other fields work the same on every block type:

  • hide_desktop and hide_mobile hide the block above or below the mobile breakpoint (620px unless the design sets body.mobile_breakpoint).
  • mobile_styles and dark_mode_styles are CSS property and value pairs, written into a media query with !important.
  • visible_if is checked only when you render with merge data. An export without merge data keeps the block.
  • display_condition puts its before and after text around the block in the export, for your sending tool to evaluate. See display conditions.
  • Lock flags: locked, content_locked, style_locked, delete_locked and move_locked.

Type names

type is the schema name, which is not always the label in the editor: Menu is navigation, Timer is countdown and HTML is raw-html. The full list is heading, text, image, button, divider, spacer, social, video, raw-html, navigation, form, countdown, gif, table, carousel, file, saved-template, grid, page-break and custom (a registered custom tool). A block with any other type fails validation.

How blocks sit inside rows and columns is on the design object page.