agrp.dev logo
Components
BadgeButtonCheckboxCollapseBasic usageDatePickerIconIndicatorInputMessageNotificationPaginationProgressRadioSelectSkeletonSwitchTabsTextAreaTimelineTooltipsTypography

Collapse

Is an alternative to the <details> element. Can be used as an accordion, where only one item can be expanded at a time.

Basic usage

import { Collapse as AtlanticCollapse, useCollapseUnique } from '@atlasgroup/react-atlantic';
// also, that's kinda bs, pls fix
const Collapse = wrap(AtlanticCollapse, useCollapseUnique);

Collapse must be wrapped with useCollapseUnique to make the element interactive. Using the component with a custom hook is encouraged.