site-kit-wp
site-kit-wp copied to clipboard
Integrate `<ConversionTrackingToggle />` Component Into Ads and GA4 Module `<SettingsView />` Components
Feature Description
With the Conversion Tracking UI toggle component and associated settings/datastore now complete (see #8616), the toggle is ready to be integrated into both the settings area of the Ads module, as well as the GA4 module.
This issue focusses on the read only / view settings area of said modules, i.e the <SettingsView /> component of each module.
The enabled/disabled status for Conversion Tracking should be displayed in read-only form based on the state of the toggle (i.e if conversion tracking enabled (true) via the applicable datastore selector).
Please reference the "Conversion Event Tracking Toggle & Settings" area of the design doc for more detailed information.
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
- The
SettingsViewcomponent ofAdsandAnalyticsmodules should display theConversion trackinglabel and value - Value should be sourced from Conversion Tracking datastore and displayed as
EnabledorDisabledtext - It should match figma designs for both modules
Implementation Brief
- [ ] Update
assets/js/modules/ads/components/settings/SettingsView.js:- Use the selector added in #8615 to pull the conversion tracking enabled setting value
- Use
DisplaySettingcomponent to renderEnabledorDisabledtext whenadsPaxfeature flag is enabled - Use
Enhanced conversion trackingfor label - Follow the figma design
- [ ] Update
assets/js/modules/analytics-4/components/settings/SettingsView.js- Do the same as in Ads module settings view component
- Follow the figma design
Test Coverage
- Update VRT images
QA Brief
Changelog entry
AC ✅
IB ✅
Note for QA: I've made a few changes which don't match the designs above but, these were already inconsistent relative to the current state there (mostly for GA). I've left a note in Figma too, so we should mostly be reviewing this visually for consistency with the rest of the settings.
QA Update ✅
- Tested on dev environment.
- Figma have different design and current is more aligned with existing styles.
- Verified toggled settings for both Analytics and Ads module.
- Verified the
SettingsViewcomponent of Ads and Analytics modules display the Conversion tracking label and value. - Verified value are sourced from Conversion Tracking datastore and displayed as Enabled or Disabled text.
Ads module
https://github.com/google/site-kit-wp/assets/94359491/ad8b8f77-a880-4d63-ab84-4d2cbd35a108
https://github.com/google/site-kit-wp/assets/94359491/2020b2fa-ad9d-47f3-9e30-2bbc54036dec
Analytics module
https://github.com/google/site-kit-wp/assets/94359491/02b4ae7f-a35d-40e1-b02d-282664b45106