You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
1.0 KiB
36 lines
1.0 KiB
4 years ago
|
import { connect } from 'react-redux';
|
||
4 years ago
|
import {
|
||
|
displayWarning,
|
||
|
requestRevealSeedWords,
|
||
|
fetchInfoToSync,
|
||
|
exportAccounts,
|
||
4 years ago
|
} from '../../store/actions';
|
||
|
import { getMostRecentOverviewPage } from '../../ducks/history/history';
|
||
|
import { getMetaMaskKeyrings } from '../../selectors';
|
||
|
import MobileSyncPage from './mobile-sync.component';
|
||
5 years ago
|
|
||
|
const mapDispatchToProps = (dispatch) => {
|
||
|
return {
|
||
4 years ago
|
requestRevealSeedWords: (password) =>
|
||
|
dispatch(requestRevealSeedWords(password)),
|
||
5 years ago
|
fetchInfoToSync: () => dispatch(fetchInfoToSync()),
|
||
|
displayWarning: (message) => dispatch(displayWarning(message || null)),
|
||
4 years ago
|
exportAccounts: (password, addresses) =>
|
||
|
dispatch(exportAccounts(password, addresses)),
|
||
4 years ago
|
};
|
||
|
};
|
||
5 years ago
|
|
||
5 years ago
|
const mapStateToProps = (state) => {
|
||
5 years ago
|
const {
|
||
4 years ago
|
metamask: { selectedAddress },
|
||
4 years ago
|
} = state;
|
||
5 years ago
|
|
||
|
return {
|
||
5 years ago
|
mostRecentOverviewPage: getMostRecentOverviewPage(state),
|
||
5 years ago
|
selectedAddress,
|
||
4 years ago
|
keyrings: getMetaMaskKeyrings(state),
|
||
4 years ago
|
};
|
||
|
};
|
||
5 years ago
|
|
||
4 years ago
|
export default connect(mapStateToProps, mapDispatchToProps)(MobileSyncPage);
|