2018-07-18 15:48:30 -04:00
|
|
|
import { connect } from 'react-redux';
|
2021-10-17 16:36:14 +08:00
|
|
|
import { doWalletStatus, doWalletDecrypt } from 'redux/actions/wallet';
|
|
|
|
import { selectWalletDecryptSucceeded } from 'redux/selectors/wallet';
|
2019-08-27 22:35:07 -04:00
|
|
|
import { doHideModal } from 'redux/actions/app';
|
2018-07-18 15:48:30 -04:00
|
|
|
import ModalWalletDecrypt from './view';
|
|
|
|
|
2021-10-17 16:36:14 +08:00
|
|
|
const select = (state) => ({
|
2018-07-18 15:48:30 -04:00
|
|
|
walletDecryptSucceded: selectWalletDecryptSucceeded(state),
|
|
|
|
});
|
|
|
|
|
2021-10-17 16:36:14 +08:00
|
|
|
const perform = (dispatch) => ({
|
2018-10-29 13:23:53 -04:00
|
|
|
closeModal: () => dispatch(doHideModal()),
|
2021-10-17 16:36:14 +08:00
|
|
|
decryptWallet: (password) => dispatch(doWalletDecrypt(password)),
|
2018-07-18 15:48:30 -04:00
|
|
|
updateWalletStatus: () => dispatch(doWalletStatus()),
|
|
|
|
});
|
|
|
|
|
2021-10-17 16:36:14 +08:00
|
|
|
export default connect(select, perform)(ModalWalletDecrypt);
|