WordPress.org

Make WordPress Core

#42037 closed defect (bug) (fixed)

Nearby events dashboard widget "city updated" speak message announced on page load

Reported by: afercia Owned by: afercia
Milestone: 4.9 Priority: normal
Severity: normal Version: 4.8
Component: Administration Keywords: has-screenshots has-patch commit
Focuses: accessibility, javascript Cc:

Description

Just noticed (a bit late...) that when loading the dashboard page, the Nearby events widgets renders its template and also sends to the ARIA live region the assertive message "city updated"

https://cldup.com/oLy8szqOiW.png

this is not ideal on page load, since users haven't taken any action and there's no need to confirm an action that hasn't happened. It's also confusing and a bit annoying hearing that message every time the dashboard screen is loaded.

Attachments (1)

42037.diff (884 bytes) - added by afercia 22 months ago.

Download all attachments as: .zip

Change History (6)

@afercia
22 months ago

#1 @afercia
22 months ago

  • Keywords has-patch added

42037.diff checks for initiatedBy to send the "city updated" message. This way, the message should be announced only when the city gets updated by users. Not sure if it's the best option or there are better ways. Also, I guess the similar unknownCity doesn't need the same check. /cc @iandunn (hey)

#2 @afercia
22 months ago

  • Summary changed from Nearby events dashboard widget "city updated" speak message announced on page lod to Nearby events dashboard widget "city updated" speak message announced on page load

#3 @iandunn
22 months ago

  • Focuses accessibility added
  • Keywords commit added
  • Owner set to afercia
  • Status changed from new to assigned

Good catch!

I was able to reproduce this before applying 42037.diff, and applying it fixes the issue for me. The message is still announce when manually changing the city, too.

The diff itself also looks good, so I'd say go ahead and commit it :)

#4 @afercia
22 months ago

@iandunn Thanks!

#5 @afercia
22 months ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 41682:

Accessibility: Improve the Dashboard Nearby Events widget wp.a11y.speak() messages.

Avoids to announce the "city updated" message on page load.

Fixes #42037.

Note: See TracTickets for help on using tickets.