import { BaseEntityService, EntityState } from '@savantly/sprout-api';
import { AxiosResponse } from 'axios';
import { Component, ReactElement } from 'react';
import { ColumnDescription } from 'react-bootstrap-table-next';
export interface EntityEditorProps<T> {
    entity: T;
    save: (entity: T) => Promise<AxiosResponse<T> | AxiosResponse<any>>;
    cancel: () => void;
}
export interface EntityPageProps<T> {
    title?: string;
    subTitle?: string;
    entityState: EntityState<T>;
    entityEditor: (props: EntityEditorProps<T>) => ReactElement;
    entityService: BaseEntityService<T>;
    entityKeyField: string;
    columndescriptions: ColumnDescription[];
    onDeleteError: (error: AxiosResponse<any>) => void;
    afterDelete: () => void;
}
export interface EntityPageState<T> {
    modalState: T | false;
    modalError: string;
    error: string;
}
export declare class EntityPage<T> extends Component<EntityPageProps<T>, EntityPageState<T>> {
    constructor(props: EntityPageProps<T>);
    save(values: T): Promise<AxiosResponse<T>>;
    deleteOne(values: T): void;
    render(): JSX.Element;
}
//# sourceMappingURL=EntityPage.d.ts.map