Layout

Stack

Definition

Arranges children vertically or horizontally.

Usage

Use Stack as the default layout primitive for spacing groups of elements.

Attributes

  • direction. vertical or horizontal.
  • gap. Astryx spacing value.
  • justify. start, center, end, between, around, or evenly.
  • align. start, center, end, or stretch.
  • wrap. Allows horizontal children to wrap.

Children

Any rendered XML content.

Example

xml
<Stack direction="horizontal" justify="between" align="center" gap="3">
<Text value="$order.number" />
<Button label="Open" />
</Stack>