Add aria-modal attribute to react-modal types (#37980)

This commit is contained in:
Craig Weber
2019-08-29 17:52:47 -07:00
committed by Ron Buckton
parent 16bfebc985
commit 9f18dc6b30
2 changed files with 6 additions and 1 deletions
+4
View File
@@ -32,8 +32,12 @@ declare namespace ReactModal {
}
interface Aria {
/** Defines a string value that labels the current element. */
labelledby?: string;
/** Identifies the element (or elements) that describes the object. */
describedby?: string;
/** Indicates whether an element is modal when displayed. */
modal?: boolean | 'false' | 'true';
}
interface Props {
+2 -1
View File
@@ -50,7 +50,8 @@ class ExampleOfUsingReactModal extends React.Component {
};
const customAriaVariables = {
labelledby: 'labelledby',
describedby: 'describedby'
describedby: 'describedby',
modal: true,
};
const customDataVariables = {
dataOne: 'one',