/// <reference types="react" />
import { AlertProps } from 'antd/lib/alert';
import EventEmitter from '../compose-form/events';
import { FormProps, FormItemProps, FormInstance } from 'antd/lib/form';
import { Request } from '../interface';
export interface CFFormItemInternalProps extends Omit<FormItemProps, 'children'> {
    label?: string;
    name: string;
    uiType: string;
    index: number;
    form: FormInstance;
    emitter: EventEmitter;
    externalComsMap?: any;
    source?: any;
    props?: any;
    info?: React.ReactNode;
    errors?: React.ReactNode;
    rules?: FormItemProps['rules'];
    tooltip?: string;
    value?: any;
    visibleOn?: (data?: any) => boolean;
    newSourceParams?: (prevParams?: any, data?: any) => any;
    _emit?: any;
}
export declare type CFFormItemProps = Omit<CFFormItemInternalProps, 'index' | 'externalComsMap' | 'form' | 'emitter'>;
export interface CFFormProps extends FormProps {
    alertProps?: AlertProps & {
        request?: Request;
    };
    initialValuesRequest?: any;
    request?: any;
    formatParams?: (formValue: any) => any;
    beforeSubmit?: (formValue: any) => Promise<boolean>;
    dataFormatBeforeSubmit?: (formValue: any) => Promise<any>;
    dataFormatAfterInit?: (formValue: any) => Promise<any>;
    controls: CFFormItemProps[];
    actions?: CFFormActionProps[];
    comsMap?: any;
    disableSubmitWhenUnChanged?: boolean;
    className?: string;
    title?: string;
    onSubmit?: (value?: any, e?: EventTarget) => void;
    onFinish?: (value?: any, e?: EventTarget) => void;
    renderItemList?(controlItems: React.ReactNodeArray, actionFormItem: React.ReactNode): React.ReactNode;
    showActionInPageFooter?: boolean;
    toastGlobalError?: boolean;
    initialValues?: any;
    value?: any;
    columns?: number;
    noContainer?: boolean;
}
export interface CFFormCustomComProps {
    value: any;
    onChange: (value: any) => void;
}
export interface CFFormActionProps {
    uiType: 'submit' | 'reset' | 'cancel' | 'confirmSubmit' | 'button';
    props: any;
}
interface FormValue {
    [formItemKey: string]: any;
}
export interface CFFormComProps {
    onChange(value: any): void;
    setFormValue(formValue: FormValue): void;
}
export {};
