Skip to content

Add GA event tracking for the dashboard tour. #12030

@techanvil

Description

@techanvil

Feature Description

GA events should be added to keep track of interaction with the dashboard tour (see #11813 and #11814).


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

  • The following GA events should be tracked for the given actions. See the GA events sheet.
  • These changes are only active when the setupFlowRefresh feature flag is enabled.
Event Name Category Label Trigger Condition
feature_tooltip_view {viewContext}_dashboard-tour-sc number of the current tooltip element visibility the tooltip is rendered on the dashboard for the Search Console-only dashboard tour variant
feature_tooltip_dismiss {viewContext}_dashboard-tour-sc number of the current tooltip click user clicks "X" to close the tooltip
feature_tooltip_advance {viewContext}_dashboard-tour-sc number of the current tooltip click user clicks "Next"
feature_tooltip_return {viewContext}_dashboard-tour-sc number of the current tooltip click user clicks "Back"
feature_tooltip_complete {viewContext}_dashboard-tour-sc number of the current tooltip click user clicks "Got it" (feature tour successfully completed)
feature_tooltip_view {viewContext}_dashboard-tour-ga4 number of the current tooltip element visibility the tooltip is rendered on the dashboard for the Analytics-connected dashboard tour variant
feature_tooltip_dismiss {viewContext}_dashboard-tour-ga4 number of the current tooltip click user clicks "X" to close the tooltip
feature_tooltip_advance {viewContext}_dashboard-tour-ga4 number of the current tooltip click user clicks "Next"
feature_tooltip_return {viewContext}_dashboard-tour-ga4 number of the current tooltip click user clicks "Back"
feature_tooltip_complete {viewContext}_dashboard-tour-ga4 number of the current tooltip click user clicks "Got it" (feature tour successfully completed)
__________________________ ______________________________________ ________________________________ __________________ _______________________________

Implementation Brief

  • In assets/js/feature-tours/welcome.ts
    • When isAnalyticsConnected is true, gaEventCategory should be ${ viewContext }_dashboard-tour-ga4, else it needs to be ${ viewContext }_dashboard-tour-sc

Test Coverage

  • Update welcome.test.js to ensure it returns correct event category.

QA Brief

  • Set up Site Kit with setupFlowRefresh enabled
  • Trigger the tour either from the Welcome modal or the Help Menu
  • Ensure the tour events are triggered with the correct category (the {viewContext}_dashboard-tour-sc variant) according to the table in AC.
  • Activate Analytics and reverify the events, making sure the Analytics variant is used ({viewContext}_dashboard-tour-ga4)

Changelog entry

  • Ensure the correct GA events are tracked for the dashboard tour.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P0High priorityTeam MIssues for Squad 2Type: EnhancementImprovement of an existing feature

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions