Skip to content
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

[a11y] Fix: Use spans instead of headings on dataviews table view page title #56956

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions packages/edit-site/src/components/page-pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* WordPress dependencies
*/
import {
__experimentalHeading as Heading,
__experimentalView as View,
__experimentalVStack as VStack,
} from '@wordpress/components';
import { __ } from '@wordpress/i18n';
Expand Down Expand Up @@ -216,7 +216,10 @@ export default function PagePages() {
render: ( { item } ) => {
return (
<VStack spacing={ 1 }>
<Heading as="h3" level={ 5 } weight={ 500 }>
<View
as="span"
className="edit-site-page-pages__list-view-title-field"
>
{ [ LAYOUT_TABLE, LAYOUT_GRID ].includes(
view.type
) ? (
Expand All @@ -236,7 +239,7 @@ export default function PagePages() {
item.title?.rendered || item.slug
) || __( '(no title)' )
) }
</Heading>
</View>
</VStack>
);
},
Expand Down
6 changes: 6 additions & 0 deletions packages/edit-site/src/components/page-pages/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,9 @@
width: $grid-unit-40;
height: $grid-unit-40;
}


.edit-site-page-pages__list-view-title-field {
font-size: $default-font-size;
font-weight: 500;
}
Loading