2021-02-04 19:15:23 +01:00
|
|
|
import { connect } from 'react-redux';
|
2019-08-02 05:57:26 +02:00
|
|
|
import {
|
|
|
|
setCompletedOnboarding,
|
|
|
|
setSeedPhraseBackedUp,
|
2021-02-04 19:15:23 +01:00
|
|
|
} from '../../../../store/actions';
|
|
|
|
import { getOnboardingInitiator } from '../../../../selectors';
|
|
|
|
import RevealSeedPhrase from './reveal-seed-phrase.component';
|
2019-11-22 18:03:51 +01:00
|
|
|
|
|
|
|
const mapStateToProps = (state) => {
|
|
|
|
return {
|
|
|
|
onboardingInitiator: getOnboardingInitiator(state),
|
2021-02-04 19:15:23 +01:00
|
|
|
};
|
|
|
|
};
|
2019-08-02 05:57:26 +02:00
|
|
|
|
2020-02-15 21:34:12 +01:00
|
|
|
const mapDispatchToProps = (dispatch) => {
|
2019-08-02 05:57:26 +02:00
|
|
|
return {
|
2020-11-03 00:41:28 +01:00
|
|
|
setSeedPhraseBackedUp: (seedPhraseBackupState) =>
|
|
|
|
dispatch(setSeedPhraseBackedUp(seedPhraseBackupState)),
|
2019-08-02 05:57:26 +02:00
|
|
|
setCompletedOnboarding: () => dispatch(setCompletedOnboarding()),
|
2021-02-04 19:15:23 +01:00
|
|
|
};
|
|
|
|
};
|
2019-08-02 05:57:26 +02:00
|
|
|
|
2021-02-04 19:15:23 +01:00
|
|
|
export default connect(mapStateToProps, mapDispatchToProps)(RevealSeedPhrase);
|