aboutsummaryrefslogtreecommitdiffstats
path: root/src/features/planSelection/containers/PlanSelectionScreen.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/features/planSelection/containers/PlanSelectionScreen.js')
-rw-r--r--src/features/planSelection/containers/PlanSelectionScreen.js10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/features/planSelection/containers/PlanSelectionScreen.js b/src/features/planSelection/containers/PlanSelectionScreen.js
index 6e8cdbf47..cb62f45d3 100644
--- a/src/features/planSelection/containers/PlanSelectionScreen.js
+++ b/src/features/planSelection/containers/PlanSelectionScreen.js
@@ -9,7 +9,7 @@ import UserStore from '../../../stores/UserStore';
9import PlanSelection from '../components/PlanSelection'; 9import PlanSelection from '../components/PlanSelection';
10import ErrorBoundary from '../../../components/util/ErrorBoundary'; 10import ErrorBoundary from '../../../components/util/ErrorBoundary';
11import { planSelectionStore, GA_CATEGORY_PLAN_SELECTION } from '..'; 11import { planSelectionStore, GA_CATEGORY_PLAN_SELECTION } from '..';
12import { gaEvent } from '../../../lib/analytics'; 12import { gaEvent, gaPage } from '../../../lib/analytics';
13 13
14const { dialog, app } = remote; 14const { dialog, app } = remote;
15 15
@@ -38,10 +38,6 @@ class PlanSelectionScreen extends Component {
38 intl: intlShape, 38 intl: intlShape,
39 }; 39 };
40 40
41 componentDidMount() {
42 gaEvent(GA_CATEGORY_PLAN_SELECTION, 'show');
43 }
44
45 upgradeAccount(planId) { 41 upgradeAccount(planId) {
46 const { upgradeAccount } = this.props.actions.payment; 42 const { upgradeAccount } = this.props.actions.payment;
47 43
@@ -80,6 +76,8 @@ class PlanSelectionScreen extends Component {
80 } 76 }
81 }} 77 }}
82 stayOnFree={() => { 78 stayOnFree={() => {
79 gaPage('/select-plan/downgrade');
80
83 const selection = dialog.showMessageBoxSync(app.mainWindow, { 81 const selection = dialog.showMessageBoxSync(app.mainWindow, {
84 type: 'question', 82 type: 'question',
85 message: intl.formatMessage(messages.dialogTitle), 83 message: intl.formatMessage(messages.dialogTitle),
@@ -101,7 +99,7 @@ class PlanSelectionScreen extends Component {
101 } else { 99 } else {
102 this.upgradeAccount(plans.personal.yearly.id); 100 this.upgradeAccount(plans.personal.yearly.id);
103 101
104 gaEvent(GA_CATEGORY_PLAN_SELECTION, 'SelectPlan', 'Revoke'); 102 gaEvent(GA_CATEGORY_PLAN_SELECTION, 'SelectPlan', 'Downgrade');
105 } 103 }
106 }} 104 }}
107 subscriptionExpired={user.team && user.team.state === 'expired' && !user.team.userHasDowngraded} 105 subscriptionExpired={user.team && user.team.state === 'expired' && !user.team.userHasDowngraded}