From d7d80a5d4678eb1614b3bac9074d9aa2dfb7ff4b Mon Sep 17 00:00:00 2001 From: Aaron Date: Fri, 21 Feb 2020 10:35:07 +1100 Subject: [PATCH 1/5] Make sure balance is updated in accounts modal --- src/modules/check/accounts.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/check/accounts.ts b/src/modules/check/accounts.ts index 89a0418ca..f5a100908 100644 --- a/src/modules/check/accounts.ts +++ b/src/modules/check/accounts.ts @@ -5,14 +5,14 @@ type AccountsAndBalances = Array<{ balance: string; address: string }> function accountSelect(): WalletCheckModule | never { let completed: boolean = false let loadingAccounts: boolean = false - let accountsAndBalances: AccountsAndBalances + let accountsAndBalances: AccountsAndBalances = [] return async (stateAndHelpers: StateAndHelpers) => { const { wallet, BigNumber, address, balance } = stateAndHelpers const { provider, type } = wallet if (type === 'hardware' && !completed) { - if (!accountsAndBalances && !loadingAccounts) { + if (accountsAndBalances.length <= 1 && !loadingAccounts) { accountsAndBalances = [{ address, balance }] } From eaf8520b8bd8080277c19b7ae51bde79424c085b Mon Sep 17 00:00:00 2001 From: Aaron Date: Fri, 21 Feb 2020 10:52:02 +1100 Subject: [PATCH 2/5] Remove unnecessary extra path --- src/modules/select/wallets/ledger.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/select/wallets/ledger.ts b/src/modules/select/wallets/ledger.ts index f04eb7048..9d4b6af1f 100644 --- a/src/modules/select/wallets/ledger.ts +++ b/src/modules/select/wallets/ledger.ts @@ -158,7 +158,7 @@ async function ledgerProvider(options: { paths.push(ledgerLive, legacy) } } else { - paths.push(`${basePath}/0'/0`, `${basePath}/0'/0/0`) + paths.push(`${basePath}/0'/0`) } let transport From 4906412dca0774849c60014684f5821981a891bd Mon Sep 17 00:00:00 2001 From: Aaron Date: Fri, 21 Feb 2020 11:13:08 +1100 Subject: [PATCH 3/5] Dynamically import Torus --- src/modules/select/wallets/torus.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/select/wallets/torus.ts b/src/modules/select/wallets/torus.ts index b9d525e5e..99e741053 100644 --- a/src/modules/select/wallets/torus.ts +++ b/src/modules/select/wallets/torus.ts @@ -1,4 +1,3 @@ -import Torus from '@toruslabs/torus-embed' import { networkName } from '../../../utilities' import { TorusOptions, @@ -27,6 +26,7 @@ function torus(options: TorusOptions & CommonWalletOptions): WalletModule { svg: svg || torusIcon, iconSrc, wallet: async () => { + const { default: Torus } = await import('@toruslabs/torus-embed') const instance = new Torus({ buttonPosition: buttonPosition // default: bottom-left }) From c6647cd5eee9e859263cada31eda4f34bbdb4ea8 Mon Sep 17 00:00:00 2001 From: Amir Date: Wed, 26 Feb 2020 23:26:46 +0500 Subject: [PATCH 4/5] Fix trust deep link --- src/modules/select/wallets/trust.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/select/wallets/trust.ts b/src/modules/select/wallets/trust.ts index 54209fdeb..282ab49ae 100644 --- a/src/modules/select/wallets/trust.ts +++ b/src/modules/select/wallets/trust.ts @@ -3,7 +3,7 @@ import { WalletModule, Helpers, CommonWalletOptions } from '../../../interfaces' import trustIcon from '../wallet-icons/icon-trust' -function trust(options: CommonWalletOptions): WalletModule { +function trust (options: CommonWalletOptions): WalletModule { const { preferred, label, iconSrc, svg } = options return { @@ -24,7 +24,7 @@ function trust(options: CommonWalletOptions): WalletModule { } }, type: 'injected', - link: `https://links.trustwalletapp.com/a/key_live_lfvIpVeI9TFWxPCqwU8rZnogFqhnzs4D?&event=openURL&url=${window.location.href}`, + link: `https://link.trustwallet.com/open_url?coin_id=60&url=${window.location.href}`, installMessage: mobileWalletInstallMessage, mobile: true, preferred From fb036b6376d7d9c12c320adaaddbfdbba66c9a37 Mon Sep 17 00:00:00 2001 From: Aaron Date: Thu, 27 Feb 2020 10:22:42 +1100 Subject: [PATCH 5/5] Change to version 1.3.1 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index f95e84355..a9e1d8221 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "bnc-onboard", - "version": "1.3.0", + "version": "1.3.1", "description": "Onboard users to web3 by allowing them to select a wallet, get that wallet ready to transact and have access to synced wallet state.", "keywords": [ "ethereum",