Skip to content

Commit

Permalink
Navigation Link Block: Remove redundant aria-labels
Browse files Browse the repository at this point in the history
  • Loading branch information
himanshupathak95 committed Jan 17, 2025
1 parent 1bc424d commit b4a0aa6
Showing 1 changed file with 3 additions and 14 deletions.
17 changes: 3 additions & 14 deletions packages/block-library/src/navigation-link/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
ToolbarGroup,
} from '@wordpress/components';
import { displayShortcut, isKeyboardEvent } from '@wordpress/keycodes';
import { __, sprintf } from '@wordpress/i18n';
import { __ } from '@wordpress/i18n';
import {
BlockControls,
InspectorControls,
Expand Down Expand Up @@ -527,10 +527,7 @@ export default function NavigationLinkEdit( {
<a className={ classes }>
{ /* eslint-enable */ }
{ ! url ? (
<span
className="wp-block-navigation-link__placeholder-text"
aria-label={ __( 'This item is missing a link' ) }
>
<span className="wp-block-navigation-link__placeholder-text">
{ missingText }
</span>
) : (
Expand Down Expand Up @@ -584,15 +581,7 @@ export default function NavigationLinkEdit( {
}
) }
>
<span
aria-label={ sprintf(
/* translators: %s: link status (Invalid or Draft) */
__( 'Navigation link text - %s' ),
isInvalid
? __( 'Invalid' )
: __( 'Draft' )
) }
>
<span>
{
// Some attributes are stored in an escaped form. It's a legacy issue.
// Ideally they would be stored in a raw, unescaped form.
Expand Down

0 comments on commit b4a0aa6

Please sign in to comment.