@types/react-modal
Advanced tools
Comparing version 1.6.1 to 1.6.2
@@ -1,32 +0,62 @@ | ||
// Type definitions for react-modal v1.6.1 | ||
// Type definitions for react-modal 1.6 | ||
// Project: https://github.com/reactjs/react-modal | ||
// Definitions by: Rajab Shakirov <https://github.com/radziksh> | ||
// Definitions by: Rajab Shakirov <https://github.com/radziksh>, Drew Noakes <https://github.com/drewnoakes> | ||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped | ||
// TypeScript Version: 2.1 | ||
/// <reference types="react"/> | ||
import * as React from "react"; | ||
declare module "react-modal" { | ||
interface ReactModal { | ||
isOpen: boolean; | ||
export as namespace ReactModal; | ||
export = ReactModal; | ||
declare namespace ReactModal { | ||
export interface Styles { | ||
style?: { | ||
content?: { | ||
[key: string]: any; | ||
}, | ||
}; | ||
overlay?: { | ||
[key: string]: any; | ||
} | ||
}, | ||
appElement?: HTMLElement | {}, | ||
onAfterOpen?: Function, | ||
onRequestClose?: Function, | ||
closeTimeoutMS?: number, | ||
ariaHideApp?: boolean, | ||
shouldCloseOnOverlayClick?: boolean, | ||
overlayClassName?: string, | ||
className?: string | ||
contentLabel?: string | ||
}; | ||
}; | ||
} | ||
let ReactModal: React.ClassicComponentClass<ReactModal>; | ||
export = ReactModal; | ||
export interface Props { | ||
/* Boolean describing if the modal should be shown or not. Defaults to false. */ | ||
isOpen: boolean; | ||
/* Object indicating styles to be used for the modal, divided into overlay and content styles. */ | ||
style?: Styles; | ||
/* Set this to properly hide your application from assistive screenreaders and other assistive technologies while the modal is open. */ | ||
appElement?: HTMLElement | {}; | ||
/* Function that will be run after the modal has opened. */ | ||
onAfterOpen?: () => void; | ||
/* Function that will be run when the modal is requested to be closed, prior to actually closing. */ | ||
onRequestClose?: () => void; | ||
/* Number indicating the milliseconds to wait before closing the modal. Defaults to zero (no timeout). */ | ||
closeTimeoutMS?: number; | ||
/* Boolean indicating if the appElement should be hidden. Defaults to true. */ | ||
ariaHideApp?: boolean; | ||
/* Boolean indicating if the overlay should close the modal. Defaults to true. */ | ||
shouldCloseOnOverlayClick?: boolean; | ||
/* String className to be applied to the portal. Defaults to "ReactModalPortal". */ | ||
portalClassName?: string; | ||
/* String className to be applied to the overlay. */ | ||
overlayClassName?: string; | ||
/* String className to be applied to the modal content. */ | ||
className?: string; | ||
/* String indicating how the content container should be announced to screenreaders. */ | ||
contentLabel?: string; | ||
/* String indicating the role of the modal, allowing the 'dialog' role to be applied if desired. */ | ||
role?: string; | ||
/* Function that will be called to get the parent element that the modal will be attached to. */ | ||
parentSelector?: () => HTMLElement; | ||
} | ||
} | ||
declare class ReactModal extends React.Component<ReactModal.Props, {}> { | ||
/* Override base styles for all instances of this component. */ | ||
static defaultStyles: ReactModal.Styles; | ||
/* Call this to properly hide your application from assistive screenreaders and other assistive technologies while the modal is open. */ | ||
static setAppElement(appElement: HTMLElement): void; | ||
} |
{ | ||
"name": "@types/react-modal", | ||
"version": "1.6.1", | ||
"version": "1.6.2", | ||
"description": "TypeScript definitions for react-modal", | ||
"license": "MIT", | ||
"author": "Rajab Shakirov <https://github.com/radziksh>", | ||
"author": "Rajab Shakirov <https://github.com/radziksh>, Drew Noakes <https://github.com/drewnoakes>", | ||
"main": "", | ||
@@ -17,4 +17,4 @@ "repository": { | ||
"peerDependencies": {}, | ||
"typesPublisherContentHash": "f6763536e2a49be20411e97c28db2bd40f8f5a800623a8af85c2f58a48508955", | ||
"typesPublisherContentHash": "c553774490eb1bcfebe82e0a5d1d273a9e207a8fc15a2d5272fd6e3ddf1a7881", | ||
"typeScriptVersion": "2.1" | ||
} |
@@ -11,7 +11,7 @@ # Installation | ||
Additional Details | ||
* Last updated: Mon, 23 Jan 2017 21:31:30 GMT | ||
* Last updated: Tue, 07 Feb 2017 20:01:00 GMT | ||
* Dependencies: react | ||
* Global values: none | ||
* Global values: ReactModal | ||
# Credits | ||
These definitions were written by Rajab Shakirov <https://github.com/radziksh>. | ||
These definitions were written by Rajab Shakirov <https://github.com/radziksh>, Drew Noakes <https://github.com/drewnoakes>. |
@@ -6,3 +6,3 @@ { | ||
"data": { | ||
"authors": "Rajab Shakirov <https://github.com/radziksh>", | ||
"authors": "Rajab Shakirov <https://github.com/radziksh>, Drew Noakes <https://github.com/drewnoakes>", | ||
"dependencies": { | ||
@@ -19,5 +19,7 @@ "react": "*" | ||
"sourceRepoURL": "https://www.github.com/DefinitelyTyped/DefinitelyTyped", | ||
"globals": [], | ||
"globals": [ | ||
"ReactModal" | ||
], | ||
"declaredModules": [ | ||
"react-modal" | ||
"react-modal/." | ||
], | ||
@@ -28,5 +30,5 @@ "files": [ | ||
"hasPackageJson": false, | ||
"contentHash": "f6763536e2a49be20411e97c28db2bd40f8f5a800623a8af85c2f58a48508955" | ||
"contentHash": "c553774490eb1bcfebe82e0a5d1d273a9e207a8fc15a2d5272fd6e3ddf1a7881" | ||
}, | ||
"isLatest": true | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5120
86