aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/reducers
diff options
context:
space:
mode:
authorDan Finlay <flyswatter@users.noreply.github.com>2017-04-25 04:53:35 +0800
committerGitHub <noreply@github.com>2017-04-25 04:53:35 +0800
commitca3faba1ac7b3a8323681e669f47fbac4bb1ead3 (patch)
treef7f02270025a812b907d756f5dd174936006a10d /ui/app/reducers
parent8d4203765279b85f0ca6c2c593dc7aad76b16776 (diff)
parent79f88398acd116980fe91d4c56a1ec6a15672745 (diff)
downloadtangerine-wallet-browser-ca3faba1ac7b3a8323681e669f47fbac4bb1ead3.tar
tangerine-wallet-browser-ca3faba1ac7b3a8323681e669f47fbac4bb1ead3.tar.gz
tangerine-wallet-browser-ca3faba1ac7b3a8323681e669f47fbac4bb1ead3.tar.bz2
tangerine-wallet-browser-ca3faba1ac7b3a8323681e669f47fbac4bb1ead3.tar.lz
tangerine-wallet-browser-ca3faba1ac7b3a8323681e669f47fbac4bb1ead3.tar.xz
tangerine-wallet-browser-ca3faba1ac7b3a8323681e669f47fbac4bb1ead3.tar.zst
tangerine-wallet-browser-ca3faba1ac7b3a8323681e669f47fbac4bb1ead3.zip
Merge pull request #1336 from MetaMask/buyButtonRedo
Buy button redo
Diffstat (limited to 'ui/app/reducers')
-rw-r--r--ui/app/reducers/app.js35
1 files changed, 5 insertions, 30 deletions
diff --git a/ui/app/reducers/app.js b/ui/app/reducers/app.js
index 7ad1229e5..324a4df35 100644
--- a/ui/app/reducers/app.js
+++ b/ui/app/reducers/app.js
@@ -469,8 +469,9 @@ function reduceApp (state, action) {
name: 'buyEth',
context: appState.currentView.name,
},
+ identity: state.metamask.identities[action.value],
buyView: {
- subview: 'buyForm',
+ subview: 'Coinbase',
amount: '15.00',
buyAddress: action.value,
formView: {
@@ -480,36 +481,10 @@ function reduceApp (state, action) {
},
})
- case actions.UPDATE_BUY_ADDRESS:
- return extend(appState, {
- buyView: {
- subview: 'buyForm',
- formView: {
- coinbase: appState.buyView.formView.coinbase,
- shapeshift: appState.buyView.formView.shapeshift,
- },
- buyAddress: action.value,
- amount: appState.buyView.amount,
- },
- })
-
- case actions.UPDATE_COINBASE_AMOUNT:
- return extend(appState, {
- buyView: {
- subview: 'buyForm',
- formView: {
- coinbase: true,
- shapeshift: false,
- },
- buyAddress: appState.buyView.buyAddress,
- amount: action.value,
- },
- })
-
case actions.COINBASE_SUBVIEW:
return extend(appState, {
buyView: {
- subview: 'buyForm',
+ subview: 'Coinbase',
formView: {
coinbase: true,
shapeshift: false,
@@ -522,7 +497,7 @@ function reduceApp (state, action) {
case actions.SHAPESHIFT_SUBVIEW:
return extend(appState, {
buyView: {
- subview: 'buyForm',
+ subview: 'ShapeShift',
formView: {
coinbase: false,
shapeshift: true,
@@ -537,7 +512,7 @@ function reduceApp (state, action) {
case actions.PAIR_UPDATE:
return extend(appState, {
buyView: {
- subview: 'buyForm',
+ subview: 'ShapeShift',
formView: {
coinbase: false,
shapeshift: true,