@uiw/react-native
Version:
UIW for React Native
22 lines (21 loc) • 702 B
TypeScript
/// <reference types="react" />
import { EntityNode, EventDataNode, FlattenNode, TreeProps } from '../type';
export declare function useTree(props: TreeProps): {
flattenNodes: FlattenNode[];
handleNodeExpand: (treeNode: EventDataNode) => void;
handlerCheck: (treeNode: EventDataNode) => void;
containerStyle: {
height: number;
flex?: undefined;
} | {
flex: number;
height?: undefined;
};
expandedKeys: string[];
checkedKeys: string[];
keyEntities: Record<string, EntityNode> | undefined;
icon: ((checked: boolean) => import("react").ReactNode) | undefined;
checkable: boolean;
disabled: boolean;
showIcon: boolean;
};