import { type MaybeRefOrGetter, type Ref } from 'vue';
import { type CheckedNodeStatus } from './get-all-checked-nodes/get-all-checked-nodes';
import type { TreeNodeData } from './Tree';
export type TreeExpandedState = Record<string, boolean>;
export declare function getTreeExpandedState(data: TreeNodeData[], values: string[] | '*'): TreeExpandedState;
export interface UseTreeInput {
    initialExpandedState?: TreeExpandedState;
    expandedState?: MaybeRefOrGetter<TreeExpandedState | undefined>;
    onExpandedStateChange?: (state: TreeExpandedState) => void;
    initialSelectedState?: string[];
    selectedState?: MaybeRefOrGetter<string[] | undefined>;
    onSelectedStateChange?: (state: string[]) => void;
    initialCheckedState?: string[];
    checkedState?: MaybeRefOrGetter<string[] | undefined>;
    onCheckedStateChange?: (state: string[]) => void;
    multiple?: boolean;
    onNodeExpand?: (value: string) => void;
    onNodeCollapse?: (value: string) => void;
    onLoadChildren?: (nodeValue: string) => Promise<void>;
    checkStrictly?: boolean;
}
export interface UseTreeReturnType {
    checkStrictly: boolean;
    multiple: boolean;
    expandedState: Readonly<Ref<TreeExpandedState>>;
    selectedState: Readonly<Ref<string[]>>;
    checkedState: Readonly<Ref<string[]>>;
    anchorNode: Ref<string | null>;
    initialize(data: TreeNodeData[]): void;
    toggleExpanded(value: string): void;
    collapse(value: string): void;
    expand(value: string): void;
    expandAllNodes(): void;
    collapseAllNodes(): void;
    setExpandedState(value: TreeExpandedState): void;
    toggleSelected(value: string): string[];
    select(value: string): void;
    deselect(value: string): void;
    clearSelected(): void;
    setSelectedState(value: string[]): void;
    checkNode(value: string): void;
    uncheckNode(value: string): void;
    checkAllNodes(): void;
    uncheckAllNodes(): void;
    setCheckedState(value: string[]): void;
    getCheckedNodes(): CheckedNodeStatus[];
    isNodeChecked(value: string): boolean;
    isNodeIndeterminate(value: string): boolean;
    isNodeLoading(value: string): boolean;
    getNodeLoadError(value: string): Error | null;
    loadNode(value: string): Promise<void>;
    invalidateNode(value: string): void;
}
export declare function useTree(input?: UseTreeInput): UseTreeReturnType;
export type TreeController = ReturnType<typeof useTree>;
