@mantine/core
Version:
React components library focused on usability, accessibility and developer experience
37 lines (36 loc) • 1.37 kB
TypeScript
import type { TreeNodeData } from '../Tree';
export interface TreeSelectChevronAriaLabels {
/** aria-label for the expand button when the node is collapsed @default 'Expand' */
expand?: string;
/** aria-label for the expand button when the node is expanded @default 'Collapse' */
collapse?: string;
}
export interface TreeSelectOptionProps {
node: TreeNodeData;
level: number;
expanded: boolean;
hasChildren: boolean;
selected: boolean;
checked: boolean;
indeterminate: boolean;
showCheckbox: boolean;
isLastChild: boolean;
lineGuides: boolean[];
withLines: boolean;
onToggleExpand: (value: string) => void;
renderNode?: (payload: TreeSelectRenderNodePayload) => React.ReactNode;
chevronAriaLabels?: TreeSelectChevronAriaLabels;
}
export interface TreeSelectRenderNodePayload {
node: TreeNodeData;
level: number;
expanded: boolean;
hasChildren: boolean;
selected: boolean;
checked: boolean;
indeterminate: boolean;
}
export declare function TreeSelectOption({ node, level, expanded, hasChildren, selected, checked, indeterminate, showCheckbox, isLastChild, lineGuides, withLines, onToggleExpand, renderNode, chevronAriaLabels, }: TreeSelectOptionProps): import("react/jsx-runtime").JSX.Element;
export declare namespace TreeSelectOption {
var displayName: string;
}