[csswg-drafts] [css-highlight-api] How should highlight pseudos be exposed to assistive techonologies? (#4601)

sanketj has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-highlight-api] How should highlight pseudos be exposed to assistive techonologies? ==
Moving this issue over from: https://github.com/MicrosoftEdge/MSEdgeExplainers/issues/73.

Post from @Reinmar:
I wonder if and how the semantics of created highlights should be exposed to assistive technologies.

For instance – when highlights would be used to render spellchecking squiggles we should also have a way to tell the that this piece of text is misspelled. I don't know how the selection itself is rendered in the Accessibility Object Model, but I think that highlights should be able to use the same mechanism.

I'd imagine that the easiest solution may be to allow defining a highlight's title. For a misspelled fragment of text it could be set to "misspelled" (that's at least what VoiceOver reads).

Post from @Comandeer
In the simplest case something like HighlightRange#label should be enough. However, if you already referenced AOM, there is proposal for virtual accessibility nodes, that are dedicated just for this case: exposing non-element nodes in accessibility tree. In such case HighlightRange interface should be updated in following manner:
partial interface HighlightRange {
 AccessibleNode attachAccessibleRoot();
The only part that it's worrying me a little is the fact that VANs are behaving a little like pseudoelements (they could have dimensions and position).

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4601 using your GitHub account

Received on Saturday, 14 December 2019 01:26:55 UTC