diff --git a/src/components/ContentBar.vue b/src/components/ContentBar.vue index ed85e957..677504e5 100644 --- a/src/components/ContentBar.vue +++ b/src/components/ContentBar.vue @@ -98,6 +98,7 @@ import { ElRow as Row, ElSelect as Select, } from "element-plus"; +import tagging from '../services/tagging'; export default { name: "ContentBar", @@ -251,6 +252,15 @@ export default { }, 1200); }); //this.contextCardVisible = false; // Hide all context cards when switching viewers + + // GA Tracking + const viewCategory = this.entries.find(entry => entry.id === value); + tagging.sendEvent({ + 'event': 'interaction_event', + 'event_name': `portal_maps_toolbar_viewer_changed`, + 'category': viewCategory?.title || '', + 'location': 'map_toolbar' + }); } }, // setPopper with is needed as the flatmap context card does not have an image and has smaller with diff --git a/src/components/ContextCard.vue b/src/components/ContextCard.vue index 3958ba3f..0a5c671b 100644 --- a/src/components/ContextCard.vue +++ b/src/components/ContextCard.vue @@ -63,7 +63,7 @@
@@ -73,6 +73,7 @@ diff --git a/src/components/SplitFlow.vue b/src/components/SplitFlow.vue index acf08a61..a3f1078c 100644 --- a/src/components/SplitFlow.vue +++ b/src/components/SplitFlow.vue @@ -50,6 +50,7 @@ @connectivity-source-change="onConnectivitySourceChange" @filter-visibility="onFilterVisibility" @connectivity-item-close="onConnectivityItemClose" + @trackEvent="trackEvent" />