1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-24 19:10:22 +01:00
metamask-extension/ui/pages/send/send-content/send-amount-row/send-amount-row.container.js
2021-06-23 16:35:25 -05:00

25 lines
586 B
JavaScript

import { connect } from 'react-redux';
import {
updateSendAmount,
getSendAmount,
sendAmountIsInError,
getSendAsset,
} from '../../../../ducks/send';
import SendAmountRow from './send-amount-row.component';
export default connect(mapStateToProps, mapDispatchToProps)(SendAmountRow);
function mapStateToProps(state) {
return {
amount: getSendAmount(state),
inError: sendAmountIsInError(state),
asset: getSendAsset(state),
};
}
function mapDispatchToProps(dispatch) {
return {
updateSendAmount: (newAmount) => dispatch(updateSendAmount(newAmount)),
};
}