fix(analytics): remove spurious click tracking (#10469)

This commit is contained in:
Sabe Jones
2018-06-27 12:12:51 -05:00
committed by Matteo Pagliazzi
parent 0062e5b1f1
commit 8969b755a6
5 changed files with 1 additions and 32 deletions

View File

@@ -58,7 +58,6 @@
<script>
import Avatar from '../avatar';
import { mapState } from 'client/libs/store';
import * as Analytics from 'client/libs/analytics';
import percent from '../../../common/script/libs/percent';
import {maxHealth} from '../../../common/script/index';
@@ -82,14 +81,6 @@ export default {
return `${Math.ceil(this.user.stats.hp)} / ${this.maxHealth}`;
},
},
mounted () {
Analytics.track({
hitType: 'event',
eventCategory: 'button',
eventAction: 'click',
eventLabel: 'Health Warning',
});
},
methods: {
close () {
this.$root.$emit('bv::hide::modal', 'low-health');

View File

@@ -164,12 +164,6 @@ export default {
},
methods: {
shareUserId () {
Analytics.track({
hitType: 'event',
eventCategory: 'button',
eventAction: 'click',
eventLabel: 'Health Warning',
});
this.shareUserIdShown = !this.shareUserIdShown;
},
async createParty () {

View File

@@ -365,13 +365,6 @@ export default {
alert(this.$t('notEnoughGems'));
return;
// @TODO return $rootScope.openModal('buyGems', {track:"Gems > Gems > Create Group"});
// @TODO when modal is implemented, enable analytics
/* Analytics.track({
hitType: 'event',
eventCategory: 'button',
eventAction: 'click',
eventLabel: 'Health Warning',
}); */
}
let errors = [];

View File

@@ -54,7 +54,6 @@ import { mapState } from 'client/libs/store';
import filter from 'lodash/filter';
import map from 'lodash/map';
import notifications from 'client/mixins/notifications';
import * as Analytics from 'client/libs/analytics';
export default {
mixins: [notifications],
@@ -65,14 +64,6 @@ export default {
emails: [],
};
},
mounted () {
Analytics.track({
hitType: 'event',
eventCategory: 'button',
eventAction: 'click',
eventLabel: 'Invite Friends',
});
},
computed: {
...mapState({user: 'user.data'}),
inviter () {

View File

@@ -211,7 +211,7 @@ export default {
// @TODO: {keyboard:false, backdrop:'static'}
} else if (after <= 30 && !this.user.flags.warnedLowHealth) {
this.$root.$emit('bv::show::modal', 'low-health');
// @TODO: {keyboard:false, backdrop:'static', controller:'UserCtrl', track:'Health Warning'}
// @TODO: {keyboard:false, backdrop:'static', controller:'UserCtrl'}
}
if (after === before) return;
if (this.user.stats.lvl === 0) return;