@hixme-ui/card-drawer
v2.2.0
Published
hixme-ui CardDrawer component
Downloads
52
Readme
Card Drawer
npm i --save @hixme-ui/card-drawer
CardDrawer is an accordion component implemented with Card and react-collapsible.
Usage
import CardDrawer from '@hixme-ui/card-drawer'
// Using react-collapsible
<CardDrawer collapsible cardHeader='Drawer title'>
<p>Drawer content</p>
</CardDrawer>
// Always open, static CardDrawer
<CardDrawer open cardHeader='Drawer title'>
<p>Drawer content</p>
</CardDrawer>
// You can also supply the content to the cardContent prop
<CardDrawer
collapsible
cardHeader='Drawer title'
cardContent={
<p>Drawer content</p>
}
/>
Props
| Name | Type | Default | | --------------- | ----------- | -------------- | | cardContent | node | null | | cardHeader | string | null | | children | node | N/A | | collapsible | boolean | false | | disabled | boolean | false | | hideArrow | boolean | false |