1.6.0 • Published 6 years ago
@fenderdigital/react-accordion v1.6.0
Accordion for Fender React UI Kit
Description
The Accordion component is used to expand and collapse content.
Installation and Usage
yarn add @fenderdigital/react-accordion --saveimport Accordion from '@fenderdigital/react-accordion';Props
- children - renders any child elements
- disableTriangle - hides the up/down triangle arrow
- hasAnimation - enables animations for the expanded / collapsed states
- icon - accepts an icon element that renders to the left of the label
- isVisible - the current collapsed / expanded state
- label - the button label
- onCallback - callback after the visibility state is set
- styles - tachyon classes for the button
- transition - accepts a prop for transtion effects
| propName | propType | defaultValue | isRequired |
|---|---|---|---|
| children | node | null | - |
| disableTriangle | node | null | - |
| hasAnimation | boolean | true | - |
| icon | node | null | - |
| isVisible | boolean | false | - |
| label | string | null | - |
| onCallback | func | () => {} | - |
| styles | func | flex | - |
| transition | string | null | - |
Development
Check the Monorepo README for development documentation.