///
import { VTable } from './index';
import { SearchFieldComp } from './searchfield';
import { CountComp } from './count';
export declare type CustomComponents = {
IconSortAsc?: () => JSX.Element;
IconSortDesc?: () => JSX.Element;
SearchField?: SearchFieldComp;
Counter?: CountComp;
};
export declare type Item = T & {
visible?: boolean;
checked?: boolean;
};
export declare type Column = {
title?: any;
name: string;
render: Render;
fn?: any;
width?: any;
className?: any;
isActionsCol?: boolean;
onClick?: any;
style?: any;
};
export declare const sortTypes: {
asc: {
key: string;
title: string;
icon: string;
};
desc: {
key: string;
title: string;
icon: string;
};
};
export declare type Sort = {
[key: string]: string;
};
export declare type Render = (value: any, item: Item, x?: any) => any;
export declare type Counter = {
visible: number;
checked: number;
};
export declare const initCounter: () => {
visible: number;
checked: number;
};
export declare const getColumnStyle: (c: Column) => any;
export declare const givenItems: (items: Item[]) => {
filter: (filter: any, matcher: any, counter: any) => void;
visibles: () => Item[];
sort: (sorting: Sort, columns: Column[]) => any;
toggleCheck: (val: any) => any[];
toggleCheckItem: (_i: Item) => any;
filterChecked: () => any;
clean: () => any;
result: Item[];
};
export declare const givenItem: (i: Item) => {
visible: () => boolean;
checked: () => boolean;
clean: () => Item;
toggleCheck: (val?: any) => any;
equal: (_i: Item) => boolean;
};
export declare const givenColumns: (_columns?: Column[] | undefined) => {
add: (cols: Column[]) => any;
addColumnFor: (key: any, sortable?: any) => any;
addSortableColumnFor: (key: any) => any;
getDefaultSorting: () => {};
sortables: (sorting?: Sort | undefined) => Column[];
result: Column[];
};
export declare const buildColumn: (key?: any, sortable?: any) => Column;
export declare const givenColumn: (_c: Column) => {
withName: (name: string) => void;
withRender: (render: any) => void;
withSortFn: (fn: any) => void;
isSortable: (sorting?: Sort | undefined) => string | true | undefined;
sort: (sorting: Sort) => void;
getSort: (sorting?: Sort | undefined) => string | undefined;
name: () => string;
getStyle: () => any;
result: Column;
};
export declare const table: (t: VTable) => {
getHeadScrollElement: () => any;
getScrollElement: () => any;
getHeight: () => number;
getRowHeight: () => number;
getDefaultSorting: () => Sort;
getSortedItems: (sorting?: any) => Item[];
setContainer: (c: any) => false | void;
shouldRenderHead: () => boolean;
shouldRenderHeadOutiseOfContainer: () => any;
shouldRenderHeadInsideOfContainer: () => boolean;
};
export declare const Given: {
items: (items: Item[]) => {
filter: (filter: any, matcher: any, counter: any) => void;
visibles: () => Item[];
sort: (sorting: Sort, columns: Column[]) => any;
toggleCheck: (val: any) => any[];
toggleCheckItem: (_i: Item) => any;
filterChecked: () => any;
clean: () => any;
result: Item[];
};
item: (i: Item) => {
visible: () => boolean;
checked: () => boolean;
clean: () => Item;
toggleCheck: (val?: any) => any;
equal: (_i: Item) => boolean;
};
column: (_c: Column) => {
withName: (name: string) => void;
withRender: (render: any) => void;
withSortFn: (fn: any) => void;
isSortable: (sorting?: Sort | undefined) => string | true | undefined;
sort: (sorting: Sort) => void;
getSort: (sorting?: Sort | undefined) => string | undefined;
name: () => string;
getStyle: () => any;
result: Column;
};
columns: (_columns?: Column[] | undefined) => {
add: (cols: Column[]) => any;
addColumnFor: (key: any, sortable?: any) => any;
addSortableColumnFor: (key: any) => any;
getDefaultSorting: () => {};
sortables: (sorting?: Sort | undefined) => Column[];
result: Column[];
};
};
declare const CP: {
list: {
row_height: number;
ref: string;
height: number;
width: number;
};
classNames: {
wrapper: string;
main: string;
container: string;
head: string;
headColumn: string;
sortable: (sortable: any) => "" | "sortable";
isActionCol: (isActionCol: any) => "" | "action-col";
rowIndex: (index: number) => string;
row: string;
rowColumn: string;
fixed: string;
checkboxWrapper: string;
checkbox: string;
checkboxChecked: string;
checkboxUnchecked: string;
checkboxDisabled: string;
icon: string;
searchField: string;
};
defaultContainerStyle: (height?: number | undefined) => {
height: string | number;
};
};
export default CP;