import React from 'react';
import PropTypes from 'prop-types';
import Typography from '../../ui/typography/typography';
import {
COLORS,
FONT_WEIGHT,
TYPOGRAPHY,
} from '../../../helpers/constants/design-system';
import Button from '../../ui/button';
export default function TransactionDetailItem({
detailTitle,
detailText,
detailTotal,
subTitle,
subText,
handleActionClick,
actionText,
}) {
return (
{actionText && handleActionClick && (
)}
{detailTitle}
{detailText && (
{detailText}
)}
{detailTotal}
{subTitle && (
{subTitle}
)}
{subText}
);
}
TransactionDetailItem.propTypes = {
handleActionClick: PropTypes.func,
actionText: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
detailTitle: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
detailText: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
detailTotal: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
subTitle: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
subText: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
};
TransactionDetailItem.defaultProps = {
detailTitle: '',
detailText: '',
detailTotal: '',
subTitle: '',
subText: '',
};