{"ast":null,"code":"'use strict';\n\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _possibleConstructorReturn from \"@babel/runtime/helpers/possibleConstructorReturn\";\nimport _getPrototypeOf from \"@babel/runtime/helpers/getPrototypeOf\";\nimport _get from \"@babel/runtime/helpers/get\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _superPropGet(t, o, e, r) { var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); return 2 & r && \"function\" == typeof p ? function (t) { return p.apply(e, t); } : p; }\nimport AnimatedValue from \"../nodes/AnimatedValue\";\nimport AnimatedValueXY from \"../nodes/AnimatedValueXY\";\nimport AnimatedInterpolation from \"../nodes/AnimatedInterpolation\";\nimport Easing from \"../../../../exports/Easing\";\nimport Animation from \"./Animation\";\nimport { shouldUseNativeDriver } from \"../NativeAnimatedHelper\";\nimport AnimatedColor from \"../nodes/AnimatedColor\";\nvar _easeInOut;\nfunction easeInOut() {\n  if (!_easeInOut) {\n    _easeInOut = Easing.inOut(Easing.ease);\n  }\n  return _easeInOut;\n}\nvar TimingAnimation = function (_Animation) {\n  function TimingAnimation(config) {\n    var _this;\n    _classCallCheck(this, TimingAnimation);\n    var _config$easing, _config$duration, _config$delay, _config$iterations, _config$isInteraction;\n    _this = _callSuper(this, TimingAnimation);\n    _this._toValue = config.toValue;\n    _this._easing = (_config$easing = config.easing) !== null && _config$easing !== void 0 ? _config$easing : easeInOut();\n    _this._duration = (_config$duration = config.duration) !== null && _config$duration !== void 0 ? _config$duration : 500;\n    _this._delay = (_config$delay = config.delay) !== null && _config$delay !== void 0 ? _config$delay : 0;\n    _this.__iterations = (_config$iterations = config.iterations) !== null && _config$iterations !== void 0 ? _config$iterations : 1;\n    _this._useNativeDriver = shouldUseNativeDriver(config);\n    _this._platformConfig = config.platformConfig;\n    _this.__isInteraction = (_config$isInteraction = config.isInteraction) !== null && _config$isInteraction !== void 0 ? _config$isInteraction : !_this._useNativeDriver;\n    return _this;\n  }\n  _inherits(TimingAnimation, _Animation);\n  return _createClass(TimingAnimation, [{\n    key: \"__getNativeAnimationConfig\",\n    value: function __getNativeAnimationConfig() {\n      var frameDuration = 1000.0 / 60.0;\n      var frames = [];\n      var numFrames = Math.round(this._duration / frameDuration);\n      for (var frame = 0; frame < numFrames; frame++) {\n        frames.push(this._easing(frame / numFrames));\n      }\n      frames.push(this._easing(1));\n      return {\n        type: 'frames',\n        frames: frames,\n        toValue: this._toValue,\n        iterations: this.__iterations,\n        platformConfig: this._platformConfig\n      };\n    }\n  }, {\n    key: \"start\",\n    value: function start(fromValue, onUpdate, onEnd, previousAnimation, animatedValue) {\n      var _this2 = this;\n      this.__active = true;\n      this._fromValue = fromValue;\n      this._onUpdate = onUpdate;\n      this.__onEnd = onEnd;\n      var start = function start() {\n        if (_this2._duration === 0 && !_this2._useNativeDriver) {\n          _this2._onUpdate(_this2._toValue);\n          _this2.__debouncedOnEnd({\n            finished: true\n          });\n        } else {\n          _this2._startTime = Date.now();\n          if (_this2._useNativeDriver) {\n            _this2.__startNativeAnimation(animatedValue);\n          } else {\n            _this2._animationFrame = requestAnimationFrame(_this2.onUpdate.bind(_this2));\n          }\n        }\n      };\n      if (this._delay) {\n        this._timeout = setTimeout(start, this._delay);\n      } else {\n        start();\n      }\n    }\n  }, {\n    key: \"onUpdate\",\n    value: function onUpdate() {\n      var now = Date.now();\n      if (now >= this._startTime + this._duration) {\n        if (this._duration === 0) {\n          this._onUpdate(this._toValue);\n        } else {\n          this._onUpdate(this._fromValue + this._easing(1) * (this._toValue - this._fromValue));\n        }\n        this.__debouncedOnEnd({\n          finished: true\n        });\n        return;\n      }\n      this._onUpdate(this._fromValue + this._easing((now - this._startTime) / this._duration) * (this._toValue - this._fromValue));\n      if (this.__active) {\n        this._animationFrame = requestAnimationFrame(this.onUpdate.bind(this));\n      }\n    }\n  }, {\n    key: \"stop\",\n    value: function stop() {\n      _superPropGet(TimingAnimation, \"stop\", this, 3)([]);\n      this.__active = false;\n      clearTimeout(this._timeout);\n      global.cancelAnimationFrame(this._animationFrame);\n      this.__debouncedOnEnd({\n        finished: false\n      });\n    }\n  }]);\n}(Animation);\nexport default TimingAnimation;","map":{"version":3,"names":["_classCallCheck","_createClass","_possibleConstructorReturn","_getPrototypeOf","_get","_inherits","_callSuper","t","o","e","_isNativeReflectConstruct","Reflect","construct","constructor","apply","Boolean","prototype","valueOf","call","_superPropGet","r","p","AnimatedValue","AnimatedValueXY","AnimatedInterpolation","Easing","Animation","shouldUseNativeDriver","AnimatedColor","_easeInOut","easeInOut","inOut","ease","TimingAnimation","_Animation","config","_this","_config$easing","_config$duration","_config$delay","_config$iterations","_config$isInteraction","_toValue","toValue","_easing","easing","_duration","duration","_delay","delay","__iterations","iterations","_useNativeDriver","_platformConfig","platformConfig","__isInteraction","isInteraction","key","value","__getNativeAnimationConfig","frameDuration","frames","numFrames","Math","round","frame","push","type","start","fromValue","onUpdate","onEnd","previousAnimation","animatedValue","_this2","__active","_fromValue","_onUpdate","__onEnd","__debouncedOnEnd","finished","_startTime","Date","now","__startNativeAnimation","_animationFrame","requestAnimationFrame","bind","_timeout","setTimeout","stop","clearTimeout","global","cancelAnimationFrame"],"sources":["/Users/pmouli/Documents/GitHub.nosync/boots-strapper/mobile/node_modules/react-native-web/dist/vendor/react-native/Animated/animations/TimingAnimation.js"],"sourcesContent":["/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n * @format\n */\n\n'use strict';\n\nimport AnimatedValue from '../nodes/AnimatedValue';\nimport AnimatedValueXY from '../nodes/AnimatedValueXY';\nimport AnimatedInterpolation from '../nodes/AnimatedInterpolation';\nimport Easing from '../../../../exports/Easing';\nimport Animation from './Animation';\nimport { shouldUseNativeDriver } from '../NativeAnimatedHelper';\nimport AnimatedColor from '../nodes/AnimatedColor';\nvar _easeInOut;\nfunction easeInOut() {\n  if (!_easeInOut) {\n    _easeInOut = Easing.inOut(Easing.ease);\n  }\n  return _easeInOut;\n}\nclass TimingAnimation extends Animation {\n  constructor(config) {\n    var _config$easing, _config$duration, _config$delay, _config$iterations, _config$isInteraction;\n    super();\n    this._toValue = config.toValue;\n    this._easing = (_config$easing = config.easing) !== null && _config$easing !== void 0 ? _config$easing : easeInOut();\n    this._duration = (_config$duration = config.duration) !== null && _config$duration !== void 0 ? _config$duration : 500;\n    this._delay = (_config$delay = config.delay) !== null && _config$delay !== void 0 ? _config$delay : 0;\n    this.__iterations = (_config$iterations = config.iterations) !== null && _config$iterations !== void 0 ? _config$iterations : 1;\n    this._useNativeDriver = shouldUseNativeDriver(config);\n    this._platformConfig = config.platformConfig;\n    this.__isInteraction = (_config$isInteraction = config.isInteraction) !== null && _config$isInteraction !== void 0 ? _config$isInteraction : !this._useNativeDriver;\n  }\n  __getNativeAnimationConfig() {\n    var frameDuration = 1000.0 / 60.0;\n    var frames = [];\n    var numFrames = Math.round(this._duration / frameDuration);\n    for (var frame = 0; frame < numFrames; frame++) {\n      frames.push(this._easing(frame / numFrames));\n    }\n    frames.push(this._easing(1));\n    return {\n      type: 'frames',\n      frames,\n      toValue: this._toValue,\n      iterations: this.__iterations,\n      platformConfig: this._platformConfig\n    };\n  }\n  start(fromValue, onUpdate, onEnd, previousAnimation, animatedValue) {\n    this.__active = true;\n    this._fromValue = fromValue;\n    this._onUpdate = onUpdate;\n    this.__onEnd = onEnd;\n    var start = () => {\n      // Animations that sometimes have 0 duration and sometimes do not\n      // still need to use the native driver when duration is 0 so as to\n      // not cause intermixed JS and native animations.\n      if (this._duration === 0 && !this._useNativeDriver) {\n        this._onUpdate(this._toValue);\n        this.__debouncedOnEnd({\n          finished: true\n        });\n      } else {\n        this._startTime = Date.now();\n        if (this._useNativeDriver) {\n          this.__startNativeAnimation(animatedValue);\n        } else {\n          this._animationFrame = requestAnimationFrame(\n          // $FlowFixMe[method-unbinding] added when improving typing for this parameters\n          this.onUpdate.bind(this));\n        }\n      }\n    };\n    if (this._delay) {\n      this._timeout = setTimeout(start, this._delay);\n    } else {\n      start();\n    }\n  }\n  onUpdate() {\n    var now = Date.now();\n    if (now >= this._startTime + this._duration) {\n      if (this._duration === 0) {\n        this._onUpdate(this._toValue);\n      } else {\n        this._onUpdate(this._fromValue + this._easing(1) * (this._toValue - this._fromValue));\n      }\n      this.__debouncedOnEnd({\n        finished: true\n      });\n      return;\n    }\n    this._onUpdate(this._fromValue + this._easing((now - this._startTime) / this._duration) * (this._toValue - this._fromValue));\n    if (this.__active) {\n      // $FlowFixMe[method-unbinding] added when improving typing for this parameters\n      this._animationFrame = requestAnimationFrame(this.onUpdate.bind(this));\n    }\n  }\n  stop() {\n    super.stop();\n    this.__active = false;\n    clearTimeout(this._timeout);\n    global.cancelAnimationFrame(this._animationFrame);\n    this.__debouncedOnEnd({\n      finished: false\n    });\n  }\n}\nexport default TimingAnimation;"],"mappings":"AAUA,YAAY;;AAAC,OAAAA,eAAA;AAAA,OAAAC,YAAA;AAAA,OAAAC,0BAAA;AAAA,OAAAC,eAAA;AAAA,OAAAC,IAAA;AAAA,OAAAC,SAAA;AAAA,SAAAC,WAAAC,CAAA,EAAAC,CAAA,EAAAC,CAAA,WAAAD,CAAA,GAAAL,eAAA,CAAAK,CAAA,GAAAN,0BAAA,CAAAK,CAAA,EAAAG,yBAAA,KAAAC,OAAA,CAAAC,SAAA,CAAAJ,CAAA,EAAAC,CAAA,QAAAN,eAAA,CAAAI,CAAA,EAAAM,WAAA,IAAAL,CAAA,CAAAM,KAAA,CAAAP,CAAA,EA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