react-native-list 1.0.0 → 2.0.0-alpha.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.
- package/README.md +190 -32
- package/ReactNativeList.podspec +39 -0
- package/android/CMakeLists.txt +48 -0
- package/android/build.gradle +151 -0
- package/android/fix-prefab.gradle +51 -0
- package/android/gradle.properties +5 -0
- package/android/src/main/AndroidManifest.xml +2 -0
- package/android/src/main/cpp/JHybridUiListModule.cpp +192 -0
- package/android/src/main/cpp/JHybridUiListModule.h +50 -0
- package/android/src/main/cpp/cpp-adapter.cpp +12 -0
- package/android/src/main/java/com/hannojg/reactnativelist/ReactNativeListPackage.kt +27 -0
- package/android/src/main/java/com/margelo/nitro/reactnativelist/HybridNativeListDataSource.kt +146 -0
- package/android/src/main/java/com/margelo/nitro/reactnativelist/HybridNativeListLayout.kt +86 -0
- package/android/src/main/java/com/margelo/nitro/reactnativelist/HybridUiListModule.kt +116 -0
- package/android/src/main/java/com/margelo/nitro/reactnativelist/HybridUiListView.kt +410 -0
- package/android/src/main/java/com/margelo/nitro/reactnativelist/HybridViewHolder.kt +9 -0
- package/android/src/main/java/com/margelo/nitro/reactnativelist/NativeListAdapter.kt +217 -0
- package/ios/DataSource/HybridNativeListDataSource.swift +213 -0
- package/ios/HybridObjects/HybridUiListModule.swift +49 -0
- package/ios/HybridObjects/HybridViewHolder.swift +16 -0
- package/ios/Layout/HybridNativeListLayout.swift +128 -0
- package/ios/Utils/ErrorUtils.h +26 -0
- package/ios/Utils/HybridIOSWorkletsModuleProxyHolder.swift +10 -0
- package/ios/Utils/SurfaceHelper.h +20 -0
- package/ios/Utils/SurfaceHelper.mm +144 -0
- package/ios/Utils/SurfacePresenterRegistry.h +17 -0
- package/ios/Utils/SurfacePresenterRegistry.m +31 -0
- package/ios/Utils/TurboModuleInstaller.h +18 -0
- package/ios/Utils/TurboModuleInstaller.mm +267 -0
- package/ios/Views/HostCell.swift +216 -0
- package/ios/Views/HybridUiListView.swift +695 -0
- package/metro/RendererProxyThreadSwitch.js +66 -0
- package/metro-config.d.ts +1 -0
- package/metro-config.js +52 -0
- package/nitro.json +47 -0
- package/nitrogen/generated/.gitattributes +1 -0
- package/nitrogen/generated/android/ReactNativeList+autolinking.cmake +99 -0
- package/nitrogen/generated/android/ReactNativeList+autolinking.gradle +27 -0
- package/nitrogen/generated/android/ReactNativeListOnLoad.cpp +156 -0
- package/nitrogen/generated/android/ReactNativeListOnLoad.hpp +34 -0
- package/nitrogen/generated/android/c++/JFunc_bool_NativeListItem_NativeListItem.hpp +83 -0
- package/nitrogen/generated/android/c++/JFunc_bool_double_NativeListItem_double.hpp +83 -0
- package/nitrogen/generated/android/c++/JFunc_double_std__string.hpp +78 -0
- package/nitrogen/generated/android/c++/JHybridIOSWorkletsModuleProxyHolderSpec.cpp +49 -0
- package/nitrogen/generated/android/c++/JHybridIOSWorkletsModuleProxyHolderSpec.hpp +63 -0
- package/nitrogen/generated/android/c++/JHybridNativeLinearListLayoutSpec.cpp +63 -0
- package/nitrogen/generated/android/c++/JHybridNativeLinearListLayoutSpec.hpp +65 -0
- package/nitrogen/generated/android/c++/JHybridNativeListDataSourceSpec.cpp +101 -0
- package/nitrogen/generated/android/c++/JHybridNativeListDataSourceSpec.hpp +70 -0
- package/nitrogen/generated/android/c++/JHybridNativeListLayoutSpec.cpp +49 -0
- package/nitrogen/generated/android/c++/JHybridNativeListLayoutSpec.hpp +63 -0
- package/nitrogen/generated/android/c++/JHybridUiListModuleSpec.cpp +65 -0
- package/nitrogen/generated/android/c++/JHybridUiListModuleSpec.hpp +64 -0
- package/nitrogen/generated/android/c++/JHybridUiListViewSpec.cpp +92 -0
- package/nitrogen/generated/android/c++/JHybridUiListViewSpec.hpp +67 -0
- package/nitrogen/generated/android/c++/JHybridViewHolderSpec.cpp +49 -0
- package/nitrogen/generated/android/c++/JHybridViewHolderSpec.hpp +63 -0
- package/nitrogen/generated/android/c++/JNativeItemSizeEstimate.hpp +61 -0
- package/nitrogen/generated/android/c++/JNativeLinearListLayoutConfig.hpp +81 -0
- package/nitrogen/generated/android/c++/JNativeLinearListLayoutIOSConfig.hpp +59 -0
- package/nitrogen/generated/android/c++/JNativeListItem.hpp +76 -0
- package/nitrogen/generated/android/c++/JVariant_NullType_HybridIOSWorkletsModuleProxyHolderSpec.cpp +26 -0
- package/nitrogen/generated/android/c++/JVariant_NullType_HybridIOSWorkletsModuleProxyHolderSpec.hpp +72 -0
- package/nitrogen/generated/android/c++/views/JHybridUiListViewStateUpdater.cpp +53 -0
- package/nitrogen/generated/android/c++/views/JHybridUiListViewStateUpdater.hpp +49 -0
- package/nitrogen/generated/android/c++/views/JHybridViewHolderStateUpdater.cpp +53 -0
- package/nitrogen/generated/android/c++/views/JHybridViewHolderStateUpdater.hpp +49 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/Func_bool_NativeListItem_NativeListItem.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/Func_bool_double_NativeListItem_double.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/Func_double_std__string.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/HybridIOSWorkletsModuleProxyHolderSpec.kt +52 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/HybridNativeLinearListLayoutSpec.kt +54 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/HybridNativeListDataSourceSpec.kt +87 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/HybridNativeListLayoutSpec.kt +52 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/HybridUiListModuleSpec.kt +59 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/HybridUiListViewSpec.kt +76 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/HybridViewHolderSpec.kt +53 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/NativeItemSizeEstimate.kt +56 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/NativeLinearListLayoutConfig.kt +76 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/NativeLinearListLayoutIOSConfig.kt +51 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/NativeListItem.kt +71 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/ReactNativeListOnLoad.kt +35 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/Variant_NullType_HybridIOSWorkletsModuleProxyHolderSpec.kt +62 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/views/HybridUiListViewManager.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/views/HybridUiListViewStateUpdater.kt +23 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/views/HybridViewHolderManager.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativelist/views/HybridViewHolderStateUpdater.kt +23 -0
- package/nitrogen/generated/ios/ReactNativeList+autolinking.rb +62 -0
- package/nitrogen/generated/ios/ReactNativeList-Swift-Cxx-Bridge.cpp +162 -0
- package/nitrogen/generated/ios/ReactNativeList-Swift-Cxx-Bridge.hpp +368 -0
- package/nitrogen/generated/ios/ReactNativeList-Swift-Cxx-Umbrella.hpp +92 -0
- package/nitrogen/generated/ios/ReactNativeListAutolinking.mm +83 -0
- package/nitrogen/generated/ios/ReactNativeListAutolinking.swift +86 -0
- package/nitrogen/generated/ios/c++/HybridIOSWorkletsModuleProxyHolderSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridIOSWorkletsModuleProxyHolderSpecSwift.hpp +75 -0
- package/nitrogen/generated/ios/c++/HybridNativeLinearListLayoutSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridNativeLinearListLayoutSpecSwift.hpp +92 -0
- package/nitrogen/generated/ios/c++/HybridNativeListDataSourceSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridNativeListDataSourceSpecSwift.hpp +132 -0
- package/nitrogen/generated/ios/c++/HybridNativeListLayoutSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridNativeListLayoutSpecSwift.hpp +75 -0
- package/nitrogen/generated/ios/c++/HybridUiListModuleSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridUiListModuleSpecSwift.hpp +93 -0
- package/nitrogen/generated/ios/c++/HybridUiListViewSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridUiListViewSpecSwift.hpp +121 -0
- package/nitrogen/generated/ios/c++/HybridViewHolderSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridViewHolderSpecSwift.hpp +75 -0
- package/nitrogen/generated/ios/c++/views/HybridUiListViewComponent.mm +118 -0
- package/nitrogen/generated/ios/c++/views/HybridViewHolderComponent.mm +118 -0
- package/nitrogen/generated/ios/swift/Func_bool_NativeListItem_NativeListItem.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_bool_double_NativeListItem_double.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_double_std__string.swift +47 -0
- package/nitrogen/generated/ios/swift/HybridIOSWorkletsModuleProxyHolderSpec.swift +55 -0
- package/nitrogen/generated/ios/swift/HybridIOSWorkletsModuleProxyHolderSpec_cxx.swift +128 -0
- package/nitrogen/generated/ios/swift/HybridNativeLinearListLayoutSpec.swift +55 -0
- package/nitrogen/generated/ios/swift/HybridNativeLinearListLayoutSpec_cxx.swift +140 -0
- package/nitrogen/generated/ios/swift/HybridNativeListDataSourceSpec.swift +62 -0
- package/nitrogen/generated/ios/swift/HybridNativeListDataSourceSpec_cxx.swift +222 -0
- package/nitrogen/generated/ios/swift/HybridNativeListLayoutSpec.swift +55 -0
- package/nitrogen/generated/ios/swift/HybridNativeListLayoutSpec_cxx.swift +128 -0
- package/nitrogen/generated/ios/swift/HybridUiListModuleSpec.swift +56 -0
- package/nitrogen/generated/ios/swift/HybridUiListModuleSpec_cxx.swift +175 -0
- package/nitrogen/generated/ios/swift/HybridUiListViewSpec.swift +59 -0
- package/nitrogen/generated/ios/swift/HybridUiListViewSpec_cxx.swift +227 -0
- package/nitrogen/generated/ios/swift/HybridViewHolderSpec.swift +55 -0
- package/nitrogen/generated/ios/swift/HybridViewHolderSpec_cxx.swift +147 -0
- package/nitrogen/generated/ios/swift/NativeItemSizeEstimate.swift +60 -0
- package/nitrogen/generated/ios/swift/NativeLinearListLayoutConfig.swift +60 -0
- package/nitrogen/generated/ios/swift/NativeLinearListLayoutIOSConfig.swift +35 -0
- package/nitrogen/generated/ios/swift/NativeListItem.swift +75 -0
- package/nitrogen/generated/ios/swift/Variant_NullType__any_HybridIOSWorkletsModuleProxyHolderSpec_.swift +30 -0
- package/nitrogen/generated/shared/c++/HybridIOSWorkletsModuleProxyHolderSpec.cpp +21 -0
- package/nitrogen/generated/shared/c++/HybridIOSWorkletsModuleProxyHolderSpec.hpp +62 -0
- package/nitrogen/generated/shared/c++/HybridNativeLinearListLayoutSpec.cpp +22 -0
- package/nitrogen/generated/shared/c++/HybridNativeLinearListLayoutSpec.hpp +67 -0
- package/nitrogen/generated/shared/c++/HybridNativeListDataSourceSpec.cpp +28 -0
- package/nitrogen/generated/shared/c++/HybridNativeListDataSourceSpec.hpp +72 -0
- package/nitrogen/generated/shared/c++/HybridNativeListLayoutSpec.cpp +21 -0
- package/nitrogen/generated/shared/c++/HybridNativeListLayoutSpec.hpp +62 -0
- package/nitrogen/generated/shared/c++/HybridUiListModuleSpec.cpp +22 -0
- package/nitrogen/generated/shared/c++/HybridUiListModuleSpec.hpp +68 -0
- package/nitrogen/generated/shared/c++/HybridUiListViewSpec.cpp +25 -0
- package/nitrogen/generated/shared/c++/HybridUiListViewSpec.hpp +79 -0
- package/nitrogen/generated/shared/c++/HybridUiManagerHelperSpec.cpp +23 -0
- package/nitrogen/generated/shared/c++/HybridUiManagerHelperSpec.hpp +65 -0
- package/nitrogen/generated/shared/c++/HybridViewHolderSpec.cpp +21 -0
- package/nitrogen/generated/shared/c++/HybridViewHolderSpec.hpp +62 -0
- package/nitrogen/generated/shared/c++/NativeItemSizeEstimate.hpp +87 -0
- package/nitrogen/generated/shared/c++/NativeLinearListLayoutConfig.hpp +105 -0
- package/nitrogen/generated/shared/c++/NativeLinearListLayoutIOSConfig.hpp +85 -0
- package/nitrogen/generated/shared/c++/NativeListItem.hpp +101 -0
- package/nitrogen/generated/shared/c++/views/HybridUiListViewComponent.cpp +72 -0
- package/nitrogen/generated/shared/c++/views/HybridUiListViewComponent.hpp +109 -0
- package/nitrogen/generated/shared/c++/views/HybridViewHolderComponent.cpp +72 -0
- package/nitrogen/generated/shared/c++/views/HybridViewHolderComponent.hpp +109 -0
- package/nitrogen/generated/shared/json/UiListViewConfig.json +9 -0
- package/nitrogen/generated/shared/json/ViewHolderConfig.json +9 -0
- package/package.json +152 -5
- package/react-native.config.js +16 -0
- package/src/ListDataSource.ts +232 -0
- package/src/ListLayout.ts +95 -0
- package/src/UiListModule.ts +5 -0
- package/src/hooks/useChangeEffect.ts +50 -0
- package/src/index.tsx +49 -0
- package/src/privateGlobals.ts +20 -0
- package/src/renderer/fabric/RenderHelper.ts +29 -0
- package/src/renderer/fabric/UiManagerHelper.ts +5 -0
- package/src/renderer/react/ReactFabricMirror.bundle.js +1984 -0
- package/src/renderer/react/ReactFabricMirror.ts +766 -0
- package/src/renderer/react/ReactFabricRenderer.ts +11 -0
- package/src/specs/IOSWorkletsModuleProxyHolder.nitro.ts +6 -0
- package/src/specs/NativeLinearListLayout.nitro.ts +23 -0
- package/src/specs/NativeListDataSource.nitro.ts +28 -0
- package/src/specs/NativeListLayout.nitro.ts +6 -0
- package/src/specs/UIListModule.nitro.ts +13 -0
- package/src/specs/UIManagerHelper.nitro.ts +34 -0
- package/src/specs/UiListView.nitro.ts +31 -0
- package/src/specs/ViewHolder.nitro.ts +11 -0
- package/src/views/List.tsx +525 -0
- package/src/views/UiListHostComponent.ts +8 -0
- package/FillRateHelper.js +0 -179
- package/FlatList.js +0 -494
- package/LICENSE.md +0 -31
- package/ListView/__mocks__/ListViewMock.js +0 -55
- package/MetroListView.js +0 -166
- package/SectionList.js +0 -291
- package/ViewabilityHelper.js +0 -260
- package/VirtualizeUtils.js +0 -163
- package/VirtualizedList.js +0 -861
- package/VirtualizedSectionList.js +0 -397
- package/__flowtests__/FlatList-flowtest.js +0 -90
- package/__flowtests__/SectionList-flowtest.js +0 -89
- package/__tests__/FillRateHelper-test.js +0 -106
- package/__tests__/FlatList-test.js +0 -64
- package/__tests__/SectionList-test.js +0 -67
- package/__tests__/ViewabilityHelper-test.js +0 -359
- package/__tests__/VirtualizeUtils-test.js +0 -74
- package/__tests__/__snapshots__/FlatList-test.js.snap +0 -251
- package/__tests__/__snapshots__/SectionList-test.js.snap +0 -283
- package/index.js +0 -5
|
@@ -1,251 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`FlatList renders all the bells and whistles 1`] = `
|
|
4
|
-
<RCTScrollView
|
|
5
|
-
ItemSeparatorComponent={[Function]}
|
|
6
|
-
ListFooterComponent={[Function]}
|
|
7
|
-
ListHeaderComponent={[Function]}
|
|
8
|
-
data={
|
|
9
|
-
Array [
|
|
10
|
-
Object {
|
|
11
|
-
"id": "0",
|
|
12
|
-
},
|
|
13
|
-
Object {
|
|
14
|
-
"id": "1",
|
|
15
|
-
},
|
|
16
|
-
Object {
|
|
17
|
-
"id": "2",
|
|
18
|
-
},
|
|
19
|
-
Object {
|
|
20
|
-
"id": "3",
|
|
21
|
-
},
|
|
22
|
-
Object {
|
|
23
|
-
"id": "4",
|
|
24
|
-
},
|
|
25
|
-
]
|
|
26
|
-
}
|
|
27
|
-
disableVirtualization={false}
|
|
28
|
-
getItem={[Function]}
|
|
29
|
-
getItemCount={[Function]}
|
|
30
|
-
getItemLayout={[Function]}
|
|
31
|
-
horizontal={false}
|
|
32
|
-
initialNumToRender={10}
|
|
33
|
-
keyExtractor={[Function]}
|
|
34
|
-
maxToRenderPerBatch={10}
|
|
35
|
-
numColumns={2}
|
|
36
|
-
onContentSizeChange={[Function]}
|
|
37
|
-
onEndReachedThreshold={2}
|
|
38
|
-
onLayout={[Function]}
|
|
39
|
-
onRefresh={[Function]}
|
|
40
|
-
onScroll={[Function]}
|
|
41
|
-
onScrollBeginDrag={[Function]}
|
|
42
|
-
onViewableItemsChanged={undefined}
|
|
43
|
-
refreshControl={
|
|
44
|
-
<RefreshControlMock
|
|
45
|
-
onRefresh={[Function]}
|
|
46
|
-
refreshing={false}
|
|
47
|
-
/>
|
|
48
|
-
}
|
|
49
|
-
refreshing={false}
|
|
50
|
-
renderItem={[Function]}
|
|
51
|
-
renderScrollComponent={[Function]}
|
|
52
|
-
scrollEventThrottle={50}
|
|
53
|
-
stickyHeaderIndices={Array []}
|
|
54
|
-
updateCellsBatchingPeriod={50}
|
|
55
|
-
windowSize={21}
|
|
56
|
-
>
|
|
57
|
-
<RCTRefreshControl />
|
|
58
|
-
<View>
|
|
59
|
-
<View
|
|
60
|
-
onLayout={[Function]}
|
|
61
|
-
>
|
|
62
|
-
<header />
|
|
63
|
-
</View>
|
|
64
|
-
<View
|
|
65
|
-
onLayout={undefined}
|
|
66
|
-
>
|
|
67
|
-
<View
|
|
68
|
-
style={
|
|
69
|
-
Array [
|
|
70
|
-
Object {
|
|
71
|
-
"flexDirection": "row",
|
|
72
|
-
},
|
|
73
|
-
undefined,
|
|
74
|
-
]
|
|
75
|
-
}
|
|
76
|
-
>
|
|
77
|
-
<item
|
|
78
|
-
value="0"
|
|
79
|
-
/>
|
|
80
|
-
<item
|
|
81
|
-
value="1"
|
|
82
|
-
/>
|
|
83
|
-
</View>
|
|
84
|
-
<separator />
|
|
85
|
-
</View>
|
|
86
|
-
<View
|
|
87
|
-
onLayout={undefined}
|
|
88
|
-
>
|
|
89
|
-
<View
|
|
90
|
-
style={
|
|
91
|
-
Array [
|
|
92
|
-
Object {
|
|
93
|
-
"flexDirection": "row",
|
|
94
|
-
},
|
|
95
|
-
undefined,
|
|
96
|
-
]
|
|
97
|
-
}
|
|
98
|
-
>
|
|
99
|
-
<item
|
|
100
|
-
value="2"
|
|
101
|
-
/>
|
|
102
|
-
<item
|
|
103
|
-
value="3"
|
|
104
|
-
/>
|
|
105
|
-
</View>
|
|
106
|
-
<separator />
|
|
107
|
-
</View>
|
|
108
|
-
<View
|
|
109
|
-
onLayout={undefined}
|
|
110
|
-
>
|
|
111
|
-
<View
|
|
112
|
-
style={
|
|
113
|
-
Array [
|
|
114
|
-
Object {
|
|
115
|
-
"flexDirection": "row",
|
|
116
|
-
},
|
|
117
|
-
undefined,
|
|
118
|
-
]
|
|
119
|
-
}
|
|
120
|
-
>
|
|
121
|
-
<item
|
|
122
|
-
value="4"
|
|
123
|
-
/>
|
|
124
|
-
</View>
|
|
125
|
-
</View>
|
|
126
|
-
<View
|
|
127
|
-
onLayout={[Function]}
|
|
128
|
-
>
|
|
129
|
-
<footer />
|
|
130
|
-
</View>
|
|
131
|
-
</View>
|
|
132
|
-
</RCTScrollView>
|
|
133
|
-
`;
|
|
134
|
-
|
|
135
|
-
exports[`FlatList renders empty list 1`] = `
|
|
136
|
-
<RCTScrollView
|
|
137
|
-
data={Array []}
|
|
138
|
-
disableVirtualization={false}
|
|
139
|
-
getItem={[Function]}
|
|
140
|
-
getItemCount={[Function]}
|
|
141
|
-
horizontal={false}
|
|
142
|
-
initialNumToRender={10}
|
|
143
|
-
keyExtractor={[Function]}
|
|
144
|
-
maxToRenderPerBatch={10}
|
|
145
|
-
numColumns={1}
|
|
146
|
-
onContentSizeChange={[Function]}
|
|
147
|
-
onEndReachedThreshold={2}
|
|
148
|
-
onLayout={[Function]}
|
|
149
|
-
onScroll={[Function]}
|
|
150
|
-
onScrollBeginDrag={[Function]}
|
|
151
|
-
onViewableItemsChanged={undefined}
|
|
152
|
-
renderItem={[Function]}
|
|
153
|
-
renderScrollComponent={[Function]}
|
|
154
|
-
scrollEventThrottle={50}
|
|
155
|
-
stickyHeaderIndices={Array []}
|
|
156
|
-
updateCellsBatchingPeriod={50}
|
|
157
|
-
windowSize={21}
|
|
158
|
-
>
|
|
159
|
-
<View />
|
|
160
|
-
</RCTScrollView>
|
|
161
|
-
`;
|
|
162
|
-
|
|
163
|
-
exports[`FlatList renders null list 1`] = `
|
|
164
|
-
<RCTScrollView
|
|
165
|
-
data={undefined}
|
|
166
|
-
disableVirtualization={false}
|
|
167
|
-
getItem={[Function]}
|
|
168
|
-
getItemCount={[Function]}
|
|
169
|
-
horizontal={false}
|
|
170
|
-
initialNumToRender={10}
|
|
171
|
-
keyExtractor={[Function]}
|
|
172
|
-
maxToRenderPerBatch={10}
|
|
173
|
-
numColumns={1}
|
|
174
|
-
onContentSizeChange={[Function]}
|
|
175
|
-
onEndReachedThreshold={2}
|
|
176
|
-
onLayout={[Function]}
|
|
177
|
-
onScroll={[Function]}
|
|
178
|
-
onScrollBeginDrag={[Function]}
|
|
179
|
-
onViewableItemsChanged={undefined}
|
|
180
|
-
renderItem={[Function]}
|
|
181
|
-
renderScrollComponent={[Function]}
|
|
182
|
-
scrollEventThrottle={50}
|
|
183
|
-
stickyHeaderIndices={Array []}
|
|
184
|
-
updateCellsBatchingPeriod={50}
|
|
185
|
-
windowSize={21}
|
|
186
|
-
>
|
|
187
|
-
<View />
|
|
188
|
-
</RCTScrollView>
|
|
189
|
-
`;
|
|
190
|
-
|
|
191
|
-
exports[`FlatList renders simple list 1`] = `
|
|
192
|
-
<RCTScrollView
|
|
193
|
-
data={
|
|
194
|
-
Array [
|
|
195
|
-
Object {
|
|
196
|
-
"key": "i1",
|
|
197
|
-
},
|
|
198
|
-
Object {
|
|
199
|
-
"key": "i2",
|
|
200
|
-
},
|
|
201
|
-
Object {
|
|
202
|
-
"key": "i3",
|
|
203
|
-
},
|
|
204
|
-
]
|
|
205
|
-
}
|
|
206
|
-
disableVirtualization={false}
|
|
207
|
-
getItem={[Function]}
|
|
208
|
-
getItemCount={[Function]}
|
|
209
|
-
horizontal={false}
|
|
210
|
-
initialNumToRender={10}
|
|
211
|
-
keyExtractor={[Function]}
|
|
212
|
-
maxToRenderPerBatch={10}
|
|
213
|
-
numColumns={1}
|
|
214
|
-
onContentSizeChange={[Function]}
|
|
215
|
-
onEndReachedThreshold={2}
|
|
216
|
-
onLayout={[Function]}
|
|
217
|
-
onScroll={[Function]}
|
|
218
|
-
onScrollBeginDrag={[Function]}
|
|
219
|
-
onViewableItemsChanged={undefined}
|
|
220
|
-
renderItem={[Function]}
|
|
221
|
-
renderScrollComponent={[Function]}
|
|
222
|
-
scrollEventThrottle={50}
|
|
223
|
-
stickyHeaderIndices={Array []}
|
|
224
|
-
updateCellsBatchingPeriod={50}
|
|
225
|
-
windowSize={21}
|
|
226
|
-
>
|
|
227
|
-
<View>
|
|
228
|
-
<View
|
|
229
|
-
onLayout={[Function]}
|
|
230
|
-
>
|
|
231
|
-
<item
|
|
232
|
-
value="i1"
|
|
233
|
-
/>
|
|
234
|
-
</View>
|
|
235
|
-
<View
|
|
236
|
-
onLayout={[Function]}
|
|
237
|
-
>
|
|
238
|
-
<item
|
|
239
|
-
value="i2"
|
|
240
|
-
/>
|
|
241
|
-
</View>
|
|
242
|
-
<View
|
|
243
|
-
onLayout={[Function]}
|
|
244
|
-
>
|
|
245
|
-
<item
|
|
246
|
-
value="i3"
|
|
247
|
-
/>
|
|
248
|
-
</View>
|
|
249
|
-
</View>
|
|
250
|
-
</RCTScrollView>
|
|
251
|
-
`;
|
|
@@ -1,283 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`SectionList rendering empty section headers is fine 1`] = `
|
|
4
|
-
<RCTScrollView
|
|
5
|
-
ItemSeparatorComponent={undefined}
|
|
6
|
-
data={
|
|
7
|
-
Array [
|
|
8
|
-
Object {
|
|
9
|
-
"data": Array [
|
|
10
|
-
Object {
|
|
11
|
-
"key": "i1",
|
|
12
|
-
},
|
|
13
|
-
Object {
|
|
14
|
-
"key": "i2",
|
|
15
|
-
},
|
|
16
|
-
],
|
|
17
|
-
"key": "s1",
|
|
18
|
-
},
|
|
19
|
-
]
|
|
20
|
-
}
|
|
21
|
-
disableVirtualization={false}
|
|
22
|
-
getItem={[Function]}
|
|
23
|
-
getItemCount={[Function]}
|
|
24
|
-
horizontal={false}
|
|
25
|
-
initialNumToRender={10}
|
|
26
|
-
keyExtractor={[Function]}
|
|
27
|
-
maxToRenderPerBatch={10}
|
|
28
|
-
onContentSizeChange={[Function]}
|
|
29
|
-
onEndReachedThreshold={2}
|
|
30
|
-
onLayout={[Function]}
|
|
31
|
-
onScroll={[Function]}
|
|
32
|
-
onScrollBeginDrag={[Function]}
|
|
33
|
-
onViewableItemsChanged={undefined}
|
|
34
|
-
renderItem={[Function]}
|
|
35
|
-
renderScrollComponent={[Function]}
|
|
36
|
-
renderSectionHeader={[Function]}
|
|
37
|
-
scrollEventThrottle={50}
|
|
38
|
-
sections={
|
|
39
|
-
Array [
|
|
40
|
-
Object {
|
|
41
|
-
"data": Array [
|
|
42
|
-
Object {
|
|
43
|
-
"key": "i1",
|
|
44
|
-
},
|
|
45
|
-
Object {
|
|
46
|
-
"key": "i2",
|
|
47
|
-
},
|
|
48
|
-
],
|
|
49
|
-
"key": "s1",
|
|
50
|
-
},
|
|
51
|
-
]
|
|
52
|
-
}
|
|
53
|
-
stickyHeaderIndices={
|
|
54
|
-
Array [
|
|
55
|
-
0,
|
|
56
|
-
]
|
|
57
|
-
}
|
|
58
|
-
stickySectionHeadersEnabled={true}
|
|
59
|
-
updateCellsBatchingPeriod={50}
|
|
60
|
-
windowSize={21}
|
|
61
|
-
>
|
|
62
|
-
<View>
|
|
63
|
-
<View
|
|
64
|
-
onLayout={[Function]}
|
|
65
|
-
/>
|
|
66
|
-
<View
|
|
67
|
-
onLayout={[Function]}
|
|
68
|
-
>
|
|
69
|
-
<item
|
|
70
|
-
value="i1"
|
|
71
|
-
/>
|
|
72
|
-
</View>
|
|
73
|
-
<View
|
|
74
|
-
onLayout={[Function]}
|
|
75
|
-
>
|
|
76
|
-
<item
|
|
77
|
-
value="i2"
|
|
78
|
-
/>
|
|
79
|
-
</View>
|
|
80
|
-
</View>
|
|
81
|
-
</RCTScrollView>
|
|
82
|
-
`;
|
|
83
|
-
|
|
84
|
-
exports[`SectionList renders all the bells and whistles 1`] = `
|
|
85
|
-
<RCTScrollView
|
|
86
|
-
ItemSeparatorComponent={undefined}
|
|
87
|
-
ListFooterComponent={[Function]}
|
|
88
|
-
ListHeaderComponent={[Function]}
|
|
89
|
-
SectionSeparatorComponent={[Function]}
|
|
90
|
-
data={
|
|
91
|
-
Array [
|
|
92
|
-
Object {
|
|
93
|
-
"ItemSeparatorComponent": [Function],
|
|
94
|
-
"data": Array [
|
|
95
|
-
Object {
|
|
96
|
-
"id": "i1s1",
|
|
97
|
-
},
|
|
98
|
-
Object {
|
|
99
|
-
"id": "i2s1",
|
|
100
|
-
},
|
|
101
|
-
],
|
|
102
|
-
"key": "1st Section",
|
|
103
|
-
"keyExtractor": [Function],
|
|
104
|
-
"renderItem": [Function],
|
|
105
|
-
},
|
|
106
|
-
Object {
|
|
107
|
-
"data": Array [
|
|
108
|
-
Object {
|
|
109
|
-
"key": "i1s2",
|
|
110
|
-
},
|
|
111
|
-
Object {
|
|
112
|
-
"key": "i2s2",
|
|
113
|
-
},
|
|
114
|
-
],
|
|
115
|
-
"key": "2nd Section",
|
|
116
|
-
},
|
|
117
|
-
]
|
|
118
|
-
}
|
|
119
|
-
disableVirtualization={false}
|
|
120
|
-
getItem={[Function]}
|
|
121
|
-
getItemCount={[Function]}
|
|
122
|
-
horizontal={false}
|
|
123
|
-
initialNumToRender={10}
|
|
124
|
-
keyExtractor={[Function]}
|
|
125
|
-
maxToRenderPerBatch={10}
|
|
126
|
-
onContentSizeChange={[Function]}
|
|
127
|
-
onEndReachedThreshold={2}
|
|
128
|
-
onLayout={[Function]}
|
|
129
|
-
onRefresh={[Function]}
|
|
130
|
-
onScroll={[Function]}
|
|
131
|
-
onScrollBeginDrag={[Function]}
|
|
132
|
-
onViewableItemsChanged={undefined}
|
|
133
|
-
refreshControl={
|
|
134
|
-
<RefreshControlMock
|
|
135
|
-
onRefresh={[Function]}
|
|
136
|
-
refreshing={false}
|
|
137
|
-
/>
|
|
138
|
-
}
|
|
139
|
-
refreshing={false}
|
|
140
|
-
renderItem={[Function]}
|
|
141
|
-
renderScrollComponent={[Function]}
|
|
142
|
-
renderSectionHeader={[Function]}
|
|
143
|
-
scrollEventThrottle={50}
|
|
144
|
-
sections={
|
|
145
|
-
Array [
|
|
146
|
-
Object {
|
|
147
|
-
"ItemSeparatorComponent": [Function],
|
|
148
|
-
"data": Array [
|
|
149
|
-
Object {
|
|
150
|
-
"id": "i1s1",
|
|
151
|
-
},
|
|
152
|
-
Object {
|
|
153
|
-
"id": "i2s1",
|
|
154
|
-
},
|
|
155
|
-
],
|
|
156
|
-
"key": "1st Section",
|
|
157
|
-
"keyExtractor": [Function],
|
|
158
|
-
"renderItem": [Function],
|
|
159
|
-
},
|
|
160
|
-
Object {
|
|
161
|
-
"data": Array [
|
|
162
|
-
Object {
|
|
163
|
-
"key": "i1s2",
|
|
164
|
-
},
|
|
165
|
-
Object {
|
|
166
|
-
"key": "i2s2",
|
|
167
|
-
},
|
|
168
|
-
],
|
|
169
|
-
"key": "2nd Section",
|
|
170
|
-
},
|
|
171
|
-
]
|
|
172
|
-
}
|
|
173
|
-
stickyHeaderIndices={
|
|
174
|
-
Array [
|
|
175
|
-
1,
|
|
176
|
-
4,
|
|
177
|
-
]
|
|
178
|
-
}
|
|
179
|
-
stickySectionHeadersEnabled={true}
|
|
180
|
-
updateCellsBatchingPeriod={50}
|
|
181
|
-
windowSize={21}
|
|
182
|
-
>
|
|
183
|
-
<RCTRefreshControl />
|
|
184
|
-
<View>
|
|
185
|
-
<View
|
|
186
|
-
onLayout={[Function]}
|
|
187
|
-
>
|
|
188
|
-
<header />
|
|
189
|
-
</View>
|
|
190
|
-
<View
|
|
191
|
-
onLayout={[Function]}
|
|
192
|
-
>
|
|
193
|
-
<sectionHeader
|
|
194
|
-
value="1st Section"
|
|
195
|
-
/>
|
|
196
|
-
</View>
|
|
197
|
-
<View
|
|
198
|
-
onLayout={[Function]}
|
|
199
|
-
>
|
|
200
|
-
<View>
|
|
201
|
-
<sectionSeparator />
|
|
202
|
-
<itemForSection1
|
|
203
|
-
value="i1s1"
|
|
204
|
-
/>
|
|
205
|
-
<itemSeparatorForSection1 />
|
|
206
|
-
</View>
|
|
207
|
-
</View>
|
|
208
|
-
<View
|
|
209
|
-
onLayout={[Function]}
|
|
210
|
-
>
|
|
211
|
-
<View>
|
|
212
|
-
<itemForSection1
|
|
213
|
-
value="i2s1"
|
|
214
|
-
/>
|
|
215
|
-
<sectionSeparator />
|
|
216
|
-
</View>
|
|
217
|
-
</View>
|
|
218
|
-
<View
|
|
219
|
-
onLayout={[Function]}
|
|
220
|
-
>
|
|
221
|
-
<sectionHeader
|
|
222
|
-
value="2nd Section"
|
|
223
|
-
/>
|
|
224
|
-
</View>
|
|
225
|
-
<View
|
|
226
|
-
onLayout={[Function]}
|
|
227
|
-
>
|
|
228
|
-
<View>
|
|
229
|
-
<sectionSeparator />
|
|
230
|
-
<defaultItem
|
|
231
|
-
value="i1s2"
|
|
232
|
-
/>
|
|
233
|
-
<defaultItemSeparator />
|
|
234
|
-
</View>
|
|
235
|
-
</View>
|
|
236
|
-
<View
|
|
237
|
-
onLayout={[Function]}
|
|
238
|
-
>
|
|
239
|
-
<View>
|
|
240
|
-
<defaultItem
|
|
241
|
-
value="i2s2"
|
|
242
|
-
/>
|
|
243
|
-
<sectionSeparator />
|
|
244
|
-
</View>
|
|
245
|
-
</View>
|
|
246
|
-
<View
|
|
247
|
-
onLayout={[Function]}
|
|
248
|
-
>
|
|
249
|
-
<footer />
|
|
250
|
-
</View>
|
|
251
|
-
</View>
|
|
252
|
-
</RCTScrollView>
|
|
253
|
-
`;
|
|
254
|
-
|
|
255
|
-
exports[`SectionList renders empty list 1`] = `
|
|
256
|
-
<RCTScrollView
|
|
257
|
-
ItemSeparatorComponent={undefined}
|
|
258
|
-
data={Array []}
|
|
259
|
-
disableVirtualization={false}
|
|
260
|
-
getItem={[Function]}
|
|
261
|
-
getItemCount={[Function]}
|
|
262
|
-
horizontal={false}
|
|
263
|
-
initialNumToRender={10}
|
|
264
|
-
keyExtractor={[Function]}
|
|
265
|
-
maxToRenderPerBatch={10}
|
|
266
|
-
onContentSizeChange={[Function]}
|
|
267
|
-
onEndReachedThreshold={2}
|
|
268
|
-
onLayout={[Function]}
|
|
269
|
-
onScroll={[Function]}
|
|
270
|
-
onScrollBeginDrag={[Function]}
|
|
271
|
-
onViewableItemsChanged={undefined}
|
|
272
|
-
renderItem={[Function]}
|
|
273
|
-
renderScrollComponent={[Function]}
|
|
274
|
-
scrollEventThrottle={50}
|
|
275
|
-
sections={Array []}
|
|
276
|
-
stickyHeaderIndices={Array []}
|
|
277
|
-
stickySectionHeadersEnabled={true}
|
|
278
|
-
updateCellsBatchingPeriod={50}
|
|
279
|
-
windowSize={21}
|
|
280
|
-
>
|
|
281
|
-
<View />
|
|
282
|
-
</RCTScrollView>
|
|
283
|
-
`;
|