-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Site Title: Fix logic for 'aria-current' attribute #68909
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
Conversation
…e on the posts page
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 Unlinked AccountsThe following contributors have not linked their GitHub and WordPress.org accounts: @bjschneidewind@santanderconsumerusa.com. Contributors, please read how to link your accounts to ensure your work is properly credited in WordPress releases. 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 your first Pull Request and for helping build the future of Gutenberg and WordPress, @bschneidewind! 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. |
Hi @bschneidewind, Can you please add the Thank You, |
The Home Link block has a different conditional statement: gutenberg/packages/block-library/src/home-link/index.php Lines 142 to 149 in 6800a97
And neither block matches the condition in |
Thank you @sabernhardt - helped ID another edge case and reworked this code a bit! |
aria-current
attribute
aria-current
attribute
Test resultsYour homepage displays Your latest postsHome: Your homepage displays A static pageHomepage is selected in the option. Posts page is selected in the option. Homepage is selected in the option. Posts page is not selected. Homepage is not selected in the option. Posts page is selected. |
I am moving this to the 6.8 board because the original trac ticket is on the 6.8 milestone, labeled as an accessibility bug. |
Unlinked contributors: bjschneidewind@santanderconsumerusa.com. Co-authored-by: carolinan <poena@git.wordpress.org> Co-authored-by: joedolson <joedolson@git.wordpress.org> Co-authored-by: hbhalodia <hbhalodia@git.wordpress.org> Co-authored-by: sabernhardt <sabernhardt@git.wordpress.org> Co-authored-by: bschneidewind <bschneidewind@git.wordpress.org>
I just cherry-picked this PR to the wp/6.8 branch to get it included in the next release: 9f8d16d. |
Unlinked contributors: bjschneidewind@santanderconsumerusa.com. Co-authored-by: carolinan <poena@git.wordpress.org> Co-authored-by: joedolson <joedolson@git.wordpress.org> Co-authored-by: hbhalodia <hbhalodia@git.wordpress.org> Co-authored-by: sabernhardt <sabernhardt@git.wordpress.org> Co-authored-by: bschneidewind <bschneidewind@git.wordpress.org>
What?
This updates the core/site-title block and the aria-current attribute. This should only be applied to the front page and prevents the aria-current being applied if a user has a separate front page from the posts page. (the posts page should not have an aria-current attribute applied to site title in these instances)
Why?
Resolves bug where a separate posts page has the site-title attribute applied to the site-title (should only be applied to the front page)
How?
Testing Instructions
Trac ticket: https://core.trac.wordpress.org/ticket/62874