/**
 * useUIBridge Hook for React Native
 *
 * Provides a simplified interface for common UI Bridge operations.
 */
import type { NativeActionRequest, NativeActionResponse, NativeFindRequest, NativeFindResponse, NativeBridgeSnapshot, RegisteredNativeElement, RegisteredNativeComponent, Workflow } from '../core/types';
/**
 * Component action request
 */
export interface ComponentActionRequest {
    /** Action ID */
    action: string;
    /** Action parameters */
    params?: Record<string, unknown>;
}
/**
 * Component action response
 */
export interface ComponentActionResponse {
    /** Whether the action succeeded */
    success: boolean;
    /** Result of the action */
    result?: unknown;
    /** Error message if failed */
    error?: string;
    /** Duration in milliseconds */
    durationMs: number;
    /** Timestamp */
    timestamp: number;
}
/**
 * useUIBridge return type
 */
export interface UseUIBridgeReturn {
    /** Whether UI Bridge is available */
    available: boolean;
    /** Whether UI Bridge is initialized */
    initialized: boolean;
    /** All registered elements */
    elements: RegisteredNativeElement[];
    /** All registered components */
    components: RegisteredNativeComponent[];
    /** All registered workflows */
    workflows: Workflow[];
    /** Create a snapshot of the current state */
    createSnapshot: () => NativeBridgeSnapshot;
    /** Execute an action on an element */
    executeAction: (elementId: string, request: NativeActionRequest) => Promise<NativeActionResponse>;
    /** Execute a component action */
    executeComponentAction: (componentId: string, request: ComponentActionRequest) => Promise<ComponentActionResponse>;
    /** Find elements */
    find: (request?: NativeFindRequest) => Promise<NativeFindResponse>;
    /** Get an element by ID */
    getElement: (id: string) => RegisteredNativeElement | undefined;
    /** Get a component by ID */
    getComponent: (id: string) => RegisteredNativeComponent | undefined;
    /** Get element state by ID */
    getElementState: (id: string) => ReturnType<RegisteredNativeElement['getState']> | null;
    /** Register a workflow */
    registerWorkflow: (workflow: Workflow) => void;
    /** Unregister a workflow */
    unregisterWorkflow: (id: string) => void;
}
/**
 * useUIBridge hook
 *
 * Provides a simplified interface for accessing UI Bridge functionality.
 *
 * @example
 * ```tsx
 * function MyComponent() {
 *   const { available, elements, executeAction, find } = useUIBridge();
 *
 *   if (!available) {
 *     return <Text>UI Bridge not available</Text>;
 *   }
 *
 *   const handlePress = async () => {
 *     // Find all buttons
 *     const result = await find({ types: ['button'] });
 *     console.log('Found buttons:', result.elements);
 *
 *     // Execute action on specific element
 *     await executeAction('submit-btn', { action: 'press' });
 *   };
 *
 *   return (
 *     <View>
 *       <Text>Elements: {elements.length}</Text>
 *       <Button title="Press" onPress={handlePress} />
 *     </View>
 *   );
 * }
 * ```
 */
export declare function useUIBridge(): UseUIBridgeReturn;
/**
 * useUIBridgeRequired hook
 *
 * Same as useUIBridge but throws if not available.
 */
export declare function useUIBridgeRequired(): UseUIBridgeReturn;
//# sourceMappingURL=useUIBridge.d.ts.map