diff --git a/.gitignore b/.gitignore index 1ba4483e4..2215b0e74 100644 --- a/.gitignore +++ b/.gitignore @@ -12,3 +12,5 @@ build dist packages/**/CHANGELOG.md .vscode/ +test/types/index.ts +test/types/tsconfig.json diff --git a/.travis.yml b/.travis.yml index ccb987775..1b3b0b93b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,11 +22,10 @@ matrix: install: npm i script: npm run lint - #TODO(issues/936): Fix existing errors before requiring this to pass - #- node_js: 10 - # env: TEST_SUITE=types - # install: npm i - # script: npm run test:types + - node_js: 10 + env: TEST_SUITE=types + install: npm i + script: npm run test:types - node_js: 10 install: npm i diff --git a/packages/button/index.tsx b/packages/button/index.tsx index 82da7c86d..a4341c91f 100644 --- a/packages/button/index.tsx +++ b/packages/button/index.tsx @@ -22,7 +22,12 @@ import React from 'react'; import classnames from 'classnames'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; import {CSS_CLASSES} from './constant'; diff --git a/packages/card/PrimaryContent.tsx b/packages/card/PrimaryContent.tsx index 53f1d5e8c..fdd5c621b 100644 --- a/packages/card/PrimaryContent.tsx +++ b/packages/card/PrimaryContent.tsx @@ -22,7 +22,12 @@ import React from 'react'; import classnames from 'classnames'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; import {CSS_CLASSES} from './constant'; diff --git a/packages/checkbox/index.tsx b/packages/checkbox/index.tsx index 02043e783..0c9babad0 100644 --- a/packages/checkbox/index.tsx +++ b/packages/checkbox/index.tsx @@ -25,7 +25,12 @@ import classnames from 'classnames'; import {MDCCheckboxFoundation} from '@material/checkbox/foundation'; import {MDCCheckboxAdapter} from '@material/checkbox/adapter'; import {cssClasses} from '@material/checkbox/constants'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; import NativeControl from './NativeControl'; diff --git a/packages/chips/Chip.tsx b/packages/chips/Chip.tsx index 6b02f1a9c..ed3404b3e 100644 --- a/packages/chips/Chip.tsx +++ b/packages/chips/Chip.tsx @@ -21,7 +21,12 @@ // THE SOFTWARE. import React from 'react'; import classnames from 'classnames'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; import {MDCChipFoundation} from '@material/chips/chip/foundation'; import {MDCChipAdapter} from '@material/chips/chip/adapter'; diff --git a/packages/fab/index.tsx b/packages/fab/index.tsx index c05b8eddf..4fa69992e 100644 --- a/packages/fab/index.tsx +++ b/packages/fab/index.tsx @@ -22,7 +22,12 @@ import React from 'react'; import classnames from 'classnames'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; import {CSS_CLASSES} from './constant'; diff --git a/packages/icon-button/index.tsx b/packages/icon-button/index.tsx index 28ca4514a..739e5bb1c 100644 --- a/packages/icon-button/index.tsx +++ b/packages/icon-button/index.tsx @@ -22,7 +22,12 @@ import React from 'react'; import classnames from 'classnames'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; import {MDCIconButtonToggleAdapter} from '@material/icon-button/adapter'; import {MDCIconButtonToggleFoundation} from '@material/icon-button/foundation'; import {MDCIconButtonToggleEventDetail} from '@material/icon-button/types'; diff --git a/packages/list/ListItem.tsx b/packages/list/ListItem.tsx index fd534683c..63654d477 100644 --- a/packages/list/ListItem.tsx +++ b/packages/list/ListItem.tsx @@ -23,7 +23,12 @@ import React from 'react'; import classnames from 'classnames'; import {closest} from '@material/dom/ponyfill'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; import {MDCListFoundation} from '@material/list/foundation'; import {ListItemContext, ListItemContextShape} from './index'; diff --git a/packages/material-icon/index.tsx b/packages/material-icon/index.tsx index 1c79df8f9..05e9a85f7 100644 --- a/packages/material-icon/index.tsx +++ b/packages/material-icon/index.tsx @@ -22,7 +22,12 @@ import React from 'react'; import classnames from 'classnames'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; export interface MaterialIconDefaultProps extends React.HTMLAttributes { diff --git a/packages/radio/index.tsx b/packages/radio/index.tsx index 27bfbf789..a37795a10 100644 --- a/packages/radio/index.tsx +++ b/packages/radio/index.tsx @@ -24,7 +24,12 @@ import React from 'react'; import classnames from 'classnames'; import {MDCRadioFoundation} from '@material/radio/foundation'; import {MDCRadioAdapter} from '@material/radio/adapter'; -import {withRipple, InjectedProps} from '@material/react-ripple'; +import { + withRipple, + InjectedProps, + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars +} from '@material/react-ripple'; import NativeControl, {NativeControlProps} from './NativeControl'; // eslint-disable-line @typescript-eslint/no-unused-vars export interface RadioProps diff --git a/packages/tab/TabRipple.tsx b/packages/tab/TabRipple.tsx index b4a640543..6166b6417 100644 --- a/packages/tab/TabRipple.tsx +++ b/packages/tab/TabRipple.tsx @@ -27,7 +27,9 @@ import { withRipple, InjectedProps, RippledComponentInterface, - RippledComponentState, // eslint-disable-line @typescript-eslint/no-unused-vars + // @ts-ignore TODO(issues/955) Remove once possible + RippledComponentProps, // eslint-disable-line @typescript-eslint/no-unused-vars + RippledComponentState, } from '@material/react-ripple'; export interface TabRippleProps