* Compare Accounts via useUpdatedAccount for withdraw * fix: onChangeAsset fixed * Mp 3250 update health bars (#403) * [Story] Add HealthBar * Update tooltip * Fixes after rebase * Fixes after rebase * Fixes after rebase * Finish health bar + gauge * Finish health bar + gauge * Finish health bar + gauge * feat: added an svg mask to the HealthBar * fix: added transitions * tidy: value sanity * fix: fixed the AccountStats * tidy: design update * fix: div adjustments * update healthguagepercentage function * make tooltiparrow responsive --------- Co-authored-by: Linkie Link <linkielink.dev@gmail.com> * Compare Accounts via useUpdatedAccount for withdraw * Mp 3250 update health bars (#403) * [Story] Add HealthBar * Update tooltip * Fixes after rebase * Fixes after rebase * Fixes after rebase * Finish health bar + gauge * Finish health bar + gauge * Finish health bar + gauge * feat: added an svg mask to the HealthBar * fix: added transitions * tidy: value sanity * fix: fixed the AccountStats * tidy: design update * fix: div adjustments * update healthguagepercentage function * make tooltiparrow responsive --------- Co-authored-by: Linkie Link <linkielink.dev@gmail.com> * Mp 3250 update health bars (#403) * [Story] Add HealthBar * Update tooltip * Fixes after rebase * Fixes after rebase * Fixes after rebase * Finish health bar + gauge * Finish health bar + gauge * Finish health bar + gauge * feat: added an svg mask to the HealthBar * fix: added transitions * tidy: value sanity * fix: fixed the AccountStats * tidy: design update * fix: div adjustments * update healthguagepercentage function * make tooltiparrow responsive --------- Co-authored-by: Linkie Link <linkielink.dev@gmail.com> * fix: merge error --------- Co-authored-by: Yusuf Seyrek <yusuf@delphilabs.io> Co-authored-by: Bob van der Helm <34470358+bobthebuidlr@users.noreply.github.com>
33 lines
765 B
TypeScript
33 lines
765 B
TypeScript
import classNames from 'classnames'
|
|
|
|
import AccordionContent, { Item } from 'components/AccordionContent'
|
|
import Card from 'components/Card'
|
|
|
|
interface Props {
|
|
items: Item[]
|
|
allowMultipleOpen?: boolean
|
|
className?: string
|
|
}
|
|
|
|
export default function Accordion(props: Props) {
|
|
if (props.allowMultipleOpen) {
|
|
return (
|
|
<Card className='w-full'>
|
|
{props.items.map((item, index) => (
|
|
<AccordionContent key={index} item={item} index={index} />
|
|
))}
|
|
</Card>
|
|
)
|
|
}
|
|
|
|
return (
|
|
<div className={classNames('w-full', props.className)}>
|
|
{props.items.map((item, index) => (
|
|
<Card key={index} className='mb-4'>
|
|
<AccordionContent item={item} index={index} />
|
|
</Card>
|
|
))}
|
|
</div>
|
|
)
|
|
}
|