Bug 170317 - AX: <hr> should use a different role description than interactive separators
Summary: AX: <hr> should use a different role description than interactive separators
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Accessibility (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: chris fleizach
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2017-03-30 17:28 PDT by James Craig
Modified: 2017-04-19 14:58 PDT (History)
10 users (show)

See Also:


Attachments
patch (5.17 KB, patch)
2017-04-13 23:47 PDT, chris fleizach
buildbot: commit-queue-
Details | Formatted Diff | Diff
Archive of layout-test-results from ews113 for mac-elcapitan (1.80 MB, application/zip)
2017-04-14 00:58 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews102 for mac-elcapitan (934.09 KB, application/zip)
2017-04-14 01:00 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews105 for mac-elcapitan-wk2 (890.29 KB, application/zip)
2017-04-14 01:03 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews124 for ios-simulator-wk2 (53.14 MB, application/zip)
2017-04-14 14:01 PDT, Build Bot
no flags Details
patch (5.97 KB, patch)
2017-04-19 09:40 PDT, chris fleizach
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description James Craig 2017-03-30 17:28:39 PDT
A VoiceOver user questioned why <hr> was spoken as "horizontal separator" when all other SRs call it the slightly less verbose "horizontal rule". Note: it's an implementation detail in that they both use the same WebCore role.

We could use a different WebCore role and use that to expose a different role description: "separator" -> "rule"
Comment 1 Radar WebKit Bug Importer 2017-03-30 19:48:20 PDT
<rdar://problem/31363024>
Comment 2 chris fleizach 2017-04-13 23:47:16 PDT
Created attachment 307097 [details]
patch
Comment 3 Build Bot 2017-04-14 00:58:29 PDT
Comment on attachment 307097 [details]
patch

Attachment 307097 [details] did not pass mac-debug-ews (mac):
Output: http://webkit-queues.webkit.org/results/3532891

New failing tests:
accessibility/roles-exposed.html
Comment 4 Build Bot 2017-04-14 00:58:31 PDT
Created attachment 307103 [details]
Archive of layout-test-results from ews113 for mac-elcapitan

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews113  Port: mac-elcapitan  Platform: Mac OS X 10.11.6
Comment 5 Build Bot 2017-04-14 01:00:45 PDT
Comment on attachment 307097 [details]
patch

Attachment 307097 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.webkit.org/results/3532945

New failing tests:
accessibility/roles-exposed.html
Comment 6 Build Bot 2017-04-14 01:00:47 PDT
Created attachment 307104 [details]
Archive of layout-test-results from ews102 for mac-elcapitan

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews102  Port: mac-elcapitan  Platform: Mac OS X 10.11.6
Comment 7 Build Bot 2017-04-14 01:03:56 PDT
Comment on attachment 307097 [details]
patch

Attachment 307097 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.webkit.org/results/3532949

New failing tests:
accessibility/roles-exposed.html
Comment 8 Build Bot 2017-04-14 01:03:57 PDT
Created attachment 307105 [details]
Archive of layout-test-results from ews105 for mac-elcapitan-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews105  Port: mac-elcapitan-wk2  Platform: Mac OS X 10.11.6
Comment 9 Joanmarie Diggs 2017-04-14 01:13:28 PDT
Comment on attachment 307097 [details]
patch

View in context: https://bugs.webkit.org/attachment.cgi?id=307097&action=review

> Source/WebCore/accessibility/AccessibilityRenderObject.cpp:2826
> +    // Horizontal rule roles can only be horizontal... even if you say it's vertical.

I have mixed feelings about this. On the one hand, of course. I cannot imagine what would motivate an author to use an HR element but style it so that it is vertical.

On the other hand, I've seen stranger things done by authors. And I've not found anything that says authors MUST NOT use an HR element styled vertically as a means to create a vertical rule. But perhaps more importantly, the HTML AAM indicates that the implicit role for HR [1] is the ARIA separator role, which of course allows for vertical orientation. And the ARIA in HTML spec says that HR supports "global aria-* attributes and any aria-* attributes applicable to the separator role." [2] So if something unforeseen motivated an author to create a vertical rule out of a styled HR element, and that author also took the time to use aria-orientation to cause it to be exposed to accessibility APIs as vertical, I think he/she has a reasonable expectation that user agents will respect that exposure (whether we happen to think it's a good idea or not).

[1] https://w3c.github.io/html-aam/#el-hr
[2] https://www.w3.org/TR/html-aria/#hr
Comment 10 chris fleizach 2017-04-14 11:39:38 PDT
(In reply to Joanmarie Diggs (irc: joanie) from comment #9)
> Comment on attachment 307097 [details]
> patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=307097&action=review
> 
> > Source/WebCore/accessibility/AccessibilityRenderObject.cpp:2826
> > +    // Horizontal rule roles can only be horizontal... even if you say it's vertical.
> 
> I have mixed feelings about this. On the one hand, of course. I cannot
> imagine what would motivate an author to use an HR element but style it so
> that it is vertical.
> 
> On the other hand, I've seen stranger things done by authors. And I've not
> found anything that says authors MUST NOT use an HR element styled
> vertically as a means to create a vertical rule. But perhaps more
> importantly, the HTML AAM indicates that the implicit role for HR [1] is the
> ARIA separator role, which of course allows for vertical orientation. And
> the ARIA in HTML spec says that HR supports "global aria-* attributes and
> any aria-* attributes applicable to the separator role." [2] So if something
> unforeseen motivated an author to create a vertical rule out of a styled HR
> element, and that author also took the time to use aria-orientation to cause
> it to be exposed to accessibility APIs as vertical, I think he/she has a
> reasonable expectation that user agents will respect that exposure (whether
> we happen to think it's a good idea or not).

I'm ok leaving the code as is, which allows for orientation=vertical for an hr

> 
> [1] https://w3c.github.io/html-aam/#el-hr
> [2] https://www.w3.org/TR/html-aria/#hr
Comment 11 Build Bot 2017-04-14 14:01:15 PDT
Comment on attachment 307097 [details]
patch

Attachment 307097 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: http://webkit-queues.webkit.org/results/3535079

New failing tests:
webrtc/release-after-getting-track.html
webrtc/video-remote-mute.html
webrtc/multi-video.html
webrtc/peer-connection-audio-mute.html
webrtc/video-mediastreamtrack-stats.html
webrtc/video-disabled-black.html
webrtc/no-port-zero-in-upd-candidates.html
webrtc/rtcpeerconnection-error-messages.html
webrtc/peer-connection-remote-audio-mute.html
webrtc/video-with-data-channel.html
Comment 12 Build Bot 2017-04-14 14:01:18 PDT
Created attachment 307144 [details]
Archive of layout-test-results from ews124 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews124  Port: ios-simulator-wk2  Platform: Mac OS X 10.11.6
Comment 13 chris fleizach 2017-04-19 09:40:42 PDT
Created attachment 307484 [details]
patch
Comment 14 WebKit Commit Bot 2017-04-19 14:58:08 PDT
Comment on attachment 307484 [details]
patch

Clearing flags on attachment: 307484

Committed r215532: <http://trac.webkit.org/changeset/215532>
Comment 15 WebKit Commit Bot 2017-04-19 14:58:10 PDT
All reviewed patches have been landed.  Closing bug.