Opened 21 months ago

Last modified 3 days ago

#18650 new enhancement

Make archives and categories widgets dropdown ada compliant

Reported by: jlevandowski Owned by:
Priority: normal Milestone: 3.6
Component: Accessibility Version: 3.2.1
Severity: major Keywords: has-patch dev-feedback
Cc: webstoc

Description

Conditionally add the <label> tag for the archives and categories widgets so they are ada compliant.

http://webaim.org/techniques/forms/controls

Attachments (4)

widgets-patch.diff (1.8 KB) - added by jlevandowski 21 months ago.
18650-patch.diff (2.5 KB) - added by jlevandowski 21 months ago.
18650.2.patch (3.0 KB) - added by SergeyBiryukov 3 months ago.
18650.patch (4.1 KB) - added by DrewAPicture 3 days ago.
esc_attr_e

Download all attachments as: .zip

Change History (13)

I'd prefer to see the <select> element get an id attribute that had the widget ID as a suffix - that way, more than one archive dropdown widget can be used on a page with valid unique ids.

Added patch that adds widget id so that more than one widget of the same kind can be used on a page.

  • Component changed from Widgets to Accessibility
  • Keywords dev-feedback added
  • Severity changed from normal to major

We verified that the patch fixes red flags in the WAVE toolbar. Curious what the hold up is on reviewing the patch by jlevandowski and getting it into the widgets? There are dozens (if not hundreds) of .gov sites using WordPress that need these fixes. As an "accessibility" issue, this more than of a "major" than "normal" severity.

Last edited 3 months ago by webstoc (previous) (diff)
  • Cc webstoc added

comment:7 follow-up: ↓ 9   SergeyBiryukov3 months ago

  • Milestone changed from Awaiting Review to 3.6

Refreshed the patch.

Not sure if changing the existing id attribute for Categories widget is a good idea though. I guess it may lead to unexpected results in some themes.

#16527 was marked as a duplicate.

esc_attr_e

comment:9 in reply to: ↑ 7   DrewAPicture3 days ago

Replying to SergeyBiryukov:

Not sure if changing the existing id attribute for Categories widget is a good idea though. I guess it may lead to unexpected results in some themes.

I see where you're coming from on this. And I can see why the inner select id was left alone -- the main widget id is unique for each instance just as with the other core widgets. On that same token, themes shouldn't have been targeting ids since they are by nature meant to be unique anyway.

18650.patch builds off 18650.2.patch and swaps out echo esc_attr( __( 'String' ) ) for esc_attr_e( 'String' )

Note: See TracTickets for help on using tickets.