@douyinfe/semi-animation-react 2.75.1-alpha.1 → 2.76.0-alpha.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -153,7 +153,6 @@ class Animation extends _react.PureComponent {
153
153
  }
154
154
  }
155
155
  }
156
- exports.default = Animation;
157
156
  Animation.propTypes = {
158
157
  onStart: _propTypes.default.func,
159
158
  onFrame: _propTypes.default.func,
@@ -181,4 +180,5 @@ Animation.defaultProps = {
181
180
  onResume: _noop.default,
182
181
  onStop: _noop.default,
183
182
  onRest: _noop.default
184
- };
183
+ };
184
+ var _default = exports.default = Animation;
@@ -86,7 +86,6 @@ class KeyFrames extends _react.Component {
86
86
  }), typeof children === 'function' ? children(currentStyle) : children);
87
87
  }
88
88
  }
89
- exports.default = KeyFrames;
90
89
  KeyFrames.propTypes = {
91
90
  frames: _propTypes.default.array,
92
91
  loop: _propTypes.default.bool,
@@ -100,4 +99,5 @@ KeyFrames.defaultProps = {
100
99
  onKeyRest: _noop.default,
101
100
  onRest: _noop.default,
102
101
  onFrame: _noop.default
103
- };
102
+ };
103
+ var _default = exports.default = KeyFrames;
@@ -78,6 +78,7 @@ class StyledAnimation extends _react.PureComponent {
78
78
  const hasLoopClass = this._hasLoopClass();
79
79
  const animateCls = className || (0, _classnames.default)(`${prefixCls}-animated`, {
80
80
  [`${prefixCls}-${type}`]: Boolean(type),
81
+ // How to use it before compatibility
81
82
  [`${prefixCls}-speed-${speed}`]: hasSpeedClass,
82
83
  [`${prefixCls}-delay-${delay}`]: hasDelayClass,
83
84
  [`${prefixCls}-loop-${loop}`]: hasLoopClass
@@ -107,7 +108,6 @@ class StyledAnimation extends _react.PureComponent {
107
108
  }) : children;
108
109
  }
109
110
  }
110
- exports.default = StyledAnimation;
111
111
  StyledAnimation.propTypes = {
112
112
  className: _propTypes.default.string,
113
113
  type: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.any]),
@@ -130,4 +130,5 @@ StyledAnimation.defaultProps = {
130
130
  onFrame: _noop.default,
131
131
  onStart: _noop.default,
132
132
  onRest: _noop.default
133
- };
133
+ };
134
+ var _default = exports.default = StyledAnimation;
@@ -112,7 +112,6 @@ class StyledTransition extends _react.Component {
112
112
  }), children);
113
113
  }
114
114
  }
115
- exports.default = StyledTransition;
116
115
  StyledTransition.propTypes = {
117
116
  state: _propTypes.default.string,
118
117
  enter: _propTypes.default.string,
@@ -132,4 +131,5 @@ StyledTransition.defaultProps = {
132
131
  didLeave: _noop.default,
133
132
  onStart: _noop.default,
134
133
  onRest: _noop.default
135
- };
134
+ };
135
+ var _default = exports.default = StyledTransition;
@@ -130,7 +130,6 @@ class Transition extends _react.Component {
130
130
  typeof children === 'function' ? children(props) : /*#__PURE__*/(0, _react.isValidElement)(children) ? children : null);
131
131
  }
132
132
  }
133
- exports.default = Transition;
134
133
  Transition.propTypes = {
135
134
  children: _propTypes.default.any,
136
135
  from: _propTypes.default.object,
@@ -149,4 +148,5 @@ Transition.defaultProps = {
149
148
  didLeave: _noop.default,
150
149
  onStart: _noop.default,
151
150
  onRest: _noop.default
152
- };
151
+ };
152
+ var _default = exports.default = Transition;
@@ -1 +0,0 @@
1
-
@@ -3,7 +3,7 @@ import { PureComponent, isValidElement } from 'react';
3
3
  import PropTypes from 'prop-types';
4
4
  import { Animation as SemiAnimation, events } from '@douyinfe/semi-animation';
5
5
  import noop from './utils/noop';
