@legendapp/list 2.1.0-beta.13 → 2.1.0-beta.14
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/index.d.mts +664 -8
- package/index.d.ts +664 -8
- package/index.js +143 -175
- package/index.mjs +143 -175
- package/index.native.d.mts +664 -8
- package/index.native.d.ts +664 -8
- package/index.native.js +144 -154
- package/index.native.mjs +144 -154
- package/package.json +1 -1
- package/section-list.d.mts +0 -113
- package/section-list.d.ts +0 -113
- package/section-list.js +0 -3924
- package/section-list.mjs +0 -3903
- package/section-list.native.d.mts +0 -113
- package/section-list.native.d.ts +0 -113
- package/section-list.native.js +0 -3703
- package/section-list.native.mjs +0 -3682
- package/types-JPHClxiw.d.mts +0 -670
- package/types-JPHClxiw.d.ts +0 -670
- package/types-YNdphn_A.d.mts +0 -670
- package/types-YNdphn_A.d.ts +0 -670
package/section-list.d.ts
DELETED
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
import * as react_native from 'react-native';
|
|
2
|
-
import { SectionListData, SectionBase, SectionListRenderItemInfo, SectionListScrollParams } from 'react-native';
|
|
3
|
-
import * as React from 'react';
|
|
4
|
-
import { a as LegendListRef, L as LegendListProps } from './types-JPHClxiw.js';
|
|
5
|
-
import 'react-native-reanimated';
|
|
6
|
-
|
|
7
|
-
type SectionListSeparatorProps<ItemT, SectionT> = {
|
|
8
|
-
leadingItem?: ItemT;
|
|
9
|
-
leadingSection?: SectionListData<ItemT, SectionT>;
|
|
10
|
-
section: SectionListData<ItemT, SectionT>;
|
|
11
|
-
trailingItem?: ItemT;
|
|
12
|
-
trailingSection?: SectionListData<ItemT, SectionT>;
|
|
13
|
-
};
|
|
14
|
-
type SectionHeaderItem<SectionT> = {
|
|
15
|
-
kind: "header";
|
|
16
|
-
key: string;
|
|
17
|
-
section: SectionT;
|
|
18
|
-
sectionIndex: number;
|
|
19
|
-
};
|
|
20
|
-
type SectionFooterItem<SectionT> = {
|
|
21
|
-
kind: "footer";
|
|
22
|
-
key: string;
|
|
23
|
-
section: SectionT;
|
|
24
|
-
sectionIndex: number;
|
|
25
|
-
};
|
|
26
|
-
type SectionBodyItem<ItemT, SectionT> = {
|
|
27
|
-
kind: "item";
|
|
28
|
-
key: string;
|
|
29
|
-
section: SectionT;
|
|
30
|
-
sectionIndex: number;
|
|
31
|
-
item: ItemT;
|
|
32
|
-
itemIndex: number;
|
|
33
|
-
absoluteItemIndex: number;
|
|
34
|
-
};
|
|
35
|
-
type SectionItemSeparator<ItemT, SectionT> = {
|
|
36
|
-
kind: "item-separator";
|
|
37
|
-
key: string;
|
|
38
|
-
section: SectionT;
|
|
39
|
-
sectionIndex: number;
|
|
40
|
-
leadingItem: ItemT;
|
|
41
|
-
leadingItemIndex: number;
|
|
42
|
-
trailingItem?: ItemT;
|
|
43
|
-
};
|
|
44
|
-
type SectionSeparator<SectionT> = {
|
|
45
|
-
kind: "section-separator";
|
|
46
|
-
key: string;
|
|
47
|
-
leadingSection: SectionT;
|
|
48
|
-
leadingSectionIndex: number;
|
|
49
|
-
trailingSection?: SectionT;
|
|
50
|
-
};
|
|
51
|
-
type FlatSectionListItem<ItemT, SectionT> = SectionHeaderItem<SectionT> | SectionFooterItem<SectionT> | SectionBodyItem<ItemT, SectionT> | SectionItemSeparator<ItemT, SectionT> | SectionSeparator<SectionT>;
|
|
52
|
-
type SectionMeta = {
|
|
53
|
-
header?: number;
|
|
54
|
-
footer?: number;
|
|
55
|
-
items: number[];
|
|
56
|
-
};
|
|
57
|
-
type BuildSectionListDataResult<ItemT, SectionT> = {
|
|
58
|
-
data: Array<FlatSectionListItem<ItemT, SectionT>>;
|
|
59
|
-
sectionMeta: SectionMeta[];
|
|
60
|
-
stickyHeaderIndices: number[];
|
|
61
|
-
};
|
|
62
|
-
|
|
63
|
-
type SectionListViewToken<ItemT, SectionT> = {
|
|
64
|
-
item: ItemT;
|
|
65
|
-
key: string;
|
|
66
|
-
index: number;
|
|
67
|
-
isViewable: boolean;
|
|
68
|
-
section: SectionListData<ItemT, SectionT>;
|
|
69
|
-
};
|
|
70
|
-
type SectionListOnViewableItemsChanged<ItemT, SectionT> = ((info: {
|
|
71
|
-
viewableItems: Array<SectionListViewToken<ItemT, SectionT>>;
|
|
72
|
-
changed: Array<SectionListViewToken<ItemT, SectionT>>;
|
|
73
|
-
}) => void) | null;
|
|
74
|
-
type SectionListLegendProps<ItemT, SectionT> = Omit<LegendListProps<FlatSectionListItem<ItemT, SectionT>>, "data" | "children" | "renderItem" | "keyExtractor" | "ItemSeparatorComponent" | "getItemType" | "getFixedItemSize" | "stickyHeaderIndices" | "numColumns" | "columnWrapperStyle" | "onViewableItemsChanged">;
|
|
75
|
-
type SectionListProps<ItemT, SectionT extends SectionBase<ItemT> = SectionBase<ItemT>> = SectionListLegendProps<ItemT, SectionT> & {
|
|
76
|
-
sections: ReadonlyArray<SectionListData<ItemT, SectionT>>;
|
|
77
|
-
extraData?: any;
|
|
78
|
-
renderItem?: (info: SectionListRenderItemInfo<ItemT, SectionT>) => React.ReactElement | null;
|
|
79
|
-
renderSectionHeader?: (info: {
|
|
80
|
-
section: SectionListData<ItemT, SectionT>;
|
|
81
|
-
}) => React.ReactElement | null;
|
|
82
|
-
renderSectionFooter?: (info: {
|
|
83
|
-
section: SectionListData<ItemT, SectionT>;
|
|
84
|
-
}) => React.ReactElement | null;
|
|
85
|
-
ItemSeparatorComponent?: React.ComponentType<SectionListSeparatorProps<ItemT, SectionT>> | null;
|
|
86
|
-
SectionSeparatorComponent?: React.ComponentType<SectionListSeparatorProps<ItemT, SectionT>> | React.ReactElement | null;
|
|
87
|
-
keyExtractor?: (item: ItemT, index: number) => string;
|
|
88
|
-
stickySectionHeadersEnabled?: boolean;
|
|
89
|
-
onViewableItemsChanged?: SectionListOnViewableItemsChanged<ItemT, SectionT>;
|
|
90
|
-
};
|
|
91
|
-
type SectionListRef = LegendListRef & {
|
|
92
|
-
scrollToLocation(params: SectionListScrollParams): void;
|
|
93
|
-
};
|
|
94
|
-
declare const SectionList: (<ItemT, SectionT extends SectionBase<ItemT, react_native.DefaultSectionT>>(props: SectionListLegendProps<ItemT, SectionT> & {
|
|
95
|
-
sections: readonly SectionListData<ItemT, SectionT>[];
|
|
96
|
-
extraData?: any;
|
|
97
|
-
renderItem?: ((info: SectionListRenderItemInfo<ItemT, SectionT>) => React.ReactElement | null) | undefined;
|
|
98
|
-
renderSectionHeader?: ((info: {
|
|
99
|
-
section: SectionListData<ItemT, SectionT>;
|
|
100
|
-
}) => React.ReactElement | null) | undefined;
|
|
101
|
-
renderSectionFooter?: ((info: {
|
|
102
|
-
section: SectionListData<ItemT, SectionT>;
|
|
103
|
-
}) => React.ReactElement | null) | undefined;
|
|
104
|
-
ItemSeparatorComponent?: React.ComponentType<SectionListSeparatorProps<ItemT, SectionT>> | null | undefined;
|
|
105
|
-
SectionSeparatorComponent?: React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ComponentType<SectionListSeparatorProps<ItemT, SectionT>> | null | undefined;
|
|
106
|
-
keyExtractor?: ((item: ItemT, index: number) => string) | undefined;
|
|
107
|
-
stickySectionHeadersEnabled?: boolean;
|
|
108
|
-
onViewableItemsChanged?: SectionListOnViewableItemsChanged<ItemT, SectionT> | undefined;
|
|
109
|
-
} & React.RefAttributes<SectionListRef>) => React.ReactNode) & {
|
|
110
|
-
displayName?: string;
|
|
111
|
-
};
|
|
112
|
-
|
|
113
|
-
export { type BuildSectionListDataResult, type FlatSectionListItem, SectionList, type SectionListOnViewableItemsChanged, type SectionListProps, type SectionListRef, type SectionListSeparatorProps, type SectionListViewToken, type SectionMeta };
|