diff options
author | fragosti <francesco.agosti93@gmail.com> | 2018-06-27 02:59:23 +0800 |
---|---|---|
committer | fragosti <francesco.agosti93@gmail.com> | 2018-06-27 02:59:23 +0800 |
commit | e27780aee9de63790da0ebd610761458f42c9259 (patch) | |
tree | bfc8359e514b8931eb0bd9d0709c82e71d17e334 /packages/website/ts | |
parent | f70c1ff009385266d694269c2c4dd0e9fb38dc46 (diff) | |
download | dexon-sol-tools-e27780aee9de63790da0ebd610761458f42c9259.tar dexon-sol-tools-e27780aee9de63790da0ebd610761458f42c9259.tar.gz dexon-sol-tools-e27780aee9de63790da0ebd610761458f42c9259.tar.bz2 dexon-sol-tools-e27780aee9de63790da0ebd610761458f42c9259.tar.lz dexon-sol-tools-e27780aee9de63790da0ebd610761458f42c9259.tar.xz dexon-sol-tools-e27780aee9de63790da0ebd610761458f42c9259.tar.zst dexon-sol-tools-e27780aee9de63790da0ebd610761458f42c9259.zip |
Fix subtle issues with ledger config dialog
Diffstat (limited to 'packages/website/ts')
-rw-r--r-- | packages/website/ts/blockchain.ts | 2 | ||||
-rw-r--r-- | packages/website/ts/components/dialogs/ledger_config_dialog.tsx | 2 | ||||
-rw-r--r-- | packages/website/ts/components/portal/portal.tsx | 20 |
3 files changed, 13 insertions, 11 deletions
diff --git a/packages/website/ts/blockchain.ts b/packages/website/ts/blockchain.ts index d55cb6771..d2040abb5 100644 --- a/packages/website/ts/blockchain.ts +++ b/packages/website/ts/blockchain.ts @@ -828,8 +828,8 @@ export class Blockchain { if (!_.isUndefined(injectedWeb3)) { this._dispatcher.updateProviderType(ProviderType.Injected); } + await this.fetchTokenInformationAsync(); } - await this.fetchTokenInformationAsync(); await this._blockchainWatcher.startEmittingUserBalanceStateAsync(); this._dispatcher.updateNetworkId(networkId); await this._rehydrateStoreWithContractEventsAsync(); diff --git a/packages/website/ts/components/dialogs/ledger_config_dialog.tsx b/packages/website/ts/components/dialogs/ledger_config_dialog.tsx index c9727b553..69144bdd3 100644 --- a/packages/website/ts/components/dialogs/ledger_config_dialog.tsx +++ b/packages/website/ts/components/dialogs/ledger_config_dialog.tsx @@ -283,6 +283,8 @@ export class LedgerConfigDialog extends React.Component<LedgerConfigDialogProps, this.setState({ stepIndex: LedgerSteps.SELECT_ADDRESS, }); + } else { + this.props.dispatcher.updateBlockchainIsLoaded(true); } return didSucceed; } diff --git a/packages/website/ts/components/portal/portal.tsx b/packages/website/ts/components/portal/portal.tsx index bb88e3824..9a61c5d34 100644 --- a/packages/website/ts/components/portal/portal.tsx +++ b/packages/website/ts/components/portal/portal.tsx @@ -266,16 +266,16 @@ export class Portal extends React.Component<PortalProps, PortalState> { networkId={this.props.networkId} /> <FlashMessage dispatcher={this.props.dispatcher} flashMessage={this.props.flashMessage} /> - {this.props.blockchainIsLoaded && ( - <LedgerConfigDialog - providerType={this.props.providerType} - networkId={this.props.networkId} - blockchain={this._blockchain} - dispatcher={this.props.dispatcher} - toggleDialogFn={this._onToggleLedgerDialog.bind(this)} - isOpen={this.state.isLedgerDialogOpen} - /> - )} + + <LedgerConfigDialog + providerType={this.props.providerType} + networkId={this.props.networkId} + blockchain={this._blockchain} + dispatcher={this.props.dispatcher} + toggleDialogFn={this._onToggleLedgerDialog.bind(this)} + isOpen={this.state.isLedgerDialogOpen} + /> + <AssetPicker userAddress={this.props.userAddress} networkId={this.props.networkId} |