@types/react-modal
Advanced tools
Comparing version 3.12.0 to 3.12.1
@@ -22,4 +22,4 @@ // Type definitions for react-modal 3.12 | ||
interface Styles { | ||
content?: React.CSSProperties; | ||
overlay?: React.CSSProperties; | ||
content?: React.CSSProperties | undefined; | ||
overlay?: React.CSSProperties | undefined; | ||
} | ||
@@ -35,7 +35,7 @@ | ||
/** Defines a string value that labels the current element. */ | ||
labelledby?: string; | ||
labelledby?: string | undefined; | ||
/** Identifies the element (or elements) that describes the object. */ | ||
describedby?: string; | ||
describedby?: string | undefined; | ||
/** Indicates whether an element is modal when displayed. */ | ||
modal?: boolean | 'false' | 'true'; | ||
modal?: boolean | 'false' | 'true' | undefined; | ||
} | ||
@@ -61,24 +61,24 @@ | ||
/* Object indicating styles to be used for the modal, divided into overlay and content styles. */ | ||
style?: Styles; | ||
style?: Styles | undefined; | ||
/* String className to be applied to the portal. Defaults to "ReactModalPortal". */ | ||
portalClassName?: string; | ||
portalClassName?: string | undefined; | ||
/* String className to be applied to the document.body (must be a constant string). When set to null it doesn't add any class to document.body. */ | ||
bodyOpenClassName?: string | null; | ||
bodyOpenClassName?: string | null | undefined; | ||
/* String className to be applied to the document.html (must be a constant string). Defaults to null. */ | ||
htmlOpenClassName?: string | null; | ||
htmlOpenClassName?: string | null | undefined; | ||
/* String or object className to be applied to the modal content. */ | ||
className?: string | Classes; | ||
className?: string | Classes | undefined; | ||
/* String or object className to be applied to the overlay. */ | ||
overlayClassName?: string | Classes; | ||
overlayClassName?: string | Classes | undefined; | ||
/* Set this to properly hide your application from assistive screenreaders and other assistive technologies while the modal is open. */ | ||
appElement?: HTMLElement | {}; | ||
appElement?: HTMLElement | {} | undefined; | ||
/* Function that will be run after the modal has opened. */ | ||
onAfterOpen?: OnAfterOpenCallback; | ||
onAfterOpen?: OnAfterOpenCallback | undefined; | ||
@@ -92,21 +92,21 @@ /* Function that will be run after the modal has closed. */ | ||
/* Number indicating the milliseconds to wait before closing the modal. Defaults to zero (no timeout). */ | ||
closeTimeoutMS?: number; | ||
closeTimeoutMS?: number | undefined; | ||
/* Boolean indicating if the appElement should be hidden. Defaults to true. */ | ||
ariaHideApp?: boolean; | ||
ariaHideApp?: boolean | undefined; | ||
/* Boolean indicating if the modal should be focused after render */ | ||
shouldFocusAfterRender?: boolean; | ||
shouldFocusAfterRender?: boolean | undefined; | ||
/* Boolean indicating if the overlay should close the modal. Defaults to true. */ | ||
shouldCloseOnOverlayClick?: boolean; | ||
shouldCloseOnOverlayClick?: boolean | undefined; | ||
/* Boolean indicating if pressing the esc key should close the modal */ | ||
shouldCloseOnEsc?: boolean; | ||
shouldCloseOnEsc?: boolean | undefined; | ||
/* Boolean indicating if the modal should restore focus to the element that had focus prior to its display. */ | ||
shouldReturnFocusAfterClose?: boolean; | ||
shouldReturnFocusAfterClose?: boolean | undefined; | ||
/* Boolean indicating if the modal should use the preventScroll flag when restoring focus to the element that had focus prior to its display. */ | ||
preventScroll?: boolean; | ||
preventScroll?: boolean | undefined; | ||
@@ -117,3 +117,3 @@ /* Function that will be called to get the parent element that the modal will be attached to. */ | ||
/* Additional aria attributes. */ | ||
aria?: Aria; | ||
aria?: Aria | undefined; | ||
@@ -124,23 +124,23 @@ /* Additional data attributes to be applied to to the modal content in the form of "data-*" */ | ||
/* String indicating the role of the modal, allowing the 'dialog' role to be applied if desired. Defaults to "dialog". */ | ||
role?: string | null; | ||
role?: string | null | undefined; | ||
/* String indicating how the content container should be announced to screenreaders. */ | ||
contentLabel?: string; | ||
contentLabel?: string | undefined; | ||
/* Function accepting the ref for the content */ | ||
contentRef?: (instance: HTMLDivElement) => void; | ||
contentRef?: ((instance: HTMLDivElement) => void) | undefined; | ||
/* Function accepting the ref for the overlay */ | ||
overlayRef?: (instance: HTMLDivElement) => void; | ||
overlayRef?: ((instance: HTMLDivElement) => void) | undefined; | ||
/* Custom Overlay element. */ | ||
overlayElement?: (props: React.ComponentPropsWithRef<"div">, contentEl: React.ReactElement) => React.ReactElement; | ||
overlayElement?: ((props: React.ComponentPropsWithRef<"div">, contentEl: React.ReactElement) => React.ReactElement) | undefined; | ||
/* Custom Content element. */ | ||
contentElement?: (props: React.ComponentPropsWithRef<"div">, children: React.ReactNode) => React.ReactElement; | ||
contentElement?: ((props: React.ComponentPropsWithRef<"div">, children: React.ReactNode) => React.ReactElement) | undefined; | ||
/* String value of data-test-id attibute to be applied to to the modal content. */ | ||
testId?: string; | ||
testId?: string | undefined; | ||
/* String value of an id attribute to be applied to the modal content */ | ||
id?: string; | ||
id?: string | undefined; | ||
} | ||
@@ -147,0 +147,0 @@ } |
{ | ||
"name": "@types/react-modal", | ||
"version": "3.12.0", | ||
"version": "3.12.1", | ||
"description": "TypeScript definitions for react-modal", | ||
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-modal", | ||
"license": "MIT", | ||
@@ -64,4 +65,4 @@ "contributors": [ | ||
}, | ||
"typesPublisherContentHash": "0f8db1c6b52191299f1686abb0f3e3cec9084e24cb0ac662715ce73c936f4be8", | ||
"typeScriptVersion": "3.4" | ||
"typesPublisherContentHash": "96e32f5cdc7c451b6e0f26b987c506c1ed2d2c16591ee78e007948dc0ecb61c6", | ||
"typeScriptVersion": "3.6" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
### Additional Details | ||
* Last updated: Thu, 04 Feb 2021 13:23:15 GMT | ||
* Last updated: Wed, 07 Jul 2021 17:33:48 GMT | ||
* Dependencies: [@types/react](https://npmjs.com/package/@types/react) | ||
@@ -14,0 +14,0 @@ * Global values: `ReactModal` |
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
10901
0