diff --git a/bin/copy-posthog-js b/bin/copy-posthog-js index 24bc26c761f1b..da49d8c904668 100755 --- a/bin/copy-posthog-js +++ b/bin/copy-posthog-js @@ -12,3 +12,4 @@ cp node_modules/posthog-js/dist/recorder-v2.js* frontend/dist/ cp node_modules/posthog-js/dist/surveys.js* frontend/dist/ cp node_modules/posthog-js/dist/exception-autocapture.js* frontend/dist/ cp node_modules/posthog-js/dist/web-vitals.js* frontend/dist/ +cp node_modules/posthog-js/dist/dead-clicks-autocapture.js* frontend/dist/ diff --git a/frontend/src/lib/taxonomy.tsx b/frontend/src/lib/taxonomy.tsx index a578556789410..0506c339a0ba1 100644 --- a/frontend/src/lib/taxonomy.tsx +++ b/frontend/src/lib/taxonomy.tsx @@ -153,6 +153,10 @@ export const CORE_FILTER_DEFINITIONS_BY_GROUP = { label: 'Rageclick', description: 'A user has rapidly and repeatedly clicked in a single place', }, + $dead_click: { + label: 'Dead click', + description: 'A user has clicked on something that is probably not clickable', + }, $exception: { label: 'Exception', description: 'Automatically captured exceptions from the client Sentry integration', @@ -1216,6 +1220,47 @@ export const CORE_FILTER_DEFINITIONS_BY_GROUP = { label: 'Surveys Activated', description: 'The surveys that were activated for this event.', }, + $dead_click_scroll_delay_ms: { + label: 'Dead click scroll delay in milliseconds', + description: 'The delay between a click and the next scroll event', + }, + $dead_click_mutation_delay_ms: { + label: 'Dead click mutation delay in milliseconds', + description: 'The delay between a click and the next mutation event', + }, + $dead_click_absolute_delay_ms: { + label: 'Dead click absolute delay in milliseconds', + description: 'The delay between a click and having seen no activity at all', + }, + $dead_click_selection_changed_delay_ms: { + label: 'Dead click selection changed delay in milliseconds', + description: 'The delay between a click and the next text selection change event', + }, + $dead_click_last_mutation_timestamp: { + label: 'Dead click last mutation timestamp', + description: 'debug signal time of the last mutation seen by dead click autocapture', + }, + $dead_click_event_timestamp: { + label: 'Dead click event timestamp', + description: 'debug signal time of the event that triggered dead click autocapture', + }, + $dead_click_scroll_timeout: { + label: 'Dead click scroll timeout', + description: 'whether the dead click autocapture passed the threshold for waiting for a scroll event', + }, + $dead_click_mutation_timeout: { + label: 'Dead click mutation timeout', + description: 'whether the dead click autocapture passed the threshold for waiting for a mutation event', + }, + $dead_click_absolute_timeout: { + label: 'Dead click absolute timeout', + description: 'whether the dead click autocapture passed the threshold for waiting for any activity', + }, + $dead_click_selection_changed_timeout: { + label: 'Dead click selection changed timeout', + description: + 'whether the dead click autocapture passed the threshold for waiting for a text selection change event', + }, }, numerical_event_properties: {}, // Same as event properties, see assignment below person_properties: {}, // Currently person properties are the same as event properties, see assignment below diff --git a/frontend/src/loadPostHogJS.tsx b/frontend/src/loadPostHogJS.tsx index 2c5a3285ef509..3a53bddc379df 100644 --- a/frontend/src/loadPostHogJS.tsx +++ b/frontend/src/loadPostHogJS.tsx @@ -50,6 +50,8 @@ export function loadPostHogJS(): void { _onCapture: (window as any)._cypress_posthog_captures ? (_, event) => (window as any)._cypress_posthog_captures.push(event) : undefined, + + capture_dead_clicks: true, }) )