Read This First
No ARIA is better than Bad ARIA. Before using any ARIA, read this to understand why.
How to build accessibility semantics into web patterns and widgets
No ARIA is better than Bad ARIA. Before using any ARIA, read this to understand why.
A feed is a section of a page that automatically loads new sections of content as the user scrolls. The sections of content in a feed are presented in article elements. So, a feed can be thought of as a dynamic list of articles that often appears to scroll infinitely.
The feature that most distinguishes feed from other ARIA patterns that support loading data as users scroll, e.g., a grid, is that a feed is a structure, not a widget. Consequently, assistive technologies with a reading mode, such as screen readers, default to reading mode when interacting with feed content. However, unlike most other WAI-ARIA structures, a feed establishes an interoperability contract between the web page and assistive technologies. The contract governs scroll interactions so that assistive technology users can read articles, jump forward and backward by article, and reliably trigger new articles to load while in reading mode.
For example, a product page on a shopping site may have a related products section that displays five products at a time. As the user scrolls, more products are requested and loaded into the DOM. While a static design might include a next button for loading five more products, a dynamic implementation that automatically loads more data as the user scrolls simplifies the user experience and reduces the inertia associated with viewing more than the first five product suggestions. But, unfortunately when web pages load content dynamically based on scroll events, it can cause usability and interoperability difficulties for users of assistive technologies.
The feed pattern enables reliable assistive technology reading mode interaction by establishing the following interoperability agreement between the web page and assistive technologies:
Thus, implementing the feed pattern allows a screen reader to reliably read and trigger the loading of feed content while staying in its reading mode.
Another feature of the feed pattern is its ability to facilitate skim reading for assistive technology users. Web page authors may provide both an accessible name and description for each article. By identifying the elements inside of an article that provide the title and the primary content, assistive technologies can provide functions that enable users to jump from article to article and efficiently discern which articles may be worthy of more attention.
The feed pattern is not based on a desktop GUI widget so the feed
role is not associated with any well-established keyboard conventions.
Supporting the following, or a similar, interface is recommended.
When focus is inside the feed:
feed
element has aria-labelledby referring to the element containing the title.
Otherwise, the feed
element has a label specified with aria-label.
article
element.
article
element has aria-labelledby referring to elements inside the article that can serve as a distinguishing label.article
element to have aria-describedby referring to one or more elements inside the article that serve as the primary content of the article.article
element has aria-posinset set to a value that represents its position in the feed.article
element has aria-setsize set to a value that represents either the total number of articles that have been loaded or the total number in the feed, depending on which value is deemed more helpful to users.
If the total number in the feed is undetermined, it can be represented by a aria-setsize
value of -1
.
article
elements are being added to or removed from the feed
container, and if the operation requires multiple DOM operations, the feed
element has aria-busy set to true
during the update operation.
Note that it is extremely important that aria-busy
is set to false
when the operation is complete or the changes may not become visible to some assistive technology users.
This is an unpublished draft preview that might include content that is not yet approved. The published website is at w3.org/WAI/.