Coder Social home page Coder Social logo

Comments (3)

cookiecrook avatar cookiecrook commented on May 10, 2024

One of the requests that always came into the ARIA group was to allow CSS-syntax in reference pointers. For example, this dialog is labeled by the first heading inside it. aria-labelledby="self > h1"... Of course that syntax didn't fly for a number of reasons.

The JavaScript object reference would solve most of the use cases for the CSS requests, since a web author could always use querySelector to get the element ref.

from aom.

minorninth avatar minorninth commented on May 10, 2024

I believe that the arrow syntax to break through web component boundaries was removed from the spec, so that made that idea really not work. It basically only would have helped with avoiding an id on every element within the same tree scope.

from aom.

minorninth avatar minorninth commented on May 10, 2024

Here's the other text I wrote up, to be merged.

Some ARIA attributes express relationships between DOM elements via an IDREF, where one element specifies the ID of the other. Two examples are aria-labelledby, and aria-activedescendant.

There are two drawbacks to this:

It can be cumbersome to add an ID to every element that needs to be referenced, for example adding an ID to every item in a dynamic list box so that the active descendant can be updated as the selected item in the list changes.

There are times when it's desirable to express a relationship between two elements that are within the same origin, but not the same ID namespace. For example, it's not possible in ARIA to express a relationship between two elements in different frames (even from the same origin), or between an element in the main page and an element inside a web component's shadow DOM.

Making it possible to implement accessibility support on the web via scripting would address this problem. Instead of setting an element's aria-activedescendant attribute to the ID of another element, it would be possible to directly establish the descendant relationship between one Element object and another Element object.

from aom.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.