WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 160009
AX: aria-label not being used correctly in accessible name calculation of heading
https://bugs.webkit.org/show_bug.cgi?id=160009
Summary
AX: aria-label not being used correctly in accessible name calculation of hea...
Dylan Barrell
Reported
2016-07-20 21:12:15 PDT
The accessible name calculation algorithm for ARIA
https://www.w3.org/TR/wai-aria/roles#textalternativecomputation
states that aria-label (step 2A) takes precedence over the content of an element (step 2C) for the calculation of the name of the element when that element's role allows both content or author as the source of the accessible name. This codepen
http://codepen.io/anon/pen/dXdEXx
shows that VO on both OS X and iOS does not implement that algorithm correctly. In the case of OS X, the rotor displays the correctly calculated text, but the spoken text does not match this. In the case of iOS, the incorrect text (content) is spoken instead of the aria-label text.
Attachments
Patch
(5.44 KB, patch)
2016-07-21 15:57 PDT
,
Nan Wang
no flags
Details
Formatted Diff
Diff
Patch
(5.49 KB, patch)
2016-07-21 16:09 PDT
,
Nan Wang
cfleizach
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2016-07-20 21:13:20 PDT
<
rdar://problem/27464404
>
Nan Wang
Comment 2
2016-07-21 15:57:24 PDT
Created
attachment 284275
[details]
Patch Webkit is exposing the correct information. We can see that the heading has the correct label in web inspector. So I think on macOS we should let VoiceOver handle what to speak. The patch is for iOS only.
chris fleizach
Comment 3
2016-07-21 16:02:22 PDT
Comment on
attachment 284275
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=284275&action=review
> Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:604 > + if (![wrapper accessibilityLabel].length)
the dot pattern looks strange for this method. can you 1) cache axLabel in an ivar then just use [axLabel length]
Nan Wang
Comment 4
2016-07-21 16:09:36 PDT
Created
attachment 284278
[details]
Patch Update from review
chris fleizach
Comment 5
2016-07-21 16:20:15 PDT
Comment on
attachment 284278
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=284278&action=review
> Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:604 > + NSString* headingLabel = [wrapper accessibilityLabel];
nit: for objc * is on the other side NSString *headingLabel
Nan Wang
Comment 6
2016-07-21 16:49:52 PDT
Committed in:
https://trac.webkit.org/changeset/203538
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug