Module spacer

Source
Expand description

Spacer component for Tessera UI.

This module provides the spacer component and its configuration struct SpacerArgs. A spacer is an invisible, non-interactive UI element used to insert empty space between other components or to create flexible layouts where certain regions expand to fill available space.

Typical use cases include aligning content within rows or columns, distributing space between widgets, or enforcing minimum gaps in layouts. The sizing behavior is controlled via DimensionValue, allowing both fixed-size and flexible (fill) spacers. This is essential for building responsive and adaptive UIs.

§Examples

  • Add a fixed gap between two buttons in a row.
  • Use a fill spacer to push content to the edges of a container.
  • Combine multiple spacers for complex layout arrangements.

See SpacerArgs and spacer for usage details.

Structs§

SpacerArgs
Arguments for configuring the spacer component.
SpacerArgsBuilder
Builder for SpacerArgs.

Enums§

SpacerArgsBuilderError
Error type for SpacerArgsBuilder

Functions§

spacer
A component that inserts an empty, flexible space into a layout.