diff options
author | Alexander Tseung <alextsg@gmail.com> | 2018-09-18 01:34:29 +0800 |
---|---|---|
committer | Alexander Tseung <alextsg@gmail.com> | 2018-09-20 05:31:10 +0800 |
commit | 5a6c333506e4000602c1a1106cee6d06fe83afa8 (patch) | |
tree | 2aed850f17114372eaca16ed7e77f42f87907713 /ui/app/components/pages | |
parent | 3e470fee8a5560b605f7ad1060fb1eebafefd21e (diff) | |
download | tangerine-wallet-browser-5a6c333506e4000602c1a1106cee6d06fe83afa8.tar tangerine-wallet-browser-5a6c333506e4000602c1a1106cee6d06fe83afa8.tar.gz tangerine-wallet-browser-5a6c333506e4000602c1a1106cee6d06fe83afa8.tar.bz2 tangerine-wallet-browser-5a6c333506e4000602c1a1106cee6d06fe83afa8.tar.lz tangerine-wallet-browser-5a6c333506e4000602c1a1106cee6d06fe83afa8.tar.xz tangerine-wallet-browser-5a6c333506e4000602c1a1106cee6d06fe83afa8.tar.zst tangerine-wallet-browser-5a6c333506e4000602c1a1106cee6d06fe83afa8.zip |
Switch existing modals from using Notification to Modal. Remove Notification component. Add CancelTransaction modal
Diffstat (limited to 'ui/app/components/pages')
-rw-r--r-- | ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.component.js | 5 | ||||
-rw-r--r-- | ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js | 4 |
2 files changed, 5 insertions, 4 deletions
diff --git a/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.component.js b/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.component.js index 56cfbccc8..40d8faf50 100644 --- a/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.component.js +++ b/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.component.js @@ -8,6 +8,7 @@ import { INSUFFICIENT_FUNDS_ERROR_KEY, TRANSACTION_ERROR_KEY, } from '../../../constants/error-keys' +import { CONFIRMED_STATUS, DROPPED_STATUS } from '../../../constants/transactions' export default class ConfirmTransactionBase extends Component { static contextTypes = { @@ -85,9 +86,9 @@ export default class ConfirmTransactionBase extends Component { clearConfirmTransaction, } = this.props - if (transactionStatus === 'dropped') { + if (transactionStatus === DROPPED_STATUS || transactionStatus === CONFIRMED_STATUS) { showTransactionConfirmedModal({ - onHide: () => { + onSubmit: () => { clearConfirmTransaction() history.push(DEFAULT_ROUTE) }, diff --git a/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js b/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js index 8f54c8040..ae31eba17 100644 --- a/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js +++ b/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js @@ -97,8 +97,8 @@ const mapDispatchToProps = dispatch => { return { clearConfirmTransaction: () => dispatch(clearConfirmTransaction()), clearSend: () => dispatch(clearSend()), - showTransactionConfirmedModal: ({ onHide }) => { - return dispatch(showModal({ name: 'TRANSACTION_CONFIRMED', onHide })) + showTransactionConfirmedModal: ({ onSubmit }) => { + return dispatch(showModal({ name: 'TRANSACTION_CONFIRMED', onSubmit })) }, showCustomizeGasModal: ({ txData, onSubmit, validate }) => { return dispatch(showModal({ name: 'CONFIRM_CUSTOMIZE_GAS', txData, onSubmit, validate })) |