google / site-kit-wp

Site Kit is a one-stop solution for WordPress users to use everything Google has to offer to make them successful on the web.
https://sitekit.withgoogle.com
Apache License 2.0
1.25k stars 291 forks source link

Add GA events for "Top Earning Pages" success notification #8214

Closed tofumatt closed 7 months ago

tofumatt commented 9 months ago

Feature Description

GA events (eg. trackEvent calls) should be added to the new "Top Earnings Pages" notification that appears after successful AdSense + GA4 integration/connection. There should be one when a user views the notification one when they click the "Show me" CTA button in the notification, and another when the user dismisses the notification with the "Got it" button.


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

Acceptance criteria

CTA widget screenshot:

Screenshot 2024-02-19 at 23 30 50

Implementation Brief

Test Coverage

QA Brief

Changelog entry

tofumatt commented 9 months ago

(Moving to stalled because this component doesn't exist yet.)

ivonac4 commented 9 months ago

@tofumatt is it maybe possible to add dependencies here? I don't know if the tickets for these component's exist already or not. In case they don't, can we add them later.

tofumatt commented 9 months ago

@ivonac4 Right now we don't have issues for it. In fact, I'm not quite sure what these events correspond to because I don't see mention of this component in the design doc either, I don't think.

@marrrmarrr Do you have a Figma design/screenshot/reference for the component that the view_overlay_CTA + {viewContext}_top-earning-pages-widget event corresponds to from the Analytics events document? I'm not sure what it's for, so I created this issue just to note that we hadn't implemented the event, but I'm actually not sure what it's for 😓

tofumatt commented 9 months ago

@ivonac4 I've updated this as blocked by #8238, now that we have that filed 😄

tofumatt commented 9 months ago

Leaving this one in AC with me until we move #8238 into IB, because the events fired will depend on how many (1 or 2) CTAs there are 🙂

eugene-manuilov commented 8 months ago

IB ✔️

wpdarren commented 8 months ago

QA Update: ✅

Verified:

When the AdSense + GA connected notification is shown the following trackEvent calls are made:

Screenshots ![image](https://github.com/google/site-kit-wp/assets/73545194/b42c73d9-2968-4b24-8887-50028ade9c2c) ![image](https://github.com/google/site-kit-wp/assets/73545194/f05f2086-7bb1-4c32-8657-587b3113bc23)