Update aria-relevant type. (#47012)

Update the aria-relevant type to include "additions removals" as the existing type is inaccurate. The actual type is a space delimited list of keywords: "additions", "removals", "text",  or "all".
This commit is contained in:
kid-icarus 2020-08-24 22:52:33 -07:00 committed by GitHub
parent e18788ab97
commit 23a1fd68ce
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -1688,7 +1688,7 @@ declare namespace React {
* Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.
* @see aria-atomic.
*/
'aria-relevant'?: 'additions' | 'additions text' | 'all' | 'removals' | 'text';
'aria-relevant'?: 'additions' | 'additions removals' | 'additions text' | 'all' | 'removals' | 'removals additions' | 'removals text' | 'text' | 'text additions' | 'text removals';
/** Indicates that user input is required on the element before a form may be submitted. */
'aria-required'?: boolean | 'false' | 'true';
/** Defines a human-readable, author-localized description for the role of an element. */

View File

@ -501,7 +501,8 @@ const htmlAttr: React.HTMLProps<HTMLElement> = {
'aria-atomic': false,
'aria-checked': 'true',
'aria-colcount': 7,
'aria-label': 'test'
'aria-label': 'test',
'aria-relevant': 'additions removals'
};
DOM.div(htmlAttr);
DOM.span(htmlAttr);