Commit e94d344
Fix behaviour of Header, Footer and Empty List components in VirtualizedList when it's inverted (#24167)
Summary:
Fixes #23453
Fixes #21196
Basically, changes made in #21496 currently breaks behavior of `<VirtualizedList />` and any components that are based on it (`<SectionList />, <FlatList />`). This PR solves both issues listed above.
Visual confirmation of the resolved issue:
**Vertical, not inverted, not empty**

**Vertical, not inverted, empty**

**Vertical, inverted, not empty**

**Vertical, inverted, empty**

**Horizontal, not inverted, not empty**

**Horizontal, not inverted, empty**

**Horizontal, inverted, not empty**

**Horizontal, inverted, empty**

[General] [Fixed] - Fixed VirtualizedList, SectionList and FlatList behavior on rendering list headers with inverted prop and zero items
Pull Request resolved: #24167
Differential Revision: D14642345
Pulled By: cpojer
fbshipit-source-id: b530bbbd57f60e53a976ac5db272ea4b2d2b3e991 parent 13cb5a9 commit e94d344
File tree
2 files changed
+17
-12
lines changed- Libraries/Lists
- __tests__/__snapshots__
2 files changed
+17
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
885 | 885 | | |
886 | 886 | | |
887 | 887 | | |
888 | | - | |
889 | | - | |
890 | | - | |
891 | | - | |
892 | | - | |
893 | | - | |
894 | | - | |
895 | | - | |
896 | | - | |
897 | | - | |
| 888 | + | |
| 889 | + | |
| 890 | + | |
| 891 | + | |
| 892 | + | |
| 893 | + | |
| 894 | + | |
| 895 | + | |
| 896 | + | |
| 897 | + | |
| 898 | + | |
898 | 899 | | |
899 | 900 | | |
900 | 901 | | |
| |||
937 | 938 | | |
938 | 939 | | |
939 | 940 | | |
940 | | - | |
| 941 | + | |
941 | 942 | | |
942 | 943 | | |
943 | 944 | | |
| |||
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
668 | 668 | | |
669 | 669 | | |
670 | 670 | | |
671 | | - | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
| 674 | + | |
| 675 | + | |
672 | 676 | | |
673 | 677 | | |
674 | 678 | | |
| |||
0 commit comments