6
- export default class Animation extends PureComponent {
6
+ class Animation extends PureComponent {
7
7
  constructor() {
8
8
  let props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
9
9
  super(props);
@@ -172,4 +172,5 @@ Animation.defaultProps = {
172
172
  onResume: noop,
173
173
  onStop: noop,
174
174
  onRest: noop
175
- };
175
+ };
176
+ export default Animation;
@@ -2,7 +2,7 @@ import React, { Component } from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import noop from './utils/noop';
4
4
  import Animation from './Animation';
5
- export default class KeyFrames extends Component {
5
+ class KeyFrames extends Component {
6
6
  constructor() {
7
7
  var _this;
8
8
  let props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
@@ -90,4 +90,5 @@ KeyFrames.defaultProps = {
90
90
  onKeyRest: noop,
91
91
  onRest: noop,
92
92
  onFrame: noop
93
- };
93
+ };
94
+ export default KeyFrames;
@@ -5,7 +5,7 @@ import { types as styledTypes, loops, delays, speeds } from '@douyinfe/semi-anim
5
5
  import noop from './utils/noop';
6
6
  import invokeFns from './utils/invokeFns';
7
7
  const types = Object.values(styledTypes).reduce((arr, cur) => [...arr, ...cur], []);
8
- export default class StyledAnimation extends PureComponent {
8
+ class StyledAnimation extends PureComponent {
9
9
  constructor() {
10
10
  var _this;
11
11
  let props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
@@ -71,6 +71,7 @@ export default class StyledAnimation extends PureComponent {
71
71
  const hasLoopClass = this._hasLoopClass();
72
72
  const animateCls = className || classnames(`${prefixCls}-animated`, {
73
73
  [`${prefixCls}-${type}`]: Boolean(type),
74
+ // How to use it before compatibility
74
75
  [`${prefixCls}-speed-${speed}`]: hasSpeedClass,
75
76
  [`${prefixCls}-delay-${delay}`]: hasDelayClass,
76
77
  [`${prefixCls}-loop-${loop}`]: hasLoopClass
@@ -122,4 +123,5 @@ StyledAnimation.defaultProps = {
122
123
  onFrame: noop,
123
124
  onStart: noop,
124
125
  onRest: noop
125
- };
126
+ };
127
+ export default StyledAnimation;
@@ -10,7 +10,7 @@ import React, { Component } from 'react';
10
10
  import PropTypes from 'prop-types';
11
11
  import StyledAnimation from './StyledAnimation';
12
12
  import noop from './utils/noop';
13
- export default class StyledTransition extends Component {
13
+ class StyledTransition extends Component {
14
14
  constructor() {
15
15
  let props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
16
16
  super(props);
@@ -122,4 +122,5 @@ StyledTransition.defaultProps = {
122
122
  didLeave: noop,
123
123
  onStart: noop,
124
124
  onRest: noop
125
- };
125
+ };
126
+ export default StyledTransition;
@@ -10,7 +10,7 @@ import Animation from './Animation';
10
10
  import PropTypes from 'prop-types';
11
11
  import React, { Component, isValidElement } from 'react';
12
12
  import noop from './utils/noop';
13
- export default class Transition extends Component {
13
+ class Transition extends Component {
14
14
  constructor() {
15
15
  let props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
16
16
  super(props);
@@ -139,4 +139,5 @@ Transition.defaultProps = {
139
139
  didLeave: noop,
140
140
  onStart: noop,
141
141
  onRest: noop
142
- };
142
+ };
143
+ export default Transition;
@@ -1 +0,0 @@
1
-
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@douyinfe/semi-animation-react",
3
- "version": "2.75.1-alpha.1",
3
+ "version": "2.76.0-alpha.5",
4
4
  "description": "motion library for semi-ui-react",
5
5
  "keywords": [
6
6
  "motion",
@@ -25,8 +25,8 @@
25
25
  "prepublishOnly": "npm run build:lib"
26
26
  },
27
27
  "dependencies": {
28
- "@douyinfe/semi-animation": "2.75.1-alpha.1",
29
- "@douyinfe/semi-animation-styled": "2.75.1-alpha.1",
28
+ "@douyinfe/semi-animation": "2.76.0-alpha.5",
29
+ "@douyinfe/semi-animation-styled": "2.76.0-alpha.2",
30
30
  "classnames": "^2.2.6"
31
31
  },
32
32
  "devDependencies": {
@@ -42,5 +42,5 @@
42
42
  "prop-types": "^15.7.2",
43
43
  "react-storybook-addon-props-combinations": "^1.1.0"
44
44
  },
45
- "gitHead": "008eacc5033ed0cec2856002dfdf0ecd46debb67"
45
+ "gitHead": "ed20b573906886b80463cd67c9ef328066e983e4"
46
46
  }