import React, { ReactNode, CSSProperties } from 'react'; import { Key } from './utils/itemUtil'; export declare type RenderFunc = (item: T, index: number, props: { style: React.CSSProperties; }) => ReactNode; export interface VirtualListProps extends Omit, 'children'> { children: RenderFunc; data: T[]; height?: number | string; itemHeight?: number; wrapper?: string | React.FC | React.ComponentClass; threshold?: number | null; isStaticItemHeight?: boolean; itemKey?: Key | ((item: T, index: number) => Key); measureLongestItem?: boolean; scrollOptions?: ScrollIntoViewOptions; needFiller?: boolean; /** Custom filler outer style */ outerStyle?: CSSProperties; onScroll?: React.UIEventHandler; } export declare type AvailableVirtualListProps = Pick, 'height' | 'itemHeight' | 'threshold' | 'isStaticItemHeight' | 'scrollOptions'>; export declare type VirtualListHandle = { dom: HTMLElement; scrollTo: (arg: number | { index: number; options?: ScrollIntoViewOptions; } | { key: Key; options?: ScrollIntoViewOptions; }) => void; }; declare const VirtualList: React.ForwardRefExoticComponent & React.RefAttributes>; export default VirtualList;