mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-05 23:44:56 +01:00
34 lines
802 B
JavaScript
34 lines
802 B
JavaScript
import React from 'react';
|
|
import PropTypes from 'prop-types';
|
|
import Button from '../../../../components/ui/button';
|
|
|
|
export default function ConfirmationFooter({
|
|
onApprove,
|
|
onCancel,
|
|
approveText,
|
|
cancelText,
|
|
alerts,
|
|
}) {
|
|
return (
|
|
<div className="confirmation-footer">
|
|
{alerts}
|
|
<div className="confirmation-footer__actions">
|
|
<Button type="secondary" onClick={onCancel}>
|
|
{cancelText}
|
|
</Button>
|
|
<Button type="primary" onClick={onApprove}>
|
|
{approveText}
|
|
</Button>
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|
|
|
|
ConfirmationFooter.propTypes = {
|
|
alerts: PropTypes.node,
|
|
onApprove: PropTypes.func.isRequired,
|
|
onCancel: PropTypes.func.isRequired,
|
|
approveText: PropTypes.string.isRequired,
|
|
cancelText: PropTypes.string.isRequired,
|
|
};
|