diff --git a/src/components/LeakyPaywall.vue b/src/components/LeakyPaywall.vue index f559e08f..5413770b 100644 --- a/src/components/LeakyPaywall.vue +++ b/src/components/LeakyPaywall.vue @@ -30,7 +30,7 @@ const isOverFreeLimit = computed(() => paywall.value.read.length >= config.value useTrackLink( computed(() => foundArticle.value?.element), (href) => ({ - event: 'article.link_clicked', + event: 'article.link_click', properties: { // Impossible to be null article_id: foundArticle.value?.id ?? '', @@ -136,7 +136,7 @@ whenever( whenever( isScrollOverThreshold, () => { - sendTrack('paywall.reached', { + sendTrack('paywall.reach', { pathname: location.value.pathname ?? '', article_id: foundArticle.value?.id ?? null, client_id: config.value.clientId, diff --git a/src/lib/tracking-schema.ts b/src/lib/tracking-schema.ts index d1a33b68..b0b1a6ea 100644 --- a/src/lib/tracking-schema.ts +++ b/src/lib/tracking-schema.ts @@ -2,9 +2,9 @@ import * as z from 'zod' import { articleScrollBack } from './tracking-schema/article-scroll-back' import { articleView } from './tracking-schema/article-view' import { pageView } from './tracking-schema/page-view' -import { paywallReached } from './tracking-schema/paywall-reached' +import { paywallReached } from './tracking-schema/paywall-reach' import { userSignIn } from './tracking-schema/subscriber-signin' -import { articleLinkClicked } from './tracking-schema/article-link-clicked' +import { articleLinkClicked } from './tracking-schema/article-link-click' import { paywallDisplay } from './tracking-schema/paywall-display' // We must import 1 by 1 or we will lost the type info here diff --git a/src/lib/tracking-schema/article-link-clicked.ts b/src/lib/tracking-schema/article-link-click.ts similarity index 86% rename from src/lib/tracking-schema/article-link-clicked.ts rename to src/lib/tracking-schema/article-link-click.ts index 3c40f738..004793c8 100644 --- a/src/lib/tracking-schema/article-link-clicked.ts +++ b/src/lib/tracking-schema/article-link-click.ts @@ -1,7 +1,7 @@ import { z } from 'zod' export const articleLinkClicked = defineTrackEvent({ - event: 'article.link_clicked', + event: 'article.link_click', properties: { pathname: z.string(), client_id: z.string(), diff --git a/src/lib/tracking-schema/paywall-reached.ts b/src/lib/tracking-schema/paywall-reach.ts similarity index 87% rename from src/lib/tracking-schema/paywall-reached.ts rename to src/lib/tracking-schema/paywall-reach.ts index 66c8261b..17cdfe9c 100644 --- a/src/lib/tracking-schema/paywall-reached.ts +++ b/src/lib/tracking-schema/paywall-reach.ts @@ -1,7 +1,7 @@ import { z } from 'zod' export const paywallReached = defineTrackEvent({ - event: 'paywall.reached', + event: 'paywall.reach', properties: { pathname: z.string(), client_id: z.string(),