Information for: DEVELOPERS   PARTNERS

Acquia Lightning Layout Library

Note

Layout library is a module used in Acquia Lightning allowing content editors to pick from a list of pre-defined layouts.

Features

Layout library provides the following features:

  • Site builders can create and deploy pre-defined layouts for each entity type and bundle combination.
  • Editors can choose from pre-defined layouts for the way they want content displayed.

Requirements

Layout library has certain installation requirements, and other modules require it for proper operation.

Required by

The following modules require Layout library:

Creating a custom layout

Note

The following example assumes you have existing content types and nodes configured.

To use Layout library to create a custom layout, complete the following steps:

  1. Sign in to your website as a user with Administrator or Site builder permissions.

  2. In the administrator menu, select Structure > Layout Library, and then click +Add layout as shown in the following screenshot:

    Adding a new layout in Layout library

  3. To create your layout, perform the following tasks:

    1. Enter a descriptive Label for your layout, select an Entity type from the list, and Save as shown in the following image:

      Enter a descriptive label and select an entity

    2. A confirmation for the new layout displays. To continue, select Edit layout.

    3. Select + Add Section, and from the far-right slider menu, Choose a layout for this section as shown in the following screenshot:

      Edit and choose from a variety of layouts

      Choose from the following layouts, and configure Column widths, if applicable:

      • One column
      • Two column
      • Three column
      • Four column
      • Three column 25–50–25
      • Three column 33–34–33
      • Moderation Dashboard Layout
    4. After you’ve selected a layout and configured Column widths, click Add section. The slider menu will close, and you can choose to add another section, or click + Add Block to add a custom block or an available block.

      After you’ve finished adding sections and blocks, click Save layout or Discard changes.

  4. To edit your new layout, return to Structure > Layout library, choose the layout you want to edit and then select Edit layout.

Using Layout Builder

For Site builders and Administrators: to build several layout options, you must manage a content type’s main display with Layout Builder:

  1. From Structure > Content types, choose a content type and select Manage display.
  2. Scroll down to Layout Options and select Use Layout Builder.

For Editors: to choose from various custom layouts created by Site builders and Administrators, select Allow content editors to use stored layouts, and Save.

Configure layout options from Manage Display of a content type

When editing a piece of content, an Editor can choose None, choose the default layout provided by Layout Builder, or they can choose from alternative layouts created by the Site builder or Administrator with Layout Library as shown in the following image:

Editors can choose from None or from custom layouts created