List
Present related information with a consistent hierarchy.
Installation
bunx --bun shadcn@latest add https://apple-ui-eduardo.vercel.app/r/list.jsonThe registry includes the shared styles and dependencies. Import @/components/apple-ui/styles.css in your root layout once. For the package route, use the installation guide.
Usage
<List aria-label="Collections">
<ListItem title="Design journal" supportingText="Updated today" href="/journal" />
<ListItem title="Weekend plans" supportingText="8 notes" href="/weekend" />
</List>Package imports use @eduardoul/apple-ui. Registry imports use @/components/apple-ui. Add "use client" to files that use state or event handlers.
API reference
| Property | Type | Default |
|---|---|---|
| title | ReactNode on item | required |
| supportingText | ReactNode on item | undefined |
| leading / trailing | ReactNode on item | undefined |
Use className and style to customize the component. The package includes full TypeScript definitions for its supported element properties and refs.
Design guidance
- Use alignment and supporting text to make scanning easy.
- Make the whole row interactive when it has a single destination.
Accessibility
Provide a visible label or accessible name. Keep keyboard focus visible and check the example with your content at 200 percent zoom. Overlays use Radix for focus management and keyboard dismissal.
Library styles support reduced motion, reduced transparency, increased contrast and forced colors. Read the accessibility foundation for the checks your application still needs.