aboutsummaryrefslogtreecommitdiffstats
path: root/mascara/src/app/first-time/import-account-screen.js
diff options
context:
space:
mode:
Diffstat (limited to 'mascara/src/app/first-time/import-account-screen.js')
-rw-r--r--mascara/src/app/first-time/import-account-screen.js11
1 files changed, 8 insertions, 3 deletions
diff --git a/mascara/src/app/first-time/import-account-screen.js b/mascara/src/app/first-time/import-account-screen.js
index 17be90c2a..a7af42cd7 100644
--- a/mascara/src/app/first-time/import-account-screen.js
+++ b/mascara/src/app/first-time/import-account-screen.js
@@ -1,6 +1,6 @@
import React, {Component, PropTypes} from 'react'
import classnames from 'classnames'
-import {importNewAccount} from '../../../../ui/app/actions'
+import {importNewAccount, hideWarning} from '../../../../ui/app/actions'
import {connect} from 'react-redux';
const Input = ({ label, placeholder, onChange, errorMessage, type = 'text' }) => (
@@ -29,6 +29,7 @@ class ImportAccountScreen extends Component {
back: PropTypes.func.isRequired,
next: PropTypes.func.isRequired,
importNewAccount: PropTypes.func.isRequired,
+ hideWarning: PropTypes.func.isRequired,
};
state = {
@@ -152,7 +153,10 @@ class ImportAccountScreen extends Component {
<select
className="import-account__dropdown"
value={selectedOption}
- onChange={e => this.setState({ selectedOption: e.target.value })}
+ onChange={e => {
+ this.setState({ selectedOption: e.target.value })
+ this.props.hideWarning()
+ }}
>
<option value={OPTIONS.PRIVATE_KEY}>Private Key</option>
<option value={OPTIONS.JSON_FILE}>JSON File</option>
@@ -180,6 +184,7 @@ class ImportAccountScreen extends Component {
export default connect(
({ appState: { isLoading, warning } }) => ({ isLoading, warning }),
dispatch => ({
- importNewAccount: (strategy, args) => dispatch(importNewAccount(strategy, args))
+ importNewAccount: (strategy, args) => dispatch(importNewAccount(strategy, args)),
+ hideWarning: () => dispatch(hideWarning()),
})
)(ImportAccountScreen)