aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ui/app/components/transaction-list-item-details/transaction-list-item-details.component.js12
-rw-r--r--ui/app/components/transaction-list-item/transaction-list-item.component.js5
2 files changed, 12 insertions, 5 deletions
diff --git a/ui/app/components/transaction-list-item-details/transaction-list-item-details.component.js b/ui/app/components/transaction-list-item-details/transaction-list-item-details.component.js
index d57ff130a..f65ff4d55 100644
--- a/ui/app/components/transaction-list-item-details/transaction-list-item-details.component.js
+++ b/ui/app/components/transaction-list-item-details/transaction-list-item-details.component.js
@@ -13,8 +13,9 @@ export default class TransactionListItemDetails extends PureComponent {
}
static propTypes = {
- transaction: PropTypes.object,
+ onRetry: PropTypes.func,
showRetry: PropTypes.bool,
+ transaction: PropTypes.object,
}
handleEtherscanClick = () => {
@@ -26,6 +27,13 @@ export default class TransactionListItemDetails extends PureComponent {
this.setState({ showTransactionDetails: true })
}
+ handleRetry = event => {
+ const { onRetry } = this.props
+
+ event.stopPropagation()
+ onRetry()
+ }
+
render () {
const { t } = this.context
const { transaction, showRetry } = this.props
@@ -40,7 +48,7 @@ export default class TransactionListItemDetails extends PureComponent {
showRetry && (
<Button
type="raised"
- onClick={this.handleEtherscanClick}
+ onClick={this.handleRetry}
className="transaction-list-item-details__header-button"
>
{ t('speedUp') }
diff --git a/ui/app/components/transaction-list-item/transaction-list-item.component.js b/ui/app/components/transaction-list-item/transaction-list-item.component.js
index 5564f0883..e590e96e0 100644
--- a/ui/app/components/transaction-list-item/transaction-list-item.component.js
+++ b/ui/app/components/transaction-list-item/transaction-list-item.component.js
@@ -42,9 +42,7 @@ export default class TransactionListItem extends PureComponent {
this.setState({ showTransactionDetails: !showTransactionDetails })
}
- handleRetryClick = event => {
- event.stopPropagation()
-
+ handleRetry = () => {
const {
transaction: { txParams: { to } = {} },
methodData: { name } = {},
@@ -156,6 +154,7 @@ export default class TransactionListItem extends PureComponent {
<TransactionListItemDetails
transaction={transaction}
showRetry={showRetry && methodData.done}
+ onRetry={this.handleRetry}
/>
</div>
)