Layouts

Layouts are used to structure the overall layout of your application.

Usage & Examples

Default

Inline LayoutInline text

Grid Layout

Card 1
Card 2
Card 3
Card 4
default.tsx
<Section tone="muted" padded>
            <Container>
              <Stack gap="md">
                <Inline justify="between" align="center">
                  <strong>Inline Layout</strong>
                  <span>Inline text</span>
                </Inline>

                <Grid minColumnWidth="12rem">
                  <p>Grid Layout</p>
                  <Card title="Container">Responsive max-width.</Card>
                  <Card title="Stack">Vertical rhythm.</Card>
                  <Card title="Grid">Auto-fit columns.</Card>
                </Grid>
              </Stack>
            </Container>
          </Section>

Props API

8 props
Columns
Layouts props API
Default
Description
alignLayoutAlignNopropsAlign prop for LayoutPrimitive.
asElementTypeNopropsAs prop for LayoutPrimitive.
childrenReactNodeNopropsContent rendered inside the component.
classNamestringNostylingAdditional CSS class names for the component root.
data-testidstringNotestingTest id used to identify the component in tests.
gapLayoutGapNoprops"md"Gap.
justifyLayoutJustifyNopropsJustify prop for LayoutPrimitive.
testIdstringNopropsTest id used to identify the component in tests.