react-virtuoso 2.6.0 → 2.8.0-alpha.2
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/dist/AATree.d.ts +40 -40
- package/dist/Grid.d.ts +482 -440
- package/dist/List.d.ts +6041 -5860
- package/dist/Table.d.ts +5875 -5729
- package/dist/TableVirtuoso.js +2 -0
- package/dist/TableVirtuoso.js.map +1 -0
- package/dist/TableVirtuoso.mjs +2 -0
- package/dist/TableVirtuoso.mjs.map +1 -0
- package/dist/VirtuosoGrid.js +2 -0
- package/dist/VirtuosoGrid.js.map +1 -0
- package/dist/VirtuosoGrid.mjs +2 -0
- package/dist/VirtuosoGrid.mjs.map +1 -0
- package/dist/alignToBottomSystem.d.ts +529 -529
- package/dist/comparators.d.ts +3 -3
- package/dist/components/CompProps.d.ts +2 -0
- package/dist/components/GroupedVirtuoso.d.ts +27 -0
- package/dist/components/TableVirtuoso.d.ts +5717 -0
- package/dist/components/Virtuoso.d.ts +205 -0
- package/dist/components/VirtuosoGrid.d.ts +93 -0
- package/dist/components/index.d.ts +4 -0
- package/dist/components.d.ts +1026 -73
- package/dist/domIOSystem.d.ts +15 -15
- package/dist/followOutputSystem.d.ts +362 -362
- package/dist/gridSystem.d.ts +281 -281
- package/dist/groupedListSystem.d.ts +71 -71
- package/dist/hooks/__mocks__/useChangedChildSizes.d.ts +4 -4
- package/dist/hooks/__mocks__/useScrollTop.d.ts +7 -7
- package/dist/hooks/__mocks__/useSize.d.ts +3 -3
- package/dist/hooks/useChangedChildSizes.d.ts +3 -3
- package/dist/hooks/useIsomorphicLayoutEffect.d.ts +3 -3
- package/dist/hooks/useScrollTop.d.ts +6 -6
- package/dist/hooks/useSize.d.ts +6 -6
- package/dist/hooks/useWindowViewportRect.d.ts +2 -2
- package/dist/index-27.js +2 -0
- package/dist/index.d.ts +3 -3
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.m.js +1 -1
- package/dist/index.m.js.map +1 -1
- package/dist/index.mjs +2 -0
- package/dist/index.mjs.map +1 -0
- package/dist/initialItemCountSystem.d.ts +518 -518
- package/dist/initialScrollTopSystem.d.ts +540 -540
- package/dist/initialTopMostItemIndexSystem.d.ts +153 -153
- package/dist/interfaces.d.ts +279 -239
- package/dist/listStateSystem.d.ts +469 -469
- package/dist/listSystem.d.ts +5214 -5214
- package/dist/loggerSystem.d.ts +17 -17
- package/dist/propsReadySystem.d.ts +12 -12
- package/dist/scrollIntoViewSystem.d.ts +617 -617
- package/dist/scrollSeekSystem.d.ts +57 -57
- package/dist/scrollToIndexSystem.d.ts +77 -77
- package/dist/shared.js +2 -0
- package/dist/shared.js.map +1 -0
- package/dist/shared.mjs +2 -0
- package/dist/shared.mjs.map +1 -0
- package/dist/sizeRangeSystem.d.ts +50 -50
- package/dist/sizeSystem.d.ts +66 -66
- package/dist/stateFlagsSystem.d.ts +65 -65
- package/dist/topItemCountSystem.d.ts +469 -469
- package/dist/totalListHeightSystem.d.ts +497 -497
- package/dist/upwardScrollFixSystem.d.ts +590 -590
- package/dist/utils/binaryArraySearch.d.ts +6 -6
- package/dist/utils/correctItemSize.d.ts +1 -1
- package/dist/utils/positionStickyCssValue.d.ts +1 -1
- package/dist/utils/simpleMemoize.d.ts +1 -1
- package/dist/windowScrollerSystem.d.ts +35 -35
- package/package.json +15 -5
package/dist/comparators.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { ListRange } from './interfaces';
|
|
2
|
-
export declare function tupleComparator(prev: [any, any] | undefined, current: [any, any]): boolean;
|
|
3
|
-
export declare function rangeComparator(prev: ListRange | undefined, next: ListRange): boolean;
|
|
1
|
+
import { ListRange } from './interfaces';
|
|
2
|
+
export declare function tupleComparator(prev: [any, any] | undefined, current: [any, any]): boolean;
|
|
3
|
+
export declare function rangeComparator(prev: ListRange | undefined, next: ListRange): boolean;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { ReactElement, Ref } from 'react';
|
|
2
|
+
import { GroupContent, GroupItemContent, IndexLocationWithAlign } from '../interfaces';
|
|
3
|
+
import { ListHandle } from '../List';
|
|
4
|
+
import { ListProps, VirtuosoProps } from './Virtuoso';
|
|
5
|
+
export interface GroupedVirtuosoProps<D, C> extends Omit<VirtuosoProps<D, C>, 'totalCount' | 'itemContent'>, Pick<ListProps, 'groupCounts' | 'groupContent'> {
|
|
6
|
+
/**
|
|
7
|
+
* Specifies the amount of items in each group (and, actually, how many groups are there).
|
|
8
|
+
* For example, passing [20, 30] will display 2 groups with 20 and 30 items each.
|
|
9
|
+
*/
|
|
10
|
+
groupCounts?: number[];
|
|
11
|
+
/**
|
|
12
|
+
* Specifies how each each group header gets rendered. The callback receives the zero-based index of the group.
|
|
13
|
+
*/
|
|
14
|
+
groupContent?: GroupContent;
|
|
15
|
+
/**
|
|
16
|
+
* Specifies how each each item gets rendered.
|
|
17
|
+
*/
|
|
18
|
+
itemContent?: GroupItemContent<D, C>;
|
|
19
|
+
}
|
|
20
|
+
export interface GroupedVirtuosoHandle extends ListHandle {
|
|
21
|
+
scrollToIndex(location: number | IndexLocationWithAlign): void;
|
|
22
|
+
scrollTo(location: ScrollToOptions): void;
|
|
23
|
+
scrollBy(location: ScrollToOptions): void;
|
|
24
|
+
}
|
|
25
|
+
export declare const GroupedVirtuoso: <ItemData extends unknown = any, Context extends unknown = any>(props: GroupedVirtuosoProps<ItemData, Context> & {
|
|
26
|
+
ref?: Ref<GroupedVirtuosoHandle> | undefined;
|
|
27
|
+
}) => ReactElement;
|