From f738d0be9c3b594bb332ba00636e11eb895efb59 Mon Sep 17 00:00:00 2001 From: Vladimir Volek Date: Thu, 15 Nov 2018 17:48:55 +0100 Subject: [PATCH] Added loader to sign and verify --- .../Wallet/views/Account/SignVerify/Container.js | 2 ++ src/views/Wallet/views/Account/SignVerify/index.js | 11 +++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/src/views/Wallet/views/Account/SignVerify/Container.js b/src/views/Wallet/views/Account/SignVerify/Container.js index bd77e997..b023c488 100644 --- a/src/views/Wallet/views/Account/SignVerify/Container.js +++ b/src/views/Wallet/views/Account/SignVerify/Container.js @@ -11,6 +11,7 @@ import Component from './index'; type OwnProps = {} export type StateProps = { + wallet: $ElementType, selectedAccount: $ElementType, signature: string, isSignProgress: boolean, @@ -24,6 +25,7 @@ export type DispatchProps = { export type Props = StateProps & DispatchProps; const mapStateToProps: MapStateToProps = (state: State): StateProps => ({ + wallet: state.wallet, selectedAccount: state.selectedAccount, signature: state.signVerifyReducer.signature, isSignProgress: state.signVerifyReducer.isSignProgress, diff --git a/src/views/Wallet/views/Account/SignVerify/index.js b/src/views/Wallet/views/Account/SignVerify/index.js index bea0913d..b57c65f1 100644 --- a/src/views/Wallet/views/Account/SignVerify/index.js +++ b/src/views/Wallet/views/Account/SignVerify/index.js @@ -98,8 +98,15 @@ class SignVerify extends Component { } render() { - if (!this.props.selectedAccount.account) return null; - + const device = this.props.wallet.selectedDevice; + const { + account, + discovery, + shouldRender, + notification, + } = this.props.selectedAccount; + const { type, title, message } = notification; + if (!device || !account || !discovery || !shouldRender) return ; const { signVerifyActions, signature,