@tamagui/react-native-web-lite 3.0.0-beta.669.1 → 3.0.0-beta.728.1

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.
Files changed (178) hide show
  1. package/dist/cjs/AccessibilityInfo/index.cjs +0 -1
  2. package/dist/cjs/ActivityIndicator/index.cjs +0 -1
  3. package/dist/cjs/Alert/index.cjs +0 -1
  4. package/dist/cjs/AppRegistry/AppContainer.cjs +0 -1
  5. package/dist/cjs/AppRegistry/index.cjs +0 -1
  6. package/dist/cjs/AppRegistry/renderApplication.cjs +0 -1
  7. package/dist/cjs/AppState/index.cjs +0 -1
  8. package/dist/cjs/Appearance/index.cjs +0 -1
  9. package/dist/cjs/BackHandler/index.cjs +0 -1
  10. package/dist/cjs/Clipboard/index.cjs +0 -1
  11. package/dist/cjs/DeviceEmitter.cjs +0 -1
  12. package/dist/cjs/DeviceInfo/index.cjs +0 -1
  13. package/dist/cjs/Dimensions/index.cjs +0 -1
  14. package/dist/cjs/FlatList.cjs +0 -1
  15. package/dist/cjs/I18nManager/index.cjs +0 -1
  16. package/dist/cjs/Image/index.cjs +0 -1
  17. package/dist/cjs/Image/types.cjs +0 -1
  18. package/dist/cjs/ImageBackground/index.cjs +0 -1
  19. package/dist/cjs/InteractionManager/TaskQueue.cjs +0 -1
  20. package/dist/cjs/InteractionManager/index.cjs +0 -1
  21. package/dist/cjs/Keyboard/index.cjs +0 -1
  22. package/dist/cjs/KeyboardAvoidingView/index.cjs +0 -1
  23. package/dist/cjs/Libraries/Pressability/Pressability.cjs +0 -1
  24. package/dist/cjs/Libraries/Pressability/usePressability.cjs +0 -1
  25. package/dist/cjs/Linking/index.cjs +0 -1
  26. package/dist/cjs/LogBox/index.cjs +0 -1
  27. package/dist/cjs/Modal/ModalAnimation.cjs +0 -1
  28. package/dist/cjs/Modal/ModalContent.cjs +0 -1
  29. package/dist/cjs/Modal/ModalPortal.cjs +0 -1
  30. package/dist/cjs/Modal/index.cjs +0 -1
  31. package/dist/cjs/NativeModules/index.cjs +0 -1
  32. package/dist/cjs/PanResponder/index.cjs +0 -1
  33. package/dist/cjs/PixelRatio/index.cjs +0 -1
  34. package/dist/cjs/Pressable/index.cjs +0 -1
  35. package/dist/cjs/RefreshControl/index.cjs +0 -1
  36. package/dist/cjs/SafeAreaView/index.cjs +0 -1
  37. package/dist/cjs/ScrollView/WebScrollView.cjs +0 -1
  38. package/dist/cjs/ScrollView/index.cjs +0 -1
  39. package/dist/cjs/SectionList.cjs +0 -1
  40. package/dist/cjs/Share/index.cjs +0 -1
  41. package/dist/cjs/StatusBar/index.cjs +0 -1
  42. package/dist/cjs/Text/index.cjs +0 -1
  43. package/dist/cjs/Text/types.cjs +0 -1
  44. package/dist/cjs/TextInput/index.cjs +0 -1
  45. package/dist/cjs/TextInput/types.cjs +0 -1
  46. package/dist/cjs/TouchableNativeFeedback.cjs +0 -1
  47. package/dist/cjs/TouchableOpacity.cjs +0 -1
  48. package/dist/cjs/TouchableWithoutFeedback.cjs +0 -1
  49. package/dist/cjs/UnimplementedView.cjs +0 -1
  50. package/dist/cjs/Vibration/index.cjs +0 -1
  51. package/dist/cjs/View/index.cjs +0 -1
  52. package/dist/cjs/View/types.cjs +0 -1
  53. package/dist/cjs/VirtualizedList.cjs +0 -1
  54. package/dist/cjs/codegenNativeCommands.cjs +0 -1
  55. package/dist/cjs/codegenNativeComponent.cjs +0 -1
  56. package/dist/cjs/createElement/index.cjs +0 -1
  57. package/dist/cjs/createReactDOMStyle.cjs +0 -1
  58. package/dist/cjs/index.cjs +0 -1
  59. package/dist/cjs/modules/requestIdleCallback.cjs +0 -1
  60. package/dist/cjs/preprocess.cjs +0 -1
  61. package/dist/cjs/render/index.cjs +0 -1
  62. package/dist/cjs/styleTypes.cjs +0 -1
  63. package/dist/cjs/types.cjs +0 -1
  64. package/dist/cjs/useColorScheme/index.cjs +0 -1
  65. package/dist/cjs/useLocaleContext/index.cjs +0 -1
  66. package/dist/cjs/useWindowDimensions/index.cjs +0 -1
  67. package/dist/cjs/vendor/react-native/Animated/Animated.cjs +0 -1
  68. package/dist/cjs/vendor/react-native/Animated/AnimatedEvent.cjs +0 -1
  69. package/dist/cjs/vendor/react-native/Animated/AnimatedImplementation.cjs +0 -1
  70. package/dist/cjs/vendor/react-native/Animated/AnimatedMock.cjs +0 -1
  71. package/dist/cjs/vendor/react-native/Animated/AnimatedPlatformConfig.cjs +0 -1
  72. package/dist/cjs/vendor/react-native/Animated/Easing.cjs +0 -1
  73. package/dist/cjs/vendor/react-native/Animated/NativeAnimatedHelper.cjs +0 -1
  74. package/dist/cjs/vendor/react-native/Animated/NativeAnimatedModule.cjs +0 -1
  75. package/dist/cjs/vendor/react-native/Animated/NativeAnimatedTurboModule.cjs +0 -1
  76. package/dist/cjs/vendor/react-native/Animated/SpringConfig.cjs +0 -1
  77. package/dist/cjs/vendor/react-native/Animated/animations/Animation.cjs +0 -1
  78. package/dist/cjs/vendor/react-native/Animated/animations/DecayAnimation.cjs +0 -1
  79. package/dist/cjs/vendor/react-native/Animated/animations/SpringAnimation.cjs +0 -1
  80. package/dist/cjs/vendor/react-native/Animated/animations/TimingAnimation.cjs +0 -1
  81. package/dist/cjs/vendor/react-native/Animated/bezier.cjs +0 -1
  82. package/dist/cjs/vendor/react-native/Animated/components/AnimatedFlatList.cjs +0 -1
  83. package/dist/cjs/vendor/react-native/Animated/components/AnimatedImage.cjs +0 -1
  84. package/dist/cjs/vendor/react-native/Animated/components/AnimatedScrollView.cjs +0 -1
  85. package/dist/cjs/vendor/react-native/Animated/components/AnimatedSectionList.cjs +0 -1
  86. package/dist/cjs/vendor/react-native/Animated/components/AnimatedText.cjs +0 -1
  87. package/dist/cjs/vendor/react-native/Animated/components/AnimatedView.cjs +0 -1
  88. package/dist/cjs/vendor/react-native/Animated/createAnimatedComponent.cjs +0 -1
  89. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedAddition.cjs +0 -1
  90. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedColor.cjs +0 -1
  91. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedDiffClamp.cjs +0 -1
  92. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedDivision.cjs +0 -1
  93. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedInterpolation.cjs +0 -1
  94. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedModulo.cjs +0 -1
  95. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedMultiplication.cjs +0 -1
  96. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedNode.cjs +0 -1
  97. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedProps.cjs +0 -1
  98. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedStyle.cjs +0 -1
  99. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedSubtraction.cjs +0 -1
  100. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedTracking.cjs +0 -1
  101. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedTransform.cjs +0 -1
  102. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedValue.cjs +0 -1
  103. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedValueXY.cjs +0 -1
  104. package/dist/cjs/vendor/react-native/Animated/nodes/AnimatedWithChildren.cjs +0 -1
  105. package/dist/cjs/vendor/react-native/Animated/useAnimatedProps.cjs +0 -1
  106. package/dist/cjs/vendor/react-native/Batchinator/index.cjs +0 -1
  107. package/dist/cjs/vendor/react-native/EventEmitter/NativeEventEmitter.cjs +0 -1
  108. package/dist/cjs/vendor/react-native/EventEmitter/RCTDeviceEventEmitter.cjs +0 -1
  109. package/dist/cjs/vendor/react-native/FeatureFlags.cjs +0 -1
  110. package/dist/cjs/vendor/react-native/FillRateHelper/index.cjs +0 -1
  111. package/dist/cjs/vendor/react-native/FlatList/index.cjs +0 -1
  112. package/dist/cjs/vendor/react-native/JSEventLoopWatchdog/index.cjs +0 -1
  113. package/dist/cjs/vendor/react-native/LayoutAnimation/index.cjs +0 -1
  114. package/dist/cjs/vendor/react-native/PanResponder/index.cjs +0 -1
  115. package/dist/cjs/vendor/react-native/PooledClass/index.cjs +0 -1
  116. package/dist/cjs/vendor/react-native/ReactNative/ReactNativeFeatureFlags.cjs +0 -1
  117. package/dist/cjs/vendor/react-native/SectionList/index.cjs +0 -1
  118. package/dist/cjs/vendor/react-native/StaticContainer/index.cjs +0 -1
  119. package/dist/cjs/vendor/react-native/StaticRenderer/index.cjs +0 -1
  120. package/dist/cjs/vendor/react-native/TouchHistoryMath/index.cjs +0 -1
  121. package/dist/cjs/vendor/react-native/TurboModule/RCTExport.cjs +0 -1
  122. package/dist/cjs/vendor/react-native/TurboModule/TurboModuleRegistry.cjs +0 -1
  123. package/dist/cjs/vendor/react-native/Types/CoreEventTypes.cjs +0 -1
  124. package/dist/cjs/vendor/react-native/Utilities/Platform.cjs +0 -1
  125. package/dist/cjs/vendor/react-native/Utilities/clamp.cjs +0 -1
  126. package/dist/cjs/vendor/react-native/Utilities/setAndForwardRef.cjs +0 -1
  127. package/dist/cjs/vendor/react-native/Utilities/useMergeRefs.cjs +0 -1
  128. package/dist/cjs/vendor/react-native/Utilities/useRefEffect.cjs +0 -1
  129. package/dist/cjs/vendor/react-native/ViewabilityHelper/index.cjs +0 -1
  130. package/dist/cjs/vendor/react-native/ViewabilityHelper.cjs +0 -1
  131. package/dist/cjs/vendor/react-native/VirtualizeUtils/index.cjs +0 -1
  132. package/dist/cjs/vendor/react-native/VirtualizedList/CellRenderMask.cjs +0 -1
  133. package/dist/cjs/vendor/react-native/VirtualizedList/ChildListCollection.cjs +0 -1
  134. package/dist/cjs/vendor/react-native/VirtualizedList/StateSafePureComponent.cjs +0 -1
  135. package/dist/cjs/vendor/react-native/VirtualizedList/VirtualizedListCellRenderer.cjs +0 -1
  136. package/dist/cjs/vendor/react-native/VirtualizedList/VirtualizedListContext.cjs +0 -1
  137. package/dist/cjs/vendor/react-native/VirtualizedList/VirtualizedListProps.cjs +0 -1
  138. package/dist/cjs/vendor/react-native/VirtualizedList/index.cjs +0 -1
  139. package/dist/cjs/vendor/react-native/VirtualizedSectionList/index.cjs +0 -1
  140. package/dist/cjs/vendor/react-native/deepDiffer/index.cjs +0 -1
  141. package/dist/cjs/vendor/react-native/emitter/EventEmitter.cjs +0 -1
  142. package/dist/cjs/vendor/react-native/emitter/EventSubscription.cjs +0 -1
  143. package/dist/cjs/vendor/react-native/emitter/_EmitterSubscription.cjs +0 -1
  144. package/dist/cjs/vendor/react-native/emitter/_EventEmitter.cjs +0 -1
  145. package/dist/cjs/vendor/react-native/emitter/_EventSubscription.cjs +0 -1
  146. package/dist/cjs/vendor/react-native/emitter/_EventSubscriptionVendor.cjs +0 -1
  147. package/dist/cjs/vendor/react-native/infoLog/index.cjs +0 -1
  148. package/dist/cjs/vendor/react-native/useRefEffect.cjs +0 -1
  149. package/dist/cjs/vendor/react-native/vendor/emitter/EventEmitter.cjs +0 -1
  150. package/dist/cjs/without-animated.cjs +0 -1
  151. package/dist/esm/AppRegistry/index.mjs.map +1 -1
  152. package/dist/esm/AppState/index.mjs.map +1 -1
  153. package/dist/esm/Dimensions/index.mjs.map +1 -1
  154. package/dist/esm/FlatList.mjs.map +1 -1
  155. package/dist/esm/Image/index.mjs.map +1 -1
  156. package/dist/esm/InteractionManager/TaskQueue.mjs.map +1 -1
  157. package/dist/esm/Linking/index.mjs.map +1 -1
  158. package/dist/esm/PixelRatio/index.mjs.map +1 -1
  159. package/dist/esm/SafeAreaView/index.mjs.map +1 -1
  160. package/dist/esm/ScrollView/WebScrollView.mjs.map +1 -1
  161. package/dist/esm/View/index.mjs.map +1 -1
  162. package/dist/esm/vendor/react-native/Animated/AnimatedEvent.mjs.map +1 -1
  163. package/dist/esm/vendor/react-native/Animated/AnimatedImplementation.mjs.map +1 -1
  164. package/dist/esm/vendor/react-native/Animated/NativeAnimatedHelper.mjs.map +1 -1
  165. package/dist/esm/vendor/react-native/Animated/nodes/AnimatedColor.mjs.map +1 -1
  166. package/dist/esm/vendor/react-native/Animated/nodes/AnimatedInterpolation.mjs.map +1 -1
  167. package/dist/esm/vendor/react-native/Animated/nodes/AnimatedNode.mjs.map +1 -1
  168. package/dist/esm/vendor/react-native/Animated/nodes/AnimatedValue.mjs.map +1 -1
  169. package/dist/esm/vendor/react-native/Animated/nodes/AnimatedValueXY.mjs.map +1 -1
  170. package/dist/esm/vendor/react-native/FlatList/index.mjs.map +1 -1
  171. package/dist/esm/vendor/react-native/VirtualizeUtils/index.mjs.map +1 -1
  172. package/dist/esm/vendor/react-native/VirtualizedList/CellRenderMask.mjs.map +1 -1
  173. package/dist/esm/vendor/react-native/VirtualizedList/index.mjs.map +1 -1
  174. package/dist/esm/vendor/react-native/VirtualizedSectionList/index.mjs.map +1 -1
  175. package/dist/esm/vendor/react-native/emitter/_EventEmitter.mjs.map +1 -1
  176. package/dist/esm/vendor/react-native/emitter/_EventSubscriptionVendor.mjs.map +1 -1
  177. package/dist/esm/without-animated.mjs.map +1 -1
  178. package/package.json +9 -9
