-
Notifications
You must be signed in to change notification settings - Fork 295
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove Individual Module pages #4134
Comments
@tofumatt This needs to consider a few more implications that removing the module screens has (at least it has one): The module setups for modules that have a module screen currently rely on that screen to render the module setup. I think replacing that is trivial since we have the same infrastructure on the dashboard, but it needs to be included. The module screens after referenced in JS and are used e.g. to redirect to the module setup, which would break if we just removed the server-side setup for it. We can probably just use |
@tofumatt I completed the ACs here with a notion about the setup flows for those 3 modules. |
@tofumatt @felixarntz, while working on the IB I have noticed, there seems to be an assumption in the AC that the setup for Tag Manager, PageSpeed Insights etc will work when the As it stands that is not the case - the modules which currently are setup on the site-kit-wp/assets/js/googlesitekit-dashboard.js Lines 41 to 50 in 8616abb
As you can see, when the FF is enabled the My question is, what should we do in this instance - do you think it would be best to enable the setup for Tag Manager, PageSpeed Insights etc on the unified dashboard as a separate item before tackling this issue? -- Addendum: Here's a bit more info I have found on the possible implementation for enabling the setup: Assuming we want to reuse We could of course add I'm not sure if there are any other aspects that need to be considered. |
Aside from that, your proposed solution of restoring the setup flow to Making that part of the IB here makes sense to me, if that's all it takes to restore the setup functionality. 👍🏻 |
Thanks @tofumatt - sounds good to me, I will include the proposed change to assets/js/googlesitekit-dashboard.js in the IB. |
@techanvil Good catch, indeed moving the condition for displaying The IB mostly looks solid. I'm only unsure about the name of the (@eugene-manuilov I see you had marked this but since I was already pinged here I just reviewed the IB) |
@felixarntz thanks for the review, and I agree with your point about renaming |
IB ✅ |
QA Update: ✅Verified: With unifiedDashboard enabled
With unifiedDashboard disabled
|
Feature Description
As per the Design Doc, we should remove all Module pages and the WP sidebar links to each module page.
This before/after from the design doc shows what we should go from and to:
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
unifiedDashboard
feature flag is enabled: the Module Pages and sidebar links for Analytics, AdSense, and Search Console should be removed. Tag Manager, PageSpeed Insights, Optimize, and Idea Hub don't have dedicated modular pages/links so they aren't included here.unifiedDashboard
feature flag is enabled, this should be changed accordingly so that they use the regulargooglesitekit-dashboard
screen as "embedding screen" (similar to how the other modules do it).Implementation Brief
JavaScript:
GoogleSitekitDashboard
component fromassets/js/googlesitekit-dashboard.js
into a new file,assets/js/components/DashboardEntryPoint.js
, also renaming the component toDashboardEntryPoint
. This will facilitate testing the component.DashboardEntryPoint
component, move the conditional render ofModuleSetup
above the conditional render ofDashboardMainApp
, i.e. move lines 48-50 above 44-46 as seen here. This is to enable the module setup flow on the dashboard screen whenunifiedDashboard
is enabled:site-kit-wp/assets/js/googlesitekit-dashboard.js
Lines 44 to 50 in 8616abb
assets/js/modules/adsense/datastore/base.js
, ensure theadminPage
setting is not defined when theunifiedDashboard
feature flag is enabled. Useimport { isFeatureEnabled } from '../../../features'
and callisFeatureEnabled( 'unifiedDashboard' )
to query the feature.site-kit-wp/assets/js/modules/adsense/datastore/base.js
Line 40 in 1a487ae
adminPage
setting is not defined when theunifiedDashboard
feature flag is enabled in bothassets/js/modules/analytics/datastore/base.js
andassets/js/modules/search-console/datastore/index.js
.PHP:
includes/Modules/AdSense.php
, ensure theregister_screen_hook
method is not invoked when theunifiedDashboard
feature flag is enabled. Useuse Google\Site_Kit\Core\Util\Feature_Flags;
and callFeature_Flags::enabled( 'unifiedDashboard' )
to query the feature.site-kit-wp/includes/Modules/AdSense.php
Line 76 in 1a487ae
register_screen_hook
is not invoked when theunifiedDashboard
feature flag is enabled in bothincludes/Modules/Analytics.php
andincludes/Modules/Search_Console.php
.Test Coverage
JavaScript:
DashboardEntryPoint
component to verify the module setup flow is active when theunifiedDashboard
feature is both enabled and disabled. This will require adding a new test file.assets/js/modules/adsense/datastore/base.js
,assets/js/modules/analytics/datastore/base.js
andassets/js/modules/search-console/datastore/index.js
to check theadminPage
setting is defined correctly depending on theunifiedDashboard
feature status. These will each require adding a new corresponding test file.PHP:
includes/Modules/AdSense.php
,includes/Modules/Analytics.php
andincludes/Modules/Search_Console.php
to check the screen is not registered when theunifiedDashboard
feature is enabled. These files have corresponding PHPUnit test files which can be updated.QA Brief
page=googlesitekit-dashboard
being present in the URL during setup:Changelog entry
unifiedDashboard
flag is enabled.The text was updated successfully, but these errors were encountered: