import { HierarchyLevelDetails, TreeRendererProps } from "../Renderers.js"; import { ErrorInfo, TreeNode } from "../TreeNode.js"; import { JSX } from "react"; /** @alpha */ interface ErrorItemRendererProps extends Pick { /** The tree node associated with the error. Used for displaying the node label in error messages and for scrolling to the node. */ treeNode: Omit; /** The error to render. */ error: ErrorInfo; /** A callback to reload a hierarchy level when an error occurs and `retry` button is clicked. */ reloadTree: (options: { parentNodeId: string | undefined; }) => void; /** A callback to scroll to the node associated with the error. */ scrollToNode: (treeNode: Omit) => void; /** A callback to initiate filtering of the given hierarchy level. */ filterHierarchyLevel?: (hierarchyLevelDetails: HierarchyLevelDetails) => void; } /** * Renders StrataKit `` for all supported error types: * - `ResultSetTooLarge` - renders `resultLimitExceeded` message with actions to increase limit or apply filtering * - `NoFilterMatches` - renders `noFilteredChildren` message with action to change filter * - `ChildrenLoad` - renders `failedToCreateHierarchy` message with action to retry loading * - `Generic` - renders message set on error object. * * @alpha */ declare function ErrorItemRenderer({ treeNode, error, getHierarchyLevelDetails, filterHierarchyLevel, reloadTree, scrollToNode }: ErrorItemRendererProps): JSX.Element; export { ErrorItemRenderer, ErrorItemRendererProps }; //# sourceMappingURL=ErrorItemRenderer.d.ts.map