Created new Result component to display operation result messages consistently

This commit is contained in:
Alejandro Celaya
2020-12-21 17:54:05 +01:00
parent c25355c531
commit b211a29fc5
19 changed files with 110 additions and 72 deletions

View File

@@ -4,11 +4,12 @@ import { ReactNode } from 'react';
interface SimpleCardProps extends Omit<CardProps, 'title'> {
title?: ReactNode;
bodyClassName?: string;
}
export const SimpleCard = ({ title, children, ...rest }: SimpleCardProps) => (
export const SimpleCard = ({ title, children, bodyClassName, ...rest }: SimpleCardProps) => (
<Card {...rest}>
{title && <CardHeader>{title}</CardHeader>}
<CardBody>{children}</CardBody>
<CardBody className={bodyClassName}>{children}</CardBody>
</Card>
);