SpacedList constructor

SpacedList({
  1. required double spacing,
  2. required List<Widget> children,
  3. double? crossAxisExtent,
  4. Color? color,
})

Creates a Gapped with spacing between regular widgets.

The spacing parameter defines the size of the gap between widgets. It must be non-null and positive.

The optional crossAxisExtent parameter allows you to specify the gap size along the cross axis (e.g., width of gap in a Column).

The optional color parameter is useful for debugging to visualize where gaps are placed.

Implementation

factory SpacedList({
  required double spacing,
  required List<Widget> children,
  double? crossAxisExtent,
  Color? color,
}) =>
    Gapped(spacing: spacing, children: children, crossAxisExtent: crossAxisExtent, color: color);