import * as React from 'react'; import { TransferDirection, RenderResult, SelectAllLabel, TransferLocale, KeyWiseTransferItem } from './index'; import DefaultListBody, { TransferListBodyProps } from './ListBody'; import { PaginationType } from './interface'; export interface RenderedItem { renderedText: string; renderedEl: React.ReactNode; item: RecordType; } declare type RenderListFunction = (props: TransferListBodyProps) => React.ReactNode; export interface TransferListProps extends TransferLocale { prefixCls: string; titleText: React.ReactNode; dataSource: RecordType[]; filterOption?: (filterText: string, item: RecordType) => boolean; style?: React.CSSProperties; checkedKeys: string[]; handleFilter: (e: React.ChangeEvent) => void; onItemSelect: (key: string, check: boolean) => void; onItemSelectAll: (dataSource: string[], checkAll: boolean) => void; onItemRemove?: (keys: string[]) => void; handleClear: () => void; /** Render item */ render?: (item: RecordType) => RenderResult; showSearch?: boolean; searchPlaceholder: string; itemUnit: string; itemsUnit: string; renderList?: RenderListFunction; footer?: (props: TransferListProps, info?: { direction: TransferDirection; }) => React.ReactNode; onScroll: (e: React.UIEvent) => void; disabled?: boolean; direction: TransferDirection; showSelectAll?: boolean; selectAllLabel?: SelectAllLabel; showRemove?: boolean; pagination?: PaginationType; } interface TransferListState { /** Filter input value */ filterValue: string; } export default class TransferList extends React.PureComponent, TransferListState> { static defaultProps: { dataSource: never[]; titleText: string; showSearch: boolean; }; timer: number; triggerScrollTimer: number; defaultListBodyRef: React.RefObject>; constructor(props: TransferListProps); componentWillUnmount(): void; getCheckStatus(filteredItems: RecordType[]): "none" | "all" | "part"; getFilteredItems(dataSource: RecordType[], filterValue: string): { filteredItems: RecordType[]; filteredRenderItems: RenderedItem[]; }; handleFilter: (e: React.ChangeEvent) => void; handleClear: () => void; matchFilter: (text: string, item: RecordType) => boolean; renderListBody: (renderList: RenderListFunction | undefined, props: TransferListBodyProps) => { customize: boolean; bodyContent: React.ReactNode; }; getListBody(prefixCls: string, searchPlaceholder: string, filterValue: string, filteredItems: RecordType[], notFoundContent: React.ReactNode | React.ReactNode, filteredRenderItems: RenderedItem[], checkedKeys: string[], renderList?: RenderListFunction, showSearch?: boolean, disabled?: boolean): React.ReactNode; getCheckBox({ filteredItems, onItemSelectAll, disabled, prefixCls, }: { filteredItems: RecordType[]; onItemSelectAll: (dataSource: string[], checkAll: boolean) => void; disabled?: boolean; prefixCls?: string; }): false | JSX.Element; renderItem: (item: RecordType) => RenderedItem; getSelectAllLabel: (selectedCount: number, totalCount: number) => React.ReactNode; render(): JSX.Element; } export {};