Marigold
Marigold

Application

MarigoldProvider
RouterProvider

Layout

AppLayoutbeta
Aside
Aspect
Breakout
Center
Columns
Container
Grid
Inline
Inset
Scrollable
Split
Stack
Tiles

Actions

ActionBaralpha
Button
Link
LinkButton
ToggleButtonalpha
ToggleButtonGroupalpha

Form

Autocomplete
Calendarupdated
Checkbox
ComboBox
DateField
DatePicker
FileField
Form
Multiselectdeprecated
NumberField
Radio
SearchField
Select
Slider
Switch
TagFieldbeta
TextArea
TextField
TimeField

Collection

SelectList
Tableupdated
Tag

Navigation

Accordion
Breadcrumbs
Pagination
Sidebarbeta
Tabs
TopNavigationbeta

Overlay

ContextualHelp
Dialog
Drawer
Menu
Toastbeta
Tooltip

Content

Badge
Card
Divider
EmptyStatebeta
Headline
Icon
List
Loader
SectionMessage
SVG
Text

Formatters

DateFormat
NumericFormat

Hooks and Utils

cn
cva
extendTheme
parseFormData
useAsyncListData
useListData
useResponsiveValue
useTheme
VisuallyHidden
Components

Tiles

Organize the content in tiles of equal width.

The <Tiles> is a layout component which is based on CSS grid system.

Usage

<Tiles> serves as a versatile container, ideal for constructing panels, cards, lists, and other content components that organize and group information. They automatically wraps children to a new line if the space given is not enough to show the <Tiles> in one row.

It's possible to display the items with some spacing through space prop or set a minimum width for all items inside <Tiles> with tilesWidth prop.

Grand Avenue Ballroom

Grand Avenue Ballroom

An elegant ballroom with crystal chandeliers and a full proscenium stage, ideal for gala dinners, award nights, and concerts.
Maple Court Theatre

Maple Court Theatre

A comfortable mid‑size theatre with raked seating and modern AV, designed for comedy, theatre, and lectures.
Broadway Community Center

Broadway Community Center

A multipurpose community center with flexible rooms and a small auditorium for talks, classes, and local performances.
Hillcrest Open Pavilion

Hillcrest Open Pavilion

An open‑air pavilion with a covered stage and movable seating, set in a hillside park for fairs and seasonal shows.
Bloomfield Garden Lawn

Bloomfield Garden Lawn

A landscaped garden lawn with power access and tent options, great for large outdoor receptions and summer series.
import { venues } from '@/lib/data/venues';import { Card, Headline, Stack, Text, Tiles } from '@marigold/components';export default () => (  <Tiles tilesWidth="200px" space={2}>    {venues.slice(5).map(venue => (      <Card key={crypto.randomUUID()} p={4}>        <Stack space={2} alignX="center">          <img src={venue.image} alt={venue.name} width={200} height={200} />          <Headline level={3}>{venue.name}</Headline>          <Text>{venue.description}</Text>        </Stack>      </Card>    ))}  </Tiles>);

Equal heights

If you need to have the items in the <Tiles> take the same height, you can use the equalHeight property, which is a boolean value that can be used to size the items of the <Tiles>. In this case, all items adopt the size of the largest card, making it essential when you want all items to match the largest child's dimensions.

import { Card, Tiles } from '@marigold/components';import { Rectangle } from '@/ui/Rectangle';export default () => (  <Tiles space={1} tilesWidth="200px" equalHeight>    <Card>      <Rectangle height="100px" />    </Card>    <Card>      <Rectangle height="100px" />      <Rectangle height="100px" />    </Card>    <Card>      <Rectangle height="100px" />    </Card>  </Tiles>);

Stretch width

Using the stretch property will make the tiles fully responsive. Meaning, they will distribute available width between them while not getting smaller than the given tilesWidth.

import { useState } from 'react';import { Card, Stack, Switch, Tiles } from '@marigold/components';import { Rectangle } from '@/ui/Rectangle';export default () => {  const [stretch, setStretch] = useState(false);  return (    <Stack space={2}>      <Switch label="Toggle stretch" onChange={() => setStretch(!stretch)} />      <Tiles space={2} stretch={stretch} tilesWidth="100px">        <Card p={2}>          <Rectangle height="100px" />        </Card>        <Card p={2}>          <Rectangle height="100px" />        </Card>        <Card p={2}>          <Rectangle height="100px" />        </Card>        <Card p={2}>          <Rectangle height="100px" />        </Card>      </Tiles>    </Stack>  );};

Props

Did you know? You can explore, test, and customize props live in Marigold's storybook. Watch the effects they have in real-time!
View Tiles stories

Tiles

Prop

Type

Alternative components

  • Columns: It should be noted that <Tiles> is used for children with the same width. If you want to set different widths for the children use <Columns> instead.

  • Grid: If you need more custom control over the layout, you should use <Grid> component instead.

Related

Building layouts

Learn how to build layouts.
Last update: 18 days ago

Stack

Display children vertically with giving space between.

ActionBar

Used for single and bulk actions

On this page

UsageEqual heightsStretch widthPropsTilesAlternative componentsRelated