Build row components

Rows are horizontal layout components. They contain an array of other components and define the location of those components on the page. No components exist outside a row (except page, header, body, and footer).

The following are characteristics of rows:

Note: You can create more than one active version of an invoice template per locale, and use conditional expressions to determine which fields appear on a version of an invoice template. You can only use conditional expressions in templates that you create or that you copy from a marketplace-provided default template. You cannot add conditional expressions to marketplace default templates. For more information, see Build row components.

Prerequisites

You can add row components to header sections, footer sections, or cell components.

Default template JSON sample

In the Appdirect Template_EN_US default template, see lines 205-235.

To download the default template, go to .

Row component JSON schema

{
    "type": "row",
    "style": { },
    "properties": {
        "visible": <true | false>
    },
    "components": [
        {
        // Can contain Components of 'type:cell or horizontalSpacer' only
        }
    ]
}

Elements to populate row components

Element     Type Description
row     object Defines styles and behaviors for a row. Rows can contain cells which can contain content that appears on invoices.
  type   string

Required. Defines the component type as row.

Valid value:

row
  style   object

Required. Defines formatting for the row.

Valid values: HTML element names and CSS styles for the named HTML element.

All HTML styles. Only relevant styles that the Invoice Builder can render appear in the user interface preview and the PDF.

Examples:

"font-size": "9px"
"font-family": "Arial"
  properties   object

Required. Define visibility.

    visible boolean

Required.

Defines whether component appears on invoices.

Valid values:

true | false
  components   array

Required.

Cells and horizontal spacers, both style components, that define the location of content in the row. At least one cell is required.

Valid components:

cell
horizontalSpacer

See:

Build cell components

Build horizontal spacers