-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Interactivity Router: Move ARIA live region and loading bar to the Interactivity Router #58377
Interactivity Router: Move ARIA live region and loading bar to the Interactivity Router #58377
Conversation
This pull request has changed or added PHP files. Please confirm whether these changes need to be synced to WordPress Core, and therefore featured in the next release of WordPress. If so, it is recommended to create a new Trac ticket and submit a pull request to the WordPress Core Github repository soon after this pull request is merged. If you're unsure, you can always ask for help in the #core-editor channel in WordPress Slack. Thank you! ❤️ View changed files❔ phpunit/interactivity-api/class-wp-interactivity-api-wp-router-region-test.php ❔ lib/compat/wordpress-6.5/interactivity-api/class-wp-interactivity-api.php ❔ phpunit/blocks/render-query-test.php |
Size Change: -146 B (0%) Total Size: 1.7 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, @DAreRodz. The e2e test fix looks good to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't tested it yet, but initially it looks great to me!
We need to add options to opt-out of both things:
const { actions } = yield import('@wordpress/interactivity-router');
actions.navigate("/...", {
loadingAnimation: false,
screenReaderAnnouncement: false,
});
I also have some additional suggestions/questions.
lib/compat/wordpress-6.5/interactivity-api/class-wp-interactivity-api.php
Show resolved
Hide resolved
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Core SVNIf you're a Core Committer, use this list when committing to
GitHub Merge commitsIf you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.
To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I only have one comment about the screen reader announcement name but everything else LGTM. Thanks David! 🙂
What?
Epic: #56803
Move the logic that renders and controls the loading top bar and the ARIA live region―both elements that inform about client-side navigations―from the Query block to the Interactivity Router module and the
wp-router-region
directive processor.Also, the
@wordpress/interactivity-router
module exposesstate.url
, containing the current URL.Why?
We want that logic to be general for any block using client-side navigations, not just for the Query block.
How?
@wordpress/interactivity-router
module.data_wp_router_region_processor
, inside theWP_Interactivity_API
class.Testing Instructions
Testing Instructions for Keyboard