Accordion | CombricSkip to content

Accordion

Combric

Single-open disclosure family with controlled and uncontrolled state.

@combric/react · v1.2.0 · Current

Import and usage

import { Accordion, AccordionItem, AccordionTrigger, AccordionContent } from "@combric/react";

Load the native stylesheet with @import "@combric/react/css";. This path does not require Tailwind.

Examples

Details accordion

Accessible disclosure content.

Disabled item

Content can be opened.

Public API

Public exports
Name
Accordion
AccordionItem
AccordionTrigger
AccordionContent
Documented contracts
Property / capabilityPublished contract
Contractvalue/defaultValue
ContractonValueChange
Contractdisabled items

Accessibility

Native buttons and stable IDs connect expanded state, controls, and labelled regions.

Keyboard

Native button Enter and Space behavior.

CSS and customization

Combric classes and canonical --combric-* variables provide the package presentation. Consumer className extends the required class; it does not replace the component contract.

Motion

Accordion content animates its measured block size by default after the native stylesheet is loaded. Customize AccordionContent through className, or use a CSS class with transition: none for a local opt-out. Reduced motion is automatic. See the Motion Foundation.

Source

View source on GitHub