Make WordPress Core

Opened 8 years ago

Closed 8 years ago

Last modified 5 years ago

#43522 closed enhancement (fixed)

Add aria-current to output of Walker_Page

Reported by: chetan200891 Owned by: SergeyBiryukov
Priority: normal Milestone: 5.1
Component: Themes Version: 4.8
Severity: normal Keywords: dev-feedback has-patch
Cc: Focuses: accessibility

Description

From the reference of ticket #43191, Also need to add area-current to output of Walker_Page.

I think below modifications can help.

if ( $page->ID == $current_page ) {
        $atts['aria-current'] = 'page';
}

Attachments (2)

43522.diff (503 bytes ) - added by wpzinc 8 years ago.
43522.1.diff (691 bytes ) - added by chetan200891 5 years ago.
Updated patch.

Download all attachments as: .zip

Change History (21)

This ticket was mentioned in Slack in #accessibility by chetan200891. View the logs.


8 years ago

This ticket was mentioned in Slack in #accessibility by afercia. View the logs.


8 years ago

#3 @afercia
8 years ago

  • Component GeneralThemes
  • Keywords needs-patch added
  • Milestone Awaiting Review5.0
  • Version trunk

@wpzinc
8 years ago

#4 @lonelyvegan
8 years ago

  • Keywords has-patch added; needs-patch removed

Looks like this has a patch, so updating the keywords.

This ticket was mentioned in Slack in #accessibility by afercia. View the logs.


8 years ago

#6 @afercia
8 years ago

  • Milestone 5.04.9.9

Discussed during today's accessibility bug scrub and we'd like to propose this ticket for 4.9.9 consideration.

#7 @pento
8 years ago

  • Milestone 4.9.95.0.1

#8 @pento
8 years ago

  • Milestone 5.0.15.0.2

#9 @pento
8 years ago

  • Milestone 5.0.25.0.3

#10 @audrasjb
8 years ago

  • Keywords 2nd-opinion dev-feedback added

Patch looks fine on my side.

This ticket is triaged in milestone 5.0.3. It will needs commit and backport to the related branch.

This ticket was mentioned in Slack in #core by desrosj. View the logs.


8 years ago

#12 @desrosj
8 years ago

  • Milestone 5.0.35.1

Going to punt this to 5.1. It is outside of the scope for 5.0.3 (block
editor bugs, regressions, and major bugs).

#13 @SergeyBiryukov
8 years ago

  • Owner set to SergeyBiryukov
  • Resolutionfixed
  • Status newclosed

In 44416:

Accessibility: Themes: use aria-current for the Walker_Page current link.

See [42808] for Walker_Nav_Menu.

The aria-current attribute is a simple, effective way to help assistive
technologies users orientate themselves within a list of items. Continues the
introduction in core of aria-current after [42440], [41683], [41359], and [41371].

Props chetan200891, wpzinc.
Fixes #43522.

#15 @jnylen0
5 years ago

  • Keywords needs-patch added; has-patch 2nd-opinion removed
  • Version4.8

[44416] has an issue: the array key is named aria-current in the code but referred to as aria_current in the docs.

This ticket was mentioned in Slack in #core by jnylen. View the logs.


5 years ago

This ticket was mentioned in Slack in #accessibility by jnylen. View the logs.


5 years ago

@chetan200891
5 years ago

Updated patch.

#18 @chetan200891
5 years ago

  • Keywords has-patch added; needs-patch removed

I have updated patch 43522.1.diff

#19 @SergeyBiryukov
5 years ago

In 50823:

Docs: Correct the aria-current array key in the documentation for two widget filters.

This applies to nav_menu_link_attributes and page_menu_link_attributes filters.

Follow-up to [42808], [44416].

Props jnylen0, chetan200891, alexstine.
See #43522, #52628.

Note: See TracTickets for help on using tickets.