RESOLVED FIXED Bug 165842
AX: Consider implementing @aria-details.
https://bugs.webkit.org/show_bug.cgi?id=165842
Summary AX: Consider implementing @aria-details.
James Craig
Reported 2016-12-13 23:36:37 PST
Consider implementing @aria-details. https://www.w3.org/TR/wai-aria-1.1/#aria-details I'm not fully convinced of the utility, b/c it's more or less an on-page versus of @longdesc, and the examples included seem pretty trivial (image followed by a section describing the image). If someone were to present a more compelling use case, or if it starts getting wider adoption, we should pick it up. Implementation would likely just be a navigation or link action from the current element to the related details element.
Attachments
Patch (18.50 KB, patch)
2021-03-25 12:34 PDT, Andres Gonzalez
no flags
Patch (18.54 KB, patch)
2021-03-25 13:37 PDT, Andres Gonzalez
no flags
Radar WebKit Bug Importer
Comment 1 2017-02-26 17:07:48 PST
James Craig
Comment 2 2019-09-26 11:28:16 PDT
@aaronlev has posted the most compelling use case so far, for annotations in document suites like Google Docs. IMO, this is worth implementing now.
James Craig
Comment 3 2019-09-26 12:10:42 PDT
Aaron Leventhal
Comment 4 2020-01-13 09:51:55 PST
Note that as part of work on ARIA Annotations, the ARIA spec is being updated to allow aria-details to support multiple ids. See w3c/aria#1136
Aaron Leventhal
Comment 5 2020-01-13 09:56:40 PST
Note the importance of aria-details has increased quite a lot with the ARIA annotations work. Supporting aria-details will be necessary in order to support comments in Google Docs, among other things. W3C ARIA spec issue: https://github.com/w3c/aria/issues/749 Explainer: https://github.com/aleventhal/aria-annotations Also, multiple ids are now supported. See https://github.com/w3c/aria/pull/1136
Aaron Leventhal
Comment 6 2020-01-13 10:05:33 PST
Luckily, the changeset pointed to in comment 3 already supports multiple ids. But, I think it's only supporting ATK and not AX APIs?
Andres Gonzalez
Comment 7 2021-03-25 12:34:25 PDT
chris fleizach
Comment 8 2021-03-25 13:10:18 PDT
Comment on attachment 424269 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=424269&action=review > Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:1873 > + if (object) { are we ever going to have a case where we have a nil pointer in the vector? won't adding a nil pointer to a vector crash anyway?
Andres Gonzalez
Comment 9 2021-03-25 13:24:45 PDT
(In reply to chris fleizach from comment #8) > Comment on attachment 424269 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=424269&action=review > > > Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:1873 > > + if (object) { > > are we ever going to have a case where we have a nil pointer in the vector? > won't adding a nil pointer to a vector crash anyway? It is a Vector<RefPtr<>> and it can have null pointers on it. In the current use, it shouldn't have null pointers, but caller can pass null pointers, so I think it is appropriate to check before dereferencing here.
chris fleizach
Comment 10 2021-03-25 13:28:08 PDT
Comment on attachment 424269 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=424269&action=review >>> Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:1873 >>> + if (object) { >> >> are we ever going to have a case where we have a nil pointer in the vector? won't adding a nil pointer to a vector crash anyway? > > It is a Vector<RefPtr<>> and it can have null pointers on it. In the current use, it shouldn't have null pointers, but caller can pass null pointers, so I think it is appropriate to check before dereferencing here. I think we can save some lines of code if we do if (!object) continue;
Andres Gonzalez
Comment 11 2021-03-25 13:37:03 PDT
Andres Gonzalez
Comment 12 2021-03-25 13:38:23 PDT
(In reply to chris fleizach from comment #10) > Comment on attachment 424269 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=424269&action=review > > >>> Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:1873 > >>> + if (object) { > >> > >> are we ever going to have a case where we have a nil pointer in the vector? won't adding a nil pointer to a vector crash anyway? > > > > It is a Vector<RefPtr<>> and it can have null pointers on it. In the current use, it shouldn't have null pointers, but caller can pass null pointers, so I think it is appropriate to check before dereferencing here. > > I think we can save some lines of code if we do > > if (!object) > continue; Done, agree that is more legible.
EWS
Comment 13 2021-03-25 16:35:26 PDT
Committed r275066: <https://commits.webkit.org/r275066> All reviewed patches have been landed. Closing bug and clearing flags on attachment 424276 [details].
Note You need to log in before you can comment on or make changes to this bug.