import type { JSONPath } from "jsonc-parser"; export interface CollapseContextValue { collapsedSet: Set; onToggleCollapse?: (path: JSONPath) => void; } export declare const CollapseContext: import("react").Context; export declare const useCollapseContext: () => CollapseContextValue; export declare const pathKey: (path: JSONPath) => string; export declare const isPathCollapsed: (collapsedSet: Set, path: JSONPath) => boolean; export declare const isNodeHidden: (collapsedPrefixes: readonly JSONPath[], nodePath: JSONPath | undefined) => boolean; /** * Drop serialized collapsed-paths that no longer resolve to an object/array * in the given JSON. Invalid JSON returns the input verbatim so a transient * edit error doesn't nuke state. */ export declare const prunePaths: (jsonText: string, paths: readonly string[]) => string[]; //# sourceMappingURL=CollapseContext.d.ts.map