Rows, columns, and grids

Use grid or horizontal stack layout components for side-by-side fields such as city and state or first and last name.

Vertical vs horizontal

LayoutBest for
Stack (vertical)One field per row
Grid / row layoutTwo or more fields on one row

Example: shipping address form

This walkthrough uses a Shipping address form with horizontal Stack rows for name and city fields.

Step 1: Add a horizontal Stack

Components tab open with Stack highlighted in the palette search.Components tab open with Stack highlighted in the palette search.
  1. Open Components.
  2. Search for Stack.
  3. Drag Stack onto the canvas.

Step 2: Set direction to row

  1. Select the row Stack in Tree (for example nameRow).
  2. On Main, set Direction to row.
  3. Set Spacing (for example 16px).

Step 3: Add fields to the row

  1. Drag First name and Last name Text field components into the row Stack.
  2. Add a full-width Street address field below the row.
  3. Add a second horizontal Stack with City, State, and ZIP / Postal.

Step 4: Check the canvas

Components tab selected with shipping address form showing side-by-side fields.Components tab selected with shipping address form showing side-by-side fields.

Step 5: Verify in Tree

Tree tab open with nameRow and cityRow Stacks and their child text fields.Tree tab open with nameRow and cityRow Stacks and their child text fields.

  1. Open TreeExpand all.
  2. nameRow and cityRow should each list their child fields indented underneath.

Test responsive layout

Compare Desktop and Mobile preview so side-by-side fields still read well on narrow screens.

  1. Click Preview.
  2. Click Desktop or Mobile in the header toolbar (next to Preview / Edit).
  3. Confirm fields stack or wrap readably on Mobile.
Desktop preview with arrow pointing at the selected Desktop device button.Desktop preview with arrow pointing at the selected Desktop device button. Mobile preview with arrow pointing at the selected Mobile device button.Mobile preview with arrow pointing at the selected Mobile device button.

Developers: Responsive breakpoints and advanced layout rules are documented in Adaptive layout.

Summary

Use grid or stack components for multi-column rows. Preview the form in Mobile mode after layout changes.

See also