datui
Color scheme

Layout

Group

Content section — card or plain — with header, description and separators between siblings.

import { Group, GroupContainer, GroupHeader, GroupDescription, GroupExpandedContent } from "datui";

Playground

<Group mode="card" padding="m" separator="auto" />

Examples

Groups

Contact

Phone: +1 555 0100
Email: mia@example.com
Only friends can see this.

Plain group

OneTwoThree

Accessibility

  • Renders <section> labelled by its header via aria-labelledby (unless you pass aria-label).
  • role="tabpanel" gets tabIndex=0 automatically.
  • Sibling separators are aria-hidden.

API

Group

Content section — a card or a plain block — with header, description and dividers between siblings.

PropTypeDefaultDescription
asElementType<any, keyof IntrinsicElements>section
classNamestring—
descriptionReactNode—Footnote after the content.
headerReactNode—Usually a `Header`. Labels the section via `aria-labelledby`.
modeGroupMode—`card` is a rounded surface, `plain` is flush. Auto: `card` at regular width, `plain` on compact screens.
padding"s" | "m"mVertical padding inside a card.
separator"auto" | "show" | "hide"autoDivider after the group: `auto` between siblings only, `show` always, `hide` never.

GroupContainer

The group surface without header/description slots. `role="tabpanel"` makes it focusable.

PropTypeDefaultDescription
asElementType<any, keyof IntrinsicElements>section
classNamestring—
modeGroupMode—`card` is a rounded surface, `plain` is flush. Auto: `card` at regular width, `plain` on compact screens.
padding"s" | "m"mVertical padding inside a card.
separator"auto" | "show" | "hide"autoDivider after the group: `auto` between siblings only, `show` always, `hide` never.

GroupHeader

Wrapper for the group's `Header`.

PropTypeDefaultDescription
classNamestring—

GroupDescription

Footnote under the group content.

PropTypeDefaultDescription
classNamestring—

GroupExpandedContent

Content that runs edge to edge inside the group, e.g. a horizontal scroller.

PropTypeDefaultDescription
classNamestring—
direction"inline" | "block"inlineLay children out in a row (`inline`, scrolls horizontally) or a column.