Bug 161081 - Accessibility of MathML links
Summary: Accessibility of MathML links
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Accessibility (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on: mathml-href 159213
Blocks:
  Show dependency treegraph
 
Reported: 2016-08-23 07:57 PDT by Frédéric Wang (:fredw)
Modified: 2016-08-24 10:18 PDT (History)
12 users (show)

See Also:


Attachments
WIP Patch (4.84 KB, patch)
2016-08-23 07:58 PDT, Frédéric Wang (:fredw)
buildbot: commit-queue-
Details | Formatted Diff | Diff
Archive of layout-test-results from ews103 for mac-yosemite (845.68 KB, application/zip)
2016-08-24 10:03 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews105 for mac-yosemite-wk2 (798.16 KB, application/zip)
2016-08-24 10:07 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews117 for mac-yosemite (1.54 MB, application/zip)
2016-08-24 10:18 PDT, Build Bot
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Frédéric Wang (:fredw) 2016-08-23 07:57:02 PDT
Support for MathML links was added in bug 85733. After the MathML article on the Safari blog we got feedback about accessibility of MathML links (see the demo https://webkit.org/demos/mathml/demo2016/#hyperlinks). I'm not sure exactly what is required, but it seems that we should somewhat expose the MathML links to the accessibility tree so that ATs can understand it.
Comment 1 Frédéric Wang (:fredw) 2016-08-23 07:58:43 PDT
Created attachment 286711 [details]
WIP Patch

This is an experimental patch adding role Link to MathML elements with a href attribute.
Comment 2 Radar WebKit Bug Importer 2016-08-23 22:26:36 PDT
<rdar://problem/27983220>
Comment 3 chris fleizach 2016-08-24 09:06:40 PDT
Comment on attachment 286711 [details]
WIP Patch

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

> Source/WebCore/accessibility/AccessibilityMathMLElement.cpp:62
> +    if (node && node->isLink())

I don't know if we want to change the math role away from what it is to a link. 
if you put the href on a <mfrac> then that might mess up the math tree that's created

it seems like either we should 
a) expand the concept of roles so that an object can have more than one role
b) make being a link an attribute as well as a role (probably the easiest path)
c) make a fake element representing the link that becomes the parent of the object
Comment 4 Frédéric Wang (:fredw) 2016-08-24 09:20:58 PDT
(In reply to comment #3)
> Comment on attachment 286711 [details]
> WIP Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=286711&action=review
> 
> > Source/WebCore/accessibility/AccessibilityMathMLElement.cpp:62
> > +    if (node && node->isLink())
> 
> I don't know if we want to change the math role away from what it is to a
> link. 
> if you put the href on a <mfrac> then that might mess up the math tree
> that's created

(In reply to comment #3)
> I don't know if we want to change the math role away from what it is to a
> link. 
> if you put the href on a <mfrac> then that might mess up the math tree
> that's created

We definitely do not want to have the role overridden (although that's maybe not too much a trouble if href is only used on mrow). That's why I did not ask review for this patch ;-)

> it seems like either we should 
> a) expand the concept of roles so that an object can have more than one role
> b) make being a link an attribute as well as a role (probably the easiest
> path)
> c) make a fake element representing the link that becomes the parent of the
> object

I believe we should get feedback from AT developers but my guess would be that on their side: c) won't need any effort , b) will need a minor effort and a) will be more complex.

Actually I'm curious about c), since that might help to remove anonymous nodes for mfenced if we decide to rewrite its renderer class (bug 160509).
Comment 5 chris fleizach 2016-08-24 09:25:23 PDT
(In reply to comment #4)
> (In reply to comment #3)
> > Comment on attachment 286711 [details]
> > WIP Patch
> > 
> > View in context:
> > https://bugs.webkit.org/attachment.cgi?id=286711&action=review
> > 
> > > Source/WebCore/accessibility/AccessibilityMathMLElement.cpp:62
> > > +    if (node && node->isLink())
> > 
> > I don't know if we want to change the math role away from what it is to a
> > link. 
> > if you put the href on a <mfrac> then that might mess up the math tree
> > that's created
> 
> (In reply to comment #3)
> > I don't know if we want to change the math role away from what it is to a
> > link. 
> > if you put the href on a <mfrac> then that might mess up the math tree
> > that's created
> 
> We definitely do not want to have the role overridden (although that's maybe
> not too much a trouble if href is only used on mrow). That's why I did not
> ask review for this patch ;-)
> 
> > it seems like either we should 
> > a) expand the concept of roles so that an object can have more than one role
> > b) make being a link an attribute as well as a role (probably the easiest
> > path)
> > c) make a fake element representing the link that becomes the parent of the
> > object
> 
> I believe we should get feedback from AT developers but my guess would be
> that on their side: c) won't need any effort , b) will need a minor effort
> and a) will be more complex.
> 
> Actually I'm curious about c), since that might help to remove anonymous
> nodes for mfenced if we decide to rewrite its renderer class (bug 160509).


i’m concerned C) might have adverse affects too. if you put this on a node within a math term, it might also change the expected hierarchy and break something. i think b) might be the easiest although we’ll need to change ATs for mac. iOS should be able to easily adopt this since a link is already an attribute
Comment 6 Build Bot 2016-08-24 10:03:50 PDT
Comment on attachment 286711 [details]
WIP Patch

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

New failing tests:
accessibility/math-links.html
Comment 7 Build Bot 2016-08-24 10:03:54 PDT
Created attachment 286858 [details]
Archive of layout-test-results from ews103 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews103  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 8 Build Bot 2016-08-24 10:07:33 PDT
Comment on attachment 286711 [details]
WIP Patch

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

New failing tests:
accessibility/math-links.html
Comment 9 Build Bot 2016-08-24 10:07:37 PDT
Created attachment 286859 [details]
Archive of layout-test-results from ews105 for mac-yosemite-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews105  Port: mac-yosemite-wk2  Platform: Mac OS X 10.10.5
Comment 10 Build Bot 2016-08-24 10:18:10 PDT
Comment on attachment 286711 [details]
WIP Patch

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

New failing tests:
accessibility/math-links.html
Comment 11 Build Bot 2016-08-24 10:18:15 PDT
Created attachment 286860 [details]
Archive of layout-test-results from ews117 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews117  Port: mac-yosemite  Platform: Mac OS X 10.10.5