Repository: google/site-kit-wp
Pull request #10601: Remove outdated feature tours and on demand tours.
Author: login: benbowler
Created: 2025-04-07T10:40:18Z | Merged: 2025-04-09T20:03:52Z

## Summary

<!-- Please reference the issue this PR addresses in the following list. -->
Addresses issue:

- #10574

## Relevant technical choices

<!-- Please describe your changes. -->

## PR Author Checklist

- [x] My code is tested and passes existing unit tests.
- [ ] My code has an appropriate set of unit tests which all pass.
- [x] My code is backward-compatible with WordPress 5.2 and PHP 7.4.
- [x] My code follows the [WordPress](https://make.wordpress.org/core/handbook/best-practices/coding-standards/) coding standards.
- [x] My code has proper inline documentation.
- [x] I have added a QA Brief on the issue linked above.
- [x] I have signed the Contributor License Agreement (see <https://cla.developers.google.com/>).

---------------

_Do not alter or remove anything below. The following sections will be managed by moderators only._

## Code Reviewer Checklist

- [x] Run the code.
- [x] Ensure the acceptance criteria are satisfied.
- [x] Reassess the implementation with the IB.
- [x] Ensure no unrelated changes are included.
- [x] Ensure CI checks pass.
- [x] Check Storybook where applicable.
- [x] Ensure there is a QA Brief.
- [x] Ensure there are no unexpected significant changes to file sizes.

## Merge Reviewer Checklist

- [ ] Ensure the PR has the correct target branch.
- [ ] Double-check that the PR is okay to be merged.
- [ ] Ensure the corresponding issue has a ZenHub release assigned.
- [ ] Add a changelog message to the issue.



Diff:
diff --git a/assets/js/components/KeyMetrics/ChangeMetricsLink.js b/assets/js/components/KeyMetrics/ChangeMetricsLink.js
index 8c91199e271..ae237f1cab6 100644
--- a/assets/js/components/KeyMetrics/ChangeMetricsLink.js
+++ b/assets/js/components/KeyMetrics/ChangeMetricsLink.js
@@ -63,7 +63,7 @@ export default function ChangeMetricsLink() {
 			<Link
 				secondary
 				linkButton
-				className="googlesitekit-widget-area__cta-link"
+				className="googlesitekit-widget-area__cta-link googlesitekit-km-change-metrics-cta"
 				onClick={ openMetricsSelectionPanel }
 				leadingIcon={ <PencilIcon width={ 22 } height={ 22 } /> }
 			>
diff --git a/assets/js/components/dashboard-sharing/DashboardSharingDialog/index.js b/assets/js/components/dashboard-sharing/DashboardSharingDialog/index.js
index 0244fb867d3..65b487da29f 100644
--- a/assets/js/components/dashboard-sharing/DashboardSharingDialog/index.js
+++ b/assets/js/components/dashboard-sharing/DashboardSharingDialog/index.js
@@ -30,7 +30,6 @@ import {
 	createInterpolateElement,
 	useEffect,
 	useCallback,
-	useRef,
 } from '@wordpress/element';
 import { arrowLeft, Icon } from '@wordpress/icons';
 
@@ -40,7 +39,6 @@ import { arrowLeft, Icon } from '@wordpress/icons';
 import { useSelect, useDispatch } from 'googlesitekit-data';
 import { Button } from 'googlesitekit-components';
 import { CORE_UI } from '../../../googlesitekit/datastore/ui/constants';
-import { CORE_USER } from '../../../googlesitekit/datastore/user/constants';
 import { CORE_SITE } from '../../../googlesitekit/datastore/site/constants';
 import { CORE_MODULES } from '../../../googlesitekit/modules/datastore/constants';
 import {
@@ -49,7 +47,6 @@ import {
 	SETTINGS_DIALOG,
 } from '../DashboardSharingSettings/constants';
 import { BREAKPOINT_SMALL, useBreakpoint } from '../../../hooks/useBreakpoint';
-import sharingSettingsTour from '../../../feature-tours/dashboard-sharing-settings';
 import Portal from '../../Portal';
 import {
 	Dialog,
@@ -66,7 +63,6 @@ export default function DashboardSharingDialog() {
 	const { y } = useWindowScroll();
 
 	const { setValue } = useDispatch( CORE_UI );
-	const { triggerOnDemandTour } = useDispatch( CORE_USER );
 	const { rollbackSharingSettings } = useDispatch( CORE_MODULES );
 
 	const settingsDialogOpen = useSelect(
@@ -87,14 +83,6 @@ export default function DashboardSharingDialog() {
 		);
 	} );
 
-	const triggeredTourRef = useRef();
-	const handleTriggerOnDemandTour = useCallback( () => {
-		if ( ! triggeredTourRef.current ) {
-			triggeredTourRef.current = true;
-			triggerOnDemandTour( sharingSettingsTour );
-		}
-	}, [ triggerOnDemandTour ] );
-
 	const dialogStyles = {};
 	// On mobile, the dialog box's flexbox is set to stretch items within to cover
 	// the whole screen. But we have to move the box and adjust its height below the
@@ -144,7 +132,6 @@ export default function DashboardSharingDialog() {
 		<Portal>
 			<Dialog
 				open={ settingsDialogOpen || resetDialogOpen }
-				onOpen={ handleTriggerOnDemandTour }
 				onClose={ closeDialog }
 				className="googlesitekit-dialog googlesitekit-sharing-settings-dialog"
 				style={ dialogStyles }
diff --git a/assets/js/feature-tours/dashboard-sharing-settings.js b/assets/js/feature-tours/dashboard-sharing-settings.js
deleted file mode 100644
index f3c6be29b2a..00000000000
--- a/assets/js/feature-tours/dashboard-sharing-settings.js
+++ /dev/null
@@ -1,72 +0,0 @@
-/**
- * Dashboard Sharing Settings Feature Tour.
- *
- * Site Kit by Google, Copyright 2022 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * External dependencies
- */
-import { EVENTS } from 'react-joyride';
-
-/**
- * WordPress dependencies
- */
-import { __ } from '@wordpress/i18n';
-
-/*
- * Internal dependencies
- */
-import { CORE_USER } from '../googlesitekit/datastore/user/constants';
-
-const { hasMultipleAdmins } = global._googlesitekitUserData || {};
-
-const steps = [
-	{
-		target: '.googlesitekit-dashboard-sharing-settings__main .googlesitekit-dashboard-sharing-settings__column--view',
-		title: __( 'Manage view access for other roles', 'google-site-kit' ),
-		content: __(
-			'Grant access to the view-only dashboard for each service for the specific roles you want. Users will see the Site Kit dashboard with only the services that have been shared with them without needing to sign-in with Google.',
-			'google-site-kit'
-		),
-		placement: 'auto',
-	},
-];
-
-if ( hasMultipleAdmins ) {
-	steps.push( {
-		target: '.googlesitekit-dashboard-sharing-settings__main .googlesitekit-dashboard-sharing-settings__column--manage',
-		title: __( 'Share management with other admins', 'google-site-kit' ),
-		content: __(
-			'By default only the user who connects a service can control who it is shared with. This setting optionally lets these users allow any other admin signed in with Google to manage the roles a service is shared with.',
-			'google-site-kit'
-		),
-		placement: 'auto',
-	} );
-}
-
-export default {
-	slug: 'dashboardSharingSettings',
-	gaEventCategory: ( viewContext ) => `${ viewContext }_dashboard-sharing`,
-	steps,
-	callback: ( { type }, { select, dispatch } ) => {
-		if (
-			EVENTS.TOOLTIP === type &&
-			select( CORE_USER ).isTourDismissed( 'dashboardSharing' ) === false
-		) {
-			dispatch( CORE_USER ).dismissTour( 'dashboardSharing' );
-		}
-	},
-};
diff --git a/assets/js/feature-tours/dashboard-sharing.js b/assets/js/feature-tours/dashboard-sharing.js
deleted file mode 100644
index e787db4e4b8..00000000000
--- a/assets/js/feature-tours/dashboard-sharing.js
+++ /dev/null
@@ -1,85 +0,0 @@
-/**
- * Dashboard Sharing Feature Tour.
- *
- * Site Kit by Google, Copyright 2022 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * WordPress dependencies
- */
-import { __ } from '@wordpress/i18n';
-import { EVENTS, ACTIONS, STATUS } from 'react-joyride';
-
-/*
- * Internal dependencies
- */
-import { VIEW_CONTEXT_MAIN_DASHBOARD } from '../googlesitekit/constants';
-import settingsTour from './dashboard-sharing-settings';
-import { CORE_UI } from '../googlesitekit/datastore/ui/constants';
-import { CORE_USER } from '../googlesitekit/datastore/user/constants';
-import { SETTINGS_DIALOG } from '../components/dashboard-sharing/DashboardSharingSettings/constants';
-
-let viewedAllSteps;
-
-const dashboardSharing = {
-	slug: 'dashboardSharing',
-	contexts: [ VIEW_CONTEXT_MAIN_DASHBOARD ],
-	version: '1.85.0',
-	gaEventCategory: ( viewContext ) => `${ viewContext }_dashboard-sharing`,
-	steps: [
-		{
-			target: '.googlesitekit-sharing-settings__button',
-			title: __( 'New! Dashboard sharing', 'google-site-kit' ),
-			content: __(
-				'Share a view-only version of your dashboard with other WordPress roles',
-				'google-site-kit'
-			),
-			placement: 'bottom-start',
-		},
-		...settingsTour.steps,
-	],
-	callback: ( data, { select, dispatch } ) => {
-		const { action, index, size, type, status } = data;
-
-		const dialogOpen = select( CORE_UI ).getValue( SETTINGS_DIALOG );
-
-		// Open sharing settings when transitioning to the second step from the first.
-		if ( ACTIONS.NEXT === action && index === 0 ) {
-			dispatch( CORE_UI ).setValue( SETTINGS_DIALOG, true );
-		}
-
-		// Close the dialog if the tour is ended or we end up back on the first step.
-		if (
-			ACTIONS.STOP === action ||
-			ACTIONS.CLOSE === action ||
-			( index === 0 && dialogOpen ) ||
-			( action === ACTIONS.NEXT && status === STATUS.FINISHED )
-		) {
-			dispatch( CORE_UI ).setValue( SETTINGS_DIALOG, false );
-		}
-
-		if (
-			index + 1 === size &&
-			EVENTS.TOOLTIP === type &&
-			! viewedAllSteps
-		) {
-			viewedAllSteps = true;
-			// If the user has "seen" all the steps, dismiss the settings tour.
-			dispatch( CORE_USER ).dismissTour( settingsTour.slug );
-		}
-	},
-};
-
-export default dashboardSharing;
diff --git a/assets/js/feature-tours/ga4-reporting.js b/assets/js/feature-tours/ga4-reporting.js
deleted file mode 100644
index a5d3a29db40..00000000000
--- a/assets/js/feature-tours/ga4-reporting.js
+++ /dev/null
@@ -1,127 +0,0 @@
-/**
- * Site Kit by Google, Copyright 2023 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * WordPress dependencies
- */
-import { __ } from '@wordpress/i18n';
-import { createInterpolateElement } from '@wordpress/element';
-
-/*
- * Internal dependencies
- */
-import { VIEW_CONTEXT_MAIN_DASHBOARD } from '../googlesitekit/constants';
-import SupportLink from '../components/SupportLink';
-
-const noBorderStyles = {
-	border: '0',
-};
-
-const reportTableStyles = {
-	spotlight: {
-		...noBorderStyles,
-		// The `15px` margins on the top and bottom, plus half of the padding
-		// added in these styles.
-		margin: '-42px 0 0 6px',
-		padding: '12px 0 20px 0',
-	},
-};
-
-const ga4Reporting = {
-	slug: 'ga4Reporting',
-	contexts: [ VIEW_CONTEXT_MAIN_DASHBOARD ],
-	version: '1.103.0',
-	gaEventCategory: ( viewContext ) => `${ viewContext }_ga4-metrics`,
-	steps: [
-		{
-			target: '.googlesitekit-data-block--conversions .googlesitekit-data-block__title, .googlesitekit-analytics-cta--setup-conversions',
-			styles: { spotlight: noBorderStyles },
-			title: __(
-				'See the new metrics from Google Analytics',
-				'google-site-kit'
-			),
-			content: createInterpolateElement(
-				__(
-					'"Conversions" have replaced "Goals," since "Goals" no longer exist in GA4. <a>Learn how to set up Conversions</a>',
-					'google-site-kit'
-				),
-				{
-					a: (
-						<SupportLink
-							path="/analytics/answer/12966437"
-							inverse
-							external
-							hideExternalIndicator
-							standalone
-						/>
-					),
-				}
-			),
-			placement: 'auto',
-		},
-		{
-			target: '.googlesitekit-table__head-item--sessions:not(.googlesitekit-table__head-item--badge)',
-			styles: reportTableStyles,
-			title: __(
-				'"Sessions" has replaced "Unique Pageviews"',
-				'google-site-kit'
-			),
-			content: createInterpolateElement(
-				__(
-					'A session is a period of time during which a user interacts with your website or app. <a>Learn more</a>',
-					'google-site-kit'
-				),
-				{
-					a: (
-						<SupportLink
-							path="/analytics/answer/9191807"
-							inverse
-							external
-							hideExternalIndicator
-							standalone
-						/>
-					),
-				}
-			),
-			placement: 'auto',
-		},
-		{
-			target: '.googlesitekit-table__head-item--engagement-rate:not(.googlesitekit-table__head-item--badge)',
-			title: __( 'New metric: engagement rate', 'google-site-kit' ),
-			styles: reportTableStyles,
-			content: createInterpolateElement(
-				__(
-					'Engagement rate shows the percentage of engaged sessions, the opposite of bounce rate. <a>Learn more</a>',
-					'google-site-kit'
-				),
-				{
-					a: (
-						<SupportLink
-							path="/analytics/answer/11109416"
-							inverse
-							external
-							hideExternalIndicator
-							standalone
-						/>
-					),
-				}
-			),
-			placement: 'auto',
-		},
-	],
-};
-
-export default ga4Reporting;
diff --git a/assets/js/feature-tours/index.js b/assets/js/feature-tours/index.js
index c681f0828f6..70515004fb9 100644
--- a/assets/js/feature-tours/index.js
+++ b/assets/js/feature-tours/index.js
@@ -16,10 +16,5 @@
  * limitations under the License.
  */
 
-/**
- * Internal dependencies
- */
-import dashboardSharing from './dashboard-sharing';
-
 // Ordered tours.
-export default [ dashboardSharing ];
+export default [];
diff --git a/assets/js/modules/analytics-4/components/module/ModulePopularPagesWidgetGA4/index.js b/assets/js/modules/analytics-4/components/module/ModulePopularPagesWidgetGA4/index.js
index 8b11be1b017..a75ef2f9bd0 100644
--- a/assets/js/modules/analytics-4/components/module/ModulePopularPagesWidgetGA4/index.js
+++ b/assets/js/modules/analytics-4/components/module/ModulePopularPagesWidgetGA4/index.js
@@ -52,7 +52,6 @@ import {
 	useBreakpoint,
 } from '../../../../../hooks/useBreakpoint';
 import useViewOnly from '../../../../../hooks/useViewOnly';
-import ga4ReportingTour from '../../../../../feature-tours/ga4-reporting';
 
 function ModulePopularPagesWidgetGA4( props ) {
 	const { Widget, WidgetReportError } = props;
@@ -126,14 +125,9 @@ function ModulePopularPagesWidgetGA4( props ) {
 		return undefined !== error || ( reportLoaded && undefined !== titles );
 	} );
 
-	const isGA4ReportingTourActive = useSelect(
-		( select ) => select( CORE_USER ).getCurrentTour() === ga4ReportingTour
-	);
-
 	const loading = ! loaded || isGatheringData === undefined;
 
-	// Bypass loading state if showing GA4 tour.
-	if ( loading && ! isGA4ReportingTourActive ) {
+	if ( loading ) {
 		return (
 			<Widget Header={ Header } Footer={ Footer } noPadding>
 				<PreviewTable padding />
@@ -220,22 +214,14 @@ function ModulePopularPagesWidgetGA4( props ) {
 		},
 	];
 
-	let rows = report?.rows?.length ? cloneDeep( report.rows ) : [];
-	let ZeroState = ZeroDataMessage;
-	// Use a custom zero state when the GA4 reporting tour is active
-	// while data is still loading.
-	if ( loading && isGA4ReportingTourActive ) {
-		rows = [];
-		ZeroState = function () {
-			return <PreviewTable rows={ rows.length || 10 } />;
-		};
-	} else {
-		// Combine the titles from the pageTitles with the rows from the metrics report.
-		rows.forEach( ( row ) => {
-			const url = row.dimensionValues[ 0 ].value;
-			row.dimensionValues.unshift( { value: titles[ url ] } ); // We always have an entry for titles[url].
-		} );
-	}
+	const rows = report?.rows?.length ? cloneDeep( report.rows ) : [];
+	const ZeroState = ZeroDataMessage;
+
+	// Combine the titles from the pageTitles with the rows from the metrics report.
+	rows.forEach( ( row ) => {
+		const url = row.dimensionValues[ 0 ].value;
+		row.dimensionValues.unshift( { value: titles[ url ] } ); // We always have an entry for titles[url].
+	} );
 
 	const tabbedLayout =
 		breakpoint === BREAKPOINT_SMALL || breakpoint === BREAKPOINT_TABLET;
diff --git a/assets/js/modules/analytics-4/components/setup/SetupForm.test.js b/assets/js/modules/analytics-4/components/setup/SetupForm.test.js
index 21072a27a16..4d7efe6a940 100644
--- a/assets/js/modules/analytics-4/components/setup/SetupForm.test.js
+++ b/assets/js/modules/analytics-4/components/setup/SetupForm.test.js
@@ -27,7 +27,6 @@ import {
 	waitForDefaultTimeouts,
 } from '../../../../../../tests/js/utils';
 import { CORE_FORMS } from '../../../../googlesitekit/datastore/forms/constants';
-import { CORE_USER } from '../../../../googlesitekit/datastore/user/constants';
 import { MODULES_TAGMANAGER } from '../../../tagmanager/datastore/constants';
 import {
 	EDIT_SCOPE,
@@ -37,7 +36,6 @@ import {
 	MODULES_ANALYTICS_4,
 } from '../../datastore/constants';
 import * as fixtures from '../../datastore/__fixtures__';
-import ga4ReportingTour from '../../../../feature-tours/ga4-reporting';
 import SetupForm from './SetupForm';
 import { CORE_SITE } from '../../../../googlesitekit/datastore/site/constants';
 
@@ -188,10 +186,6 @@ describe( 'SetupForm', () => {
 			);
 		} );
 
-		registry
-			.dispatch( CORE_USER )
-			.receiveGetDismissedTours( [ ga4ReportingTour.slug ] );
-
 		muteFetch( REGEX_REST_GA4_SETTINGS );
 
 		fetchMock.post( REGEX_REST_DISMISS_ITEM, {
@@ -278,10 +272,6 @@ describe( 'SetupForm', () => {
 			grantedScopes: [ EDIT_SCOPE ],
 		} );
 
-		registry
-			.dispatch( CORE_USER )
-			.receiveGetDismissedTours( [ ga4ReportingTour.slug ] );
-
 		fetchMock.post( REGEX_REST_GA4_CREATE_PROPERTY, {
 			status: 200,
 			body: properties[ 0 ],
@@ -373,10 +363,6 @@ describe( 'SetupForm', () => {
 			grantedScopes: [ EDIT_SCOPE ],
 		} );
 
-		registry
-			.dispatch( CORE_USER )
-			.receiveGetDismissedTours( [ ga4ReportingTour.slug ] );
-
 		fetchMock.post( REGEX_REST_GA4_CREATE_PROPERTY, {
 			status: 403,
 			body: {
diff --git a/assets/js/modules/search-console/components/dashboard/SearchFunnelWidgetGA4/Overview/index.js b/assets/js/modules/search-console/components/dashboard/SearchFunnelWidgetGA4/Overview/index.js
index f247064d65d..7d88a62121f 100644
--- a/assets/js/modules/search-console/components/dashboard/SearchFunnelWidgetGA4/Overview/index.js
+++ b/assets/js/modules/search-console/components/dashboard/SearchFunnelWidgetGA4/Overview/index.js
@@ -27,18 +27,17 @@ import { isPlainObject } from 'lodash';
 /**
  * WordPress dependencies
  */
-import { useCallback, useEffect } from '@wordpress/element';
+import { useCallback } from '@wordpress/element';
 import { __ } from '@wordpress/i18n';
 
 /**
  * Internal dependencies
  */
-import { useSelect, useDispatch, useInViewSelect } from 'googlesitekit-data';
+import { useSelect, useInViewSelect } from 'googlesitekit-data';
 import { Grid, Row, Cell } from '../../../../../../material-components';
 import { extractSearchConsoleDashboardData } from '../../../../util';
 import { calculateChange, trackEvent } from '../../../../../../util';
 import { CORE_MODULES } from '../../../../../../googlesitekit/modules/datastore/constants';
-import { CORE_UI } from '../../../../../../googlesitekit/datastore/ui/constants';
 import { CORE_USER } from '../../../../../../googlesitekit/datastore/user/constants';
 import { CORE_SITE } from '../../../../../../googlesitekit/datastore/site/constants';
 import { MODULES_SEARCH_CONSOLE } from '../../../../datastore/constants';
@@ -52,7 +51,6 @@ import useViewOnly from '../../../../../../hooks/useViewOnly';
 import useViewContext from '../../../../../../hooks/useViewContext';
 import OptionalCells from './OptionalCells';
 import NewBadge from '../../../../../../components/NewBadge';
-import ga4ReportingTour from '../../../../../../feature-tours/ga4-reporting';
 import DataBlockGroup from '../../../../../../components/DataBlockGroup';
 
 function getDatapointAndChange( report, selectedStat, divider = 1 ) {
@@ -102,10 +100,6 @@ export default function Overview( props ) {
 		return select( CORE_USER ).canViewSharedModule( 'analytics-4' );
 	} );
 
-	const canShowGA4ReportingFeatureTour = useSelect( ( select ) => {
-		return select( CORE_UI ).getValue( 'showGA4ReportingTour' );
-	} );
-
 	const ga4ModuleConnected = useSelect( ( select ) =>
 		select( CORE_MODULES ).isModuleConnected( 'analytics-4' )
 	);
@@ -179,24 +173,6 @@ export default function Overview( props ) {
 		! error &&
 		! showRecoverableAnalytics;
 
-	const { triggerOnDemandTour } = useDispatch( CORE_USER );
-	useEffect( () => {
-		if (
-			! showGA4 ||
-			! canShowGA4ReportingFeatureTour ||
-			dashboardType !== DASHBOARD_TYPE_MAIN
-		) {
-			return;
-		}
-
-		triggerOnDemandTour( ga4ReportingTour );
-	}, [
-		showGA4,
-		dashboardType,
-		triggerOnDemandTour,
-		canShowGA4ReportingFeatureTour,
-	] );
-
 	const onGA4NewBadgeLearnMoreClick = useCallback( () => {
 		trackEvent( `${ viewContext }_ga4-new-badge`, 'click_learn_more_link' );
 	}, [ viewContext ] );


Reviews:
user: login: 10upsimon
body: @benbowler changes LGTM ✅  Moving to MR
state: APPROVED
author_association: CONTRIBUTOR
submitted_at: 2025-04-07T13:06:41Z
user: login: aaemnnosttv
body: Pending question to Mariya
state: COMMENTED
author_association: COLLABORATOR
submitted_at: 2025-04-07T18:35:06Z
user: login: aaemnnosttv
state: COMMENTED
author_association: COLLABORATOR
submitted_at: 2025-04-08T18:05:16Z
user: login: aaemnnosttv
body: Thanks @benbowler, and apologies for the change but we actually want to keep the on-demand shared key metrics tour. All the rest can go though. I'll update the AC to reflect this change.
state: CHANGES_REQUESTED
author_association: COLLABORATOR
submitted_at: 2025-04-08T18:06:38Z
user: login: benbowler
state: COMMENTED
author_association: COLLABORATOR
submitted_at: 2025-04-09T10:48:15Z
user: login: eugene-manuilov
body: LGMT. Just one change is suggested to remove an excessive comment. I'll apply it myself.
state: CHANGES_REQUESTED
author_association: COLLABORATOR
submitted_at: 2025-04-09T15:09:07Z
user: login: eugene-manuilov
state: APPROVED
author_association: COLLABORATOR
submitted_at: 2025-04-09T15:09:31Z

Review comments:
diff_hunk: @@ -1,59 +0,0 @@
-/**
- * Change metrics feature tour hook.
- *
- * Site Kit by Google, Copyright 2023 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * External dependencies
- */
-import { useEffect } from '@wordpress/element';
-
-/**
- * Internal dependencies
- */
-import { useSelect, useDispatch } from 'googlesitekit-data';
-import { CORE_SITE } from '../../../googlesitekit/datastore/site/constants';
-import { CORE_USER } from '../../../googlesitekit/datastore/user/constants';
-import sharedKeyMetrics from '../../../feature-tours/shared-key-metrics';
-
-/**
- * Triggers on demand tour for shared key metrics if all conditions are met.
- *
- * @since 1.113.0
- *
- * @param {boolean} renderChangeMetricLink If metric link meets the conditions to render.
- */
-export const useChangeMetricsFeatureTourEffect = ( renderChangeMetricLink ) => {
-	const keyMetricsSetupCompletedBy = useSelect( ( select ) =>
-		select( CORE_SITE ).getKeyMetricsSetupCompletedBy()
-	);
-	const currentUserID = useSelect( ( select ) =>
-		select( CORE_USER ).getID()
-	);
-	const { triggerOnDemandTour } = useDispatch( CORE_USER );
-
-	const isUserEligibleForTour =
-		Number.isInteger( keyMetricsSetupCompletedBy ) &&
-		Number.isInteger( currentUserID ) &&
-		keyMetricsSetupCompletedBy > 0 &&
-		currentUserID !== keyMetricsSetupCompletedBy;
-
-	useEffect( () => {
-		if ( renderChangeMetricLink && isUserEligibleForTour ) {
-			triggerOnDemandTour( sharedKeyMetrics );
path: assets/js/components/KeyMetrics/hooks/useChangeMetricsFeatureTourEffect.js
user: login: aaemnnosttv
body: Looking at this again, I think we may want to keep this one (or repurpose into a tooltip maybe) since it isn't really a standard tour that is only shown to users who upgraded from an older version of SK. 
created_at: 2025-04-07T18:34:29Z
author_association: COLLABORATOR
diff_hunk: @@ -1,59 +0,0 @@
-/**
- * Change metrics feature tour hook.
- *
- * Site Kit by Google, Copyright 2023 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * External dependencies
- */
-import { useEffect } from '@wordpress/element';
-
-/**
- * Internal dependencies
- */
-import { useSelect, useDispatch } from 'googlesitekit-data';
-import { CORE_SITE } from '../../../googlesitekit/datastore/site/constants';
-import { CORE_USER } from '../../../googlesitekit/datastore/user/constants';
-import sharedKeyMetrics from '../../../feature-tours/shared-key-metrics';
-
-/**
- * Triggers on demand tour for shared key metrics if all conditions are met.
- *
- * @since 1.113.0
- *
- * @param {boolean} renderChangeMetricLink If metric link meets the conditions to render.
- */
-export const useChangeMetricsFeatureTourEffect = ( renderChangeMetricLink ) => {
-	const keyMetricsSetupCompletedBy = useSelect( ( select ) =>
-		select( CORE_SITE ).getKeyMetricsSetupCompletedBy()
-	);
-	const currentUserID = useSelect( ( select ) =>
-		select( CORE_USER ).getID()
-	);
-	const { triggerOnDemandTour } = useDispatch( CORE_USER );
-
-	const isUserEligibleForTour =
-		Number.isInteger( keyMetricsSetupCompletedBy ) &&
-		Number.isInteger( currentUserID ) &&
-		keyMetricsSetupCompletedBy > 0 &&
-		currentUserID !== keyMetricsSetupCompletedBy;
-
-	useEffect( () => {
-		if ( renderChangeMetricLink && isUserEligibleForTour ) {
-			triggerOnDemandTour( sharedKeyMetrics );
path: assets/js/components/KeyMetrics/hooks/useChangeMetricsFeatureTourEffect.js
user: login: aaemnnosttv
body: Confirmed that we do want to keep this one. I'll update the AC
created_at: 2025-04-08T18:05:16Z
author_association: COLLABORATOR
diff_hunk: @@ -1,59 +0,0 @@
-/**
- * Change metrics feature tour hook.
- *
- * Site Kit by Google, Copyright 2023 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * External dependencies
- */
-import { useEffect } from '@wordpress/element';
-
-/**
- * Internal dependencies
- */
-import { useSelect, useDispatch } from 'googlesitekit-data';
-import { CORE_SITE } from '../../../googlesitekit/datastore/site/constants';
-import { CORE_USER } from '../../../googlesitekit/datastore/user/constants';
-import sharedKeyMetrics from '../../../feature-tours/shared-key-metrics';
-
-/**
- * Triggers on demand tour for shared key metrics if all conditions are met.
- *
- * @since 1.113.0
- *
- * @param {boolean} renderChangeMetricLink If metric link meets the conditions to render.
- */
-export const useChangeMetricsFeatureTourEffect = ( renderChangeMetricLink ) => {
-	const keyMetricsSetupCompletedBy = useSelect( ( select ) =>
-		select( CORE_SITE ).getKeyMetricsSetupCompletedBy()
-	);
-	const currentUserID = useSelect( ( select ) =>
-		select( CORE_USER ).getID()
-	);
-	const { triggerOnDemandTour } = useDispatch( CORE_USER );
-
-	const isUserEligibleForTour =
-		Number.isInteger( keyMetricsSetupCompletedBy ) &&
-		Number.isInteger( currentUserID ) &&
-		keyMetricsSetupCompletedBy > 0 &&
-		currentUserID !== keyMetricsSetupCompletedBy;
-
-	useEffect( () => {
-		if ( renderChangeMetricLink && isUserEligibleForTour ) {
-			triggerOnDemandTour( sharedKeyMetrics );
path: assets/js/components/KeyMetrics/hooks/useChangeMetricsFeatureTourEffect.js
user: login: benbowler
body: Sounds good, I raised this in the IB originally as I agree some tours that appear when a new feature is enabled make sense to keep longer term.
created_at: 2025-04-09T10:48:14Z
author_association: COLLABORATOR
diff_hunk: @@ -63,7 +63,8 @@ export default function ChangeMetricsLink() {
 			<Link
 				secondary
 				linkButton
-				className="googlesitekit-widget-area__cta-link"
+				// The googlesitekit-km-change-metrics-cta class is required for the shared key metrics feature tour to display.
path: assets/js/components/KeyMetrics/ChangeMetricsLink.js
user: login: eugene-manuilov
body: ```suggestion
```
created_at: 2025-04-09T15:06:08Z
author_association: COLLABORATOR

PR comments:
user: login: github-actions[bot]
created_at: 2025-04-07T10:47:00Z
body: **Size Change:** -3.74 kB (-0.18%) 

**Total Size:** 2.08 MB

| Filename | Size | Change |
| :--- | :---: | :---: |
| `./dist/assets/js/googlesitekit-datastore-user-********************.js` | 27.2 kB | -1.24 kB (-4.36%) |

<details><summary>ℹ️ <strong>View Unchanged</strong></summary>

| Filename | Size | Change |
| :--- | :---: | :---: |
| `./dist/assets/css/googlesitekit-admin-css-********************.min.css` | 64.1 kB | 0 B |
| `./dist/assets/css/googlesitekit-adminbar-css-********************.min.css` | 11.8 kB | 0 B |
| `./dist/assets/css/googlesitekit-authorize-application-css-********************.min.css` | 846 B | 0 B |
| `./dist/assets/css/googlesitekit-wp-dashboard-css-********************.min.css` | 8.48 kB | 0 B |
| `./dist/assets/js/33-********************.js` | 2.76 kB | 0 B |
| `./dist/assets/js/34-********************.js` | 2.25 kB | 0 B |
| `./dist/assets/js/35-********************.js` | 3.64 kB | 0 B |
| `./dist/assets/js/36-********************.js` | 935 B | 0 B |
| `./dist/assets/js/37-********************.js` | 892 B | -1 B (-0.11%) |
| `./dist/assets/js/38-********************.js` | 1.61 kB | 0 B |
| `./dist/assets/js/39-********************.js` | 1.57 kB | 0 B |
| `./dist/assets/js/40-********************.js` | 1.61 kB | 0 B |
| `./dist/assets/js/41-********************.js` | 1.59 kB | 0 B |
| `./dist/assets/js/42-********************.js` | 1.83 kB | 0 B |
| `./dist/assets/js/43-********************.js` | 3.12 kB | 0 B |
| `./dist/assets/js/analytics-advanced-tracking-********************.js` | 901 B | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/block-editor-plugin/editor-styles.css` | 124 B | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/block-editor-plugin/editor-styles.js` | 492 B | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/block-editor-plugin/index.js` | 7.97 kB | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/common/editor-styles.css` | 307 B | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/common/editor-styles.js` | 491 B | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/contribute-with-google/index.js` | 9.12 kB | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/contribute-with-google/non-site-kit-user.js` | 8.62 kB | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/subscribe-with-google/index.js` | 9.13 kB | 0 B |
| `./dist/assets/js/blocks/reader-revenue-manager/subscribe-with-google/non-site-kit-user.js` | 8.63 kB | 0 B |
| `./dist/assets/js/blocks/sign-in-with-google/editor-styles.css` | 84 B | 0 B |
| `./dist/assets/js/blocks/sign-in-with-google/editor-styles.js` | 492 B | 0 B |
| `./dist/assets/js/blocks/sign-in-with-google/index.js` | 18.1 kB | 0 B |
| `./dist/assets/js/googlesitekit-activation-********************.js` | 23.9 kB | +2 B (+0.01%) |
| `./dist/assets/js/googlesitekit-ad-blocking-recovery-********************.js` | 54.5 kB | -14 B (-0.03%) |
| `./dist/assets/js/googlesitekit-adminbar-********************.js` | 34.7 kB | -3 B (-0.01%) |
| `./dist/assets/js/googlesitekit-api-********************.js` | 10.1 kB | +2 B (+0.02%) |
| `./dist/assets/js/googlesitekit-components-gm2-********************.js` | 6.46 kB | 0 B |
| `./dist/assets/js/googlesitekit-components-gm3-********************.js` | 10.1 kB | 0 B |
| `./dist/assets/js/googlesitekit-consent-mode-********************.js` | 25.6 kB | 0 B |
| `./dist/assets/js/googlesitekit-data-********************.js` | 2.37 kB | 0 B |
| `./dist/assets/js/googlesitekit-datastore-forms-********************.js` | 8.94 kB | -1 B (-0.01%) |
| `./dist/assets/js/googlesitekit-datastore-location-********************.js` | 2.08 kB | -1 B (-0.05%) |
| `./dist/assets/js/googlesitekit-datastore-site-********************.js` | 20.4 kB | +5 B (+0.02%) |
| `./dist/assets/js/googlesitekit-datastore-ui-********************.js` | 10 kB | -1 B (-0.01%) |
| `./dist/assets/js/googlesitekit-entity-dashboard-********************.js` | 80.8 kB | -592 B (-0.73%) |
| `./dist/assets/js/googlesitekit-events-provider-contact-form-7-********************.js` | 646 B | 0 B |
| `./dist/assets/js/googlesitekit-events-provider-easy-digital-downloads-********************.js` | 624 B | 0 B |
| `./dist/assets/js/googlesitekit-events-provider-mailchimp-********************.js` | 630 B | 0 B |
| `./dist/assets/js/googlesitekit-events-provider-ninja-forms-********************.js` | 712 B | 0 B |
| `./dist/assets/js/googlesitekit-events-provider-optin-monster-********************.js` | 675 B | 0 B |
| `./dist/assets/js/googlesitekit-events-provider-popup-maker-********************.js` | 634 B | 0 B |
| `./dist/assets/js/googlesitekit-events-provider-woocommerce-********************.js` | 657 B | 0 B |
| `./dist/assets/js/googlesitekit-events-provider-wpforms-********************.js` | 633 B | 0 B |
| `./dist/assets/js/googlesitekit-i18n-********************.js` | 3.93 kB | 0 B |
| `./dist/assets/js/googlesitekit-main-dashboard-********************.js` | 153 kB | -525 B (-0.34%) |
| `./dist/assets/js/googlesitekit-metric-selection-********************.js` | 52.6 kB | -13 B (-0.02%) |
| `./dist/assets/js/googlesitekit-modules-********************.js` | 22.4 kB | +20 B (+0.09%) |
| `./dist/assets/js/googlesitekit-modules-ads-********************.js` | 50.5 kB | +7 B (+0.01%) |
| `./dist/assets/js/googlesitekit-modules-adsense-********************.js` | 118 kB | +35 B (+0.03%) |
| `./dist/assets/js/googlesitekit-modules-analytics-4-********************.js` | 194 kB | -644 B (-0.33%) |
| `./dist/assets/js/googlesitekit-modules-pagespeed-insights-********************.js` | 25.7 kB | -6 B (-0.02%) |
| `./dist/assets/js/googlesitekit-modules-reader-revenue-manager-********************.js` | 47 kB | -20 B (-0.04%) |
| `./dist/assets/js/googlesitekit-modules-search-console-********************.js` | 69.1 kB | -730 B (-1.05%) |
| `./dist/assets/js/googlesitekit-modules-sign-in-with-google-********************.js` | 33 kB | -6 B (-0.02%) |
| `./dist/assets/js/googlesitekit-modules-tagmanager-********************.js` | 32.2 kB | -14 B (-0.04%) |
| `./dist/assets/js/googlesitekit-notifications-********************.js` | 47.7 kB | -184 B (-0.38%) |
| `./dist/assets/js/googlesitekit-polyfills-********************.js` | 377 B | -1 B (-0.26%) |
| `./dist/assets/js/googlesitekit-settings-********************.js` | 129 kB | -13 B (-0.01%) |
| `./dist/assets/js/googlesitekit-splash-********************.js` | 69.2 kB | -17 B (-0.02%) |
| `./dist/assets/js/googlesitekit-user-input-********************.js` | 44 kB | -11 B (-0.02%) |
| `./dist/assets/js/googlesitekit-vendor-********************.js` | 324 kB | +205 B (+0.06%) |
| `./dist/assets/js/googlesitekit-widgets-********************.js` | 102 kB | +39 B (+0.04%) |
| `./dist/assets/js/googlesitekit-wp-dashboard-********************.js` | 63.2 kB | -17 B (-0.03%) |
| `./dist/assets/js/runtime-********************.js` | 1.4 kB | -3 B (-0.21%) |

</details>



<a href="https://github.com/preactjs/compressed-size-action"><sub>compressed-size-action</sub></a>
author_association: NONE
user: login: github-actions[bot]
created_at: 2025-04-07T10:47:01Z
body: Build files for 8b28beb78e7492087f6e43fb41025acf7fe5b4ae have been deleted.
author_association: NONE
user: login: benbowler
created_at: 2025-04-09T11:08:13Z
body: @aaemnnosttv I reverted this tour, while testing I found that the class has been removed from the ChangeMetricsLink which means this tour has been broken for a little while. I fixed this as part of the update and added an inline comment to make sure it's not removed in future.
author_association: COLLABORATOR