1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-02 14:15:06 +01:00
metamask-extension/ui/components/app/transaction-breakdown/transaction-breakdown-row/transaction-breakdown-row.component.js
Elliot Winkler a35f22fcdf
Add Max Fee Per Gas to transaction breakdown (#12042)
This comes through in EIP-1559 transactions and so it is helpful to show
this to users.
2021-09-08 12:06:16 -06:00

36 lines
893 B
JavaScript

import React, { PureComponent } from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
export default class TransactionBreakdownRow extends PureComponent {
static propTypes = {
title: PropTypes.string,
children: PropTypes.node,
className: PropTypes.string,
};
render() {
const { title, children, className } = this.props;
return (
<div
className={classnames('transaction-breakdown-row', className)}
data-testid="transaction-breakdown-row"
>
<div
className="transaction-breakdown-row__title"
data-testid="transaction-breakdown-row-title"
>
{title}
</div>
<div
className="transaction-breakdown-row__value"
data-testid="transaction-breakdown-row-value"
>
{children}
</div>
</div>
);
}
}