Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix - transactions pages issue with endless scroll.
refactoring - balances
- Loading branch information
Showing
36 changed files
with
239 additions
and
321 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 13 additions & 1 deletion
14
.../blockchain-wallet-v4-frontend/src/layouts/Wallet/MenuTop/Balance/BchBalance/selectors.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,15 @@ | ||
import { selectors } from 'data' | ||
import { createDeepEqualSelector } from 'services/ReselectHelper' | ||
import { add, traverse, reduce } from 'ramda' | ||
import { Remote } from 'blockchain-wallet-v4/src' | ||
|
||
export const getData = selectors.core.data.bch.getSpendableBalance | ||
export const getData = state => createDeepEqualSelector( | ||
[ | ||
selectors.core.kvStore.bch.getSpendableContext | ||
], | ||
(context) => { | ||
const getBalance = address => selectors.core.data.bch.getFinalBalance(address, state) | ||
const balancesR = traverse(Remote.of, getBalance, context) | ||
return balancesR.map(xs => reduce(add, 0, xs)) | ||
} | ||
)(state) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 13 additions & 1 deletion
14
...in-wallet-v4-frontend/src/layouts/Wallet/MenuTop/Balance/BchWatchOnlyBalance/selectors.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,15 @@ | ||
import { selectors } from 'data' | ||
import { createDeepEqualSelector } from 'services/ReselectHelper' | ||
import { add, traverse, reduce } from 'ramda' | ||
import { Remote } from 'blockchain-wallet-v4/src' | ||
|
||
export const getData = selectors.core.data.bch.getUnspendableBalance | ||
export const getData = state => createDeepEqualSelector( | ||
[ | ||
selectors.core.kvStore.bch.getUnspendableContext | ||
], | ||
(context) => { | ||
const getBalance = address => selectors.core.data.bch.getFinalBalance(address, state) | ||
const balancesR = traverse(Remote.of, getBalance, context) | ||
return balancesR.map(xs => reduce(add, 0, xs)) | ||
} | ||
)(state) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 13 additions & 1 deletion
14
.../blockchain-wallet-v4-frontend/src/layouts/Wallet/MenuTop/Balance/BtcBalance/selectors.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,15 @@ | ||
import { selectors } from 'data' | ||
import { createDeepEqualSelector } from 'services/ReselectHelper' | ||
import { add, traverse, reduce } from 'ramda' | ||
import { Remote } from 'blockchain-wallet-v4/src' | ||
|
||
export const getData = selectors.core.data.bitcoin.getSpendableBalance | ||
export const getData = state => createDeepEqualSelector( | ||
[ | ||
selectors.core.wallet.getSpendableContext | ||
], | ||
(context) => { | ||
const getBalance = address => selectors.core.data.bitcoin.getFinalBalance(address, state) | ||
const balancesR = traverse(Remote.of, getBalance, context) | ||
return balancesR.map(xs => reduce(add, 0, xs)) | ||
} | ||
)(state) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 13 additions & 1 deletion
14
...in-wallet-v4-frontend/src/layouts/Wallet/MenuTop/Balance/BtcWatchOnlyBalance/selectors.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,15 @@ | ||
import { selectors } from 'data' | ||
import { createDeepEqualSelector } from 'services/ReselectHelper' | ||
import { add, traverse, reduce } from 'ramda' | ||
import { Remote } from 'blockchain-wallet-v4/src' | ||
|
||
export const getData = selectors.core.data.bitcoin.getUnspendableBalance | ||
export const getData = state => createDeepEqualSelector( | ||
[ | ||
selectors.core.wallet.getUnspendableContext | ||
], | ||
(context) => { | ||
const getBalance = address => selectors.core.data.bitcoin.getFinalBalance(address, state) | ||
const balancesR = traverse(Remote.of, getBalance, context) | ||
return balancesR.map(xs => reduce(add, 0, xs)) | ||
} | ||
)(state) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 22 additions & 13 deletions
35
...lockchain-wallet-v4-frontend/src/layouts/Wallet/MenuTop/Balance/TotalBalance/selectors.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.