-
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
Browse mode: Add an H2 inside the sidebar navigation screen title #47241
Conversation
Size Change: +842 B (0%) Total Size: 1.33 MB
ℹ️ View Unchanged
|
Flaky tests detected in 287e584. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/3967908081
|
packages/edit-site/src/components/sidebar-navigation-screen/index.js
Outdated
Show resolved
Hide resolved
packages/edit-site/src/components/sidebar-navigation-screen/index.js
Outdated
Show resolved
Hide resolved
packages/edit-site/src/components/sidebar-navigation-screen/index.js
Outdated
Show resolved
Hide resolved
packages/edit-site/src/components/sidebar-navigation-screen/style.scss
Outdated
Show resolved
Hide resolved
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.
Really cool improvement to the component and a11 fix
) } | ||
</HStack> | ||
title={ config[ postType ].labels.title } | ||
action={ |
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.
For consistency, I'd probably rename this prop to actions
as we've been using a similar prop in other components.
What?
Places the words design, templates and template parts inside
h2
elements in the navigation sidebar in the Site Editor.Closes #47217
Why?
Text that visually looks like headings should use HTML heading elements.
By using heading elements for the visual heading texts instead of divs, users can use the headings to navigate to the content; the list of buttons that represents the templates and template parts.
How?
Updates the sidebar navigation screen title div:
Adds a new condition for displaying either the heading text or the inner elements that include the
the back button, the template/template parts heading and the add new button.
Testing Instructions
H2
.H2
.Testing Instructions for Screen reader
Note that this document does not have an H1. This will be implemented in a separate PR.
Screenshots or screencast