{"version":3,"sources":["webpack:///./node_modules/rc-animate/es/ChildrenUtils.js","webpack:///./node_modules/rc-animate/es/util/animate.js","webpack:///./node_modules/rc-animate/es/AnimateChild.js","webpack:///./node_modules/rc-animate/es/Animate.js"],"names":["toArrayChildren","children","ret","react_default","a","Children","forEach","child","push","findChildInChildrenByKey","key","findShownChildInChildrenByKey","showProp","props","Error","animate","isAppearSupported","transitionName","transitionAppear","animation","appear","isEnterSupported","transitionEnter","enter","isLeaveSupported","transitionLeave","leave","allowAppearCallback","allowEnterCallback","allowLeaveCallback","transitionMap","AnimateChild_AnimateChild","_React$Component","AnimateChild","classCallCheck_default","this","possibleConstructorReturn_default","__proto__","Object","getPrototypeOf","apply","arguments","inherits_default","createClass_default","value","stop","done","transition","animationType","finishCallback","_this2","node","react_dom_default","findDOMNode","nameIsObj","end","stopper","es","name","activeName","active","Component","propTypes","prop_types_default","any","es_AnimateChild","defaultKey","Date","now","getChildrenFromProps","isValidElement","cloneElement","noop","Animate_Animate","Animate","_this","call","Animate_initialiseProps","currentlyAnimatingKeys","keysToEnter","keysToLeave","state","childrenRefs","filter","performAppear","nextProps","_this3","nextChildren","exclusive","keys","next","nextChildrenPending","pendingChildren","currentChildren","newChildren","currentChild","nextChild","newChild","defineProperty_default","length","prototype","hasOwnProperty","concat","setState","hasPrev","showInNext","hasNext","showInNow","performEnter","performLeave","component","_this4","stateChildren","map","createElement","ref","passedProps","extends_default","className","style","componentProps","isAnimate","object","oneOfType","string","bool","onEnd","func","onEnter","onLeave","onAppear","defaultProps","_this5","componentWillEnter","handleDoneAdding","bind","componentWillAppear","type","isValidChildByKey","componentWillLeave","handleDoneLeaving","c1","c2","same","index","child2","__webpack_exports__"],"mappings":"8NAEO,SAAAA,EAAAC,GACP,IAAAC,EAAA,GAIA,OAHEC,EAAAC,EAAKC,SAAAC,QAAAL,EAAA,SAAAM,GACPL,EAAAM,KAAAD,KAEAL,EAGO,SAAAO,EAAAR,EAAAS,GACP,IAAAR,EAAA,KAWA,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AAAD,KACTmI,GAAA,MAKAA,EGmRAxF,IAJA6E,EAAA7B,SAAA,CACAtG,SAAA4F,GACStC,OAQM2F,EAAA","file":"vendor.rc-animate~a51c4939.bundle.js","sourcesContent":["import React from 'react';\n\nexport function toArrayChildren(children) {\n  var ret = [];\n  React.Children.forEach(children, function (child) {\n    ret.push(child);\n  });\n  return ret;\n}\n\nexport function findChildInChildrenByKey(children, key) {\n  var ret = null;\n  if (children) {\n    children.forEach(function (child) {\n      if (ret) {\n        return;\n      }\n      if (child && child.key === key) {\n        ret = child;\n      }\n    });\n  }\n  return ret;\n}\n\nexport function findShownChildInChildrenByKey(children, key, showProp) {\n  var ret = null;\n  if (children) {\n    children.forEach(function (child) {\n      if (child && child.key === key && child.props[showProp]) {\n        if (ret) {\n          throw new Error('two child with same key for <rc-animate> children');\n        }\n        ret = child;\n      }\n    });\n  }\n  return ret;\n}\n\nexport function findHiddenChildInChildrenByKey(children, key, showProp) {\n  var found = 0;\n  if (children) {\n    children.forEach(function (child) {\n      if (found) {\n        return;\n      }\n      found = child && child.key === key && !child.props[showProp];\n    });\n  }\n  return found;\n}\n\nexport function isSameChildren(c1, c2, showProp) {\n  var same = c1.length === c2.length;\n  if (same) {\n    c1.forEach(function (child, index) {\n      var child2 = c2[index];\n      if (child && child2) {\n        if (child && !child2 || !child && child2) {\n          same = false;\n        } else if (child.key !== child2.key) {\n          same = false;\n        } else if (showProp && child.props[showProp] !== child2.props[showProp]) {\n          same = false;\n        }\n      }\n    });\n  }\n  return same;\n}\n\nexport function mergeChildren(prev, next) {\n  var ret = [];\n\n  // For each key of `next`, the list of keys to insert before that key in\n  // the combined list\n  var nextChildrenPending = {};\n  var pendingChildren = [];\n  prev.forEach(function (child) {\n    if (child && findChildInChildrenByKey(next, child.key)) {\n      if (pendingChildren.length) {\n        nextChildrenPending[child.key] = pendingChildren;\n        pendingChildren = [];\n      }\n    } else {\n      pendingChildren.push(child);\n    }\n  });\n\n  next.forEach(function (child) {\n    if (child && Object.prototype.hasOwnProperty.call(nextChildrenPending, child.key)) {\n      ret = ret.concat(nextChildrenPending[child.key]);\n    }\n    ret.push(child);\n  });\n\n  ret = ret.concat(pendingChildren);\n\n  return ret;\n}","var util = {\n  isAppearSupported: function isAppearSupported(props) {\n    return props.transitionName && props.transitionAppear || props.animation.appear;\n  },\n  isEnterSupported: function isEnterSupported(props) {\n    return props.transitionName && props.transitionEnter || props.animation.enter;\n  },\n  isLeaveSupported: function isLeaveSupported(props) {\n    return props.transitionName && props.transitionLeave || props.animation.leave;\n  },\n  allowAppearCallback: function allowAppearCallback(props) {\n    return props.transitionAppear || props.animation.appear;\n  },\n  allowEnterCallback: function allowEnterCallback(props) {\n    return props.transitionEnter || props.animation.enter;\n  },\n  allowLeaveCallback: function allowLeaveCallback(props) {\n    return props.transitionLeave || props.animation.leave;\n  }\n};\nexport default util;","import _classCallCheck from 'babel-runtime/helpers/classCallCheck';\nimport _createClass from 'babel-runtime/helpers/createClass';\nimport _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';\nimport _inherits from 'babel-runtime/helpers/inherits';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport cssAnimate, { isCssAnimationSupported } from 'css-animation';\nimport animUtil from './util/animate';\n\nvar transitionMap = {\n  enter: 'transitionEnter',\n  appear: 'transitionAppear',\n  leave: 'transitionLeave'\n};\n\nvar AnimateChild = function (_React$Component) {\n  _inherits(AnimateChild, _React$Component);\n\n  function AnimateChild() {\n    _classCallCheck(this, AnimateChild);\n\n    return _possibleConstructorReturn(this, (AnimateChild.__proto__ || Object.getPrototypeOf(AnimateChild)).apply(this, arguments));\n  }\n\n  _createClass(AnimateChild, [{\n    key: 'componentWillUnmount',\n    value: function componentWillUnmount() {\n      this.stop();\n    }\n  }, {\n    key: 'componentWillEnter',\n    value: function componentWillEnter(done) {\n      if (animUtil.isEnterSupported(this.props)) {\n        this.transition('enter', done);\n      } else {\n        done();\n      }\n    }\n  }, {\n    key: 'componentWillAppear',\n    value: function componentWillAppear(done) {\n      if (animUtil.isAppearSupported(this.props)) {\n        this.transition('appear', done);\n      } else {\n        done();\n      }\n    }\n  }, {\n    key: 'componentWillLeave',\n    value: function componentWillLeave(done) {\n      if (animUtil.isLeaveSupported(this.props)) {\n        this.transition('leave', done);\n      } else {\n        // always sync, do not interupt with react component life cycle\n        // update hidden -> animate hidden ->\n        // didUpdate -> animate leave -> unmount (if animate is none)\n        done();\n      }\n    }\n  }, {\n    key: 'transition',\n    value: function transition(animationType, finishCallback) {\n      var _this2 = this;\n\n      var node = ReactDOM.findDOMNode(this);\n      var props = this.props;\n      var transitionName = props.transitionName;\n      var nameIsObj = typeof transitionName === 'object';\n      this.stop();\n      var end = function end() {\n        _this2.stopper = null;\n        finishCallback();\n      };\n      if ((isCssAnimationSupported || !props.animation[animationType]) && transitionName && props[transitionMap[animationType]]) {\n        var name = nameIsObj ? transitionName[animationType] : transitionName + '-' + animationType;\n        var activeName = name + '-active';\n        if (nameIsObj && transitionName[animationType + 'Active']) {\n          activeName = transitionName[animationType + 'Active'];\n        }\n        this.stopper = cssAnimate(node, {\n          name: name,\n          active: activeName\n        }, end);\n      } else {\n        this.stopper = props.animation[animationType](node, end);\n      }\n    }\n  }, {\n    key: 'stop',\n    value: function stop() {\n      var stopper = this.stopper;\n      if (stopper) {\n        this.stopper = null;\n        stopper.stop();\n      }\n    }\n  }, {\n    key: 'render',\n    value: function render() {\n      return this.props.children;\n    }\n  }]);\n\n  return AnimateChild;\n}(React.Component);\n\nAnimateChild.propTypes = {\n  children: PropTypes.any\n};\nexport default AnimateChild;","import _extends from 'babel-runtime/helpers/extends';\nimport _defineProperty from 'babel-runtime/helpers/defineProperty';\nimport _classCallCheck from 'babel-runtime/helpers/classCallCheck';\nimport _createClass from 'babel-runtime/helpers/createClass';\nimport _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';\nimport _inherits from 'babel-runtime/helpers/inherits';\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport { toArrayChildren, mergeChildren, findShownChildInChildrenByKey, findChildInChildrenByKey, isSameChildren } from './ChildrenUtils';\nimport AnimateChild from './AnimateChild';\nimport animUtil from './util/animate';\n\nvar defaultKey = 'rc_animate_' + Date.now();\n\nfunction getChildrenFromProps(props) {\n  var children = props.children;\n  if (React.isValidElement(children)) {\n    if (!children.key) {\n      return React.cloneElement(children, {\n        key: defaultKey\n      });\n    }\n  }\n  return children;\n}\n\nfunction noop() {}\n\nvar Animate = function (_React$Component) {\n  _inherits(Animate, _React$Component);\n\n  // eslint-disable-line\n\n  function Animate(props) {\n    _classCallCheck(this, Animate);\n\n    var _this = _possibleConstructorReturn(this, (Animate.__proto__ || Object.getPrototypeOf(Animate)).call(this, props));\n\n    _initialiseProps.call(_this);\n\n    _this.currentlyAnimatingKeys = {};\n    _this.keysToEnter = [];\n    _this.keysToLeave = [];\n\n    _this.state = {\n      children: toArrayChildren(getChildrenFromProps(props))\n    };\n\n    _this.childrenRefs = {};\n    return _this;\n  }\n\n  _createClass(Animate, [{\n    key: 'componentDidMount',\n    value: function componentDidMount() {\n      var _this2 = this;\n\n      var showProp = this.props.showProp;\n      var children = this.state.children;\n      if (showProp) {\n        children = children.filter(function (child) {\n          return !!child.props[showProp];\n        });\n      }\n      children.forEach(function (child) {\n        if (child) {\n          _this2.performAppear(child.key);\n        }\n      });\n    }\n  }, {\n    key: 'componentWillReceiveProps',\n    value: function componentWillReceiveProps(nextProps) {\n      var _this3 = this;\n\n      this.nextProps = nextProps;\n      var nextChildren = toArrayChildren(getChildrenFromProps(nextProps));\n      var props = this.props;\n      // exclusive needs immediate response\n      if (props.exclusive) {\n        Object.keys(this.currentlyAnimatingKeys).forEach(function (key) {\n          _this3.stop(key);\n        });\n      }\n      var showProp = props.showProp;\n      var currentlyAnimatingKeys = this.currentlyAnimatingKeys;\n      // last props children if exclusive\n      var currentChildren = props.exclusive ? toArrayChildren(getChildrenFromProps(props)) : this.state.children;\n      // in case destroy in showProp mode\n      var newChildren = [];\n      if (showProp) {\n        currentChildren.forEach(function (currentChild) {\n          var nextChild = currentChild && findChildInChildrenByKey(nextChildren, currentChild.key);\n          var newChild = void 0;\n          if ((!nextChild || !nextChild.props[showProp]) && currentChild.props[showProp]) {\n            newChild = React.cloneElement(nextChild || currentChild, _defineProperty({}, showProp, true));\n          } else {\n            newChild = nextChild;\n          }\n          if (newChild) {\n            newChildren.push(newChild);\n          }\n        });\n        nextChildren.forEach(function (nextChild) {\n          if (!nextChild || !findChildInChildrenByKey(currentChildren, nextChild.key)) {\n            newChildren.push(nextChild);\n          }\n        });\n      } else {\n        newChildren = mergeChildren(currentChildren, nextChildren);\n      }\n\n      // need render to avoid update\n      this.setState({\n        children: newChildren\n      });\n\n      nextChildren.forEach(function (child) {\n        var key = child && child.key;\n        if (child && currentlyAnimatingKeys[key]) {\n          return;\n        }\n        var hasPrev = child && findChildInChildrenByKey(currentChildren, key);\n        if (showProp) {\n          var showInNext = child.props[showProp];\n          if (hasPrev) {\n            var showInNow = findShownChildInChildrenByKey(currentChildren, key, showProp);\n            if (!showInNow && showInNext) {\n              _this3.keysToEnter.push(key);\n            }\n          } else if (showInNext) {\n            _this3.keysToEnter.push(key);\n          }\n        } else if (!hasPrev) {\n          _this3.keysToEnter.push(key);\n        }\n      });\n\n      currentChildren.forEach(function (child) {\n        var key = child && child.key;\n        if (child && currentlyAnimatingKeys[key]) {\n          return;\n        }\n        var hasNext = child && findChildInChildrenByKey(nextChildren, key);\n        if (showProp) {\n          var showInNow = child.props[showProp];\n          if (hasNext) {\n            var showInNext = findShownChildInChildrenByKey(nextChildren, key, showProp);\n            if (!showInNext && showInNow) {\n              _this3.keysToLeave.push(key);\n            }\n          } else if (showInNow) {\n            _this3.keysToLeave.push(key);\n          }\n        } else if (!hasNext) {\n          _this3.keysToLeave.push(key);\n        }\n      });\n    }\n  }, {\n    key: 'componentDidUpdate',\n    value: function componentDidUpdate() {\n      var keysToEnter = this.keysToEnter;\n      this.keysToEnter = [];\n      keysToEnter.forEach(this.performEnter);\n      var keysToLeave = this.keysToLeave;\n      this.keysToLeave = [];\n      keysToLeave.forEach(this.performLeave);\n    }\n  }, {\n    key: 'isValidChildByKey',\n    value: function isValidChildByKey(currentChildren, key) {\n      var showProp = this.props.showProp;\n      if (showProp) {\n        return findShownChildInChildrenByKey(currentChildren, key, showProp);\n      }\n      return findChildInChildrenByKey(currentChildren, key);\n    }\n  }, {\n    key: 'stop',\n    value: function stop(key) {\n      delete this.currentlyAnimatingKeys[key];\n      var component = this.childrenRefs[key];\n      if (component) {\n        component.stop();\n      }\n    }\n  }, {\n    key: 'render',\n    value: function render() {\n      var _this4 = this;\n\n      var props = this.props;\n      this.nextProps = props;\n      var stateChildren = this.state.children;\n      var children = null;\n      if (stateChildren) {\n        children = stateChildren.map(function (child) {\n          if (child === null || child === undefined) {\n            return child;\n          }\n          if (!child.key) {\n            throw new Error('must set key for <rc-animate> children');\n          }\n          return React.createElement(\n            AnimateChild,\n            {\n              key: child.key,\n              ref: function ref(node) {\n                _this4.childrenRefs[child.key] = node;\n              },\n              animation: props.animation,\n              transitionName: props.transitionName,\n              transitionEnter: props.transitionEnter,\n              transitionAppear: props.transitionAppear,\n              transitionLeave: props.transitionLeave\n            },\n            child\n          );\n        });\n      }\n      var Component = props.component;\n      if (Component) {\n        var passedProps = props;\n        if (typeof Component === 'string') {\n          passedProps = _extends({\n            className: props.className,\n            style: props.style\n          }, props.componentProps);\n        }\n        return React.createElement(\n          Component,\n          passedProps,\n          children\n        );\n      }\n      return children[0] || null;\n    }\n  }]);\n\n  return Animate;\n}(React.Component);\n\nAnimate.isAnimate = true;\nAnimate.propTypes = {\n  component: PropTypes.any,\n  componentProps: PropTypes.object,\n  animation: PropTypes.object,\n  transitionName: PropTypes.oneOfType([PropTypes.string, PropTypes.object]),\n  transitionEnter: PropTypes.bool,\n  transitionAppear: PropTypes.bool,\n  exclusive: PropTypes.bool,\n  transitionLeave: PropTypes.bool,\n  onEnd: PropTypes.func,\n  onEnter: PropTypes.func,\n  onLeave: PropTypes.func,\n  onAppear: PropTypes.func,\n  showProp: PropTypes.string,\n  children: PropTypes.node\n};\nAnimate.defaultProps = {\n  animation: {},\n  component: 'span',\n  componentProps: {},\n  transitionEnter: true,\n  transitionLeave: true,\n  transitionAppear: false,\n  onEnd: noop,\n  onEnter: noop,\n  onLeave: noop,\n  onAppear: noop\n};\n\nvar _initialiseProps = function _initialiseProps() {\n  var _this5 = this;\n\n  this.performEnter = function (key) {\n    // may already remove by exclusive\n    if (_this5.childrenRefs[key]) {\n      _this5.currentlyAnimatingKeys[key] = true;\n      _this5.childrenRefs[key].componentWillEnter(_this5.handleDoneAdding.bind(_this5, key, 'enter'));\n    }\n  };\n\n  this.performAppear = function (key) {\n    if (_this5.childrenRefs[key]) {\n      _this5.currentlyAnimatingKeys[key] = true;\n      _this5.childrenRefs[key].componentWillAppear(_this5.handleDoneAdding.bind(_this5, key, 'appear'));\n    }\n  };\n\n  this.handleDoneAdding = function (key, type) {\n    var props = _this5.props;\n    delete _this5.currentlyAnimatingKeys[key];\n    // if update on exclusive mode, skip check\n    if (props.exclusive && props !== _this5.nextProps) {\n      return;\n    }\n    var currentChildren = toArrayChildren(getChildrenFromProps(props));\n    if (!_this5.isValidChildByKey(currentChildren, key)) {\n      // exclusive will not need this\n      _this5.performLeave(key);\n    } else if (type === 'appear') {\n      if (animUtil.allowAppearCallback(props)) {\n        props.onAppear(key);\n        props.onEnd(key, true);\n      }\n    } else if (animUtil.allowEnterCallback(props)) {\n      props.onEnter(key);\n      props.onEnd(key, true);\n    }\n  };\n\n  this.performLeave = function (key) {\n    // may already remove by exclusive\n    if (_this5.childrenRefs[key]) {\n      _this5.currentlyAnimatingKeys[key] = true;\n      _this5.childrenRefs[key].componentWillLeave(_this5.handleDoneLeaving.bind(_this5, key));\n    }\n  };\n\n  this.handleDoneLeaving = function (key) {\n    var props = _this5.props;\n    delete _this5.currentlyAnimatingKeys[key];\n    // if update on exclusive mode, skip check\n    if (props.exclusive && props !== _this5.nextProps) {\n      return;\n    }\n    var currentChildren = toArrayChildren(getChildrenFromProps(props));\n    // in case state change is too fast\n    if (_this5.isValidChildByKey(currentChildren, key)) {\n      _this5.performEnter(key);\n    } else {\n      var end = function end() {\n        if (animUtil.allowLeaveCallback(props)) {\n          props.onLeave(key);\n          props.onEnd(key, false);\n        }\n      };\n      if (!isSameChildren(_this5.state.children, currentChildren, props.showProp)) {\n        _this5.setState({\n          children: currentChildren\n        }, end);\n      } else {\n        end();\n      }\n    }\n  };\n};\n\nexport default Animate;"],"sourceRoot":""}