wordpress-seo
wordpress-seo copied to clipboard
Distinguish between users that are able to see the lists in the Indexables page and users that are not
Context
- This PR implements the full workflow associated to the indexables page (see this flowchart for a graphical representation of it)
Summary
This PR can be summarized in the following changelog entry:
- Distinguish between users that are able to see the lists in the Indexables page and users that are not.
Relevant technical choices:
Test instructions
Test instructions for the acceptance test before the PR gets merged
This PR can be acceptance tested by following these steps:
- Start with a fresh installation of Yoast SEO - if you have Yoast SEO Premium activated, deactivate it
- Add the following filter to your site:
add_filter( 'wpseo_posts_threshold', 'custom_posts_threshold', 1 );
function custom_posts_threshold() {
return 2000;
}
(This sets the minimum number of required public posts to 2000, in order to enter the not enough public posts state
)
- Navigate to the Indexables tab, you should see the following page:


- Check that:
- The
Start writing a new post
button opens the edit post page - When you activate some checkboxes and you browse away from the page, when you come back the checkboxes state is preserved
- The
- Remove the
custom_posts_threshold
filter you have added before and add the following one:
add_filter( 'wpseo_analyzed_posts_threshold', 'custom_analyzed_posts_threshold', 1 );
function custom_analyzed_posts_threshold() {
return 1.0;
}
(This sets the minimum number of required analyzed posts to be the 100% of the public posts, in order to enter the not enough analyzed public posts
state)
-
Refresh the indexables page, you should see the following page:
-
Check that:
- Clicking on
Add focus keyphrase
opens a tab to edit the corresponding post - Clicking on
Show 5 more
shows 5 more posts (if any)
- Clicking on
-
Update the
custom_analyzed_posts_threshold
return value to be meaningful for your site: for example, if you have 100 public posts and only 10 of them have seo/readability score associated, set the value to be less than 0.1 (e.g. 0.09) -
Refresh the indexables page and you should see the following page:

-
Go to the
Features
tab and try to switch off a combination of the following three features:- SEO analysis
- Readability analysis
- Text link counter The combination should be reflected by the visualized cards in the indexables page, i.e.:
- SEO analysis switched off ->
Lowest SEO scores
card not visible - Readability analysis switched off ->
Lowest Readability scores
card not visible - Text link counter switched off ->
Lowest number of incoming links
andHighest number of incoming links
cards not visible
-
In the indexables page, check that:
- Clicking on an element title open that element in the frontend
-
Improve
andEdit
buttons open the edit page of the corresponding element -
Add links
shows an upsell modal - Clicking on the crossed-out eye icon (ignore):
- Removes from a list the corresponding element
- Shows an undo notice that, if clicked, puts the element back in the list in its original position
- If you ignore all the elements in a list, the list is not shown anymore
Relevant test scenarios
- [ ] Changes should be tested with the browser console open
- [ ] Changes should be tested on different posts/pages/taxonomies/custom post types/custom taxonomies
- [ ] Changes should be tested on different editors (Block/Classic/Elementor/other)
- [X] Changes should be tested on different browsers
- [ ] Changes should be tested on multisite
Test instructions for QA when the code is in the RC
- [ ] QA should use the same steps as above.
QA can test this PR by following these steps:
Impact check
This PR affects the following parts of the plugin, which may require extra testing:
- Since we have refactored the indexation component, please test that the "Start SEO data optimization" button in
Tools
andFirst-time configuration
works correctly
UI changes
- [ ] This PR changes the UI in the plugin. I have added the 'UI change' label to this PR.
Other environments
- [ ] This PR also affects Shopify. I have added a changelog entry starting with
[shopify-seo]
, added test instructions for Shopify and attached theShopify
label to this PR.
Documentation
- [ ] I have written documentation for this change.
Quality assurance
- [ ] I have tested this code to the best of my abilities
- [ ] I have added unit tests to verify the code works as intended
- [ ] If any part of the code is behind a feature flag, my test instructions also cover cases where the feature flag is switched off.
- [ ] I have written this PR in accordance with my team's definition of done.
Fixes #
✅ Changed some things and smoke tested but seems to work!