@@ -1 +1 @@
1
- {"version":3,"file":"TaskQueue.js","names":[],"sources":["esm/InteractionManager/TaskQueue.js"],"sourcesContent":["import { invariant } from \"@tamagui/react-native-web-internals\";\nclass TaskQueue {\n _queueStack;\n _onMoreTasks;\n constructor({ onMoreTasks }) {\n this._onMoreTasks = onMoreTasks;\n this._queueStack = [{ tasks: [], popable: true }];\n }\n enqueue(task) {\n this._getCurrentQueue().push(task);\n }\n enqueueTasks(tasks) {\n tasks.forEach((task) => this.enqueue(task));\n }\n cancelTasks(tasksToCancel) {\n this._queueStack = this._queueStack.map((queue) => ({\n ...queue,\n tasks: queue.tasks.filter((task) => !tasksToCancel.includes(task))\n })).filter((queue, idx) => queue.tasks.length > 0 || idx === 0);\n }\n hasTasksToProcess() {\n return this._getCurrentQueue().length > 0;\n }\n /**\n * Executes the next task in the queue.\n */\n processNext() {\n const queue = this._getCurrentQueue();\n if (queue.length) {\n const task = queue.shift();\n try {\n if (typeof task === \"object\" && \"gen\" in task) {\n this._genPromise(task);\n } else if (typeof task === \"object\" && \"run\" in task) {\n task.run();\n } else {\n invariant(\n typeof task === \"function\",\n \"Expected Function, SimpleTask, or PromiseTask, but got:\\n\" + JSON.stringify(task, null, 2)\n );\n task();\n }\n } catch (e) {\n if (e instanceof Error) {\n e.message = \"TaskQueue: Error with task \" + (task?.name || \"\") + \": \" + e.message;\n }\n throw e;\n }\n }\n }\n _getCurrentQueue() {\n const stackIdx = this._queueStack.length - 1;\n const queue = this._queueStack[stackIdx];\n if (queue.popable && queue.tasks.length === 0 && stackIdx > 0) {\n this._queueStack.pop();\n return this._getCurrentQueue();\n } else {\n return queue.tasks;\n }\n }\n _genPromise(task) {\n const length = this._queueStack.push({ tasks: [], popable: false });\n const stackIdx = length - 1;\n const stackItem = this._queueStack[stackIdx];\n task.gen().then(() => {\n stackItem.popable = true;\n if (this.hasTasksToProcess()) {\n this._onMoreTasks();\n }\n }).catch((ex) => {\n setTimeout(() => {\n if (ex instanceof Error) {\n ex.message = `TaskQueue: Error resolving Promise in task ${task.name}: ${ex.message}`;\n }\n throw ex;\n }, 0);\n });\n }\n}\nexport {\n TaskQueue\n};\n//# sourceMappingURL=TaskQueue.js.map\n"],"mappings":";;;AACA,IAAM,YAAN,MAAgB;CACd;CACA;CACA,YAAY,EAAE,eAAe;EAC3B,KAAK,eAAe;EACpB,KAAK,cAAc,CAAC;GAAE,OAAO,CAAC;GAAG,SAAS;EAAK,CAAC;CAClD;CACA,QAAQ,MAAM;EACZ,KAAK,iBAAiB,EAAE,KAAK,IAAI;CACnC;CACA,aAAa,OAAO;EAClB,MAAM,SAAS,SAAS,KAAK,QAAQ,IAAI,CAAC;CAC5C;CACA,YAAY,eAAe;EACzB,KAAK,cAAc,KAAK,YAAY,KAAK,WAAW;GAClD,GAAG;GACH,OAAO,MAAM,MAAM,QAAQ,SAAS,CAAC,cAAc,SAAS,IAAI,CAAC;EACnE,EAAE,EAAE,QAAQ,OAAO,QAAQ,MAA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H;AACF"}
1
+ {"version":3,"file":"TaskQueue.js","names":[],"sources":["esm/InteractionManager/TaskQueue.js"],"sourcesContent":["import { invariant } from \"@tamagui/react-native-web-internals\";\nclass TaskQueue {\n _queueStack;\n _onMoreTasks;\n constructor({ onMoreTasks }) {\n this._onMoreTasks = onMoreTasks;\n this._queueStack = [{ tasks: [], popable: true }];\n }\n enqueue(task) {\n this._getCurrentQueue().push(task);\n }\n enqueueTasks(tasks) {\n tasks.forEach((task) => this.enqueue(task));\n }\n cancelTasks(tasksToCancel) {\n this._queueStack = this._queueStack.map((queue) => ({\n ...queue,\n tasks: queue.tasks.filter((task) => !tasksToCancel.includes(task))\n })).filter((queue, idx) => queue.tasks.length > 0 || idx === 0);\n }\n hasTasksToProcess() {\n return this._getCurrentQueue().length > 0;\n }\n /**\n * Executes the next task in the queue.\n */\n processNext() {\n const queue = this._getCurrentQueue();\n if (queue.length) {\n const task = queue.shift();\n try {\n if (typeof task === \"object\" && \"gen\" in task) {\n this._genPromise(task);\n } else if (typeof task === \"object\" && \"run\" in task) {\n task.run();\n } else {\n invariant(\n typeof task === \"function\",\n \"Expected Function, SimpleTask, or PromiseTask, but got:\\n\" + JSON.stringify(task, null, 2)\n );\n task();\n }\n } catch (e) {\n if (e instanceof Error) {\n e.message = \"TaskQueue: Error with task \" + (task?.name || \"\") + \": \" + e.message;\n }\n throw e;\n }\n }\n }\n _getCurrentQueue() {\n const stackIdx = this._queueStack.length - 1;\n const queue = this._queueStack[stackIdx];\n if (queue.popable && queue.tasks.length === 0 && stackIdx > 0) {\n this._queueStack.pop();\n return this._getCurrentQueue();\n } else {\n return queue.tasks;\n }\n }\n _genPromise(task) {\n const length = this._queueStack.push({ tasks: [], popable: false });\n const stackIdx = length - 1;\n const stackItem = this._queueStack[stackIdx];\n task.gen().then(() => {\n stackItem.popable = true;\n if (this.hasTasksToProcess()) {\n this._onMoreTasks();\n }\n }).catch((ex) => {\n setTimeout(() => {\n if (ex instanceof Error) {\n ex.message = `TaskQueue: Error resolving Promise in task ${task.name}: ${ex.message}`;\n }\n throw ex;\n }, 0);\n });\n }\n}\nexport {\n TaskQueue\n};\n//# sourceMappingURL=TaskQueue.js.map\n"],"mappings":";;;AACA,IAAM,YAAN,MAAgB;CACd;CACA;CACA,YAAY,EAAE,eAAe;EAC3B,KAAK,eAAe;EACpB,KAAK,cAAc,CAAC;GAAE,OAAO,CAAC;GAAG,SAAS;EAAK,CAAC;CAClD;CACA,QAAQ,MAAM;EACZ,KAAK,iBAAiB,CAAC,CAAC,KAAK,IAAI;CACnC;CACA,aAAa,OAAO;EAClB,MAAM,SAAS,SAAS,KAAK,QAAQ,IAAI,CAAC;CAC5C;CACA,YAAY,eAAe;EACzB,KAAK,cAAc,KAAK,YAAY,KAAK,WAAW;GAClD,GAAG;GACH,OAAO,MAAM,MAAM,QAAQ,SAAS,CAAC,cAAc,SAAS,IAAI,CAAC;EACnE,EAAE,CAAC,CAAC,QAAQ,OAAO,QAAQ,MAAM,MAAM,SAAS,KAAK,QAAQ,CAAC;CAChE;CACA,oBAAoB;EAClB,OAAO,KAAK,iBAAiB,CAAC,CAAC,SAAS;CAC1C;;;;CAIA,cAAc;EACZ,MAAM,QAAQ,KAAK,iBAAiB;EACpC,IAAI,MAAM,QAAQ;GAChB,MAAM,OAAO,MAAM,MAAM;GACzB,IAAI;IACF,IAAI,OAAO,SAAS,YAAY,SAAS,MAAM;KAC7C,KAAK,YAAY,IAAI;IACvB,OAAO,IAAI,OAAO,SAAS,YAAY,SAAS,MAAM;KACpD,KAAK,IAAI;IACX,OAAO;KACL,UACE,OAAO,SAAS,YAChB,8DAA8D,KAAK,UAAU,MAAM,MAAM,CAAC,CAC5F;KACA,KAAK;IACP;GACF,SAAS,GAAG;IACV,IAAI,aAAa,OAAO;KACtB,EAAE,UAAU,iCAAiC,MAAM,QAAQ,MAAM,OAAO,EAAE;IAC5E;IACA,MAAM;GACR;EACF;CACF;CACA,mBAAmB;EACjB,MAAM,WAAW,KAAK,YAAY,SAAS;EAC3C,MAAM,QAAQ,KAAK,YAAY;EAC/B,IAAI,MAAM,WAAW,MAAM,MAAM,WAAW,KAAK,WAAW,GAAG;GAC7D,KAAK,YAAY,IAAI;GACrB,OAAO,KAAK,iBAAiB;EAC/B,OAAO;GACL,OAAO,MAAM;EACf;CACF;CACA,YAAY,MAAM;EAChB,MAAM,SAAS,KAAK,YAAY,KAAK;GAAE,OAAO,CAAC;GAAG,SAAS;EAAM,CAAC;EAClE,MAAM,WAAW,SAAS;EAC1B,MAAM,YAAY,KAAK,YAAY;EACnC,KAAK,IAAI,CAAC,CAAC,WAAW;GACpB,UAAU,UAAU;GACpB,IAAI,KAAK,kBAAkB,GAAG;IAC5B,KAAK,aAAa;GACpB;EACF,CAAC,CAAC,CAAC,OAAO,OAAO;GACf,iBAAiB;IACf,IAAI,cAAc,OAAO;KACvB,GAAG,UAAU,8CAA8C,KAAK,KAAK,IAAI,GAAG;IAC9E;IACA,MAAM;GACR,GAAG,CAAC;EACN,CAAC;CACH;AACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["esm/Linking/index.js"],"sourcesContent":["import { canUseDOM, invariant } from \"@tamagui/react-native-web-internals\";\nconst initialURL = canUseDOM ? window.location.href : \"\";\nclass Linking {\n /**\n * An object mapping of event name\n * and all the callbacks subscribing to it\n */\n _eventCallbacks = {};\n _dispatchEvent(event, ...data) {\n const listeners = this._eventCallbacks[event];\n if (listeners != null && Array.isArray(listeners)) {\n listeners.map((listener) => {\n listener(...data);\n });\n }\n }\n /**\n * Adds a event listener for the specified event. The callback will be called when the\n * said event is dispatched.\n */\n addEventListener = (event, callback) => {\n if (!this._eventCallbacks[event]) {\n this._eventCallbacks[event] = [callback];\n return;\n }\n this._eventCallbacks[event].push(callback);\n };\n /**\n * Removes a previously added event listener for the specified event. The callback must\n * be the same object as the one passed to `addEventListener`.\n */\n removeEventListener = (event, callback) => {\n const callbacks = this._eventCallbacks[event];\n const filteredCallbacks = callbacks.filter(\n (c) => c.toString() !== callback.toString()\n );\n this._eventCallbacks[event] = filteredCallbacks;\n };\n canOpenURL() {\n return Promise.resolve(true);\n }\n getInitialURL() {\n return Promise.resolve(initialURL);\n }\n /**\n * Try to open the given url in a secure fashion. The method returns a Promise object.\n * If a target is passed (including undefined) that target will be used, otherwise '_blank'.\n * If the url opens, the promise is resolved. If not, the promise is rejected.\n * Dispatches the `onOpen` event if `url` is opened successfully.\n */\n openURL(url, target) {\n if (arguments.length === 1) {\n target = \"_blank\";\n }\n try {\n open(url, target);\n this._dispatchEvent(\"onOpen\", url);\n return Promise.resolve();\n } catch (e) {\n return Promise.reject(e);\n }\n }\n _validateURL(url) {\n invariant(typeof url === \"string\", \"Invalid URL: should be a string. Was: \" + url);\n invariant(url, \"Invalid URL: cannot be empty\");\n }\n}\nconst open = (url, target) => {\n if (canUseDOM) {\n const urlToOpen = new URL(url, window.location).toString();\n if (urlToOpen.indexOf(\"tel:\") === 0) {\n window.location = urlToOpen;\n } else {\n window.open(urlToOpen, target, \"noopener\");\n }\n }\n};\nconst LinkingInstance = new Linking();\nexport {\n LinkingInstance as Linking\n};\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;AACA,MAAM,aAAa,YAAY,OAAO,SAAS,OAAO;AACtD,IAAM,UAAN,MAAc;;;;;CAKZ,kBAAkB,CAAC;CACnB,eAAe,OAAO,GAAG,MAAM;EAC7B,MAAM,YAAY,KAAK,gBAAgB;EACvC,IAAI,aAAa,QAAQ,MAAM,QAAQ,SAAS,GAAG;GACjD,UAAU,KAAK,aAAa;IAC1B,SAAS,GAAG,IAAI;GAClB,CAAC;EACH;CACF;;;;;CAKA,oBAAoB,OAAO,aAAa;EACtC,IAAI,CAAC,KAAK,gBAAgB,QAAQ;GAChC,KAAK,gBAAgB,SAAS,CAAC,QAAQ;GACvC;EACF;EACA,KAAK,gBAAgB,OAAO,KAAK,QAAQ;CAC3C;;;;;CAKA,uBAAuB,OAAO,aAAa;EACzC,MAAM,YAAY,KAAK,gBAAgB;EACvC,MAAM,oBAAoB,UAAU,QACjC,MAAM,EAAE,SAAS,MAAM,SAAS,SAAS,CAC5C;EACA,KAAK,gBAAgB,SAAS;CAChC;CACA,aAAa;EACX,OAAO,QAAQ,QAAQ,IAAI;CAC7B;CACA,gBAAgB;EACd,OAAO,QAAQ,QAAQ,UAAU;CACnC;;;;;;;CAOA,QAAQ,KAAK,QAAQ;EACnB,IAAI,UAAU,WAAW,GAAG;GAC1B,SAAS;EACX;EACA,IAAI;GACF,KAAK,KAAK,MAAM;GAChB,KAAK,eAAe,UAAU,GAAG;GACjC,OAAO,QAAQ,QAAQ;EACzB,SAAS,GAAG;GACV,OAAO,QAAQ,OAAO,CAAC;EACzB;CACF;CACA,aAAa,KAAK;EAChB,UAAU,OAAO,QAAQ,UAAU,2CAA2C,GAAG;EACjF,UAAU,KAAK,8BAA8B;CAC/C;AACF;AACA,MAAM,QAAQ,KAAK,WAAW;CAC5B,IAAI,WAAW;EACb,MAAM,YAAY,IAAI,IAAI,KAAK,OAAO,QAAQ,EAAE,SAAS;EACzD,IAAI,UAAU,QAAQ,MAAM,MAAM,GAAG;GACnC,OAAO,WAAW;EACpB,OAAO;GACL,OAAO,KAAK,WAAW,QAAQ,UAAU;EAC3C;CACF;AACF;AACA,MAAM,kBAAkB,IAAI,QAAQ"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["esm/Linking/index.js"],"sourcesContent":["import { canUseDOM, invariant } from \"@tamagui/react-native-web-internals\";\nconst initialURL = canUseDOM ? window.location.href : \"\";\nclass Linking {\n /**\n * An object mapping of event name\n * and all the callbacks subscribing to it\n */\n _eventCallbacks = {};\n _dispatchEvent(event, ...data) {\n const listeners = this._eventCallbacks[event];\n if (listeners != null && Array.isArray(listeners)) {\n listeners.map((listener) => {\n listener(...data);\n });\n }\n }\n /**\n * Adds a event listener for the specified event. The callback will be called when the\n * said event is dispatched.\n */\n addEventListener = (event, callback) => {\n if (!this._eventCallbacks[event]) {\n this._eventCallbacks[event] = [callback];\n return;\n }\n this._eventCallbacks[event].push(callback);\n };\n /**\n * Removes a previously added event listener for the specified event. The callback must\n * be the same object as the one passed to `addEventListener`.\n */\n removeEventListener = (event, callback) => {\n const callbacks = this._eventCallbacks[event];\n const filteredCallbacks = callbacks.filter(\n (c) => c.toString() !== callback.toString()\n );\n this._eventCallbacks[event] = filteredCallbacks;\n };\n canOpenURL() {\n return Promise.resolve(true);\n }\n getInitialURL() {\n return Promise.resolve(initialURL);\n }\n /**\n * Try to open the given url in a secure fashion. The method returns a Promise object.\n * If a target is passed (including undefined) that target will be used, otherwise '_blank'.\n * If the url opens, the promise is resolved. If not, the promise is rejected.\n * Dispatches the `onOpen` event if `url` is opened successfully.\n */\n openURL(url, target) {\n if (arguments.length === 1) {\n target = \"_blank\";\n }\n try {\n open(url, target);\n this._dispatchEvent(\"onOpen\", url);\n return Promise.resolve();\n } catch (e) {\n return Promise.reject(e);\n }\n }\n _validateURL(url) {\n invariant(typeof url === \"string\", \"Invalid URL: should be a string. Was: \" + url);\n invariant(url, \"Invalid URL: cannot be empty\");\n }\n}\nconst open = (url, target) => {\n if (canUseDOM) {\n const urlToOpen = new URL(url, window.location).toString();\n if (urlToOpen.indexOf(\"tel:\") === 0) {\n window.location = urlToOpen;\n } else {\n window.open(urlToOpen, target, \"noopener\");\n }\n }\n};\nconst LinkingInstance = new Linking();\nexport {\n LinkingInstance as Linking\n};\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;AACA,MAAM,aAAa,YAAY,OAAO,SAAS,OAAO;AACtD,IAAM,UAAN,MAAc;;;;;CAKZ,kBAAkB,CAAC;CACnB,eAAe,OAAO,GAAG,MAAM;EAC7B,MAAM,YAAY,KAAK,gBAAgB;EACvC,IAAI,aAAa,QAAQ,MAAM,QAAQ,SAAS,GAAG;GACjD,UAAU,KAAK,aAAa;IAC1B,SAAS,GAAG,IAAI;GAClB,CAAC;EACH;CACF;;;;;CAKA,oBAAoB,OAAO,aAAa;EACtC,IAAI,CAAC,KAAK,gBAAgB,QAAQ;GAChC,KAAK,gBAAgB,SAAS,CAAC,QAAQ;GACvC;EACF;EACA,KAAK,gBAAgB,MAAM,CAAC,KAAK,QAAQ;CAC3C;;;;;CAKA,uBAAuB,OAAO,aAAa;EACzC,MAAM,YAAY,KAAK,gBAAgB;EACvC,MAAM,oBAAoB,UAAU,QACjC,MAAM,EAAE,SAAS,MAAM,SAAS,SAAS,CAC5C;EACA,KAAK,gBAAgB,SAAS;CAChC;CACA,aAAa;EACX,OAAO,QAAQ,QAAQ,IAAI;CAC7B;CACA,gBAAgB;EACd,OAAO,QAAQ,QAAQ,UAAU;CACnC;;;;;;;CAOA,QAAQ,KAAK,QAAQ;EACnB,IAAI,UAAU,WAAW,GAAG;GAC1B,SAAS;EACX;EACA,IAAI;GACF,KAAK,KAAK,MAAM;GAChB,KAAK,eAAe,UAAU,GAAG;GACjC,OAAO,QAAQ,QAAQ;EACzB,SAAS,GAAG;GACV,OAAO,QAAQ,OAAO,CAAC;EACzB;CACF;CACA,aAAa,KAAK;EAChB,UAAU,OAAO,QAAQ,UAAU,2CAA2C,GAAG;EACjF,UAAU,KAAK,8BAA8B;CAC/C;AACF;AACA,MAAM,QAAQ,KAAK,WAAW;CAC5B,IAAI,WAAW;EACb,MAAM,YAAY,IAAI,IAAI,KAAK,OAAO,QAAQ,CAAC,CAAC,SAAS;EACzD,IAAI,UAAU,QAAQ,MAAM,MAAM,GAAG;GACnC,OAAO,WAAW;EACpB,OAAO;GACL,OAAO,KAAK,WAAW,QAAQ,UAAU;EAC3C;CACF;AACF;AACA,MAAM,kBAAkB,IAAI,QAAQ"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["esm/PixelRatio/index.js"],"sourcesContent":["import { Dimensions } from \"../Dimensions/index\";\nclass PixelRatio {\n /**\n * Returns the device pixel density.\n */\n static get() {\n return Dimensions.get(\"window\").scale;\n }\n /**\n * No equivalent for Web\n */\n static getFontScale() {\n return Dimensions.get(\"window\").fontScale || PixelRatio.get();\n }\n /**\n * Converts a layout size (dp) to pixel size (px).\n * Guaranteed to return an integer number.\n */\n static getPixelSizeForLayoutSize(layoutSize) {\n return Math.round(layoutSize * PixelRatio.get());\n }\n /**\n * Rounds a layout size (dp) to the nearest layout size that corresponds to\n * an integer number of pixels. For example, on a device with a PixelRatio\n * of 3, `PixelRatio.roundToNearestPixel(8.4) = 8.33`, which corresponds to\n * exactly (8.33 * 3) = 25 pixels.\n */\n static roundToNearestPixel(layoutSize) {\n const ratio = PixelRatio.get();\n return Math.round(layoutSize * ratio) / ratio;\n }\n}\nexport {\n PixelRatio\n};\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;AACA,IAAM,aAAN,MAAM,WAAW;;;;CAIf,OAAO,MAAM;EACX,OAAO,WAAW,IAAI,QAAQ,EAAE;CAClC;;;;CAIA,OAAO,eAAe;EACpB,OAAO,WAAW,IAAI,QAAQ,EAAE,aAAa,WAAW,IAAI;CAC9D;;;;;CAKA,OAAO,0BAA0B,YAAY;EAC3C,OAAO,KAAK,MAAM,aAAa,WAAW,IAAI,CAAC;CACjD;;;;;;;CAOA,OAAO,oBAAoB,YAAY;EACrC,MAAM,QAAQ,WAAW,IAAI;EAC7B,OAAO,KAAK,MAAM,aAAa,KAAK,IAAI;CAC1C;AACF"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["esm/PixelRatio/index.js"],"sourcesContent":["import { Dimensions } from \"../Dimensions/index\";\nclass PixelRatio {\n /**\n * Returns the device pixel density.\n */\n static get() {\n return Dimensions.get(\"window\").scale;\n }\n /**\n * No equivalent for Web\n */\n static getFontScale() {\n return Dimensions.get(\"window\").fontScale || PixelRatio.get();\n }\n /**\n * Converts a layout size (dp) to pixel size (px).\n * Guaranteed to return an integer number.\n */\n static getPixelSizeForLayoutSize(layoutSize) {\n return Math.round(layoutSize * PixelRatio.get());\n }\n /**\n * Rounds a layout size (dp) to the nearest layout size that corresponds to\n * an integer number of pixels. For example, on a device with a PixelRatio\n * of 3, `PixelRatio.roundToNearestPixel(8.4) = 8.33`, which corresponds to\n * exactly (8.33 * 3) = 25 pixels.\n */\n static roundToNearestPixel(layoutSize) {\n const ratio = PixelRatio.get();\n return Math.round(layoutSize * ratio) / ratio;\n }\n}\nexport {\n PixelRatio\n};\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;AACA,IAAM,aAAN,MAAM,WAAW;;;;CAIf,OAAO,MAAM;EACX,OAAO,WAAW,IAAI,QAAQ,CAAC,CAAC;CAClC;;;;CAIA,OAAO,eAAe;EACpB,OAAO,WAAW,IAAI,QAAQ,CAAC,CAAC,aAAa,WAAW,IAAI;CAC9D;;;;;CAKA,OAAO,0BAA0B,YAAY;EAC3C,OAAO,KAAK,MAAM,aAAa,WAAW,IAAI,CAAC;CACjD;;;;;;;CAOA,OAAO,oBAAoB,YAAY;EACrC,MAAM,QAAQ,WAAW,IAAI;EAC7B,OAAO,KAAK,MAAM,aAAa,KAAK,IAAI;CAC1C;AACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["esm/SafeAreaView/index.js"],"sourcesContent":["import * as React from \"react\";\nimport { StyleSheet, canUseDOM } from \"@tamagui/react-native-web-internals\";\nimport { View } from \"../View/index\";\nimport { jsx } from \"react/jsx-runtime\";\nconst cssFunction = (() => {\n if (canUseDOM && window.CSS && window.CSS.supports && window.CSS.supports(\"top: constant(safe-area-inset-top)\")) {\n return \"constant\";\n }\n return \"env\";\n})();\nconst SafeAreaView = React.forwardRef((props, ref) => {\n const { style, ...rest } = props;\n return /* @__PURE__ */ jsx(View, { ...rest, ref, style: StyleSheet.compose(styles.root, style) });\n});\nSafeAreaView.displayName = \"SafeAreaView\";\nconst styles = StyleSheet.create({\n root: {\n paddingTop: `${cssFunction}(safe-area-inset-top)`,\n paddingRight: `${cssFunction}(safe-area-inset-right)`,\n paddingBottom: `${cssFunction}(safe-area-inset-bottom)`,\n paddingLeft: `${cssFunction}(safe-area-inset-left)`\n }\n});\nvar SafeAreaView_default = SafeAreaView;\nexport {\n SafeAreaView,\n SafeAreaView_default as default\n};\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;;;;AAIA,MAAM,qBAAqB;CACzB,IAAI,aAAa,OAAO,OAAO,OAAO,IAAI,YAAY,OAAO,IAAI,SAAS,oCAAoC,GAAG;EAC/G,OAAO;CACT;CACA,OAAO;AACT,GAAG;AACH,MAAM,eAAe,MAAM,YAAY,OAAO,QAAQ;CACpD,MAAM,EAAE,OAAO,GAAG,SAAS;CAC3B,OAAuB,oBAAI,MAAM;EAAE,GAAG;EAAM;EAAK,OAAO,WAAW,QAAQ,OAAO,MAAM,KAAK;CAAE,CAAC;AAClG,CAAC;AACD,aAAa,cAAc;AAC3B,MAAM,SAAS,WAAW,OAAO,EAC/B,MAAM;CACJ,YAAY,GAAG,YAAY;CAC3B,cAAc,GAAG,YAAY;CAC7B,eAAe,GAAG,YAAY;CAC9B,aAAa,GAAG,YAAY;AAC9B,EACF,CAAC;AACD,IAAI,uBAAuB"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["esm/SafeAreaView/index.js"],"sourcesContent":["import * as React from \"react\";\nimport { StyleSheet, canUseDOM } from \"@tamagui/react-native-web-internals\";\nimport { View } from \"../View/index\";\nimport { jsx } from \"react/jsx-runtime\";\nconst cssFunction = (() => {\n if (canUseDOM && window.CSS && window.CSS.supports && window.CSS.supports(\"top: constant(safe-area-inset-top)\")) {\n return \"constant\";\n }\n return \"env\";\n})();\nconst SafeAreaView = React.forwardRef((props, ref) => {\n const { style, ...rest } = props;\n return /* @__PURE__ */ jsx(View, { ...rest, ref, style: StyleSheet.compose(styles.root, style) });\n});\nSafeAreaView.displayName = \"SafeAreaView\";\nconst styles = StyleSheet.create({\n root: {\n paddingTop: `${cssFunction}(safe-area-inset-top)`,\n paddingRight: `${cssFunction}(safe-area-inset-right)`,\n paddingBottom: `${cssFunction}(safe-area-inset-bottom)`,\n paddingLeft: `${cssFunction}(safe-area-inset-left)`\n }\n});\nvar SafeAreaView_default = SafeAreaView;\nexport {\n SafeAreaView,\n SafeAreaView_default as default\n};\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;;;;AAIA,MAAM,qBAAqB;CACzB,IAAI,aAAa,OAAO,OAAO,OAAO,IAAI,YAAY,OAAO,IAAI,SAAS,oCAAoC,GAAG;EAC/G,OAAO;CACT;CACA,OAAO;AACT,EAAC,CAAE;AACH,MAAM,eAAe,MAAM,YAAY,OAAO,QAAQ;CACpD,MAAM,EAAE,OAAO,GAAG,SAAS;CAC3B,OAAuB,oBAAI,MAAM;EAAE,GAAG;EAAM;EAAK,OAAO,WAAW,QAAQ,OAAO,MAAM,KAAK;CAAE,CAAC;AAClG,CAAC;AACD,aAAa,cAAc;AAC3B,MAAM,SAAS,WAAW,OAAO,EAC/B,MAAM;CACJ,YAAY,GAAG,YAAY;CAC3B,cAAc,GAAG,YAAY;CAC7B,eAAe,GAAG,YAAY;CAC9B,aAAa,GAAG,YAAY;AAC9B,EACF,CAAC;AACD,IAAI,uBAAuB"}
@@ -1 +1 @@
1
- {"version":3,"file":"WebScrollView.js","names":["View","LiteView"],"sources":["esm/ScrollView/WebScrollView.js"],"sourcesContent":["import * as React from \"react\";\nimport { View as LiteView } from \"../View/index\";\nimport { jsx } from \"react/jsx-runtime\";\nconst View = LiteView;\nfunction mergeRefs(...refs) {\n return (node) => {\n for (const ref of refs) {\n if (!ref) continue;\n if (typeof ref === \"function\") ref(node);\n else ref.current = node;\n }\n };\n}\nfunction normalizeScrollEvent(e) {\n const target = e.target;\n return {\n nativeEvent: {\n contentOffset: {\n get x() {\n return target.scrollLeft;\n },\n get y() {\n return target.scrollTop;\n }\n },\n contentSize: {\n get height() {\n return target.scrollHeight;\n },\n get width() {\n return target.scrollWidth;\n }\n },\n layoutMeasurement: {\n get height() {\n return target.offsetHeight;\n },\n get width() {\n return target.offsetWidth;\n }\n }\n },\n timeStamp: Date.now()\n };\n}\nfunction shouldEmitScrollEvent(lastTick, eventThrottle) {\n const timeSinceLastTick = Date.now() - lastTick;\n return eventThrottle > 0 && timeSinceLastTick >= eventThrottle;\n}\nfunction resolveStyles(...inputs) {\n const style = {};\n const classNames = [];\n const walk = (s) => {\n if (!s) return;\n if (Array.isArray(s)) {\n for (const item of s) walk(item);\n return;\n }\n if (s.$$css) {\n for (const k in s) {\n if (k !== \"$$css\") classNames.push(s[k]);\n }\n } else {\n Object.assign(style, s);\n }\n };\n for (const input of inputs) walk(input);\n return { style, className: classNames.join(\" \") };\n}\nfunction joinClassNames(...parts) {\n const joined = parts.filter(Boolean).join(\" \").trim();\n return joined || void 0;\n}\nconst commonStyle = {\n flexGrow: 1,\n flexShrink: 1\n};\nconst styles = {\n baseVertical: {\n ...commonStyle,\n flexDirection: \"column\",\n overflowX: \"hidden\",\n overflowY: \"auto\"\n },\n baseHorizontal: {\n ...commonStyle,\n flexDirection: \"row\",\n overflowX: \"auto\",\n overflowY: \"hidden\"\n },\n contentContainerHorizontal: {\n flexDirection: \"row\"\n },\n contentContainerCenterContent: {\n justifyContent: \"center\",\n flexGrow: 1\n },\n stickyHeader: {\n position: \"sticky\",\n top: 0,\n zIndex: 10\n },\n pagingEnabledHorizontal: {\n scrollSnapType: \"x mandatory\"\n },\n pagingEnabledVertical: {\n scrollSnapType: \"y mandatory\"\n },\n pagingEnabledChild: {\n scrollSnapAlign: \"start\"\n },\n scrollDisabled: {\n overflowX: \"hidden\",\n overflowY: \"hidden\",\n touchAction: \"none\"\n }\n};\nconst WebScrollView = React.forwardRef(\n (props, forwardedRef) => {\n const {\n children,\n contentContainerStyle,\n horizontal,\n onContentSizeChange,\n onScroll,\n refreshControl,\n stickyHeaderIndices,\n pagingEnabled,\n centerContent,\n scrollEnabled = true,\n scrollEventThrottle = 0,\n showsHorizontalScrollIndicator,\n showsVerticalScrollIndicator,\n style,\n // strip react-native-only props that shouldn't reach the DOM\n keyboardShouldPersistTaps,\n keyboardDismissMode,\n contentOffset,\n contentInset,\n contentInsetAdjustmentBehavior,\n decelerationRate,\n directionalLockEnabled,\n disableIntervalMomentum,\n disableScrollViewPanResponder,\n endFillColor,\n fadingEdgeLength,\n indicatorStyle,\n invertStickyHeaders,\n maintainVisibleContentPosition,\n maximumZoomScale,\n minimumZoomScale,\n nestedScrollEnabled,\n onScrollToTop,\n overScrollMode,\n pinchGestureEnabled,\n removeClippedSubviews,\n scrollIndicatorInsets,\n scrollPerfTag,\n scrollToOverflowEnabled,\n snapToAlignment,\n snapToEnd,\n snapToInterval,\n snapToOffsets,\n snapToStart,\n bounces,\n ...rest\n } = props;\n const { dataSet, ...domRest } = rest;\n const dataAttrs = {};\n if (dataSet) {\n for (const key in dataSet) {\n dataAttrs[`data-${key}`] = dataSet[key];\n }\n }\n const scrollNodeRef = React.useRef(null);\n const innerViewRef = React.useRef(null);\n const scrollState = React.useRef({ isScrolling: false, scrollLastTick: 0 });\n const scrollTimeout = React.useRef(null);\n const scrollTo = (options) => {\n const node = scrollNodeRef.current;\n if (node == null) return;\n const { x = 0, y = 0, animated = true } = options || {};\n if (typeof node.scroll === \"function\") {\n node.scroll({ top: y, left: x, behavior: animated ? \"smooth\" : \"auto\" });\n } else {\n node.scrollLeft = x;\n node.scrollTop = y;\n }\n };\n const scrollToEnd = (options) => {\n const node = scrollNodeRef.current;\n if (node == null) return;\n const animated = (options && options.animated) !== false;\n const x = horizontal ? node.scrollWidth : 0;\n const y = horizontal ? 0 : node.scrollHeight;\n scrollTo({ x, y, animated });\n };\n const setScrollNodeRef = React.useCallback(\n (node) => {\n scrollNodeRef.current = node;\n if (node != null) {\n node.getScrollResponder = () => node;\n node.getScrollableNode = () => node;\n node.getInnerViewNode = () => innerViewRef.current;\n node.getInnerViewRef = () => innerViewRef.current;\n node.getNativeScrollRef = () => node;\n node.scrollTo = scrollTo;\n node.scrollToEnd = scrollToEnd;\n node.flashScrollIndicators = () => {\n };\n }\n mergeRefs(forwardedRef)(node);\n },\n [forwardedRef, horizontal]\n );\n function handleScroll(e) {\n e.stopPropagation();\n if (e.target !== scrollNodeRef.current) return;\n if (scrollTimeout.current != null) {\n clearTimeout(scrollTimeout.current);\n }\n scrollTimeout.current = setTimeout(() => {\n scrollState.current.isScrolling = false;\n onScroll?.(normalizeScrollEvent(e));\n }, 100);\n if (scrollState.current.isScrolling) {\n if (shouldEmitScrollEvent(scrollState.current.scrollLastTick, scrollEventThrottle)) {\n scrollState.current.scrollLastTick = Date.now();\n onScroll?.(normalizeScrollEvent(e));\n }\n } else {\n scrollState.current.isScrolling = true;\n scrollState.current.scrollLastTick = Date.now();\n onScroll?.(normalizeScrollEvent(e));\n }\n }\n const handleContentLayout = onContentSizeChange ? (e) => {\n const { width, height } = e.nativeEvent.layout;\n onContentSizeChange(width, height);\n } : void 0;\n const hasStickyHeaderIndices = !horizontal && Array.isArray(stickyHeaderIndices);\n const renderedChildren = hasStickyHeaderIndices || pagingEnabled ? React.Children.map(children, (child, i) => {\n const isSticky = hasStickyHeaderIndices && stickyHeaderIndices.indexOf(i) > -1;\n if (child != null && (isSticky || pagingEnabled)) {\n const resolved = resolveStyles(\n isSticky && styles.stickyHeader,\n pagingEnabled && styles.pagingEnabledChild\n );\n return /* @__PURE__ */ jsx(\n View,\n {\n style: resolved.style,\n className: joinClassNames(resolved.className),\n children: child\n }\n );\n }\n return child;\n }) : children;\n const contentResolved = resolveStyles(\n horizontal && styles.contentContainerHorizontal,\n centerContent && styles.contentContainerCenterContent,\n contentContainerStyle\n );\n const contentContainer = /* @__PURE__ */ jsx(\n View,\n {\n ref: innerViewRef,\n onLayout: handleContentLayout,\n style: contentResolved.style,\n className: joinClassNames(contentResolved.className),\n children: renderedChildren\n }\n );\n const baseStyle = horizontal ? styles.baseHorizontal : styles.baseVertical;\n const pagingEnabledStyle = horizontal ? styles.pagingEnabledHorizontal : styles.pagingEnabledVertical;\n const hideHorizontalScrollbar = showsHorizontalScrollIndicator === false;\n const hideVerticalScrollbar = showsVerticalScrollIndicator === false;\n const extraClassName = (hideHorizontalScrollbar ? \" _hsb-x\" : \"\") + (hideVerticalScrollbar ? \" _hsb-y\" : \"\");\n const scrollResolved = resolveStyles(\n baseStyle,\n pagingEnabled && pagingEnabledStyle,\n style,\n !scrollEnabled && styles.scrollDisabled\n );\n const scrollView = /* @__PURE__ */ jsx(\n View,\n {\n ...domRest,\n ...dataAttrs,\n className: joinClassNames(\n domRest.className,\n scrollResolved.className,\n extraClassName\n ),\n ref: setScrollNodeRef,\n onScroll: handleScroll,\n style: scrollResolved.style,\n children: contentContainer\n }\n );\n if (refreshControl) {\n const refreshResolved = resolveStyles(baseStyle, style);\n return React.cloneElement(\n refreshControl,\n {\n style: refreshResolved.style,\n className: joinClassNames(refreshResolved.className)\n },\n scrollView\n );\n }\n return scrollView;\n }\n);\nWebScrollView.displayName = \"ScrollView\";\nexport {\n WebScrollView\n};\n//# sourceMappingURL=WebScrollView.js.map\n"],"mappings":";;;;;AAGA,MAAMA,SAAOC;AACb,SAAS,UAAU,GAAG,MAAM;CAC1B,QAAQ,SAAS;EACf,KAAK,MAAM,OAAO,MAAM;GACtB,IAAI,CAAC,KAAK;GACV,IAAI,OAAO,QAAQ,YAAY,IAAI,IAAI;QAClC,IAAI,UAAU;EACrB;CACF;AACF;AACA,SAAS,qBAAqB,GAAG;CAC/B,MAAM,SAAS,EAAE;CACjB,OAAO;EACL,aAAa;GACX,eAAe;IACb,IAAI,IAAI;KACN,OAAO,OAAO;IAChB;IACA,IAAI,IAAI;KACN,OAAO,OAAO;IAChB;GACF;GACA,aAAa;IACX,IAAI,SAAS;KACX,OAAO,OAAO;IAChB;IACA,IAAI,QAAQ;KACV,OAAO,OAAO;IAChB;GACF;GACA,mBAAmB;IACjB,IAAI,SAAS;KACX,OAAO,OAAO;IAChB;IACA,IAAI,QAAQ;KACV,OAAO,OAAO;IAChB;GACF;EACF;EACA,WAAW,KAAK,IAAI;CACtB;AACF;AACA,SAAS,sBAAsB,UAAU,eAAe;CACtD,MAAM,oBAAoB,KAAK,IAAI,IAAI;CACvC,OAAO,gBAAgB,KAAK,qBAAqB;AACnD;AACA,SA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BAAkB,cACtB,cAAc,OAAO,4BACrB,iBAAiB,OAAO,+BACxB,qBACF;CACA,MAAM,mBAAmC,oBACvCA,QACA;EACE,KAAK;EACL,UAAU;EACV,OAAO,gBAAgB;EACvB,WAAW,eAAe,gBAAgB,SAAS;EACnD,UAAU;CACZ,CACF;CACA,MAAM,YAAY,aAAa,OAAO,iBAAiB,OAAO;CAC9D,MAAM,qBAAqB,aAAa,OAAO,0BAA0B,OAAO;CAChF,MAAM,0BAA0B,mCAAmC;CACnE,MAAM,wBAAwB,iCAAiC;CAC/D,MAAM,kBAAkB,0BAA0B,YAAY,OAAO,wBAAwB,YAAY;CACzG,MAAM,iBAAiB,cACrB,WACA,iBAAiB,oBACjB,OACA,CAAC,iBAAiB,OAAO,cAC3B;CACA,MAAM,aAA6B,oBACjCA,QACA;EACE,GAAG;EACH,GAAG;EACH,WAAW,eACT,QAAQ,WACR,eAAe,WACf,cACF;EACA,KAAK;EACL,UAAU;EACV,OAAO,eAAe;EACtB,UAAU;CACZ,CACF;CACA,IAAI,gBAAgB;EAClB,MAAM,kBAAkB,cAAc,WAAW,KAAK;EACtD,OAAO,MAAM,aACX,gBACA;GACE,OAAO,gBAAgB;GACvB,WAAW,eAAe,gBAAgB,SAAS;EACrD,GACA,UACF;CACF;CACA,OAAO;AACT,CACF;AACA,cAAc,cAAc"}
1
+ {"version":3,"file":"WebScrollView.js","names":["View","LiteView"],"sources":["esm/ScrollView/WebScrollView.js"],"sourcesContent":["import * as React from \"react\";\nimport { View as LiteView } from \"../View/index\";\nimport { jsx } from \"react/jsx-runtime\";\nconst View = LiteView;\nfunction mergeRefs(...refs) {\n return (node) => {\n for (const ref of refs) {\n if (!ref) continue;\n if (typeof ref === \"function\") ref(node);\n else ref.current = node;\n }\n };\n}\nfunction normalizeScrollEvent(e) {\n const target = e.target;\n return {\n nativeEvent: {\n contentOffset: {\n get x() {\n return target.scrollLeft;\n },\n get y() {\n return target.scrollTop;\n }\n },\n contentSize: {\n get height() {\n return target.scrollHeight;\n },\n get width() {\n return target.scrollWidth;\n }\n },\n layoutMeasurement: {\n get height() {\n return target.offsetHeight;\n },\n get width() {\n return target.offsetWidth;\n }\n }\n },\n timeStamp: Date.now()\n };\n}\nfunction shouldEmitScrollEvent(lastTick, eventThrottle) {\n const timeSinceLastTick = Date.now() - lastTick;\n return eventThrottle > 0 && timeSinceLastTick >= eventThrottle;\n}\nfunction resolveStyles(...inputs) {\n const style = {};\n const classNames = [];\n const walk = (s) => {\n if (!s) return;\n if (Array.isArray(s)) {\n for (const item of s) walk(item);\n return;\n }\n if (s.$$css) {\n for (const k in s) {\n if (k !== \"$$css\") classNames.push(s[k]);\n }\n } else {\n Object.assign(style, s);\n }\n };\n for (const input of inputs) walk(input);\n return { style, className: classNames.join(\" \") };\n}\nfunction joinClassNames(...parts) {\n const joined = parts.filter(Boolean).join(\" \").trim();\n return joined || void 0;\n}\nconst commonStyle = {\n flexGrow: 1,\n flexShrink: 1\n};\nconst styles = {\n baseVertical: {\n ...commonStyle,\n flexDirection: \"column\",\n overflowX: \"hidden\",\n overflowY: \"auto\"\n },\n baseHorizontal: {\n ...commonStyle,\n flexDirection: \"row\",\n overflowX: \"auto\",\n overflowY: \"hidden\"\n },\n contentContainerHorizontal: {\n flexDirection: \"row\"\n },\n contentContainerCenterContent: {\n justifyContent: \"center\",\n flexGrow: 1\n },\n stickyHeader: {\n position: \"sticky\",\n top: 0,\n zIndex: 10\n },\n pagingEnabledHorizontal: {\n scrollSnapType: \"x mandatory\"\n },\n pagingEnabledVertical: {\n scrollSnapType: \"y mandatory\"\n },\n pagingEnabledChild: {\n scrollSnapAlign: \"start\"\n },\n scrollDisabled: {\n overflowX: \"hidden\",\n overflowY: \"hidden\",\n touchAction: \"none\"\n }\n};\nconst WebScrollView = React.forwardRef(\n (props, forwardedRef) => {\n const {\n children,\n contentContainerStyle,\n horizontal,\n onContentSizeChange,\n onScroll,\n refreshControl,\n stickyHeaderIndices,\n pagingEnabled,\n centerContent,\n scrollEnabled = true,\n scrollEventThrottle = 0,\n showsHorizontalScrollIndicator,\n showsVerticalScrollIndicator,\n style,\n // strip react-native-only props that shouldn't reach the DOM\n keyboardShouldPersistTaps,\n keyboardDismissMode,\n contentOffset,\n contentInset,\n contentInsetAdjustmentBehavior,\n decelerationRate,\n directionalLockEnabled,\n disableIntervalMomentum,\n disableScrollViewPanResponder,\n endFillColor,\n fadingEdgeLength,\n indicatorStyle,\n invertStickyHeaders,\n maintainVisibleContentPosition,\n maximumZoomScale,\n minimumZoomScale,\n nestedScrollEnabled,\n onScrollToTop,\n overScrollMode,\n pinchGestureEnabled,\n removeClippedSubviews,\n scrollIndicatorInsets,\n scrollPerfTag,\n scrollToOverflowEnabled,\n snapToAlignment,\n snapToEnd,\n snapToInterval,\n snapToOffsets,\n snapToStart,\n bounces,\n ...rest\n } = props;\n const { dataSet, ...domRest } = rest;\n const dataAttrs = {};\n if (dataSet) {\n for (const key in dataSet) {\n dataAttrs[`data-${key}`] = dataSet[key];\n }\n }\n const scrollNodeRef = React.useRef(null);\n const innerViewRef = React.useRef(null);\n const scrollState = React.useRef({ isScrolling: false, scrollLastTick: 0 });\n const scrollTimeout = React.useRef(null);\n const scrollTo = (options) => {\n const node = scrollNodeRef.current;\n if (node == null) return;\n const { x = 0, y = 0, animated = true } = options || {};\n if (typeof node.scroll === \"function\") {\n node.scroll({ top: y, left: x, behavior: animated ? \"smooth\" : \"auto\" });\n } else {\n node.scrollLeft = x;\n node.scrollTop = y;\n }\n };\n const scrollToEnd = (options) => {\n const node = scrollNodeRef.current;\n if (node == null) return;\n const animated = (options && options.animated) !== false;\n const x = horizontal ? node.scrollWidth : 0;\n const y = horizontal ? 0 : node.scrollHeight;\n scrollTo({ x, y, animated });\n };\n const setScrollNodeRef = React.useCallback(\n (node) => {\n scrollNodeRef.current = node;\n if (node != null) {\n node.getScrollResponder = () => node;\n node.getScrollableNode = () => node;\n node.getInnerViewNode = () => innerViewRef.current;\n node.getInnerViewRef = () => innerViewRef.current;\n node.getNativeScrollRef = () => node;\n node.scrollTo = scrollTo;\n node.scrollToEnd = scrollToEnd;\n node.flashScrollIndicators = () => {\n };\n }\n mergeRefs(forwardedRef)(node);\n },\n [forwardedRef, horizontal]\n );\n function handleScroll(e) {\n e.stopPropagation();\n if (e.target !== scrollNodeRef.current) return;\n if (scrollTimeout.current != null) {\n clearTimeout(scrollTimeout.current);\n }\n scrollTimeout.current = setTimeout(() => {\n scrollState.current.isScrolling = false;\n onScroll?.(normalizeScrollEvent(e));\n }, 100);\n if (scrollState.current.isScrolling) {\n if (shouldEmitScrollEvent(scrollState.current.scrollLastTick, scrollEventThrottle)) {\n scrollState.current.scrollLastTick = Date.now();\n onScroll?.(normalizeScrollEvent(e));\n }\n } else {\n scrollState.current.isScrolling = true;\n scrollState.current.scrollLastTick = Date.now();\n onScroll?.(normalizeScrollEvent(e));\n }\n }\n const handleContentLayout = onContentSizeChange ? (e) => {\n const { width, height } = e.nativeEvent.layout;\n onContentSizeChange(width, height);\n } : void 0;\n const hasStickyHeaderIndices = !horizontal && Array.isArray(stickyHeaderIndices);\n const renderedChildren = hasStickyHeaderIndices || pagingEnabled ? React.Children.map(children, (child, i) => {\n const isSticky = hasStickyHeaderIndices && stickyHeaderIndices.indexOf(i) > -1;\n if (child != null && (isSticky || pagingEnabled)) {\n const resolved = resolveStyles(\n isSticky && styles.stickyHeader,\n pagingEnabled && styles.pagingEnabledChild\n );\n return /* @__PURE__ */ jsx(\n View,\n {\n style: resolved.style,\n className: joinClassNames(resolved.className),\n children: child\n }\n );\n }\n return child;\n }) : children;\n const contentResolved = resolveStyles(\n horizontal && styles.contentContainerHorizontal,\n centerContent && styles.contentContainerCenterContent,\n contentContainerStyle\n );\n const contentContainer = /* @__PURE__ */ jsx(\n View,\n {\n ref: innerViewRef,\n onLayout: handleContentLayout,\n style: contentResolved.style,\n className: joinClassNames(contentResolved.className),\n children: renderedChildren\n }\n );\n const baseStyle = horizontal ? styles.baseHorizontal : styles.baseVertical;\n const pagingEnabledStyle = horizontal ? styles.pagingEnabledHorizontal : styles.pagingEnabledVertical;\n const hideHorizontalScrollbar = showsHorizontalScrollIndicator === false;\n const hideVerticalScrollbar = showsVerticalScrollIndicator === false;\n const extraClassName = (hideHorizontalScrollbar ? \" _hsb-x\" : \"\") + (hideVerticalScrollbar ? \" _hsb-y\" : \"\");\n const scrollResolved = resolveStyles(\n baseStyle,\n pagingEnabled && pagingEnabledStyle,\n style,\n !scrollEnabled && styles.scrollDisabled\n );\n const scrollView = /* @__PURE__ */ jsx(\n View,\n {\n ...domRest,\n ...dataAttrs,\n className: joinClassNames(\n domRest.className,\n scrollResolved.className,\n extraClassName\n ),\n ref: setScrollNodeRef,\n onScroll: handleScroll,\n style: scrollResolved.style,\n children: contentContainer\n }\n );\n if (refreshControl) {\n const refreshResolved = resolveStyles(baseStyle, style);\n return React.cloneElement(\n refreshControl,\n {\n style: refreshResolved.style,\n className: joinClassNames(refreshResolved.className)\n },\n scrollView\n );\n }\n return scrollView;\n }\n);\nWebScrollView.displayName = \"ScrollView\";\nexport {\n WebScrollView\n};\n//# sourceMappingURL=WebScrollView.js.map\n"],"mappings":";;;;;AAGA,MAAMA,SAAOC;AACb,SAAS,UAAU,GAAG,MAAM;CAC1B,QAAQ,SAAS;EACf,KAAK,MAAM,OAAO,MAAM;GACtB,IAAI,CAAC,KAAK;GACV,IAAI,OAAO,QAAQ,YAAY,IAAI,IAAI;QAClC,IAAI,UAAU;EACrB;CACF;AACF;AACA,SAAS,qBAAqB,GAAG;CAC/B,MAAM,SAAS,EAAE;CACjB,OAAO;EACL,aAAa;GACX,eAAe;IACb,IAAI,IAAI;KACN,OAAO,OAAO;IAChB;IACA,IAAI,IAAI;KACN,OAAO,OAAO;IAChB;GACF;GACA,aAAa;IACX,IAAI,SAAS;KACX,OAAO,OAAO;IAChB;IACA,IAAI,QAAQ;KACV,OAAO,OAAO;IAChB;GACF;GACA,mBAAmB;IACjB,IAAI,SAAS;KACX,OAAO,OAAO;IAChB;IACA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AY,gBAAgB;GAChD,MAAM,WAAW,cACf,YAAY,OAAO,cACnB,iBAAiB,OAAO,kBAC1B;GACA,OAAuB,oBACrBD,QACA;IACE,OAAO,SAAS;IAChB,WAAW,eAAe,SAAS,SAAS;IAC5C,UAAU;GACZ,CACF;EACF;EACA,OAAO;CACT,CAAC,IAAI;CACL,MAAM,kBAAkB,cACtB,cAAc,OAAO,4BACrB,iBAAiB,OAAO,+BACxB,qBACF;CACA,MAAM,mBAAmC,oBACvCA,QACA;EACE,KAAK;EACL,UAAU;EACV,OAAO,gBAAgB;EACvB,WAAW,eAAe,gBAAgB,SAAS;EACnD,UAAU;CACZ,CACF;CACA,MAAM,YAAY,aAAa,OAAO,iBAAiB,OAAO;CAC9D,MAAM,qBAAqB,aAAa,OAAO,0BAA0B,OAAO;CAChF,MAAM,0BAA0B,mCAAmC;CACnE,MAAM,wBAAwB,iCAAiC;CAC/D,MAAM,kBAAkB,0BAA0B,YAAY,OAAO,wBAAwB,YAAY;CACzG,MAAM,iBAAiB,cACrB,WACA,iBAAiB,oBACjB,OACA,CAAC,iBAAiB,OAAO,cAC3B;CACA,MAAM,aAA6B,oBACjCA,QACA;EACE,GAAG;EACH,GAAG;EACH,WAAW,eACT,QAAQ,WACR,eAAe,WACf,cACF;EACA,KAAK;EACL,UAAU;EACV,OAAO,eAAe;EACtB,UAAU;CACZ,CACF;CACA,IAAI,gBAAgB;EAClB,MAAM,kBAAkB,cAAc,WAAW,KAAK;EACtD,OAAO,MAAM,aACX,gBACA;GACE,OAAO,gBAAgB;GACvB,WAAW,eAAe,gBAAgB,SAAS;EACrD,GACA,UACF;CACF;CACA,OAAO;AACT,CACF;AACA,cAAc,cAAc"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["esm/View/index.js"],"sourcesContent":["import {\n forwardPropsListView,\n getLocaleDirection,\n pick,\n TextAncestorContext,\n useElementLayout,\n useLocaleContext,\n useMergeRefs,\n usePlatformMethods,\n useResponderEvents\n} from \"@tamagui/react-native-web-internals\";\nimport * as React from \"react\";\nimport { useCreateElement } from \"../createElement/index\";\nconst pickProps = (props) => pick(props, forwardPropsListView);\nconst View = React.forwardRef(\n (props, forwardedRef) => {\n const {\n hrefAttrs,\n onLayout,\n onMoveShouldSetResponder,\n onMoveShouldSetResponderCapture,\n onResponderEnd,\n onResponderGrant,\n onResponderMove,\n onResponderReject,\n onResponderRelease,\n onResponderStart,\n onResponderTerminate,\n onResponderTerminationRequest,\n onScrollShouldSetResponder,\n onScrollShouldSetResponderCapture,\n onSelectionChangeShouldSetResponder,\n onSelectionChangeShouldSetResponderCapture,\n onStartShouldSetResponder,\n onStartShouldSetResponderCapture,\n ...rest\n } = props;\n if (process.env.NODE_ENV !== \"production\") {\n React.Children.toArray(props.children).forEach((item) => {\n if (typeof item === \"string\") {\n console.error(\n `Unexpected text node: ${item}. A text node cannot be a child of a <View>.`\n );\n }\n });\n }\n const hasTextAncestor = React.useContext(TextAncestorContext);\n const hostRef = React.useRef(null);\n const { direction: contextDirection } = useLocaleContext();\n useElementLayout(hostRef, onLayout);\n useResponderEvents(hostRef, {\n onMoveShouldSetResponder,\n onMoveShouldSetResponderCapture,\n onResponderEnd,\n onResponderGrant,\n onResponderMove,\n onResponderReject,\n onResponderRelease,\n onResponderStart,\n onResponderTerminate,\n onResponderTerminationRequest,\n onScrollShouldSetResponder,\n onScrollShouldSetResponderCapture,\n onSelectionChangeShouldSetResponder,\n onSelectionChangeShouldSetResponderCapture,\n onStartShouldSetResponder,\n onStartShouldSetResponderCapture\n });\n let component = \"div\";\n const langDirection = props.lang != null ? getLocaleDirection(props.lang) : null;\n const componentDirection = props.dir || langDirection;\n const writingDirection = componentDirection || contextDirection;\n const supportedProps = pickProps(rest);\n supportedProps.dir = componentDirection;\n supportedProps.style = [styles.view, hasTextAncestor && styles.inline, props.style];\n if (props.href != null) {\n component = \"a\";\n if (hrefAttrs != null) {\n const { download, rel, target } = hrefAttrs;\n if (download != null) {\n supportedProps.download = download;\n }\n if (rel != null) {\n supportedProps.rel = rel;\n }\n if (typeof target === \"string\") {\n supportedProps.target = target.charAt(0) !== \"_\" ? \"_\" + target : target;\n }\n }\n }\n const platformMethodsRef = usePlatformMethods(supportedProps);\n const setRef = useMergeRefs(hostRef, platformMethodsRef, forwardedRef);\n supportedProps.ref = setRef;\n return useCreateElement(component, supportedProps, { writingDirection });\n }\n);\nView.displayName = \"View\";\nconst styles = {\n view: {\n alignItems: \"stretch\",\n boxSizing: \"border-box\",\n display: \"flex\",\n flexBasis: \"auto\",\n flexDirection: \"column\",\n flexShrink: 0\n },\n inline: {\n display: \"inline-flex\"\n }\n};\nvar View_default = View;\nexport {\n View,\n View_default as default\n};\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;;;AAaA,MAAM,aAAa,UAAU,KAAK,OAAO,oBAAoB;AAC7D,MAAM,OAAO,MAAM,YAChB,OAAO,iBAAiB;CACvB,MAAM,EACJ,WACA,UACA,0BACA,iCACA,gBACA,kBACA,iBACA,mBACA,oBACA,kBACA,sBACA,+BACA,4BACA,mCACA,qCACA,4CACA,2BACA,kCACA,GAAG,SACD;CACJ,IAAI,QAAQ,IAAI,aAAa,cAAc;EACzC,MAAM,SAAS,QAAQ,MAAM,QAAQ,EAAE,SAAS,SAAS;GACvD,IAAI,OAAO,SAAS,UAAU;IAC5B,QAAQ,MACN,yBAAyB,KAAK,6CAChC;GACF;EACF,CAAC;CACH;CACA,MAAM,kBAAkB,MAAM,WAAW,mBAAmB;CAC5D,MAAM,UAAU,MAAM,OAAO,IAAI;CACjC,MAAM,EAAE,WAAW,qBAAqB,iBAAiB;CACzD,iBAAiB,SAAS,QAAQ;CAClC,mBAAmB,SAAS;EAC1B;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;CACF,CAAC;CACD,IAAI,YAAY;CAChB,MAAM,gBAAgB,MAAM,QAAQ,OAAO,mBAAmB,MAAM,IAAI,IAAI;CAC5E,MAAM,qBAAqB,MAAM,OAAO;CACxC,MAAM,mBAAmB,sBAAsB;CAC/C,MAAM,iBAAiB,UAAU,IAAI;CACrC,eAAe,MAAM;CACrB,eAAe,QAAQ;EAAC,OAAO;EAAM,mBAAmB,OAAO;EAAQ,MAAM;CAAK;CAClF,IAAI,MAAM,QAAQ,MAAM;EACtB,YAAY;EACZ,IAAI,aAAa,MAAM;GACrB,MAAM,EAAE,UAAU,KAAK,WAAW;GAClC,IAAI,YAAY,MAAM;IACpB,eAAe,WAAW;GAC5B;GACA,IAAI,OAAO,MAAM;IACf,eAAe,MAAM;GACvB;GACA,IAAI,OAAO,WAAW,UAAU;IAC9B,eAAe,SAAS,OAAO,OAAO,CAAC,MAAM,MAAM,MAAM,SAAS;GACpE;EACF;CACF;CACA,MAAM,qBAAqB,mBAAmB,cAAc;CAC5D,MAAM,SAAS,aAAa,SAAS,oBAAoB,YAAY;CACrE,eAAe,MAAM;CACrB,OAAO,iBAAiB,WAAW,gBAAgB,EAAE,iBAAiB,CAAC;AACzE,CACF;AACA,KAAK,cAAc;AACnB,MAAM,SAAS;CACb,MAAM;EACJ,YAAY;EACZ,WAAW;EACX,SAAS;EACT,WAAW;EACX,eAAe;EACf,YAAY;CACd;CACA,QAAQ,EACN,SAAS,cACX;AACF;AACA,IAAI,eAAe"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["esm/View/index.js"],"sourcesContent":["import {\n forwardPropsListView,\n getLocaleDirection,\n pick,\n TextAncestorContext,\n useElementLayout,\n useLocaleContext,\n useMergeRefs,\n usePlatformMethods,\n useResponderEvents\n} from \"@tamagui/react-native-web-internals\";\nimport * as React from \"react\";\nimport { useCreateElement } from \"../createElement/index\";\nconst pickProps = (props) => pick(props, forwardPropsListView);\nconst View = React.forwardRef(\n (props, forwardedRef) => {\n const {\n hrefAttrs,\n onLayout,\n onMoveShouldSetResponder,\n onMoveShouldSetResponderCapture,\n onResponderEnd,\n onResponderGrant,\n onResponderMove,\n onResponderReject,\n onResponderRelease,\n onResponderStart,\n onResponderTerminate,\n onResponderTerminationRequest,\n onScrollShouldSetResponder,\n onScrollShouldSetResponderCapture,\n onSelectionChangeShouldSetResponder,\n onSelectionChangeShouldSetResponderCapture,\n onStartShouldSetResponder,\n onStartShouldSetResponderCapture,\n ...rest\n } = props;\n if (process.env.NODE_ENV !== \"production\") {\n React.Children.toArray(props.children).forEach((item) => {\n if (typeof item === \"string\") {\n console.error(\n `Unexpected text node: ${item}. A text node cannot be a child of a <View>.`\n );\n }\n });\n }\n const hasTextAncestor = React.useContext(TextAncestorContext);\n const hostRef = React.useRef(null);\n const { direction: contextDirection } = useLocaleContext();\n useElementLayout(hostRef, onLayout);\n useResponderEvents(hostRef, {\n onMoveShouldSetResponder,\n onMoveShouldSetResponderCapture,\n onResponderEnd,\n onResponderGrant,\n onResponderMove,\n onResponderReject,\n onResponderRelease,\n onResponderStart,\n onResponderTerminate,\n onResponderTerminationRequest,\n onScrollShouldSetResponder,\n onScrollShouldSetResponderCapture,\n onSelectionChangeShouldSetResponder,\n onSelectionChangeShouldSetResponderCapture,\n onStartShouldSetResponder,\n onStartShouldSetResponderCapture\n });\n let component = \"div\";\n const langDirection = props.lang != null ? getLocaleDirection(props.lang) : null;\n const componentDirection = props.dir || langDirection;\n const writingDirection = componentDirection || contextDirection;\n const supportedProps = pickProps(rest);\n supportedProps.dir = componentDirection;\n supportedProps.style = [styles.view, hasTextAncestor && styles.inline, props.style];\n if (props.href != null) {\n component = \"a\";\n if (hrefAttrs != null) {\n const { download, rel, target } = hrefAttrs;\n if (download != null) {\n supportedProps.download = download;\n }\n if (rel != null) {\n supportedProps.rel = rel;\n }\n if (typeof target === \"string\") {\n supportedProps.target = target.charAt(0) !== \"_\" ? \"_\" + target : target;\n }\n }\n }\n const platformMethodsRef = usePlatformMethods(supportedProps);\n const setRef = useMergeRefs(hostRef, platformMethodsRef, forwardedRef);\n supportedProps.ref = setRef;\n return useCreateElement(component, supportedProps, { writingDirection });\n }\n);\nView.displayName = \"View\";\nconst styles = {\n view: {\n alignItems: \"stretch\",\n boxSizing: \"border-box\",\n display: \"flex\",\n flexBasis: \"auto\",\n flexDirection: \"column\",\n flexShrink: 0\n },\n inline: {\n display: \"inline-flex\"\n }\n};\nvar View_default = View;\nexport {\n View,\n View_default as default\n};\n//# sourceMappingURL=index.js.map\n"],"mappings":";;;;;AAaA,MAAM,aAAa,UAAU,KAAK,OAAO,oBAAoB;AAC7D,MAAM,OAAO,MAAM,YAChB,OAAO,iBAAiB;CACvB,MAAM,EACJ,WACA,UACA,0BACA,iCACA,gBACA,kBACA,iBACA,mBACA,oBACA,kBACA,sBACA,+BACA,4BACA,mCACA,qCACA,4CACA,2BACA,kCACA,GAAG,SACD;CACJ,IAAI,QAAQ,IAAI,aAAa,cAAc;EACzC,MAAM,SAAS,QAAQ,MAAM,QAAQ,CAAC,CAAC,SAAS,SAAS;GACvD,IAAI,OAAO,SAAS,UAAU;IAC5B,QAAQ,MACN,yBAAyB,KAAK,6CAChC;GACF;EACF,CAAC;CACH;CACA,MAAM,kBAAkB,MAAM,WAAW,mBAAmB;CAC5D,MAAM,UAAU,MAAM,OAAO,IAAI;CACjC,MAAM,EAAE,WAAW,qBAAqB,iBAAiB;CACzD,iBAAiB,SAAS,QAAQ;CAClC,mBAAmB,SAAS;EAC1B;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;CACF,CAAC;CACD,IAAI,YAAY;CAChB,MAAM,gBAAgB,MAAM,QAAQ,OAAO,mBAAmB,MAAM,IAAI,IAAI;CAC5E,MAAM,qBAAqB,MAAM,OAAO;CACxC,MAAM,mBAAmB,sBAAsB;CAC/C,MAAM,iBAAiB,UAAU,IAAI;CACrC,eAAe,MAAM;CACrB,eAAe,QAAQ;EAAC,OAAO;EAAM,mBAAmB,OAAO;EAAQ,MAAM;CAAK;CAClF,IAAI,MAAM,QAAQ,MAAM;EACtB,YAAY;EACZ,IAAI,aAAa,MAAM;GACrB,MAAM,EAAE,UAAU,KAAK,WAAW;GAClC,IAAI,YAAY,MAAM;IACpB,eAAe,WAAW;GAC5B;GACA,IAAI,OAAO,MAAM;IACf,eAAe,MAAM;GACvB;GACA,IAAI,OAAO,WAAW,UAAU;IAC9B,eAAe,SAAS,OAAO,OAAO,CAAC,MAAM,MAAM,MAAM,SAAS;GACpE;EACF;CACF;CACA,MAAM,qBAAqB,mBAAmB,cAAc;CAC5D,MAAM,SAAS,aAAa,SAAS,oBAAoB,YAAY;CACrE,eAAe,MAAM;CACrB,OAAO,iBAAiB,WAAW,gBAAgB,EAAE,iBAAiB,CAAC;AACzE,CACF;AACA,KAAK,cAAc;AACnB,MAAM,SAAS;CACb,MAAM;EACJ,YAAY;EACZ,WAAW;EACX,SAAS;EACT,WAAW;EACX,eAAe;EACf,YAAY;CACd;CACA,QAAQ,EACN,SAAS,cACX;AACF;AACA,IAAI,eAAe"}
@@ -1 +1 @@
1
- {"version":3,"file":"AnimatedEvent.js","names":[],"sources":["esm/vendor/react-native/Animated/AnimatedEvent.js"],"sourcesContent":["import { AnimatedValue } from \"./nodes/AnimatedValue\";\nimport { NativeAnimatedHelper } from \"./NativeAnimatedHelper\";\nimport { invariant } from \"@tamagui/react-native-web-internals\";\nimport { shouldUseNativeDriver } from \"./NativeAnimatedHelper\";\nconst __DEV__ = process.env.NODE_ENV !== \"production\";\nfunction attachNativeEvent(viewRef, eventName, argMapping) {\n const eventMappings = [];\n const traverse = (value, path) => {\n if (value instanceof AnimatedValue) {\n value.__makeNative();\n eventMappings.push({\n nativeEventPath: path,\n animatedValueTag: value.__getNativeTag()\n });\n } else if (typeof value === \"object\") {\n for (const key in value) {\n traverse(value[key], path.concat(key));\n }\n }\n };\n invariant(\n argMapping[0] && argMapping[0].nativeEvent,\n \"Native driven events only support animated values contained inside `nativeEvent`.\"\n );\n traverse(argMapping[0].nativeEvent, []);\n if (viewRef != null) {\n eventMappings.forEach((mapping) => {\n NativeAnimatedHelper.API.addAnimatedEventToView(viewRef, eventName, mapping);\n });\n }\n return {\n detach() {\n if (viewRef != null) {\n eventMappings.forEach((mapping) => {\n NativeAnimatedHelper.API.removeAnimatedEventFromView(\n viewRef,\n eventName,\n mapping.animatedValueTag\n );\n });\n }\n }\n };\n}\nfunction validateMapping(argMapping, args) {\n const validate = (recMapping, recEvt, key) => {\n if (recMapping instanceof AnimatedValue) {\n invariant(\n typeof recEvt === \"number\",\n \"Bad mapping of event key \" + key + \", should be number but got \" + typeof recEvt\n );\n return;\n }\n if (typeof recEvt === \"number\") {\n invariant(\n recMapping instanceof AnimatedValue,\n \"Bad mapping of type \" + typeof recMapping + \" for key \" + key + \", event value must map to AnimatedValue\"\n );\n return;\n }\n invariant(\n typeof recMapping === \"object\",\n \"Bad mapping of type \" + typeof recMapping + \" for key \" + key\n );\n invariant(\n typeof recEvt === \"object\",\n \"Bad event of type \" + typeof recEvt + \" for key \" + key\n );\n for (const mappingKey in recMapping) {\n validate(recMapping[mappingKey], recEvt[mappingKey], mappingKey);\n }\n };\n invariant(args.length >= argMapping.length, \"Event has less arguments than mapping\");\n argMapping.forEach((mapping, idx) => {\n validate(mapping, args[idx], \"arg\" + idx);\n });\n}\nclass AnimatedEvent {\n _argMapping;\n _listeners = [];\n _attachedEvent;\n __isNative;\n constructor(argMapping, config) {\n this._argMapping = argMapping;\n if (config == null) {\n console.warn(\"Animated.event now requires a second argument for options\");\n config = { useNativeDriver: false };\n }\n if (config.listener) {\n this.__addListener(config.listener);\n }\n this._callListeners = this._callListeners.bind(this);\n this._attachedEvent = null;\n this.__isNative = shouldUseNativeDriver(config);\n }\n __addListener(callback) {\n this._listeners.push(callback);\n }\n __removeListener(callback) {\n this._listeners = this._listeners.filter((listener) => listener !== callback);\n }\n __attach(viewRef, eventName) {\n invariant(this.__isNative, \"Only native driven events need to be attached.\");\n this._attachedEvent = attachNativeEvent(viewRef, eventName, this._argMapping);\n }\n __detach(viewTag, eventName) {\n invariant(this.__isNative, \"Only native driven events need to be detached.\");\n this._attachedEvent && this._attachedEvent.detach();\n }\n __getHandler() {\n if (this.__isNative) {\n if (__DEV__) {\n let validatedMapping2 = false;\n return (...args) => {\n if (!validatedMapping2) {\n validateMapping(this._argMapping, args);\n validatedMapping2 = true;\n }\n this._callListeners(...args);\n };\n } else {\n return this._callListeners;\n }\n }\n let validatedMapping = false;\n return (...args) => {\n if (__DEV__ && !validatedMapping) {\n validateMapping(this._argMapping, args);\n validatedMapping = true;\n }\n const traverse = (recMapping, recEvt, key) => {\n if (recMapping instanceof AnimatedValue) {\n if (typeof recEvt === \"number\") {\n recMapping.setValue(recEvt);\n }\n } else if (typeof recMapping === \"object\") {\n for (const mappingKey in recMapping) {\n traverse(recMapping[mappingKey], recEvt[mappingKey], mappingKey);\n }\n }\n };\n this._argMapping.forEach((mapping, idx) => {\n traverse(mapping, args[idx], \"arg\" + idx);\n });\n this._callListeners(...args);\n };\n }\n _callListeners(...args) {\n this._listeners.forEach((listener) => listener(...args));\n }\n}\nexport {\n AnimatedEvent,\n attachNativeEvent\n};\n//# sourceMappingURL=AnimatedEvent.js.map\n"],"mappings":";;;;;AAIA,MAAM,UAAU,QAAQ,IAAI,aAAa;AACzC,SAAS,kBAAkB,SAAS,WAAW,YAAY;CACzD,MAAM,gBAAgB,CAAC;CACvB,MAAM,YAAY,OAAO,SAAS;EAChC,IAAI,iBAAiB,eAAe;GAClC,MAAM,aAAa;GACnB,cAAc,KAAK;IACjB,iBAAiB;IACjB,kBAAkB,MAAM,eAAe;GACzC,CAAC;EACH,OAAO,IAAI,OAAO,UAAU,UAAU;GACpC,KAAK,MAAM,OAAO,OAAO;IACvB,SAAS,MAAM,MAAM,KAAK,OAAO,GAAG,CAAC;GACvC;EACF;CACF;CACA,UACE,WAAW,MAAM,WAAW,GAAG,aAC/B,mFACF;CACA,SAAS,WAAW,GAAG,aAAa,CAAC,CAAC;CACtC,IAAI,WAAW,MAAM;EACnB,cAAc,SAAS,YAAY;GACjC,qBAAqB,IAAI,uBAAuB,SAAS,WAAW,OAAO;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AAK,WAAW,QAAQ,aAAa,aAAa,QAAQ;CAC9E;CACA,SAAS,SAAS,WAAW;EAC3B,UAAU,KAAK,YAAY,gDAAgD;EAC3E,KAAK,iBAAiB,kBAAkB,SAAS,WAAW,KAAK,WAAW;CAC9E;CACA,SAAS,SAAS,WAAW;EAC3B,UAAU,KAAK,YAAY,gDAAgD;EAC3E,KAAK,kBAAkB,KAAK,eAAe,OAAO;CACpD;CACA,eAAe;EACb,IAAI,KAAK,YAAY;GACnB,IAAI,SAAS;IACX,IAAI,oBAAoB;IACxB,QAAQ,GAAG,SAAS;KAClB,IAAI,CAAC,mBAAmB;MACtB,gBAAgB,KAAK,aAAa,IAAI;MACtC,oBAAoB;KACtB;KACA,KAAK,eAAe,GAAG,IAAI;IAC7B;GACF,OAAO;IACL,OAAO,KAAK;GACd;EACF;EACA,IAAI,mBAAmB;EACvB,QAAQ,GAAG,SAAS;GAClB,IAAI,WAAW,CAAC,kBAAkB;IAChC,gBAAgB,KAAK,aAAa,IAAI;IACtC,mBAAmB;GACrB;GACA,MAAM,YAAY,YAAY,QAAQ,QAAQ;IAC5C,IAAI,sBAAsB,eAAe;KACvC,IAAI,OAAO,WAAW,UAAU;MAC9B,WAAW,SAAS,MAAM;KAC5B;IACF,OAAO,IAAI,OAAO,eAAe,UAAU;KACzC,KAAK,MAAM,cAAc,YAAY;MACnC,SAAS,WAAW,aAAa,OAAO,aAAa,UAAU;KACjE;IACF;GACF;GACA,KAAK,YAAY,SAAS,SAAS,QAAQ;IACzC,SAAS,SAAS,KAAK,MAAM,QAAQ,GAAG;GAC1C,CAAC;GACD,KAAK,eAAe,GAAG,IAAI;EAC7B;CACF;CACA,eAAe,GAAG,MAAM;EACtB,KAAK,WAAW,SAAS,aAAa,SAAS,GAAG,IAAI,CAAC;CACzD;AACF"}
1
+ {"version":3,"file":"AnimatedEvent.js","names":[],"sources":["esm/vendor/react-native/Animated/AnimatedEvent.js"],"sourcesContent":["import { AnimatedValue } from \"./nodes/AnimatedValue\";\nimport { NativeAnimatedHelper } from \"./NativeAnimatedHelper\";\nimport { invariant } from \"@tamagui/react-native-web-internals\";\nimport { shouldUseNativeDriver } from \"./NativeAnimatedHelper\";\nconst __DEV__ = process.env.NODE_ENV !== \"production\";\nfunction attachNativeEvent(viewRef, eventName, argMapping) {\n const eventMappings = [];\n const traverse = (value, path) => {\n if (value instanceof AnimatedValue) {\n value.__makeNative();\n eventMappings.push({\n nativeEventPath: path,\n animatedValueTag: value.__getNativeTag()\n });\n } else if (typeof value === \"object\") {\n for (const key in value) {\n traverse(value[key], path.concat(key));\n }\n }\n };\n invariant(\n argMapping[0] && argMapping[0].nativeEvent,\n \"Native driven events only support animated values contained inside `nativeEvent`.\"\n );\n traverse(argMapping[0].nativeEvent, []);\n if (viewRef != null) {\n eventMappings.forEach((mapping) => {\n NativeAnimatedHelper.API.addAnimatedEventToView(viewRef, eventName, mapping);\n });\n }\n return {\n detach() {\n if (viewRef != null) {\n eventMappings.forEach((mapping) => {\n NativeAnimatedHelper.API.removeAnimatedEventFromView(\n viewRef,\n eventName,\n mapping.animatedValueTag\n );\n });\n }\n }\n };\n}\nfunction validateMapping(argMapping, args) {\n const validate = (recMapping, recEvt, key) => {\n if (recMapping instanceof AnimatedValue) {\n invariant(\n typeof recEvt === \"number\",\n \"Bad mapping of event key \" + key + \", should be number but got \" + typeof recEvt\n );\n return;\n }\n if (typeof recEvt === \"number\") {\n invariant(\n recMapping instanceof AnimatedValue,\n \"Bad mapping of type \" + typeof recMapping + \" for key \" + key + \", event value must map to AnimatedValue\"\n );\n return;\n }\n invariant(\n typeof recMapping === \"object\",\n \"Bad mapping of type \" + typeof recMapping + \" for key \" + key\n );\n invariant(\n typeof recEvt === \"object\",\n \"Bad event of type \" + typeof recEvt + \" for key \" + key\n );\n for (const mappingKey in recMapping) {\n validate(recMapping[mappingKey], recEvt[mappingKey], mappingKey);\n }\n };\n invariant(args.length >= argMapping.length, \"Event has less arguments than mapping\");\n argMapping.forEach((mapping, idx) => {\n validate(mapping, args[idx], \"arg\" + idx);\n });\n}\nclass AnimatedEvent {\n _argMapping;\n _listeners = [];\n _attachedEvent;\n __isNative;\n constructor(argMapping, config) {\n this._argMapping = argMapping;\n if (config == null) {\n console.warn(\"Animated.event now requires a second argument for options\");\n config = { useNativeDriver: false };\n }\n if (config.listener) {\n this.__addListener(config.listener);\n }\n this._callListeners = this._callListeners.bind(this);\n this._attachedEvent = null;\n this.__isNative = shouldUseNativeDriver(config);\n }\n __addListener(callback) {\n this._listeners.push(callback);\n }\n __removeListener(callback) {\n this._listeners = this._listeners.filter((listener) => listener !== callback);\n }\n __attach(viewRef, eventName) {\n invariant(this.__isNative, \"Only native driven events need to be attached.\");\n this._attachedEvent = attachNativeEvent(viewRef, eventName, this._argMapping);\n }\n __detach(viewTag, eventName) {\n invariant(this.__isNative, \"Only native driven events need to be detached.\");\n this._attachedEvent && this._attachedEvent.detach();\n }\n __getHandler() {\n if (this.__isNative) {\n if (__DEV__) {\n let validatedMapping2 = false;\n return (...args) => {\n if (!validatedMapping2) {\n validateMapping(this._argMapping, args);\n validatedMapping2 = true;\n }\n this._callListeners(...args);\n };\n } else {\n return this._callListeners;\n }\n }\n let validatedMapping = false;\n return (...args) => {\n if (__DEV__ && !validatedMapping) {\n validateMapping(this._argMapping, args);\n validatedMapping = true;\n }\n const traverse = (recMapping, recEvt, key) => {\n if (recMapping instanceof AnimatedValue) {\n if (typeof recEvt === \"number\") {\n recMapping.setValue(recEvt);\n }\n } else if (typeof recMapping === \"object\") {\n for (const mappingKey in recMapping) {\n traverse(recMapping[mappingKey], recEvt[mappingKey], mappingKey);\n }\n }\n };\n this._argMapping.forEach((mapping, idx) => {\n traverse(mapping, args[idx], \"arg\" + idx);\n });\n this._callListeners(...args);\n };\n }\n _callListeners(...args) {\n this._listeners.forEach((listener) => listener(...args));\n }\n}\nexport {\n AnimatedEvent,\n attachNativeEvent\n};\n//# sourceMappingURL=AnimatedEvent.js.map\n"],"mappings":";;;;;AAIA,MAAM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,QAAQ;IAC5C,IAAI,sBAAsB,eAAe;KACvC,IAAI,OAAO,WAAW,UAAU;MAC9B,WAAW,SAAS,MAAM;KAC5B;IACF,OAAO,IAAI,OAAO,eAAe,UAAU;KACzC,KAAK,MAAM,cAAc,YAAY;MACnC,SAAS,WAAW,aAAa,OAAO,aAAa,UAAU;KACjE;IACF;GACF;GACA,KAAK,YAAY,SAAS,SAAS,QAAQ;IACzC,SAAS,SAAS,KAAK,MAAM,QAAQ,GAAG;GAC1C,CAAC;GACD,KAAK,eAAe,GAAG,IAAI;EAC7B;CACF;CACA,eAAe,GAAG,MAAM;EACtB,KAAK,WAAW,SAAS,aAAa,SAAS,GAAG,IAAI,CAAC;CACzD;AACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"AnimatedImplementation.js","names":[],"sources":["esm/vendor/react-native/Animated/AnimatedImplementation.js"],"sourcesContent":["import { AnimatedEvent, attachNativeEvent } from \"./AnimatedEvent\";\nimport { DecayAnimation } from \"./animations/DecayAnimation\";\nimport { SpringAnimation } from \"./animations/SpringAnimation\";\nimport { TimingAnimation } from \"./animations/TimingAnimation\";\nimport { AnimatedAddition } from \"./nodes/AnimatedAddition\";\nimport { AnimatedDiffClamp } from \"./nodes/AnimatedDiffClamp\";\nimport { AnimatedDivision } from \"./nodes/AnimatedDivision\";\nimport { AnimatedInterpolation } from \"./nodes/AnimatedInterpolation\";\nimport { AnimatedModulo } from \"./nodes/AnimatedModulo\";\nimport { AnimatedMultiplication } from \"./nodes/AnimatedMultiplication\";\nimport { AnimatedNode } from \"./nodes/AnimatedNode\";\nimport { AnimatedSubtraction } from \"./nodes/AnimatedSubtraction\";\nimport { AnimatedTracking } from \"./nodes/AnimatedTracking\";\nimport { AnimatedValue } from \"./nodes/AnimatedValue\";\nimport { AnimatedValueXY } from \"./nodes/AnimatedValueXY\";\nimport { createAnimatedComponent } from \"./createAnimatedComponent\";\nimport { AnimatedColor } from \"./nodes/AnimatedColor\";\nconst add = function(a, b) {\n return new AnimatedAddition(a, b);\n};\nconst subtract = function(a, b) {\n return new AnimatedSubtraction(a, b);\n};\nconst divide = function(a, b) {\n return new AnimatedDivision(a, b);\n};\nconst multiply = function(a, b) {\n return new AnimatedMultiplication(a, b);\n};\nconst modulo = function(a, modulus) {\n return new AnimatedModulo(a, modulus);\n};\nconst diffClamp = function(a, min, max) {\n return new AnimatedDiffClamp(a, min, max);\n};\nconst _combineCallbacks = function(callback, config) {\n if (callback && config.onComplete) {\n return (...args) => {\n config.onComplete && config.onComplete(...args);\n callback && callback(...args);\n };\n } else {\n return callback || config.onComplete;\n }\n};\nconst maybeVectorAnim = function(value, config, anim) {\n if (value instanceof AnimatedValueXY) {\n const configX = { ...config };\n const configY = { ...config };\n for (const key in config) {\n const { x, y } = config[key];\n if (x !== void 0 && y !== void 0) {\n configX[key] = x;\n configY[key] = y;\n }\n }\n const aX = anim(value.x, configX);\n const aY = anim(value.y, configY);\n return parallel([aX, aY], { stopTogether: false });\n } else if (value instanceof AnimatedColor) {\n const configR = { ...config };\n const configG = { ...config };\n const configB = { ...config };\n const configA = { ...config };\n for (const key in config) {\n const { r, g, b, a } = config[key];\n if (r !== void 0 && g !== void 0 && b !== void 0 && a !== void 0) {\n configR[key] = r;\n configG[key] = g;\n configB[key] = b;\n configA[key] = a;\n }\n }\n const aR = anim(value.r, configR);\n const aG = anim(value.g, configG);\n const aB = anim(value.b, configB);\n const aA = anim(value.a, configA);\n return parallel([aR, aG, aB, aA], { stopTogether: false });\n }\n return null;\n};\nconst spring = function(value, config) {\n const start = function(animatedValue, configuration, callback) {\n callback = _combineCallbacks(callback, configuration);\n const singleValue = animatedValue;\n const singleConfig = configuration;\n singleValue.stopTracking();\n if (configuration.toValue instanceof AnimatedNode) {\n singleValue.track(\n new AnimatedTracking(\n singleValue,\n configuration.toValue,\n SpringAnimation,\n singleConfig,\n callback\n )\n );\n } else {\n singleValue.animate(new SpringAnimation(singleConfig), callback);\n }\n };\n return maybeVectorAnim(value, config, spring) || {\n start: function(callback) {\n start(value, config, callback);\n },\n stop: function() {\n value.stopAnimation();\n },\n reset: function() {\n value.resetAnimation();\n },\n _startNativeLoop: function(iterations) {\n const singleConfig = { ...config, iterations };\n start(value, singleConfig);\n },\n _isUsingNativeDriver: function() {\n return config.useNativeDriver || false;\n }\n };\n};\nconst timing = function(value, config) {\n const start = function(animatedValue, configuration, callback) {\n callback = _combineCallbacks(callback, configuration);\n const singleValue = animatedValue;\n const singleConfig = configuration;\n singleValue.stopTracking();\n if (configuration.toValue instanceof AnimatedNode) {\n singleValue.track(\n new AnimatedTracking(\n singleValue,\n configuration.toValue,\n TimingAnimation,\n singleConfig,\n callback\n )\n );\n } else {\n singleValue.animate(new TimingAnimation(singleConfig), callback);\n }\n };\n return maybeVectorAnim(value, config, timing) || {\n start: function(callback) {\n start(value, config, callback);\n },\n stop: function() {\n value.stopAnimation();\n },\n reset: function() {\n value.resetAnimation();\n },\n _startNativeLoop: function(iterations) {\n const singleConfig = { ...config, iterations };\n start(value, singleConfig);\n },\n _isUsingNativeDriver: function() {\n return config.useNativeDriver || false;\n }\n };\n};\nconst decay = function(value, config) {\n const start = function(animatedValue, configuration, callback) {\n callback = _combineCallbacks(callback, configuration);\n const singleValue = animatedValue;\n const singleConfig = configuration;\n singleValue.stopTracking();\n singleValue.animate(new DecayAnimation(singleConfig), callback);\n };\n return maybeVectorAnim(value, config, decay) || {\n start: function(callback) {\n start(value, config, callback);\n },\n stop: function() {\n value.stopAnimation();\n },\n reset: function() {\n value.resetAnimation();\n },\n _startNativeLoop: function(iterations) {\n const singleConfig = { ...config, iterations };\n start(value, singleConfig);\n },\n _isUsingNativeDriver: function() {\n return config.useNativeDriver || false;\n }\n };\n};\nconst sequence = function(animations) {\n let current = 0;\n return {\n start: function(callback) {\n const onComplete = function(result) {\n if (!result.finished) {\n callback && callback(result);\n return;\n }\n current++;\n if (current === animations.length) {\n callback && callback(result);\n return;\n }\n animations[current].start(onComplete);\n };\n if (animations.length === 0) {\n callback && callback({ finished: true });\n } else {\n animations[current].start(onComplete);\n }\n },\n stop: function() {\n if (current < animations.length) {\n animations[current].stop();\n }\n },\n reset: function() {\n animations.forEach((animation, idx) => {\n if (idx <= current) {\n animation.reset();\n }\n });\n current = 0;\n },\n _startNativeLoop: function() {\n throw new Error(\n \"Loops run using the native driver cannot contain Animated.sequence animations\"\n );\n },\n _isUsingNativeDriver: function() {\n return false;\n }\n };\n};\nconst parallel = function(animations, config) {\n let doneCount = 0;\n const hasEnded = {};\n const stopTogether = !(config && config.stopTogether === false);\n const result = {\n start: function(callback) {\n if (doneCount === animations.length) {\n callback && callback({ finished: true });\n return;\n }\n animations.forEach((animation, idx) => {\n const cb = function(endResult) {\n hasEnded[idx] = true;\n doneCount++;\n if (doneCount === animations.length) {\n doneCount = 0;\n callback && callback(endResult);\n return;\n }\n if (!endResult.finished && stopTogether) {\n result.stop();\n }\n };\n if (!animation) {\n cb({ finished: true });\n } else {\n animation.start(cb);\n }\n });\n },\n stop: function() {\n animations.forEach((animation, idx) => {\n !hasEnded[idx] && animation.stop();\n hasEnded[idx] = true;\n });\n },\n reset: function() {\n animations.forEach((animation, idx) => {\n animation.reset();\n hasEnded[idx] = false;\n doneCount = 0;\n });\n },\n _startNativeLoop: function() {\n throw new Error(\n \"Loops run using the native driver cannot contain Animated.parallel animations\"\n );\n },\n _isUsingNativeDriver: function() {\n return false;\n }\n };\n return result;\n};\nconst delay = function(time) {\n return timing(new AnimatedValue(0), {\n toValue: 0,\n delay: time,\n duration: 0,\n useNativeDriver: false\n });\n};\nconst stagger = function(time, animations) {\n return parallel(\n animations.map((animation, i) => {\n return sequence([delay(time * i), animation]);\n })\n );\n};\nconst loop = function(animation, { iterations = -1, resetBeforeIteration = true } = {}) {\n let isFinished = false;\n let iterationsSoFar = 0;\n return {\n start: function(callback) {\n const restart = function(result = { finished: true }) {\n if (isFinished || iterationsSoFar === iterations || result.finished === false) {\n callback && callback(result);\n } else {\n iterationsSoFar++;\n resetBeforeIteration && animation.reset();\n animation.start(restart);\n }\n };\n if (!animation || iterations === 0) {\n callback && callback({ finished: true });\n } else {\n if (animation._isUsingNativeDriver()) {\n animation._startNativeLoop(iterations);\n } else {\n restart();\n }\n }\n },\n stop: function() {\n isFinished = true;\n animation.stop();\n },\n reset: function() {\n iterationsSoFar = 0;\n isFinished = false;\n animation.reset();\n },\n _startNativeLoop: function() {\n throw new Error(\n \"Loops run using the native driver cannot contain Animated.loop animations\"\n );\n },\n _isUsingNativeDriver: function() {\n return animation._isUsingNativeDriver();\n }\n };\n};\nfunction forkEvent(event2, listener) {\n if (!event2) {\n return listener;\n } else if (event2 instanceof AnimatedEvent) {\n event2.__addListener(listener);\n return event2;\n } else {\n return (...args) => {\n typeof event2 === \"function\" && event2(...args);\n listener(...args);\n };\n }\n}\nfunction unforkEvent(event2, listener) {\n if (event2 && event2 instanceof AnimatedEvent) {\n event2.__removeListener(listener);\n }\n}\nconst event = function(argMapping, config) {\n const animatedEvent = new AnimatedEvent(argMapping, config);\n if (animatedEvent.__isNative) {\n return animatedEvent;\n } else {\n return animatedEvent.__getHandler();\n }\n};\nconst AnimatedImplementationExports = {\n /**\n * Standard value class for driving animations. Typically initialized with\n * `new Animated.Value(0);`\n *\n * See https://reactnative.dev/docs/animated#value\n */\n Value: AnimatedValue,\n /**\n * 2D value class for driving 2D animations, such as pan gestures.\n *\n * See https://reactnative.dev/docs/animatedvaluexy\n */\n ValueXY: AnimatedValueXY,\n /**\n * Value class for driving color animations.\n */\n Color: AnimatedColor,\n /**\n * Exported to use the Interpolation type in flow.\n *\n * See https://reactnative.dev/docs/animated#interpolation\n */\n Interpolation: AnimatedInterpolation,\n /**\n * Exported for ease of type checking. All animated values derive from this\n * class.\n *\n * See https://reactnative.dev/docs/animated#node\n */\n Node: AnimatedNode,\n /**\n * Animates a value from an initial velocity to zero based on a decay\n * coefficient.\n *\n * See https://reactnative.dev/docs/animated#decay\n */\n decay,\n /**\n * Animates a value along a timed easing curve. The Easing module has tons of\n * predefined curves, or you can use your own function.\n *\n * See https://reactnative.dev/docs/animated#timing\n */\n timing,\n /**\n * Animates a value according to an analytical spring model based on\n * damped harmonic oscillation.\n *\n * See https://reactnative.dev/docs/animated#spring\n */\n spring,\n /**\n * Creates a new Animated value composed from two Animated values added\n * together.\n *\n * See https://reactnative.dev/docs/animated#add\n */\n add,\n /**\n * Creates a new Animated value composed by subtracting the second Animated\n * value from the first Animated value.\n *\n * See https://reactnative.dev/docs/animated#subtract\n */\n subtract,\n /**\n * Creates a new Animated value composed by dividing the first Animated value\n * by the second Animated value.\n *\n * See https://reactnative.dev/docs/animated#divide\n */\n divide,\n /**\n * Creates a new Animated value composed from two Animated values multiplied\n * together.\n *\n * See https://reactnative.dev/docs/animated#multiply\n */\n multiply,\n /**\n * Creates a new Animated value that is the (non-negative) modulo of the\n * provided Animated value.\n *\n * See https://reactnative.dev/docs/animated#modulo\n */\n modulo,\n /**\n * Create a new Animated value that is limited between 2 values. It uses the\n * difference between the last value so even if the value is far from the\n * bounds it will start changing when the value starts getting closer again.\n *\n * See https://reactnative.dev/docs/animated#diffclamp\n */\n diffClamp,\n /**\n * Starts an animation after the given delay.\n *\n * See https://reactnative.dev/docs/animated#delay\n */\n delay,\n /**\n * Starts an array of animations in order, waiting for each to complete\n * before starting the next. If the current running animation is stopped, no\n * following animations will be started.\n *\n * See https://reactnative.dev/docs/animated#sequence\n */\n sequence,\n /**\n * Starts an array of animations all at the same time. By default, if one\n * of the animations is stopped, they will all be stopped. You can override\n * this with the `stopTogether` flag.\n *\n * See https://reactnative.dev/docs/animated#parallel\n */\n parallel,\n /**\n * Array of animations may run in parallel (overlap), but are started in\n * sequence with successive delays. Nice for doing trailing effects.\n *\n * See https://reactnative.dev/docs/animated#stagger\n */\n stagger,\n /**\n * Loops a given animation continuously, so that each time it reaches the\n * end, it resets and begins again from the start.\n *\n * See https://reactnative.dev/docs/animated#loop\n */\n loop,\n /**\n * Takes an array of mappings and extracts values from each arg accordingly,\n * then calls `setValue` on the mapped outputs.\n *\n * See https://reactnative.dev/docs/animated#event\n */\n event,\n /**\n * Make any React component Animatable. Used to create `Animated.View`, etc.\n *\n * See https://reactnative.dev/docs/animated#createanimatedcomponent\n */\n createAnimatedComponent,\n /**\n * Imperative API to attach an animated value to an event on a view. Prefer\n * using `Animated.event` with `useNativeDrive: true` if possible.\n *\n * See https://reactnative.dev/docs/animated#attachnativeevent\n */\n attachNativeEvent,\n /**\n * Advanced imperative API for snooping on animated events that are passed in\n * through props. Use values directly where possible.\n *\n * See https://reactnative.dev/docs/animated#forkevent\n */\n forkEvent,\n unforkEvent,\n /**\n * Expose Event class, so it can be used as a type for type checkers.\n */\n Event: AnimatedEvent\n};\nvar AnimatedImplementation_default = AnimatedImplementationExports;\nexport {\n AnimatedImplementationExports as AnimatedImplementation,\n AnimatedImplementationExports,\n AnimatedImplementation_default as default\n};\n//# sourceMappingURL=AnimatedImplementation.js.map\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAiBA,MAAM,MAAM,SAAS,GAAG,GAAG;CACzB,OAAO,IAAI,iBAAiB,GAAG,CAAC;AAClC;AACA,MAAM,WAAW,SAAS,GAAG,GAAG;CAC9B,OAAO,IAAI,oBAAoB,GAAG,CAAC;AACrC;AACA,MAAM,SAAS,SAAS,GAAG,GAAG;CAC5B,OAAO,IAAI,iBAAiB,GAAG,CAAC;AAClC;AACA,MAAM,WAAW,SAAS,GAAG,GAAG;CAC9B,OAAO,IAAI,uBAAuB,GAAG,CAAC;AACxC;AACA,MAAM,SAAS,SAAS,GAAG,SAAS;CAClC,OAAO,IAAI,eAAe,GAAG,OAAO;AACtC;AACA,MAAM,YAAY,SAAS,GAAG,KAAK,KAAK;CACtC,OAAO,IAAI,kBAAkB,GAAG,KAAK,GAAG;AAC1C;AACA,MAAM,oBAAoB,SAAS,UAAU,QAAQ;CACnD,IAAI,YAAY,OAAO,YAAY;EACjC,QAAQ,GAAG,SAAS;GAClB,OAAO,cAAc,OAAO,WAAW,GAAG,IAAI;GAC9C,YAAY,SAAS,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ACF;AACF;AACA,SAAS,YAAY,QAAQ,UAAU;CACrC,IAAI,UAAU,kBAAkB,eAAe;EAC7C,OAAO,iBAAiB,QAAQ;CAClC;AACF;AACA,MAAM,QAAQ,SAAS,YAAY,QAAQ;CACzC,MAAM,gBAAgB,IAAI,cAAc,YAAY,MAAM;CAC1D,IAAI,cAAc,YAAY;EAC5B,OAAO;CACT,OAAO;EACL,OAAO,cAAc,aAAa;CACpC;AACF;AACA,MAAM,gCAAgC;;;;;;;CAOpC,OAAO;;;;;;CAMP,SAAS;;;;CAIT,OAAO;;;;;;CAMP,eAAe;;;;;;;CAOf,MAAM;;;;;;;CAON;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;;CAQA;;;;;;CAMA;;;;;;;;CAQA;;;;;;;;CAQA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;CAMA;;;;;;;CAOA;;;;;;;CAOA;CACA;;;;CAIA,OAAO;AACT;AACA,IAAI,iCAAiC"}
1
+ {"version":3,"file":"AnimatedImplementation.js","names":[],"sources":["esm/vendor/react-native/Animated/AnimatedImplementation.js"],"sourcesContent":["import { AnimatedEvent, attachNativeEvent } from \"./AnimatedEvent\";\nimport { DecayAnimation } from \"./animations/DecayAnimation\";\nimport { SpringAnimation } from \"./animations/SpringAnimation\";\nimport { TimingAnimation } from \"./animations/TimingAnimation\";\nimport { AnimatedAddition } from \"./nodes/AnimatedAddition\";\nimport { AnimatedDiffClamp } from \"./nodes/AnimatedDiffClamp\";\nimport { AnimatedDivision } from \"./nodes/AnimatedDivision\";\nimport { AnimatedInterpolation } from \"./nodes/AnimatedInterpolation\";\nimport { AnimatedModulo } from \"./nodes/AnimatedModulo\";\nimport { AnimatedMultiplication } from \"./nodes/AnimatedMultiplication\";\nimport { AnimatedNode } from \"./nodes/AnimatedNode\";\nimport { AnimatedSubtraction } from \"./nodes/AnimatedSubtraction\";\nimport { AnimatedTracking } from \"./nodes/AnimatedTracking\";\nimport { AnimatedValue } from \"./nodes/AnimatedValue\";\nimport { AnimatedValueXY } from \"./nodes/AnimatedValueXY\";\nimport { createAnimatedComponent } from \"./createAnimatedComponent\";\nimport { AnimatedColor } from \"./nodes/AnimatedColor\";\nconst add = function(a, b) {\n return new AnimatedAddition(a, b);\n};\nconst subtract = function(a, b) {\n return new AnimatedSubtraction(a, b);\n};\nconst divide = function(a, b) {\n return new AnimatedDivision(a, b);\n};\nconst multiply = function(a, b) {\n return new AnimatedMultiplication(a, b);\n};\nconst modulo = function(a, modulus) {\n return new AnimatedModulo(a, modulus);\n};\nconst diffClamp = function(a, min, max) {\n return new AnimatedDiffClamp(a, min, max);\n};\nconst _combineCallbacks = function(callback, config) {\n if (callback && config.onComplete) {\n return (...args) => {\n config.onComplete && config.onComplete(...args);\n callback && callback(...args);\n };\n } else {\n return callback || config.onComplete;\n }\n};\nconst maybeVectorAnim = function(value, config, anim) {\n if (value instanceof AnimatedValueXY) {\n const configX = { ...config };\n const configY = { ...config };\n for (const key in config) {\n const { x, y } = config[key];\n if (x !== void 0 && y !== void 0) {\n configX[key] = x;\n configY[key] = y;\n }\n }\n const aX = anim(value.x, configX);\n const aY = anim(value.y, configY);\n return parallel([aX, aY], { stopTogether: false });\n } else if (value instanceof AnimatedColor) {\n const configR = { ...config };\n const configG = { ...config };\n const configB = { ...config };\n const configA = { ...config };\n for (const key in config) {\n const { r, g, b, a } = config[key];\n if (r !== void 0 && g !== void 0 && b !== void 0 && a !== void 0) {\n configR[key] = r;\n configG[key] = g;\n configB[key] = b;\n configA[key] = a;\n }\n }\n const aR = anim(value.r, configR);\n const aG = anim(value.g, configG);\n const aB = anim(value.b, configB);\n const aA = anim(value.a, configA);\n return parallel([aR, aG, aB, aA], { stopTogether: false });\n }\n return null;\n};\nconst spring = function(value, config) {\n const start = function(animatedValue, configuration, callback) {\n callback = _combineCallbacks(callback, configuration);\n const singleValue = animatedValue;\n const singleConfig = configuration;\n singleValue.stopTracking();\n if (configuration.toValue instanceof AnimatedNode) {\n singleValue.track(\n new AnimatedTracking(\n singleValue,\n configuration.toValue,\n SpringAnimation,\n singleConfig,\n callback\n )\n );\n } else {\n singleValue.animate(new SpringAnimation(singleConfig), callback);\n }\n };\n return maybeVectorAnim(value, config, spring) || {\n start: function(callback) {\n start(value, config, callback);\n },\n stop: function() {\n value.stopAnimation();\n },\n reset: function() {\n value.resetAnimation();\n },\n _startNativeLoop: function(iterations) {\n const singleConfig = { ...config, iterations };\n start(value, singleConfig);\n },\n _isUsingNativeDriver: function() {\n return config.useNativeDriver || false;\n }\n };\n};\nconst timing = function(value, config) {\n const start = function(animatedValue, configuration, callback) {\n callback = _combineCallbacks(callback, configuration);\n const singleValue = animatedValue;\n const singleConfig = configuration;\n singleValue.stopTracking();\n if (configuration.toValue instanceof AnimatedNode) {\n singleValue.track(\n new AnimatedTracking(\n singleValue,\n configuration.toValue,\n TimingAnimation,\n singleConfig,\n callback\n )\n );\n } else {\n singleValue.animate(new TimingAnimation(singleConfig), callback);\n }\n };\n return maybeVectorAnim(value, config, timing) || {\n start: function(callback) {\n start(value, config, callback);\n },\n stop: function() {\n value.stopAnimation();\n },\n reset: function() {\n value.resetAnimation();\n },\n _startNativeLoop: function(iterations) {\n const singleConfig = { ...config, iterations };\n start(value, singleConfig);\n },\n _isUsingNativeDriver: function() {\n return config.useNativeDriver || false;\n }\n };\n};\nconst decay = function(value, config) {\n const start = function(animatedValue, configuration, callback) {\n callback = _combineCallbacks(callback, configuration);\n const singleValue = animatedValue;\n const singleConfig = configuration;\n singleValue.stopTracking();\n singleValue.animate(new DecayAnimation(singleConfig), callback);\n };\n return maybeVectorAnim(value, config, decay) || {\n start: function(callback) {\n start(value, config, callback);\n },\n stop: function() {\n value.stopAnimation();\n },\n reset: function() {\n value.resetAnimation();\n },\n _startNativeLoop: function(iterations) {\n const singleConfig = { ...config, iterations };\n start(value, singleConfig);\n },\n _isUsingNativeDriver: function() {\n return config.useNativeDriver || false;\n }\n };\n};\nconst sequence = function(animations) {\n let current = 0;\n return {\n start: function(callback) {\n const onComplete = function(result) {\n if (!result.finished) {\n callback && callback(result);\n return;\n }\n current++;\n if (current === animations.length) {\n callback && callback(result);\n return;\n }\n animations[current].start(onComplete);\n };\n if (animations.length === 0) {\n callback && callback({ finished: true });\n } else {\n animations[current].start(onComplete);\n }\n },\n stop: function() {\n if (current < animations.length) {\n animations[current].stop();\n }\n },\n reset: function() {\n animations.forEach((animation, idx) => {\n if (idx <= current) {\n animation.reset();\n }\n });\n current = 0;\n },\n _startNativeLoop: function() {\n throw new Error(\n \"Loops run using the native driver cannot contain Animated.sequence animations\"\n );\n },\n _isUsingNativeDriver: function() {\n return false;\n }\n };\n};\nconst parallel = function(animations, config) {\n let doneCount = 0;\n const hasEnded = {};\n const stopTogether = !(config && config.stopTogether === false);\n const result = {\n start: function(callback) {\n if (doneCount === animations.length) {\n callback && callback({ finished: true });\n return;\n }\n animations.forEach((animation, idx) => {\n const cb = function(endResult) {\n hasEnded[idx] = true;\n doneCount++;\n if (doneCount === animations.length) {\n doneCount = 0;\n callback && callback(endResult);\n return;\n }\n if (!endResult.finished && stopTogether) {\n result.stop();\n }\n };\n if (!animation) {\n cb({ finished: true });\n } else {\n animation.start(cb);\n }\n });\n },\n stop: function() {\n animations.forEach((animation, idx) => {\n !hasEnded[idx] && animation.stop();\n hasEnded[idx] = true;\n });\n },\n reset: function() {\n animations.forEach((animation, idx) => {\n animation.reset();\n hasEnded[idx] = false;\n doneCount = 0;\n });\n },\n _startNativeLoop: function() {\n throw new Error(\n \"Loops run using the native driver cannot contain Animated.parallel animations\"\n );\n },\n _isUsingNativeDriver: function() {\n return false;\n }\n };\n return result;\n};\nconst delay = function(time) {\n return timing(new AnimatedValue(0), {\n toValue: 0,\n delay: time,\n duration: 0,\n useNativeDriver: false\n });\n};\nconst stagger = function(time, animations) {\n return parallel(\n animations.map((animation, i) => {\n return sequence([delay(time * i), animation]);\n })\n );\n};\nconst loop = function(animation, { iterations = -1, resetBeforeIteration = true } = {}) {\n let isFinished = false;\n let iterationsSoFar = 0;\n return {\n start: function(callback) {\n const restart = function(result = { finished: true }) {\n if (isFinished || iterationsSoFar === iterations || result.finished === false) {\n callback && callback(result);\n } else {\n iterationsSoFar++;\n resetBeforeIteration && animation.reset();\n animation.start(restart);\n }\n };\n if (!animation || iterations === 0) {\n callback && callback({ finished: true });\n } else {\n if (animation._isUsingNativeDriver()) {\n animation._startNativeLoop(iterations);\n } else {\n restart();\n }\n }\n },\n stop: function() {\n isFinished = true;\n animation.stop();\n },\n reset: function() {\n iterationsSoFar = 0;\n isFinished = false;\n animation.reset();\n },\n _startNativeLoop: function() {\n throw new Error(\n \"Loops run using the native driver cannot contain Animated.loop animations\"\n );\n },\n _isUsingNativeDriver: function() {\n return animation._isUsingNativeDriver();\n }\n };\n};\nfunction forkEvent(event2, listener) {\n if (!event2) {\n return listener;\n } else if (event2 instanceof AnimatedEvent) {\n event2.__addListener(listener);\n return event2;\n } else {\n return (...args) => {\n typeof event2 === \"function\" && event2(...args);\n listener(...args);\n };\n }\n}\nfunction unforkEvent(event2, listener) {\n if (event2 && event2 instanceof AnimatedEvent) {\n event2.__removeListener(listener);\n }\n}\nconst event = function(argMapping, config) {\n const animatedEvent = new AnimatedEvent(argMapping, config);\n if (animatedEvent.__isNative) {\n return animatedEvent;\n } else {\n return animatedEvent.__getHandler();\n }\n};\nconst AnimatedImplementationExports = {\n /**\n * Standard value class for driving animations. Typically initialized with\n * `new Animated.Value(0);`\n *\n * See https://reactnative.dev/docs/animated#value\n */\n Value: AnimatedValue,\n /**\n * 2D value class for driving 2D animations, such as pan gestures.\n *\n * See https://reactnative.dev/docs/animatedvaluexy\n */\n ValueXY: AnimatedValueXY,\n /**\n * Value class for driving color animations.\n */\n Color: AnimatedColor,\n /**\n * Exported to use the Interpolation type in flow.\n *\n * See https://reactnative.dev/docs/animated#interpolation\n */\n Interpolation: AnimatedInterpolation,\n /**\n * Exported for ease of type checking. All animated values derive from this\n * class.\n *\n * See https://reactnative.dev/docs/animated#node\n */\n Node: AnimatedNode,\n /**\n * Animates a value from an initial velocity to zero based on a decay\n * coefficient.\n *\n * See https://reactnative.dev/docs/animated#decay\n */\n decay,\n /**\n * Animates a value along a timed easing curve. The Easing module has tons of\n * predefined curves, or you can use your own function.\n *\n * See https://reactnative.dev/docs/animated#timing\n */\n timing,\n /**\n * Animates a value according to an analytical spring model based on\n * damped harmonic oscillation.\n *\n * See https://reactnative.dev/docs/animated#spring\n */\n spring,\n /**\n * Creates a new Animated value composed from two Animated values added\n * together.\n *\n * See https://reactnative.dev/docs/animated#add\n */\n add,\n /**\n * Creates a new Animated value composed by subtracting the second Animated\n * value from the first Animated value.\n *\n * See https://reactnative.dev/docs/animated#subtract\n */\n subtract,\n /**\n * Creates a new Animated value composed by dividing the first Animated value\n * by the second Animated value.\n *\n * See https://reactnative.dev/docs/animated#divide\n */\n divide,\n /**\n * Creates a new Animated value composed from two Animated values multiplied\n * together.\n *\n * See https://reactnative.dev/docs/animated#multiply\n */\n multiply,\n /**\n * Creates a new Animated value that is the (non-negative) modulo of the\n * provided Animated value.\n *\n * See https://reactnative.dev/docs/animated#modulo\n */\n modulo,\n /**\n * Create a new Animated value that is limited between 2 values. It uses the\n * difference between the last value so even if the value is far from the\n * bounds it will start changing when the value starts getting closer again.\n *\n * See https://reactnative.dev/docs/animated#diffclamp\n */\n diffClamp,\n /**\n * Starts an animation after the given delay.\n *\n * See https://reactnative.dev/docs/animated#delay\n */\n delay,\n /**\n * Starts an array of animations in order, waiting for each to complete\n * before starting the next. If the current running animation is stopped, no\n * following animations will be started.\n *\n * See https://reactnative.dev/docs/animated#sequence\n */\n sequence,\n /**\n * Starts an array of animations all at the same time. By default, if one\n * of the animations is stopped, they will all be stopped. You can override\n * this with the `stopTogether` flag.\n *\n * See https://reactnative.dev/docs/animated#parallel\n */\n parallel,\n /**\n * Array of animations may run in parallel (overlap), but are started in\n * sequence with successive delays. Nice for doing trailing effects.\n *\n * See https://reactnative.dev/docs/animated#stagger\n */\n stagger,\n /**\n * Loops a given animation continuously, so that each time it reaches the\n * end, it resets and begins again from the start.\n *\n * See https://reactnative.dev/docs/animated#loop\n */\n loop,\n /**\n * Takes an array of mappings and extracts values from each arg accordingly,\n * then calls `setValue` on the mapped outputs.\n *\n * See https://reactnative.dev/docs/animated#event\n */\n event,\n /**\n * Make any React component Animatable. Used to create `Animated.View`, etc.\n *\n * See https://reactnative.dev/docs/animated#createanimatedcomponent\n */\n createAnimatedComponent,\n /**\n * Imperative API to attach an animated value to an event on a view. Prefer\n * using `Animated.event` with `useNativeDrive: true` if possible.\n *\n * See https://reactnative.dev/docs/animated#attachnativeevent\n */\n attachNativeEvent,\n /**\n * Advanced imperative API for snooping on animated events that are passed in\n * through props. Use values directly where possible.\n *\n * See https://reactnative.dev/docs/animated#forkevent\n */\n forkEvent,\n unforkEvent,\n /**\n * Expose Event class, so it can be used as a type for type checkers.\n */\n Event: AnimatedEvent\n};\nvar AnimatedImplementation_default = AnimatedImplementationExports;\nexport {\n AnimatedImplementationExports as AnimatedImplementation,\n AnimatedImplementationExports,\n AnimatedImplementation_default as default\n};\n//# sourceMappingURL=AnimatedImplementation.js.map\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAiBA,MAAM,MAAM,SAAS,GAAG,GAAG;CACzB,OAAO,IAAI,iBAAiB,GAAG,CAAC;AAClC;AACA,MAAM,WAAW,SAAS,GAAG,GAAG;CAC9B,OAAO,IAAI,oBAAoB,GAAG,CAAC;AACrC;AACA,MAAM,SAAS,SAAS,GAAG,GAAG;CAC5B,OAAO,IAAI,iBAAiB,GAAG,CAAC;AAClC;AACA,MAAM,WAAW,SAAS,GAAG,GAAG;CAC9B,OAAO,IAAI,uBAAuB,GAAG,CAAC;AACxC;AACA,MAAM,SAAS,SAAS,GAAG,SAAS;CAClC,OAAO,IAAI,eAAe,GAAG,OAAO;AACtC;AACA,MAAM,YAAY,SAAS,GAAG,KAAK,K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AU,QAAQ,UAAU;CACnC,IAAI,CAAC,QAAQ;EACX,OAAO;CACT,OAAO,IAAI,kBAAkB,eAAe;EAC1C,OAAO,cAAc,QAAQ;EAC7B,OAAO;CACT,OAAO;EACL,QAAQ,GAAG,SAAS;GAClB,OAAO,WAAW,cAAc,OAAO,GAAG,IAAI;GAC9C,SAAS,GAAG,IAAI;EAClB;CACF;AACF;AACA,SAAS,YAAY,QAAQ,UAAU;CACrC,IAAI,UAAU,kBAAkB,eAAe;EAC7C,OAAO,iBAAiB,QAAQ;CAClC;AACF;AACA,MAAM,QAAQ,SAAS,YAAY,QAAQ;CACzC,MAAM,gBAAgB,IAAI,cAAc,YAAY,MAAM;CAC1D,IAAI,cAAc,YAAY;EAC5B,OAAO;CACT,OAAO;EACL,OAAO,cAAc,aAAa;CACpC;AACF;AACA,MAAM,gCAAgC;;;;;;;CAOpC,OAAO;;;;;;CAMP,SAAS;;;;CAIT,OAAO;;;;;;CAMP,eAAe;;;;;;;CAOf,MAAM;;;;;;;CAON;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;;CAQA;;;;;;CAMA;;;;;;;;CAQA;;;;;;;;CAQA;;;;;;;CAOA;;;;;;;CAOA;;;;;;;CAOA;;;;;;CAMA;;;;;;;CAOA;;;;;;;CAOA;CACA;;;;CAIA,OAAO;AACT;AACA,IAAI,iCAAiC"}
@@ -1 +1 @@
1
- {"version":3,"file":"NativeAnimatedHelper.js","names":[],"sources":["esm/vendor/react-native/Animated/NativeAnimatedHelper.js"],"sourcesContent":["import { NativeAnimatedNonTurboModule } from \"./NativeAnimatedModule\";\nimport { NativeAnimatedTurboModule } from \"./NativeAnimatedTurboModule\";\nimport { NativeEventEmitter } from \"../EventEmitter/NativeEventEmitter\";\nimport { Platform } from \"../Utilities/Platform\";\nimport { ReactNativeFeatureFlags } from \"../ReactNative/ReactNativeFeatureFlags\";\nimport { invariant } from \"@tamagui/react-native-web-internals\";\nimport { RCTDeviceEventEmitter } from \"../EventEmitter/RCTDeviceEventEmitter\";\nconst NativeAnimatedModule = Platform.OS === \"ios\" && global.RN$Bridgeless === true ? NativeAnimatedTurboModule : NativeAnimatedNonTurboModule;\nlet __nativeAnimatedNodeTagCount = 1;\nlet __nativeAnimationIdCount = 1;\nlet nativeEventEmitter;\nlet waitingForQueuedOperations = /* @__PURE__ */ new Set();\nlet queueOperations = false;\nlet queue = [];\nlet singleOpQueue = [];\nconst useSingleOpBatching = false;\nPlatform.OS === \"android\" && !!NativeAnimatedModule?.queueAndExecuteBatchedOperations && ReactNativeFeatureFlags.animatedShouldUseSingleOp();\nlet flushQueueTimeout = null;\nconst eventListenerGetValueCallbacks = {};\nconst eventListenerAnimationFinishedCallbacks = {};\nconst nativeOps = useSingleOpBatching ? (function() {\n const apis = [\n \"createAnimatedNode\",\n // 1\n \"updateAnimatedNodeConfig\",\n // 2\n \"getValue\",\n // 3\n \"startListeningToAnimatedNodeValue\",\n // 4\n \"stopListeningToAnimatedNodeValue\",\n // 5\n \"connectAnimatedNodes\",\n // 6\n \"disconnectAnimatedNodes\",\n // 7\n \"startAnimatingNode\",\n // 8\n \"stopAnimation\",\n // 9\n \"setAnimatedNodeValue\",\n // 10\n \"setAnimatedNodeOffset\",\n // 11\n \"flattenAnimatedNodeOffset\",\n // 12\n \"extractAnimatedNodeOffset\",\n // 13\n \"connectAnimatedNodeToView\",\n // 14\n \"disconnectAnimatedNodeFromView\",\n // 15\n \"restoreDefaultValues\",\n // 16\n \"dropAnimatedNode\",\n // 17\n \"addAnimatedEventToView\",\n // 18\n \"removeAnimatedEventFromView\",\n // 19\n \"addListener\",\n // 20\n \"removeListener\"\n // 21\n ];\n return apis.reduce((acc, functionName, i) => {\n acc[functionName] = i + 1;\n return acc;\n }, {});\n})() : NativeAnimatedModule;\nconst API = {\n getValue: function(tag, saveValueCallback) {\n invariant(nativeOps, \"Native animated module is not available\");\n if (useSingleOpBatching) {\n if (saveValueCallback) {\n eventListenerGetValueCallbacks[tag] = saveValueCallback;\n }\n API.queueOperation(nativeOps.getValue, tag);\n } else {\n API.queueOperation(nativeOps.getValue, tag, saveValueCallback);\n }\n },\n setWaitingForIdentifier: function(id) {\n waitingForQueuedOperations.add(id);\n queueOperations = true;\n if (ReactNativeFeatureFlags.animatedShouldDebounceQueueFlush() && flushQueueTimeout) {\n clearTimeout(flushQueueTimeout);\n }\n },\n unsetWaitingForIdentifier: function(id) {\n waitingForQueuedOperations.delete(id);\n if (waitingForQueuedOperations.size === 0) {\n queueOperations = false;\n API.disableQueue();\n }\n },\n disableQueue: function() {\n invariant(nativeOps, \"Native animated module is not available\");\n if (ReactNativeFeatureFlags.animatedShouldDebounceQueueFlush()) {\n const prevTimeout = flushQueueTimeout;\n clearImmediate(prevTimeout);\n flushQueueTimeout = setImmediate(API.flushQueue);\n } else {\n API.flushQueue();\n }\n },\n flushQueue: function() {\n },\n queueOperation: (fn, ...args) => {\n if (useSingleOpBatching) {\n singleOpQueue.push(fn, ...args);\n return;\n }\n if (queueOperations || queue.length !== 0) {\n queue.push(() => fn(...args));\n } else {\n fn(...args);\n }\n },\n createAnimatedNode: function(tag, config) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.createAnimatedNode, tag, config);\n },\n updateAnimatedNodeConfig: function(tag, config) {\n invariant(nativeOps, \"Native animated module is not available\");\n },\n startListeningToAnimatedNodeValue: function(tag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.startListeningToAnimatedNodeValue, tag);\n },\n stopListeningToAnimatedNodeValue: function(tag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.stopListeningToAnimatedNodeValue, tag);\n },\n connectAnimatedNodes: function(parentTag, childTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.connectAnimatedNodes, parentTag, childTag);\n },\n disconnectAnimatedNodes: function(parentTag, childTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.disconnectAnimatedNodes, parentTag, childTag);\n },\n startAnimatingNode: function(animationId, nodeTag, config, endCallback) {\n invariant(nativeOps, \"Native animated module is not available\");\n if (useSingleOpBatching) {\n if (endCallback) {\n eventListenerAnimationFinishedCallbacks[animationId] = endCallback;\n }\n API.queueOperation(nativeOps.startAnimatingNode, animationId, nodeTag, config);\n } else {\n API.queueOperation(\n nativeOps.startAnimatingNode,\n animationId,\n nodeTag,\n config,\n endCallback\n );\n }\n },\n stopAnimation: function(animationId) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.stopAnimation, animationId);\n },\n setAnimatedNodeValue: function(nodeTag, value) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.setAnimatedNodeValue, nodeTag, value);\n },\n setAnimatedNodeOffset: function(nodeTag, offset) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.setAnimatedNodeOffset, nodeTag, offset);\n },\n flattenAnimatedNodeOffset: function(nodeTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.flattenAnimatedNodeOffset, nodeTag);\n },\n extractAnimatedNodeOffset: function(nodeTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.extractAnimatedNodeOffset, nodeTag);\n },\n connectAnimatedNodeToView: function(nodeTag, viewTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.connectAnimatedNodeToView, nodeTag, viewTag);\n },\n disconnectAnimatedNodeFromView: function(nodeTag, viewTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.disconnectAnimatedNodeFromView, nodeTag, viewTag);\n },\n restoreDefaultValues: function(nodeTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n if (nativeOps.restoreDefaultValues != null) {\n API.queueOperation(nativeOps.restoreDefaultValues, nodeTag);\n }\n },\n dropAnimatedNode: function(tag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.dropAnimatedNode, tag);\n },\n addAnimatedEventToView: function(viewTag, eventName, eventMapping) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.addAnimatedEventToView, viewTag, eventName, eventMapping);\n },\n removeAnimatedEventFromView(viewTag, eventName, animatedNodeTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(\n nativeOps.removeAnimatedEventFromView,\n viewTag,\n eventName,\n animatedNodeTag\n );\n }\n};\nconst SUPPORTED_COLOR_STYLES = {\n backgroundColor: true,\n borderBottomColor: true,\n borderColor: true,\n borderEndColor: true,\n borderLeftColor: true,\n borderRightColor: true,\n borderStartColor: true,\n borderTopColor: true,\n color: true,\n tintColor: true\n};\nconst SUPPORTED_STYLES = {\n ...SUPPORTED_COLOR_STYLES,\n borderBottomEndRadius: true,\n borderBottomLeftRadius: true,\n borderBottomRightRadius: true,\n borderBottomStartRadius: true,\n borderRadius: true,\n borderTopEndRadius: true,\n borderTopLeftRadius: true,\n borderTopRightRadius: true,\n borderTopStartRadius: true,\n elevation: true,\n opacity: true,\n transform: true,\n zIndex: true,\n /* ios styles */\n shadowOpacity: true,\n shadowRadius: true,\n /* legacy android transform properties */\n scaleX: true,\n scaleY: true,\n translateX: true,\n translateY: true\n};\nconst SUPPORTED_TRANSFORMS = {\n translateX: true,\n translateY: true,\n scale: true,\n scaleX: true,\n scaleY: true,\n rotate: true,\n rotateX: true,\n rotateY: true,\n rotateZ: true,\n perspective: true\n};\nconst SUPPORTED_INTERPOLATION_PARAMS = {\n inputRange: true,\n outputRange: true,\n extrapolate: true,\n extrapolateRight: true,\n extrapolateLeft: true\n};\nfunction addWhitelistedStyleProp(prop) {\n SUPPORTED_STYLES[prop] = true;\n}\nfunction addWhitelistedTransformProp(prop) {\n SUPPORTED_TRANSFORMS[prop] = true;\n}\nfunction addWhitelistedInterpolationParam(param) {\n SUPPORTED_INTERPOLATION_PARAMS[param] = true;\n}\nfunction isSupportedColorStyleProp(prop) {\n return SUPPORTED_COLOR_STYLES.hasOwnProperty(prop);\n}\nfunction isSupportedStyleProp(prop) {\n return SUPPORTED_STYLES.hasOwnProperty(prop);\n}\nfunction isSupportedTransformProp(prop) {\n return SUPPORTED_TRANSFORMS.hasOwnProperty(prop);\n}\nfunction isSupportedInterpolationParam(param) {\n return SUPPORTED_INTERPOLATION_PARAMS.hasOwnProperty(param);\n}\nfunction validateTransform(configs) {\n configs.forEach((config) => {\n if (!isSupportedTransformProp(config.property)) {\n throw new Error(\n `Property '${config.property}' is not supported by native animated module`\n );\n }\n });\n}\nfunction validateStyles(styles) {\n for (const key in styles) {\n if (!isSupportedStyleProp(key)) {\n throw new Error(\n `Style property '${key}' is not supported by native animated module`\n );\n }\n }\n}\nfunction validateInterpolation(config) {\n for (const key in config) {\n if (!isSupportedInterpolationParam(key)) {\n throw new Error(\n `Interpolation property '${key}' is not supported by native animated module`\n );\n }\n }\n}\nfunction generateNewNodeTag() {\n return __nativeAnimatedNodeTagCount++;\n}\nfunction generateNewAnimationId() {\n return __nativeAnimationIdCount++;\n}\nfunction assertNativeAnimatedModule() {\n invariant(NativeAnimatedModule, \"Native animated module is not available\");\n}\nlet _warnedMissingNativeAnimated = false;\nfunction shouldUseNativeDriver(config) {\n if (config.useNativeDriver == null) {\n console.warn(\n \"Animated: `useNativeDriver` was not specified. This is a required option and must be explicitly set to `true` or `false`\"\n );\n }\n if (config.useNativeDriver === true && !NativeAnimatedModule) {\n if (!_warnedMissingNativeAnimated) {\n console.warn(\n \"Animated: `useNativeDriver` is not supported because the native animated module is missing. Falling back to JS-based animation. To resolve this, add `RCTAnimation` module to this app, or remove `useNativeDriver`. Make sure to run `bundle exec pod install` first. Read more about autolinking: https://github.com/react-native-community/cli/blob/master/docs/autolinking.md\"\n );\n _warnedMissingNativeAnimated = true;\n }\n return false;\n }\n return config.useNativeDriver || false;\n}\nfunction transformDataType(value) {\n if (typeof value !== \"string\") {\n return value;\n }\n if (/deg$/.test(value)) {\n const degrees = parseFloat(value) || 0;\n const radians = degrees * Math.PI / 180;\n return radians;\n } else {\n return value;\n }\n}\nconst NativeAnimatedHelper = {\n API,\n isSupportedColorStyleProp,\n isSupportedStyleProp,\n isSupportedTransformProp,\n isSupportedInterpolationParam,\n addWhitelistedStyleProp,\n addWhitelistedTransformProp,\n addWhitelistedInterpolationParam,\n validateStyles,\n validateTransform,\n validateInterpolation,\n generateNewNodeTag,\n generateNewAnimationId,\n assertNativeAnimatedModule,\n shouldUseNativeDriver,\n transformDataType,\n get nativeEventEmitter() {\n if (!nativeEventEmitter) {\n nativeEventEmitter = new NativeEventEmitter(\n // T88715063: NativeEventEmitter only used this parameter on iOS. Now it uses it on all platforms, so this code was modified automatically to preserve its behavior\n // If you want to use the native module on other platforms, please remove this condition and test its behavior\n Platform.OS !== \"ios\" ? null : NativeAnimatedModule\n );\n }\n return nativeEventEmitter;\n }\n};\nvar NativeAnimatedHelper_default = NativeAnimatedHelper;\nexport {\n API,\n NativeAnimatedHelper,\n addWhitelistedInterpolationParam,\n addWhitelistedStyleProp,\n addWhitelistedTransformProp,\n assertNativeAnimatedModule,\n NativeAnimatedHelper_default as default,\n generateNewAnimationId,\n generateNewNodeTag,\n isSupportedColorStyleProp,\n isSupportedInterpolationParam,\n isSupportedStyleProp,\n isSupportedTransformProp,\n shouldUseNativeDriver,\n transformDataType,\n validateInterpolation,\n validateStyles,\n validateTransform\n};\n//# sourceMappingURL=NativeAnimatedHelper.js.map\n"],"mappings":";;;;;;;;;AAOA,MAAM,uBAAuB,SAAS,OAAO,SAAS,OAAO,kBAAkB,OAAO,4BAA4B;AAClH,IAAI,+BAA+B;AACnC,IAAI,2BAA2B;AAC/B,IAAI;AACJ,IAAI,6CAA6C,IAAI,IAAI;AACzD,IAAI,kBAAkB;AACtB,IAAI,QAAQ,CAAC;AACb,IAAI,gBAAgB,CAAC;AACrB,MAAM,sBAAsB;AAC5B,SAAS,OAAO,aAAa,CAAC,CA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G,GAAG;GACvC,MAAM,IAAI,MACR,2BAA2B,IAAI,6CACjC;EACF;CACF;AACF;AACA,SAAS,qBAAqB;CAC5B,OAAO;AACT;AACA,SAAS,yBAAyB;CAChC,OAAO;AACT;AACA,SAAS,6BAA6B;CACpC,UAAU,sBAAsB,yCAAyC;AAC3E;AACA,IAAI,+BAA+B;AACnC,SAAS,sBAAsB,QAAQ;CACrC,IAAI,OAAO,mBAAmB,MAAM;EAClC,QAAQ,KACN,0HACF;CACF;CACA,IAAI,OAAO,oBAAoB,QAAQ,CAAC,sBAAsB;EAC5D,IAAI,CAAC,8BAA8B;GACjC,QAAQ,KACN,mXACF;GACA,+BAA+B;EACjC;EACA,OAAO;CACT;CACA,OAAO,OAAO,mBAAmB;AACnC;AACA,SAAS,kBAAkB,OAAO;CAChC,IAAI,OAAO,UAAU,UAAU;EAC7B,OAAO;CACT;CACA,IAAI,OAAO,KAAK,KAAK,GAAG;EACtB,MAAM,UAAU,WAAW,KAAK,KAAK;EACrC,MAAM,UAAU,UAAU,KAAK,KAAK;EACpC,OAAO;CACT,OAAO;EACL,OAAO;CACT;AACF;AACA,MAAM,uBAAuB;CAC3B;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA,IAAI,qBAAqB;EACvB,IAAI,CAAC,oBAAoB;GACvB,qBAAqB,IAAI,mBAGvB,SAAS,OAAO,QAAQ,OAAO,oBACjC;EACF;EACA,OAAO;CACT;AACF;AACA,IAAI,+BAA+B"}
1
+ {"version":3,"file":"NativeAnimatedHelper.js","names":[],"sources":["esm/vendor/react-native/Animated/NativeAnimatedHelper.js"],"sourcesContent":["import { NativeAnimatedNonTurboModule } from \"./NativeAnimatedModule\";\nimport { NativeAnimatedTurboModule } from \"./NativeAnimatedTurboModule\";\nimport { NativeEventEmitter } from \"../EventEmitter/NativeEventEmitter\";\nimport { Platform } from \"../Utilities/Platform\";\nimport { ReactNativeFeatureFlags } from \"../ReactNative/ReactNativeFeatureFlags\";\nimport { invariant } from \"@tamagui/react-native-web-internals\";\nimport { RCTDeviceEventEmitter } from \"../EventEmitter/RCTDeviceEventEmitter\";\nconst NativeAnimatedModule = Platform.OS === \"ios\" && global.RN$Bridgeless === true ? NativeAnimatedTurboModule : NativeAnimatedNonTurboModule;\nlet __nativeAnimatedNodeTagCount = 1;\nlet __nativeAnimationIdCount = 1;\nlet nativeEventEmitter;\nlet waitingForQueuedOperations = /* @__PURE__ */ new Set();\nlet queueOperations = false;\nlet queue = [];\nlet singleOpQueue = [];\nconst useSingleOpBatching = false;\nPlatform.OS === \"android\" && !!NativeAnimatedModule?.queueAndExecuteBatchedOperations && ReactNativeFeatureFlags.animatedShouldUseSingleOp();\nlet flushQueueTimeout = null;\nconst eventListenerGetValueCallbacks = {};\nconst eventListenerAnimationFinishedCallbacks = {};\nconst nativeOps = useSingleOpBatching ? (function() {\n const apis = [\n \"createAnimatedNode\",\n // 1\n \"updateAnimatedNodeConfig\",\n // 2\n \"getValue\",\n // 3\n \"startListeningToAnimatedNodeValue\",\n // 4\n \"stopListeningToAnimatedNodeValue\",\n // 5\n \"connectAnimatedNodes\",\n // 6\n \"disconnectAnimatedNodes\",\n // 7\n \"startAnimatingNode\",\n // 8\n \"stopAnimation\",\n // 9\n \"setAnimatedNodeValue\",\n // 10\n \"setAnimatedNodeOffset\",\n // 11\n \"flattenAnimatedNodeOffset\",\n // 12\n \"extractAnimatedNodeOffset\",\n // 13\n \"connectAnimatedNodeToView\",\n // 14\n \"disconnectAnimatedNodeFromView\",\n // 15\n \"restoreDefaultValues\",\n // 16\n \"dropAnimatedNode\",\n // 17\n \"addAnimatedEventToView\",\n // 18\n \"removeAnimatedEventFromView\",\n // 19\n \"addListener\",\n // 20\n \"removeListener\"\n // 21\n ];\n return apis.reduce((acc, functionName, i) => {\n acc[functionName] = i + 1;\n return acc;\n }, {});\n})() : NativeAnimatedModule;\nconst API = {\n getValue: function(tag, saveValueCallback) {\n invariant(nativeOps, \"Native animated module is not available\");\n if (useSingleOpBatching) {\n if (saveValueCallback) {\n eventListenerGetValueCallbacks[tag] = saveValueCallback;\n }\n API.queueOperation(nativeOps.getValue, tag);\n } else {\n API.queueOperation(nativeOps.getValue, tag, saveValueCallback);\n }\n },\n setWaitingForIdentifier: function(id) {\n waitingForQueuedOperations.add(id);\n queueOperations = true;\n if (ReactNativeFeatureFlags.animatedShouldDebounceQueueFlush() && flushQueueTimeout) {\n clearTimeout(flushQueueTimeout);\n }\n },\n unsetWaitingForIdentifier: function(id) {\n waitingForQueuedOperations.delete(id);\n if (waitingForQueuedOperations.size === 0) {\n queueOperations = false;\n API.disableQueue();\n }\n },\n disableQueue: function() {\n invariant(nativeOps, \"Native animated module is not available\");\n if (ReactNativeFeatureFlags.animatedShouldDebounceQueueFlush()) {\n const prevTimeout = flushQueueTimeout;\n clearImmediate(prevTimeout);\n flushQueueTimeout = setImmediate(API.flushQueue);\n } else {\n API.flushQueue();\n }\n },\n flushQueue: function() {\n },\n queueOperation: (fn, ...args) => {\n if (useSingleOpBatching) {\n singleOpQueue.push(fn, ...args);\n return;\n }\n if (queueOperations || queue.length !== 0) {\n queue.push(() => fn(...args));\n } else {\n fn(...args);\n }\n },\n createAnimatedNode: function(tag, config) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.createAnimatedNode, tag, config);\n },\n updateAnimatedNodeConfig: function(tag, config) {\n invariant(nativeOps, \"Native animated module is not available\");\n },\n startListeningToAnimatedNodeValue: function(tag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.startListeningToAnimatedNodeValue, tag);\n },\n stopListeningToAnimatedNodeValue: function(tag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.stopListeningToAnimatedNodeValue, tag);\n },\n connectAnimatedNodes: function(parentTag, childTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.connectAnimatedNodes, parentTag, childTag);\n },\n disconnectAnimatedNodes: function(parentTag, childTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.disconnectAnimatedNodes, parentTag, childTag);\n },\n startAnimatingNode: function(animationId, nodeTag, config, endCallback) {\n invariant(nativeOps, \"Native animated module is not available\");\n if (useSingleOpBatching) {\n if (endCallback) {\n eventListenerAnimationFinishedCallbacks[animationId] = endCallback;\n }\n API.queueOperation(nativeOps.startAnimatingNode, animationId, nodeTag, config);\n } else {\n API.queueOperation(\n nativeOps.startAnimatingNode,\n animationId,\n nodeTag,\n config,\n endCallback\n );\n }\n },\n stopAnimation: function(animationId) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.stopAnimation, animationId);\n },\n setAnimatedNodeValue: function(nodeTag, value) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.setAnimatedNodeValue, nodeTag, value);\n },\n setAnimatedNodeOffset: function(nodeTag, offset) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.setAnimatedNodeOffset, nodeTag, offset);\n },\n flattenAnimatedNodeOffset: function(nodeTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.flattenAnimatedNodeOffset, nodeTag);\n },\n extractAnimatedNodeOffset: function(nodeTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.extractAnimatedNodeOffset, nodeTag);\n },\n connectAnimatedNodeToView: function(nodeTag, viewTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.connectAnimatedNodeToView, nodeTag, viewTag);\n },\n disconnectAnimatedNodeFromView: function(nodeTag, viewTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.disconnectAnimatedNodeFromView, nodeTag, viewTag);\n },\n restoreDefaultValues: function(nodeTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n if (nativeOps.restoreDefaultValues != null) {\n API.queueOperation(nativeOps.restoreDefaultValues, nodeTag);\n }\n },\n dropAnimatedNode: function(tag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.dropAnimatedNode, tag);\n },\n addAnimatedEventToView: function(viewTag, eventName, eventMapping) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(nativeOps.addAnimatedEventToView, viewTag, eventName, eventMapping);\n },\n removeAnimatedEventFromView(viewTag, eventName, animatedNodeTag) {\n invariant(nativeOps, \"Native animated module is not available\");\n API.queueOperation(\n nativeOps.removeAnimatedEventFromView,\n viewTag,\n eventName,\n animatedNodeTag\n );\n }\n};\nconst SUPPORTED_COLOR_STYLES = {\n backgroundColor: true,\n borderBottomColor: true,\n borderColor: true,\n borderEndColor: true,\n borderLeftColor: true,\n borderRightColor: true,\n borderStartColor: true,\n borderTopColor: true,\n color: true,\n tintColor: true\n};\nconst SUPPORTED_STYLES = {\n ...SUPPORTED_COLOR_STYLES,\n borderBottomEndRadius: true,\n borderBottomLeftRadius: true,\n borderBottomRightRadius: true,\n borderBottomStartRadius: true,\n borderRadius: true,\n borderTopEndRadius: true,\n borderTopLeftRadius: true,\n borderTopRightRadius: true,\n borderTopStartRadius: true,\n elevation: true,\n opacity: true,\n transform: true,\n zIndex: true,\n /* ios styles */\n shadowOpacity: true,\n shadowRadius: true,\n /* legacy android transform properties */\n scaleX: true,\n scaleY: true,\n translateX: true,\n translateY: true\n};\nconst SUPPORTED_TRANSFORMS = {\n translateX: true,\n translateY: true,\n scale: true,\n scaleX: true,\n scaleY: true,\n rotate: true,\n rotateX: true,\n rotateY: true,\n rotateZ: true,\n perspective: true\n};\nconst SUPPORTED_INTERPOLATION_PARAMS = {\n inputRange: true,\n outputRange: true,\n extrapolate: true,\n extrapolateRight: true,\n extrapolateLeft: true\n};\nfunction addWhitelistedStyleProp(prop) {\n SUPPORTED_STYLES[prop] = true;\n}\nfunction addWhitelistedTransformProp(prop) {\n SUPPORTED_TRANSFORMS[prop] = true;\n}\nfunction addWhitelistedInterpolationParam(param) {\n SUPPORTED_INTERPOLATION_PARAMS[param] = true;\n}\nfunction isSupportedColorStyleProp(prop) {\n return SUPPORTED_COLOR_STYLES.hasOwnProperty(prop);\n}\nfunction isSupportedStyleProp(prop) {\n return SUPPORTED_STYLES.hasOwnProperty(prop);\n}\nfunction isSupportedTransformProp(prop) {\n return SUPPORTED_TRANSFORMS.hasOwnProperty(prop);\n}\nfunction isSupportedInterpolationParam(param) {\n return SUPPORTED_INTERPOLATION_PARAMS.hasOwnProperty(param);\n}\nfunction validateTransform(configs) {\n configs.forEach((config) => {\n if (!isSupportedTransformProp(config.property)) {\n throw new Error(\n `Property '${config.property}' is not supported by native animated module`\n );\n }\n });\n}\nfunction validateStyles(styles) {\n for (const key in styles) {\n if (!isSupportedStyleProp(key)) {\n throw new Error(\n `Style property '${key}' is not supported by native animated module`\n );\n }\n }\n}\nfunction validateInterpolation(config) {\n for (const key in config) {\n if (!isSupportedInterpolationParam(key)) {\n throw new Error(\n `Interpolation property '${key}' is not supported by native animated module`\n );\n }\n }\n}\nfunction generateNewNodeTag() {\n return __nativeAnimatedNodeTagCount++;\n}\nfunction generateNewAnimationId() {\n return __nativeAnimationIdCount++;\n}\nfunction assertNativeAnimatedModule() {\n invariant(NativeAnimatedModule, \"Native animated module is not available\");\n}\nlet _warnedMissingNativeAnimated = false;\nfunction shouldUseNativeDriver(config) {\n if (config.useNativeDriver == null) {\n console.warn(\n \"Animated: `useNativeDriver` was not specified. This is a required option and must be explicitly set to `true` or `false`\"\n );\n }\n if (config.useNativeDriver === true && !NativeAnimatedModule) {\n if (!_warnedMissingNativeAnimated) {\n console.warn(\n \"Animated: `useNativeDriver` is not supported because the native animated module is missing. Falling back to JS-based animation. To resolve this, add `RCTAnimation` module to this app, or remove `useNativeDriver`. Make sure to run `bundle exec pod install` first. Read more about autolinking: https://github.com/react-native-community/cli/blob/master/docs/autolinking.md\"\n );\n _warnedMissingNativeAnimated = true;\n }\n return false;\n }\n return config.useNativeDriver || false;\n}\nfunction transformDataType(value) {\n if (typeof value !== \"string\") {\n return value;\n }\n if (/deg$/.test(value)) {\n const degrees = parseFloat(value) || 0;\n const radians = degrees * Math.PI / 180;\n return radians;\n } else {\n return value;\n }\n}\nconst NativeAnimatedHelper = {\n API,\n isSupportedColorStyleProp,\n isSupportedStyleProp,\n isSupportedTransformProp,\n isSupportedInterpolationParam,\n addWhitelistedStyleProp,\n addWhitelistedTransformProp,\n addWhitelistedInterpolationParam,\n validateStyles,\n validateTransform,\n validateInterpolation,\n generateNewNodeTag,\n generateNewAnimationId,\n assertNativeAnimatedModule,\n shouldUseNativeDriver,\n transformDataType,\n get nativeEventEmitter() {\n if (!nativeEventEmitter) {\n nativeEventEmitter = new NativeEventEmitter(\n // T88715063: NativeEventEmitter only used this parameter on iOS. Now it uses it on all platforms, so this code was modified automatically to preserve its behavior\n // If you want to use the native module on other platforms, please remove this condition and test its behavior\n Platform.OS !== \"ios\" ? null : NativeAnimatedModule\n );\n }\n return nativeEventEmitter;\n }\n};\nvar NativeAnimatedHelper_default = NativeAnimatedHelper;\nexport {\n API,\n NativeAnimatedHelper,\n addWhitelistedInterpolationParam,\n addWhitelistedStyleProp,\n addWhitelistedTransformProp,\n assertNativeAnimatedModule,\n NativeAnimatedHelper_default as default,\n generateNewAnimationId,\n generateNewNodeTag,\n isSupportedColorStyleProp,\n isSupportedInterpolationParam,\n isSupportedStyleProp,\n isSupportedTransformProp,\n shouldUseNativeDriver,\n transformDataType,\n validateInterpolation,\n validateStyles,\n validateTransform\n};\n//# sourceMappingURL=NativeAnimatedHelper.js.map\n"],"mappings":";;;;;;;;;AAOA,MAAM,uBAAuB,SAAS,OAAO,SAAS,OAAO,kBAAkB,OAAO,4BAA4B;AAClH,IAAI,+BAA+B;AACnC,IAAI,2BAA2B;AAC/B,IAAI;AACJ,IAAI,6CAA6C,IAAI,IAAI;AACzD,IAAI,kBAAkB;AACtB,IAAI,QAAQ,CAAC;AACb,IAAI,gBAAgB,CAAC;AACrB,MAAM,sBAAsB;AAC5B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Q;EACxB,IAAI,CAAC,8BAA8B,GAAG,GAAG;GACvC,MAAM,IAAI,MACR,2BAA2B,IAAI,6CACjC;EACF;CACF;AACF;AACA,SAAS,qBAAqB;CAC5B,OAAO;AACT;AACA,SAAS,yBAAyB;CAChC,OAAO;AACT;AACA,SAAS,6BAA6B;CACpC,UAAU,sBAAsB,yCAAyC;AAC3E;AACA,IAAI,+BAA+B;AACnC,SAAS,sBAAsB,QAAQ;CACrC,IAAI,OAAO,mBAAmB,MAAM;EAClC,QAAQ,KACN,0HACF;CACF;CACA,IAAI,OAAO,oBAAoB,QAAQ,CAAC,sBAAsB;EAC5D,IAAI,CAAC,8BAA8B;GACjC,QAAQ,KACN,mXACF;GACA,+BAA+B;EACjC;EACA,OAAO;CACT;CACA,OAAO,OAAO,mBAAmB;AACnC;AACA,SAAS,kBAAkB,OAAO;CAChC,IAAI,OAAO,UAAU,UAAU;EAC7B,OAAO;CACT;CACA,IAAI,OAAO,KAAK,KAAK,GAAG;EACtB,MAAM,UAAU,WAAW,KAAK,KAAK;EACrC,MAAM,UAAU,UAAU,KAAK,KAAK;EACpC,OAAO;CACT,OAAO;EACL,OAAO;CACT;AACF;AACA,MAAM,uBAAuB;CAC3B;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA,IAAI,qBAAqB;EACvB,IAAI,CAAC,oBAAoB;GACvB,qBAAqB,IAAI,mBAGvB,SAAS,OAAO,QAAQ,OAAO,oBACjC;EACF;EACA,OAAO;CACT;AACF;AACA,IAAI,+BAA+B"}
@@ -1 +1 @@
1
- {"version":3,"file":"AnimatedColor.js","names":[],"sources":["esm/vendor/react-native/Animated/nodes/AnimatedColor.js"],"sourcesContent":["import { AnimatedValue } from \"./AnimatedValue\";\nimport { AnimatedWithChildren } from \"./AnimatedWithChildren\";\nimport { normalizeColor } from \"@tamagui/react-native-web-internals\";\nimport { NativeAnimatedHelper } from \"../NativeAnimatedHelper\";\nconst NativeAnimatedAPI = NativeAnimatedHelper.API;\nconst defaultColor = { r: 0, g: 0, b: 0, a: 1 };\nlet _uniqueId = 1;\nconst processColorObject = (color) => {\n return color;\n};\nfunction processColor(color) {\n if (color === void 0 || color === null) {\n return null;\n }\n if (isRgbaValue(color)) {\n return color;\n }\n let normalizedColor = normalizeColor(color);\n if (normalizedColor === void 0 || normalizedColor === null) {\n return null;\n }\n if (typeof normalizedColor === \"object\") {\n const processedColorObj = processColorObject(normalizedColor);\n if (processedColorObj != null) {\n return processedColorObj;\n }\n } else if (typeof normalizedColor === \"number\") {\n const r = (normalizedColor & 4278190080) >>> 24;\n const g = (normalizedColor & 16711680) >>> 16;\n const b = (normalizedColor & 65280) >>> 8;\n const a = (normalizedColor & 255) / 255;\n return { r, g, b, a };\n }\n return null;\n}\nfunction isRgbaValue(value) {\n return value && typeof value.r === \"number\" && typeof value.g === \"number\" && typeof value.b === \"number\" && typeof value.a === \"number\";\n}\nfunction isRgbaAnimatedValue(value) {\n return value && value.r instanceof AnimatedValue && value.g instanceof AnimatedValue && value.b instanceof AnimatedValue && value.a instanceof AnimatedValue;\n}\nclass AnimatedColor extends AnimatedWithChildren {\n constructor(valueIn, config) {\n super();\n this._listeners = {};\n let value = valueIn ?? defaultColor;\n if (isRgbaAnimatedValue(value)) {\n const rgbaAnimatedValue = value;\n this.r = rgbaAnimatedValue.r;\n this.g = rgbaAnimatedValue.g;\n this.b = rgbaAnimatedValue.b;\n this.a = rgbaAnimatedValue.a;\n } else {\n const processedColor = processColor(value) ?? defaultColor;\n let initColor = defaultColor;\n if (isRgbaValue(processedColor)) {\n initColor = processedColor;\n } else {\n this.nativeColor = processedColor;\n }\n this.r = new AnimatedValue(initColor.r);\n this.g = new AnimatedValue(initColor.g);\n this.b = new AnimatedValue(initColor.b);\n this.a = new AnimatedValue(initColor.a);\n }\n if (this.nativeColor || config && config.useNativeDriver) {\n this.__makeNative();\n }\n }\n /**\n * Directly set the value. This will stop any animations running on the value\n * and update all the bound properties.\n */\n setValue(value) {\n let shouldUpdateNodeConfig = false;\n if (this.__isNative) {\n const nativeTag = this.__getNativeTag();\n NativeAnimatedAPI.setWaitingForIdentifier(nativeTag.toString());\n }\n const processedColor = processColor(value) ?? defaultColor;\n if (isRgbaValue(processedColor)) {\n const rgbaValue = processedColor;\n this.r.setValue(rgbaValue.r);\n this.g.setValue(rgbaValue.g);\n this.b.setValue(rgbaValue.b);\n this.a.setValue(rgbaValue.a);\n if (this.nativeColor != null) {\n this.nativeColor = null;\n shouldUpdateNodeConfig = true;\n }\n } else {\n const nativeColor = processedColor;\n if (this.nativeColor !== nativeColor) {\n this.nativeColor = nativeColor;\n shouldUpdateNodeConfig = true;\n }\n }\n if (this.__isNative) {\n const nativeTag = this.__getNativeTag();\n if (shouldUpdateNodeConfig) {\n NativeAnimatedAPI.updateAnimatedNodeConfig(nativeTag, this.__getNativeConfig());\n }\n NativeAnimatedAPI.unsetWaitingForIdentifier(nativeTag.toString());\n }\n }\n /**\n * Sets an offset that is applied on top of whatever value is set, whether\n * via `setValue`, an animation, or `Animated.event`. Useful for compensating\n * things like the start of a pan gesture.\n */\n setOffset(offset) {\n this.r.setOffset(offset.r);\n this.g.setOffset(offset.g);\n this.b.setOffset(offset.b);\n this.a.setOffset(offset.a);\n }\n /**\n * Merges the offset value into the base value and resets the offset to zero.\n * The final output of the value is unchanged.\n */\n flattenOffset() {\n this.r.flattenOffset();\n this.g.flattenOffset();\n this.b.flattenOffset();\n this.a.flattenOffset();\n }\n /**\n * Sets the offset value to the base value, and resets the base value to\n * zero. The final output of the value is unchanged.\n */\n extractOffset() {\n this.r.extractOffset();\n this.g.extractOffset();\n this.b.extractOffset();\n this.a.extractOffset();\n }\n /**\n * Adds an asynchronous listener to the value so you can observe updates from\n * animations. This is useful because there is no way to synchronously read\n * the value because it might be driven natively.\n *\n * Returns a string that serves as an identifier for the listener.\n */\n addListener(callback) {\n const id = String(_uniqueId++);\n const jointCallback = ({ value }) => {\n callback(this.__getValue());\n };\n this._listeners[id] = {\n r: this.r.addListener(jointCallback),\n g: this.g.addListener(jointCallback),\n b: this.b.addListener(jointCallback),\n a: this.a.addListener(jointCallback)\n };\n return id;\n }\n removeListener(id) {\n if (this._listeners[id]) {\n this.r.removeListener(this._listeners[id].r);\n this.g.removeListener(this._listeners[id].g);\n this.b.removeListener(this._listeners[id].b);\n this.a.removeListener(this._listeners[id].a);\n delete this._listeners[id];\n }\n }\n removeAllListeners() {\n this.r.removeAllListeners();\n this.g.removeAllListeners();\n this.b.removeAllListeners();\n this.a.removeAllListeners();\n this._listeners = {};\n }\n stopAnimation(callback) {\n this.r.stopAnimation();\n this.g.stopAnimation();\n this.b.stopAnimation();\n this.a.stopAnimation();\n callback && callback(this.__getValue());\n }\n resetAnimation(callback) {\n this.r.resetAnimation();\n this.g.resetAnimation();\n this.b.resetAnimation();\n this.a.resetAnimation();\n callback && callback(this.__getValue());\n }\n interpolate(config) {\n throw new Error(\n \"Directly calling interpolate on an AnimatedColor is not supported. Call interpolate on the AnimatedColor.r/g/b/a values instead.\"\n );\n }\n __getValue() {\n if (this.nativeColor != null) {\n return this.nativeColor;\n } else {\n return {\n r: this.r.__getValue(),\n g: this.g.__getValue(),\n b: this.b.__getValue(),\n a: this.a.__getValue()\n };\n }\n }\n __attach() {\n this.r.__addChild(this);\n this.g.__addChild(this);\n this.b.__addChild(this);\n this.a.__addChild(this);\n super.__attach();\n }\n __detach() {\n this.r.__removeChild(this);\n this.g.__removeChild(this);\n this.b.__removeChild(this);\n this.a.__removeChild(this);\n super.__detach();\n }\n __makeNative(platformConfig) {\n this.r.__makeNative(platformConfig);\n this.g.__makeNative(platformConfig);\n this.b.__makeNative(platformConfig);\n this.a.__makeNative(platformConfig);\n super.__makeNative(platformConfig);\n }\n __getNativeConfig() {\n return {\n type: \"color\",\n r: this.r.__getNativeTag(),\n g: this.g.__getNativeTag(),\n b: this.b.__getNativeTag(),\n a: this.a.__getNativeTag(),\n nativeColor: this.nativeColor\n };\n }\n}\nvar AnimatedColor_default = AnimatedColor;\nexport {\n AnimatedColor,\n AnimatedColor_default as default\n};\n//# sourceMappingURL=AnimatedColor.js.map\n"],"mappings":";;;;;;AAIA,MAAM,oBAAoB,qBAAqB;AAC/C,MAAM,eAAe;CAAE,GAAG;CAAG,GAAG;CAAG,GAAG;CAAG,GAAG;AAAE;AAC9C,IAAI,YAAY;AAChB,MAAM,sBAAsB,UAAU;CACpC,OAAO;AACT;AACA,SAAS,aAAa,OAAO;CAC3B,IAAI,UAAU,KAAK,KAAK,UAAU,MAAM;EACtC,OAAO;CACT;CACA,IAAI,YAAY,KAAK,GAAG;EACtB,OAAO;CACT;CACA,IAAI,kBAAkB,eAAe,KAAK;CAC1C,IAAI,oBAAoB,KAAK,KAAK,oBAAoB,MAAM;EAC1D,OAAO;CACT;CACA,IAAI,OAAO,oBAAoB,UAAU;EACvC,MAAM,oBAAoB,mBAAmB,eAAe;EAC5D,IAAI,qBAAqB,MAAM;GAC7B,OAAO;EACT;CACF,OAAO,IAAI,OAAO,oBAAoB,UAAU;EAC9C,MAAM,KAAK,kBAAkB,gBAAgB;EAC7C,MAAM,KAAK,kBAAkB,cAAc;EAC3C,MAAM,KAAK,kBAAkB,WAAW;EACxC,MAAM,KAAK,kBAAkB,OAAO;EACpC,OAAO;GAAE;GAAG;GAAG;GAAG;EAAE;CACtB;CACA,OAAO;AACT;AACA,SAAS,YAAY,OAAO;CAC1B,OAAO,SAAS,OAAO,MAAM,MAAM,YAAY,OAAO,MAAM,MAAM,YAAY,OAAO,MAAM,MAAM,YAAY,OAAO,MAAM,MAAM;AAClI;AACA,SAAS,oBAAoB,OAAO;CAClC,OAAO,SAAS,MAAM,aAAa,iBAAiB,MAAM,aAAa,iBAAiB,MAAM,aAAa,iBAAiB,MAAM,aAAa;AACjJ;AACA,IAAM,gBAAN,cAA4B,qBAAqB;CAC/C,YAAY,SAAS,QAAQ;EAC3B,MAAM;EACN,KAAK,aAAa,CAAC;EACnB,IAAI,QAAQ,WAAW;EACvB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;AACF;AACA,IAAI,wBAAwB"}
1
+ {"version":3,"file":"AnimatedColor.js","names":[],"sources":["esm/vendor/react-native/Animated/nodes/AnimatedColor.js"],"sourcesContent":["import { AnimatedValue } from \"./AnimatedValue\";\nimport { AnimatedWithChildren } from \"./AnimatedWithChildren\";\nimport { normalizeColor } from \"@tamagui/react-native-web-internals\";\nimport { NativeAnimatedHelper } from \"../NativeAnimatedHelper\";\nconst NativeAnimatedAPI = NativeAnimatedHelper.API;\nconst defaultColor = { r: 0, g: 0, b: 0, a: 1 };\nlet _uniqueId = 1;\nconst processColorObject = (color) => {\n return color;\n};\nfunction processColor(color) {\n if (color === void 0 || color === null) {\n return null;\n }\n if (isRgbaValue(color)) {\n return color;\n }\n let normalizedColor = normalizeColor(color);\n if (normalizedColor === void 0 || normalizedColor === null) {\n return null;\n }\n if (typeof normalizedColor === \"object\") {\n const processedColorObj = processColorObject(normalizedColor);\n if (processedColorObj != null) {\n return processedColorObj;\n }\n } else if (typeof normalizedColor === \"number\") {\n const r = (normalizedColor & 4278190080) >>> 24;\n const g = (normalizedColor & 16711680) >>> 16;\n const b = (normalizedColor & 65280) >>> 8;\n const a = (normalizedColor & 255) / 255;\n return { r, g, b, a };\n }\n return null;\n}\nfunction isRgbaValue(value) {\n return value && typeof value.r === \"number\" && typeof value.g === \"number\" && typeof value.b === \"number\" && typeof value.a === \"number\";\n}\nfunction isRgbaAnimatedValue(value) {\n return value && value.r instanceof AnimatedValue && value.g instanceof AnimatedValue && value.b instanceof AnimatedValue && value.a instanceof AnimatedValue;\n}\nclass AnimatedColor extends AnimatedWithChildren {\n constructor(valueIn, config) {\n super();\n this._listeners = {};\n let value = valueIn ?? defaultColor;\n if (isRgbaAnimatedValue(value)) {\n const rgbaAnimatedValue = value;\n this.r = rgbaAnimatedValue.r;\n this.g = rgbaAnimatedValue.g;\n this.b = rgbaAnimatedValue.b;\n this.a = rgbaAnimatedValue.a;\n } else {\n const processedColor = processColor(value) ?? defaultColor;\n let initColor = defaultColor;\n if (isRgbaValue(processedColor)) {\n initColor = processedColor;\n } else {\n this.nativeColor = processedColor;\n }\n this.r = new AnimatedValue(initColor.r);\n this.g = new AnimatedValue(initColor.g);\n this.b = new AnimatedValue(initColor.b);\n this.a = new AnimatedValue(initColor.a);\n }\n if (this.nativeColor || config && config.useNativeDriver) {\n this.__makeNative();\n }\n }\n /**\n * Directly set the value. This will stop any animations running on the value\n * and update all the bound properties.\n */\n setValue(value) {\n let shouldUpdateNodeConfig = false;\n if (this.__isNative) {\n const nativeTag = this.__getNativeTag();\n NativeAnimatedAPI.setWaitingForIdentifier(nativeTag.toString());\n }\n const processedColor = processColor(value) ?? defaultColor;\n if (isRgbaValue(processedColor)) {\n const rgbaValue = processedColor;\n this.r.setValue(rgbaValue.r);\n this.g.setValue(rgbaValue.g);\n this.b.setValue(rgbaValue.b);\n this.a.setValue(rgbaValue.a);\n if (this.nativeColor != null) {\n this.nativeColor = null;\n shouldUpdateNodeConfig = true;\n }\n } else {\n const nativeColor = processedColor;\n if (this.nativeColor !== nativeColor) {\n this.nativeColor = nativeColor;\n shouldUpdateNodeConfig = true;\n }\n }\n if (this.__isNative) {\n const nativeTag = this.__getNativeTag();\n if (shouldUpdateNodeConfig) {\n NativeAnimatedAPI.updateAnimatedNodeConfig(nativeTag, this.__getNativeConfig());\n }\n NativeAnimatedAPI.unsetWaitingForIdentifier(nativeTag.toString());\n }\n }\n /**\n * Sets an offset that is applied on top of whatever value is set, whether\n * via `setValue`, an animation, or `Animated.event`. Useful for compensating\n * things like the start of a pan gesture.\n */\n setOffset(offset) {\n this.r.setOffset(offset.r);\n this.g.setOffset(offset.g);\n this.b.setOffset(offset.b);\n this.a.setOffset(offset.a);\n }\n /**\n * Merges the offset value into the base value and resets the offset to zero.\n * The final output of the value is unchanged.\n */\n flattenOffset() {\n this.r.flattenOffset();\n this.g.flattenOffset();\n this.b.flattenOffset();\n this.a.flattenOffset();\n }\n /**\n * Sets the offset value to the base value, and resets the base value to\n * zero. The final output of the value is unchanged.\n */\n extractOffset() {\n this.r.extractOffset();\n this.g.extractOffset();\n this.b.extractOffset();\n this.a.extractOffset();\n }\n /**\n * Adds an asynchronous listener to the value so you can observe updates from\n * animations. This is useful because there is no way to synchronously read\n * the value because it might be driven natively.\n *\n * Returns a string that serves as an identifier for the listener.\n */\n addListener(callback) {\n const id = String(_uniqueId++);\n const jointCallback = ({ value }) => {\n callback(this.__getValue());\n };\n this._listeners[id] = {\n r: this.r.addListener(jointCallback),\n g: this.g.addListener(jointCallback),\n b: this.b.addListener(jointCallback),\n a: this.a.addListener(jointCallback)\n };\n return id;\n }\n removeListener(id) {\n if (this._listeners[id]) {\n this.r.removeListener(this._listeners[id].r);\n this.g.removeListener(this._listeners[id].g);\n this.b.removeListener(this._listeners[id].b);\n this.a.removeListener(this._listeners[id].a);\n delete this._listeners[id];\n }\n }\n removeAllListeners() {\n this.r.removeAllListeners();\n this.g.removeAllListeners();\n this.b.removeAllListeners();\n this.a.removeAllListeners();\n this._listeners = {};\n }\n stopAnimation(callback) {\n this.r.stopAnimation();\n this.g.stopAnimation();\n this.b.stopAnimation();\n this.a.stopAnimation();\n callback && callback(this.__getValue());\n }\n resetAnimation(callback) {\n this.r.resetAnimation();\n this.g.resetAnimation();\n this.b.resetAnimation();\n this.a.resetAnimation();\n callback && callback(this.__getValue());\n }\n interpolate(config) {\n throw new Error(\n \"Directly calling interpolate on an AnimatedColor is not supported. Call interpolate on the AnimatedColor.r/g/b/a values instead.\"\n );\n }\n __getValue() {\n if (this.nativeColor != null) {\n return this.nativeColor;\n } else {\n return {\n r: this.r.__getValue(),\n g: this.g.__getValue(),\n b: this.b.__getValue(),\n a: this.a.__getValue()\n };\n }\n }\n __attach() {\n this.r.__addChild(this);\n this.g.__addChild(this);\n this.b.__addChild(this);\n this.a.__addChild(this);\n super.__attach();\n }\n __detach() {\n this.r.__removeChild(this);\n this.g.__removeChild(this);\n this.b.__removeChild(this);\n this.a.__removeChild(this);\n super.__detach();\n }\n __makeNative(platformConfig) {\n this.r.__makeNative(platformConfig);\n this.g.__makeNative(platformConfig);\n this.b.__makeNative(platformConfig);\n this.a.__makeNative(platformConfig);\n super.__makeNative(platformConfig);\n }\n __getNativeConfig() {\n return {\n type: \"color\",\n r: this.r.__getNativeTag(),\n g: this.g.__getNativeTag(),\n b: this.b.__getNativeTag(),\n a: this.a.__getNativeTag(),\n nativeColor: this.nativeColor\n };\n }\n}\nvar AnimatedColor_default = AnimatedColor;\nexport {\n AnimatedColor,\n AnimatedColor_default as default\n};\n//# sourceMappingURL=AnimatedColor.js.map\n"],"mappings":";;;;;;AAIA,MAAM,oBAAoB,qBAAqB;AAC/C,MAAM,eAAe;CAAE,GAAG;CAAG,GAAG;CAAG,GAAG;CAAG,GAAG;AAAE;AAC9C,IAAI,YAAY;AAChB,MAAM,sBAAsB,UAAU;CACpC,OAAO;AACT;AACA,SAAS,aAAa,OAAO;CAC3B,IAAI,UAAU,KAAK,KAAK,UAAU,MAAM;EACtC,OAAO;CACT;CACA,IAAI,YAAY,KAAK,GAAG;EACtB,OAAO;CACT;CACA,IAAI,kBAAkB,eAAe,KAAK;CAC1C,IAAI,oBAAoB,KAAK,KAAK,oBAAoB,MAAM;EAC1D,OAAO;CACT;CACA,IAAI,OAAO,oBAAoB,UAAU;EACvC,MAAM,oBAAoB,mBAAmB,eAAe;EAC5D,IAAI,qBAAqB,MAAM;GAC7B,OAAO;EACT;CACF,OAAO,IAAI,OAAO,oBAAoB,UAAU;EAC9C,MAAM,KAAK,kBAAkB,gBAAgB;EAC7C,MAAM,KAAK,kBAAkB,cAAc;EAC3C,MAAM,KAAK,kBAAkB,WAAW;EACxC,MAAM,KAAK,kBAAkB,OAAO;EACpC,OAAO;GAAE;GAAG;GAAG;GAAG;EAAE;CACtB;CACA,OAAO;AACT;AACA,SAAS,YAAY,OAAO;CAC1B,OAAO,SAAS,OAAO,MAAM,MAAM,YAAY,OAAO,MAAM,MAAM,YAAY,OAAO,MAAM,MAAM,YAAY,OAAO,M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EAAE,aAAa,cAAc;EAClC,KAAK,EAAE,aAAa,cAAc;EAClC,KAAK,EAAE,aAAa,cAAc;EAClC,MAAM,aAAa,cAAc;CACnC;CACA,oBAAoB;EAClB,OAAO;GACL,MAAM;GACN,GAAG,KAAK,EAAE,eAAe;GACzB,GAAG,KAAK,EAAE,eAAe;GACzB,GAAG,KAAK,EAAE,eAAe;GACzB,GAAG,KAAK,EAAE,eAAe;GACzB,aAAa,KAAK;EACpB;CACF;AACF;AACA,IAAI,wBAAwB"}
@@ -1 +1 @@
1
- {"version":3,"file":"AnimatedInterpolation.js","names":[],"sources":["esm/vendor/react-native/Animated/nodes/AnimatedInterpolation.js"],"sourcesContent":["import { AnimatedWithChildren } from \"./AnimatedWithChildren\";\nimport { NativeAnimatedHelper } from \"../NativeAnimatedHelper\";\nimport { normalizeColor, invariant } from \"@tamagui/react-native-web-internals\";\nconst __DEV__ = process.env.NODE_ENV !== \"production\";\nconst linear = (t) => t;\nfunction createInterpolation(config) {\n if (config.outputRange && typeof config.outputRange[0] === \"string\") {\n return createInterpolationFromStringOutputRange(config);\n }\n const outputRange = config.outputRange;\n const inputRange = config.inputRange;\n if (__DEV__) {\n checkInfiniteRange(\"outputRange\", outputRange);\n checkInfiniteRange(\"inputRange\", inputRange);\n checkValidInputRange(inputRange);\n invariant(\n inputRange.length === outputRange.length,\n \"inputRange (\" + inputRange.length + \") and outputRange (\" + outputRange.length + \") must have the same length\"\n );\n }\n const easing = config.easing || linear;\n let extrapolateLeft = \"extend\";\n if (config.extrapolateLeft !== void 0) {\n extrapolateLeft = config.extrapolateLeft;\n } else if (config.extrapolate !== void 0) {\n extrapolateLeft = config.extrapolate;\n }\n let extrapolateRight = \"extend\";\n if (config.extrapolateRight !== void 0) {\n extrapolateRight = config.extrapolateRight;\n } else if (config.extrapolate !== void 0) {\n extrapolateRight = config.extrapolate;\n }\n return (input) => {\n invariant(\n typeof input === \"number\",\n \"Cannot interpolation an input which is not a number\"\n );\n const range = findRange(input, inputRange);\n return interpolate(\n input,\n inputRange[range],\n inputRange[range + 1],\n outputRange[range],\n outputRange[range + 1],\n easing,\n extrapolateLeft,\n extrapolateRight\n );\n };\n}\nfunction interpolate(input, inputMin, inputMax, outputMin, outputMax, easing, extrapolateLeft, extrapolateRight) {\n let result = input;\n if (result < inputMin) {\n if (extrapolateLeft === \"identity\") {\n return result;\n } else if (extrapolateLeft === \"clamp\") {\n result = inputMin;\n } else if (extrapolateLeft === \"extend\") {\n }\n }\n if (result > inputMax) {\n if (extrapolateRight === \"identity\") {\n return result;\n } else if (extrapolateRight === \"clamp\") {\n result = inputMax;\n } else if (extrapolateRight === \"extend\") {\n }\n }\n if (outputMin === outputMax) {\n return outputMin;\n }\n if (inputMin === inputMax) {\n if (input <= inputMin) {\n return outputMin;\n }\n return outputMax;\n }\n if (inputMin === -Infinity) {\n result = -result;\n } else if (inputMax === Infinity) {\n result = result - inputMin;\n } else {\n result = (result - inputMin) / (inputMax - inputMin);\n }\n result = easing(result);\n if (outputMin === -Infinity) {\n result = -result;\n } else if (outputMax === Infinity) {\n result = result + outputMin;\n } else {\n result = result * (outputMax - outputMin) + outputMin;\n }\n return result;\n}\nfunction colorToRgba(input) {\n let normalizedColor = normalizeColor(input);\n if (normalizedColor === null || typeof normalizedColor !== \"number\") {\n return input;\n }\n normalizedColor = normalizedColor || 0;\n const r = (normalizedColor & 4278190080) >>> 24;\n const g = (normalizedColor & 16711680) >>> 16;\n const b = (normalizedColor & 65280) >>> 8;\n const a = (normalizedColor & 255) / 255;\n return `rgba(${r}, ${g}, ${b}, ${a})`;\n}\nconst stringShapeRegex = /[+-]?(?:\\d+\\.?\\d*|\\.\\d+)(?:[eE][+-]?\\d+)?/g;\nfunction createInterpolationFromStringOutputRange(config) {\n let outputRange = config.outputRange;\n invariant(outputRange.length >= 2, \"Bad output range\");\n outputRange = outputRange.map(colorToRgba);\n checkPattern(outputRange);\n const outputRanges = outputRange[0].match(stringShapeRegex).map(() => []);\n outputRange.forEach((value) => {\n value.match(stringShapeRegex).forEach((number, i) => {\n outputRanges[i].push(+number);\n });\n });\n const interpolations = outputRange[0].match(stringShapeRegex).map((value, i) => {\n return createInterpolation({\n ...config,\n outputRange: outputRanges[i]\n });\n });\n const shouldRound = isRgbOrRgba(outputRange[0]);\n return (input) => {\n let i = 0;\n return outputRange[0].replace(stringShapeRegex, () => {\n let val = +interpolations[i++](input);\n if (shouldRound) {\n val = i < 4 ? Math.round(val) : Math.round(val * 1e3) / 1e3;\n }\n return String(val);\n });\n };\n}\nfunction isRgbOrRgba(range) {\n return typeof range === \"string\" && range.startsWith(\"rgb\");\n}\nfunction checkPattern(arr) {\n const pattern = arr[0].replace(stringShapeRegex, \"\");\n for (let i = 1; i < arr.length; ++i) {\n invariant(\n pattern === arr[i].replace(stringShapeRegex, \"\"),\n \"invalid pattern \" + arr[0] + \" and \" + arr[i]\n );\n }\n}\nfunction findRange(input, inputRange) {\n let i;\n for (i = 1; i < inputRange.length - 1; ++i) {\n if (inputRange[i] >= input) {\n break;\n }\n }\n return i - 1;\n}\nfunction checkValidInputRange(arr) {\n invariant(arr.length >= 2, \"inputRange must have at least 2 elements\");\n const message = \"inputRange must be monotonically non-decreasing \" + String(arr);\n for (let i = 1; i < arr.length; ++i) {\n invariant(arr[i] >= arr[i - 1], message);\n }\n}\nfunction checkInfiniteRange(name, arr) {\n invariant(arr.length >= 2, name + \" must have at least 2 elements\");\n invariant(\n arr.length !== 2 || arr[0] !== -Infinity || arr[1] !== Infinity,\n name + \"cannot be ]-infinity;+infinity[ \" + arr\n );\n}\nclass AnimatedInterpolation extends AnimatedWithChildren {\n // Export for testing.\n static __createInterpolation = createInterpolation;\n constructor(parent, config) {\n super();\n this._parent = parent;\n this._config = config;\n this._interpolation = createInterpolation(config);\n }\n __makeNative(platformConfig) {\n this._parent.__makeNative(platformConfig);\n super.__makeNative(platformConfig);\n }\n __getValue() {\n const parentValue = this._parent.__getValue();\n invariant(\n typeof parentValue === \"number\",\n \"Cannot interpolate an input which is not a number.\"\n );\n return this._interpolation(parentValue);\n }\n interpolate(config) {\n return new AnimatedInterpolation(this, config);\n }\n __attach() {\n this._parent.__addChild(this);\n }\n __detach() {\n this._parent.__removeChild(this);\n super.__detach();\n }\n __transformDataType(range) {\n return range.map(NativeAnimatedHelper.transformDataType);\n }\n __getNativeConfig() {\n if (__DEV__) {\n NativeAnimatedHelper.validateInterpolation(this._config);\n }\n return {\n inputRange: this._config.inputRange,\n // Only the `outputRange` can contain strings so we don't need to transform `inputRange` here\n outputRange: this.__transformDataType(this._config.outputRange),\n extrapolateLeft: this._config.extrapolateLeft || this._config.extrapolate || \"extend\",\n extrapolateRight: this._config.extrapolateRight || this._config.extrapolate || \"extend\",\n type: \"interpolation\"\n };\n }\n}\nvar AnimatedInterpolation_default = AnimatedInterpolation;\nexport {\n AnimatedInterpolation,\n AnimatedInterpolation_default as default\n};\n//# sourceMappingURL=AnimatedInterpolation.js.map\n"],"mappings":";;;;;AAGA,MAAM,UAAU,QAAQ,IAAI,aAAa;AACzC,MAAM,UAAU,MAAM;AACtB,SAAS,oBAAoB,QAAQ;CACnC,IAAI,OAAO,eAAe,OAAO,OAAO,YAAY,OAAO,UAAU;EACnE,OAAO,yCAAyC,MAAM;CACxD;CACA,MAAM,cAAc,OAAO;CAC3B,MAAM,aAAa,OAAO;CAC1B,IAAI,SAAS;EACX,mBAAmB,eAAe,WAAW;EAC7C,mBAAmB,cAAc,UAAU;EAC3C,qBAAqB,UAAU;EAC/B,UACE,WAAW,WAAW,YAAY,QAClC,iBAAiB,WAAW,SAAS,wBAAwB,YAAY,SAAS,6BACpF;CACF;CACA,MAAM,SAAS,OAAO,UAAU;CAChC,IAAI,kBAAkB;CACtB,IAAI,OAAO,oBAAoB,KAAK,GAAG;EACrC,kBAAkB,OAAO;CAC3B,OAAO,IAAI,OAAO,gBAAgB,KAAK,GAAG;EACxC,kBAAkB,OAAO;CAC3B;CACA,IAAI,mBAAmB;CACvB,IAAI,OAAO,qBAAqB,KAAK,GAA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Ac,IAAI;EAC/B,MAAM,SAAS;CACjB;CACA,oBAAoB,OAAO;EACzB,OAAO,MAAM,IAAI,qBAAqB,iBAAiB;CACzD;CACA,oBAAoB;EAClB,IAAI,SAAS;GACX,qBAAqB,sBAAsB,KAAK,OAAO;EACzD;EACA,OAAO;GACL,YAAY,KAAK,QAAQ;GAEzB,aAAa,KAAK,oBAAoB,KAAK,QAAQ,WAAW;GAC9D,iBAAiB,KAAK,QAAQ,mBAAmB,KAAK,QAAQ,eAAe;GAC7E,kBAAkB,KAAK,QAAQ,oBAAoB,KAAK,QAAQ,eAAe;GAC/E,MAAM;EACR;CACF;AACF;AACA,IAAI,gCAAgC"}
1
+ {"version":3,"file":"AnimatedInterpolation.js","names":[],"sources":["esm/vendor/react-native/Animated/nodes/AnimatedInterpolation.js"],"sourcesContent":["import { AnimatedWithChildren } from \"./AnimatedWithChildren\";\nimport { NativeAnimatedHelper } from \"../NativeAnimatedHelper\";\nimport { normalizeColor, invariant } from \"@tamagui/react-native-web-internals\";\nconst __DEV__ = process.env.NODE_ENV !== \"production\";\nconst linear = (t) => t;\nfunction createInterpolation(config) {\n if (config.outputRange && typeof config.outputRange[0] === \"string\") {\n return createInterpolationFromStringOutputRange(config);\n }\n const outputRange = config.outputRange;\n const inputRange = config.inputRange;\n if (__DEV__) {\n checkInfiniteRange(\"outputRange\", outputRange);\n checkInfiniteRange(\"inputRange\", inputRange);\n checkValidInputRange(inputRange);\n invariant(\n inputRange.length === outputRange.length,\n \"inputRange (\" + inputRange.length + \") and outputRange (\" + outputRange.length + \") must have the same length\"\n );\n }\n const easing = config.easing || linear;\n let extrapolateLeft = \"extend\";\n if (config.extrapolateLeft !== void 0) {\n extrapolateLeft = config.extrapolateLeft;\n } else if (config.extrapolate !== void 0) {\n extrapolateLeft = config.extrapolate;\n }\n let extrapolateRight = \"extend\";\n if (config.extrapolateRight !== void 0) {\n extrapolateRight = config.extrapolateRight;\n } else if (config.extrapolate !== void 0) {\n extrapolateRight = config.extrapolate;\n }\n return (input) => {\n invariant(\n typeof input === \"number\",\n \"Cannot interpolation an input which is not a number\"\n );\n const range = findRange(input, inputRange);\n return interpolate(\n input,\n inputRange[range],\n inputRange[range + 1],\n outputRange[range],\n outputRange[range + 1],\n easing,\n extrapolateLeft,\n extrapolateRight\n );\n };\n}\nfunction interpolate(input, inputMin, inputMax, outputMin, outputMax, easing, extrapolateLeft, extrapolateRight) {\n let result = input;\n if (result < inputMin) {\n if (extrapolateLeft === \"identity\") {\n return result;\n } else if (extrapolateLeft === \"clamp\") {\n result = inputMin;\n } else if (extrapolateLeft === \"extend\") {\n }\n }\n if (result > inputMax) {\n if (extrapolateRight === \"identity\") {\n return result;\n } else if (extrapolateRight === \"clamp\") {\n result = inputMax;\n } else if (extrapolateRight === \"extend\") {\n }\n }\n if (outputMin === outputMax) {\n return outputMin;\n }\n if (inputMin === inputMax) {\n if (input <= inputMin) {\n return outputMin;\n }\n return outputMax;\n }\n if (inputMin === -Infinity) {\n result = -result;\n } else if (inputMax === Infinity) {\n result = result - inputMin;\n } else {\n result = (result - inputMin) / (inputMax - inputMin);\n }\n result = easing(result);\n if (outputMin === -Infinity) {\n result = -result;\n } else if (outputMax === Infinity) {\n result = result + outputMin;\n } else {\n result = result * (outputMax - outputMin) + outputMin;\n }\n return result;\n}\nfunction colorToRgba(input) {\n let normalizedColor = normalizeColor(input);\n if (normalizedColor === null || typeof normalizedColor !== \"number\") {\n return input;\n }\n normalizedColor = normalizedColor || 0;\n const r = (normalizedColor & 4278190080) >>> 24;\n const g = (normalizedColor & 16711680) >>> 16;\n const b = (normalizedColor & 65280) >>> 8;\n const a = (normalizedColor & 255) / 255;\n return `rgba(${r}, ${g}, ${b}, ${a})`;\n}\nconst stringShapeRegex = /[+-]?(?:\\d+\\.?\\d*|\\.\\d+)(?:[eE][+-]?\\d+)?/g;\nfunction createInterpolationFromStringOutputRange(config) {\n let outputRange = config.outputRange;\n invariant(outputRange.length >= 2, \"Bad output range\");\n outputRange = outputRange.map(colorToRgba);\n checkPattern(outputRange);\n const outputRanges = outputRange[0].match(stringShapeRegex).map(() => []);\n outputRange.forEach((value) => {\n value.match(stringShapeRegex).forEach((number, i) => {\n outputRanges[i].push(+number);\n });\n });\n const interpolations = outputRange[0].match(stringShapeRegex).map((value, i) => {\n return createInterpolation({\n ...config,\n outputRange: outputRanges[i]\n });\n });\n const shouldRound = isRgbOrRgba(outputRange[0]);\n return (input) => {\n let i = 0;\n return outputRange[0].replace(stringShapeRegex, () => {\n let val = +interpolations[i++](input);\n if (shouldRound) {\n val = i < 4 ? Math.round(val) : Math.round(val * 1e3) / 1e3;\n }\n return String(val);\n });\n };\n}\nfunction isRgbOrRgba(range) {\n return typeof range === \"string\" && range.startsWith(\"rgb\");\n}\nfunction checkPattern(arr) {\n const pattern = arr[0].replace(stringShapeRegex, \"\");\n for (let i = 1; i < arr.length; ++i) {\n invariant(\n pattern === arr[i].replace(stringShapeRegex, \"\"),\n \"invalid pattern \" + arr[0] + \" and \" + arr[i]\n );\n }\n}\nfunction findRange(input, inputRange) {\n let i;\n for (i = 1; i < inputRange.length - 1; ++i) {\n if (inputRange[i] >= input) {\n break;\n }\n }\n return i - 1;\n}\nfunction checkValidInputRange(arr) {\n invariant(arr.length >= 2, \"inputRange must have at least 2 elements\");\n const message = \"inputRange must be monotonically non-decreasing \" + String(arr);\n for (let i = 1; i < arr.length; ++i) {\n invariant(arr[i] >= arr[i - 1], message);\n }\n}\nfunction checkInfiniteRange(name, arr) {\n invariant(arr.length >= 2, name + \" must have at least 2 elements\");\n invariant(\n arr.length !== 2 || arr[0] !== -Infinity || arr[1] !== Infinity,\n name + \"cannot be ]-infinity;+infinity[ \" + arr\n );\n}\nclass AnimatedInterpolation extends AnimatedWithChildren {\n // Export for testing.\n static __createInterpolation = createInterpolation;\n constructor(parent, config) {\n super();\n this._parent = parent;\n this._config = config;\n this._interpolation = createInterpolation(config);\n }\n __makeNative(platformConfig) {\n this._parent.__makeNative(platformConfig);\n super.__makeNative(platformConfig);\n }\n __getValue() {\n const parentValue = this._parent.__getValue();\n invariant(\n typeof parentValue === \"number\",\n \"Cannot interpolate an input which is not a number.\"\n );\n return this._interpolation(parentValue);\n }\n interpolate(config) {\n return new AnimatedInterpolation(this, config);\n }\n __attach() {\n this._parent.__addChild(this);\n }\n __detach() {\n this._parent.__removeChild(this);\n super.__detach();\n }\n __transformDataType(range) {\n return range.map(NativeAnimatedHelper.transformDataType);\n }\n __getNativeConfig() {\n if (__DEV__) {\n NativeAnimatedHelper.validateInterpolation(this._config);\n }\n return {\n inputRange: this._config.inputRange,\n // Only the `outputRange` can contain strings so we don't need to transform `inputRange` here\n outputRange: this.__transformDataType(this._config.outputRange),\n extrapolateLeft: this._config.extrapolateLeft || this._config.extrapolate || \"extend\",\n extrapolateRight: this._config.extrapolateRight || this._config.extrapolate || \"extend\",\n type: \"interpolation\"\n };\n }\n}\nvar AnimatedInterpolation_default = AnimatedInterpolation;\nexport {\n AnimatedInterpolation,\n AnimatedInterpolation_default as default\n};\n//# sourceMappingURL=AnimatedInterpolation.js.map\n"],"mappings":";;;;;AAGA,MAAM,UAAU,QAAQ,IAAI,aAAa;AACzC,MAAM,UAAU,MAAM;AACtB,SAAS,oBAAoB,QAAQ;CACnC,IAAI,OAAO,eAAe,OAAO,OAAO,YAAY,OAAO,UAAU;EACnE,OAAO,yCAAyC,MAAM;CACxD;CACA,MAAM,cAAc,OAAO;CAC3B,MAAM,aAAa,OAAO;CAC1B,IAAI,SAAS;EACX,mBAAmB,eAAe,WAAW;EAC7C,mBAAmB,cAAc,UAAU;EAC3C,qBAAqB,UAAU;EAC/B,UACE,WAAW,WAAW,YAAY,QAClC,iBAAiB,WAAW,SAAS,wBAAwB,YAAY,SAAS,6BACpF;CACF;CACA,MAAM,SAAS,OAAO,UAAU;CAChC,IAAI,kBAAkB;CACtB,IAAI,OAAO,oBAAoB,KAAK,GAAG;EACrC,kBAAkB,OAAO;CAC3B,OAAO,IAAI,OAAO,gBAAgB,KAAK,GAAG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;CACA,YAAY,QAAQ;EAClB,OAAO,IAAI,sBAAsB,MAAM,MAAM;CAC/C;CACA,WAAW;EACT,KAAK,QAAQ,WAAW,IAAI;CAC9B;CACA,WAAW;EACT,KAAK,QAAQ,cAAc,IAAI;EAC/B,MAAM,SAAS;CACjB;CACA,oBAAoB,OAAO;EACzB,OAAO,MAAM,IAAI,qBAAqB,iBAAiB;CACzD;CACA,oBAAoB;EAClB,IAAI,SAAS;GACX,qBAAqB,sBAAsB,KAAK,OAAO;EACzD;EACA,OAAO;GACL,YAAY,KAAK,QAAQ;GAEzB,aAAa,KAAK,oBAAoB,KAAK,QAAQ,WAAW;GAC9D,iBAAiB,KAAK,QAAQ,mBAAmB,KAAK,QAAQ,eAAe;GAC7E,kBAAkB,KAAK,QAAQ,oBAAoB,KAAK,QAAQ,eAAe;GAC/E,MAAM;EACR;CACF;AACF;AACA,IAAI,gCAAgC"}
@@ -1 +1 @@
1
- {"version":3,"file":"AnimatedNode.js","names":[],"sources":["esm/vendor/react-native/Animated/nodes/AnimatedNode.js"],"sourcesContent":["import { NativeAnimatedHelper } from \"../NativeAnimatedHelper\";\nimport { invariant } from \"@tamagui/react-native-web-internals\";\nconst NativeAnimatedAPI = NativeAnimatedHelper.API;\nlet _uniqueId = 1;\nclass AnimatedNode {\n _listeners;\n _platformConfig;\n __nativeAnimatedValueListener;\n __attach() {\n }\n __detach() {\n if (this.__isNative && this.__nativeTag != null) {\n NativeAnimatedHelper.API.dropAnimatedNode(this.__nativeTag);\n this.__nativeTag = void 0;\n }\n }\n __getValue() {\n }\n __getAnimatedValue() {\n return this.__getValue();\n }\n __addChild(child) {\n }\n __removeChild(child) {\n }\n __getChildren() {\n return [];\n }\n /* Methods and props used by native Animated impl */\n __isNative;\n __nativeTag;\n __shouldUpdateListenersForNewNativeTag;\n constructor() {\n this._listeners = {};\n }\n __makeNative(platformConfig) {\n if (!this.__isNative) {\n throw new Error('This node cannot be made a \"native\" animated node');\n }\n this._platformConfig = platformConfig;\n if (this.hasListeners()) {\n this._startListeningToNativeValueUpdates();\n }\n }\n /**\n * Adds an asynchronous listener to the value so you can observe updates from\n * animations. This is useful because there is no way to\n * synchronously read the value because it might be driven natively.\n *\n * See https://reactnative.dev/docs/animatedvalue#addlistener\n */\n addListener(callback) {\n const id = String(_uniqueId++);\n this._listeners[id] = callback;\n if (this.__isNative) {\n this._startListeningToNativeValueUpdates();\n }\n return id;\n }\n /**\n * Unregister a listener. The `id` param shall match the identifier\n * previously returned by `addListener()`.\n *\n * See https://reactnative.dev/docs/animatedvalue#removelistener\n */\n removeListener(id) {\n delete this._listeners[id];\n if (this.__isNative && !this.hasListeners()) {\n this._stopListeningForNativeValueUpdates();\n }\n }\n /**\n * Remove all registered listeners.\n *\n * See https://reactnative.dev/docs/animatedvalue#removealllisteners\n */\n removeAllListeners() {\n this._listeners = {};\n if (this.__isNative) {\n this._stopListeningForNativeValueUpdates();\n }\n }\n hasListeners() {\n return !!Object.keys(this._listeners).length;\n }\n _startListeningToNativeValueUpdates() {\n if (this.__nativeAnimatedValueListener && !this.__shouldUpdateListenersForNewNativeTag) {\n return;\n }\n if (this.__shouldUpdateListenersForNewNativeTag) {\n this.__shouldUpdateListenersForNewNativeTag = false;\n this._stopListeningForNativeValueUpdates();\n }\n NativeAnimatedAPI.startListeningToAnimatedNodeValue(this.__getNativeTag());\n this.__nativeAnimatedValueListener = NativeAnimatedHelper.nativeEventEmitter.addListener(\n \"onAnimatedValueUpdate\",\n (data) => {\n if (data.tag !== this.__getNativeTag()) {\n return;\n }\n this.__onAnimatedValueUpdateReceived(data.value);\n }\n );\n }\n __onAnimatedValueUpdateReceived(value) {\n this.__callListeners(value);\n }\n __callListeners(value) {\n for (const key in this._listeners) {\n this._listeners[key]({ value });\n }\n }\n _stopListeningForNativeValueUpdates() {\n if (!this.__nativeAnimatedValueListener) {\n return;\n }\n this.__nativeAnimatedValueListener.remove();\n this.__nativeAnimatedValueListener = null;\n NativeAnimatedAPI.stopListeningToAnimatedNodeValue(this.__getNativeTag());\n }\n __getNativeTag() {\n NativeAnimatedHelper.assertNativeAnimatedModule();\n invariant(\n this.__isNative,\n 'Attempt to get native tag from node not marked as \"native\"'\n );\n const nativeTag = this.__nativeTag ?? NativeAnimatedHelper.generateNewNodeTag();\n if (this.__nativeTag == null) {\n this.__nativeTag = nativeTag;\n const config = this.__getNativeConfig();\n if (this._platformConfig) {\n config.platformConfig = this._platformConfig;\n }\n NativeAnimatedHelper.API.createAnimatedNode(nativeTag, config);\n this.__shouldUpdateListenersForNewNativeTag = true;\n }\n return nativeTag;\n }\n __getNativeConfig() {\n throw new Error(\"This JS animated node type cannot be used as native animated node\");\n }\n toJSON() {\n return this.__getValue();\n }\n __getPlatformConfig() {\n return this._platformConfig;\n }\n __setPlatformConfig(platformConfig) {\n this._platformConfig = platformConfig;\n }\n}\nvar AnimatedNode_default = AnimatedNode;\nexport {\n AnimatedNode,\n AnimatedNode_default as default\n};\n//# sourceMappingURL=AnimatedNode.js.map\n"],"mappings":";;;;AAEA,MAAM,oBAAoB,qBAAqB;AAC/C,IAAI,YAAY;AAChB,IAAM,eAAN,MAAmB;CACjB;CACA;CACA;CACA,WAAW,CACX;CACA,WAAW;EACT,IAAI,KAAK,cAAc,KAAK,eAAe,MAAM;GAC/C,qBAAqB,IAAI,iBAAiB,KAAK,WAAW;GAC1D,KAAK,cAAc,KAAK;EAC1B;CACF;CACA,aAAa,CACb;CACA,qBAAqB;EACnB,OAAO,KAAK,WAAW;CACzB;CACA,WAAW,OAAO,CAClB;CACA,cAAc,OAAO,CACrB;CACA,gBAAgB;EACd,OAAO,CAAC;CACV;CAEA;CACA;CACA;CACA,cAAc;EACZ,KAAK,aAAa,CAAC;CACrB;CACA,aAAa,gBAAgB;EAC3B,IAAI,CAAC,KAAK,YAAY;GACpB,MAAM,IAAI,MAAM,qDAAmD;EACrE;EACA,KAAK,kBAAkB;EACvB,IAAI,KAAK,aAAa,GAAG;GACvB,KAAK,oCAAoC;EAC3C;CACF;;;;;;;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,MAAM;GAC5B,KAAK,cAAc;GACnB,MAAM,SAAS,KAAK,kBAAkB;GACtC,IAAI,KAAK,iBAAiB;IACxB,OAAO,iBAAiB,KAAK;GAC/B;GACA,qBAAqB,IAAI,mBAAmB,WAAW,MAAM;GAC7D,KAAK,yCAAyC;EAChD;EACA,OAAO;CACT;CACA,oBAAoB;EAClB,MAAM,IAAI,MAAM,mEAAmE;CACrF;CACA,SAAS;EACP,OAAO,KAAK,WAAW;CACzB;CACA,sBAAsB;EACpB,OAAO,KAAK;CACd;CACA,oBAAoB,gBAAgB;EAClC,KAAK,kBAAkB;CACzB;AACF;AACA,IAAI,uBAAuB"}
1
+ {"version":3,"file":"AnimatedNode.js","names":[],"sources":["esm/vendor/react-native/Animated/nodes/AnimatedNode.js"],"sourcesContent":["import { NativeAnimatedHelper } from \"../NativeAnimatedHelper\";\nimport { invariant } from \"@tamagui/react-native-web-internals\";\nconst NativeAnimatedAPI = NativeAnimatedHelper.API;\nlet _uniqueId = 1;\nclass AnimatedNode {\n _listeners;\n _platformConfig;\n __nativeAnimatedValueListener;\n __attach() {\n }\n __detach() {\n if (this.__isNative && this.__nativeTag != null) {\n NativeAnimatedHelper.API.dropAnimatedNode(this.__nativeTag);\n this.__nativeTag = void 0;\n }\n }\n __getValue() {\n }\n __getAnimatedValue() {\n return this.__getValue();\n }\n __addChild(child) {\n }\n __removeChild(child) {\n }\n __getChildren() {\n return [];\n }\n /* Methods and props used by native Animated impl */\n __isNative;\n __nativeTag;\n __shouldUpdateListenersForNewNativeTag;\n constructor() {\n this._listeners = {};\n }\n __makeNative(platformConfig) {\n if (!this.__isNative) {\n throw new Error('This node cannot be made a \"native\" animated node');\n }\n this._platformConfig = platformConfig;\n if (this.hasListeners()) {\n this._startListeningToNativeValueUpdates();\n }\n }\n /**\n * Adds an asynchronous listener to the value so you can observe updates from\n * animations. This is useful because there is no way to\n * synchronously read the value because it might be driven natively.\n *\n * See https://reactnative.dev/docs/animatedvalue#addlistener\n */\n addListener(callback) {\n const id = String(_uniqueId++);\n this._listeners[id] = callback;\n if (this.__isNative) {\n this._startListeningToNativeValueUpdates();\n }\n return id;\n }\n /**\n * Unregister a listener. The `id` param shall match the identifier\n * previously returned by `addListener()`.\n *\n * See https://reactnative.dev/docs/animatedvalue#removelistener\n */\n removeListener(id) {\n delete this._listeners[id];\n if (this.__isNative && !this.hasListeners()) {\n this._stopListeningForNativeValueUpdates();\n }\n }\n /**\n * Remove all registered listeners.\n *\n * See https://reactnative.dev/docs/animatedvalue#removealllisteners\n */\n removeAllListeners() {\n this._listeners = {};\n if (this.__isNative) {\n this._stopListeningForNativeValueUpdates();\n }\n }\n hasListeners() {\n return !!Object.keys(this._listeners).length;\n }\n _startListeningToNativeValueUpdates() {\n if (this.__nativeAnimatedValueListener && !this.__shouldUpdateListenersForNewNativeTag) {\n return;\n }\n if (this.__shouldUpdateListenersForNewNativeTag) {\n this.__shouldUpdateListenersForNewNativeTag = false;\n this._stopListeningForNativeValueUpdates();\n }\n NativeAnimatedAPI.startListeningToAnimatedNodeValue(this.__getNativeTag());\n this.__nativeAnimatedValueListener = NativeAnimatedHelper.nativeEventEmitter.addListener(\n \"onAnimatedValueUpdate\",\n (data) => {\n if (data.tag !== this.__getNativeTag()) {\n return;\n }\n this.__onAnimatedValueUpdateReceived(data.value);\n }\n );\n }\n __onAnimatedValueUpdateReceived(value) {\n this.__callListeners(value);\n }\n __callListeners(value) {\n for (const key in this._listeners) {\n this._listeners[key]({ value });\n }\n }\n _stopListeningForNativeValueUpdates() {\n if (!this.__nativeAnimatedValueListener) {\n return;\n }\n this.__nativeAnimatedValueListener.remove();\n this.__nativeAnimatedValueListener = null;\n NativeAnimatedAPI.stopListeningToAnimatedNodeValue(this.__getNativeTag());\n }\n __getNativeTag() {\n NativeAnimatedHelper.assertNativeAnimatedModule();\n invariant(\n this.__isNative,\n 'Attempt to get native tag from node not marked as \"native\"'\n );\n const nativeTag = this.__nativeTag ?? NativeAnimatedHelper.generateNewNodeTag();\n if (this.__nativeTag == null) {\n this.__nativeTag = nativeTag;\n const config = this.__getNativeConfig();\n if (this._platformConfig) {\n config.platformConfig = this._platformConfig;\n }\n NativeAnimatedHelper.API.createAnimatedNode(nativeTag, config);\n this.__shouldUpdateListenersForNewNativeTag = true;\n }\n return nativeTag;\n }\n __getNativeConfig() {\n throw new Error(\"This JS animated node type cannot be used as native animated node\");\n }\n toJSON() {\n return this.__getValue();\n }\n __getPlatformConfig() {\n return this._platformConfig;\n }\n __setPlatformConfig(platformConfig) {\n this._platformConfig = platformConfig;\n }\n}\nvar AnimatedNode_default = AnimatedNode;\nexport {\n AnimatedNode,\n AnimatedNode_default as default\n};\n//# sourceMappingURL=AnimatedNode.js.map\n"],"mappings":";;;;AAEA,MAAM,oBAAoB,qBAAqB;AAC/C,IAAI,YAAY;AAChB,IAAM,eAAN,MAAmB;CACjB;CACA;CACA;CACA,WAAW,CACX;CACA,WAAW;EACT,IAAI,KAAK,cAAc,KAAK,eAAe,MAAM;GAC/C,qBAAqB,IAAI,iBAAiB,KAAK,WAAW;GAC1D,KAAK,cAAc,KAAK;EAC1B;CACF;CACA,aAAa,CACb;CACA,qBAAqB;EACnB,OAAO,KAAK,WAAW;CACzB;CACA,WAAW,OAAO,CAClB;CACA,cAAc,OAAO,CACrB;CACA,gBAAgB;EACd,OAAO,CAAC;CACV;CAEA;CACA;CACA;CACA,cAAc;EACZ,KAAK,aAAa,CAAC;CACrB;CACA,aAAa,gBAAgB;EAC3B,IAAI,CAAC,KAAK,YAAY;GACpB,MAAM,IAAI,MAAM,qDAAmD;EACrE;EACA,KAAK,kBAAkB;EACvB,IAAI,KAAK,aAAa,GAAG;GACvB,KAAK,oCAAoC;EAC3C;CACF;;;;;;;;CAQA,YAAY,UAAU;EACpB,MAAM,KAAK,OAAO,WAAW;EAC7B,KAAK,WAAW,MAAM;EACtB,IAAI,KAAK,YAAY;GACnB,KAAK,oCAAoC;EAC3C;EACA,OAAO;CACT;;;;;;;CAOA,eAAe,IAAI;EAC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