Contents

Margin

The object for defining the space above and below a component.

Declaration

object Margin

Properties

NameTypeDescription
bottom(SupportedUnits | number)

The bottom margin in points, or with any of the units of measure for components. See Specifying Measurements for Components.

top(SupportedUnits | number)

The top margin in points, or with any of the units of measure for components. See Specifying Measurements for Components.

Mentioned in

Discussion

Use the margin object to specify top and bottom margins to designate space above and below a component. For information on the units, see Specifying Measurements for Components.

You can use this object in ComponentLayout and AutoPlacementLayout.

Example

{
  "components": [
    {
      "role": "header",
      "layout": "headerLayout",
      "components": [
        {
          "role": "title",
          "text": "Article Title"
        }
      ]
    }
  ],
  "componentLayouts": {
    "headerLayout": {
      "margin": {
        "top": 50,
        "bottom": 50
      }
    }
  }
}

See Also

Article Layout