AccordionItem
Add an expandable section with a heading and optional metadata to an Accordion.
AccordionItem combines a heading with a collapsible content panel. Use open and onOpenChange to control expansion, or defaultOpen for local state.
Import
import { AccordionItem } from "@solarius/onset";Props
| Prop | Type | Default | Description |
|---|---|---|---|
title | ReactNode | — | Header label on the toggle button. |
meta | ReactNode | — | Dim right-aligned meta on the header row (counts, sizes). |
open | boolean | — | Controlled open state. |
defaultOpen | boolean | false | Initial open state when uncontrolled. |
onOpenChange | (open: boolean) => void | — | Callback when open state changes. |
children | ReactNode | — | Body content. Unmounted while collapsed unless keepMounted is set. |
keepMounted | boolean | false | Keeps panel children mounted while collapsed. Defaults to false. Passed through to Collapsible. |