mirror of
https://github.com/n8n-io/n8n.git
synced 2025-01-13 05:47:31 -08:00
feat: Add telemetry event when users click on templates link (#8625)
This commit is contained in:
parent
6bc1c3d7a8
commit
bf4f896373
|
@ -388,6 +388,9 @@ export default defineComponent({
|
||||||
workflow_id: this.workflowsStore.workflowId,
|
workflow_id: this.workflowsStore.workflowId,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
trackTemplatesClick() {
|
||||||
|
this.$telemetry.track('User clicked on templates', {});
|
||||||
|
},
|
||||||
async onUserActionToggle(action: string) {
|
async onUserActionToggle(action: string) {
|
||||||
switch (action) {
|
switch (action) {
|
||||||
case 'logout':
|
case 'logout':
|
||||||
|
@ -419,6 +422,14 @@ export default defineComponent({
|
||||||
},
|
},
|
||||||
async handleSelect(key: string) {
|
async handleSelect(key: string) {
|
||||||
switch (key) {
|
switch (key) {
|
||||||
|
case 'templates':
|
||||||
|
if (
|
||||||
|
this.settingsStore.isTemplatesEnabled &&
|
||||||
|
!this.templatesStore.hasCustomTemplatesHost
|
||||||
|
) {
|
||||||
|
this.trackTemplatesClick();
|
||||||
|
}
|
||||||
|
break;
|
||||||
case 'about': {
|
case 'about': {
|
||||||
this.trackHelpItemClick('about');
|
this.trackHelpItemClick('about');
|
||||||
this.uiStore.openModal(ABOUT_MODAL_KEY);
|
this.uiStore.openModal(ABOUT_MODAL_KEY);
|
||||||
|
|
Loading…
Reference in a new issue