diff --git a/.jest.js b/.jest.js index d162b283be..afcd51ffab 100644 --- a/.jest.js +++ b/.jest.js @@ -2,7 +2,7 @@ const transformIgnorePatterns = [ '/dist/', // Ignore modules without es dir. // Update: @babel/runtime should also be transformed - 'node_modules/(?!.*@babel)[^/]+?/(?!(es|node_modules)/)', + 'node_modules/(?!.*@(babel|ant-design))[^/]+?/(?!(es|node_modules)/)', ]; function getTestRegex(libDir) { diff --git a/components/_util/openAnimation.tsx b/components/_util/openAnimation.tsx index d5d3f4b862..243b0738f1 100644 --- a/components/_util/openAnimation.tsx +++ b/components/_util/openAnimation.tsx @@ -2,7 +2,7 @@ * Deprecated. We should replace the animation with pure react motion instead of modify style directly. * If you are creating new component with animation, please use `./motion`. */ -import cssAnimation from 'css-animation'; +import cssAnimation from '@ant-design/css-animation'; import raf from 'raf'; function animate(node: HTMLElement, show: boolean, done: () => void) { diff --git a/components/_util/wave.tsx b/components/_util/wave.tsx index 457eb8cd43..aa6aa96062 100644 --- a/components/_util/wave.tsx +++ b/components/_util/wave.tsx @@ -1,6 +1,6 @@ import * as React from 'react'; import { findDOMNode } from 'react-dom'; -import TransitionEvents from 'css-animation/lib/Event'; +import TransitionEvents from '@ant-design/css-animation/lib/Event'; import raf from './raf'; import { ConfigConsumer, ConfigConsumerProps, CSPConfig } from '../config-provider'; diff --git a/package.json b/package.json index 54d2de6680..22ecd84e0b 100644 --- a/package.json +++ b/package.json @@ -96,12 +96,12 @@ "ie >= 11" ], "dependencies": { + "@ant-design/css-animation": "^1.7.1", "@ant-design/icons": "^4.1.0", "@ant-design/react-slick": "~0.25.5", "array-tree-filter": "^2.1.0", "classnames": "~2.2.6", "copy-to-clipboard": "^3.2.0", - "css-animation": "^1.5.0", "lodash": "^4.17.13", "moment": "~2.25.3", "omit.js": "^1.0.2", diff --git a/typings/custom-typings.d.ts b/typings/custom-typings.d.ts index 05245aa613..5e9e592184 100644 --- a/typings/custom-typings.d.ts +++ b/typings/custom-typings.d.ts @@ -24,7 +24,7 @@ declare module 'rc-animate*'; declare module 'rc-util*'; -declare module 'css-animation*'; +declare module '@ant-design/css-animation*'; declare module 'rc-checkbox';