/** * ToolContext facade — re-exports from submodules for backwards compatibility. * * All existing `import { ... } from "./context.js"` continue to work unchanged. * Internal logic is split into: * - context/shared-state.ts — per-platform caches * - context/ios-helpers.ts — iOS tree parsing * - context/hints.ts — action hints & platform element helpers */ import { DeviceManager } from "../device-manager.js"; import type { UiElement } from "../adb/ui-parser.js"; export { getCachedElements, setCachedElements, lastScreenshotMap, lastUiTreeMap, screenshotScaleMap, invalidateUiTreeCache, } from "./context/shared-state.js"; export { iosTreeToUiElements, formatIOSUITree, } from "./context/ios-helpers.js"; export declare const deviceManager: DeviceManager; export declare const generateActionHints: (platform: string | undefined) => Promise; export declare const getElementsForPlatform: (plat: string) => Promise; export declare const platformParam: { type: string; enum: string[]; description: string; }; export declare const MAX_RECURSION_DEPTH = 3; export interface ToolContext { deviceManager: DeviceManager; getCachedElements: (platform: string) => UiElement[]; setCachedElements: (platform: string, elements: UiElement[]) => void; lastScreenshotMap: Map; lastUiTreeMap: Map; screenshotScaleMap: Map; generateActionHints: (platform?: string) => Promise; getElementsForPlatform: (plat: string) => Promise; iosTreeToUiElements: (tree: any) => UiElement[]; formatIOSUITree: (tree: any, indent?: number) => string; invalidateUiTreeCache: (platform?: string) => void; platformParam: typeof platformParam; handleTool: (name: string, args: Record, depth?: number) => Promise; turboDefault: boolean; } export declare function createToolContext(handleTool: ToolContext["handleTool"], options?: { turboDefault?: boolean; }): ToolContext; //# sourceMappingURL=context.d.ts.map