@redocly/theme
Version:
Shared UI components lib
16 lines (15 loc) • 774 B
TypeScript
import { BaseEntity, CatalogColumn } from '../../../components/Catalog/CatalogTableView/CatalogTableView';
import { SortOption } from '../../types';
type CatalogTableHeaderCellActionsProps<T extends BaseEntity> = {
column: CatalogColumn<T>;
handleSortClick: (sortKey: string, direction: 'asc' | 'desc') => void;
setSortOption: (sortOption: SortOption | null) => void;
isColumnSorted: (sortKey: string, direction: 'asc' | 'desc') => boolean;
};
export declare function useCatalogTableHeaderCellActions<T extends BaseEntity>({ column, handleSortClick, setSortOption, isColumnSorted, }: CatalogTableHeaderCellActionsProps<T>): {
handleCellClick: () => void;
sortKey: string | undefined;
isUpActive: boolean;
isDownActive: boolean;
};
export {};