ListGroup
Grouped settings rows and recyclable records.
- Composed
- In the first release
import { ListGroup, ListSection, ListRow, listRowPrimitive, listSectionPrimitive } from "nitro-ui-sdk/list-row";- HeroUI Native
- ListGroup
- Expo UI
- ListListItemSectionForm

Light 
Dark
On this page
ListGroup is the iOS inset-grouped list: a section header, rows on a rounded surface with inset hairlines, and a footer. A row can open another screen (chevron), run an action, pick one option (checkmark), show a value, or hold a control such as a switch. Rows have a leading icon tile (a colored rounded square with an SF Symbol), a title, an optional description and detail, and a trailing accessory.
ListGroup.Root is a section and ListGroup.Item a row. The same components are also exported as ListSection (Root, Header, Footer) and ListRow (Root and the row parts). Rows work inside a NitroUI List: their agent identity follows itemKey, so a recycled row gets a new agent ref. Use Accordion for content that expands in place.
Anatomy
import { ListGroup } from "nitro-ui-sdk/list-row";
<ListGroup.Root header="Network" footer="Manage network connections.">
<ListGroup.Item itemKey="wifi" label="Wi-Fi" detail="Home" onPress={() => {}}>
<ListGroup.Icon symbol="wifi" />
<ListGroup.Content>
<ListGroup.Title>Wi-Fi</ListGroup.Title>
<ListGroup.Description>Connected</ListGroup.Description>
</ListGroup.Content>
<ListGroup.Detail>Home</ListGroup.Detail>
<ListGroup.Chevron />
</ListGroup.Item>
</ListGroup.Root>;
| Part | Description |
|---|---|
Root |
The section: header, rounded surface, rows with inset separators, footer. |
Header / Footer |
Footnote text above and below the rows. Header is a heading. Built from header and footer. |
Item |
One row. Without children it renders icon, label, description, detail and accessory. |
Icon |
The leading tile: a tinted rounded square with a symbol. |
Leading |
Custom leading content, e.g. an avatar. |
Content |
Stacks title and description and takes the free width. |
Title / Description |
The row’s text lines. |
Detail |
The trailing value text (e.g. the selected network). |
Chevron / Checkmark |
Trailing accessories. |
Trailing |
Trailing content. A control here stays its own accessible element, outside the row button. |
Divider |
An inset hairline, for rows you lay out yourself. Sections draw dividers automatically. |
Usage
import { ListGroup } from "nitro-ui-sdk/list-row";
<ListGroup.Root header="Network">
<ListGroup.Item itemKey="wifi" label="Wi-Fi" icon="wifi" detail="Home" accessory="chevron" onPress={() => {}} />
<ListGroup.Item itemKey="bluetooth" label="Bluetooth" icon="dot.radiowaves.left.and.right" detail="On" accessory="chevron" onPress={() => {}} />
</ListGroup.Root>;
Variants and sizes
Section variants: default (surface), secondary (surfaceSecondary), tertiary (surfaceTertiary) and transparent (a plain list without fill). Row variants:
| Variant | Use |
|---|---|
default |
Navigate or act. A button when it has onPress, plain text otherwise. |
choice |
Pick one option. A radio with a checkmark while selected. |
danger |
A destructive action; the title uses danger. |
Sizes sm | md | lg (minimum height 44, 52, 60 pt; icon tile 26, 30, 34 pt) are set on the section for all rows or per row. Icon tints: accent, success, warning, danger, default.
import { ListGroup } from "nitro-ui-sdk/list-row";
import { Switch } from "nitro-ui-sdk/switch";
<ListGroup.Root header="Notifications" size="lg" variant="secondary">
<ListGroup.Item itemKey="sound" label="Sounds">
<ListGroup.Icon symbol="speaker.wave.2.fill" tint="danger" />
<ListGroup.Content>
<ListGroup.Title>Sounds</ListGroup.Title>
</ListGroup.Content>
<ListGroup.Trailing>
<Switch.Root label="Sounds" defaultValue />
</ListGroup.Trailing>
</ListGroup.Item>
</ListGroup.Root>;
States
- Disabled:
opacity.disabled, no press or select from any source. - Selected (
choice): the checkmark shows and the row has the selected trait. - Pressed: the native
Semanticshighlight dims the row while the touch is down.
Controlled
Choice rows take selected/defaultSelected and onSelect. Without selected, the row keeps its own selection. Call details.preventDefault() from onSelect to decline the change. To select one row from a set, control selected from the owner.
import { useState } from "react";
import { ListGroup } from "nitro-ui-sdk/list-row";
function Units() {
const [unit, setUnit] = useState("km");
return (
<ListGroup.Root header="Units">
{["km", "mi"].map((key) => (
<ListGroup.Item key={key} itemKey={key} label={key} variant="choice" selected={unit === key} onSelect={() => setUnit(key)} />
))}
</ListGroup.Root>
);
}
Props
ListGroup.Root
| Prop | Type | Default | Description |
|---|---|---|---|
header |
string |
Title above the rows. | |
footer |
string |
Explanation below the rows. | |
variant |
"default" | "secondary" | "tertiary" | "transparent" |
"default" |
Section fill. |
size |
"sm" | "md" | "lg" |
"md" |
Size of rows that do not set their own. |
dividers |
boolean |
true |
Inset separators between rows. |
styles |
ListSectionStyles |
Section part styles (section, header, footer). |
|
rowStyles |
ListRowStyles |
Styles for rows without their own styles. |
|
layout |
LayoutStyleProps |
Layout of the section. |
ListGroup.Item
| Prop | Type | Default | Description |
|---|---|---|---|
itemKey |
string |
Required. Stable record identity for the agent. | |
label |
string |
Required. Title and spoken name. | |
description |
string |
Second line; spoken after the label. | |
detail |
string |
Trailing value; the row’s spoken value. | |
icon |
string |
SF Symbol for the leading tile. | |
iconTint |
ListRowIconTint |
"accent" |
Tile fill. |
accessory |
"none" | "chevron" | "checkmark" |
checkmark while a choice is selected, else none |
Trailing glyph. |
variant |
"default" | "choice" | "danger" |
"default" |
What the row does. |
size |
"sm" | "md" | "lg" |
section size | Row size. |
disabled |
boolean |
false |
Blocks press and select. |
selected / defaultSelected |
boolean |
Choice selection, controlled or initial. | |
onPress |
(details: ActionDetails) => void |
Action rows. | |
onSelect |
(details: ActionDetails) => void |
Requests a change from unselected to selected. | |
hint |
string |
VoiceOver hint. | |
api |
Controller<ListRowActions> |
From listRowPrimitive.createApi(). |
|
confirm |
Confirmation |
Localized confirmation the agent must pass before pressing. Required to expose the press action on a danger row. |
|
styles |
ListRowStyles |
Row part styles. | |
children |
ReactNode |
Replaces the default anatomy. |
Icon
| Prop | Type | Default | Description |
|---|---|---|---|
symbol |
string |
SF Symbol. | |
tint |
ListRowIconTint |
"accent" |
Tile fill; the glyph uses the matching Foreground. |
fallback |
ImageLoader |
Asset for Android or a missing symbol. |
Title, Description and Detail take children: string; Leading, Content and Trailing take children; Divider takes inset?: number. Every part takes part.
Controller API
import { ListRow, listRowPrimitive } from "nitro-ui-sdk/list-row";
const api = listRowPrimitive.createApi();
<ListRow.Root itemKey="wifi" label="Wi-Fi" onPress={() => {}} api={api} />;
api.current?.press();
| Action | Signature | Result |
|---|---|---|
press |
press(source?: ActionSource): ActionStatus |
Runs onPress: accepted, disabled, refused or unavailable. |
select |
select(source?: ActionSource): ChangeStatus |
Selects a choice row. Returns requested while a controlled owner decides, refused when prevented, or unavailable for read-only choices and other variants. |
Styles
import { ListGroup, type ListRowStyles } from "nitro-ui-sdk/list-row";
const rowStyles: ListRowStyles = {
title: ({ tokens, state }) => ({ text: { color: state.selected ? tokens.colors.accent : tokens.colors.foreground } }),
};
<ListGroup.Root rowStyles={rowStyles} />;
Row parts: row, leading, icon, content, title, description, detail, trailing, accessory, divider; row state { disabled; selected; interactive; inset }. Section parts: section, header, footer; section state { inset }. Custom children opt in with useListRowPart(props, "title").
Accessibility
- An action row is one button, a choice row a radio with the selected trait, a display row text. The name is “label, description” and the value is
detail. - Controls in
Trailingstay outside the row button, so VoiceOver reaches them separately. - The section header is a heading. Separators and icon tiles are decorative.
- Inside an
AgentScopemarkedsecret, the name and value are hidden from the agent.
Agent API
| Action | Arguments | Notes |
|---|---|---|
press |
none | Action rows with onPress. A danger row without confirm remains discoverable with no agent press action. |
select |
none | Choice rows with onSelect, or uncontrolled choice rows. The agent reports refused if a controlled owner keeps the prior value. |
Each row registers as component ListRow with role button, radio or text, value = detail, and state { disabled, selected }. Display rows are read-only. Names and values show as REDACTED under a secret scope.
Platform notes
| iOS | Android | |
|---|---|---|
| Rows and sections | Composed views, Semantics and the shared Separator hairline (LayoutMetrics.hairline); verified in the iOS harness, including recycling in List. |
Same composition; written, compile-only on this machine. |
| Icons | SF Symbols. | fallback assets; without one the glyph is omitted. |