跳到主要内容

side-by-side

side-by-side(source)

A simple wrapper around grid that creates a single-row grid. Used as the default composer for multi-body slides. Alias for cols.

Example: side-by-side(gutter: 1em)[a][b][c] will display a, b, and c side by side.

Parameters

columns : auto | array

The column widths. Default is auto, which creates equal-width columns matching the number of bodies.

gutter : length

The space between columns. Default is 1em.

lazy-layout : bool

When true, wraps the grid with lazy-layout so that lazy-v markers inside the bodies are resolved correctly. Default is true.

bodies : content

The contents to display side by side.

Returns: content