/**
 * @file Tree
 * @description 树形组件
 * @author fex
 */
import React from 'react';
import { Option, Options } from './Checkboxes';
import { ClassNamesFn } from '../theme';
interface TreeSelectorProps {
    classPrefix: string;
    classnames: ClassNamesFn;
    highlightTxt?: string;
    showIcon?: boolean;
    initiallyOpen?: boolean;
    unfoldedLevel?: number;
    showRadio?: boolean;
    multiple?: boolean;
    disabled?: boolean;
    withChildren?: boolean;
    onlyChildren?: boolean;
    nameField?: string;
    valueField?: string;
    iconField?: string;
    unfoldedField?: string;
    foldedField?: string;
    disabledField?: string;
    className?: string;
    itemClassName?: string;
    joinValues?: boolean;
    extractValue?: boolean;
    delimiter?: string;
    data: Options;
    value: any;
    onChange: Function;
    placeholder?: string;
    hideRoot?: boolean;
    rootLabel?: string;
    rootValue?: any;
    cascade?: boolean;
    selfDisabledAffectChildren?: boolean;
    minLength?: number;
    maxLength?: number;
    addMode?: 'dialog' | 'normal';
    addable?: boolean;
    onAdd?: Function;
    openAddDialog?: Function;
    editMode?: 'dialog' | 'normal';
    onEdit?: Function;
    editable?: boolean;
    openEditDialog?: Function;
    removable?: boolean;
    onRemove?: Function;
}
interface TreeSelectorState {
    value: Array<any>;
    unfolded: {
        [propName: string]: string;
    };
    editItem: Option | null;
    addItem: Option | null;
    addingItem: Option | null;
    editingItem: Option | null;
    addTop: boolean;
}
export declare class TreeSelector extends React.Component<TreeSelectorProps, TreeSelectorState> {
    static defaultProps: {
        showIcon: boolean;
        initiallyOpen: boolean;
        unfoldedLevel: number;
        showRadio: boolean;
        multiple: boolean;
        disabled: boolean;
        withChildren: boolean;
        onlyChildren: boolean;
        nameField: string;
        valueField: string;
        iconField: string;
        unfoldedField: string;
        foldedField: string;
        disabledField: string;
        joinValues: boolean;
        extractValue: boolean;
        delimiter: string;
        hideRoot: boolean;
        rootLabel: string;
        rootValue: number;
        cascade: boolean;
        selfDisabledAffectChildren: boolean;
    };
    componentWillMount(): void;
    componentWillReceiveProps(nextProps: TreeSelectorProps): void;
    syncUnFolded(props: TreeSelectorProps): {
        [propName: string]: string;
    };
    toggleUnfolded(node: any): void;
    clearSelect(): void;
    handleSelect(node: any, value?: any): void;
    handleCheck(item: any, checked: boolean): void;
    handleAdd(item: Option | null, isFolder: boolean): void;
    handleEdit(item: Option): void;
    handleRemove(item: Option): void;
    handleConfirmOnAdd(): void;
    handleCancelOnAdd(): void;
    handleConfirmOnEdit(): void;
    handleCancelOnEdit(): void;
    handleChangeOnAdd(value: string): void;
    handleChangeOnEdit(item: Option, value: string): void;
    renderList(list: Options, value: Option[], uncheckable: boolean): {
        dom: Array<JSX.Element | null>;
        childrenChecked: number;
    };
    render(): JSX.Element;
}
declare const _default: React.ComponentClass<Pick<Pick<TreeSelectorProps, "data" | "value" | "minLength" | "maxLength" | "className" | "classPrefix" | "classnames" | "onChange" | "addable" | "editable" | "placeholder" | "removable" | "itemClassName" | "highlightTxt" | "addMode" | "onAdd" | "openAddDialog" | "editMode" | "onEdit" | "openEditDialog" | "onRemove"> & Partial<Pick<TreeSelectorProps, "disabled" | "multiple" | "delimiter" | "valueField" | "joinValues" | "extractValue" | "hideRoot" | "showIcon" | "showRadio" | "initiallyOpen" | "unfoldedLevel" | "withChildren" | "onlyChildren" | "nameField" | "iconField" | "unfoldedField" | "foldedField" | "disabledField" | "rootLabel" | "rootValue" | "cascade" | "selfDisabledAffectChildren">> & Partial<Pick<{
    showIcon: boolean;
    initiallyOpen: boolean;
    unfoldedLevel: number;
    showRadio: boolean;
    multiple: boolean;
    disabled: boolean;
    withChildren: boolean;
    onlyChildren: boolean;
    nameField: string;
    valueField: string;
    iconField: string;
    unfoldedField: string;
    foldedField: string;
    disabledField: string;
    joinValues: boolean;
    extractValue: boolean;
    delimiter: string;
    hideRoot: boolean;
    rootLabel: string;
    rootValue: number;
    cascade: boolean;
    selfDisabledAffectChildren: boolean;
}, never>>, "disabled" | "data" | "multiple" | "value" | "delimiter" | "valueField" | "joinValues" | "extractValue" | "minLength" | "maxLength" | "className" | "onChange" | "addable" | "editable" | "hideRoot" | "placeholder" | "removable" | "showIcon" | "showRadio" | "itemClassName" | "highlightTxt" | "initiallyOpen" | "unfoldedLevel" | "withChildren" | "onlyChildren" | "nameField" | "iconField" | "unfoldedField" | "foldedField" | "disabledField" | "rootLabel" | "rootValue" | "cascade" | "selfDisabledAffectChildren" | "addMode" | "onAdd" | "openAddDialog" | "editMode" | "onEdit" | "openEditDialog" | "onRemove"> & {
    theme?: string | undefined;
    classPrefix?: string | undefined;
    classnames?: ClassNamesFn | undefined;
}, any> & {
    ComposedComponent: typeof TreeSelector;
};
export default _default;
