antd
Version:
An enterprise-class UI design language and React components implementation
31 lines (30 loc) • 911 B
JavaScript
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
import { Keyframes } from '@ant-design/cssinjs';
import { initMotion } from './motion';
export var fadeIn = new Keyframes('antFadeIn', {
'0%': {
opacity: 0
},
'100%': {
opacity: 1
}
});
export var fadeOut = new Keyframes('antFadeOut', {
'0%': {
opacity: 1
},
'100%': {
opacity: 0
}
});
export var initFadeMotion = function initFadeMotion(token) {
var _ref;
var antCls = token.antCls;
var motionCls = "".concat(antCls, "-fade");
return [initMotion(motionCls, fadeIn, fadeOut, token.motionDurationMid), (_ref = {}, _defineProperty(_ref, "\n ".concat(motionCls, "-enter,\n ").concat(motionCls, "-appear\n "), {
opacity: 0,
animationTimingFunction: 'linear'
}), _defineProperty(_ref, "".concat(motionCls, "-leave"), {
animationTimingFunction: 'linear'
}), _ref)];
};