/// import type { ArrowDown } from '@fluentui/keyboard-keys'; import type { ArrowLeft } from '@fluentui/keyboard-keys'; import type { ArrowRight } from '@fluentui/keyboard-keys'; import type { ArrowUp } from '@fluentui/keyboard-keys'; import type { AvatarContextValue } from '@fluentui/react-avatar'; import type { AvatarSize } from '@fluentui/react-avatar'; import { ButtonContextValue } from '@fluentui/react-button'; import { Checkbox } from '@fluentui/react-checkbox'; import { CheckboxProps } from '@fluentui/react-checkbox'; import type { ComponentProps } from '@fluentui/react-utilities'; import type { ComponentState } from '@fluentui/react-utilities'; import { ContextSelector } from '@fluentui/react-context-selector'; import type { DistributiveOmit } from '@fluentui/react-utilities'; import type { End } from '@fluentui/keyboard-keys'; import type { Enter } from '@fluentui/keyboard-keys'; import type { EventData } from '@fluentui/react-utilities'; import type { EventHandler } from '@fluentui/react-utilities'; import type { ExtractSlotProps } from '@fluentui/react-utilities'; import { ForwardRefComponent } from '@fluentui/react-utilities'; import type { Home } from '@fluentui/keyboard-keys'; import type { PresenceMotionSlotProps } from '@fluentui/react-motion'; import { Radio } from '@fluentui/react-radio'; import { RadioProps } from '@fluentui/react-radio'; import * as React_2 from 'react'; import type { SelectionMode as SelectionMode_2 } from '@fluentui/react-utilities'; import type { Slot } from '@fluentui/react-utilities'; import type { SlotClassNames } from '@fluentui/react-utilities'; declare type FlattenedTreeItem = HeadlessFlatTreeItemProps & Props; /** * Converts a nested structure to a flat one which can be consumed by `useFlatTreeItems` * @example * ```tsx * const defaultItems = flattenTree_unstable([ * { * children: level 1, item 1, * subtree: [ * { * children: level 2, item 1, * }, * { * children: level 2, item 2, * }, * { * children: level 2, item 3, * }, * ], * }, * { * children: level 1, item 2, * subtree: [ * { * children: level 2, item 1, * subtree: [ * { * children: level 3, item 1, * subtree: [ * { * children: level 4, item 1, * }, * ], * }, * ], * }, * ], * }, * ]); * ``` */ export declare const flattenTree_unstable: (items: FlattenTreeItem[]) => FlattenedTreeItem[]; export declare type FlattenTreeItem = Omit & { value: TreeItemValue; subtree?: FlattenTreeItem[]; }; /** * The `FlatTree` component is a variation of the `Tree` component that deals with a flattened data structure. * * It should be used on cases where more complex interactions with a Tree is required. * On simple scenarios it is advised to simply use a nested structure instead. */ export declare const FlatTree: ForwardRefComponent; export declare const flatTreeClassNames: SlotClassNames>; declare type FlatTreeContextValues = { tree: TreeContextValue; }; /** * The `FlatTreeItem` component represents a single item in a flat tree. */ export declare const FlatTreeItem: ForwardRefComponent; /** * FlatTreeItem Props */ export declare type FlatTreeItemProps = TreeItemProps & { value: TreeItemValue; 'aria-level': number; 'aria-setsize': number; 'aria-posinset': number; }; export declare type FlatTreeProps = ComponentProps & { /** * A tree item can have various appearances: * - 'subtle' (default): The default tree item styles. * - 'subtle-alpha': Minimizes emphasis on hovered or focused states. * - 'transparent': Removes background color. * @default 'subtle' */ appearance?: 'subtle' | 'subtle-alpha' | 'transparent'; /** * Size of the tree item. * @default 'medium' */ size?: 'small' | 'medium'; /** * This refers to a list of ids of opened tree items. * Controls the state of the open tree items. * These property is ignored for subtrees. */ openItems?: Iterable; /** * Callback fired when the component changes value from open state. * These property is ignored for subtrees. * * @param event - a React's Synthetic event * @param data - A data object with relevant information, * such as open value and type of interaction that created the event. */ onOpenChange?(event: TreeOpenChangeEvent, data: TreeOpenChangeData): void; /** * Callback fired when navigation happens inside the component. * These property is ignored for subtrees. * * FIXME: This method is not ideal, as navigation should be handled internally by tabster. * * @param event - a React's Synthetic event * @param data - A data object with relevant information, */ onNavigation?(event: TreeNavigationEvent_unstable, data: TreeNavigationData_unstable): void; /** * This refers to the selection mode of the tree. * - undefined: No selection can be done. * - 'single': Only one tree item can be selected, radio buttons are rendered. * - 'multiselect': Multiple tree items can be selected, checkboxes are rendered. * * @default undefined */ selectionMode?: SelectionMode_2; /** * This refers to a list of ids of checked tree items, or a list of tuples of ids and checked state. * Controls the state of the checked tree items. * These property is ignored for subtrees. */ checkedItems?: Iterable; /** * Callback fired when the component changes value from checked state. * These property is ignored for subtrees. * * @param event - a React's Synthetic event * @param data - A data object with relevant information, * such as checked value and type of interaction that created the event. */ onCheckedChange?(event: TreeCheckedChangeEvent, data: TreeCheckedChangeData): void; }; export declare type FlatTreeSlots = TreeSlots; export declare type FlatTreeState = ComponentState & TreeContextValue & { open: boolean; }; /** * FlatTree API to manage all required mechanisms to convert a list of items into renderable TreeItems * in multiple scenarios including virtualization. * * !!A flat tree is an unofficial spec for tree!! * * It should be used on cases where more complex interactions with a Tree is required. * * On simple scenarios it is advised to simply use a nested structure instead. */ export declare type HeadlessFlatTree = { /** * returns the properties required for the Tree component to work properly. * That includes: * `openItems`, `onOpenChange`, `onNavigation_unstable` and `ref` */ getTreeProps(): Required> & { ref: React_2.Ref; openItems: ImmutableSet; }; /** * internal method used to react to an `onNavigation` event. * This method ensures proper navigation on keyboard and mouse interaction. * In case of virtualization it might be required to cancel default provided `onNavigation` * event and then call this method manually. * * @example * ```ts * // react-window * const handleNavigation = (event, data) => { * event.preventDefault(); * const nextItem = tree.getNextNavigableItem(data); * // scroll to item using virtualization scroll mechanism * if (nextItem && tree.getElementFromItem(nextItem)) { * listRef.current.scrollToItem(nextItem.index); * } * // wait for scrolling to happen and then invoke navigate method * requestAnimationFrame(() => { * tree.navigate(data); * }); * }; *``` */ navigate(data: TreeNavigationData_unstable): void; /** * returns next item to be focused on a navigation. * This method is provided to decouple the element that needs to be focused from * the action of focusing it itself. * * On the case of TypeAhead navigation this method returns the current item. */ getNextNavigableItem(visibleItems: HeadlessTreeItem[], data: TreeNavigationData_unstable): HeadlessTreeItem | undefined; /** * similar to getElementById but for FlatTreeItems */ getElementFromItem(item: HeadlessTreeItem): HTMLElement | null; /** * an iterable containing all visually available flat tree items */ items(): IterableIterator>; }; export declare type HeadlessFlatTreeItem = HeadlessTreeItem; export declare type HeadlessFlatTreeItemProps = HeadlessTreeItemProps; export declare type HeadlessFlatTreeOptions = Pick & Pick & { defaultCheckedItems?: TreeProps['checkedItems']; }; /** * @internal */ declare type HeadlessFlatTreeReturn = HeadlessFlatTree & { getItem(value: TreeItemValue): HeadlessTreeItem | undefined; }; /** * The item that is returned by `createHeadlessTree`, it represents a wrapper around the properties provided to * `createHeadlessTree` but with extra information that might be useful on virtual tree scenarios */ declare type HeadlessTreeItem = { level: number; index: number; position: number; childrenValues: TreeItemValue[]; value: TreeItemValue; parentValue: TreeItemValue | undefined; itemType: TreeItemType; getTreeItemProps(): Required> & Props; }; declare type HeadlessTreeItemProps = Omit & { value: TreeItemValue; itemType?: TreeItemType; parentValue?: TreeItemValue; }; declare class ImmutableMap implements Iterable<[Key, Value]> { static empty: ImmutableMap; readonly size: number; private [internalMapSymbol]; static dangerouslyGetInternalMap(immutableMap: ImmutableMap): Map; static copy(immutableMap: ImmutableMap): ImmutableMap; /** * Creates a new {@link ImmutableMap} from an iterable. * If the iterable is undefined, {@link ImmutableMap.empty} will be returned. * If the iterable is already an {@link ImmutableMap}, it will be returned as is no copy will be made. */ static from(iterable?: Iterable): ImmutableMap; /** * Creates a new {@link ImmutableMap} from an iterable with an auxiliary map function to modify the iterable. * If the iterable is undefined, {@link ImmutableMap.empty} will be returned. * If the iterable is already an {@link ImmutableMap}, it will be returned as is no copy will be made. * The map function will be called for each element in the iterable. */ static from(iterable: Iterable | undefined, mapFn: (value: T) => U): ImmutableMap; static [Symbol.hasInstance](instance: unknown): boolean; /** * Do not use this constructor directly, use {@link ImmutableMap.from} instead. * {@link ImmutableMap.from} handles instance verification (which might be problematic on {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/instanceof#instanceof_and_multiple_realms | multiple realms}), * avoid unnecessary copies, supports iterables and ensures that the internal map is never exposed. * *⚠️⚠️ _By using this constructor directly, you might end up with a mutable map, as it is not guaranteed that the internal map is not exposed._ ⚠️⚠️ */ constructor(internalMap: Map); delete(key: Key): ImmutableMap; get(key: Key): Value | undefined; has(key: Key): boolean; set(key: Key, value: Value): ImmutableMap; [Symbol.iterator](): Iterator<[Key, Value]>; } /** * @public * * Small immutable wrapper around the native Set implementation. * Every operation that would modify the set returns a new copy instance. */ declare class ImmutableSet implements Iterable { static empty: ImmutableSet; readonly size: number; private [internalSetSymbol]; static dangerouslyGetInternalSet(set: ImmutableSet): Set; static copy(immutableSet: ImmutableSet): ImmutableSet; /** * Creates a new {@link ImmutableSet} from an iterable. * If the iterable is undefined, {@link ImmutableSet.empty} will be returned. * If the iterable is already an {@link ImmutableSet}, it will be returned as is no copy will be made. */ static from(iterable?: Iterable): ImmutableSet; static [Symbol.hasInstance](instance: unknown): boolean; /** * Do not use this constructor directly, use {@link ImmutableSet.from} instead. * {@link ImmutableSet.from} handles instance verification (which might be problematic on {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/instanceof#instanceof_and_multiple_realms | multiple realms}), * avoid unnecessary copies, supports iterables and ensures that the internal set is never exposed. * *⚠️⚠️ _By using this constructor directly, you might end up with a mutable set, as it is not guaranteed that the internal set is not exposed._ ⚠️⚠️ */ constructor(internalSet: Set); add(value: T): ImmutableSet; delete(value: T): ImmutableSet; has(value: T): boolean; [Symbol.iterator](): Iterator; } declare const internalMapSymbol: unique symbol; declare const internalSetSymbol: unique symbol; declare type MultiSelectValue = NonNullable; export declare const renderFlatTree_unstable: (state: FlatTreeState, contextValues: FlatTreeContextValues) => JSX.Element; export declare const renderTree_unstable: (state: TreeState, contextValues: TreeContextValues) => JSX.Element; /** * Render the final JSX of TreeItem */ export declare const renderTreeItem_unstable: (state: TreeItemState, contextValues: TreeItemContextValues) => JSX.Element; /** * Render the final JSX of TreeItemLayout */ export declare const renderTreeItemLayout_unstable: (state: TreeItemLayoutState) => JSX.Element; /** * Render the final JSX of TreeItemPersonaLayout */ export declare const renderTreeItemPersonaLayout_unstable: (state: TreeItemPersonaLayoutState, contextValues: TreeItemPersonaLayoutContextValues) => JSX.Element; declare type SingleSelectValue = NonNullable; export declare type SubtreeContextValue = { contextType: 'subtree'; level: number; }; /** * The `Tree` component renders nested items in a hierarchical structure. * Use it with `TreeItem` component and layouts components `TreeItemLayout` or `TreeItemPersonaLayout`. */ export declare const Tree: ForwardRefComponent; export declare type TreeCheckedChangeData = { value: TreeItemValue; checkedItems: Map; target: HTMLElement; event: React_2.ChangeEvent; type: 'Change'; } & ({ selectionMode: 'multiselect'; checked: MultiSelectValue; } | { selectionMode: 'single'; checked: SingleSelectValue; }); export declare type TreeCheckedChangeEvent = TreeCheckedChangeData['event']; export declare const treeClassNames: SlotClassNames>; export declare type TreeContextValue = { contextType?: 'root'; level: number; treeType: 'nested' | 'flat'; selectionMode: 'none' | SelectionMode_2; appearance: 'subtle' | 'subtle-alpha' | 'transparent'; size: 'small' | 'medium'; openItems: ImmutableSet; checkedItems: ImmutableMap; /** * requests root Tree component to respond to some tree item event, */ requestTreeResponse(request: TreeItemRequest): void; }; export declare type TreeContextValues = { tree: TreeContextValue | SubtreeContextValue; }; /** * The `TreeItem` component represents a single item in a tree. * It expects a certain order of children to work properly: the first child should be the node itself, * and the second child should be a nested subtree in the form of another Tree component or a standalone TreeItem. * This order follows the same order as document traversal for the TreeWalker API in JavaScript: * https://developer.mozilla.org/en-US/docs/Web/API/TreeWalker. * The content and layout of a TreeItem can be defined using the TreeItemLayout or TreeItemPersonaLayout component, * which should be used as a direct child of TreeItem. * * When a TreeItem has nested child subtree, an expand/collapse control is displayed, * allowing the user to show or hide the children. */ export declare const TreeItem: ForwardRefComponent; export declare const treeItemClassNames: SlotClassNames; export declare type TreeItemContextValue = { /** * @deprecated - this value is irrelevant for the tree item */ isActionsVisible: boolean; /** * @deprecated - this value is irrelevant for the tree item */ isAsideVisible: boolean; selectionRef: React_2.Ref; actionsRef: React_2.Ref; expandIconRef: React_2.Ref; layoutRef: React_2.Ref; subtreeRef: React_2.Ref; treeItemRef?: React_2.RefObject; itemType: TreeItemType; value: TreeItemValue; open: boolean; checked: TreeSelectionValue; }; declare type TreeItemContextValues = { treeItem: TreeItemContextValue; }; declare type TreeItemCSSProperties = React_2.CSSProperties & { [treeItemLevelToken]?: string | number; }; /** * The `TreeItemLayout` component is used as a child of `TreeItem` to define the content and layout of a tree item. * It provides a consistent visual structure for tree items in a `Tree` component. * This component should only be used as a direct child of `TreeItem`. */ export declare const TreeItemLayout: ForwardRefComponent; declare type TreeItemLayoutActionSlotProps = ExtractSlotProps & { /** * Forces visibility of the aside/action content */ visible?: boolean; onVisibilityChange?: EventHandler; }>; declare type TreeItemLayoutActionVisibilityChangeData = (EventData<'mouseover' | 'mouseout', MouseEvent> | EventData<'focus' | 'blur', FocusEvent> | EventData<'blur', React_2.FocusEvent>) & { visible: boolean; }; export declare const treeItemLayoutClassNames: SlotClassNames; /** * TreeItemLayout Props */ export declare type TreeItemLayoutProps = ComponentProps>; export declare type TreeItemLayoutSlots = { root: Slot<'div'>; /** * Content. Children of the root slot are automatically rendered here */ main: NonNullable>; /** * Icon slot that renders right before main content */ iconBefore?: Slot<'div'>; /** * Icon slot that renders right after main content */ iconAfter?: Slot<'div'>; /** * Expand icon slot, * by default renders a chevron icon to indicate opening and closing */ expandIcon?: Slot<'div'>; /** * Aside content is normally used to render a badge or other non-actionable content * It is aria-hidden by default and is only meant to be used as visual aid. */ aside?: Slot<'div'>; /** * Actionable elements are normally buttons, menus, or other focusable elements. * Those elements are only visibly available if the given tree item is currently active. * * `actions` and `aside` slots are positioned on the exact same spot, * so they won't be visible at the same time. * `aside` slot is visible by default meanwhile `actions` slot are only visible when the tree item is active. * * `actions` slot supports a `visible` prop to force visibility of the actions. */ actions?: Slot; selector?: Slot | Slot; }; /** * State used in rendering TreeItemLayout */ export declare type TreeItemLayoutState = ComponentState & { buttonContextValue: ButtonContextValue; }; export declare const treeItemLevelToken: "--fluent-TreeItem--level"; export declare type TreeItemOpenChangeData = { open: boolean; value: TreeItemValue; target: HTMLElement; } & ({ event: React_2.MouseEvent; type: 'ExpandIconClick'; } | { event: React_2.MouseEvent; type: 'Click'; } | { event: React_2.KeyboardEvent; type: typeof Enter; } | { event: React_2.KeyboardEvent; type: typeof ArrowRight; } | { event: React_2.KeyboardEvent; type: typeof ArrowLeft; }); export declare type TreeItemOpenChangeEvent = TreeItemOpenChangeData['event']; /** * The `TreeItemPersonaLayout` component is used as a child of `TreeItem` to display a `TreeItem` with a media (typically an avatar) and a description. * It provides a more visually appealing representation of a `TreeItem` and is typically used to display a list of people or topics. * This component should only be used as a direct child of `TreeItem`. */ export declare const TreeItemPersonaLayout: ForwardRefComponent; export declare const treeItemPersonaLayoutClassNames: SlotClassNames; declare type TreeItemPersonaLayoutContextValues = { avatar: AvatarContextValue; }; /** * TreeItemPersonaLayout Props */ export declare type TreeItemPersonaLayoutProps = ComponentProps>; export declare type TreeItemPersonaLayoutSlots = Pick & { root: NonNullable>; /** * Avatar to display. */ media: NonNullable>; /** * Content. Children of the root slot are automatically rendered here */ main: NonNullable>; /** * Secondary text that describes or complements the content */ description?: Slot<'div'>; }; /** * State used in rendering TreeItemPersonaLayout */ export declare type TreeItemPersonaLayoutState = ComponentState & { avatarSize: AvatarSize; buttonContextValue: ButtonContextValue; }; /** * TreeItem Props */ export declare type TreeItemProps = ComponentProps> & { /** * A tree item can be a leaf or a branch */ itemType: TreeItemType; /** * A tree item should have a well defined value, in case one is not provided by the user by this prop * one will be inferred internally. */ value?: TreeItemValue; /** * Whether the tree item is in an open state * * This overrides the open value provided by the root tree, * and ensure control of the visibility of the tree item per tree item. * * NOTE: controlling the open state of a tree item will not affect the open state of its children */ open?: boolean; onOpenChange?: (e: TreeItemOpenChangeEvent, data: TreeItemOpenChangeData) => void; /** * This property is inferred through context on a nested tree, and required for a flat tree. */ parentValue?: TreeItemValue; }; export declare const TreeItemProvider: React_2.Provider & React_2.FC>; declare type TreeItemRequest = { itemType: TreeItemType; } & ((DistributiveOmit & { requestType: 'open'; }) | (TreeNavigationData_unstable & { requestType: 'navigate'; }) | (DistributiveOmit & { requestType: 'selection'; })); export declare type TreeItemSlots = { root: Slot & { style?: TreeItemCSSProperties; }>>; }; /** * State used in rendering TreeItem */ export declare type TreeItemState = ComponentState & TreeItemContextValue & { level: number; itemType: TreeItemType; }; export declare type TreeItemType = 'leaf' | 'branch'; export declare type TreeItemValue = string | number; export declare type TreeNavigationData_unstable = { target: HTMLElement; value: TreeItemValue; parentValue: TreeItemValue | undefined; } & ({ event: React_2.MouseEvent; type: 'Click'; } | { event: React_2.KeyboardEvent; type: 'TypeAhead'; } | { event: React_2.KeyboardEvent; type: typeof ArrowRight; } | { event: React_2.KeyboardEvent; type: typeof ArrowLeft; } | { event: React_2.KeyboardEvent; type: typeof ArrowUp; } | { event: React_2.KeyboardEvent; type: typeof ArrowDown; } | { event: React_2.KeyboardEvent; type: typeof Home; } | { event: React_2.KeyboardEvent; type: typeof End; }); /** * @internal * * To avoid breaking changes on TreeNavigationData * we are creating a new type that extends the old one * and adds the new methods, and this type will not be exported */ declare type TreeNavigationDataParam = TreeNavigationData_unstable & { preventScroll(): void; isScrollPrevented(): boolean; }; export declare type TreeNavigationEvent_unstable = TreeNavigationData_unstable['event']; export declare type TreeOpenChangeData = { open: boolean; openItems: Set; value: TreeItemValue; target: HTMLElement; } & ({ event: React_2.MouseEvent; type: 'ExpandIconClick'; } | { event: React_2.MouseEvent; type: 'Click'; } /** * @deprecated * Use `type: 'Click'` instead of Enter, * an enter press will trigger a click event, which will trigger an open change, * so there is no need to have a separate type for it. */ | { event: React_2.KeyboardEvent; type: typeof Enter; } | { event: React_2.KeyboardEvent; type: typeof ArrowRight; } | { event: React_2.KeyboardEvent; type: typeof ArrowLeft; }); export declare type TreeOpenChangeEvent = TreeOpenChangeData['event']; export declare type TreeProps = ComponentProps & { /** * A tree item can have various appearances: * - 'subtle' (default): The default tree item styles. * - 'subtle-alpha': Minimizes emphasis on hovered or focused states. * - 'transparent': Removes background color. * @default 'subtle' */ appearance?: 'subtle' | 'subtle-alpha' | 'transparent'; /** * Size of the tree item. * @default 'medium' */ size?: 'small' | 'medium'; /** * This refers to a list of ids of opened tree items. * Controls the state of the open tree items. * These property is ignored for subtrees. */ openItems?: Iterable; /** * This refers to a list of ids of default opened items. * This property is ignored for subtrees. */ defaultOpenItems?: Iterable; /** * Callback fired when the component changes value from open state. * These property is ignored for subtrees. * * @param event - a React's Synthetic event * @param data - A data object with relevant information, * such as open value and type of interaction that created the event. */ onOpenChange?(event: TreeOpenChangeEvent, data: TreeOpenChangeData): void; /** * Callback fired when navigation happens inside the component. * These property is ignored for subtrees. * * FIXME: This method is not ideal, as navigation should be handled internally by tabster. * * @param event - a React's Synthetic event * @param data - A data object with relevant information, */ onNavigation?(event: TreeNavigationEvent_unstable, data: TreeNavigationDataParam): void; /** * This refers to the selection mode of the tree. * - undefined: No selection can be done. * - 'single': Only one tree item can be selected, radio buttons are rendered. * - 'multiselect': Multiple tree items can be selected, checkboxes are rendered. * * @default undefined */ selectionMode?: SelectionMode_2; /** * This refers to a list of ids of checked tree items, or a list of tuples of ids and checked state. * Controls the state of the checked tree items. * These property is ignored for subtrees. */ checkedItems?: Iterable; /** * Callback fired when the component changes value from checked state. * These property is ignored for subtrees. * * @param event - a React's Synthetic event * @param data - A data object with relevant information, * such as checked value and type of interaction that created the event. */ onCheckedChange?(event: TreeCheckedChangeEvent, data: TreeCheckedChangeData): void; }; export declare const TreeProvider: { (props: React_2.ProviderProps): JSX.Element; displayName: string; }; export declare type TreeSelectionValue = MultiSelectValue | SingleSelectValue; export declare type TreeSlots = { root: Slot<'div'>; collapseMotion?: Slot; }; /** * State used in rendering Tree */ export declare type TreeState = ComponentState & { open: boolean; } & (TreeContextValue | SubtreeContextValue); export declare const useFlatTree_unstable: (props: FlatTreeProps, ref: React_2.Ref) => FlatTreeState; export declare const useFlatTreeContextValues_unstable: (state: FlatTreeState) => FlatTreeContextValues; export declare const useFlatTreeStyles_unstable: (state: FlatTreeState) => FlatTreeState; /** * this hook provides FlatTree API to manage all required mechanisms to convert a list of items into renderable TreeItems * in multiple scenarios including virtualization. * * !!A flat tree is an unofficial spec for tree!! * * It should be used on cases where more complex interactions with a Tree is required. * On simple scenarios it is advised to simply use a nested structure instead. * * @param props - a list of tree items * @param options - in case control over the internal openItems is required */ export declare function useHeadlessFlatTree_unstable(props: Props[], options?: HeadlessFlatTreeOptions): HeadlessFlatTreeReturn; export declare const useSubtreeContext_unstable: () => SubtreeContextValue; export declare const useTree_unstable: (props: TreeProps, ref: React_2.Ref) => TreeState; export declare const useTreeContext_unstable: (selector: ContextSelector) => T; export declare function useTreeContextValues_unstable(state: TreeState): TreeContextValues; /** * Create the state required to render TreeItem. * * The returned state can be modified with hooks such as useTreeItemStyles_unstable, * before being passed to renderTreeItem_unstable. * * @param props - props from this instance of TreeItem * @param ref - reference to root HTMLElement of TreeItem */ export declare function useTreeItem_unstable(props: TreeItemProps, ref: React_2.Ref): TreeItemState; export declare const useTreeItemContext_unstable: (selector: ContextSelector) => T; export declare function useTreeItemContextValues_unstable(state: TreeItemState): TreeItemContextValues; /** * Create the state required to render TreeItemLayout. * * The returned state can be modified with hooks such as useTreeItemLayoutStyles_unstable, * before being passed to renderTreeItemLayout_unstable. * * @param props - props from this instance of TreeItemLayout * @param ref - reference to root HTMLElement of TreeItemLayout */ export declare const useTreeItemLayout_unstable: (props: TreeItemLayoutProps, ref: React_2.Ref) => TreeItemLayoutState; /** * Apply styling to the TreeItemLayout slots based on the state */ export declare const useTreeItemLayoutStyles_unstable: (state: TreeItemLayoutState) => TreeItemLayoutState; /** * Create the state required to render TreeItemPersonaLayout. * * The returned state can be modified with hooks such as useTreeItemPersonaLayoutStyles_unstable, * before being passed to renderTreeItemPersonaLayout_unstable. * * @param props - props from this instance of TreeItemPersonaLayout * @param ref - reference to root HTMLElement of TreeItemPersonaLayout */ export declare const useTreeItemPersonaLayout_unstable: (props: TreeItemPersonaLayoutProps, ref: React_2.Ref) => TreeItemPersonaLayoutState; /** * Apply styling to the TreeItemPersonaLayout slots based on the state */ export declare const useTreeItemPersonaLayoutStyles_unstable: (state: TreeItemPersonaLayoutState) => TreeItemPersonaLayoutState; /** * Apply styling to the TreeItem slots based on the state */ export declare const useTreeItemStyles_unstable: (state: TreeItemState) => TreeItemState; export declare const useTreeStyles_unstable: (state: TreeState) => TreeState; export { }