-
Notifications
You must be signed in to change notification settings - Fork 330
Closed
Labels
P0High priorityHigh priorityTeam MIssues for Squad 2Issues for Squad 2Type: EnhancementImprovement of an existing featureImprovement of an existing feature
Description
Feature Description
Add the googlesitekit-key-metrics-setup screen and script asset with stub content, including webpack configuration.
For reference, see the Key Metrics setup section in the Design Doc.
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
- A new WordPress screen
googlesitekit-key-metrics-setupis created. - The screen is only accessible to administrators.
- The screen doesn't appear in the WordPress menu.
- The new screen renders basic stub content without full functionality.
Implementation Brief
- Create a new component,
KeyMetricsSetupApp, inassets/js/components/key-metrics-setup/KeyMetricsSetupApp.js.- Render some basic stub content in the component.
- Create the entry point for the JS asset,
assets/js/googlesitekit-key-metrics-setup.js.- Follow the pattern of the
googlesitekit-user-input.jsfile. - Use the render target
js-googlesitekit-key-metrics-setup. - Render the
KeyMetricsSetupAppcomponent, wrapped in theRootcomponent with a newVIEW_CONTEXT_KEY_METRICS_SETUPview context.
- Follow the pattern of the
- Add the new JS asset to the list of modules in
assets/webpack/modules.config.js. - In
Core::Admin::Screens::get_screens(), add a new screen with the sluggooglesitekit-key-metrics-setup.capabilityshould bePermissions::MANAGE_OPTIONS.parent_slugshould beself::PARENT_SLUG_NULL.
- In
Core::Assets::get_assets(), add a new asset with the handlegooglesitekit-key-metrics-setup.srcshould point togooglesitekit-key-metrics-setup.js.dependenciesshould be the same as theuser-inputasset, i.e. thedashboarddependencies.
Test Coverage
- No new tests needed.
QA Brief
- Set up Site Kit
- Visit
wp-admin/admin.php?page=googlesitekit-key-metrics-setup - Ensure that the screen loads and has the stub content.
- Ensure the screen is not linked to in the menu.
Changelog entry
- Add the
googlesitekit-key-metrics-setupscreen, with stub content.
Metadata
Metadata
Assignees
Labels
P0High priorityHigh priorityTeam MIssues for Squad 2Issues for Squad 2Type: EnhancementImprovement of an existing featureImprovement of an existing feature