/** * React hooks for PeersCaller integration * Provides easy-to-use React hooks for video call functionality */ import { PeersCaller } from "../core/PeersCaller"; import { useCallStore } from "../store"; import type { PeersCallerConfig, PeersCallerCallbacks, CallParticipant, MediaStreamConfig, RecordingData } from "../types"; export interface UseVideoCallOptions extends PeersCallerConfig { callbacks?: PeersCallerCallbacks; autoInitialize?: boolean; } export interface UseVideoCallReturn { initialize: () => Promise; startCall: (mediaConfig?: MediaStreamConfig) => Promise; joinCall: (mediaConfig?: MediaStreamConfig) => Promise; endCall: () => void; toggleAudio: (enabled: boolean) => void; toggleVideo: (enabled: boolean) => void; startScreenShare: () => Promise; stopScreenShare: () => Promise; startRecording: (recordingData: RecordingData) => Promise; stopRecording: () => Promise; callState: ReturnType; participants: CallParticipant[]; localParticipant: CallParticipant | null; isConnected: boolean; isRecording: boolean; error: string | null; cleanup: () => void; peersCaller: PeersCaller | null; } /** * Main hook for video call functionality */ export declare function useVideoCall(options: UseVideoCallOptions): UseVideoCallReturn; /** * Hook for accessing participant video streams */ export declare function useParticipantVideo(userId: string): { videoElement: HTMLVideoElement | null; stream: MediaStream | null; participant: CallParticipant; }; /** * Hook for call state management */ export declare function useCallState(): { conversationId: string; participants: Record; localParticipant: CallParticipant | null; isCalling: boolean; isRecording: boolean; recordLoading: boolean; callStatus: "idle" | "connecting" | "connected" | "disconnecting" | "failed"; error: string | null; participantCount: number; isConnected: boolean; hasError: boolean; }; /** * Hook for media device management */ export declare function useMediaDevices(): { devices: { videoDevices: MediaDeviceInfo[]; audioDevices: MediaDeviceInfo[]; }; permissions: { camera: PermissionState | null; microphone: PermissionState | null; }; getDevices: () => Promise; checkPermissions: () => Promise; requestPermissions: () => Promise; }; /** * Hook for browser compatibility checking */ export declare function useBrowserSupport(): { support: { webRTC: boolean; getUserMedia: boolean; getDisplayMedia: boolean; mediaRecorder: boolean; speechRecognition: boolean; }; isSupported: boolean; unsupportedFeatures: string[]; }; //# sourceMappingURL=index.d.ts.map