You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 line
5.5 KiB
1 line
5.5 KiB
{"ast":null,"code":"'use strict';\n\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport NativeAnimatedHelper from \"../NativeAnimatedHelper\";\nvar startNativeAnimationNextId = 1;\nvar Animation = function () {\n function Animation() {\n _classCallCheck(this, Animation);\n }\n _createClass(Animation, [{\n key: \"start\",\n value: function start(fromValue, onUpdate, onEnd, previousAnimation, animatedValue) {}\n }, {\n key: \"stop\",\n value: function stop() {\n if (this.__nativeId) {\n NativeAnimatedHelper.API.stopAnimation(this.__nativeId);\n }\n }\n }, {\n key: \"__getNativeAnimationConfig\",\n value: function __getNativeAnimationConfig() {\n throw new Error('This animation type cannot be offloaded to native');\n }\n }, {\n key: \"__debouncedOnEnd\",\n value: function __debouncedOnEnd(result) {\n var onEnd = this.__onEnd;\n this.__onEnd = null;\n onEnd && onEnd(result);\n }\n }, {\n key: \"__startNativeAnimation\",\n value: function __startNativeAnimation(animatedValue) {\n var startNativeAnimationWaitId = startNativeAnimationNextId + \":startAnimation\";\n startNativeAnimationNextId += 1;\n NativeAnimatedHelper.API.setWaitingForIdentifier(startNativeAnimationWaitId);\n try {\n animatedValue.__makeNative();\n this.__nativeId = NativeAnimatedHelper.generateNewAnimationId();\n NativeAnimatedHelper.API.startAnimatingNode(this.__nativeId, animatedValue.__getNativeTag(), this.__getNativeAnimationConfig(), this.__debouncedOnEnd.bind(this));\n } catch (e) {\n throw e;\n } finally {\n NativeAnimatedHelper.API.unsetWaitingForIdentifier(startNativeAnimationWaitId);\n }\n }\n }]);\n return Animation;\n}();\nexport default Animation;","map":{"version":3,"names":["NativeAnimatedHelper","startNativeAnimationNextId","Animation","fromValue","onUpdate","onEnd","previousAnimation","animatedValue","__nativeId","API","stopAnimation","Error","result","__onEnd","startNativeAnimationWaitId","setWaitingForIdentifier","__makeNative","generateNewAnimationId","startAnimatingNode","__getNativeTag","__getNativeAnimationConfig","__debouncedOnEnd","bind","e","unsetWaitingForIdentifier"],"sources":["/Users/thomaschazot/Documents/But2A/LaSuperMeteo/iut-expo-starter/node_modules/react-native-web/dist/vendor/react-native/Animated/animations/Animation.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'use strict';\n\nimport NativeAnimatedHelper from '../NativeAnimatedHelper';\nvar startNativeAnimationNextId = 1; // Important note: start() and stop() will only be called at most once.\n// Once an animation has been stopped or finished its course, it will\n// not be reused.\n\nclass Animation {\n start(fromValue, onUpdate, onEnd, previousAnimation, animatedValue) {}\n\n stop() {\n if (this.__nativeId) {\n NativeAnimatedHelper.API.stopAnimation(this.__nativeId);\n }\n }\n\n __getNativeAnimationConfig() {\n // Subclasses that have corresponding animation implementation done in native\n // should override this method\n throw new Error('This animation type cannot be offloaded to native');\n } // Helper function for subclasses to make sure onEnd is only called once.\n\n\n __debouncedOnEnd(result) {\n var onEnd = this.__onEnd;\n this.__onEnd = null;\n onEnd && onEnd(result);\n }\n\n __startNativeAnimation(animatedValue) {\n var startNativeAnimationWaitId = startNativeAnimationNextId + \":startAnimation\";\n startNativeAnimationNextId += 1;\n NativeAnimatedHelper.API.setWaitingForIdentifier(startNativeAnimationWaitId);\n\n try {\n animatedValue.__makeNative();\n\n this.__nativeId = NativeAnimatedHelper.generateNewAnimationId();\n NativeAnimatedHelper.API.startAnimatingNode(this.__nativeId, animatedValue.__getNativeTag(), this.__getNativeAnimationConfig(), this.__debouncedOnEnd.bind(this));\n } catch (e) {\n throw e;\n } finally {\n NativeAnimatedHelper.API.unsetWaitingForIdentifier(startNativeAnimationWaitId);\n }\n }\n\n}\n\nexport default Animation;"],"mappings":"AASA,YAAY;;AAAC;AAAA;AAEb,OAAOA,oBAAoB;AAC3B,IAAIC,0BAA0B,GAAG,CA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