Skip to main content

Layout

Allows users to create dashboard displays.

🔗 Explore Layouts: Use Cases

Function Parameters​

1. hconcat​

  • Horizontally concatenate a collection of Web elements. Places elements in a row.

Function Signature

app.mosaic(
vg.layouts.hconcat(contents)
)
ParametersDescription
contents (List[Component])A list of components to be horizontally concatenated in a row layout.
*args (Component)Components to be horizontally concatenated in a row layout.

2. hspace​

  • Add horizontal space between elements. If size is a number it is interpreted as a pixel value, otherwise it will be interpreted as a CSS dimension.

Function Signature

app.mosaic(
vg.layouts.hspace(space)
)
ParametersDescription
space (Union[int, float, str])Horizontal space to place between components. Number values indicate screen pixels, and string values may use CSS units (em, pt, px, etc).

3. vconcat​

Function Signature

app.mosaic(
vg.layouts.vconcat(contents)
)
  • Vertically concatenate a collection of Web elements. Places elements in a column.
ParametersDescription
contents (List[Component])A list of components to be vertically concatenated in a column layout.
*args (Component)Components to be vertically concatenated in a column layout.

4. vspace​

Function Signature

app.mosaic(
vg.layouts.vspace(space)
)
  • Add vertical space between elements. If size is a number it is interpreted as a pixel value, otherwise it will be interpreted as a CSS dimension.
ParametersDescription
space (Union[int, float, str])Vertical space to place between components. Number values indicate screen pixels, and string values may use CSS units (em, pt, px, etc).