-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
fix: Adds ariaLabel attribute to navigation block #68735
base: trunk
Are you sure you want to change the base?
fix: Adds ariaLabel attribute to navigation block #68735
Conversation
👋 Thanks for your first Pull Request and for helping build the future of Gutenberg and WordPress, @singhakanshu00! In case you missed it, we'd love to have you join us in our Slack community. If you want to learn more about WordPress development in general, check out the Core Handbook full of helpful information. |
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 If 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. |
Thanks for contributing, @singhakanshu00! Please use reserved keywords when to link PRs to the issues. See: https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/using-keywords-in-issues-and-pull-requests |
Why is the aria label needed as a block attribute when the aria label block support is already enabled? |
Hi @carolinan
Hence I added an ariaLabel attribute. Let me know if I missed something. Thanks |
@carolinan is correct. @singhakanshu00, based on the details you've shared, the root cause of the issue seems to be with |
Adding the If this is currently broken we need to resolve it at the root and not "fix" the cause here :) |
I think this is a bit of a tricky problem. The underlying problem is that block support for dynamic blocks is not complete. There are two main reasons for this: Block support schema issues
This is exactly why we need to add block attributes explicitly, i.e. store them as comments. We have tried in the past to add anchor support to dynamic blocks as well as static blocks, but encountered similar issues that are still not resolved. See #51402 for details. Server-side processingFor block support to work in dynamic blocks, registration is required on the PHP side, not just the JS side. However, there is no PHP-side processing for To fundamentally solve this problem, I think we need to extend the |
What?
fixes #68719
Why?
How?
ariaLabel
as an attribute, but we haven't added this attribute to block.json of the Navigation block.Testing Instructions
Screenshots or screencast
hey.mp4