aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/select-app.js
diff options
context:
space:
mode:
authorAlexander Tseung <alextsg@users.noreply.github.com>2017-12-23 02:43:02 +0800
committerGitHub <noreply@github.com>2017-12-23 02:43:02 +0800
commita218008adf85dfb5fa8ca93c789e14d9f2090813 (patch)
tree863dd34eed719074277a8c65397d9e5081b2084b /ui/app/select-app.js
parent4acd48966edf2e6cf4ced6e3e0983a44dcb2ec13 (diff)
downloadtangerine-wallet-browser-a218008adf85dfb5fa8ca93c789e14d9f2090813.tar
tangerine-wallet-browser-a218008adf85dfb5fa8ca93c789e14d9f2090813.tar.gz
tangerine-wallet-browser-a218008adf85dfb5fa8ca93c789e14d9f2090813.tar.bz2
tangerine-wallet-browser-a218008adf85dfb5fa8ca93c789e14d9f2090813.tar.lz
tangerine-wallet-browser-a218008adf85dfb5fa8ca93c789e14d9f2090813.tar.xz
tangerine-wallet-browser-a218008adf85dfb5fa8ca93c789e14d9f2090813.tar.zst
tangerine-wallet-browser-a218008adf85dfb5fa8ca93c789e14d9f2090813.zip
Track usage of old and new UI (#2794)
[NewUI] Track usage of old and new UI
Diffstat (limited to 'ui/app/select-app.js')
-rw-r--r--ui/app/select-app.js13
1 files changed, 10 insertions, 3 deletions
diff --git a/ui/app/select-app.js b/ui/app/select-app.js
index 0b837b547..ac6867aeb 100644
--- a/ui/app/select-app.js
+++ b/ui/app/select-app.js
@@ -5,7 +5,8 @@ const h = require('react-hyperscript')
const App = require('./app')
const OldApp = require('../../old-ui/app/app')
const { autoAddToBetaUI } = require('./selectors')
-const { setFeatureFlag } = require('./actions')
+const { setFeatureFlag, setNetworkEndpoints } = require('./actions')
+const { BETA_UI_NETWORK_TYPE } = require('../../app/scripts/config').enums
function mapStateToProps (state) {
return {
@@ -19,8 +20,14 @@ function mapStateToProps (state) {
function mapDispatchToProps (dispatch) {
return {
- setFeatureFlagWithModal: () => dispatch(setFeatureFlag('betaUI', true, 'BETA_UI_NOTIFICATION_MODAL')),
- setFeatureFlagWithoutModal: () => dispatch(setFeatureFlag('betaUI', true)),
+ setFeatureFlagWithModal: () => {
+ return dispatch(setFeatureFlag('betaUI', true, 'BETA_UI_NOTIFICATION_MODAL'))
+ .then(() => dispatch(setNetworkEndpoints(BETA_UI_NETWORK_TYPE)))
+ },
+ setFeatureFlagWithoutModal: () => {
+ return dispatch(setFeatureFlag('betaUI', true))
+ .then(() => dispatch(setNetworkEndpoints(BETA_UI_NETWORK_TYPE)))
+ },
}
}
module.exports = connect(mapStateToProps, mapDispatchToProps)(SelectedApp)