import React from 'react'; import { IndeterminateCheckboxStatus, TreeViewProps } from '../..'; import { TreeViewSelectable } from '.'; declare const _default: any; export default _default; export declare const Simple: { render: (args: Partial) => React.JSX.Element; parameters: { controls: { exclude: string[]; }; }; }; export declare const Complex: { render: (args: Partial) => React.JSX.Element; args: { selectable: TreeViewSelectable; ariaLabel: string; initialExpandedItems: string[]; preselectedItems: ({ itemId: string; checkedStatus: IndeterminateCheckboxStatus; isDisabled?: undefined; } | { itemId: string; checkedStatus: IndeterminateCheckboxStatus; isDisabled: boolean; })[]; checkParents: boolean; checkChildren: boolean; isDisabled: boolean; testId: string; }; }; export declare const NoIcons: { render: (args: Partial) => React.JSX.Element; args: { initialExpandedItems: string[]; preselectedItems: { itemId: string; checkedStatus: IndeterminateCheckboxStatus; }[]; }; }; export declare const Textbook: { render: (args: Partial) => React.JSX.Element; args: { ariaLabelledBy: string; }; }; export declare const DefaultIcon: { render: (args: Partial) => React.JSX.Element; parameters: { controls: { exclude: string[]; }; }; }; export declare const FirstItemLeaf: { render: (args: Partial) => React.JSX.Element; args: { initialExpandedItems: string[]; preselectedItems: { itemId: string; checkedStatus: IndeterminateCheckboxStatus; }[]; }; parameters: { controls: { exclude: string[]; }; }; }; export declare const FirstItemBranch: { render: (args: Partial) => React.JSX.Element; args: { ariaLabel: string; selectable: TreeViewSelectable; preselectedItems: { itemId: string; checkedStatus: IndeterminateCheckboxStatus; }[]; initialExpandedItems: string[]; }; }; export declare const FlatTree: { render: (args: Partial) => React.JSX.Element; args: { selectable: TreeViewSelectable; }; parameters: { controls: { exclude: string[]; }; }; }; export declare const ParentsAndChildrenNotAutoChecked: { render: (args: Partial) => React.JSX.Element; args: { checkParents: boolean; checkChildren: boolean; ariaLabel: string; selectable: TreeViewSelectable; testId: string; }; parameters: { controls: { exclude: string[]; }; }; }; export declare const InvalidTreeItems: { render: (args: Partial) => React.JSX.Element; parameters: { controls: { exclude: string[]; }; }; }; export declare const AccordionSectionWithTreeView: (props: any) => React.JSX.Element; export declare const AccordionTreeWithShowAllAndExpandAll: { render: (props: any) => React.JSX.Element; parameters: { controls: { exclude: string[]; }; }; }; export declare const ComplexTreeWithShowAllAndExpandAll: { render: (args: Partial) => React.JSX.Element; args: { checkParents: boolean; checkChildren: boolean; selectable: TreeViewSelectable; ariaLabel: string; }; parameters: { controls: { exclude: string[]; }; }; }; export declare const ComplexTreeWithLargeDataSet: { render: (args: Partial) => React.JSX.Element; args: { checkParents: boolean; checkChildren: boolean; selectable: TreeViewSelectable; ariaLabel: string; }; parameters: { controls: { exclude: string[]; }; }; }; export declare const ComplexWithTopLevelNotSelectable: { render: (args: Partial) => React.JSX.Element; args: { selectable: TreeViewSelectable; isTopLevelSelectable: boolean; ariaLabel: string; initialExpandedItems: string[]; preselectedItems: ({ itemId: string; checkedStatus: IndeterminateCheckboxStatus; isDisabled?: undefined; } | { itemId: string; checkedStatus: IndeterminateCheckboxStatus; isDisabled: boolean; })[]; checkParents: boolean; checkChildren: boolean; isDisabled: boolean; testId: string; }; }; export declare const DynamicTreeItems: { render: (args: Partial) => React.JSX.Element; parameters: { controls: { exclude: string[]; }; }; }; export declare const ComplexWithAdditionalContent: { render: (args: Partial) => React.JSX.Element; args: { ariaLabel: string; initialExpandedItems: string[]; checkParents: boolean; checkChildren: boolean; isDisabled: boolean; testId: string; }; }; export declare function TreeViewWithDifferentElements(args: Partial): React.JSX.Element; export declare function CustomExpandIconArrowAndTreeItemStyles(): React.JSX.Element; export declare const VirtualizedLargeTree: { render: (args: Partial) => React.JSX.Element; args: { ariaLabel: string; selectable: TreeViewSelectable; initialExpandedItems: any[]; checkParents: boolean; checkChildren: boolean; isDisabled: boolean; testId: string; enableVirtualization: boolean; }; }; export declare const ResizableVirtualizedTree: { render: ({ lessonsPerChapter, ...args }: TreeViewProps & { lessonsPerChapter: number; }) => React.JSX.Element; args: { ariaLabel: string; enableVirtualization: boolean; initialExpandedItems: string[]; testId: string; lessonsPerChapter: number; }; argTypes: { lessonsPerChapter: { control: { type: string; min: number; max: number; }; }; }; }; export declare const SelectChildrenOnly: { render: (args: TreeViewProps) => React.JSX.Element; args: { selectable: TreeViewSelectable; selectParents: boolean; }; }; /** * Performance reproduction story. * * Generates a large multi-select tree (default LEVELS=4, CHILDREN=15 → ~54,240 nodes) * to reproduce the lag that happens when a parent checkbox is clicked * with selectable=multi, checkChildren=true, checkParents=true. * * Two amplifiers are intentionally enabled: * - large total node count (N) — makes processChildrenSelection's per-call * `new Map(items.map(...))` rebuild expensive (O(K·N) per click). * - top-level nodes are pre-expanded — so the re-render storm hits * every mounted TreeItem (each does `items.find()` → O(N²) per render). * * Repro steps: * 1. Open the story. * 2. Click the checkbox of any top-level parent — the UI will freeze. * * Reduce LEVELS / CHILDREN args if your machine cannot handle the default. */ export declare const LargeTreePerformanceIssue: { render: (args: Partial & { levels: number; childrenCount: number; preExpandTopLevel: boolean; }) => React.JSX.Element; argTypes: { levels: { control: { type: string; min: number; max: number; step: number; }; description: string; }; childrenCount: { control: { type: string; min: number; max: number; step: number; }; description: string; }; preExpandTopLevel: { control: string; description: string; }; }; args: { selectable: TreeViewSelectable; checkParents: boolean; checkChildren: boolean; isTopLevelSelectable: boolean; selectParents: boolean; enableVirtualization: boolean; preExpandTopLevel: boolean; levels: number; childrenCount: number; }; };