@shopify/flash-list 1.0.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 (206) hide show
  1. package/CHANGELOG.md +159 -0
  2. package/LICENSE.md +7 -0
  3. package/README.md +65 -0
  4. package/RNFlashList.podspec +26 -0
  5. package/android/build.gradle +59 -0
  6. package/android/src/main/AndroidManifest.xml +3 -0
  7. package/android/src/main/kotlin/com/shopify/reactnative/flash_list/AutoLayoutShadow.kt +94 -0
  8. package/android/src/main/kotlin/com/shopify/reactnative/flash_list/AutoLayoutView.kt +79 -0
  9. package/android/src/main/kotlin/com/shopify/reactnative/flash_list/AutoLayoutViewManager.kt +69 -0
  10. package/android/src/main/kotlin/com/shopify/reactnative/flash_list/CellContainer.java +16 -0
  11. package/android/src/main/kotlin/com/shopify/reactnative/flash_list/CellContainerImpl.kt +16 -0
  12. package/android/src/main/kotlin/com/shopify/reactnative/flash_list/CellContainerManager.kt +27 -0
  13. package/android/src/main/kotlin/com/shopify/reactnative/flash_list/FlashListPackage.kt +19 -0
  14. package/android/src/test/java/com/shopify/reactnative/flash_list/AutoLayoutShadowTest.kt +146 -0
  15. package/android/src/test/java/com/shopify/reactnative/flash_list/models/Rect.kt +59 -0
  16. package/android/src/test/java/com/shopify/reactnative/flash_list/models/TestCollection.kt +6 -0
  17. package/android/src/test/java/com/shopify/reactnative/flash_list/models/TestDataModel.kt +8 -0
  18. package/android/src/test/resources/LayoutTestData.json +708 -0
  19. package/dist/AnimatedFlashList.d.ts +6 -0
  20. package/dist/AnimatedFlashList.d.ts.map +1 -0
  21. package/dist/AnimatedFlashList.js +8 -0
  22. package/dist/AnimatedFlashList.js.map +1 -0
  23. package/dist/FlashList.d.ts +121 -0
  24. package/dist/FlashList.d.ts.map +1 -0
  25. package/dist/FlashList.js +502 -0
  26. package/dist/FlashList.js.map +1 -0
  27. package/dist/FlashListProps.d.ts +251 -0
  28. package/dist/FlashListProps.d.ts.map +1 -0
  29. package/dist/FlashListProps.js +3 -0
  30. package/dist/FlashListProps.js.map +1 -0
  31. package/dist/GridLayoutProviderWithProps.d.ts +30 -0
  32. package/dist/GridLayoutProviderWithProps.d.ts.map +1 -0
  33. package/dist/GridLayoutProviderWithProps.js +80 -0
  34. package/dist/GridLayoutProviderWithProps.js.map +1 -0
  35. package/dist/PureComponentWrapper.d.ts +22 -0
  36. package/dist/PureComponentWrapper.d.ts.map +1 -0
  37. package/dist/PureComponentWrapper.js +37 -0
  38. package/dist/PureComponentWrapper.js.map +1 -0
  39. package/dist/__tests__/AverageWindow.test.d.ts +2 -0
  40. package/dist/__tests__/AverageWindow.test.d.ts.map +1 -0
  41. package/dist/__tests__/AverageWindow.test.js +69 -0
  42. package/dist/__tests__/AverageWindow.test.js.map +1 -0
  43. package/dist/__tests__/FlashList.test.d.ts +2 -0
  44. package/dist/__tests__/FlashList.test.d.ts.map +1 -0
  45. package/dist/__tests__/FlashList.test.js +656 -0
  46. package/dist/__tests__/FlashList.test.js.map +1 -0
  47. package/dist/__tests__/GridLayoutProviderWithProps.test.d.ts +2 -0
  48. package/dist/__tests__/GridLayoutProviderWithProps.test.d.ts.map +1 -0
  49. package/dist/__tests__/GridLayoutProviderWithProps.test.js +133 -0
  50. package/dist/__tests__/GridLayoutProviderWithProps.test.js.map +1 -0
  51. package/dist/__tests__/PlatformHelper.web.test.d.ts +2 -0
  52. package/dist/__tests__/PlatformHelper.web.test.d.ts.map +1 -0
  53. package/dist/__tests__/PlatformHelper.web.test.js +25 -0
  54. package/dist/__tests__/PlatformHelper.web.test.js.map +1 -0
  55. package/dist/__tests__/ViewabilityHelper.test.d.ts +2 -0
  56. package/dist/__tests__/ViewabilityHelper.test.d.ts.map +1 -0
  57. package/dist/__tests__/ViewabilityHelper.test.js +187 -0
  58. package/dist/__tests__/ViewabilityHelper.test.js.map +1 -0
  59. package/dist/__tests__/helpers/mountFlashList.d.ts +20 -0
  60. package/dist/__tests__/helpers/mountFlashList.d.ts.map +1 -0
  61. package/dist/__tests__/helpers/mountFlashList.js +44 -0
  62. package/dist/__tests__/helpers/mountFlashList.js.map +1 -0
  63. package/dist/__tests__/useBlankAreaTracker.test.d.ts +2 -0
  64. package/dist/__tests__/useBlankAreaTracker.test.d.ts.map +1 -0
  65. package/dist/__tests__/useBlankAreaTracker.test.js +179 -0
  66. package/dist/__tests__/useBlankAreaTracker.test.js.map +1 -0
  67. package/dist/benchmark/AutoScrollHelper.d.ts +18 -0
  68. package/dist/benchmark/AutoScrollHelper.d.ts.map +1 -0
  69. package/dist/benchmark/AutoScrollHelper.js +68 -0
  70. package/dist/benchmark/AutoScrollHelper.js.map +1 -0
  71. package/dist/benchmark/JSFPSMonitor.d.ts +23 -0
  72. package/dist/benchmark/JSFPSMonitor.d.ts.map +1 -0
  73. package/dist/benchmark/JSFPSMonitor.js +65 -0
  74. package/dist/benchmark/JSFPSMonitor.js.map +1 -0
  75. package/dist/benchmark/roundToDecimalPlaces.d.ts +2 -0
  76. package/dist/benchmark/roundToDecimalPlaces.d.ts.map +1 -0
  77. package/dist/benchmark/roundToDecimalPlaces.js +9 -0
  78. package/dist/benchmark/roundToDecimalPlaces.js.map +1 -0
  79. package/dist/benchmark/useBenchmark.d.ts +35 -0
  80. package/dist/benchmark/useBenchmark.d.ts.map +1 -0
  81. package/dist/benchmark/useBenchmark.js +167 -0
  82. package/dist/benchmark/useBenchmark.js.map +1 -0
  83. package/dist/benchmark/useBlankAreaTracker.d.ts +34 -0
  84. package/dist/benchmark/useBlankAreaTracker.d.ts.map +1 -0
  85. package/dist/benchmark/useBlankAreaTracker.js +67 -0
  86. package/dist/benchmark/useBlankAreaTracker.js.map +1 -0
  87. package/dist/benchmark/useDataMultiplier.d.ts +9 -0
  88. package/dist/benchmark/useDataMultiplier.d.ts.map +1 -0
  89. package/dist/benchmark/useDataMultiplier.js +25 -0
  90. package/dist/benchmark/useDataMultiplier.js.map +1 -0
  91. package/dist/benchmark/useFlatListBenchmark.d.ts +13 -0
  92. package/dist/benchmark/useFlatListBenchmark.d.ts.map +1 -0
  93. package/dist/benchmark/useFlatListBenchmark.js +100 -0
  94. package/dist/benchmark/useFlatListBenchmark.js.map +1 -0
  95. package/dist/errors/CustomError.d.ts +8 -0
  96. package/dist/errors/CustomError.d.ts.map +1 -0
  97. package/dist/errors/CustomError.js +14 -0
  98. package/dist/errors/CustomError.js.map +1 -0
  99. package/dist/errors/ExceptionList.d.ts +20 -0
  100. package/dist/errors/ExceptionList.d.ts.map +1 -0
  101. package/dist/errors/ExceptionList.js +22 -0
  102. package/dist/errors/ExceptionList.js.map +1 -0
  103. package/dist/errors/Warnings.d.ts +10 -0
  104. package/dist/errors/Warnings.d.ts.map +1 -0
  105. package/dist/errors/Warnings.js +15 -0
  106. package/dist/errors/Warnings.js.map +1 -0
  107. package/dist/index.d.ts +13 -0
  108. package/dist/index.d.ts.map +1 -0
  109. package/dist/index.js +28 -0
  110. package/dist/index.js.map +1 -0
  111. package/dist/native/auto-layout/AutoLayoutView.d.ts +21 -0
  112. package/dist/native/auto-layout/AutoLayoutView.d.ts.map +1 -0
  113. package/dist/native/auto-layout/AutoLayoutView.js +48 -0
  114. package/dist/native/auto-layout/AutoLayoutView.js.map +1 -0
  115. package/dist/native/auto-layout/AutoLayoutViewNativeComponent.d.ts +4 -0
  116. package/dist/native/auto-layout/AutoLayoutViewNativeComponent.d.ts.map +1 -0
  117. package/dist/native/auto-layout/AutoLayoutViewNativeComponent.js +6 -0
  118. package/dist/native/auto-layout/AutoLayoutViewNativeComponent.js.map +1 -0
  119. package/dist/native/auto-layout/AutoLayoutViewNativeComponent.web.d.ts +5 -0
  120. package/dist/native/auto-layout/AutoLayoutViewNativeComponent.web.d.ts.map +1 -0
  121. package/dist/native/auto-layout/AutoLayoutViewNativeComponent.web.js +6 -0
  122. package/dist/native/auto-layout/AutoLayoutViewNativeComponent.web.js.map +1 -0
  123. package/dist/native/auto-layout/AutoLayoutViewNativeComponentProps.d.ts +14 -0
  124. package/dist/native/auto-layout/AutoLayoutViewNativeComponentProps.d.ts.map +1 -0
  125. package/dist/native/auto-layout/AutoLayoutViewNativeComponentProps.js +3 -0
  126. package/dist/native/auto-layout/AutoLayoutViewNativeComponentProps.js.map +1 -0
  127. package/dist/native/cell-container/CellContainer.d.ts +6 -0
  128. package/dist/native/cell-container/CellContainer.d.ts.map +1 -0
  129. package/dist/native/cell-container/CellContainer.js +9 -0
  130. package/dist/native/cell-container/CellContainer.js.map +1 -0
  131. package/dist/native/cell-container/CellContainer.web.d.ts +7 -0
  132. package/dist/native/cell-container/CellContainer.web.d.ts.map +1 -0
  133. package/dist/native/cell-container/CellContainer.web.js +13 -0
  134. package/dist/native/cell-container/CellContainer.web.js.map +1 -0
  135. package/dist/tsconfig.tsbuildinfo +1 -0
  136. package/dist/utils/AverageWindow.d.ts +21 -0
  137. package/dist/utils/AverageWindow.d.ts.map +1 -0
  138. package/dist/utils/AverageWindow.js +49 -0
  139. package/dist/utils/AverageWindow.js.map +1 -0
  140. package/dist/utils/PlatformHelper.d.ts +14 -0
  141. package/dist/utils/PlatformHelper.d.ts.map +1 -0
  142. package/dist/utils/PlatformHelper.js +16 -0
  143. package/dist/utils/PlatformHelper.js.map +1 -0
  144. package/dist/utils/PlatformHelper.web.d.ts +14 -0
  145. package/dist/utils/PlatformHelper.web.d.ts.map +1 -0
  146. package/dist/utils/PlatformHelper.web.js +18 -0
  147. package/dist/utils/PlatformHelper.web.js.map +1 -0
  148. package/dist/viewability/ViewToken.d.ts +8 -0
  149. package/dist/viewability/ViewToken.d.ts.map +1 -0
  150. package/dist/viewability/ViewToken.js +3 -0
  151. package/dist/viewability/ViewToken.js.map +1 -0
  152. package/dist/viewability/ViewabilityHelper.d.ts +25 -0
  153. package/dist/viewability/ViewabilityHelper.d.ts.map +1 -0
  154. package/dist/viewability/ViewabilityHelper.js +104 -0
  155. package/dist/viewability/ViewabilityHelper.js.map +1 -0
  156. package/dist/viewability/ViewabilityManager.d.ts +24 -0
  157. package/dist/viewability/ViewabilityManager.d.ts.map +1 -0
  158. package/dist/viewability/ViewabilityManager.js +94 -0
  159. package/dist/viewability/ViewabilityManager.js.map +1 -0
  160. package/ios/RNFlashList.xcodeproj/project.pbxproj +3 -0
  161. package/ios/RNFlashList.xcodeproj/project.xcworkspace/contents.xcworkspacedata +4 -0
  162. package/ios/Sources/AutoLayoutView.swift +218 -0
  163. package/ios/Sources/AutoLayoutViewManager.m +14 -0
  164. package/ios/Sources/AutoLayoutViewManager.swift +12 -0
  165. package/ios/Sources/CellContainer.swift +9 -0
  166. package/ios/Sources/CellContainerManager.m +8 -0
  167. package/ios/Sources/CellContainerManager.swift +12 -0
  168. package/ios/Sources/FlatListPro-Bridging-Header.h +8 -0
  169. package/ios/Tests/AutoLayoutViewTests.swift +113 -0
  170. package/jestSetup.js +15 -0
  171. package/package.json +75 -0
  172. package/src/AnimatedFlashList.ts +11 -0
  173. package/src/FlashList.tsx +801 -0
  174. package/src/FlashListProps.ts +312 -0
  175. package/src/GridLayoutProviderWithProps.ts +137 -0
  176. package/src/PureComponentWrapper.tsx +42 -0
  177. package/src/__tests__/AverageWindow.test.ts +80 -0
  178. package/src/__tests__/FlashList.test.tsx +738 -0
  179. package/src/__tests__/GridLayoutProviderWithProps.test.ts +150 -0
  180. package/src/__tests__/PlatformHelper.web.test.ts +29 -0
  181. package/src/__tests__/ViewabilityHelper.test.ts +283 -0
  182. package/src/__tests__/helpers/mountFlashList.tsx +62 -0
  183. package/src/__tests__/useBlankAreaTracker.test.tsx +206 -0
  184. package/src/benchmark/AutoScrollHelper.ts +70 -0
  185. package/src/benchmark/JSFPSMonitor.ts +74 -0
  186. package/src/benchmark/roundToDecimalPlaces.ts +4 -0
  187. package/src/benchmark/useBenchmark.ts +240 -0
  188. package/src/benchmark/useBlankAreaTracker.ts +117 -0
  189. package/src/benchmark/useDataMultiplier.ts +19 -0
  190. package/src/benchmark/useFlatListBenchmark.ts +107 -0
  191. package/src/errors/CustomError.ts +10 -0
  192. package/src/errors/ExceptionList.ts +23 -0
  193. package/src/errors/Warnings.ts +18 -0
  194. package/src/index.ts +32 -0
  195. package/src/native/auto-layout/AutoLayoutView.tsx +72 -0
  196. package/src/native/auto-layout/AutoLayoutViewNativeComponent.ts +7 -0
  197. package/src/native/auto-layout/AutoLayoutViewNativeComponent.web.ts +8 -0
  198. package/src/native/auto-layout/AutoLayoutViewNativeComponentProps.ts +14 -0
  199. package/src/native/cell-container/CellContainer.ts +7 -0
  200. package/src/native/cell-container/CellContainer.web.tsx +9 -0
  201. package/src/utils/AverageWindow.ts +49 -0
  202. package/src/utils/PlatformHelper.ts +16 -0
  203. package/src/utils/PlatformHelper.web.ts +20 -0
  204. package/src/viewability/ViewToken.ts +7 -0
  205. package/src/viewability/ViewabilityHelper.ts +162 -0
  206. package/src/viewability/ViewabilityManager.ts +133 -0
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Behaves as a regular `View` with an extra `index` prop that is saved in the native layer.
3
+ */
4
+ declare const CellContainer: import("react-native").HostComponent<unknown>;
5
+ export default CellContainer;
6
+ //# sourceMappingURL=CellContainer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CellContainer.d.ts","sourceRoot":"","sources":["../../../src/native/cell-container/CellContainer.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,QAAA,MAAM,aAAa,+CAA0C,CAAC;AAC9D,eAAe,aAAa,CAAC"}
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var react_native_1 = require("react-native");
4
+ /**
5
+ * Behaves as a regular `View` with an extra `index` prop that is saved in the native layer.
6
+ */
7
+ var CellContainer = (0, react_native_1.requireNativeComponent)("CellContainer");
8
+ exports.default = CellContainer;
9
+ //# sourceMappingURL=CellContainer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CellContainer.js","sourceRoot":"","sources":["../../../src/native/cell-container/CellContainer.ts"],"names":[],"mappings":";;AAAA,6CAAsD;AAEtD;;GAEG;AACH,IAAM,aAAa,GAAG,IAAA,qCAAsB,EAAC,eAAe,CAAC,CAAC;AAC9D,kBAAe,aAAa,CAAC"}
@@ -0,0 +1,7 @@
1
+ import React from "react";
2
+ /**
3
+ * On web we use a view instead of cell container till we build native web implementations
4
+ */
5
+ declare const CellContainer: React.ForwardRefExoticComponent<Pick<any, string | number | symbol> & React.RefAttributes<unknown>>;
6
+ export default CellContainer;
7
+ //# sourceMappingURL=CellContainer.web.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CellContainer.web.d.ts","sourceRoot":"","sources":["../../../src/native/cell-container/CellContainer.web.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B;;GAEG;AACH,QAAA,MAAM,aAAa,qGAEjB,CAAC;AAEH,eAAe,aAAa,CAAC"}
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var tslib_1 = require("tslib");
4
+ var react_1 = tslib_1.__importDefault(require("react"));
5
+ /**
6
+ * On web we use a view instead of cell container till we build native web implementations
7
+ */
8
+ var CellContainer = react_1.default.forwardRef(function (props, ref) {
9
+ return react_1.default.createElement("div", tslib_1.__assign({ ref: ref }, props));
10
+ });
11
+ CellContainer.displayName = "CellContainer";
12
+ exports.default = CellContainer;
13
+ //# sourceMappingURL=CellContainer.web.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CellContainer.web.js","sourceRoot":"","sources":["../../../src/native/cell-container/CellContainer.web.tsx"],"names":[],"mappings":";;;AAAA,wDAA0B;AAC1B;;GAEG;AACH,IAAM,aAAa,GAAG,eAAK,CAAC,UAAU,CAAC,UAAC,KAAU,EAAE,GAAG;IACrD,OAAO,wDAAK,GAAG,EAAE,GAAG,IAAM,KAAK,EAAI,CAAC;AACtC,CAAC,CAAC,CAAC;AACH,aAAa,CAAC,WAAW,GAAG,eAAe,CAAC;AAC5C,kBAAe,aAAa,CAAC"}
@@ -0,0 +1 @@
1
+ {"program":{"fileNames":["../node_modules/typescript/lib/lib.es5.d.ts","../node_modules/typescript/lib/lib.es2015.d.ts","../node_modules/typescript/lib/lib.es2016.d.ts","../node_modules/typescript/lib/lib.es2017.d.ts","../node_modules/typescript/lib/lib.es2018.d.ts","../node_modules/typescript/lib/lib.es2019.d.ts","../node_modules/typescript/lib/lib.es2020.d.ts","../node_modules/typescript/lib/lib.dom.d.ts","../node_modules/typescript/lib/lib.dom.iterable.d.ts","../node_modules/typescript/lib/lib.es2015.core.d.ts","../node_modules/typescript/lib/lib.es2015.collection.d.ts","../node_modules/typescript/lib/lib.es2015.generator.d.ts","../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../node_modules/typescript/lib/lib.es2015.promise.d.ts","../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../node_modules/typescript/lib/lib.es2017.object.d.ts","../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../node_modules/typescript/lib/lib.es2017.string.d.ts","../node_modules/typescript/lib/lib.es2017.intl.d.ts","../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../node_modules/typescript/lib/lib.es2018.intl.d.ts","../node_modules/typescript/lib/lib.es2018.promise.d.ts","../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../node_modules/typescript/lib/lib.es2019.array.d.ts","../node_modules/typescript/lib/lib.es2019.object.d.ts","../node_modules/typescript/lib/lib.es2019.string.d.ts","../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../node_modules/typescript/lib/lib.es2020.date.d.ts","../node_modules/typescript/lib/lib.es2020.promise.d.ts","../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../node_modules/typescript/lib/lib.es2020.string.d.ts","../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../node_modules/typescript/lib/lib.es2020.intl.d.ts","../node_modules/typescript/lib/lib.es2020.number.d.ts","../node_modules/typescript/lib/lib.esnext.intl.d.ts","../node_modules/tslib/tslib.d.ts","../node_modules/@types/react-native/globals.d.ts","../node_modules/@types/react-native/legacy-properties.d.ts","../node_modules/@types/react-native/BatchedBridge.d.ts","../node_modules/@types/react-native/Devtools.d.ts","../node_modules/@types/react-native/LaunchScreen.d.ts","../node_modules/@types/react/global.d.ts","../node_modules/csstype/index.d.ts","../node_modules/@types/prop-types/index.d.ts","../node_modules/@types/scheduler/tracing.d.ts","../node_modules/@types/react/index.d.ts","../node_modules/@types/react-native/index.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/dependencies/ContextProvider.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/dependencies/DataProvider.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/layoutmanager/LayoutManager.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/dependencies/LayoutProvider.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/dependencies/GridLayoutProvider.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/scrollcomponent/BaseScrollView.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/ViewabilityTracker.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/VirtualRenderer.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/ItemAnimator.d.ts","../node_modules/recyclerlistview/dist/reactnative/utils/ComponentCompat.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/RecyclerListView.d.ts","../node_modules/recyclerlistview/dist/reactnative/utils/AutoScroll.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/layoutmanager/GridLayoutManager.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/ProgressiveListView.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/devutils/debughandlers/resize/ResizeDebugHandler.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/devutils/debughandlers/DebugHandlers.d.ts","../node_modules/recyclerlistview/dist/reactnative/index.d.ts","../node_modules/recyclerlistview/dist/reactnative/core/StickyContainer.d.ts","../node_modules/recyclerlistview/sticky/index.d.ts","../src/native/auto-layout/AutoLayoutViewNativeComponentProps.ts","../src/native/auto-layout/AutoLayoutViewNativeComponent.ts","../src/native/auto-layout/AutoLayoutView.tsx","../src/native/cell-container/CellContainer.ts","../src/PureComponentWrapper.tsx","../src/viewability/ViewToken.ts","../src/FlashListProps.ts","../src/utils/AverageWindow.ts","../src/GridLayoutProviderWithProps.ts","../src/errors/CustomError.ts","../src/errors/ExceptionList.ts","../src/errors/Warnings.ts","../src/viewability/ViewabilityHelper.ts","../src/viewability/ViewabilityManager.ts","../src/utils/PlatformHelper.ts","../src/FlashList.tsx","../src/AnimatedFlashList.ts","../src/benchmark/AutoScrollHelper.ts","../src/benchmark/roundToDecimalPlaces.ts","../src/benchmark/JSFPSMonitor.ts","../src/benchmark/useBlankAreaTracker.ts","../src/benchmark/useBenchmark.ts","../src/benchmark/useDataMultiplier.ts","../src/benchmark/useFlatListBenchmark.ts","../src/index.ts","../src/__tests__/AverageWindow.test.ts","../node_modules/@quilted/react-testing/build/typescript/types.d.ts","../node_modules/@quilted/react-testing/build/typescript/matchers/index.d.ts","../node_modules/@quilted/react-testing/build/typescript/environment.d.ts","../node_modules/@quilted/react-testing/build/typescript/implementations/test-renderer.d.ts","../node_modules/@quilted/react-testing/build/typescript/index.d.ts","../src/__tests__/helpers/mountFlashList.tsx","../src/__tests__/FlashList.test.tsx","../src/__tests__/GridLayoutProviderWithProps.test.ts","../node_modules/recyclerlistview/dist/reactnative/platform/reactnative/itemanimators/defaultjsanimator/DefaultJSItemAnimator.d.ts","../src/utils/PlatformHelper.web.ts","../src/__tests__/PlatformHelper.web.test.ts","../src/__tests__/ViewabilityHelper.test.ts","../src/__tests__/useBlankAreaTracker.test.tsx","../src/native/auto-layout/AutoLayoutViewNativeComponent.web.ts","../src/native/cell-container/CellContainer.web.tsx","../node_modules/@babel/types/lib/index.d.ts","../node_modules/@types/babel__generator/index.d.ts","../node_modules/@babel/parser/typings/babel-parser.d.ts","../node_modules/@types/babel__template/index.d.ts","../node_modules/@types/babel__traverse/index.d.ts","../node_modules/@types/babel__core/index.d.ts","../node_modules/@types/node/assert.d.ts","../node_modules/@types/node/assert/strict.d.ts","../node_modules/@types/node/globals.d.ts","../node_modules/@types/node/async_hooks.d.ts","../node_modules/@types/node/buffer.d.ts","../node_modules/@types/node/child_process.d.ts","../node_modules/@types/node/cluster.d.ts","../node_modules/@types/node/console.d.ts","../node_modules/@types/node/constants.d.ts","../node_modules/@types/node/crypto.d.ts","../node_modules/@types/node/dgram.d.ts","../node_modules/@types/node/diagnostics_channel.d.ts","../node_modules/@types/node/dns.d.ts","../node_modules/@types/node/dns/promises.d.ts","../node_modules/@types/node/domain.d.ts","../node_modules/@types/node/events.d.ts","../node_modules/@types/node/fs.d.ts","../node_modules/@types/node/fs/promises.d.ts","../node_modules/@types/node/http.d.ts","../node_modules/@types/node/http2.d.ts","../node_modules/@types/node/https.d.ts","../node_modules/@types/node/inspector.d.ts","../node_modules/@types/node/module.d.ts","../node_modules/@types/node/net.d.ts","../node_modules/@types/node/os.d.ts","../node_modules/@types/node/path.d.ts","../node_modules/@types/node/perf_hooks.d.ts","../node_modules/@types/node/process.d.ts","../node_modules/@types/node/punycode.d.ts","../node_modules/@types/node/querystring.d.ts","../node_modules/@types/node/readline.d.ts","../node_modules/@types/node/repl.d.ts","../node_modules/@types/node/stream.d.ts","../node_modules/@types/node/stream/promises.d.ts","../node_modules/@types/node/stream/consumers.d.ts","../node_modules/@types/node/stream/web.d.ts","../node_modules/@types/node/string_decoder.d.ts","../node_modules/@types/node/timers.d.ts","../node_modules/@types/node/timers/promises.d.ts","../node_modules/@types/node/tls.d.ts","../node_modules/@types/node/trace_events.d.ts","../node_modules/@types/node/tty.d.ts","../node_modules/@types/node/url.d.ts","../node_modules/@types/node/util.d.ts","../node_modules/@types/node/v8.d.ts","../node_modules/@types/node/vm.d.ts","../node_modules/@types/node/wasi.d.ts","../node_modules/@types/node/worker_threads.d.ts","../node_modules/@types/node/zlib.d.ts","../node_modules/@types/node/globals.global.d.ts","../node_modules/@types/node/index.d.ts","../node_modules/@types/graceful-fs/index.d.ts","../node_modules/@types/istanbul-lib-coverage/index.d.ts","../node_modules/@types/istanbul-lib-report/index.d.ts","../node_modules/@types/istanbul-reports/index.d.ts","../node_modules/chalk/index.d.ts","../node_modules/@sinclair/typebox/typebox.d.ts","../node_modules/@jest/schemas/build/index.d.ts","../node_modules/pretty-format/build/index.d.ts","../node_modules/jest-diff/build/index.d.ts","../node_modules/jest-matcher-utils/build/index.d.ts","../node_modules/@types/jest/index.d.ts","../node_modules/@types/json-schema/index.d.ts","../node_modules/@types/json5/index.d.ts","../node_modules/@types/parse-json/index.d.ts","../node_modules/@types/prettier/index.d.ts","../node_modules/@types/react-test-renderer/index.d.ts","../node_modules/@types/scheduler/index.d.ts","../node_modules/@types/stack-utils/index.d.ts","../node_modules/@types/websocket/index.d.ts","../node_modules/@types/yargs-parser/index.d.ts","../node_modules/@types/yargs/index.d.ts"],"fileInfos":[{"version":"f5c28122bee592cfaf5c72ed7bcc47f453b79778ffa6e301f45d21a0970719d4","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","e6b724280c694a9f588847f754198fb96c43d805f065c3a5b28bbc9594541c84","1fc5ab7a764205c68fa10d381b08417795fc73111d6dd16b5b1ed36badb743d9",{"version":"3f149f903dd20dfeb7c80e228b659f0e436532de772469980dbd00702cc05cc1","affectsGlobalScope":true},{"version":"1272277fe7daa738e555eb6cc45ded42cc2d0f76c07294142283145d49e96186","affectsGlobalScope":true},{"version":"adb996790133eb33b33aadb9c09f15c2c575e71fb57a62de8bf74dbf59ec7dfb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"181f1784c6c10b751631b24ce60c7f78b20665db4550b335be179217bacc0d5f","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"09aa50414b80c023553090e2f53827f007a301bc34b0495bfb2c3c08ab9ad1eb","affectsGlobalScope":true},{"version":"d7f680a43f8cd12a6b6122c07c54ba40952b0c8aa140dcfcf32eb9e6cb028596","affectsGlobalScope":true},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"cd483c056da900716879771893a3c9772b66c3c88f8943b4205aec738a94b1d0","affectsGlobalScope":true},{"version":"b248e32ca52e8f5571390a4142558ae4f203ae2f94d5bac38a3084d529ef4e58","affectsGlobalScope":true},{"version":"c37f8a49593a0030eecb51bbfa270e709bec9d79a6cc3bb851ef348d4e6b26f8","affectsGlobalScope":true},"12f4cfe2fe60b810c3174537bc2ddb20c1067b7768643d12cb1266fd183afb75",{"version":"4452f559618410bd9950973795fa657dbf3411cdc55c4c3460c5bab189903863","affectsGlobalScope":true},"9e9df0ee50fc117b15fd7815162a41c46e95996b513e4107b433d3e37dbe2ce8",{"version":"efd32b1ab5e3897f64ed3d0f236657c3c9c7bcc669449e608ebee1ad9dbe396a","affectsGlobalScope":true},"7fb3279c4bf36d993b1e8b339cded5908f7b2ec1b6e0ac2feaa842b5b6b143f1","234b97ac9af46707f2315ff395a9b340d37b7dbc8290d91f5d6bd97189d220f3",{"version":"ecf78e637f710f340ec08d5d92b3f31b134a46a4fcf2e758690d8c46ce62cba6","affectsGlobalScope":true},"ea0aa24a32c073b8639aa1f3130ba0add0f0f2f76b314d9ba988a5cb91d7e3c4","f7b46d22a307739c145e5fddf537818038fdfffd580d79ed717f4d4d37249380","f5a8b384f182b3851cec3596ccc96cb7464f8d3469f48c74bf2befb782a19de5",{"version":"29b8a3a533884705024eab54e56465614ad167f5dd87fdc2567d8e451f747224","affectsGlobalScope":true},{"version":"c346273e3b558c2ae42fd275c4b20a0bf3087d9cd5d0fb6013472c8879d46b3d","affectsGlobalScope":true},"590a41ccab332c66a6aa62746612b03ceb2e92cc1da58c140e90fb7ff6e8c851","dc1d2996f23fe7f0da0b2c843e05c0ac170a36b51da11e58de089d344de93c3b","78ff01b50e7e9761f239527ec70b96171bccc28a08d909243e193db03b6f6983","ed18472ee2247563a26d754dd4c8bd66383013df13ce7c2927b03cab1a27b7e8","28ac9ac1fa163e5f2321fafa49b9931908c0076216ed3c82646d79abdf79775e","07dd4bed8ddab685f82a2125bf3aa41b42e36f28c16a5aec7357b727649076fb","fc15a2216f29b825747c0c3a54d6989518dd0f4aa0b580520e5526b4a47bec8f","c656d5baf3d4a8f358fc083db04b0fda8cb8503a613a9ba42327ecbd7909773c","397c2c81eaeae1388f7459699d7606feecfc304b212eb9113407c1315746a578","c2d923e9adc26a3efe5186f3a4a72413d24c80f03b306c68c30fa146690fb101","d34782833b7d5f72486a5fb926d3d96198706ed76aeaf1d435c748ebcf9169fc","b093e56054755189dd891ea832dec40d729d110a0a3f432fff5ea5ab1078cdde","98affe620e6230a3888b445c32376e4edbf6b1b376a71f2bf9c07bee11fcdd65","1e05491bef32ff48393d605d557152735899da3d9b111ba3588a1800f2927f4a","1ff7813974b1b9a0524c1e5a99aa52a05e79fc7df7749ada75ded8c53fe1b7e0","cd8c517f54d4ff3475755b290d741c8799df3265ce73d454d8fafe423f8ff749","bf431147b104ae92d61de6b43e9f25d27e8d3eaeaffd612e0c0d3bb8e2423926","f0f21604ae8f880c0ab529f00303806fdeadc943e32a25ca063fc8fea0fa063c","8dc4f45212fba9381e1674e8bd934a588730efbb8a6681b661cad8cd09b081c5",{"version":"c2e5f42ee5c7739690f71376cdfd143b987c0d055cde586af9f29e79186847ac","signature":"a630af6691c60fa307adb874f57149a8781a93aa0a992abbb318e35bdc1a9a07"},{"version":"377ba49d29102653a4b0c72b3870f9c599575df7db3a3fae7a21be5327ff84e2","signature":"c47f5db4df0a5031ed84bc6ee192c412b9e2d4d5e94681af77ccdcc25c851839"},{"version":"109c35cff8e6e4e15aca6e498350e211d6039a7e7b272a35b05956627debba65","signature":"c8043e1efbb5c429235e2e15dc68119dc4239602132cdb25ecb2eea8ee256d0a"},{"version":"39833acf7547216b2f31b2279dcfec3ed1359dec8adc9d1cb87c695ebf9bff94","signature":"7292d4dc9dac6d815dc30245a4a4a4959845d3a2b84ba0166857e4b23f2d033f"},{"version":"84c5fc9d0d22f4566791b88d5fc2c24f56508b50c9ce894ac549ebaa158b1fca","signature":"677ea66c6fa02f1cebf82df19f416a8302c7a7d10e2de265b162760fcd865eef"},{"version":"8455135ea42310a73404fa2513e212d170af1191584061f583ec1e0f6b75dd91","signature":"83e4298f0b6834e955ee6a76569d3e5b3192065d47f1daf4535bb9edb16e88cb"},{"version":"d6e4e0f19d1799e110b4ccf89984989f1835dcfdf385528780c6f8a424a84c8e","signature":"c6fd3e16726097fa07a7f1cf894f079155d9dc407e7289625d1c2ca45648c802"},{"version":"9856c4cf9bed38fd64486c25263e3c931f43c2cfa8ec148117cd279341e83642","signature":"2421f9c6b1ecedd50818719090a77e9d2748c2339c33f3d4817beebf7a39d211"},{"version":"c2d50c4910fe98fd4e1de539f8f19df419568dade02bbabae0d825393b81620c","signature":"0fb38ed4e7226af189227d01fad98ba5d04bc4974333ccc9ea52f8560d2d0b94"},{"version":"ecfa1b63e3829b310ac968b2cc1cc7016ba76ffb8532439aebecbcbc57173b99","signature":"2f1dda63ade2bd085704674523b56ede942bc8c2c37fe8ed9b9b0fdfd69b1262"},{"version":"431c0d9711d681a40ba764e646312537c11fc4ed78e93a2085b10500982f6ff3","signature":"a145f122430dd0445ff1ee821b4786fcfc55d3e21c6fd162e405231186848b23"},{"version":"cfd807b2af1519d9c951921a5f3a39dc99d4a9e4d2a867b99d79a26af5eb87cb","signature":"9426f21966a3aa976f8c73abbed67663121f5d37208f5dcc4c56a041094e9eb6"},{"version":"90a927875e054379466cf8b2e5f0490eca5ddd15fd8acad6174cd02267e77edd","signature":"cfa7179e0306fc04d93f062c96e7ae8bad58d0cc4a7aa0dd4494ff9d262b101c"},{"version":"8166ba2d0ddda7fd46bbd049555e9996142c4525acf92b58f5c1b7118c66de39","signature":"306683152ff5a6038cf05b03ddff85a15b1bc8e18ef268aad26b02fd8e0e8b9d"},{"version":"c3b82ab978cf388ff93063382b0e8a7a00a4cdc58971d061c07a595382891cba","signature":"519d424f282600afc61e7ebfa96bf24687b4e0679c19a443a218cdbf1df909d6"},{"version":"d396e1cd38c32bc989d7536a568f00263a20ba6e3db4c032a0591e427d509720","signature":"ead3f997a9a1b63edd1b8369d5db5f687cc7908808de9bc157e0136b99a0d704"},{"version":"a1691ae6d70af82f3e26d9e2e021dc5063021bd9c335bfdb40dc97d3574d1b3f","signature":"cd1c566b611a70ff987a79d0465da67649a8ed7e7668feddfcdf6dceb01c09a8"},{"version":"93de4b1c3b1bd0dd4490c40d1a75ed7e6ba543b091e4b90b8967ccf773ad98e3","signature":"0ca09d92d6469d906a3d1c7192a6294c7f65b75f4f7eb8072bbd1b68c7f021e1"},{"version":"2e6426c1a1ff8561aa5f01d9398426bf06e55307f688464939de3196f0d4c143","signature":"5357bd09c9816a9765e617f86a9b49f85133d0bc0f9c5e29e834f2f8e6d52acb"},{"version":"508279c48de5627ae6c30a0aee01f4391bf32450335d7f09d5dd82acbc4d13c5","signature":"11d546a505f70f9c5f8092916027d8045c280a817b709fcaf2c4e63fa026c89c"},{"version":"557f2e0a4e5ac8a59b7c3068b2b30162fb963d72d50152482ab8c414e81caf37","signature":"008eaae28119118f1c589a1e29ea7fd17277f2280d2d3bfddeacd71fd1671bb5"},{"version":"f45c172ca54fb28d64b2dd04e495f17038034e20f37bd286a9f3eeb286cf1388","signature":"75a8761564c8fc5581b062dd339ea698921baf60e52eae055c8177dfa89eba90"},{"version":"ea696a0517ad69afea472e47eb1f904aba1667f54d4557eb98b8c766469d56a2","signature":"7e125d9abc19f62d1480f6c04a45d7bb2c89153316245ae8b8e5a0234b078c4e"},{"version":"902937c505f88d8b5b32829b4c14243eb740013fd0e2f58e6485324bbfe197a6","signature":"dc7de7650e5a64fc010387db18e84d48fe8f562dbd9caac01e54f83681ac976b"},{"version":"1f89fe550e0d6dad5d9808a48db229e95f72a1a2661237ff7de23802fc5718ed","signature":"801991f7de194b8032ab0aeb656b9344d85fb4b7120d8bd713d7b7864838be0f"},{"version":"45b1a895868587c78a2ddff937967669b4e1968ea72c01e1c2b6dd5993f53b36","signature":"8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881"},"ba1fed463e8a21ffddb67a53df3f0d818b351991723736e167d065e2de1c7183",{"version":"22e311fec88bcc49b2b1fb3c9a7c082cd84b3388c9bcc7b9ef08253f6fa74e26","affectsGlobalScope":true},"c186097fd9b86681981cdeba08c0b6bbfcd8b562ab490c25656d85fef8f10c79","0b0c483e991e81c3f26e5f2da53ff26a15994c98c8b89cda1e4156dfc2428111","3340eb7b30bdee5f0349107d4068fd6f2f4712e11a2ba68e203b2f2489350317",{"version":"c15a60d78b3a7f508c51c1f57984cbf5e4768093988cd1164e0af0b9b81433d5","signature":"211b40381fc68e8eefce4eff7928c0d9d7d8fb6ff9d392a3254e3fdbccc84a53"},{"version":"5cf661a7480a603a7fbfec5ad79dd80267ef08ae902f6735e96e2297adf28ceb","signature":"b1802850887a3ea11a06df1fc1c65c6579332eefba1e63b3967a73dc937a2574"},{"version":"ec2027bb978f2eb2dc6bc18e8bb17bcecdec0142ee64b57c3b22059b3cad22b8","signature":"8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881"},"a11c3e55d22d6379fe0949793e2638a6b43aa6e9def4f7452c3e352a296ef8da",{"version":"3e964bac5f962828860aac2783f2d64b8bb84d1ee6b625af1b9e196f1070cf1e","signature":"519d424f282600afc61e7ebfa96bf24687b4e0679c19a443a218cdbf1df909d6"},{"version":"a1fce27c804c9d5b67b3db86ed9eba6201556e90db0639b1d6215f226fb1c4d8","signature":"8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881"},{"version":"1c024431c672cf9c6dcdb4d30c5b625435d81a5423b9d45e8de0082e969af8a8","signature":"8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881"},{"version":"eee1b57475023853cd09dd79b8d0d6639b6b82c3baee5863c2f2022b710f4102","signature":"8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881"},{"version":"e2c3254c37d7201a4b8824d6d99fa64f4303c297ed3679f3f99fb0803364345c","signature":"3fb127aac79a5f742c1341994cb2f14677506b4802ba35f605820c0308028d7c"},{"version":"529dd364d169ab3dbbb177ccdc4987c4a6f69187f553f3d36460ab65879ad998","signature":"3919e9d5911da2254732c31942e2cdc0057056ebfc2a16d34041c76a9b58d447"},"e432b56911b58550616fc4d54c1606f65fe98c74875b81d74601f5f965767c60","cc957354aa3c94c9961ebf46282cfde1e81d107fc5785a61f62c67f1dd3ac2eb","a46a2e69d12afe63876ec1e58d70e5dbee6d3e74132f4468f570c3d69f809f1c","93de1c6dab503f053efe8d304cb522bb3a89feab8c98f307a674a4fae04773e9","3b043cf9a81854a72963fdb57d1884fc4da1cf5be69b5e0a4c5b751e58cb6d88","dd5647a9ccccb2b074dca8a02b00948ac293091ebe73fdf2e6e98f718819f669","0cba3a5d7b81356222594442753cf90dd2892e5ccfe1d262aaca6896ba6c1380","a69c09dbea52352f479d3e7ac949fde3d17b195abe90b045d619f747b38d6d1a",{"version":"c2ab70bbc7a24c42a790890739dd8a0ba9d2e15038b40dff8163a97a5d148c00","affectsGlobalScope":true},"422dbb183fdced59425ca072c8bd09efaa77ce4e2ab928ec0d8a1ce062d2a45a",{"version":"712ba0d43b44d144dfd01593f61af6e2e21cfae83e834d297643e7973e55ed61","affectsGlobalScope":true},"1dab5ab6bcf11de47ab9db295df8c4f1d92ffa750e8f095e88c71ce4c3299628","f71f46ccd5a90566f0a37b25b23bc4684381ab2180bdf6733f4e6624474e1894",{"version":"54e65985a3ee3cec182e6a555e20974ea936fc8b8d1738c14e8ed8a42bd921d4","affectsGlobalScope":true},"82408ed3e959ddc60d3e9904481b5a8dc16469928257af22a3f7d1a3bc7fd8c4","98a3ebfa494b46265634a73459050befba5da8fdc6ca0ef9b7269421780f4ff3","34e5de87d983bc6aefef8b17658556e3157003e8d9555d3cb098c6bef0b5fbc8","cc0b61316c4f37393f1f9595e93b673f4184e9d07f4c127165a490ec4a928668","f27371653aded82b2b160f7a7033fb4a5b1534b6f6081ef7be1468f0f15327d3","c762cd6754b13a461c54b59d0ae0ab7aeef3c292c6cf889873f786ee4d8e75c9","f4ea7d5df644785bd9fbf419930cbaec118f0d8b4160037d2339b8e23c059e79",{"version":"bfea28e6162ed21a0aeed181b623dcf250aa79abf49e24a6b7e012655af36d81","affectsGlobalScope":true},"7a5459efa09ea82088234e6533a203d528c594b01787fb90fba148885a36e8b6","ae97e20f2e10dbeec193d6a2f9cd9a367a1e293e7d6b33b68bacea166afd7792","10d4796a130577d57003a77b95d8723530bbec84718e364aa2129fa8ffba0378","ad41bb744149e92adb06eb953da195115620a3f2ad48e7d3ae04d10762dae197","bf73c576885408d4a176f44a9035d798827cc5020d58284cb18d7573430d9022","7ae078ca42a670445ae0c6a97c029cb83d143d62abd1730efb33f68f0b2c0e82",{"version":"e8b18c6385ff784228a6f369694fcf1a6b475355ba89090a88de13587a9391d5","affectsGlobalScope":true},"5d0a9ea09d990b5788f867f1c79d4878f86f7384cb7dab38eecbf22f9efd063d","12eea70b5e11e924bb0543aea5eadc16ced318aa26001b453b0d561c2fd0bd1e","08777cd9318d294646b121838574e1dd7acbb22c21a03df84e1f2c87b1ad47f2","08a90bcdc717df3d50a2ce178d966a8c353fd23e5c392fd3594a6e39d9bb6304",{"version":"4cd4cff679c9b3d9239fd7bf70293ca4594583767526916af8e5d5a47d0219c7","affectsGlobalScope":true},"2a12d2da5ac4c4979401a3f6eaafa874747a37c365e4bc18aa2b171ae134d21b","002b837927b53f3714308ecd96f72ee8a053b8aeb28213d8ec6de23ed1608b66","1dc9c847473bb47279e398b22c740c83ea37a5c88bf66629666e3cf4c5b9f99c","a9e4a5a24bf2c44de4c98274975a1a705a0abbaad04df3557c2d3cd8b1727949","00fa7ce8bc8acc560dc341bbfdf37840a8c59e6a67c9bfa3fa5f36254df35db2","1b952304137851e45bc009785de89ada562d9376177c97e37702e39e60c2f1ff",{"version":"806ef4cac3b3d9fa4a48d849c8e084d7c72fcd7b16d76e06049a9ed742ff79c0","affectsGlobalScope":true},"44b8b584a338b190a59f4f6929d072431950c7bd92ec2694821c11bce180c8a5","5f0ed51db151c2cdc4fa3bb0f44ce6066912ad001b607a34e65a96c52eb76248",{"version":"3345c276cab0e76dda86c0fb79104ff915a4580ba0f3e440870e183b1baec476","affectsGlobalScope":true},"664d8f2d59164f2e08c543981453893bc7e003e4dfd29651ce09db13e9457980","e383ff72aabf294913f8c346f5da1445ae6ad525836d28efd52cbadc01a361a6","f52fbf64c7e480271a9096763c4882d356b05cab05bf56a64e68a95313cd2ce2","59bdb65f28d7ce52ccfc906e9aaf422f8b8534b2d21c32a27d7819be5ad81df7",{"version":"3a2da34079a2567161c1359316a32e712404b56566c45332ac9dcee015ecce9f","affectsGlobalScope":true},"28a2e7383fd898c386ffdcacedf0ec0845e5d1a86b5a43f25b86bc315f556b79","3aff9c8c36192e46a84afe7b926136d520487155154ab9ba982a8b544ea8fc95","a880cf8d85af2e4189c709b0fea613741649c0e40fffb4360ec70762563d5de0","85bbf436a15bbeda4db888be3062d47f99c66fd05d7c50f0f6473a9151b6a070","9f9c49c95ecd25e0cb2587751925976cf64fd184714cb11e213749c80cf0f927","f0c75c08a71f9212c93a719a25fb0320d53f2e50ca89a812640e08f8ad8c408c",{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true},"9cafe917bf667f1027b2bb62e2de454ecd2119c80873ad76fc41d941089753b8","3ebae8c00411116a66fca65b08228ea0cf0b72724701f9b854442100aab55aba","8b06ac3faeacb8484d84ddb44571d8f410697f98d7bfa86c0fda60373a9f5215","7eb06594824ada538b1d8b48c3925a83e7db792f47a081a62cf3e5c4e23cf0ee","f5638f7c2f12a9a1a57b5c41b3c1ea7db3876c003bab68e6a57afd6bcc169af0","0d14fa22c41fdc7277e6f71473b20ebc07f40f00e38875142335d5b63cdfc9d2","7980bf9d2972585cdf76b5a72105f7817be0723ccb2256090f6335f45b462abe","301d7466eb591139c7d456958f732153b3400f3243f68d3321956b43a64769e9","22f13de9e2fe5f0f4724797abd3d34a1cdd6e47ef81fc4933fea3b8bf4ad524b","e3ba509d3dce019b3190ceb2f3fc88e2610ab717122dabd91a9efaa37804040d","cda0cb09b995489b7f4c57f168cd31b83dcbaa7aad49612734fb3c9c73f6e4f2",{"version":"2abad7477cf6761b55c18bea4c21b5a5dcf319748c13696df3736b35f8ac149e","affectsGlobalScope":true},"d38e588a10943bbab1d4ce03d94759bf065ff802a9a72fc57aa75a72f1725b71","96d14f21b7652903852eef49379d04dbda28c16ed36468f8c9fa08f7c14c9538","2b8264b2fefd7367e0f20e2c04eed5d3038831fe00f5efbc110ff0131aab899b","6209c901f30cc321f4b86800d11fad3d67e73a3308f19946b1bc642af0280298","60aaac5fb1858fbd4c4eb40e01706eb227eed9eca5c665564bd146971280dbd3","74b0245c42990ed8a849df955db3f4362c81b13f799ebc981b7bec2d5b414a57","b0d10e46cfe3f6c476b69af02eaa38e4ccc7430221ce3109ae84bb9fb8282298","4266ccd2cf1d6a281efd9c7ddf9efd7daecf76575364148bd233e18919cac3ed","70e9a18da08294f75bf23e46c7d69e67634c0765d355887b9b41f0d959e1426e","105b9a2234dcb06ae922f2cd8297201136d416503ff7d16c72bfc8791e9895c1"],"options":{"composite":true,"declaration":true,"declarationMap":true,"downlevelIteration":true,"esModuleInterop":true,"experimentalDecorators":true,"importHelpers":true,"jsx":2,"noEmitOnError":false,"noImplicitAny":true,"noUnusedLocals":true,"outDir":"./","rootDir":"../src","skipLibCheck":true,"sourceMap":true,"strictNullChecks":true,"target":1,"tsBuildInfoFile":"./tsconfig.tsbuildinfo"},"fileIdsList":[[115,164],[164],[164,177],[53,100,164],[102,104,164],[100,102,103,164],[53,164],[115,116,117,118,119,164],[115,117,164],[137,164,171],[164,173],[164,174],[164,179,181],[121,164],[124,164],[125,130,164],[126,136,137,144,153,163,164],[126,127,136,144,164],[128,164],[129,130,137,145,164],[130,153,160,164],[131,133,136,144,164],[132,164],[133,134,164],[135,136,164],[136,164],[136,137,138,153,163,164],[136,137,138,153,164],[139,144,153,163,164],[136,137,139,140,144,153,160,163,164],[139,141,153,160,163,164],[121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170],[136,142,164],[143,163,164],[133,136,144,153,164],[145,164],[146,164],[124,147,164],[148,162,164,168],[149,164],[150,164],[136,151,164],[151,152,164,166],[136,153,154,155,164],[153,155,164],[153,154,164],[156,164],[157,164],[136,158,159,164],[158,159,164],[130,144,153,160,164],[161,164],[144,162,164],[125,139,150,163,164],[130,164],[153,164,165],[164,166],[164,167],[125,130,136,138,147,153,163,164,166,168],[153,164,169],[47,164],[44,45,46,47,48,53,164],[45,54,164],[49,50,51,52,164],[136,139,141,144,163,164,171],[164,191],[164,179],[164,176,180],[164,178],[65,164],[53,55,56,57,58,60,61,62,63,64,71,164],[45,53,54,61,64,65,164],[57,58,164],[56,57,58,61,164],[57,164],[69,164],[71,164],[58,164],[53,58,164],[55,56,57,58,59,60,61,63,64,65,66,67,68,70,164],[63,164],[72,164],[43,45,54,80,89,164],[43,45,53,54,71,73,76,77,78,80,82,83,84,85,87,88,164],[43,45,54,76,79,164],[43,71,80,81,164],[43,53,164],[43,81,164],[43,45,53,54,71,76,77,85,101,105,164],[43,45,54,71,89,105,164],[43,109,164],[43,71,83,84,86,164],[43,45,53,54,80,89,101,104,164],[43,53,89,94,104,105,164],[43,164],[43,92,164],[43,53,89,91,92,93,94,164],[43,53,71,76,89,164],[43,45,53,54,91,93,95,164],[43,76,77,79,80,89,90,91,93,94,95,96,97,164],[43,45,53,54,74,75,164],[43,45,54,74,164],[43,45,53,54,74,164],[43,45,54,164],[43,71,164],[43,71,108,164],[43,45,54,71,83,84,164],[43,45,54,79,86,89,164],[45,53,54,80],[53,71,80,82],[45,54,76,79],[71,80],[53],[101],[45,53,54,80,89,101,104],[53,89,93,94,98],[53,76,89],[45,54,95],[76,77,79,80,89,90,91,93,94,95,96,97],[45,53,54],[45,54,74],[53,74],[45,54],[71],[45,54,71],[89]],"referencedMap":[[117,1],[115,2],[178,3],[102,4],[103,5],[104,6],[101,4],[100,7],[177,2],[120,8],[116,1],[118,9],[119,1],[172,10],[173,2],[174,11],[175,12],[182,13],[183,2],[184,2],[121,14],[122,14],[124,15],[125,16],[126,17],[127,18],[128,19],[129,20],[130,21],[131,22],[132,23],[133,24],[134,24],[135,25],[136,26],[137,27],[138,28],[123,2],[170,2],[139,29],[140,30],[141,31],[171,32],[142,33],[143,34],[144,35],[145,36],[146,37],[147,38],[148,39],[149,40],[150,41],[151,42],[152,43],[153,44],[155,45],[154,46],[156,47],[157,48],[158,49],[159,50],[160,51],[161,52],[162,53],[163,54],[164,55],[165,56],[166,57],[167,58],[168,59],[169,60],[185,2],[186,2],[51,2],[46,2],[47,61],[48,2],[44,2],[54,62],[45,63],[187,7],[49,2],[53,64],[188,2],[52,2],[189,2],[190,65],[191,2],[192,66],[176,2],[50,2],[180,67],[181,68],[179,69],[63,2],[68,70],[65,71],[72,72],[61,73],[62,74],[55,2],[56,2],[59,73],[58,75],[70,76],[69,77],[67,73],[57,78],[60,79],[71,80],[108,81],[66,2],[64,7],[73,82],[43,2],[8,2],[9,2],[11,2],[10,2],[2,2],[12,2],[13,2],[14,2],[15,2],[16,2],[17,2],[18,2],[19,2],[3,2],[4,2],[23,2],[20,2],[21,2],[22,2],[24,2],[25,2],[26,2],[5,2],[27,2],[28,2],[29,2],[30,2],[6,2],[31,2],[32,2],[33,2],[34,2],[7,2],[35,2],[40,2],[41,2],[36,2],[37,2],[38,2],[39,2],[1,2],[42,2],[90,83],[89,84],[80,85],[82,86],[78,87],[99,88],[106,89],[107,90],[110,91],[111,92],[105,93],[112,94],[91,95],[93,96],[92,95],[95,97],[94,98],[96,95],[97,99],[83,95],[84,95],[85,95],[98,100],[76,101],[75,102],[113,103],[74,95],[77,104],[114,87],[81,95],[88,105],[109,106],[79,95],[86,107],[87,108]],"exportedModulesMap":[[117,1],[115,2],[178,3],[102,4],[103,5],[104,6],[101,4],[100,7],[177,2],[120,8],[116,1],[118,9],[119,1],[172,10],[173,2],[174,11],[175,12],[182,13],[183,2],[184,2],[121,14],[122,14],[124,15],[125,16],[126,17],[127,18],[128,19],[129,20],[130,21],[131,22],[132,23],[133,24],[134,24],[135,25],[136,26],[137,27],[138,28],[123,2],[170,2],[139,29],[140,30],[141,31],[171,32],[142,33],[143,34],[144,35],[145,36],[146,37],[147,38],[148,39],[149,40],[150,41],[151,42],[152,43],[153,44],[155,45],[154,46],[156,47],[157,48],[158,49],[159,50],[160,51],[161,52],[162,53],[163,54],[164,55],[165,56],[166,57],[167,58],[168,59],[169,60],[185,2],[186,2],[51,2],[46,2],[47,61],[48,2],[44,2],[54,62],[45,63],[187,7],[49,2],[53,64],[188,2],[52,2],[189,2],[190,65],[191,2],[192,66],[176,2],[50,2],[180,67],[181,68],[179,69],[63,2],[68,70],[65,71],[72,72],[61,73],[62,74],[55,2],[56,2],[59,73],[58,75],[70,76],[69,77],[67,73],[57,78],[60,79],[71,80],[108,81],[66,2],[64,7],[73,82],[43,2],[8,2],[9,2],[11,2],[10,2],[2,2],[12,2],[13,2],[14,2],[15,2],[16,2],[17,2],[18,2],[19,2],[3,2],[4,2],[23,2],[20,2],[21,2],[22,2],[24,2],[25,2],[26,2],[5,2],[27,2],[28,2],[29,2],[30,2],[6,2],[31,2],[32,2],[33,2],[34,2],[7,2],[35,2],[40,2],[41,2],[36,2],[37,2],[38,2],[39,2],[1,2],[42,2],[90,109],[89,110],[80,111],[82,112],[78,113],[106,114],[105,115],[95,116],[94,117],[97,118],[98,119],[76,120],[75,121],[113,122],[77,123],[114,113],[88,124],[109,124],[86,125],[87,126]],"semanticDiagnosticsPerFile":[117,115,178,102,103,104,101,100,177,120,116,118,119,172,173,174,175,182,183,184,121,122,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,123,170,139,140,141,171,142,143,144,145,146,147,148,149,150,151,152,153,155,154,156,157,158,159,160,161,162,163,164,165,166,167,168,169,185,186,51,46,47,48,44,54,45,187,49,53,188,52,189,190,191,192,176,50,180,181,179,63,68,65,72,61,62,55,56,59,58,70,69,67,57,60,71,108,66,64,73,43,8,9,11,10,2,12,13,14,15,16,17,18,19,3,4,23,20,21,22,24,25,26,5,27,28,29,30,6,31,32,33,34,7,35,40,41,36,37,38,39,1,42,90,89,80,82,78,99,106,107,110,111,105,112,91,93,92,95,94,96,97,83,84,85,98,76,75,113,74,77,114,81,88,109,79,86,87]},"version":"4.7.4"}
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Helper class to calculate running average of the most recent n values
3
+ */
4
+ export declare class AverageWindow {
5
+ private currentAverage;
6
+ private currentCount;
7
+ private inputValues;
8
+ private nextIndex;
9
+ constructor(size: number, startValue?: number);
10
+ /**
11
+ * Can be used to get the current average value
12
+ */
13
+ get currentValue(): number;
14
+ /**
15
+ *
16
+ * @param value Add new value to the average window and updated current average
17
+ */
18
+ addValue(value: number): void;
19
+ private getNextIndex;
20
+ }
21
+ //# sourceMappingURL=AverageWindow.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AverageWindow.d.ts","sourceRoot":"","sources":["../../src/utils/AverageWindow.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,qBAAa,aAAa;IACxB,OAAO,CAAC,cAAc,CAAS;IAC/B,OAAO,CAAC,YAAY,CAAS;IAC7B,OAAO,CAAC,WAAW,CAAyB;IAC5C,OAAO,CAAC,SAAS,CAAa;gBAClB,IAAI,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM;IAQ7C;;OAEG;IACH,IAAW,YAAY,IAAI,MAAM,CAEhC;IAED;;;OAGG;IACI,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI;IAepC,OAAO,CAAC,YAAY;CAMrB"}
@@ -0,0 +1,49 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.AverageWindow = void 0;
4
+ /**
5
+ * Helper class to calculate running average of the most recent n values
6
+ */
7
+ var AverageWindow = /** @class */ (function () {
8
+ function AverageWindow(size, startValue) {
9
+ this.nextIndex = 0;
10
+ this.inputValues = new Array(Math.max(1, size));
11
+ this.currentAverage = startValue !== null && startValue !== void 0 ? startValue : 0;
12
+ this.currentCount = startValue === undefined ? 0 : 1;
13
+ this.nextIndex = this.currentCount;
14
+ this.inputValues[0] = startValue;
15
+ }
16
+ Object.defineProperty(AverageWindow.prototype, "currentValue", {
17
+ /**
18
+ * Can be used to get the current average value
19
+ */
20
+ get: function () {
21
+ return this.currentAverage;
22
+ },
23
+ enumerable: false,
24
+ configurable: true
25
+ });
26
+ /**
27
+ *
28
+ * @param value Add new value to the average window and updated current average
29
+ */
30
+ AverageWindow.prototype.addValue = function (value) {
31
+ var target = this.getNextIndex();
32
+ var oldValue = this.inputValues[target];
33
+ var newCount = oldValue === undefined ? this.currentCount + 1 : this.currentCount;
34
+ this.inputValues[target] = value;
35
+ this.currentAverage =
36
+ this.currentAverage * (this.currentCount / newCount) +
37
+ (value - (oldValue !== null && oldValue !== void 0 ? oldValue : 0)) / newCount;
38
+ this.currentCount = newCount;
39
+ };
40
+ AverageWindow.prototype.getNextIndex = function () {
41
+ // starts from 0 once we reach end of the array
42
+ var newTarget = this.nextIndex;
43
+ this.nextIndex = (this.nextIndex + 1) % this.inputValues.length;
44
+ return newTarget;
45
+ };
46
+ return AverageWindow;
47
+ }());
48
+ exports.AverageWindow = AverageWindow;
49
+ //# sourceMappingURL=AverageWindow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AverageWindow.js","sourceRoot":"","sources":["../../src/utils/AverageWindow.ts"],"names":[],"mappings":";;;AAAA;;GAEG;AACH;IAKE,uBAAY,IAAY,EAAE,UAAmB;QADrC,cAAS,GAAW,CAAC,CAAC;QAE5B,IAAI,CAAC,WAAW,GAAG,IAAI,KAAK,CAAS,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC;QACxD,IAAI,CAAC,cAAc,GAAG,UAAU,aAAV,UAAU,cAAV,UAAU,GAAI,CAAC,CAAC;QACtC,IAAI,CAAC,YAAY,GAAG,UAAU,KAAK,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QACrD,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,YAAY,CAAC;QACnC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,GAAG,UAAU,CAAC;IACnC,CAAC;IAKD,sBAAW,uCAAY;QAHvB;;WAEG;aACH;YACE,OAAO,IAAI,CAAC,cAAc,CAAC;QAC7B,CAAC;;;OAAA;IAED;;;OAGG;IACI,gCAAQ,GAAf,UAAgB,KAAa;QAC3B,IAAM,MAAM,GAAG,IAAI,CAAC,YAAY,EAAE,CAAC;QACnC,IAAM,QAAQ,GAAG,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC;QAC1C,IAAM,QAAQ,GACZ,QAAQ,KAAK,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,YAAY,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,YAAY,CAAC;QAErE,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,GAAG,KAAK,CAAC;QAEjC,IAAI,CAAC,cAAc;YACjB,IAAI,CAAC,cAAc,GAAG,CAAC,IAAI,CAAC,YAAY,GAAG,QAAQ,CAAC;gBACpD,CAAC,KAAK,GAAG,CAAC,QAAQ,aAAR,QAAQ,cAAR,QAAQ,GAAI,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC;QAEvC,IAAI,CAAC,YAAY,GAAG,QAAQ,CAAC;IAC/B,CAAC;IAEO,oCAAY,GAApB;QACE,+CAA+C;QAC/C,IAAM,SAAS,GAAG,IAAI,CAAC,SAAS,CAAC;QACjC,IAAI,CAAC,SAAS,GAAG,CAAC,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC,GAAG,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC;QAChE,OAAO,SAAS,CAAC;IACnB,CAAC;IACH,oBAAC;AAAD,CAAC,AA7CD,IA6CC;AA7CY,sCAAa"}
@@ -0,0 +1,14 @@
1
+ import { BaseItemAnimator } from "recyclerlistview";
2
+ declare const PlatformConfig: {
3
+ defaultDrawDistance: number;
4
+ };
5
+ declare const getCellContainerPlatformStyles: (inverted: boolean, parentProps: {
6
+ x: number;
7
+ y: number;
8
+ }) => {
9
+ transform: string;
10
+ WebkitTransform: string;
11
+ } | undefined;
12
+ declare const getItemAnimator: () => BaseItemAnimator | undefined;
13
+ export { PlatformConfig, getCellContainerPlatformStyles, getItemAnimator };
14
+ //# sourceMappingURL=PlatformHelper.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PlatformHelper.d.ts","sourceRoot":"","sources":["../../src/utils/PlatformHelper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAEpD,QAAA,MAAM,cAAc;;CAEnB,CAAC;AACF,QAAA,MAAM,8BAA8B,aACxB,OAAO,eACJ;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE,KACpC;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,eAAe,EAAE,MAAM,CAAA;CAAE,GAAG,SAEnD,CAAC;AAEF,QAAA,MAAM,eAAe,QAAO,gBAAgB,GAAG,SAE9C,CAAC;AACF,OAAO,EAAE,cAAc,EAAE,8BAA8B,EAAE,eAAe,EAAE,CAAC"}
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getItemAnimator = exports.getCellContainerPlatformStyles = exports.PlatformConfig = void 0;
4
+ var PlatformConfig = {
5
+ defaultDrawDistance: 250,
6
+ };
7
+ exports.PlatformConfig = PlatformConfig;
8
+ var getCellContainerPlatformStyles = function (inverted, parentProps) {
9
+ return undefined;
10
+ };
11
+ exports.getCellContainerPlatformStyles = getCellContainerPlatformStyles;
12
+ var getItemAnimator = function () {
13
+ return undefined;
14
+ };
15
+ exports.getItemAnimator = getItemAnimator;
16
+ //# sourceMappingURL=PlatformHelper.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PlatformHelper.js","sourceRoot":"","sources":["../../src/utils/PlatformHelper.ts"],"names":[],"mappings":";;;AAEA,IAAM,cAAc,GAAG;IACrB,mBAAmB,EAAE,GAAG;CACzB,CAAC;AAWO,wCAAc;AAVvB,IAAM,8BAA8B,GAAG,UACrC,QAAiB,EACjB,WAAqC;IAErC,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC;AAKuB,wEAA8B;AAHvD,IAAM,eAAe,GAAG;IACtB,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC;AACuD,0CAAe"}
@@ -0,0 +1,14 @@
1
+ import { BaseItemAnimator } from "recyclerlistview";
2
+ declare const PlatformConfig: {
3
+ defaultDrawDistance: number;
4
+ };
5
+ declare const getCellContainerPlatformStyles: (inverted: boolean, parentProps: {
6
+ x: number;
7
+ y: number;
8
+ }) => {
9
+ transform: string;
10
+ WebkitTransform: string;
11
+ } | undefined;
12
+ declare const getItemAnimator: () => BaseItemAnimator | undefined;
13
+ export { PlatformConfig, getCellContainerPlatformStyles, getItemAnimator };
14
+ //# sourceMappingURL=PlatformHelper.web.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PlatformHelper.web.d.ts","sourceRoot":"","sources":["../../src/utils/PlatformHelper.web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAGpD,QAAA,MAAM,cAAc;;CAEnB,CAAC;AACF,QAAA,MAAM,8BAA8B,aACxB,OAAO,eACJ;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE,KACpC;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,eAAe,EAAE,MAAM,CAAA;CAAE,GAAG,SAKnD,CAAC;AAEF,QAAA,MAAM,eAAe,QAAO,gBAAgB,GAAG,SAE9C,CAAC;AACF,OAAO,EAAE,cAAc,EAAE,8BAA8B,EAAE,eAAe,EAAE,CAAC"}
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getItemAnimator = exports.getCellContainerPlatformStyles = exports.PlatformConfig = void 0;
4
+ var DefaultJSItemAnimator_1 = require("recyclerlistview/dist/reactnative/platform/reactnative/itemanimators/defaultjsanimator/DefaultJSItemAnimator");
5
+ var PlatformConfig = {
6
+ defaultDrawDistance: 2000,
7
+ };
8
+ exports.PlatformConfig = PlatformConfig;
9
+ var getCellContainerPlatformStyles = function (inverted, parentProps) {
10
+ var transformValue = "translate(".concat(parentProps.x, "px,").concat(parentProps.y, "px)").concat(inverted ? " scaleY(-1)" : "");
11
+ return { transform: transformValue, WebkitTransform: transformValue };
12
+ };
13
+ exports.getCellContainerPlatformStyles = getCellContainerPlatformStyles;
14
+ var getItemAnimator = function () {
15
+ return new DefaultJSItemAnimator_1.DefaultJSItemAnimator();
16
+ };
17
+ exports.getItemAnimator = getItemAnimator;
18
+ //# sourceMappingURL=PlatformHelper.web.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PlatformHelper.web.js","sourceRoot":"","sources":["../../src/utils/PlatformHelper.web.ts"],"names":[],"mappings":";;;AACA,sJAAqJ;AAErJ,IAAM,cAAc,GAAG;IACrB,mBAAmB,EAAE,IAAI;CAC1B,CAAC;AAcO,wCAAc;AAbvB,IAAM,8BAA8B,GAAG,UACrC,QAAiB,EACjB,WAAqC;IAErC,IAAM,cAAc,GAAG,oBAAa,WAAW,CAAC,CAAC,gBAAM,WAAW,CAAC,CAAC,gBAClE,QAAQ,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,CAC7B,CAAC;IACH,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,eAAe,EAAE,cAAc,EAAE,CAAC;AACxE,CAAC,CAAC;AAKuB,wEAA8B;AAHvD,IAAM,eAAe,GAAG;IACtB,OAAO,IAAI,6CAAqB,EAAE,CAAC;AACrC,CAAC,CAAC;AACuD,0CAAe"}
@@ -0,0 +1,8 @@
1
+ export default interface ViewToken {
2
+ item: any;
3
+ key: string;
4
+ index: number | null;
5
+ isViewable: boolean;
6
+ timestamp: number;
7
+ }
8
+ //# sourceMappingURL=ViewToken.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ViewToken.d.ts","sourceRoot":"","sources":["../../src/viewability/ViewToken.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,WAAW,SAAS;IAChC,IAAI,EAAE,GAAG,CAAC;IACV,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,UAAU,EAAE,OAAO,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;CACnB"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=ViewToken.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ViewToken.js","sourceRoot":"","sources":["../../src/viewability/ViewToken.ts"],"names":[],"mappings":""}
@@ -0,0 +1,25 @@
1
+ import { ViewabilityConfig } from "react-native";
2
+ import { Dimension, Layout } from "recyclerlistview";
3
+ /**
4
+ * Helper class for computing viewable items based on the passed `viewabilityConfig`.
5
+ * Note methods in this class will be invoked on every scroll and should be optimized for performance.
6
+ */
7
+ declare class ViewabilityHelper {
8
+ /**
9
+ * Viewable indices regardless of the viewability config
10
+ */
11
+ possiblyViewableIndices: number[];
12
+ hasInteracted: boolean;
13
+ private viewableIndices;
14
+ private lastReportedViewableIndices;
15
+ private viewabilityConfig;
16
+ private viewableIndicesChanged;
17
+ private timers;
18
+ constructor(viewabilityConfig: ViewabilityConfig | null | undefined, viewableIndicesChanged: (indices: number[], newlyVisibleIndicies: number[], newlyNonvisibleIndices: number[]) => void);
19
+ dispose(): void;
20
+ updateViewableItems(horizontal: boolean, scrollOffset: number, listSize: Dimension, getLayout: (index: number) => Layout | undefined, viewableIndices?: number[]): void;
21
+ checkViewableIndicesChanges(newViewableIndices: number[]): void;
22
+ private isItemViewable;
23
+ }
24
+ export default ViewabilityHelper;
25
+ //# sourceMappingURL=ViewabilityHelper.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ViewabilityHelper.d.ts","sourceRoot":"","sources":["../../src/viewability/ViewabilityHelper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAKrD;;;GAGG;AACH,cAAM,iBAAiB;IACrB;;OAEG;IACH,uBAAuB,EAAE,MAAM,EAAE,CAAM;IAEvC,aAAa,EAAE,OAAO,CAAS;IAE/B,OAAO,CAAC,eAAe,CAAgB;IACvC,OAAO,CAAC,2BAA2B,CAAgB;IAEnD,OAAO,CAAC,iBAAiB,CAAuC;IAChE,OAAO,CAAC,sBAAsB,CAIpB;IAEV,OAAO,CAAC,MAAM,CAAkC;gBAG9C,iBAAiB,EAAE,iBAAiB,GAAG,IAAI,GAAG,SAAS,EACvD,sBAAsB,EAAE,CACtB,OAAO,EAAE,MAAM,EAAE,EACjB,oBAAoB,EAAE,MAAM,EAAE,EAC9B,sBAAsB,EAAE,MAAM,EAAE,KAC7B,IAAI;IAMJ,OAAO;IAKP,mBAAmB,CACxB,UAAU,EAAE,OAAO,EACnB,YAAY,EAAE,MAAM,EACpB,QAAQ,EAAE,SAAS,EACnB,SAAS,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,MAAM,GAAG,SAAS,EAChD,eAAe,CAAC,EAAE,MAAM,EAAE;IA8CrB,2BAA2B,CAAC,kBAAkB,EAAE,MAAM,EAAE;IAsB/D,OAAO,CAAC,cAAc;CAuCvB;AAED,eAAe,iBAAiB,CAAC"}
@@ -0,0 +1,104 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var tslib_1 = require("tslib");
4
+ var CustomError_1 = tslib_1.__importDefault(require("../errors/CustomError"));
5
+ var ExceptionList_1 = tslib_1.__importDefault(require("../errors/ExceptionList"));
6
+ /**
7
+ * Helper class for computing viewable items based on the passed `viewabilityConfig`.
8
+ * Note methods in this class will be invoked on every scroll and should be optimized for performance.
9
+ */
10
+ var ViewabilityHelper = /** @class */ (function () {
11
+ function ViewabilityHelper(viewabilityConfig, viewableIndicesChanged) {
12
+ /**
13
+ * Viewable indices regardless of the viewability config
14
+ */
15
+ this.possiblyViewableIndices = [];
16
+ this.hasInteracted = false;
17
+ this.viewableIndices = [];
18
+ this.lastReportedViewableIndices = [];
19
+ this.timers = new Set();
20
+ this.viewabilityConfig = viewabilityConfig;
21
+ this.viewableIndicesChanged = viewableIndicesChanged;
22
+ }
23
+ ViewabilityHelper.prototype.dispose = function () {
24
+ // Clean up on dismount
25
+ this.timers.forEach(clearTimeout);
26
+ };
27
+ ViewabilityHelper.prototype.updateViewableItems = function (horizontal, scrollOffset, listSize, getLayout, viewableIndices) {
28
+ var _this = this;
29
+ var _a, _b, _c, _d, _e, _f, _g, _h;
30
+ if (viewableIndices !== undefined) {
31
+ this.possiblyViewableIndices = viewableIndices;
32
+ }
33
+ if (((_a = this.viewabilityConfig) === null || _a === void 0 ? void 0 : _a.itemVisiblePercentThreshold) !== null &&
34
+ ((_b = this.viewabilityConfig) === null || _b === void 0 ? void 0 : _b.itemVisiblePercentThreshold) !== undefined &&
35
+ ((_c = this.viewabilityConfig) === null || _c === void 0 ? void 0 : _c.viewAreaCoveragePercentThreshold) !== null &&
36
+ ((_d = this.viewabilityConfig) === null || _d === void 0 ? void 0 : _d.viewAreaCoveragePercentThreshold) !== undefined) {
37
+ throw new CustomError_1.default(ExceptionList_1.default.multipleViewabilityThresholdTypesNotSupported);
38
+ }
39
+ if (((_f = (_e = this.viewabilityConfig) === null || _e === void 0 ? void 0 : _e.waitForInteraction) !== null && _f !== void 0 ? _f : false) &&
40
+ !this.hasInteracted) {
41
+ return;
42
+ }
43
+ var newViewableIndices = this.possiblyViewableIndices.filter(function (index) {
44
+ var _a, _b;
45
+ return _this.isItemViewable(index, horizontal, scrollOffset, listSize, (_a = _this.viewabilityConfig) === null || _a === void 0 ? void 0 : _a.viewAreaCoveragePercentThreshold, (_b = _this.viewabilityConfig) === null || _b === void 0 ? void 0 : _b.itemVisiblePercentThreshold, getLayout);
46
+ });
47
+ this.viewableIndices = newViewableIndices;
48
+ var minimumViewTime = (_h = (_g = this.viewabilityConfig) === null || _g === void 0 ? void 0 : _g.minimumViewTime) !== null && _h !== void 0 ? _h : 250;
49
+ // Setting default to 250. Default of 0 can impact performance when user scrolls fast.
50
+ if (minimumViewTime > 0) {
51
+ var timeoutId_1 = setTimeout(function () {
52
+ _this.timers.delete(timeoutId_1);
53
+ _this.checkViewableIndicesChanges(newViewableIndices);
54
+ _this.timers.add(timeoutId_1);
55
+ }, minimumViewTime);
56
+ }
57
+ else {
58
+ this.checkViewableIndicesChanges(newViewableIndices);
59
+ }
60
+ };
61
+ ViewabilityHelper.prototype.checkViewableIndicesChanges = function (newViewableIndices) {
62
+ var _this = this;
63
+ // Check if all viewable indices are still available (applicable if minimumViewTime > 0)
64
+ var currentlyNewViewableIndices = newViewableIndices.filter(function (index) {
65
+ return _this.viewableIndices.includes(index);
66
+ });
67
+ var newlyVisibleItems = currentlyNewViewableIndices.filter(function (index) { return !_this.lastReportedViewableIndices.includes(index); });
68
+ var newlyNonvisibleItems = this.lastReportedViewableIndices.filter(function (index) { return !currentlyNewViewableIndices.includes(index); });
69
+ if (newlyVisibleItems.length > 0 || newlyNonvisibleItems.length > 0) {
70
+ this.lastReportedViewableIndices = currentlyNewViewableIndices;
71
+ this.viewableIndicesChanged(currentlyNewViewableIndices, newlyVisibleItems, newlyNonvisibleItems);
72
+ }
73
+ };
74
+ ViewabilityHelper.prototype.isItemViewable = function (index, horizontal, scrollOffset, listSize, viewAreaCoveragePercentThreshold, itemVisiblePercentThreshold, getLayout) {
75
+ var itemLayout = getLayout(index);
76
+ if (itemLayout === undefined) {
77
+ return false;
78
+ }
79
+ var itemTop = (horizontal ? itemLayout.x : itemLayout.y) - scrollOffset;
80
+ var itemSize = horizontal ? itemLayout.width : itemLayout.height;
81
+ var listMainSize = horizontal ? listSize.width : listSize.height;
82
+ var pixelsVisible = Math.min(itemTop + itemSize, listMainSize) - Math.max(itemTop, 0);
83
+ // Always consider item fully viewable if it is fully visible, regardless of the `viewAreaCoveragePercentThreshold`
84
+ if (pixelsVisible === itemSize) {
85
+ return true;
86
+ }
87
+ // Skip checking item if it's not visible at all
88
+ if (pixelsVisible === 0) {
89
+ return false;
90
+ }
91
+ var viewAreaMode = viewAreaCoveragePercentThreshold !== null &&
92
+ viewAreaCoveragePercentThreshold !== undefined;
93
+ var percent = viewAreaMode
94
+ ? pixelsVisible / listMainSize
95
+ : pixelsVisible / itemSize;
96
+ var viewableAreaPercentThreshold = viewAreaMode
97
+ ? viewAreaCoveragePercentThreshold * 0.01
98
+ : (itemVisiblePercentThreshold !== null && itemVisiblePercentThreshold !== void 0 ? itemVisiblePercentThreshold : 0) * 0.01;
99
+ return percent >= viewableAreaPercentThreshold;
100
+ };
101
+ return ViewabilityHelper;
102
+ }());
103
+ exports.default = ViewabilityHelper;
104
+ //# sourceMappingURL=ViewabilityHelper.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ViewabilityHelper.js","sourceRoot":"","sources":["../../src/viewability/ViewabilityHelper.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,24 @@
1
+ import FlashList from "../FlashList";
2
+ /**
3
+ * Manager for viewability tracking. It holds multiple viewability callback pairs and keeps them updated.
4
+ */
5
+ export default class ViewabilityManager<T> {
6
+ private flashListRef;
7
+ private viewabilityHelpers;
8
+ private hasInteracted;
9
+ constructor(flashListRef: FlashList<T>);
10
+ /**
11
+ * @returns true if the viewability manager has any viewability callback pairs registered.
12
+ */
13
+ get shouldListenToVisibleIndices(): boolean;
14
+ dispose: () => void;
15
+ onVisibleIndicesChanged: (all: number[]) => void;
16
+ recordInteraction: () => void;
17
+ updateViewableItems: (newViewableIndices?: number[]) => void;
18
+ /**
19
+ * Creates a new `ViewabilityHelper` instance with `onViewableItemsChanged` callback and `ViewabilityConfig`
20
+ * @returns `ViewabilityHelper` instance
21
+ */
22
+ private createViewabilityHelper;
23
+ }
24
+ //# sourceMappingURL=ViewabilityManager.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ViewabilityManager.d.ts","sourceRoot":"","sources":["../../src/viewability/ViewabilityManager.ts"],"names":[],"mappings":"AAEA,OAAO,SAAS,MAAM,cAAc,CAAC;AAKrC;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,kBAAkB,CAAC,CAAC;IACvC,OAAO,CAAC,YAAY,CAAe;IACnC,OAAO,CAAC,kBAAkB,CAA2B;IACrD,OAAO,CAAC,aAAa,CAAS;gBAElB,YAAY,EAAE,SAAS,CAAC,CAAC,CAAC;IAyBtC;;OAEG;IACH,IAAW,4BAA4B,YAEtC;IAEM,OAAO,aAIZ;IAEK,uBAAuB,QAAS,MAAM,EAAE,UAE7C;IAEK,iBAAiB,aAStB;IAEK,mBAAmB,wBAAyB,MAAM,EAAE,UAmBzD;IAEF;;;OAGG;IACH,OAAO,CAAC,uBAAuB,CAsC7B;CACH"}
@@ -0,0 +1,94 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var tslib_1 = require("tslib");
4
+ var ViewabilityHelper_1 = tslib_1.__importDefault(require("./ViewabilityHelper"));
5
+ /**
6
+ * Manager for viewability tracking. It holds multiple viewability callback pairs and keeps them updated.
7
+ */
8
+ var ViewabilityManager = /** @class */ (function () {
9
+ function ViewabilityManager(flashListRef) {
10
+ var _this = this;
11
+ var _a;
12
+ this.viewabilityHelpers = [];
13
+ this.hasInteracted = false;
14
+ this.dispose = function () {
15
+ _this.viewabilityHelpers.forEach(function (viewabilityHelper) {
16
+ return viewabilityHelper.dispose();
17
+ });
18
+ };
19
+ this.onVisibleIndicesChanged = function (all) {
20
+ _this.updateViewableItems(all);
21
+ };
22
+ this.recordInteraction = function () {
23
+ if (_this.hasInteracted) {
24
+ return;
25
+ }
26
+ _this.hasInteracted = true;
27
+ _this.viewabilityHelpers.forEach(function (viewabilityHelper) {
28
+ viewabilityHelper.hasInteracted = true;
29
+ });
30
+ _this.updateViewableItems();
31
+ };
32
+ this.updateViewableItems = function (newViewableIndices) {
33
+ var _a, _b, _c;
34
+ var listSize = (_a = _this.flashListRef.recyclerlistview_unsafe) === null || _a === void 0 ? void 0 : _a.getRenderedSize();
35
+ if (listSize === undefined || !_this.shouldListenToVisibleIndices) {
36
+ return;
37
+ }
38
+ var scrollOffset = ((_c = (_b = _this.flashListRef.recyclerlistview_unsafe) === null || _b === void 0 ? void 0 : _b.getCurrentScrollOffset()) !== null && _c !== void 0 ? _c : 0) - _this.flashListRef.firstItemOffset;
39
+ _this.viewabilityHelpers.forEach(function (viewabilityHelper) {
40
+ var _a;
41
+ viewabilityHelper.updateViewableItems((_a = _this.flashListRef.props.horizontal) !== null && _a !== void 0 ? _a : false, scrollOffset, listSize, function (index) { var _a; return (_a = _this.flashListRef.recyclerlistview_unsafe) === null || _a === void 0 ? void 0 : _a.getLayout(index); }, newViewableIndices);
42
+ });
43
+ };
44
+ /**
45
+ * Creates a new `ViewabilityHelper` instance with `onViewableItemsChanged` callback and `ViewabilityConfig`
46
+ * @returns `ViewabilityHelper` instance
47
+ */
48
+ this.createViewabilityHelper = function (viewabilityConfig, onViewableItemsChanged) {
49
+ var mapViewToken = function (index, isViewable) {
50
+ var _a;
51
+ var item = (_a = _this.flashListRef.props.data) === null || _a === void 0 ? void 0 : _a[index];
52
+ var key = item === undefined || _this.flashListRef.props.keyExtractor === undefined
53
+ ? index.toString()
54
+ : _this.flashListRef.props.keyExtractor(item, index);
55
+ return {
56
+ index: index,
57
+ isViewable: isViewable,
58
+ item: item,
59
+ key: key,
60
+ timestamp: Date.now(),
61
+ };
62
+ };
63
+ return new ViewabilityHelper_1.default(viewabilityConfig, function (indices, newlyVisibleIndices, newlyNonvisibleIndices) {
64
+ onViewableItemsChanged === null || onViewableItemsChanged === void 0 ? void 0 : onViewableItemsChanged({
65
+ viewableItems: indices.map(function (index) { return mapViewToken(index, true); }),
66
+ changed: tslib_1.__spreadArray(tslib_1.__spreadArray([], tslib_1.__read(newlyVisibleIndices.map(function (index) { return mapViewToken(index, true); })), false), tslib_1.__read(newlyNonvisibleIndices.map(function (index) {
67
+ return mapViewToken(index, false);
68
+ })), false),
69
+ });
70
+ });
71
+ };
72
+ this.flashListRef = flashListRef;
73
+ if (flashListRef.props.onViewableItemsChanged !== null &&
74
+ flashListRef.props.onViewableItemsChanged !== undefined) {
75
+ this.viewabilityHelpers.push(this.createViewabilityHelper(flashListRef.props.viewabilityConfig, flashListRef.props.onViewableItemsChanged));
76
+ }
77
+ ((_a = flashListRef.props.viewabilityConfigCallbackPairs) !== null && _a !== void 0 ? _a : []).forEach(function (pair) {
78
+ _this.viewabilityHelpers.push(_this.createViewabilityHelper(pair.viewabilityConfig, pair.onViewableItemsChanged));
79
+ });
80
+ }
81
+ Object.defineProperty(ViewabilityManager.prototype, "shouldListenToVisibleIndices", {
82
+ /**
83
+ * @returns true if the viewability manager has any viewability callback pairs registered.
84
+ */
85
+ get: function () {
86
+ return this.viewabilityHelpers.length > 0;
87
+ },
88
+ enumerable: false,
89
+ configurable: true
90
+ });
91
+ return ViewabilityManager;
92
+ }());
93
+ exports.default = ViewabilityManager;
94
+ //# sourceMappingURL=ViewabilityManager.js.map