diff options
author | fragosti <francesco.agosti93@gmail.com> | 2018-07-12 03:14:23 +0800 |
---|---|---|
committer | fragosti <francesco.agosti93@gmail.com> | 2018-07-12 03:14:23 +0800 |
commit | 9131a72a47690912db9b536186d05120daabd115 (patch) | |
tree | edbf0fb3b572a9422410b6fac9f47c103c1c0218 /packages/website/ts/components/onboarding | |
parent | d319b53e23047d4ff62415555475ef6da5f3d774 (diff) | |
download | dexon-sol-tools-9131a72a47690912db9b536186d05120daabd115.tar.gz dexon-sol-tools-9131a72a47690912db9b536186d05120daabd115.tar.zst dexon-sol-tools-9131a72a47690912db9b536186d05120daabd115.zip |
Replace calls to google analytics with calls to heap
Diffstat (limited to 'packages/website/ts/components/onboarding')
-rw-r--r-- | packages/website/ts/components/onboarding/portal_onboarding_flow.tsx | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/packages/website/ts/components/onboarding/portal_onboarding_flow.tsx b/packages/website/ts/components/onboarding/portal_onboarding_flow.tsx index 20a8f0a32..63b98cee7 100644 --- a/packages/website/ts/components/onboarding/portal_onboarding_flow.tsx +++ b/packages/website/ts/components/onboarding/portal_onboarding_flow.tsx @@ -225,20 +225,25 @@ class PlainPortalOnboardingFlow extends React.Component<PortalOnboardingFlowProp (this.props.stepIndex === 0 && !this.props.isRunning && this.props.blockchainIsLoaded) || (!this.props.isRunning && !this.props.hasBeenClosed && this.props.blockchainIsLoaded) ) { - const networkName = sharedConstants.NETWORK_NAME_BY_ID[this.props.networkId]; - analytics.logEvent('Portal', 'Onboarding Started - Automatic', networkName, this.props.stepIndex); + analytics.track('Onboarding Started', { + reason: 'automatic', + stepIndex: this.props.stepIndex, + }); this.props.updateIsRunning(true); } } private _updateOnboardingStep(stepIndex: number): void { - const networkName = sharedConstants.NETWORK_NAME_BY_ID[this.props.networkId]; this.props.updateOnboardingStep(stepIndex); - analytics.logEvent('Portal', 'Update Onboarding Step', networkName, stepIndex); + analytics.track('Update Onboarding Step', { + stepIndex, + }); } private _closeOnboarding(): void { const networkName = sharedConstants.NETWORK_NAME_BY_ID[this.props.networkId]; this.props.updateIsRunning(false); - analytics.logEvent('Portal', 'Onboarding Closed', networkName, this.props.stepIndex); + analytics.track('OnboardingClosed', { + stepIndex: this.props.stepIndex, + }); } private _renderZrxAllowanceToggle(): React.ReactNode { const zrxToken = utils.getZrxToken(this.props.tokenByAddress); |